KosmoKrator

productivity

Appetize Lua API for KosmoKrator Agents

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

Lua Namespace

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

Call Lua from the Headless CLI

Use kosmo integrations:lua when a shell script, CI job, cron job, or another coding CLI should run a deterministic Appetize workflow without starting an interactive agent session.

Inline Lua call
kosmo integrations:lua --eval 'dump(app.integrations.appetize.list({}))' --json
Read Lua docs headlessly
kosmo integrations:lua --eval 'print(docs.read("appetize"))' --json
kosmo integrations:lua --eval 'print(docs.read("appetize.list"))' --json

Workflow file

Put repeatable logic in a Lua file, then execute it with JSON output for the calling process.

workflow.lua
local appetize = app.integrations.appetize
local result = appetize.list({})

dump(result)
Run the workflow
kosmo integrations:lua workflow.lua --json
kosmo integrations:lua workflow.lua --force --json
Namespace note. integrations:lua exposes app.integrations.appetize, app.mcp.*, docs.*, json.*, and regex.*. Use app.integrations.appetize.default.* or app.integrations.appetize.work.* when you configured named credential accounts.

MCP-only Lua

If the script only needs configured MCP servers and does not need Appetize, use the narrower mcp:lua command.

MCP Lua command
# Use mcp:lua for MCP-only scripts; use integrations:lua for this integration namespace.
kosmo mcp:lua --eval 'dump(mcp.servers())' --json

Agent-Facing Lua Docs

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

Appetize

Use the appetize namespace to manage Appetize-hosted mobile app builds, app groups, usage reports, and supported device metadata.

Authentication uses an Appetize organization API token sent as the X-API-KEY header. Private Enterprise instances can override the API base URL in integration settings.

Common usage

  • Use appetize_list_apps with query.nextKey to page through account apps.
  • Use appetize_get_app with a build public key, or an app-group public key beginning with ag_.
  • Use appetize_create_app with a payload that includes platform and a public app file url.
  • Use appetize_update_app to replace a build or update settings for an existing public key.
  • Use appetize_get_usage_summary with query.startMonth and query.nextKey for monthly session totals.
  • Use appetize_list_devices to fetch supported devices and OS versions from the v2 service endpoint.

Tool notes

appetize_list_apps returns Appetize’s paginated shape, typically including hasMore, nextKey, and data.

appetize_list_all_apps calls the non-paginated Appetize endpoint. Prefer appetize_list_apps for large accounts.

appetize_create_app accepts the documented Appetize create-app JSON body. A minimal Android example:

appetize_create_app({
  payload = {
    platform = "android",
    url = "https://example.test/app.apk",
    note = "QA smoke build"
  }
})

appetize_get_usage_summary returns usage rows grouped by month and public key. A paginated example:

appetize_get_usage_summary({
  query = {
    startMonth = "2026-05",
    nextKey = "cursor"
  }
})

appetize_api_get, appetize_api_post, and appetize_api_delete are escape hatches for documented Appetize endpoints that do not yet have first-class tools. They only accept relative paths such as /v1/apps; full URLs are rejected.

Raw agent markdown
# Appetize

Use the `appetize` namespace to manage Appetize-hosted mobile app builds, app groups, usage reports, and supported device metadata.

Authentication uses an Appetize organization API token sent as the `X-API-KEY` header. Private Enterprise instances can override the API base URL in integration settings.

## Common usage

- Use `appetize_list_apps` with `query.nextKey` to page through account apps.
- Use `appetize_get_app` with a build public key, or an app-group public key beginning with `ag_`.
- Use `appetize_create_app` with a `payload` that includes `platform` and a public app file `url`.
- Use `appetize_update_app` to replace a build or update settings for an existing public key.
- Use `appetize_get_usage_summary` with `query.startMonth` and `query.nextKey` for monthly session totals.
- Use `appetize_list_devices` to fetch supported devices and OS versions from the v2 service endpoint.

## Tool notes

`appetize_list_apps` returns Appetize's paginated shape, typically including `hasMore`, `nextKey`, and `data`.

`appetize_list_all_apps` calls the non-paginated Appetize endpoint. Prefer `appetize_list_apps` for large accounts.

`appetize_create_app` accepts the documented Appetize create-app JSON body. A minimal Android example:

```lua
appetize_create_app({
  payload = {
    platform = "android",
    url = "https://example.test/app.apk",
    note = "QA smoke build"
  }
})
```

`appetize_get_usage_summary` returns usage rows grouped by month and public key. A paginated example:

```lua
appetize_get_usage_summary({
  query = {
    startMonth = "2026-05",
    nextKey = "cursor"
  }
})
```

`appetize_api_get`, `appetize_api_post`, and `appetize_api_delete` are escape hatches for documented Appetize endpoints that do not yet have first-class tools. They only accept relative paths such as `/v1/apps`; full URLs are rejected.
Metadata-derived Lua example
local result = app.integrations.appetize.list({})
print(result)

Functions

list Read

List Appetize apps with pagination.

Lua path
app.integrations.appetize.list
Full name
appetize.appetize_list_apps
ParameterTypeRequiredDescription
No parameters.
list_all Read

List all Appetize apps without pagination.

Lua path
app.integrations.appetize.list_all
Full name
appetize.appetize_list_all_apps
ParameterTypeRequiredDescription
No parameters.
get Read

Get one app or app group by public key.

Lua path
app.integrations.appetize.get
Full name
appetize.appetize_get_app
ParameterTypeRequiredDescription
No parameters.
create Write

Create a new Appetize app from a public URL.

Lua path
app.integrations.appetize.create
Full name
appetize.appetize_create_app
ParameterTypeRequiredDescription
No parameters.
update Write

Update an app build or settings.

Lua path
app.integrations.appetize.update
Full name
appetize.appetize_update_app
ParameterTypeRequiredDescription
No parameters.
delete Write

Delete one Appetize app.

Lua path
app.integrations.appetize.delete
Full name
appetize.appetize_delete_app
ParameterTypeRequiredDescription
No parameters.
get_usage_summary Read

Get account usage summary.

Lua path
app.integrations.appetize.get_usage_summary
Full name
appetize.appetize_get_usage_summary
ParameterTypeRequiredDescription
No parameters.
list_devices Read

List supported Appetize devices and OS versions.

Lua path
app.integrations.appetize.list_devices
Full name
appetize.appetize_list_devices
ParameterTypeRequiredDescription
No parameters.
api_get Read

Call a safe relative Appetize GET path.

Lua path
app.integrations.appetize.api_get
Full name
appetize.appetize_api_get
ParameterTypeRequiredDescription
No parameters.
api_post Write

Call a safe relative Appetize POST path.

Lua path
app.integrations.appetize.api_post
Full name
appetize.appetize_api_post
ParameterTypeRequiredDescription
No parameters.
api_delete Write

Call a safe relative Appetize DELETE path.

Lua path
app.integrations.appetize.api_delete
Full name
appetize.appetize_api_delete
ParameterTypeRequiredDescription
No parameters.