Skip to content
  • Auto
  • Light
  • Dark

Update

Update Agent Route for an Agent
agents.routes.update(strpath_child_agent_uuid, RouteUpdateParams**kwargs) -> child_agent_uuidstrparent_agent_uuidstrrollbackbooluuidstrRouteUpdateResponse
put/v2/gen-ai/agents/{parent_agent_uuid}/child_agents/{child_agent_uuid}

To update an agent route for an agent, send a PUT request to /v2/gen-ai/agents/{parent_agent_uuid}/child_agents/{child_agent_uuid}.

Parameters
parent_agent_uuidstr
child_agent_uuidstr
child_agent_uuidstr
if_casestr
optional

Describes the case in which the child agent should be used

parent_agent_uuidstr
route_namestr
optional

Route name

uuidstr
optional

Unique id of linkage

Returns
RouteUpdateResponseclass

Information about an updated linkage

Hide ParametersShow Parameters
child_agent_uuidstr
optional

Routed agent id

parent_agent_uuidstr
optional

A unique identifier for the parent agent.

rollbackbool
optional
uuidstr
optional

Unique id of linkage

from do_gradientai import GradientAI

client = GradientAI()
route = client.agents.routes.update(
    path_child_agent_uuid="\"123e4567-e89b-12d3-a456-426614174000\"",
    path_parent_agent_uuid="\"123e4567-e89b-12d3-a456-426614174000\"",
)
print(route.child_agent_uuid)
200 Example
{
  "child_agent_uuid": "\"123e4567-e89b-12d3-a456-426614174000\"",
  "parent_agent_uuid": "\"123e4567-e89b-12d3-a456-426614174000\"",
  "rollback": true,
  "uuid": "\"123e4567-e89b-12d3-a456-426614174000\""
}