Hermeseus

Revalidate a flight fare

Re-price an itinerary right before you book to confirm the fare is still available.

POST/Air/AirRevalidate

Access requires the permission air_revalidate

Fares from search are a snapshot. Call revalidate at the moment the traveller confirms. If the price or availability changed, you find out here instead of at book time. Use the returned itinerary as the source of truth for what you charge.

Path parameters

None.

Query parameters

None.

Body parameters

NameTypeRequiredDescription
SessionIdstringYesYour session id.
FareSourceCodestringYesThe itinerary code from search.

Request

curl -X POST https://api.hermeseus.com/api/Air/AirRevalidate \
  -H "Content-Type: application/json" \
  -d '{
    "SessionId": "8f3c81d2-4a5b-4c6d-9e0f-1a2b3c4d5e6f",
    "FareSourceCode": "dHA6ODc0NTE6ZmwxMjM0OjMyNw=="
  }'
const res = await fetch("https://api.hermeseus.com/api/Air/AirRevalidate", {
  method: "POST",
  headers: { "Content-Type": "application/json" },
  body: JSON.stringify({
    SessionId: "8f3c81d2-4a5b-4c6d-9e0f-1a2b3c4d5e6f",
    FareSourceCode: "dHA6ODc0NTE6ZmwxMjM0OjMyNw=="
  })
});

const data = await res.json();
import requests

res = requests.post(
    "https://api.hermeseus.com/api/Air/AirRevalidate",
    json={
        "SessionId": "8f3c81d2-4a5b-4c6d-9e0f-1a2b3c4d5e6f",
        "FareSourceCode": "dHA6ODc0NTE6ZmwxMjM0OjMyNw==",
    },
)

data = res.json()

Response

FieldTypeDescription
Successbooleantrue when the fare is still bookable.
PricedItineraryobjectThe re-priced itinerary. Same shape as a search result, including a FareSourceCode to book with.
ServicesarrayAvailable ancillary services.
MealTypeServicesarrayMeal options.
SeatServicesarraySeat options.
Errorobjectnull on success.
{
  "Success": true,
  "PricedItinerary": {
    "FareSourceCode": "dHA6ODc0NTE6ZmwxMjM0OjMyNw==",
    "ValidatingAirlineCode": "TK",
    "AirItineraryPricingInfo": {
      "ItinTotalFare": {
        "BaseFare": 182.40,
        "TotalTax": 37.20,
        "TotalFare": 219.60,
        "Currency": "USD"
      }
    }
  },
  "Services": [],
  "MealTypeServices": [],
  "SeatServices": [],
  "Error": null
}
The price can move. The FareSourceCode here may differ from the one you sent. Always book with the code this call returns, and show the traveller the fare from this response before charging them.

Errors

CodeMeaningFix
Err0102002Invalid FareSourceCode.Use a code from the latest search.
Err0102003The fare is no longer available.Search again.
Err0102005The fare has expired.Search again.
Next step. Book the itinerary with the FareSourceCode this call returned.