Errors
The Brave gateway uses standard HTTP codes. The OS-Travel and Cyberesa compatible gateways always answer HTTP 200 and carry the error in the body — read all three sections.
Brave gateway — HTTP codes
| Code | Typical error.code | Meaning |
|---|---|---|
400 | validation_failed | Invalid body or parameters (details in error.fields) |
401 | invalid_signature, stale_timestamp, missing_credentials | Authentication failed — see Request signing |
403 | ip_not_allowed, key_revoked, gateway_not_enabled | IP not allowed, key revoked, gateway or format not enabled |
404 | not_found | Unknown hotel, booking or reference data |
409 | invalid_state | State conflict (e.g. cancelling an already cancelled booking) |
422 | rate_expired, stop_sales, on_request_only | Offer expired, stop-sales, or “on request” offer not bookable |
429 | rate_limited | Quota exceeded — the Retry-After header says when to retry |
500 | internal_error | Internal error — retryable for reads only |
Brave gateway — error envelope
JSON (Accept: application/json):
{
"error": {
"code": "rate_expired",
"message": "The rate has expired. Run a new search.",
"fields": { "rateKey": "expired on 2026-11-13T10:22:00+01:00" }
}
}
XML (Accept: application/xml):
<ErrorResponse>
<Code>rate_expired</Code>
<Message>The rate has expired. Run a new search.</Message>
</ErrorResponse>
OS-Travel gateway — ErrorMessage
Always HTTP 200, even on errors: V1/V2 clients only parse 200.
{
"ErrorMessage": {
"Code": 401,
"Description": "Invalid credentials."
}
}
- On success,
ErrorMessageis always present withCode: nullandDescription: null(V2). - Quota exceeded:
Descriptioncontains"Too many requests ... Retry after YYYY-MM-DD HH:MM:SS.". - For
BookingCancellation, read the error inBookingCancellation.ErrorMessage(Code ≠ 200).
Cyberesa gateway — ErrorResult
Always HTTP 200 + valid XML, no CDATA. Business errors appear as:
<ErrorResult>
<Message>Invalid credentials</Message>
</ErrorResult>
or <Error><Message>…</Message></Error>, or <Error>…</Error>. Check for these nodes before parsing the business response.
What to do
- 429 — respect
Retry-Afterand slow down; see Rate limits. - 401 — check the signature computation and clock sync (NTP).
- 422
rate_expired— therateKeyis gone: new search, newcheckrate. - Bookings — never retry blindly: replay with the same
clientReference(see Idempotency). - Reads — a single retry is fine (
GET, search) on500or timeout.