Skip to main content
If you already have a knowledge base with at least one processed document, you can create and run an agent in about two minutes.
Creating an agent publishes version 1. You do not need a separate deploy call before the first run.

Dashboard: the two-minute path

1

0:00 — Open Agents

In the dashboard, open Agents and choose Create agent.
2

0:20 — Choose the knowledge base

Select the KB with your processed documents. This choice is fixed after creation, so use Copy if you later need the configuration on another KB.
3

0:40 — Define the job

Add a clear name, one-sentence goal, focused instructions, and a model. Leave tools, memory, and scheduling off for the first test.
4

1:10 — Create version 1

Save the agent. AutoSage validates the configuration and publishes its first version.
5

1:30 — Run it

Send one realistic request. Open the run to inspect its status, answer, sources, usage, and associated chat.

Starter configuration

FieldExample
NameSupport specialist
GoalAnswer customer questions from approved support documentation.
InstructionsCite supporting sources. If the KB does not contain the answer, say so and recommend escalation.
ModelChoose an available model
Knowledge baseYour processed support KB

API: create and run

export AUTOSAGE_URL="https://api.autosage.ai/api/v1"
export AUTOSAGE_KEY="sk_live_your_key_here"

1. Create version 1

AGENT_RESPONSE=$(curl --fail --silent --show-error \
  -X POST "$AUTOSAGE_URL/agents" \
  -H "Authorization: Bearer $AUTOSAGE_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "tenant_id": "TENANT_ID",
    "name": "Support specialist",
    "goal": "Answer customer questions from approved support documentation.",
    "instructions": "Cite supporting sources. If the KB does not contain the answer, recommend escalation.",
    "model_id": "MODEL_ID",
    "selected_knowledge_base_id": "KB_ID",
    "web_search_enabled": false,
    "use_memory_enabled": false
  }')

AGENT_ID=$(printf '%s' "$AGENT_RESPONSE" | jq -r '.agent.id')
printf 'Agent: %s\n' "$AGENT_ID"

2. Start a run

curl --fail --silent --show-error \
  -X POST "$AUTOSAGE_URL/agents/$AGENT_ID/messages" \
  -H "Authorization: Bearer $AUTOSAGE_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "message": "A customer bought an item 20 days ago. Can they return it?"
  }'
The response includes run_id, chat_id, the answer, sources, and usage. Save chat_id if you want to continue the same agent conversation.

3. Continue the run

curl -X POST "$AUTOSAGE_URL/agents/$AGENT_ID/messages" \
  -H "Authorization: Bearer $AUTOSAGE_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "message": "Turn that answer into a reply I can send.",
    "chat_id": "AGENT_CHAT_ID"
  }'

Add capabilities after the first run

Once the basic run works, deploy a new version to add web search, durable memory, connected apps, MCP servers, skills, custom tools, callable agents, or a schedule. Deploy accepts the complete agent configuration and publishes the next numbered version.

Continue the learning path

KB prompts vs. agents

Put shared behavior and job-specific behavior in the right place.

Chat vs. agent runs

Understand the run and associated chat you just created.

Configure capabilities

Add tools, skills, memory, delegates, and schedules.

Agents API

See every agent endpoint and field.