API reference

Agents

An agent is a standing member of your team: a named role with its own instructions, tools, status and memory, used across any number of workflows. Link one into a crew with agentId.

The agent object#

idstringoptional
Unique identifier. Use it as agentId on a crew entry.
namestringoptional
Display name, 1–80 characters.
descriptionstring | nulloptional
Optional one-liner, up to 280 characters.
categorystringoptional
Free-text grouping, default General.
rolestringoptional
The step name used in workflows and run logs, 1–60 characters.
systemPromptstringoptional
The agent's instructions, 1–8000 characters.
modelstring | nulloptional
Model override; null inherits the workflow default.
maxTokensinteger | nulloptional
Per-turn output cap, 256–32000.
connectorsstring[]optional
Connector ids the agent may use.
capabilitiesstring[]optional
Enabled capability ids, e.g. gmail.send.
statusstringoptional
active or paused. A run that reaches a step linked to a paused agent fails with a clear message instead of running it.
memory_enabledbooleanoptional
Whether the agent keeps memory between runs, shared across every workflow it works in. Default true.
created_atstringoptional
ISO 8601 timestamp.
updated_atstringoptional
ISO 8601 timestamp.
Linking an agent into a workflow
Put { "agentId": "<id>", "role": "...", "systemPrompt": "..." } in a workflow's crew. The runner uses the agent's live definition; the other fields are a display snapshot and a fallback if the agent is later deleted. Edit the agent once and every workflow picks it up on its next run.

List agents#

GET/v1/agents
bash
curl https://loopllama.ai/api/v1/agents \
  -H "Authorization: Bearer $LOOPLLAMA_API_KEY"

Create an agent#

POST/v1/agents

Body parameters

namestringrequired
1–80 characters.
rolestringrequired
1–60 characters.
systemPromptstringrequired
1–8000 characters.
descriptionstringoptional
Optional.
categorystringoptional
Optional.
modelstringoptional
Optional; must be a routable catalog id.
maxTokensintegeroptional
Optional.
connectorsstring[]optional
Optional, up to 8.
capabilitiesstring[]optional
Optional, up to 40.
statusstringoptional
Optional, default active.
memory_enabledbooleanoptional
Optional, default true.
bash
curl -X POST https://loopllama.ai/api/v1/agents \
  -H "Authorization: Bearer $LOOPLLAMA_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "name": "Account Manager",
    "role": "account-manager",
    "systemPrompt": "You look after our merchant accounts. Be warm, precise, and keep notes on each relationship.",
    "connectors": ["gmail", "salesforce"],
    "capabilities": ["gmail.read", "gmail.send", "salesforce.read"]
  }'

Response

json
{
  "data": {
    "id": "ckag...",
    "name": "Account Manager",
    "description": null,
    "category": "General",
    "role": "account-manager",
    "systemPrompt": "You look after our merchant accounts. ...",
    "model": null,
    "maxTokens": null,
    "connectors": ["gmail", "salesforce"],
    "capabilities": ["gmail.read", "gmail.send", "salesforce.read"],
    "status": "active",
    "memory_enabled": true,
    "created_at": "2026-10-07T15:00:00.000Z",
    "updated_at": "2026-10-07T15:00:00.000Z"
  }
}

Retrieve an agent#

GET/v1/agents/{id}

Update, pause or resume an agent#

PATCH/v1/agents/{id}

Any subset of the create fields. Send { "status": "paused" } to take the agent offline and { "status": "active" } to bring it back.

Delete an agent#

DELETE/v1/agents/{id}

Deletes the agent and its memory. Workflows that linked it keep their snapshot and run those steps as plain, unlinked steps. Run history is kept.

Agent memory#

The same memory object and semantics as workflow memory, scoped to the agent instead of a workflow role. Notes written here are seen by the agent in every workflow it works in.

GET/v1/agents/{id}/memory
POST/v1/agents/{id}/memory
GET/v1/agents/{id}/memory/{memoryId}
PATCH/v1/agents/{id}/memory/{memoryId}
DELETE/v1/agents/{id}/memory/{memoryId}
bash
curl -X POST https://loopllama.ai/api/v1/agents/ckag.../memory \
  -H "Authorization: Bearer $LOOPLLAMA_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{ "content": "Acme Corp renews in March; Dana Reyes wants a call before any pricing email.", "pinned": true }'