upcloud_list_servers
List all cloud servers on the UpCloud account.
- Operation
- Read
read - Full name
upcloud.upcloud_list_servers
| Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
productivity
Agent-facing Lua documentation and function reference for the UpCloud KosmoKrator integration.
Agents call this integration through app.integrations.upcloud.*.
Use lua_read_doc("integrations.upcloud") inside KosmoKrator to discover the same reference at runtime.
This is the rendered version of the full Lua documentation exposed to agents when they inspect the integration namespace.
List all cloud servers on the UpCloud account.
None.
-- List all servers
local result = app.integrations.upcloud.list_servers({})
for _, server in ipairs(result.servers) do
print(server.uuid .. ": " .. server.title .. " (" .. server.state .. ")")
end
Get details for a specific UpCloud server.
| Name | Type | Required | Description |
|---|---|---|---|
uuid | string | yes | The server UUID |
local result = app.integrations.upcloud.get_server({ uuid = "abc123-def456" })
print(result.server.title)
print(result.server.state)
print(result.server.vcpu)
print(result.server.memory_amount)
List storage devices on the UpCloud account.
| Name | Type | Required | Description |
|---|---|---|---|
type | string | no | Storage type filter: “disk”, “backup”, or “cdrom” |
-- List all storages
local result = app.integrations.upcloud.list_storages({})
-- List only disk storages
local result = app.integrations.upcloud.list_storages({ type = "disk" })
for _, storage in ipairs(result.storages) do
print(storage.uuid .. ": " .. storage.title .. " (" .. storage.size .. " GB)")
end
List private networks on the UpCloud account.
None.
local result = app.integrations.upcloud.list_networks({})
for _, network in ipairs(result.networks) do
print(network.uuid .. ": " .. network.name .. " (" .. network.zone .. ")")
end
List IP addresses on the UpCloud account.
None.
local result = app.integrations.upcloud.list_ips({})
for _, ip in ipairs(result.ip_addresses) do
print(ip.address .. " (" .. ip.family .. ") -> " .. (ip.server or "unassigned"))
end
List available UpCloud zones (data centers).
None.
local result = app.integrations.upcloud.list_zones({})
for _, zone in ipairs(result.zones) do
print(zone.id .. ": " .. zone.description)
end
Get the profile of the currently authenticated user.
None.
local result = app.integrations.upcloud.get_current_user({})
print("Logged in as: " .. result.account.username)
If you have multiple UpCloud accounts configured, use account-specific namespaces:
-- Default account (always works)
app.integrations.upcloud.function_name({...})
-- Explicit default (portable across setups)
app.integrations.upcloud.default.function_name({...})
-- Named accounts
app.integrations.upcloud.production.function_name({...})
app.integrations.upcloud.staging.function_name({...})
All functions are identical across accounts — only the credentials differ.
# UpCloud — Lua API Reference
## list_servers
List all cloud servers on the UpCloud account.
### Parameters
None.
### Examples
```lua
-- List all servers
local result = app.integrations.upcloud.list_servers({})
for _, server in ipairs(result.servers) do
print(server.uuid .. ": " .. server.title .. " (" .. server.state .. ")")
end
```
---
## get_server
Get details for a specific UpCloud server.
### Parameters
| Name | Type | Required | Description |
|------|------|----------|-------------|
| `uuid` | string | yes | The server UUID |
### Examples
```lua
local result = app.integrations.upcloud.get_server({ uuid = "abc123-def456" })
print(result.server.title)
print(result.server.state)
print(result.server.vcpu)
print(result.server.memory_amount)
```
---
## list_storages
List storage devices on the UpCloud account.
### Parameters
| Name | Type | Required | Description |
|------|------|----------|-------------|
| `type` | string | no | Storage type filter: "disk", "backup", or "cdrom" |
### Examples
```lua
-- List all storages
local result = app.integrations.upcloud.list_storages({})
-- List only disk storages
local result = app.integrations.upcloud.list_storages({ type = "disk" })
for _, storage in ipairs(result.storages) do
print(storage.uuid .. ": " .. storage.title .. " (" .. storage.size .. " GB)")
end
```
---
## list_networks
List private networks on the UpCloud account.
### Parameters
None.
### Examples
```lua
local result = app.integrations.upcloud.list_networks({})
for _, network in ipairs(result.networks) do
print(network.uuid .. ": " .. network.name .. " (" .. network.zone .. ")")
end
```
---
## list_ips
List IP addresses on the UpCloud account.
### Parameters
None.
### Examples
```lua
local result = app.integrations.upcloud.list_ips({})
for _, ip in ipairs(result.ip_addresses) do
print(ip.address .. " (" .. ip.family .. ") -> " .. (ip.server or "unassigned"))
end
```
---
## list_zones
List available UpCloud zones (data centers).
### Parameters
None.
### Examples
```lua
local result = app.integrations.upcloud.list_zones({})
for _, zone in ipairs(result.zones) do
print(zone.id .. ": " .. zone.description)
end
```
---
## get_current_user
Get the profile of the currently authenticated user.
### Parameters
None.
### Examples
```lua
local result = app.integrations.upcloud.get_current_user({})
print("Logged in as: " .. result.account.username)
```
---
## Multi-Account Usage
If you have multiple UpCloud accounts configured, use account-specific namespaces:
```lua
-- Default account (always works)
app.integrations.upcloud.function_name({...})
-- Explicit default (portable across setups)
app.integrations.upcloud.default.function_name({...})
-- Named accounts
app.integrations.upcloud.production.function_name({...})
app.integrations.upcloud.staging.function_name({...})
```
All functions are identical across accounts — only the credentials differ. local result = app.integrations.upcloud.upcloud_list_servers({})
print(result) upcloud_list_serversList all cloud servers on the UpCloud account.
readupcloud.upcloud_list_servers| Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
upcloud_get_serverGet details for a specific UpCloud server by UUID.
readupcloud.upcloud_get_server| Parameter | Type | Required | Description |
|---|---|---|---|
uuid | string | yes | The server UUID. |
upcloud_list_storagesList storage devices on the UpCloud account. Optionally filter by type (disk, backup, cdrom).
readupcloud.upcloud_list_storages| Parameter | Type | Required | Description |
|---|---|---|---|
type | string | no | Storage type filter: "disk", "backup", or "cdrom". |
upcloud_list_networksList private networks on the UpCloud account.
readupcloud.upcloud_list_networks| Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
upcloud_list_ipsList IP addresses on the UpCloud account.
readupcloud.upcloud_list_ips| Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
upcloud_list_zonesList available UpCloud zones (data centers).
readupcloud.upcloud_list_zones| Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
upcloud_get_current_userGet the profile of the currently authenticated UpCloud user. Useful for verifying credentials and displaying account information.
readupcloud.upcloud_get_current_user| Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||