Loyalty Transactions
Loyalty Transaction is the umbrella term for both Credit Receptions and Reward Receptions, representing all the changes to a Credit Balance.
Loyalty Transaction is the umbrella term for both Credit Receptions and Reward Receptions, representing all the changes to a Credit Balance.
List Loyalty Transactions
Returns transactions for a Loyalty Program. The results can be filtered by Contact, Shop and Loyalty Transaction type.
GET
https://api.piggy.eu/api/v3/oauth/clients/loyalty-transactionsHeaders
Authorization
Accept
Bearer {{ personal_access_token }}
application/json
Input parameters
limit number
optional
Limit of records to retrieve. Default: 10; Maximum: 100.
page number
optional
Page to retrieve. Default: 1.
type string
optional
Type of Loyalty Transactions to be retrieved, options: 'credit_receptions' and 'reward_receptions'. If not set, loyalty transactions of all types are retrieved.
shop_uuid string
optional
Retrieve transactions performed at a specific Shop/Business Profile
sort string
optional
Sort by column. Ascending by default, prefix with a hyphen to sort descending (e.g. ?sort=-created_at)
Possible values:
created_at'Sort by creation date. Prefix with '-' for descending.
created_at array
optional
Filter on creation date, can only be sent in as array. Date value must be in ISO8601 format. Combine to retrieve transactions between two dates.
Possible values:
created_at[gt]Filter on creation date is greater than value.
created_at[gte]Filter on creation date is greater than or equal to value.
created_at[lt]Filter on creation date is lower than value.
created_at[lte]Filter on creation date is greater than value.
Response Example
{
"data": [
{
"uuid": "daa78841-b321-4564-9dd3-91c6ccd9d600",
"credits": 1177,
"created_at": "2023-11-12T19:27:49+00:00",
"type": "credit_reception",
"contact_identifier": null,
"contact": {
"uuid": "123",
"email": "spongebob@bikinibottom.sea",
"credit_balance": {
"id": 2625740,
"balance": 2929
}
},
"shop": {
"id": 15,
"uuid": "123abc-def789-qwerty-34567",
"type": "physical",
"name": "Krusty Krab",
"address": {
"id": 59,
"shop_id": 15,
"street": "Conch Street",
"housenumber": 12,
"postalcode": "9999YZ",
"city": "Bikini Bottom",
"state": "NH",
"country": "NL",
"latitude": null,
"longitude": null,
"house_number": null,
"postal_code": null
}
},
"unit_value": 1.15,
"unit": {
"id": 298,
"name": "test2",
"label": "Calories",
"prefix": "t",
"is_default": true
}
},
{
"uuid": "9423bcfa-c2b1-41e6-998b-5c4182d1e259",
"credits": 20,
"created_at": "2023-11-12T17:37:41+00:00",
"type": "credit_reception",
"contact_identifier": null,
"contact": {
"uuid": "123",
"email": "spongebob@bikinibottom.sea",
"credit_balance": {
"id": 2625740,
"balance": 2929
}
},
"shop": {
"id": 15,
"uuid": "123abc-def789-qwerty-34567",
"type": "physical",
"name": "Krusty Krab",
"address": {
"id": 59,
"shop_id": 15,
"street": "Conch Street",
"housenumber": 12,
"postalcode": "9999YZ",
"city": "Bikini Bottom",
"state": "NH",
"country": "NL",
"latitude": null,
"longitude": null,
"house_number": null,
"postal_code": null
}
},
"unit_value": null,
"unit": {
"id": 112,
"name": "test",
"label": "Calories",
"prefix": "",
"is_default": true
}
},
{
"uuid": "57589e9f-0107-4cdc-afb6-03b8c89d892e",
"credits": 0,
"created_at": "2023-11-10T16:47:40+00:00",
"type": "credit_reception",
"contact_identifier": null,
"contact": {
"uuid": "123",
"email": "spongebob@bikinibottom.sea",
"credit_balance": {
"id": 2625740,
"balance": 2929
}
},
"shop": {
"id": 15,
"uuid": "123abc-def789-qwerty-34567",
"type": "physical",
"name": "Krusty Krab",
"address": {
"id": 59,
"shop_id": 15,
"street": "Conch Street",
"housenumber": 12,
"postalcode": "9999YZ",
"city": "Bikini Bottom",
"state": "NH",
"country": "NL",
"latitude": null,
"longitude": null,
"house_number": null,
"postal_code": null
}
},
"unit_value": null,
"unit": {
"id": 112,
"name": "test",
"label": "Calories",
"prefix": "",
"is_default": true
}
},
{
"uuid": "a45f1a18-bed8-4451-aba5-1a9e83fa5ea4",
"credits": 0,
"created_at": "2023-11-10T16:46:12+00:00",
"type": "credit_reception",
"contact_identifier": null,
"contact": {
"uuid": "123abc-def789-qwerty-34567",
"email": "spongebob@bikinibottom.sea",
"credit_balance": {
"id": 2625740,
"balance": 2929
}
},
"shop": {
"id": 15,
"uuid": "123abc-def789-qwerty-34567",
"type": "physical",
"name": "Krusty Krab",
"address": {
"id": 59,
"shop_id": 15,
"street": "Conch Street",
"housenumber": 12,
"postalcode": "9999YZ",
"city": "Bikini Bottom",
"state": "NH",
"country": "NL",
"latitude": null,
"longitude": null,
"house_number": null,
"postal_code": null
}
},
"unit_value": null,
"unit": {
"id": 112,
"name": "test",
"label": "Calories",
"prefix": "",
"is_default": true
}
},
{
"uuid": "a06e0546-48d4-4faf-91c6-f66989f5a49f",
"credits": 0,
"created_at": "2023-11-10T16:23:38+00:00",
"type": "credit_reception",
"contact_identifier": null,
"contact": {
"uuid": "123",
"email": "spongebob@bikinibottom.sea",
"credit_balance": {
"id": 2625740,
"balance": 2929
}
},
"shop": {
"id": 15,
"uuid": "123abc-def789-qwerty-34567",
"type": "physical",
"name": "Krusty Krab",
"address": {
"id": 59,
"shop_id": 15,
"street": "Conch Street",
"housenumber": 12,
"postalcode": "9999YZ",
"city": "Bikini Bottom",
"state": "NH",
"country": "NL",
"latitude": null,
"longitude": null,
"house_number": null,
"postal_code": null
}
},
"unit_value": null,
"unit": {
"id": 112,
"name": "test",
"label": "Calories",
"prefix": "",
"is_default": true
}
},
{
"uuid": "e64ad300-668b-428d-850d-f4eb9b37268b",
"credits": 10,
"created_at": "2023-11-09T19:24:58+00:00",
"type": "credit_reception",
"contact_identifier": null,
"contact": {
"uuid": "123abc-def789-qwerty-34567",
"email": "spongebob@bikinibottom.sea",
"credit_balance": {
"id": 2625740,
"balance": 2929
}
},
"shop": {
"id": 15,
"uuid": "123abc-def789-qwerty-34567",
"type": "physical",
"name": "Krusty Krab",
"address": {
"id": 59,
"shop_id": 15,
"street": "Conch Street",
"housenumber": 12,
"postalcode": "9999YZ",
"city": "Bikini Bottom",
"state": "NH",
"country": "NL",
"latitude": null,
"longitude": null,
"house_number": null,
"postal_code": null
}
},
"unit_value": null,
"unit": {
"id": 112,
"name": "test",
"label": "Calories",
"prefix": "",
"is_default": true
}
},
{
"uuid": "8630aa53-0097-4beb-8504-4938f4ef724e",
"credits": 10,
"created_at": "2023-11-09T14:13:36+00:00",
"type": "credit_reception",
"contact_identifier": null,
"contact": {
"uuid": "123abc-def789-qwerty-34567",
"email": "spongebob@bikinibottom.sea",
"credit_balance": {
"id": 2625740,
"balance": 2929
}
},
"shop": {
"id": 15,
"uuid": "123abc-def789-qwerty-34567",
"type": "physical",
"name": "Krusty Krab",
"address": {
"id": 59,
"shop_id": 15,
"street": "Conch Street",
"housenumber": 12,
"postalcode": "9999YZ",
"city": "Bikini Bottom",
"state": "NH",
"country": "NL",
"latitude": null,
"longitude": null,
"house_number": null,
"postal_code": null
}
},
"unit_value": null,
"unit": {
"id": 112,
"name": "test",
"label": "Calories",
"prefix": "",
"is_default": true
}
},
{
"uuid": "ec2e9f1f-2573-4937-90f7-b610e881059b",
"credits": 10,
"created_at": "2023-11-09T14:12:44+00:00",
"type": "credit_reception",
"contact_identifier": null,
"contact": {
"uuid": "123abc-def789-qwerty-34567",
"email": "spongebob@bikinibottom.sea",
"credit_balance": {
"id": 2625740,
"balance": 2929
}
},
"shop": {
"id": 15,
"uuid": "123abc-def789-qwerty-34567",
"type": "physical",
"name": "Krusty Krab",
"address": {
"id": 59,
"shop_id": 15,
"street": "Conch Street",
"housenumber": 12,
"postalcode": "9999YZ",
"city": "Bikini Bottom",
"state": "NH",
"country": "NL",
"latitude": null,
"longitude": null,
"house_number": null,
"postal_code": null
}
},
"unit_value": null,
"unit": {
"id": 112,
"name": "test",
"label": "Calories",
"prefix": "",
"is_default": true
}
},
{
"uuid": "e075a8a4-6d50-4b30-a62b-142fb8a91a30",
"credits": 10,
"created_at": "2023-11-09T14:12:29+00:00",
"type": "credit_reception",
"contact_identifier": null,
"contact": {
"uuid": "123abc-def789-qwerty-34567",
"email": "spongebob@bikinibottom.sea",
"credit_balance": {
"id": 2625740,
"balance": 2929
}
},
"shop": {
"id": 15,
"uuid": "123abc-def789-qwerty-34567",
"type": "physical",
"name": "Krusty Krab",
"address": {
"id": 59,
"shop_id": 15,
"street": "Conch Street",
"housenumber": 12,
"postalcode": "9999YZ",
"city": "Bikini Bottom",
"state": "NH",
"country": "NL",
"latitude": null,
"longitude": null,
"house_number": null,
"postal_code": null
}
},
"unit_value": null,
"unit": {
"id": 112,
"name": "test",
"label": "Calories",
"prefix": "",
"is_default": true
}
},
{
"uuid": "13d3f57a-5566-42d0-8a63-328958f49144",
"credits": 10,
"created_at": "2023-11-09T14:11:32+00:00",
"type": "credit_reception",
"contact_identifier": null,
"contact": {
"uuid": "123",
"email": "spongebob@bikinibottom.sea",
"credit_balance": {
"id": 2625740,
"balance": 2929
}
},
"shop": {
"id": 15,
"uuid": "123123",
"type": "physical",
"name": "Krusty Krab",
"address": {
"id": 59,
"shop_id": 15,
"street": "Conch Street",
"housenumber": 12,
"postalcode": "9999YZ",
"city": "Bikini Bottom",
"state": "NH",
"country": "NL",
"latitude": null,
"longitude": null,
"house_number": null,
"postal_code": null
}
},
"unit_value": null,
"unit": {
"id": 112,
"name": "test",
"label": "Calories",
"prefix": "",
"is_default": true
}
}
],
"meta": {
"page": 1,
"limit": 10,
"viewing_from": 1,
"viewing_to": 10,
"last_page": 6,
"total": 57
}
}Loyalty Program Settings
Contacts save credits at Loyalty Programs. Clients (people, store-owners or corporations who buy our software) may not use Loyalty at all, or join a Loyalty Pro
Credit Receptions
Credit Receptions have been largely replaced by top level entities such as Orders, Visits and Bookings. Please use those instead. If your use case doesn't fit a