Skip to main content
POST
C#
This endpoint requires the gift-cards.write scope.

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Headers

idempotency-key
string | null

A unique key forwarded to the gift card service to make the issuance idempotent.

x-gr4vy-merchant-account-id
string | null

The ID of the merchant account to use for this request.

Example:

"default"

Body

application/json

The details used to issue a new virtual gift card.

theme
string
required

The provider theme code to issue the gift card against.

Required string length: 1 - 200
Example:

"031111372"

amount
integer
required

The amount to load onto the gift card, in the smallest denomination for the currency.

Required range: 0 <= x <= 99999999
Example:

5000

currency
string
required

The ISO-4217 currency code for the amount.

Pattern: ^[A-Z]{3}$
Examples:

"EUR"

"GBP"

"USD"

external_identifier
string | null

An optional external identifier for this issuance.

Required string length: 1 - 200
Example:

"order-12345"

Response

Successful Response

id
string<uuid>
required

The ID for the gift card issuance.

Example:

"356d56e5-fe16-42ae-97ee-8d55d846ae2e"

merchant_account_id
string
required

The ID of the merchant account this gift card issuance belongs to.

Example:

"default"

gift_card_service
GiftCardService · object
required

The service this gift card was issued against.

gift_card_service_payment_issuance_id
string
required

The identifier for this issuance as provided by the gift card service.

Example:

"12345"

url
string
required

The URL for the issued gift card.

Example:

"https://example.com/gift_card_issuance/ABCD1234"

amount
integer
required

The amount loaded onto the gift card, in the smallest denomination for the currency.

Required range: 0 <= x <= 99999999
Example:

5000

currency
string
required

The ISO-4217 currency code for the amount.

Pattern: ^[A-Z]{3}$
Examples:

"EUR"

"GBP"

"USD"

created_at
string<date-time>
required

The date and time when this gift card was issued.

Example:

"2013-07-16T19:23:00.000+00:00"

updated_at
string<date-time>
required

The date and time when this gift card issuance was last updated.

Example:

"2013-07-16T19:23:00.000+00:00"

type
string
default:gift-card-issuance

Always gift-card-issuance.

Allowed value: "gift-card-issuance"
Example:

"gift-card-issuance"

external_identifier
string | null

The external identifier provided when issuing the gift card.

Required string length: 1 - 200
Example:

"order-12345"