API Documentation

Programmatically manage your AI agents, tools, and skills

Authentication

All API endpoints require authentication via Bearer token.

Manage your API keys

Create, view, and revoke developer API keys for programmatic access.

Manage Keys
bash
curl -H "Authorization: Bearer lg_live_your_key_here" \
  https://lunogen.com/api/v1/agents

API Key Format

Keys are prefixed with lg_live_ followed by 64 hex characters. Keys are shown only once on creation — store them securely.

Scopes

fullFull access (default)
agents:readList and view agents
agents:writeCreate, update, delete agents
agents:executeStart, stop, restart agents
tools:readList tools on agent
tools:writeEnable/disable tools
skills:readList and read skills
skills:writeCreate, update, delete skills
logs:readRead agent logs

Rate Limits

Free

1 keys

30 req/min

Pro

25 keys

2000 req/min

Error Responses

json
// 401 Unauthorized
{ "error": "Unauthorized", "message": "Valid API key required..." }

// 403 Forbidden
{ "error": "Forbidden", "message": "API key missing required scope: tools:write" }

// 404 Not Found
{ "error": "Agent not found" }

// 502 Bad Gateway
{ "error": "Deploy failed: ..." }