KosmoKrator

productivity

Podio Lua API for KosmoKrator Agents

Agent-facing Lua documentation and function reference for the Podio KosmoKrator integration.

7 functions 7 read 0 write Manual OAuth token auth

Lua Namespace

Agents call this integration through app.integrations.podio.*. Use lua_read_doc("integrations.podio") inside KosmoKrator to discover the same reference at runtime.

Agent-Facing Lua Docs

This is the rendered version of the full Lua documentation exposed to agents when they inspect the integration namespace.

Podio — Lua API Reference

list_spaces

List all workspaces (spaces) in a Podio organization.

Parameters

NameTypeRequiredDescription
org_idintegeryesThe Podio organization ID

Example

local result = app.integrations.podio.list_spaces({
  org_id = 12345
})

for _, space in ipairs(result.spaces) do
  print(space.name .. " (ID: " .. space.space_id .. ")")
end

get_space

Get detailed information about a specific Podio workspace.

Parameters

NameTypeRequiredDescription
space_idintegeryesThe Podio space (workspace) ID

Example

local space = app.integrations.podio.get_space({
  space_id = 67890
})

print("Space: " .. space.name)
print("URL: " .. space.url)

list_apps

List all apps in a Podio workspace.

Parameters

NameTypeRequiredDescription
space_idintegeryesThe Podio space (workspace) ID

Example

local result = app.integrations.podio.list_apps({
  space_id = 67890
})

for _, app in ipairs(result.apps) do
  print(app.name .. " (" .. app.item_count .. " items)")
end

get_app

Get detailed information about a specific Podio app, including field definitions.

Parameters

NameTypeRequiredDescription
app_idintegeryesThe Podio app ID

Example

local app = app.integrations.podio.get_app({
  app_id = 11111
})

print("App: " .. app.name)
for _, field in ipairs(app.fields) do
  print("  Field: " .. field.external_id .. " (" .. field.type .. ")")
end

list_items

List and filter items in a Podio app with sorting and pagination.

Parameters

NameTypeRequiredDescription
app_idintegeryesThe Podio app ID
limitintegernoMax items to return (default: 20, max: 500)
offsetintegernoOffset for pagination (default: 0)
sort_bystringnoField to sort by (e.g., "created_on", "title", or a field external ID)
sort_descbooleannoSort descending (default: true)
filtersstringnoJSON-encoded filter object (keys are field external IDs)

Example

-- List recent items
local result = app.integrations.podio.list_items({
  app_id = 11111,
  limit = 10,
  sort_by = "created_on",
  sort_desc = true
})

for _, item in ipairs(result.items) do
  print(item.title .. " (ID: " .. item.item_id .. ")")
end

-- Filter items by field value
local result = app.integrations.podio.list_items({
  app_id = 11111,
  filters = '{"status":"active"}',
  limit = 50
})

get_item

Get detailed information about a specific Podio item, including all field values.

Parameters

NameTypeRequiredDescription
item_idintegeryesThe Podio item ID

Example

local item = app.integrations.podio.get_item({
  item_id = 22222
})

print("Item: " .. item.title)
for _, field in ipairs(item.fields) do
  print("  " .. field.external_id .. ": " .. vim.inspect(field.values))
end

get_current_user

Get the status of the currently authenticated Podio user.

Parameters

None.

Example

local status = app.integrations.podio.get_current_user({})
print("Logged in as: " .. status.profile.name)

Multi-Account Usage

If you have multiple Podio accounts configured, use account-specific namespaces:

-- Default account (always works)
app.integrations.podio.list_spaces({ org_id = 12345 })

-- Explicit default (portable across setups)
app.integrations.podio.default.list_spaces({ org_id = 12345 })

-- Named accounts
app.integrations.podio.work.list_spaces({ org_id = 12345 })
app.integrations.podio.personal.list_spaces({ org_id = 67890 })

All functions are identical across accounts — only the credentials differ.

Raw agent markdown
# Podio — Lua API Reference

## list_spaces

List all workspaces (spaces) in a Podio organization.

### Parameters

| Name | Type | Required | Description |
|------|------|----------|-------------|
| `org_id` | integer | yes | The Podio organization ID |

### Example

```lua
local result = app.integrations.podio.list_spaces({
  org_id = 12345
})

for _, space in ipairs(result.spaces) do
  print(space.name .. " (ID: " .. space.space_id .. ")")
end
```

---

## get_space

Get detailed information about a specific Podio workspace.

### Parameters

| Name | Type | Required | Description |
|------|------|----------|-------------|
| `space_id` | integer | yes | The Podio space (workspace) ID |

### Example

```lua
local space = app.integrations.podio.get_space({
  space_id = 67890
})

print("Space: " .. space.name)
print("URL: " .. space.url)
```

---

## list_apps

List all apps in a Podio workspace.

### Parameters

| Name | Type | Required | Description |
|------|------|----------|-------------|
| `space_id` | integer | yes | The Podio space (workspace) ID |

### Example

```lua
local result = app.integrations.podio.list_apps({
  space_id = 67890
})

for _, app in ipairs(result.apps) do
  print(app.name .. " (" .. app.item_count .. " items)")
end
```

---

## get_app

