GiftCardTransactionResponse

Information about a gift card transaction from the gift card provider. The Toast platform uses this information to complete guests' gift card transactions.

The set of information in this object depends on the gift card transaction type. The transaction type is specified in the Toast-Transaction-Type header parameter for the request.

All GiftCardTransactionResponse objects must include a transactionStatus value.

The GiftCardTransactionResponse object includes the following additional values for specific transaction types:

  • GIFTCARD_ACTIVATE - includes an activateResponse value.
  • GIFTCARD_ADD_VALUE - includes an addValueResponse value.
  • GIFTCARD_GET_BALANCE - includes a getBalanceResponse value.
  • GIFTCARD_REDEEM - includes a redeemResponse value.
  • GIFTCARD_REVERSE - includes a reverseResponse value.

For example, the response object for a GIFTCARD_ACTIVATE transaction includes an activateResponse value.

object (TransactionResponseActivate)

Information about a gift card transaction from the gift card service provider for activating a new gift card. The Toast POS system uses this information to complete guests' gift card transactions.

object (TransactionResponseAddValue)

Information about a gift card transaction from the gift card service provider for add value transactions. The Toast platform uses this information to complete guests' gift card transactions.

object (TransactionResponseGetBalance)

Information about a gift card transaction from the gift card service provider for get balance transactions. The Toast POS system uses this information to complete guests' gift card transactions.

object (TransactionResponseRedeem)

Information about a gift card transaction from the gift card service provider that reduces the balance of funds available from the card. For example, when the gift card is used for a purchase. The Toast platform uses this information to complete guests' gift card transactions.

object (TransactionResponseReverse)

Information about a gift card transaction from the gift card service provider that undoes a previous gift card transaction. The Toast platform uses this information to complete guests' gift card transactions.

transactionStatus
string

Indicates the result of a gift card transaction, reported by the gift card service provider. Possible values are:

  • `ACCEPT` - The gift card service provider processed the transaction successfully.
  • `ERROR_INVALID_TOAST_TRANSACTION_TYPE` - The requested Toast-Transaction-Type is not valid.
  • `ERROR_CARD_ALREADY_ACTIVATED` - The gift card has already been activated.
  • `ERROR_CARD_NOT_ACTIVATED` - The gift card has not been activated.
  • `ERROR_CARD_INVALID` - The gift card is not valid at the current restaurant.
  • `ERROR_INVALID_INPUT_PROPERTIES` - The specified JSON properties in the request body are not valid.
  • `ERROR_TRANSACTION_DOES_NOT_EXIST` - The transaction that is being requested to be reversed does not exist. Only occurs on a `GIFTCARD_REVERSE`
  • `ERROR_INVALID_TOKEN` - The token supplied in the `Authorization` header field is invalid or cannot be validated.
  • `ERROR_TRANSACTION_CANNOT_BE_REVERSED` - The specified transaction cannot be reversed. `GIFTCARD_GET_BALANCE` and `GIFTCARD_REVERSE` transactions cannot be reversed.
  • `ERROR_INVALID_RESTAURANT` - The restaurant specified by the `Toast-Restaurant-External-ID` is invalid.
  • `ERROR_VERIFICATION_FAILED` - Verification data specified by the JSON body is invalid.
  • `ERROR_VERIFICATION_REQUIRED` - Verification data necessary to complete the transaction but the data is missing or `null` in the JSON body.
  • `ERROR_VERIFICATION_NOT_SUPPORTED` - Verification data is provided by the JSON body but the provider doesn't support verification.
Enum: "ACCEPT" "ERROR_INVALID_TOAST_TRANSACTION_TYPE" "ERROR_CARD_ALREADY_ACTIVATED" "ERROR_CARD_NOT_ACTIVATED" "ERROR_CARD_INVALID" "ERROR_INVALID_INPUT_PROPERTIES" "ERROR_TRANSACTION_DOES_NOT_EXIST" "ERROR_INVALID_TOKEN" "ERROR_TRANSACTION_CANNOT_BE_REVERSED" "ERROR_INVALID_RESTAURANT" "ERROR_VERIFICATION_FAILED" "ERROR_VERIFICATION_REQUIRED" "ERROR_VERIFICATION_NOT_SUPPORTED"
{
  • "transactionStatus": "ACCEPT",
  • "activateResponse": {
    },
  • "addValueResponse": {
    },
  • "getBalanceResponse": {
    },
  • "redeemResponse": {
    },
  • "reverseResponse": {
    }
}