Gyvar docs

Create or fetch an address

Returns the address for your `reference` on a chain, creating it if needed: 201 when created, 200 when it already existed. Needs the `receive` capability.

POST
/addresses

Authorization

KeyID Timestamp Nonce Signature
X-Gyvar-Key<token>

Your key id, gyv_k_live_... or gyv_k_sandbox_....

In: header

X-Gyvar-Timestamp<token>

Unix seconds. Must be within 5 minutes of our clock.

In: header

X-Gyvar-Nonce<token>

A unique value per request. Replays are rejected.

In: header

X-Gyvar-Signature<token>

Ed25519 signature over the canonical string. See the Signing guide.

In: header

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

chain*Chain

A chain that can hold a receive address. Lightning uses invoices instead.

Value in

  • "bitcoin"
  • "tron"
  • "ethereum"
  • "polygon"
  • "solana"
  • "base"
  • "bsc"
reference*string

Your id for what this address is for - a customer, an invoice. The same reference always returns the same address.

Lengthlength <= 120
label?string

A note for display.

Lengthlength <= 120

Response Body

application/json

application/json

application/json

application/json

application/json

application/json

application/json

curl -X POST "https://example.com/addresses" \  -H "Content-Type: application/json" \  -d '{    "chain": "base",    "reference": "customer_8842",    "label": "Ama Owusu"  }'
{  "data": {    "id": "0d6c2f3a-1b4e-4c9a-9f2d-7a1e5c8b3d60",    "chain": "bitcoin",    "address": "0x2f1a9C4b7E3d5A8f6B0c1D4e7A9b2C5d8E3f6A1b",    "assets": [      "USDT",      "USDC"    ],    "label": "Ama Owusu",    "reference": "customer_8842",    "created_at": "2019-08-24T14:15:22Z"  }}