productivity
Lokalise Lua API for KosmoKrator Agents
Agent-facing Lua documentation and function reference for the Lokalise KosmoKrator integration.Lua Namespace
Agents call this integration through app.integrations.lokalise.*.
Use lua_read_doc("integrations.lokalise") 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
Lokalise workflow without starting an interactive agent session.
kosmo integrations:lua --eval 'dump(app.integrations.lokalise.list_projects({limit = 1, page = 1}))' --json kosmo integrations:lua --eval 'print(docs.read("lokalise"))' --json
kosmo integrations:lua --eval 'print(docs.read("lokalise.list_projects"))' --json Workflow file
Put repeatable logic in a Lua file, then execute it with JSON output for the calling process.
local lokalise = app.integrations.lokalise
local result = lokalise.list_projects({limit = 1, page = 1})
dump(result) kosmo integrations:lua workflow.lua --json
kosmo integrations:lua workflow.lua --force --json integrations:lua exposes app.integrations.lokalise, app.mcp.*, docs.*, json.*, and regex.*. Use app.integrations.lokalise.default.* or app.integrations.lokalise.work.* when you configured named credential accounts.
MCP-only Lua
If the script only needs configured MCP servers and does not need Lokalise, use the narrower 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.
Lokalise Integration
Tools
lokalise_list_projects
List Lokalise projects.
Parameters:
limit(integer, optional) — Maximum number of projects to return (default 25).page(integer, optional) — Page number for pagination (default 1).
lokalise_get_project
Get details of a specific Lokalise project.
Parameters:
project_id(string, required) — The project ID.
lokalise_list_keys
List translation keys in a Lokalise project.
Parameters:
project_id(string, required) — The project ID.limit(integer, optional) — Maximum number of keys to return (default 25).page(integer, optional) — Page number for pagination (default 1).
lokalise_get_key
Get details of a specific translation key.
Parameters:
project_id(string, required) — The project ID.key_id(integer, required) — The key ID.
lokalise_create_key
Create a new translation key in a Lokalise project.
Parameters:
project_id(string, required) — The project ID.key_name(string, required) — The key name (e.g. “app.welcome”).platforms(array, optional) — List of platforms (e.g. [“web”, “ios”, “android”]).translations(object, optional) — Key-value map of language ISO codes to translation values (e.g. {“en”: “Welcome”, “fr”: “Bienvenue”}).description(string, optional) — Description for the key.tags(array, optional) — List of tags to assign to the key.
lokalise_list_translations
List translations in a Lokalise project.
Parameters:
project_id(string, required) — The project ID.limit(integer, optional) — Maximum number of translations to return (default 25).page(integer, optional) — Page number for pagination (default 1).
lokalise_get_current_user
Get the currently authenticated Lokalise user.
Parameters: None.
Raw agent markdown
# Lokalise Integration
## Tools
### lokalise_list_projects
List Lokalise projects.
**Parameters:**
- `limit` (integer, optional) — Maximum number of projects to return (default 25).
- `page` (integer, optional) — Page number for pagination (default 1).
### lokalise_get_project
Get details of a specific Lokalise project.
**Parameters:**
- `project_id` (string, required) — The project ID.
### lokalise_list_keys
List translation keys in a Lokalise project.
**Parameters:**
- `project_id` (string, required) — The project ID.
- `limit` (integer, optional) — Maximum number of keys to return (default 25).
- `page` (integer, optional) — Page number for pagination (default 1).
### lokalise_get_key
Get details of a specific translation key.
**Parameters:**
- `project_id` (string, required) — The project ID.
- `key_id` (integer, required) — The key ID.
### lokalise_create_key
Create a new translation key in a Lokalise project.
**Parameters:**
- `project_id` (string, required) — The project ID.
- `key_name` (string, required) — The key name (e.g. "app.welcome").
- `platforms` (array, optional) — List of platforms (e.g. ["web", "ios", "android"]).
- `translations` (object, optional) — Key-value map of language ISO codes to translation values (e.g. {"en": "Welcome", "fr": "Bienvenue"}).
- `description` (string, optional) — Description for the key.
- `tags` (array, optional) — List of tags to assign to the key.
### lokalise_list_translations
List translations in a Lokalise project.
**Parameters:**
- `project_id` (string, required) — The project ID.
- `limit` (integer, optional) — Maximum number of translations to return (default 25).
- `page` (integer, optional) — Page number for pagination (default 1).
### lokalise_get_current_user
Get the currently authenticated Lokalise user.
**Parameters:** None. local result = app.integrations.lokalise.list_projects({limit = 1, page = 1})
print(result) Functions
list_projects Read
List Lokalise projects. Returns project IDs, names, languages, and other metadata. Supports pagination.
- Lua path
app.integrations.lokalise.list_projects- Full name
lokalise.lokalise_list_projects
| Parameter | Type | Required | Description |
|---|---|---|---|
limit | integer | no | Maximum number of projects to return (default 25). |
page | integer | no | Page number for pagination (default 1). |
get_project Read
Get details of a specific Lokalise project. Returns project name, description, languages, statistics, and settings.
- Lua path
app.integrations.lokalise.get_project- Full name
lokalise.lokalise_get_project
| Parameter | Type | Required | Description |
|---|---|---|---|
project_id | string | yes | The project ID. |
list_keys Read
List translation keys in a Lokalise project. Returns key IDs, names, platforms, and other metadata. Supports pagination.
- Lua path
app.integrations.lokalise.list_keys- Full name
lokalise.lokalise_list_keys
| Parameter | Type | Required | Description |
|---|---|---|---|
project_id | string | yes | The project ID. |
limit | integer | no | Maximum number of keys to return (default 25). |
page | integer | no | Page number for pagination (default 1). |
get_key Read
Get details of a specific translation key in a Lokalise project. Returns key name, platforms, translations, and other metadata.
- Lua path
app.integrations.lokalise.get_key- Full name
lokalise.lokalise_get_key
| Parameter | Type | Required | Description |
|---|---|---|---|
project_id | string | yes | The project ID. |
key_id | integer | yes | The key ID. |
create_key Write
Create a new translation key in a Lokalise project. The key name and optional translations for each language can be provided.
- Lua path
app.integrations.lokalise.create_key- Full name
lokalise.lokalise_create_key
| Parameter | Type | Required | Description |
|---|---|---|---|
project_id | string | yes | The project ID. |
key_name | string | yes | The key name (e.g. "app.welcome"). |
platforms | array | no | List of platforms (e.g. ["web", "ios", "android"]). |
translations | object | no | Key-value map of language ISO codes to translation values (e.g. {"en": "Welcome", "fr": "Bienvenue"}). |
description | string | no | Description for the key. |
tags | array | no | List of tags to assign to the key. |
list_translations Read
List translations in a Lokalise project. Returns translation values, language codes, and key references. Supports pagination.
- Lua path
app.integrations.lokalise.list_translations- Full name
lokalise.lokalise_list_translations
| Parameter | Type | Required | Description |
|---|---|---|---|
project_id | string | yes | The project ID. |
limit | integer | no | Maximum number of translations to return (default 25). |
page | integer | no | Page number for pagination (default 1). |
get_current_user Read
Get the currently authenticated Lokalise user. Returns user email, name, and account details.
- Lua path
app.integrations.lokalise.get_current_user- Full name
lokalise.lokalise_get_current_user
| Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||