Skip to content
Voraal

Guide · APIs

How travel APIs work, from search request to issued ticket

Travel APIs let software search, price, book and service travel products held by airlines, GDSs, hotel suppliers and aggregators. This guide explains the layers, the request flow, why prices change between search and booking, and the engineering patterns that keep bookings correct.

Built for

  • OTA developers
  • Product managers
  • CTOs at agencies
  • Fintech and super-app teams
  • Startup founders

Short answer

How do travel APIs work?

Travel APIs work as a chain: your application sends a search request to an API, which queries suppliers such as GDSs, NDC airline APIs, low-cost carriers or hotel aggregators, normalises the answers into offers, re-prices the chosen offer, creates a booking (a PNR or an airline order), then issues tickets or vouchers and handles changes and cancellations. Unified APIs such as Voraal's Avunzo hide supplier differences behind one schema.

By the Voraal team · Updated · 7 min read

What are the layers behind a travel API?

There are usually three layers: supplier systems, an aggregation layer, and your application. Knowing which layer causes a problem saves days of debugging.

Supplier systems are the sources of inventory. For flights, that means the GDSs (Amadeus, Sabre and Travelport), airline NDC APIs and low-cost carrier booking APIs. IATA describes NDC as an XML-based data transmission standard built on offer and order management, which airlines adopt at their own pace. For hotels it means aggregators, bedbanks, chain connections and contracted inventory. Each supplier has its own data model, authentication and error codes.

The aggregation layer calls several suppliers, merges results, applies business rules such as markups and filters, and presents one schema. You can build this yourself or use a unified API. Your application then calls the aggregation layer, not each supplier. For a deeper look at the GDS route specifically, see flight booking API vs GDS.

What happens at each step of a flight booking API call?

StepWhat the API doesWhat can go wrongHow to handle it
SearchSends origin, destination, dates, passengers and cabin; returns priced options from each sourceSlow suppliers, partial results, cached prices that are staleSet per-supplier timeouts; label cached results; return what arrived
Price / offerRe-checks the chosen option live; returns a firm price, fare rules, baggage and an expiryPrice increase or sold-out classShow the new price and ask the user to confirm
BookCreates a PNR in a GDS or an order with an NDC airline, with passenger detailsTimeout with unknown outcome; name format errorsUse idempotency keys and retrieve before retrying
Ticket / fulfilIssues e-tickets or confirms the order and paymentTicketing time limit missed; payment declinedQueue by time limit; separate booking from ticketing
ServiceChanges, cancellations, voids, refunds, seat and baggage additionsDifferent rules per source; refunds that take weeksStore source and fare rules on the booking; track status

Why does the price change between search and booking?

Because search results are often a snapshot and inventory moves constantly. Airlines release and close booking classes as seats sell; hotels change availability and rates; and to keep search fast, many systems cache results for minutes.

The pricing step is where the snapshot is replaced by a live quote. A well-designed API returns an offer with an expiry time and a clear signal when the price has changed. Your application should never book on a search price without re-pricing, and it should treat a price change as a normal outcome rather than an error.

How do hotel APIs differ from flight APIs?

Hotel APIs revolve around rate keys and cancellation policies rather than fare rules and tickets. A search returns properties with room and rate combinations; each rate has a key that is valid for a short time. Before booking, a rate check or pre-book call confirms the price and policy. The booking returns a confirmation number and, eventually, a voucher.

Two hotel-specific traps catch new teams. First, the same property appears from several suppliers with slightly different names and room descriptions, so mapping is a real workload. Second, cancellation deadlines are often in the hotel's local time zone, and getting that wrong turns a free cancellation into a full charge.

How should you integrate a travel API safely?

  1. 01

    Start in the sandbox

    Use test credentials and test data to build the full flow, including errors. Do not move to production until cancellations and refunds work in test.

  2. 02

    Read the specification

    Use the OpenAPI or schema documentation to generate clients and validate payloads. The OpenAPI Specification is a widely used, language-agnostic way to describe HTTP APIs.

  3. 03

    Design for partial results

    Show whatever arrived within your search time budget. One slow supplier should not block the whole page.

  4. 04

    Make booking idempotent

    Send a unique key with each booking request. If a timeout occurs, retrieve by that key before retrying, so a network error does not create two bookings.

  5. 05

    Subscribe to webhooks

    Receive booking status, ticketing and schedule-change events instead of polling. Verify signatures and handle duplicate deliveries.

  6. 06

    Store what you need to service

    Keep supplier references, fare rules, cancellation policy and the price breakdown on your booking record. You will need them for every change and refund.

  7. 07

    Test with live, low-value bookings

    Before launch, book and cancel real inventory on each source to confirm that production behaves like the sandbox.

