API Referencev1.0
HomeLog inSign up
GIFT CARDS

Purchase a gift card

POSThttps://production.dutchapi.co/v1/gift-cards/purchase

Purchases a gift card from the organization USD wallet after rechecking the provider price. Delivery details are encrypted at rest and can be retrieved through the order endpoint.

🔒Send the project API key as a Bearer token and your Business ID with this call.

Send an Idempotency-Key header and reuse it only when retrying the same purchase.

First call the price endpoint and pass its totalUsd as quotedTotalUsd; if the current price changed, the purchase is rejected without charging.

Body Params

productIdintegerrequired

Gift card product ID.

countryCodestringrequired

Two-letter ISO country code.

unitPricenumberrequired

Recipient-facing unit denomination.

quantityintegeroptional

Quantity from 1 to 5 (default 1).

quotedTotalUsdnumberrequired

Current USD total returned by the price endpoint.

recipientEmailstringrequired

Email address for gift card delivery.

recipientPhonestringoptional

Recipient phone number in international format.

Responses

{
  "data": {
    "transactionId": "gft_8f2c1a",
    "status": "completed"
  }
}
{
  "error": "insufficient_scope",
  "message": "This project key is not allowed to do that."
}

Errors

StatuserrorMeaning
403insufficient_scopeThis project key is not allowed to do that.
400idempotency_key_requiredSend an Idempotency-Key header.
402insufficient_fundsThe wallet balance is too low.
400gift_card_order_details_requiredProvide a valid recipient email and current quote.
409gift_card_price_changedThe price changed; request a new quote.
422gift_card_order_rejectedThe provider rejected the order and the USD wallet was refunded.
503gift_cards_live_mode_requiredGift card purchases are currently unavailable.
Updated 2026
Did this page help you?