Agents

Create an Agent once, then use its ID as model in the Responses API.

Create an Agent

curl -fsS https://api.rebyte.ai/v1/agents \
  -H "Authorization: Bearer $REBYTE_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: agent-research-v1" \
  -d '{
    "name": "Research assistant",
    "description": "Research with source-backed answers",
    "instructions": "Be concise and cite the evidence you use.",
    "model": "deepseek-v4-pro",
    "maxSteps": 32,
    "mcpServers": [
      {"kind": "internal", "name": "web_search_&_browse"},
      {"kind": "internal", "name": "skills"}
    ],
    "skills": [
      {"repo": "rebyteai/skills", "path": "research/deep-research"}
    ]
  }'

The response is { "agent": { ... } }. Save agent.id.

Fields

FieldRequiredInitial valueConstraint
nameYesTrimmed string, 1–100 characters.
descriptionNoNot setTrimmed string, up to 500 characters.
instructionsNoEmptyString, up to 100,000 characters.
modelNodeepseek-v4-proSupported model ID.
maxStepsNo32Integer from 1 through 128.
mcpServersNoSeven default internal toolsUp to 64 unique typed tool references.
skillsNoEmptyUp to 128 unique repository directories.

Supported model IDs:

deepseek-v4-pro
glm-5.2
kimi-k3
claude-sonnet-5
claude-opus-5
gpt-5.6
gpt-5.4-mini

Model access depends on organization credits and subscription policy.

See Tools and Skills for the exact mcpServers and skills schemas.

List and retrieve

curl -fsS https://api.rebyte.ai/v1/agents \
  -H "Authorization: Bearer $REBYTE_API_KEY"

curl -fsS https://api.rebyte.ai/v1/agents/$REBYTE_AGENT_ID \
  -H "Authorization: Bearer $REBYTE_API_KEY"

These endpoints return API-only Agents owned by the key's organization.

Update

curl -fsS -X PATCH \
  https://api.rebyte.ai/v1/agents/$REBYTE_AGENT_ID \
  -H "Authorization: Bearer $REBYTE_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"maxSteps": 48}'

The patch must contain at least one Agent field. An update affects only Conversations created afterward; existing Conversations keep their snapshot.

Use the CLI when the source of truth is agent.toml.

Delete

curl -fsS -X DELETE \
  https://api.rebyte.ai/v1/agents/$REBYTE_AGENT_ID \
  -H "Authorization: Bearer $REBYTE_API_KEY"

Deletion is rejected while any Conversation references the Agent. Delete those Conversations first.

Idempotent creation

Idempotency-Key is optional on Agent creation. Repeating the same key and request body returns the same Agent. Reusing the key with a different body returns 409 idempotency_key_conflict.