Which API concepts matter most to non-engineers?

  • Look-to-book ratio

    Suppliers watch how many searches you make per booking. Excessive searching without booking can lead to throttling or fees, so caching strategy has commercial consequences.

  • Offer expiry

    Every priced offer has a lifetime. Long checkout pages and slow payment steps cause expired offers and re-pricing.

  • Normalisation

    Different suppliers describe baggage, cabins and room types differently. A unified schema decides how these are mapped, which affects what customers see.

  • Versioning

    APIs change. Versioned endpoints let you upgrade on your timetable instead of discovering a breaking change in production.

  • Scoped credentials

    Separate keys per environment and channel limit the damage from a leaked key and make usage reporting clearer.

Should you build the aggregation layer or use a unified API?

Build it if travel technology is your core product and you have a team to maintain supplier connections for years. Each supplier integration needs certification, monitoring and updates as the supplier changes its interface.

Use a unified API if you want to launch faster and spend engineering time on your own product. The trade-off is dependency on the provider's coverage and roadmap. A practical middle path is to use a unified API for most content and add a direct connection only where it gives you a clear commercial edge. The travel API integration checklist is a useful scoping tool either way.

How do webhooks and schedule changes work?

A webhook is a message the API sends to your server when something changes, such as a ticket being issued, a booking cancelled by the supplier or an airline changing a flight time. Your system receives it, verifies it, and updates the booking.

Schedule changes are the event that matters most operationally. Airlines move flights regularly, and each change may require the traveller to accept a new time, be rebooked or be refunded. A good integration turns each change into a task with a deadline, shows the old and new itinerary side by side, and records the traveller's response. Webhook handlers should be idempotent too, because the same event can be delivered more than once.

How are travel APIs secured?

Through credentials per environment and channel, encrypted transport, rate limits and careful handling of personal and payment data. Keep sandbox and production keys separate, rotate them when staff leave, and never embed them in a mobile app or browser code where they can be extracted. Passenger data such as passport details should be stored only where you need it for the booking, with access limited by role. Card data has its own rules; many integrations avoid handling raw card numbers by using a payment provider's hosted fields or tokens.

How Voraal fits

Avunzo is Voraal's unified REST/JSON travel API. It covers flights from Amadeus, Sabre and Travelport, NDC airlines and low-cost carriers, plus hotels, transfers, car rental, activities and dynamic packages, with a sandbox, OpenAPI specification, webhooks, versioned endpoints, scoped credentials, idempotent booking requests, caching and parallel supplier calls. Pricing is usage-based. See the travel API integration service, the flight booking API and hotel booking API pages, or the developer-focused travel API overview.

Key takeaways

  • Treat search results as a snapshot and always re-price before booking
  • Show partial results within a fixed search time budget
  • Use idempotency keys and retrieve before retrying any booking
  • Store supplier references, fare rules and cancellation policies on every booking
  • Handle hotel cancellation deadlines in the property's local time zone
  • Use webhooks for status and schedule changes instead of polling
  • Watch look-to-book ratios; caching decisions have commercial effects

How Voraal delivers this

The product behind it.

FAQ

Frequently asked questions

Questions buyers ask about how travel apis work.

Ask us anything
  • What is the difference between a PNR and an NDC order?

    A PNR is the booking record in a GDS or airline reservation system, with tickets issued against it. An NDC order is the airline's record of what was sold, built on the offer and order model, and may include ancillaries in the same order.

  • Why do some travel APIs return fewer results than the airline website?

    The API may access different content, apply filters or time out slow suppliers. Airlines also sometimes reserve certain fares or bundles for direct or NDC channels.

  • Is REST or SOAP more common in travel APIs?

    Both are still in use. Many established GDS services use SOAP/XML, NDC uses XML schemas, and newer aggregator and unified APIs typically expose REST with JSON.

  • What is an idempotency key in a booking API?

    It is a unique value you send with a request so that, if the same request arrives twice, the server performs the action only once. It prevents duplicate bookings after network timeouts.

  • How long is a travel API price quote valid?

    It varies by supplier and product, from minutes to longer. The pricing response should include an expiry; if it does not, assume a short life and re-price before booking.

  • Do travel APIs handle refunds automatically?

    Some do for certain sources and fare types, others only submit the request and report status later. Check per supplier whether refunds are automated, semi-automated or manual.

Sources and further reading

Regulations, airline programmes and supplier terms change. Confirm requirements with the relevant authority or supplier before acting. Contact [email protected] if you spot something out of date.

Let’s build what comes next.

Tell us how your travel business works. We’ll recommend the right products and walk you through them on your own use case.

WhatsApp