Skip to main content
Managed AgentsVersion: v3New

Get a Managed Agent build

GET/agent-studio/managed-agents/builds/{buildId}

Returns the state of a build: still running, waiting for answers or a reply, or finished. nextAction says what to do next. Builds are kept for 24 hours; the agent and its build history stay after that.

Authorizations

Authorizationstringheaderrequired

Bearer authentication header of the form Bearer <token>, where <token> is your access token.

Scope:managed-agents.buildAndPublish
Auth methods:OAuthPrivate Integration
Token type:Sub-Account Token

Request​

Headers

Versionstringrequired

API version.

Available optionsv3
Example:v3

Path Parameters

buildIdstringrequired

Build ID

Example:b7a1f0e2-4c3d-4e5f-8a9b-0c1d2e3f4a5b

Query Parameters

locationIdstringrequired

Location (sub-account) the build belongs to

Example:ve9EPM428h8vShlRW1KT

Response

Build state

buildIdstringrequired

Build id to poll and to continue the build with

Example:b7a1f0e2-4c3d-4e5f-8a9b-0c1d2e3f4a5b
statusstringrequired

RUNNING: still building. NEEDS_INPUT: answer questions. NEEDS_REPLY: the builder asked something in message; send the reply as a new message on this build. ANSWERS_STALE: the questions changed, so send the request again. COMPLETED: done (changed tells whether the agent was saved). FAILED: see error.

Available optionsRUNNINGNEEDS_INPUTNEEDS_REPLYANSWERS_STALECOMPLETEDFAILED
Example:RUNNING
nextActionstringrequired

What to do next. POLL: call get build again after pollAfterMs. ASK_USER: show the user the questions or message and send their answer. REVIEW: the draft was saved; review it, then publish when ready. USE_RESULT: use message as the answer; nothing changed. RETRY: nothing was applied (see error or staleReason); send the request again with a new Idempotency-Key.

Available optionsPOLLASK_USERREVIEWUSE_RESULTRETRY
Example:POLL
pollAfterMsnumber

Milliseconds to wait before polling again (RUNNING only)

Example:5000
managedAgentIdstring

The agent this build creates or edits, once known

Example:027ee957-ae94-40ad-89a3-b25c985f729b
changedboolean

COMPLETED only: true when the agent draft was saved, false when the builder only answered

Example:true
messagestring

The builder's message: its summary, its answer, or the question it needs answered

Example:I built a lead qualifier that books qualified leads into your Sales calendar.
questionsobject[]

NEEDS_INPUT only: the questions to answer

staleReasonstring

ANSWERS_STALE only: why the answers no longer apply

Available optionsno_pending_roundexpiredconfig_changedwrong_targetround_mismatch
Example:expired
errorobject

FAILED only: why the build failed

hasPublishedVersionboolean

Whether the agent has a published version

Example:false
hasUnpublishedChangesboolean

Whether the saved draft differs from the published version

Example:true
createdAtstringrequired

When the build started

Example:2026-10-29T12:00:00.000Z
updatedAtstringrequired

When the build last changed state

Example:2026-10-29T12:01:30.000Z