Get detailed information about a specific Podio app, including field definitions.

### Parameters

| Name | Type | Required | Description |
|------|------|----------|-------------|
| `app_id` | integer | yes | The Podio app ID |

### Example

```lua
local app = app.integrations.podio.get_app({
  app_id = 11111
})

print("App: " .. app.name)
for _, field in ipairs(app.fields) do
  print("  Field: " .. field.external_id .. " (" .. field.type .. ")")
end
```

---

## list_items

List and filter items in a Podio app with sorting and pagination.

### Parameters

| Name | Type | Required | Description |
|------|------|----------|-------------|
| `app_id` | integer | yes | The Podio app ID |
| `limit` | integer | no | Max items to return (default: 20, max: 500) |
| `offset` | integer | no | Offset for pagination (default: 0) |
| `sort_by` | string | no | Field to sort by (e.g., `"created_on"`, `"title"`, or a field external ID) |
| `sort_desc` | boolean | no | Sort descending (default: true) |
| `filters` | string | no | JSON-encoded filter object (keys are field external IDs) |

### Example

```lua
-- List recent items
local result = app.integrations.podio.list_items({
  app_id = 11111,
  limit = 10,
  sort_by = "created_on",
  sort_desc = true
})

for _, item in ipairs(result.items) do
  print(item.title .. " (ID: " .. item.item_id .. ")")
end

-- Filter items by field value
local result = app.integrations.podio.list_items({
  app_id = 11111,
  filters = '{"status":"active"}',
  limit = 50
})
```

---

## get_item

Get detailed information about a specific Podio item, including all field values.

### Parameters

| Name | Type | Required | Description |
|------|------|----------|-------------|
| `item_id` | integer | yes | The Podio item ID |

### Example

```lua
local item = app.integrations.podio.get_item({
  item_id = 22222
})

print("Item: " .. item.title)
for _, field in ipairs(item.fields) do
  print("  " .. field.external_id .. ": " .. vim.inspect(field.values))
end
```

---

## get_current_user

Get the status of the currently authenticated Podio user.

### Parameters

None.

### Example

```lua
local status = app.integrations.podio.get_current_user({})
print("Logged in as: " .. status.profile.name)
```

---

## Multi-Account Usage

If you have multiple Podio accounts configured, use account-specific namespaces:

```lua
-- Default account (always works)
app.integrations.podio.list_spaces({ org_id = 12345 })

-- Explicit default (portable across setups)
app.integrations.podio.default.list_spaces({ org_id = 12345 })

-- Named accounts
app.integrations.podio.work.list_spaces({ org_id = 12345 })
app.integrations.podio.personal.list_spaces({ org_id = 67890 })
```

All functions are identical across accounts — only the credentials differ.

Metadata-Derived Lua Example

local result = app.integrations.podio.podio_list_spaces({
  org_id = 1
})
print(result)

Functions

podio_list_spaces

List all workspaces (spaces) in a Podio organization. Returns space IDs, names, URLs, and membership details. Use this to discover available workspaces before exploring their apps and items.

Operation
Read read
Full name
podio.podio_list_spaces
ParameterTypeRequiredDescription
org_id integer yes The Podio organization ID to list spaces for.

podio_get_space

Get detailed information about a specific Podio workspace, including its name, description, URL, and settings. Use the space ID obtained from podio_list_spaces.

Operation
Read read
Full name
podio.podio_get_space
ParameterTypeRequiredDescription
space_id integer yes The Podio space (workspace) ID.

podio_list_apps

List all apps in a Podio workspace. Returns app IDs, names, item counts, and configuration. Use this to discover available apps before querying their items.

Operation
Read read
Full name
podio.podio_list_apps
ParameterTypeRequiredDescription
space_id integer yes The Podio space (workspace) ID to list apps for.

podio_get_app

Get detailed information about a specific Podio app, including its field definitions, layout, and configuration. Use this to understand the data structure before listing or filtering items.

Operation
Read read
Full name
podio.podio_get_app
ParameterTypeRequiredDescription
app_id integer yes The Podio app ID.

podio_list_items

List and filter items in a Podio app. Supports filtering by field values, sorting, and pagination. Use podio_get_app first to understand the available fields for filtering.

Operation
Read read
Full name
podio.podio_list_items
ParameterTypeRequiredDescription
app_id integer yes The Podio app ID to list items from.
limit integer no Maximum number of items to return (default: 20, max: 500).
offset integer no Offset for pagination (default: 0).
sort_by string no The field to sort by. Use "created_on" or "last_event_on" for built-in sorting, or a field external ID.
sort_desc boolean no Sort in descending order (default: true).
filters string no JSON-encoded filter object. Keys are field external IDs, values are the filter criteria. Example: '{"title":"My Item"}'

podio_get_item

Get detailed information about a specific Podio item, including all field values, references, and metadata. Use the item ID obtained from podio_list_items.

Operation
Read read
Full name
podio.podio_get_item
ParameterTypeRequiredDescription
item_id integer yes The Podio item ID.

podio_get_current_user

Get the status of the currently authenticated Podio user, including profile information, active organization memberships, and account details.

Operation
Read read
Full name
podio.podio_get_current_user
ParameterTypeRequiredDescription
No parameters.