Skip to main content
POST
/
v2
/
giftcards
/
gdpr
/
consent
Creategiftcardconsent
curl --request POST \
  --url https://api.loyalty.dog/v2/giftcards/gdpr/consent \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "purposes": [],
  "ipAddress": "<string>",
  "customerEmail": "<string>",
  "customerPhone": "<string>"
}
'
{
  "customerId": "<string>",
  "purposes": [
    "<string>"
  ],
  "consentedAt": "2023-11-07T05:31:56Z",
  "ipAddress": "<string>",
  "expiresAt": "2023-11-07T05:31:56Z",
  "updatedAt": "2023-11-07T05:31:56Z"
}

Authorizations

Authorization
string
header
required

JWT access token obtained from POST /v2/token.

Headers

X-Eposn-Customer-Token
string | null
X-Eposn-Merchant-Token
string | null

Query Parameters

programId
string | null
Required string length: 24
Pattern: ^[0-9a-f]{24}$
Example:

"5eb7cf5a86d9755df3a6c593"

cardId
string | null
Required string length: 24
Pattern: ^[0-9a-f]{24}$
Example:

"5eb7cf5a86d9755df3a6c593"

Body

application/json
purposes
string[]
ipAddress
string | null
customerEmail
string | null
customerPhone
string | null

Response

Successful Response

customerId
string
required
purposes
string[]
required
consentedAt
string<date-time>
required
ipAddress
string | null
required
expiresAt
string<date-time> | null
required
updatedAt
string<date-time> | null
required