Skip to content

Agents API

Agents are persistent AI identities with persona, objectives, and memory. They accumulate context across tasks.

Create Agent

POST /api/v1/agents

Request Body

FieldTypeRequiredDescription
namestringYesDisplay name (e.g. “Sarah - Sales AI”)
external_user_idstringNoUser ID in external system this agent acts as
personaobjectNoRole, communication style, description
objectivesarrayNoCurrent goals for the agent
allowed_toolsarrayNoTool-level permissions
configobjectNoAgent-specific settings

Example

Terminal window
curl -X POST https://api.kernelservice.com/api/v1/agents \
-H "Content-Type: application/json" \
-H "X-Tenant-ID: $TENANT_ID" \
-H "X-API-Key: $API_KEY" \
-d '{
"name": "Sarah - Sales AI",
"external_user_id": "rol-user-42",
"persona": {
"role": "Sales Development Representative",
"communication_style": "professional, warm, concise",
"description": "Specialises in recruitment industry sales"
},
"objectives": [
"Qualify inbound leads within 5 minutes",
"Draft personalised follow-up emails",
"Book meetings with qualified prospects"
]
}'

List Agents

GET /api/v1/agents

Get Agent

GET /api/v1/agents/{agent_id}

Update Agent

PATCH /api/v1/agents/{agent_id}

Update persona, objectives, or permissions for an existing agent.