Validatemerchantsession
curl --request POST \
--url https://api.loyalty.dog/v2/giftcards/merchants/session/validate \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"sessionToken": "<string>"
}
'const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({sessionToken: '<string>'})
};
fetch('https://api.loyalty.dog/v2/giftcards/merchants/session/validate', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.loyalty.dog/v2/giftcards/merchants/session/validate"
payload = { "sessionToken": "<string>" }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text){
"valid": true,
"merchant": {
"id": "<string>",
"merchantId": "5eb7cf5a86d9755df3a6c593",
"name": "<string>",
"platform": "<string>",
"programId": "<string>",
"active": true,
"locationId": "<string>",
"locationName": "<string>",
"locations": [
{
"locationId": "<string>",
"locationName": "<string>",
"lastSeenAt": "<string>",
"programId": "<string>"
}
],
"cashierId": "<string>",
"terminalId": "<string>",
"role": "<string>",
"sessionToken": "<string>"
}
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}Gift Card Merchants
Validatemerchantsession
Validate Merchant Session
Check if a merchant session token is still valid.
POST
/
v2
/
giftcards
/
merchants
/
session
/
validate
Validatemerchantsession
curl --request POST \
--url https://api.loyalty.dog/v2/giftcards/merchants/session/validate \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"sessionToken": "<string>"
}
'const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({sessionToken: '<string>'})
};
fetch('https://api.loyalty.dog/v2/giftcards/merchants/session/validate', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.loyalty.dog/v2/giftcards/merchants/session/validate"
payload = { "sessionToken": "<string>" }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text){
"valid": true,
"merchant": {
"id": "<string>",
"merchantId": "5eb7cf5a86d9755df3a6c593",
"name": "<string>",
"platform": "<string>",
"programId": "<string>",
"active": true,
"locationId": "<string>",
"locationName": "<string>",
"locations": [
{
"locationId": "<string>",
"locationName": "<string>",
"lastSeenAt": "<string>",
"programId": "<string>"
}
],
"cashierId": "<string>",
"terminalId": "<string>",
"role": "<string>",
"sessionToken": "<string>"
}
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}Authorizations
JWT access token obtained from POST /v2/token.
Body
application/json
