Reverse
POST
/api/v1/generic-api-service/flight/reverse
The reverse endpoint performs the actual PNR cancellation using the reverseToken obtained from the Reverse Inquire service. It cancels the ticket(s) and applies the previously quoted penalty and refund amounts.
- cURL
- Request
- Response
- Request Details
- Response Details
curl --location 'https://test-api.etscore.com/api/v1/generic-api-service/flight/reverse' \
--header 'Content-Type: application/json' \
--header 'Accept: application/json' \
--header 'Authorization: Bearer <token>' \
--data '{
"orderId": "49661695",
"pnr": "42ED16",
"reverseToken": "00b1804f-0791-4480-9842-758fa48cd119"
}'
{
"orderId": "49661695",
"pnr": "42ED16",
"reverseToken": "00b1804f-0791-4480-9842-758fa48cd119"
}
{
"success": true,
"orderId": 49661695,
"pnr": "42ED16",
"orderStatus": "REFUND_PNR",
"reverseType": "REFUND_PNR",
"totalPenaltyAmount": 68.53,
"totalRefundAmount": 39.85,
"currency": "EUR"
}
| Name | Type | Required | Description |
|---|---|---|---|
| orderId | string | Yes | The unique order identifier of the booking to be cancelled. |
| pnr | string | Yes | The PNR (booking reference) to be cancelled. |
| reverseToken | string | Yes | The reverseToken obtained from the Reverse Inquire service. It must still be valid (before its expireTime). |
| Name | Type | Required | Description |
|---|---|---|---|
| success | boolean | Yes | Indicates whether the cancellation was performed successfully. |
| orderId | int | Yes | The order identifier. |
| pnr | string | Yes | The PNR that was cancelled. |
| orderStatus | string | Yes | Order status after the reverse operation (e.g. REFUND_PNR). |
| reverseType | string | Yes | The type of reverse operation performed (e.g. REFUND_PNR). |
| totalPenaltyAmount | decimal | Yes | Total cancellation penalty charged. |
| totalRefundAmount | decimal | Yes | Total amount refunded after the penalty. |
| currency | string | Yes | Currency of the amounts (e.g. EUR). |