Public A P I

Update Agent

PATCH
/v2/agents/{agent_id}

Update an agent with a JSON Patch document — an array of {op, path, value} operations applied to the agent, e.g. [{"op": "replace", "path": "/display_name", "value": "My agent"}]. Returns the updated agent.

Authorization

BearerAuth
AuthorizationBearer <token>

In: header

Path Parameters

agent_id*Agent Id

Web Search Agent ID, format wsa_<uuid>.

Formatuuid

Request Body

A JSON Patch document per RFC 6902 — a JSON array of patch operations.

[index: integer]?

A single JSON Patch operation per RFC 6902.

Response Body

application/json

application/json

application/json

curl -X PATCH "https://example.com/v2/agents/497f6eca-6276-4993-bfeb-53cbbbba6f08" \  -H "Content-Type: application/json" \  -d '[    {      "op": "add",      "path": "string"    }  ]'
{  "agent_name": "string",  "created_at": "2019-08-24T14:15:22Z",  "description": "string",  "display_name": "string",  "effort": "low",  "goals": [    {      "goal": "string",      "id": "string",      "order": 0    }  ],  "icon": "string",  "id": "string",  "is_active": true,  "output_schema": {},  "skill": "string",  "sources": {    "allow": [      {        "domains": [          "string"        ],        "id": "string",        "order": 0,        "title": "string"      }    ],    "avoid": "string",    "block": [      {        "domains": [          "string"        ],        "id": "string",        "order": 0,        "title": "string"      }    ],    "prioritize": "string"  },  "suggested_questions": [    {      "id": "string",      "order": 0,      "question": "string"    }  ],  "updated_at": "2019-08-24T14:15:22Z",  "use_case": "research"}