Skip to content

Latest commit

 

History

History
55 lines (46 loc) · 5.91 KB

gift-card-activity.md

File metadata and controls

55 lines (46 loc) · 5.91 KB

Gift Card Activity

Represents an action performed on a gift card that affects its state or balance. A gift card activity contains information about a specific activity type. For example, a REDEEM activity includes a redeem_activity_details field that contains information about the redemption.

Structure

Gift Card Activity

Fields

Name Type Tags Description
id str Optional The Square-assigned ID of the gift card activity.
type str (Gift Card Activity Type) Required Indicates the type of gift card activity.
location_id str Required The ID of the business location where the activity occurred.
created_at str Optional The timestamp when the gift card activity was created, in RFC 3339 format.
gift_card_id str Optional The gift card ID. When creating a gift card activity, gift_card_id is not required if
gift_card_gan is specified.
gift_card_gan str Optional The gift card account number (GAN). When creating a gift card activity, gift_card_gan
is not required if gift_card_id is specified.
gift_card_balance_money Money Optional Represents an amount of money. Money fields can be signed or unsigned.
Fields that do not explicitly define whether they are signed or unsigned are
considered unsigned and can only hold positive amounts. For signed fields, the
sign of the value indicates the purpose of the money transfer. See
Working with Monetary Amounts
for more information.
load_activity_details Gift Card Activity Load Optional Represents details about a LOAD gift card activity type.
activate_activity_details Gift Card Activity Activate Optional Represents details about an ACTIVATE gift card activity type.
redeem_activity_details Gift Card Activity Redeem Optional Represents details about a REDEEM gift card activity type.
clear_balance_activity_details Gift Card Activity Clear Balance Optional Represents details about a CLEAR_BALANCE gift card activity type.
deactivate_activity_details Gift Card Activity Deactivate Optional Represents details about a DEACTIVATE gift card activity type.
adjust_increment_activity_details Gift Card Activity Adjust Increment Optional Represents details about an ADJUST_INCREMENT gift card activity type.
adjust_decrement_activity_details Gift Card Activity Adjust Decrement Optional Represents details about an ADJUST_DECREMENT gift card activity type.
refund_activity_details Gift Card Activity Refund Optional Represents details about a REFUND gift card activity type.
unlinked_activity_refund_activity_details Gift Card Activity Unlinked Activity Refund Optional Represents details about an UNLINKED_ACTIVITY_REFUND gift card activity type.
import_activity_details Gift Card Activity Import Optional Represents details about an IMPORT gift card activity type.
This activity type is used when Square imports a third-party gift card, in which case the
gan_source of the gift card is set to OTHER.
block_activity_details Gift Card Activity Block Optional Represents details about a BLOCK gift card activity type.
unblock_activity_details Gift Card Activity Unblock Optional Represents details about an UNBLOCK gift card activity type.
import_reversal_activity_details Gift Card Activity Import Reversal Optional Represents details about an IMPORT_REVERSAL gift card activity type.
transfer_balance_to_activity_details Gift Card Activity Transfer Balance To Optional Represents details about a TRANSFER_BALANCE_TO gift card activity type.
transfer_balance_from_activity_details Gift Card Activity Transfer Balance From Optional Represents details about a TRANSFER_BALANCE_FROM gift card activity type.

Example (as JSON)

{
  "id": "id8",
  "type": "REDEEM",
  "location_id": "location_id2",
  "created_at": "created_at6",
  "gift_card_id": "gift_card_id6",
  "gift_card_gan": "gift_card_gan4",
  "gift_card_balance_money": {
    "amount": 82,
    "currency": "KPW"
  }
}