LangChain Reference home pageLangChain ReferenceLangChain Reference
  • GitHub
  • Main Docs
Deep Agents
LangChain
LangGraph
Integrations
LangSmith
  • Overview
  • Client
  • AsyncClient
  • Run Helpers
  • Run Trees
  • Evaluation
  • Schemas
  • Utilities
  • Wrappers
  • Anonymizer
  • Testing
  • Expect API
  • Middleware
  • Pytest Plugin
  • Deployment SDK
⌘I

Chat LangChain

What can I help with?

Enter to send·Shift+Enter new line

Menu

OverviewClientAsyncClientRun HelpersRun TreesEvaluationSchemasUtilitiesWrappersAnonymizerTestingExpect APIMiddlewarePytest PluginDeployment SDK
Language
Theme
PythonlangsmithresourcesagentsAgentsResourceupdate
Method●Since v0.14

update

Copy
update(
  self,
  agent_id: str,
  *,
  agent_type: Literal['CUSTOM', 'CODING'] 
View source on GitHub
|
Omit
=
omit
,
name
:
str
|
Omit
=
omit
,
owner_id
:
Optional
[
str
]
|
Omit
=
omit
,
source_type
:
Literal
[
'LSD'
,
'MDA'
,
'EXTERNAL'
,
'FLEET'
]
|
Omit
=
omit
,
extra_headers
:
Headers
|
None
=
None
,
extra_query
:
Query
|
None
=
None
,
extra_body
:
Body
|
None
=
None
,
timeout
:
float
|
httpx
.
Timeout
|
None
|
NotGiven
=
not_given
)
->
Agent

Parameters

NameTypeDescription
agent_typeLiteral['CUSTOM', 'CODING'] | Omit
Default:omit

New classification. Omit to keep the current classification.

namestr | Omit
Default:omit

New display name. Omit to keep the current name.

owner_idOptional[str] | Omit
Default:omit
source_typeLiteral['LSD', 'MDA', 'EXTERNAL', 'FLEET'] | Omit
Default:omit
extra_headersHeaders | None
Default:None
extra_queryQuery | None
Default:None
extra_bodyBody | None
Default:None
timeoutfloat | httpx.Timeout | None | NotGiven
Default:not_given

Updates an Agent's name, source_type, agent_type, or owner_id.

Omitted fields keep their values. Changing or clearing owner_id additionally requires workspaces:manage; assigning an owner also requires workspaces:read and active workspace membership. Owner changes update the Agent registry only; Fleet runtime ownership, access, and connected accounts are unchanged. Changing agent_type requires workspaces:manage in addition to project update access; repeating the current type is a no-op. Source type can change only for an EXTERNAL Agent without runtime bindings. The id is immutable and is rejected when present. Requires update permission on every environment project.

Omit to leave the owner unchanged; null clears it.

New runtime kind. Only EXTERNAL agents without runtime bindings can change kind.

Send extra headers

Add additional query parameters to the request

Add additional JSON properties to the request

Override the client-level default timeout for this request, in seconds