Provides information about a gift card transaction processed by the Toast platform. The transaction information in the message body is intended to allow a gift card provider to perform corresponding operations on the gift card account, maintained by that provider.
You define the endpoint name for this implementation. The Toast platform makes requests to the REST path that you supply during integration setup.
Each POST request to the endpoint includes a
Toast-Transaction-Type header parameter value to indicate the
type of gift card transaction it represents. The possible
transaction types are:
The GiftCardTransaction
object in the message body includes a set of information that
is specific for each transaction type.
The response time for a gift card transaction request must be less than 500ms.
All gift card transactions must be considered idempotent. The
implementation must handle multiple requests with the same
Toast-Transaction-GUID and the same giftCardIdentifier.
A GiftCardTransaction
object containing information about the gift card
transaction that the Toast platform processed.
object (TransactionInformationActivate) Information about a gift card transaction in the Toast | |
object (TransactionInformationAddValue) Information about a gift card transaction in the Toast POS system that adds to the funds that are available on the card. Gift card providers are expected to handle the transaction. | |
object (TransactionInformationGetBalance) Information about a gift card transaction in the Toast | |
object (TransactionInformationRedeem) Information about a gift card transaction in the Toast | |
object (TransactionInformationReverse) Information about a gift card transaction in the Toast |
OK. The transactionStatus value of the
GiftCardTransactionResponse object is ACCEPT.
Bad request. The transactionStatus value of the
GiftCardTransactionResponse object is one of:
ERROR_INVALID_TOAST_TRANSACTION_TYPEERROR_CARD_ALREADY_ACTIVATEDERROR_CARD_NOT_ACTIVATEDERROR_CARD_INVALIDERROR_INVALID_INPUT_PROPERTIESERROR_TRANSACTION_DOES_NOT_EXISTERROR_INVALID_TOKENERROR_TRANSACTION_CANNOT_BE_REVERSEDERROR_INVALID_RESTAURANTERROR_VERIFICATION_FAILEDERROR_VERIFICATION_REQUIREDERROR_VERIFICATION_NOT_SUPPORTEDInternal server error.
{- "activateTransactionInformation": {
- "giftCardIdentifier": "string",
- "identifierSource": "KEYED",
- "verificationCode": {
- "value": "string",
- "source": "KEYED"
}, - "initialBalance": 0,
- "checkIdentifier": "string"
}, - "addValueTransactionInformation": {
- "giftCardIdentifier": "string",
- "identifierSource": "KEYED",
- "verificationCode": {
- "value": "string",
- "source": "KEYED"
}, - "additionalValue": 0,
- "checkIdentifier": "string"
}, - "getBalanceTransactionInformation": {
- "giftCardIdentifier": "string",
- "identifierSource": "KEYED",
- "verificationCode": {
- "value": "string",
- "source": "KEYED"
}
}, - "redeemTransactionInformation": {
- "giftCardIdentifier": "string",
- "identifierSource": "KEYED",
- "verificationCode": {
- "value": "string",
- "source": "KEYED"
}, - "redeemedValue": 0,
- "checkIdentifier": "string",
- "isCashOut": true,
- "relatedTransaction": "string"
}, - "reverseTransactionInformation": {
- "previousTransaction": "string",
- "giftCardIdentifier": "string",
- "identifierSource": "KEYED",
- "verificationCode": {
- "value": "string",
- "source": "KEYED"
}
}
}{- "transactionStatus": "ACCEPT",
- "activateResponse": {
- "currentBalance": 0
}, - "addValueResponse": {
- "currentBalance": 0
}, - "getBalanceResponse": {
- "currentBalance": 0
}, - "redeemResponse": {
- "currentBalance": 0,
- "redeemedValue": 0
}, - "reverseResponse": {
- "currentBalance": 0
}
}