/ vars/ v1/ agentsRelated guide: Register an agent.
Authentication: the method you chose, X-Pay-Token or two-way TLS; see X-Pay-Token / mTLS. X-Pay uses the signed apiKey query.
Request body
Required JSON body, with the fields below.
contactEmailstring · emailrequiredRoutable contact, unique on your TRID: a duplicate answers
409, which Basis Theory reports asAGENT_CONTACT_EMAIL_CONFLICT, and a plus-address counts as a different email. Visa CLI sends a stable plus-address alias of the verified contact.tokenRequestorIdstringrequiredToken requestor identifier. Visa CLI sends a label of its own for each agent, not the agent's ID; get the correct identifier for your VDP integration.
keysarray ofKeyCreateOptional initial public signing keys.
Responses
| HTTP | Meaning | Schema |
|---|---|---|
201 | Agent created. Agents are active on creation, so there's no agent activation step. | AgentResponse |
409 | A conflict, such as a duplicate domain. One TRID covers many agents, so a shared tokenRequestorId isn't a duplicate. A contactEmail already used on your TRID is a conflict too. A plus-address counts as a different email. | ErrorResponse |
422 | Invalid / extra input fields. | ValidationError |
The token covers this URL's exact query and the exact request body, so each request needs a new one. Replace the YOUR_ values with your own.
curl --request POST \
'https://sandbox.api.visa.com/vars/v1/agents?apiKey=YOUR_API_KEY' \
--header 'Accept: application/json' \
--header 'x-pay-token: TOKEN_FOR_THIS_EXACT_REQUEST' \
--header 'Content-Type: application/json' \
--data-binary @agent-create.json{
"name": "Example Commerce Agent",
"domain": "https://agent.example.com",
"description": "An agent that browses and purchases for its users.",
"contactEmail": "agent-team+tap-example@example.com",
"tokenRequestorId": "YOUR_TOKEN_REQUESTOR_ID",
"keys": [
{
"keyName": "YOUR_PUBLIC_JWK_THUMBPRINT",
"algorithm": "ed25519",
"publicKey": "BASE64_ENCODED_SPKI_PEM_PUBLIC_KEY",
"expirationDate": "2027-11-05T00:00:00Z"
}
]
}{
"id": "7f4c82a1-305e-4f9c-8d2a-1b3e5f7c502a",
"name": "Example Commerce Agent",
"domain": "https://agent.example.com",
"isActive": true,
"tokenRequestorId": "YOUR_TOKEN_REQUESTOR_ID",
"createdAt": "2026-11-05T00:00:00Z",
"updatedAt": "2026-11-05T00:00:00Z",
"keys": []
}