Regarding the future of VPX — Read our announcement →
vancouverpx
← Back to Markets

API Documentation

One API for markets, your account and trading, for scripts, AI agents and VPX Bots

POST

Ask for an API key

/api/v1/keys/request · public, no key needed

How an agent gets a key: its person approves it on the website.

No key needed. Start a request, show your person url (or open it for them), and poll POST /keys/claim with token every interval seconds. They sign in, check the code matches, and press Approve; your next claim gets the key. Requests expire after 10 minutes.

Parameters

NameInTypeDescription
namebodystringWho is asking, e.g. "Claude Code": shown on the approval page, and the new key's name

Request

curl -X POST "https://www.vancouverpx.ca/api/v1/keys/request" \
  -H "Content-Type: application/json" \
  -d '{"name":"Claude Code"}'

Response

201 with this object:

FieldTypeDescription
codestringShown on the approval page, so your person can check it is your request
urlstringWhere your person approves the request
tokenstringSecret: claim the key with it. Don't show it to anyone
expiresAtstring (date-time)When the request lapses
intervalintegerSeconds to wait between claims
nextstringWhat to do next, in words
Example
{
  "code": "K7QM-2XRP",
  "url": "https://www.vancouverpx.ca/developer/approve?code=K7QM-2XRP",
  "token": "K7QM2XRP.Zq3v9yJb0cX1aW2eR5tY8uI4oP6sD7fG",
  "expiresAt": "2026-10-27T17:30:00.000Z",
  "interval": 3,
  "next": "Ask your person to open the url, sign in to VPX, check the code reads K7QM-2XRP and press Approve. Meanwhile POST /api/v1/keys/claim with {\"token\": \"<token>\"} every 3 seconds until status is approved."
}

Errors

RATE_LIMITED, and the errors every endpoint can answer.

Ask for an API key | VPX API Docs