Skip to content

Quick Start

Get from zero to a running AI agent in under 10 minutes.

Prerequisites: curl, jq, and a terminal.

  1. Use the dev login endpoint. Google/GitHub OAuth is coming soon.

    Terminal window
    TOKEN=$(curl -s -X POST https://api.astromesh.io/api/v1/auth/dev/login \
    -H "Content-Type: application/json" \
    -d '{"email": "you@example.com", "name": "Your Name"}' \
    | jq -r '.access_token')
    ORG=$(curl -s https://api.astromesh.io/api/v1/orgs/me \
    -H "Authorization: Bearer $TOKEN" \
    | jq -r '.slug')
    echo "Org: $ORG"
  2. Store your OpenAI key so the agent can call the model. Skip this step if you want to use ollama/llama3 (included in the platform).

    Terminal window
    curl -X POST "https://api.astromesh.io/api/v1/orgs/$ORG/providers" \
    -H "Authorization: Bearer $TOKEN" \
    -H "Content-Type: application/json" \
    -d '{"provider": "openai", "api_key": "sk-your-openai-key"}'
  3. Create an agent in draft state with a WizardConfig:

    Terminal window
    curl -X POST "https://api.astromesh.io/api/v1/orgs/$ORG/agents" \
    -H "Authorization: Bearer $TOKEN" \
    -H "Content-Type: application/json" \
    -d '{
    "name": "my-first-agent",
    "display_name": "My First Agent",
    "step1": {"model": "openai/gpt-4o-mini"},
    "step2": {
    "system_prompt": "You are a helpful assistant. Answer clearly and concisely.",
    "persona": "Assistant"
    },
    "step3": {"tools": []},
    "step4": {
    "memory_type": "conversational",
    "memory_strategy": "sliding_window",
    "window_size": 10
    },
    "step5": {}
    }'

    The response includes "status": "draft".

  4. Compile the config and register the agent in the runtime:

    Terminal window
    curl -X POST "https://api.astromesh.io/api/v1/orgs/$ORG/agents/my-first-agent/deploy" \
    -H "Authorization: Bearer $TOKEN"
    {
    "status": "deployed",
    "agent_id": "my-org__my-first-agent",
    "deployed_at": "2026-03-17T12:00:00Z"
    }
  5. Terminal window
    curl -X POST "https://api.astromesh.io/api/v1/orgs/$ORG/agents/my-first-agent/run" \
    -H "Authorization: Bearer $TOKEN" \
    -H "Content-Type: application/json" \
    -d '{"query": "Hello! What can you help me with?", "session_id": "sess-001"}'
    {
    "answer": "I can help you with a wide range of questions...",
    "session_id": "sess-001",
    "tokens_used": 87,
    "model": "openai/gpt-4o-mini",
    "latency_ms": 950
    }
  6. JWT tokens expire. For production integrations, create a long-lived API key:

    Terminal window
    SECRET=$(curl -s -X POST "https://api.astromesh.io/api/v1/orgs/$ORG/keys" \
    -H "Authorization: Bearer $TOKEN" \
    -H "Content-Type: application/json" \
    -d '{"name": "Production"}' \
    | jq -r '.secret')
    echo "API Key: $SECRET"
    # Store this securely — it will not be shown again

    Use the API key in production:

    Terminal window
    curl -X POST "https://api.astromesh.io/api/v1/orgs/$ORG/agents/my-first-agent/run" \
    -H "X-API-Key: $SECRET" \
    -H "Content-Type: application/json" \
    -d '{"query": "What can you do?", "session_id": "prod-001"}'

Connect your ADK agents to Astromesh Cloud for remote execution:

from astromesh_adk import agent, connect
@agent(name="my-first-agent", model="openai/gpt-4o-mini")
async def my_agent(ctx):
"""You are a helpful assistant."""
return None
# Route execution to your deployed Cloud agent
connect(
url="https://api.astromesh.io",
api_key="ask-your-key-here",
org="your-org-slug"
)
result = await my_agent.run("Hello from ADK!")
print(result.answer)

Or use the context manager for scoped remote execution:

from astromesh_adk import remote
async with remote("https://api.astromesh.io", api_key="ask-...", org="my-org"):
result = await my_agent.run("Remote query")
# Back to local execution after the context block
result = await my_agent.run("Local query")