Nostraddeveloper documentationDocumentationDeveloper console

Your server

Your server: check, acknowledge, consume

curl https://gateway.nostrad.ai/v1/purchases/$PURCHASE_TOKEN -H "Authorization: Bearer $SALES_KEY"
{ "purchase_token": "pt_...", "order_id": "NOS.1234-5678-9012-34567", "product": "coins_100", "type": "consumable",
  "quantity": 2, "refundable_quantity": 2, "state": "purchased", "acknowledgement": "pending", "consumption": "not_consumed",
  "account_token": "user-42", "purchased_at": 1793000000000, "price": { "credits": 398, "usd": "$3.98" },
  "refunded": 0, "test": false, "acknowledge_by": 1793259200000 }
FieldMeaning
statepurchased, or cancelled once it was refunded and taken back: take away what you gave
acknowledgementpending until you acknowledge or consume it; acknowledged after
consumptionConsumables only: not_consumed or consumed
acknowledge_byWhen it is refunded unless acknowledged (milliseconds); null once acknowledged
refunded, refundable_quantityCredits refunded so far, and how many of the quantity can still be refunded
testA test purchase: no credit moved

Orders

The order ID (NOS.1234-5678-9012-34567) is what the buyer sees on the receipt Nostrad emails them and under Purchases on their account; ask for it when they write to you.

Security