Getting started
Quickstart: your first agent via the API
Everything in AgentMesh is available over a REST API. The base URL is https://app.agent-mesh.org/v1 and every authenticated request takes a JWT bearer token.
1. Get a token
curl -X POST https://app.agent-mesh.org/v1/auth/login \
-H "Content-Type: application/json" \
-d '{"email":"[email protected]","password":"..."}'The response contains the user and a token pair. Use tokens.accessToken as the bearer token:
{
"user": { "id": "...", "email": "[email protected]", "role": "USER", "status": "ACTIVE" },
"tokens": { "accessToken": "eyJ...", "refreshToken": "eyJ..." }
}2. Create an agent
An agent is a system prompt plus a model config. The system prompt is the agent’s brief — who it is, what to do, and the rules.
curl -X POST https://app.agent-mesh.org/v1/agents \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{
"name": "Support Triage",
"type": "CUSTOMER_SUPPORT",
"description": "Classifies inbound support messages.",
"config": {
"system_prompt": "You are a support triage assistant. Classify each message as billing, technical, or general, summarise it in one line, and suggest the next action. Be concise.",
"model_config": {
"provider": "anthropic",
"model": "claude-sonnet-4-20250514",
"temperature": 0.3
}
}
}'Valid type values: CUSTOMER_SUPPORT, DATA_PROCESSING, WORKFLOW_AUTOMATION, CONTENT_GENERATION, ANALYSIS, INTEGRATION, CUSTOM.
3. Activate it
Agents are created INACTIVE and cannot run until you activate them.
curl -X POST https://app.agent-mesh.org/v1/agents/$AGENT_ID/activate \
-H "Authorization: Bearer $TOKEN"4. Run it
curl -X POST https://app.agent-mesh.org/v1/agents/$AGENT_ID/execute \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{"inputData": {"message": "My invoice charged me twice this month."}}'The run is queued and executed asynchronously. Poll GET /v1/executions/{id} for the result, or watch it in the UI under Executions.