For the complete documentation index, see llms.txt. This page is also available as Markdown.

PATCH /agents/{address}

Rename an agent

Rename an agent.

operationId: renameAgent

Declared server: https://api.testnet.nexus.xyz/v1. See Networks.

Not reachable through CCXT. Nexus-specific trading-agent registration. No CCXT equivalent — the closest unified concepts are API-key management, which CCXT deliberately leaves to the venue.

Authentication: hmacAuth, walletSignature.

Rename an agent

patch
/agents/{address}

Change the label of one of your agent keys. Only the label changes: the key's address, expiry and scope stay as they are, and the key keeps signing without being re-registered.

The label is trimmed and runs of whitespace are collapsed to one space before it is stored. It must be 1 to 32 characters after that, with no control characters (newlines, tabs). The response carries the stored record, so read the label back from it rather than from what you sent.

A key that is not registered to the calling wallet, has expired or does not exist returns 404 (code AGENT_NOT_FOUND). The three cases are not told apart, so this cannot be used to probe for keys on other accounts.

Agent keys are refused here with 403 (code AGENT_KEY_FORBIDDEN): a trade-only agent key may not list, rename or revoke its sibling credentials. Call this as the wallet itself: its own API key (hmacAuth), or a signature from the wallet over this action (walletSignature), which is how a client holding only an agent key does it.

Authorizations
X-API-KeystringRequired

HMAC API key authentication. Send three headers:

  • X-API-Key: your key ID (e.g. nx_a1b2c3...)
  • X-Timestamp: current time in unix milliseconds
  • X-Signature: hex(hmac_sha256(secret, timestamp + "\n" + METHOD + "\n" + path + "\n" + query + "\n" + sha256_hex(body)))

Timestamp must be within 30 seconds of server time.

The key is network-scoped; the signature is not. The canonical string above has no network component, so the same signed request is byte-identical on every host. What stops a testnet key from authenticating against mainnet is that the key does not exist in that host's key store — sign only for the host that minted the key, and never replay a signed payload against another network. Presented to the wrong host, a key is refused with the same opaque 401 as an unknown key and must not be retried there. See “API keys are bound to one network” in the API description.

Path parameters
addressstringRequired

Agent address to rename (0x-prefixed)

Body

Body of PATCH /agents/{address}. label is the only field a rename can change; any other field is refused.

labelstring · min: 1 · max: 32Required

New label. Trimmed and whitespace-collapsed before storing; 1 to 32 characters after that, no control characters.

Responses
200

Agent renamed. The body is the updated record, in the GET /agents shape.

application/json

A registered agent key as GET /agents reports it.

This schema is camelCase, unlike the snake_case native Nexus schemas around it: expiresAt and registeredAt, not expires_at and registered_at. It is not one of the CCXT-compatible schemas either, so it matches neither naming family the Schema Reference's conventions describe. Read the field names here literally rather than inferring them from the rest of the API.

addressstringOptional

Agent address (0x-prefixed)

expiresAtinteger · int64Optional

Expiry Unix ms

registeredAtinteger · int64Optional

Registration time Unix ms

labelstring · nullableOptional

Optional label

patch/agents/{address}
PATCH /v1/agents/{address} HTTP/1.1
Host: api.testnet.nexus.xyz
X-API-Key: YOUR_API_KEY
Content-Type: application/json
Accept: */*
Content-Length: 20

{
  "label": "Desk bot"
}
{
  "address": "0x1234567890AbCdEf1234567890AbCdEf12345678",
  "expiresAt": 1782000000000,
  "registeredAt": 1779000000000,
  "label": "Desk bot"
}

Test it cannot sign this request. X-Signature is an HMAC computed per call: see Authentication, or use an SDK.


API version 0.9.131

Last updated