Skip to main content
PATCH
/
v1
/
agents
/
{agentId}
Update agent
curl --request PATCH \
  --url https://api.useproxy.ai/v1/agents/{agentId} \
  --header 'Api-Key: <api-key>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "name": "<string>",
  "description": "<string>",
  "status": "active",
  "spendingLimit": 123,
  "spendingLimitFrequency": "perTransaction",
  "onLimitExceeded": "suspend",
  "metadata": {}
}
'
{
  "id": "<string>",
  "userId": "<string>",
  "name": "<string>",
  "status": "active",
  "createdAt": 123,
  "externalId": "<string>",
  "description": "<string>",
  "deregisteredAt": 123,
  "spendingLimit": 123,
  "spendingLimitFrequency": "perTransaction",
  "currentSpend": 123,
  "onLimitExceeded": "suspend",
  "maxCards": 123,
  "cardCount": 123,
  "metadata": {},
  "defaultRequireApproval": true,
  "defaultAutoApproveBelow": 123
}

Authorizations

Api-Key
string
header
required

API key for authentication. Get your key from the Dashboard.

Path Parameters

agentId
string
required

The agent ID

Body

application/json
name
string
description
string
status
enum<string>
Available options:
active,
suspended
spendingLimit
integer
spendingLimitFrequency
enum<string>
Available options:
perTransaction,
per24HourPeriod,
perWeek,
perMonth,
perYear,
allTime
onLimitExceeded
enum<string>
Available options:
suspend,
notify,
none
metadata
object

Response

Agent updated

id
string
required
userId
string
required
name
string
required
status
enum<string>
required
Available options:
active,
suspended,
deregistered
createdAt
integer
required
externalId
string

Developer's identifier for the agent (unique per organization)

description
string
deregisteredAt
integer

Timestamp when agent was deregistered

spendingLimit
integer
spendingLimitFrequency
enum<string>
Available options:
perTransaction,
per24HourPeriod,
perWeek,
perMonth,
perYear,
allTime
currentSpend
integer

Current spend in the period

onLimitExceeded
enum<string>
Available options:
suspend,
notify,
none
maxCards
integer
cardCount
integer
metadata
object
defaultRequireApproval
boolean

Default: require human approval for intents on cards created by this agent

defaultAutoApproveBelow
integer

Default: auto-approve intents below this amount (cents)