Aller au contenu

Pré-autoriser un hold incidentals au check-in (en-tête Idempotency-Key obligatoire, NON-BLOQUANT)

POST
/v1/incidentals
curl --request POST \
--url https://example.com/v1/incidentals \
--header 'Content-Type: application/json' \
--header 'Idempotency-Key: example' \
--header 'X-API-Key: <X-API-Key>' \
--data '{ "stayId": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "folioId": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "establishmentId": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "amount": { "amountCents": "15000", "currency": "EUR" }, "readerRef": "example" }'
Idempotency-Key
required
string
>= 8 characters <= 200 characters

Clé d’idempotence OBLIGATOIRE (8–200 car.) — anti-double-hold PSP.

Pré-autorisation card-present. readerRef = réf OPAQUE du reader appairé (jamais une donnée carte).

Media type application/json
object
stayId
required
string format: uuid
folioId
required
string format: uuid
establishmentId
required
string format: uuid
amount
required
object
amountCents
required
string
Example
15000
currency
required
string
Allowed values: EUR GBP
readerRef
required

Réf opaque du reader appairé

string

Hold créé (pending, NOMINAL — résolution asynchrone par webhook)

Media type application/json
object
data
required
object
holdId
required
string format: uuid
Example generated
{
"data": {
"holdId": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0"
}
}

Corps invalide ou montant hors plafond

Media type application/json
object
code
required

Code machine de l’erreur

string
message
required

Message lisible

string
origin

Origine domaine de l’erreur (optionnel)

object
boundedContext
string
module
string
status
required
integer
traceId
required

Identifiant de corrélation pour le support

string
Example
{
"code": "RESERVATION_NOT_FOUND",
"message": "Réservation introuvable",
"status": 404
}

Non authentifié (Idempotency-Key manquante → 400)

Media type application/json
object
code
required

Code machine de l’erreur

string
message
required

Message lisible

string
origin

Origine domaine de l’erreur (optionnel)

object
boundedContext
string
module
string
status
required
integer
traceId
required

Identifiant de corrélation pour le support

string
Example
{
"code": "RESERVATION_NOT_FOUND",
"message": "Réservation introuvable",
"status": 404
}

Permission refusée ou IDOR

Media type application/json
object
code
required

Code machine de l’erreur

string
message
required

Message lisible

string
origin

Origine domaine de l’erreur (optionnel)

object
boundedContext
string
module
string
status
required
integer
traceId
required

Identifiant de corrélation pour le support

string
Example
{
"code": "RESERVATION_NOT_FOUND",
"message": "Réservation introuvable",
"status": 404
}