JANZAY
0
DEVELOPER DOCUMENTATION

Reseller API.

Base URL: https://www.janzay.com/api/reseller

Manage your access and keys →

Before your first request

  1. Sign in and create your reseller profile. No manual approval is required.
  2. Complete a deposit of at least $20 through the account dashboard. Access unlocks automatically when payment is confirmed and your wallet is credited.
  3. Create a key. Send it as Authorization: Bearer YOUR_API_KEY. Never embed it in browser code.
  4. Read the current terms and refund policy. The policy version returned by GET requests must match your order request.

There is no sandbox or test key. GET requests are read-only; POST /orders and /pay are live and can debit your wallet and place a real order. Start testing with GET /balance and GET /products. All prices and amounts use integer USD cents. Product prices already include your reseller discount, with minimum product prices applying. Stock is a recent snapshot, not a reservation. We verify it again before debiting your wallet.

Read products

GET /products
curl 'https://www.janzay.com/api/reseller/products' \
  -H 'Authorization: Bearer YOUR_API_KEY'

Read your balance

GET /balance
curl 'https://www.janzay.com/api/reseller/balance' \
  -H 'Authorization: Bearer YOUR_API_KEY'

Create an order

POST /orders
curl 'https://www.janzay.com/api/reseller/orders' \
  -H 'Authorization: Bearer YOUR_API_KEY' \
  -X POST -H 'Content-Type: application/json' \
  -H 'Idempotency-Key: UNIQUE_ORDER_REFERENCE_123' \
  --data '{
  "items": [
    {
      "id": "PRODUCT_ID",
      "quantity": 1
    }
  ],
  "accepted_terms": true,
  "policy_version": "2026-09-09.1"
}'

Read an order and delivery

GET /orders/ORDER_ID
curl 'https://www.janzay.com/api/reseller/orders/ORDER_ID' \
  -H 'Authorization: Bearer YOUR_API_KEY'

List orders

GET /orders?before=2026-09-08T00:00:00Z
curl 'https://www.janzay.com/api/reseller/orders?before=2026-09-08T00:00:00Z' \
  -H 'Authorization: Bearer YOUR_API_KEY'

Pay a held order after funding

POST /orders/ORDER_ID/pay
curl 'https://www.janzay.com/api/reseller/orders/ORDER_ID/pay' \
  -H 'Authorization: Bearer YOUR_API_KEY' \
  -X POST -H 'Content-Type: application/json' \
  --data '{}'

Responses and delivery

Successful responses use {"ok":true,"data":...}. GET responses also include policy_version. Product fields: id, name, price_cents, currency, stock, stock_checked_at. Balance fields: balance_cents, currency, frozen, minimum_deposit_cents.

Order creation returns id, status and total_cents. Save the id. GET an individual order to read order_items, each with name, quantity, status and delivery. Delivery remains null until that item is delivered. Treat returned credentials as confidential and store them encrypted.

Order states: awaiting_payment, paid, processing, delivered, attention, refunded, cancelled. A 202 response means the order is held awaiting funds. Add funds, then POST to its /pay endpoint. We recheck stock and price before any debit. A changed price can require a new quote; contact support rather than submitting duplicates.

List orders returns up to 50 records. For the next page, pass both before and before_id from next_cursor. A null next_cursor means there are no more records. Using both values prevents missing orders created at the same time. Poll an individual order every 15–30 seconds. There are no reseller outbound webhooks in this version.

Idempotency, limits and errors

For order creation, use a unique 16–100 character Idempotency-Key. Reusing it with identical items returns the original order; different items produce 409. After a timeout, retry with the same key. Paying a held order is also idempotent, accepts an empty body, and returns paid: true if payment was already recorded.

Up to 60 API requests per minute per reseller. Maximum 100 different items per order. Actual quantity is constrained by live stock and wallet funds. Duplicate product IDs are rejected. There is also an order creation limit of 5 per minute.

  • 400: invalid fields or policy version.
  • 401: missing, invalid or revoked key.
  • 403: reseller profile restricted or missing, wallet frozen, or qualifying deposit missing.
  • 404: resource does not exist or is not yours.
  • 409: stock, price, wallet or idempotency conflict.
  • 429: wait one minute before retrying.
  • 503: maintenance or temporary service failure. Retry with the original idempotency key.

Keep order IDs for support. Never retry by inventing new keys after an uncertain response. API refunds are handled by our support team; submit a ticket linked to the order.