Get a list of tokens
This method allows you to get a list of tokens and their corresponding information.
- URL syntax: /api/v2/merchant/tokens
- Method: GET
URL parameters
| Name | Type | Mandatory | Description |
|---|---|---|---|
| status | string | N | The token status. See Token statuses. |
| expiration_date_start | unix timestamp | N | The expiration start date from which you want to get the tokens. |
| expiration_date_end | unix timestamp | N | The expiration end date until where you want to get the tokens. |
| creation_date_start | unix timestamp | N | The creation start date from which you want to get the tokens. |
| creation_date_end | unix timestamp | N | The creation end date until where you want to get the tokens. |
| moto_instance_id | string | N | The phone booking instance id related to the token. |
| customer.email | string | N | The customer email. |
| payment_method.type | string | N | The payment method type. See Payment Method types. |
| payment_method.validation_status | string | N | The payment method validation status. See validation status. |
| page | int | N | The results page number requested. |
Example request
/api/v2/merchant/tokens?status=ACTIVE
/api/v2/merchant/tokens?expiration_date_start=1364957978
/api/v2/merchant/tokens?customer.email=test@test.com&payment_method.validation_status=VALID
Response parameters
The response in this case is a List with potential Token(s).
Example response
{
"class": "list",
"items_class": "token",
"total_count": 2,
"pages": 1,
"page": 1,
"limit": 100,
"next_page": null,
"previous_page": null,
"data": [
{
"class": "token",
"id": "45843",
"status": "ACTIVE",
"action_url": null,
"booking_id": null,
"check_in_date": null,
"check_out_date": null,
"booking_details": {
"class": "booking_details",
"type": "HOTEL",
"booking_id": null,
"check_in_date": null,
"check_out_date": null,
"total_booking_amount": null,
"booking_currency": null
},
"creation_date": "1487945884",
"expiration_date": "1738368000",
"accept_until": null,
"description": "testing",
"extra": null,
"customer": {
"class": "customer",
"email": null,
"language": "en",
"firstname": null,
"lastname": "test",
"billing_address": null
},
"payment_method": {
"class": "payment_method",
"type": "CREDITCARD",
"validation_status": "VALID",
"validation_date": "1487945886",
"invalid_reason": null,
"display": null,
"details": {
"class": "payment_method_details",
"fingerprint": "d5b08ba4-ac2e-4005-b952-0fdebd3d65ff",
"holder": "test",
"scheme": "VISA",
"exp_month": "01",
"exp_year": "2025"
}
},
"moto_instance_id": "58b04071c7f17e546c8b45e7",
"mandate": {
"class": "mandate",
"status": "ACTIVE",
"currency": "EUR",
"end_reason": null,
"start_date": 1487945884,
"end_date": null
},
"payment": {
"class": "payment",
"id": 156981,
"reference": "gen-58b0409c2572f",
"amount": 100,
"currency": "EUR",
"status": "SUCCESS",
"preauth_expiration_date": null,
"action_url": null,
"flow": "SELLER",
"processing_time": 1487945885,
"source": 2544,
"contract": "SysPay (8737476)",
"descriptor": "Test Contract",
"extra": null,
"description": "testing",
"account_id": 23918,
"merchant_id": 2744,
"merchant_login": "23918001",
"settlement_date": 1488810904,
"failure_category": null,
"chip_and_pin_status": null,
"capture_date": null,
"token": {
"class": "reference",
"id": 45843,
"type": "token",
"link": "https://app-sandbox.syspay.com/api/v2/merchant/token/45843"
},
"customer": {
"class": "customer",
"email": null,
"language": "en",
"firstname": null,
"lastname": null,
"billing_address": null
},
"payment_method": {
"class": "payment_method",
"type": "CREDITCARD",
"validation_status": "VALID",
"validation_date": "1487945886",
"invalid_reason": null,
"display": null,
"details": {
"class": "payment_method_details",
"fingerprint": "d5b08ba4-ac2e-4005-b952-0fdebd3d65ff",
"holder": "test",
"scheme": "VISA",
"exp_month": "01",
"exp_year": "2025"
}
},
"processor_reference": null,
"qr_code": null
},
"risk": {
"class": "risk",
"level": "MEDIUM",
"reason": null
}
},
{
"class": "token",
"id": "83377",
"status": "ACTIVE",
"action_url": null,
"booking_id": "65eaf84d2694e",
"check_in_date": "2024-03-31",
"check_out_date": "2024-04-07",
"booking_details": {
"class": "booking_details",
"type": "HOTEL",
"booking_id": "65eaf84d2694e",
"check_in_date": "2024-03-31",
"check_out_date": "2024-04-07",
"total_booking_amount": "100000",
"booking_currency": "EUR"
},
"creation_date": "1709847486",
"expiration_date": "1712489805",
"accept_until": null,
"description": "Booking 65ea33bc7446e from 2024-03-30 to 2024-04-06.",
"extra": "Array",
"customer": {
"class": "customer",
"email": "john.doe+65ea33bc72e00@gmail.com",
"language": "en",
"firstname": "John",
"lastname": "Doe",
"billing_address": {
"class": "billing_address",
"address1": "55 rue du Faubourg Saint-Honoré",
"address2": null,
"address3": null,
"city": "Paris",
"country": "FR",
"postal_code": "75008"
}
},
"payment_method": {
"class": "payment_method",
"type": "CREDITCARD",
"validation_status": "VALID",
"validation_date": "1709898064",
"invalid_reason": null,
"display": "4491-70xx-xxxx-4007",
"details": {
"class": "payment_method_details",
"fingerprint": "1c2cd558-d343-49c4-ac98-0bee7846c0c4",
"holder": "Card Holder Name",
"scheme": "VISA",
"exp_month": "01",
"exp_year": "2025"
}
},
"moto_instance_id": null,
"mandate": {
"class": "mandate",
"status": "ACTIVE",
"currency": "EUR",
"end_reason": null,
"start_date": 1709847486,
"end_date": null
},
"payment": null,
"risk": {
"class": "risk",
"level": "MEDIUM",
"reason": null
}
}
]
}