Gift cards
Import a gift card
Records a gift card that was sold somewhere else, such as a web shop. Cliento records no sale and makes no receipt for it. The card can be redeemed at the merchant's point of sale at once. Answers 201 for a new card and 200 with the existing card when externalReference was used before, so the call is safe to retry.
post/v1/locations/{locationId}/gift-cards/import
Request
- Base URL: https://api.cliento.com
- URL: https://api.cliento.com/v1/locations/{locationId}/gift-cards/import
- Auth: HTTP bearer
Path parameters
locationIdstring required
Headers
Idempotency-Keystring
A value you make up for this one request, such as a UUID. Send the same value when you retry and the first answer is returned; see Retrying safely.
Request body
Example request
{
"accountingType": "single_purpose",
"beneficiary": "Anna Andersson",
"code": "NH-4711",
"customerId": "per_2QCtWVSaVO7yCRYBj1zsbA",
"description": "Presentkort",
"externalReference": "shopify-5512340001-1",
"merchantId": "mer_2Rk8sVh3Yq6Nf1Tz0JwUcM",
"note": "Web shop order 10042",
"remainingValue": "500.00",
"soldDate": "2026-11-17",
"validUntil": "2027-11-17",
"value": "500.00",
"vatPercent": "25"
}Response
A card with this externalReference already existed. It is returned as it is now; nothing in this request was applied.
Example response
{
"accountingType": "single_purpose",
"beneficiary": "Anna Andersson",
"code": "K7QX9M2D",
"createdAt": "2026-11-17T09:14:03Z",
"currency": "SEK",
"customerId": "per_2QCtWVSaVO7yCRYBj1zsbA",
"description": "Presentkort",
"externalReference": "shopify-5512340001-1",
"id": "gft_7Qm2xN0cT1kPz4Wb9LrEaD",
"locationId": "loc_4fK9xQ2mLr8TzB1vNc7HdW",
"merchantId": "mer_2Rk8sVh3Yq6Nf1Tz0JwUcM",
"note": "Web shop order 10042",
"remainingValue": "500.00",
"soldDate": "2026-11-17",
"status": "active",
"updatedAt": "2026-10-12T09:24:31.512Z",
"validUntil": "2027-11-17",
"value": "500.00",
"vatPercent": "25"
}Changes
No recorded changes to this operation across all 1 revision of this API.