Skip to main content

Agents

Agents are configured AI agents that run in the background in a workspace. Use these endpoints to create, update, enable, disable, and delete agents, launch background agent runs, and track the status of those runs.

All agent operations run in a workspace context and require workspaceId.

Path and query parameters​

Name

Type

Location

Req/Opt

Description

workspaceId

integer

query

Optional

Workspace identifier.

search

string

query

Optional

Free-text search filter to match against agent name.

max

integer

query

Optional

Maximum number of results to return. Default: 20.

offset

integer

query

Optional

Number of results to skip for pagination. Default: 0.

agentRunId

string

path

Required

Agent run identifier.

agentId

string

path

Required

Agent identifier.

Request body parameters​

Name

Type

Req/Opt

Description

CreateAgent

Create agent

description

string

Optional

Agent description. Can be null.

name

string

Optional

Agent name. Maximum 255 characters.

agentInstructions

string

Optional

Instructions that define the agent's behavior. Maximum 50,000 characters.

agentInstructionsTemplateId

string

Optional

Identifier of the agent instructions template. Maximum 255 characters. Can be null.

githubAppCredentialId

string

Optional

GitHub App credentials identifier the agent uses for GitHub access. The credentials must belong to the same workspace. Can be null.

serviceAccountId

integer

Optional

Service account identifier the agent runs as. The service account must belong to the workspace organization. Can be null.

LaunchAgent

Launch agent

agentConfigId

string

Optional

Agent identifier of the configured agent to launch. The agent must be active. Omit to launch a run without a saved agent configuration. Can be null.

instructions

string

Optional

Instructions for the agent run. Maximum 50,000 characters.

triggerContext

object

Optional

Free-form context object for the run. Supplied fields are preserved, and workspace_id is always set to the workspace the run executes in. Can be null.

UpdateAgent

Update agent

description

string

Optional

Agent description. Can be null.

name

string

Optional

Agent name. Maximum 255 characters.

agentInstructions

string

Optional

Instructions that define the agent's behavior. Maximum 50,000 characters.

agentInstructionsTemplateId

string

Optional

Identifier of the agent instructions template. Maximum 255 characters. Can be null.

githubAppCredentialId

string

Optional

GitHub App credentials identifier the agent uses for GitHub access. The credentials must belong to the same workspace. Can be null.

serviceAccountId

integer

Optional

Service account identifier the agent runs as. The service account must belong to the workspace organization. Can be null.