Skip to main content
PUT
Python

Authorizations

X-Auth-Token
string
header
required

Project API key for sending traces and accessing project-scoped resources. Format: sk-lw-... (no underscore). Obtain one by creating a project via the Admin API or the LangWatch UI.

Path Parameters

id
string
required

The agent id.

Minimum string length: 1

Body

application/json
name
string
Required string length: 1 - 255
type
enum<string>

The kind of agent to write. A connected agent is registered from code by the SDK, so "connected" is refused with agent_register_only.

Available options:
signature,
code,
workflow,
http,
connected
config
object
workflowId
string | null

Response

200 - application/json

Success

id
string
required
name
string
required
type
enum<string>
required

The kind of agent. A connected agent is registered from code by the SDK and cannot be created or reconfigured through this API.

Available options:
signature,
code,
workflow,
http,
connected
config
object | null
required
environment
string | null
required

The environment a connected agent registered with, for example production or development. Null for every other kind.

ownerUserId
string | null
required

The user a personal development agent belongs to. Only that user can run simulations against it. Null when the agent is shared.

hostLabel
string | null
required

The machine a development agent registered from with a project or service key. Null when the agent is personal or shared.

lastSeenAt
string | null
required

When an instance of a connected agent was last connected. Null for every other kind.

parameters
object[]
required

The run parameters a connected agent declares from its function signature: name, type, options, default and description. Empty for every other kind.

owner
object | null
required

The person a personal development agent belongs to. Null when the agent is shared or host-scoped.

status
enum<string>
required

online while at least one process running the connected agent is connected; offline otherwise, and always for every other kind.

Available options:
online,
offline
instances
object[]
required

The processes currently connected for a connected agent: hostname, user, pid, SDK and how many calls each has in flight. Empty for every other kind.

createdAt
string
required
updatedAt
string
required
platformUrl
string<uri>
required
Last modified on August 31, 2026