Data model description
The loyalty card object contains details about the loyalty-type voucher.
Attributes | Description | Example |
---|---|---|
idstring | System generated id for the loyalty card object. | v_nqM9ve5MsS3WnbSNdzft6xsGmx9CO7TE |
codestring | A code that identifies the voucher. | tSqB4vkw |
campaignstring | Name of the campaign connected to the loyalty card. | Loyalty Campaign |
campaign_idstring | Campaign id connected to the loyalty card. | camp_pqZjuhG6Mgtp4GD0zD7b8hA3 |
category | ||
typestring | Loyalty card voucher type is LOYALTY_CARD . | LOYALTY_CARD |
discount | ||
loyalty_cardobject | This object represents loyalty parameters. - points ( integer ): Total number of points accrued over the lifetime of the loyalty card.- balance ( integer ): Remaining balance that customer is able to spend.- next_expiration_date ( string ): YYYY-MM-DD , when the next set of points are due to expire- next_expiration_points ( integer ): number of points that are next in line to expire | "loyalty_card": { "points": 1100, "balance": 970, "next_expiration_date": "2022-09-30", "next_expiration_points": 100 } |
start_date | ||
expiration_date | Loyalty cards's expiration date | |
validity_timeframe | ||
validity_day_of_week | ||
publishobject | Stores details of each publish event and events counter in an array. | { "object": "list", "count": 1, "data_ref": "entries", "entries": [], "total": 1, "url": "/v1/vouchers/tSqB4vkw/publications?page=1&limit=10" } |
redemptionobject | { "object": "list", "quantity": null, "redeemed_quantity": 0, "data_ref": "redemption_entries", "redemption_entries": [], "total": 0, "url": "/v1/vouchers/tSqB4vkw/redemptions?page=1&limit=10", "redeemed_points": 0 } | |
activeboolean | A flag that allows to disable a campaign. | true or false |
additional_info | Optional description | |
metadataobject | Metadata gather custom attributes assigned to the loyalty card as metadata. | |
assetsobject | Links to generated QR and barcode | { "qr": { "id": "U2FsdGVkX19wmeB2x1oS+NZcJi4Y+HpemBWER7N5AQ0qxXxyjKOR9ELuh4xSr4sLvAppKFYawFGEQ98+J9WrqaR1WZM9OaoQNno/a+RfLcZP6EWOfiSBi2imK/2msAs+8w388kSa0rciObZAdt+z+Q==", "url": "https://dev.dl.voucherify.io/api/v1/assets/qr/U2FsdGVkX19wmeB2x1oS%2BNZcJi4Y%2BHpemBWER7N5AQ0qxXxyjKOR9ELuh4xSr4sLvAppKFYawFGEQ98%2BJ9WrqaR1WZM9OaoQNno%2Fa%2BRfLcZP6EWOfiSBi2imK%2F2msAs%2B8w388kSa0rciObZAdt%2Bz%2BQ%3D%3D" } |
holder_idstring | Customer ID of the owner of the loyalty card | cust_dDIUK0wZ5tlhbTZO5Kn3N4Ki |
updated_atstring , ISO 8601 date format | When the loyalty card was updated | 2021-12-13T13:26:23Z |
created_atstring , ISO 8601 date format | When the loyalty card was created | 2021-12-13T07:45:32Z |
objectstring | Type of the object represented by JSON. Value is voucher . | voucher |
validation_rules_assignmentsobject | List of The validation rule assignment object | { "data": [], "object": "list", "total": 0, "data_ref": "data" } |