packages/cloud-frontend/content/api/agents.mdx
import { Callout, Tabs } from "@/docs/components";
Create, configure, and manage your AI agents (characters).
<Callout type="info"> **API Key Support:** All agent management endpoints support API key authentication. This enables: - **Developers** to manage agents programmatically from scripts and CI/CD pipelines - **AI Agents** to create and manage other agents autonomously - **Integration** with external systems that need to provision agents automatically </Callout>All agent endpoints accept authentication via:
X-API-Key header or Authorization: Bearer header# Using X-API-Key header (recommended)
curl "https://elizacloud.ai/api/my-agents/characters" \
-H "X-API-Key: YOUR_API_KEY"
# Using Authorization header
curl "https://elizacloud.ai/api/my-agents/characters" \
-H "Authorization: Bearer YOUR_API_KEY"
Get all your agents with optional filtering and pagination.
| Parameter | Type | Description |
|---|---|---|
search | string | Search by name or bio |
category | string | Filter by category |
sortBy | string | newest, updated, or name |
order | string | asc or desc |
page | number | Page number (default: 1) |
limit | number | Items per page (default: 30, max: 1000) |
{
"success": true,
"data": {
"characters": [
{
"id": "uuid-abc123",
"name": "Customer Support Bot",
"bio": ["Expert in customer support"],
"avatarUrl": "https://...",
"category": "support",
"isPublic": false,
"createdAt": "2024-01-15T10:30:00Z",
"updatedAt": "2024-01-15T10:30:00Z"
}
],
"pagination": {
"page": 1,
"limit": 30,
"totalPages": 1,
"totalCount": 1,
"hasMore": false
}
}
}
Create a new agent with a name and optional bio.
{
"name": "My Assistant",
"bio": "A helpful customer support assistant"
}
| Parameter | Type | Required | Description |
|---|---|---|---|
name | string | ✓ | Agent name (max 100 characters) |
bio | string | Agent bio/description |
{
"success": true,
"agent": {
"id": "uuid-abc123",
"name": "My Assistant",
"username": "my-assistant",
"bio": ["A helpful customer support assistant"],
"created_at": "2024-01-15T10:30:00Z"
}
}
Get details about a specific agent.
{
"success": true,
"data": {
"character": {
"id": "uuid-abc123",
"name": "My Assistant",
"bio": ["A helpful assistant"],
"avatarUrl": null,
"category": null,
"isPublic": false,
"createdAt": "2024-01-15T10:30:00Z"
}
}
}
Delete an agent you own.
{
"success": true,
"data": {
"message": "Character deleted successfully"
}
}
Create a copy of an existing agent.
Get usage statistics for an agent. The response currently exposes counters reported by the API; treat zero values as "no recorded activity" rather than a guarantee that deeper analytics are unavailable.
{
"success": true,
"data": {
"stats": {
"views": 0,
"interactions": 0,
"messageCount": 0
}
}
}
Publish an agent to the marketplace.
<Callout type="info"> Published agents can be discovered and used by other users in the marketplace. </Callout>