How MoonTrip's PNR Parser Turns Raw GDS Text into Flight Vouchers and Invoices

Paste Amadeus, Sabre, or Galileo PNR text — MoonTrip extracts every flight segment, passenger, and booking class instantly. No GDS terminal connection needed.

March 2026 6 min read

The Problem: GDS Text Is Not Human-Readable

A PNR (Passenger Name Record) is a coded data record containing all flight segments, passenger names, booking classes, and reservation status for an air booking. If you've ever looked at raw PNR output from a GDS terminal, you know it looks like this:

Raw Amadeus PNRRP/DELAA1234/ 1.SHARMA/RAJESH MR 2.SHARMA/PRIYA MRS 2 AI 865 Y 15MAR DELBOM HK2 0630 0840 3 6E 204 S 18MAR BOMDEL HK2 1900 2115 4 AP DEL 9876543210 5 TK OK15MAR

For a trained GDS operator, this is readable. But most travel agents today don't work on GDS terminals — they receive this text from a consolidator, an airline's booking confirmation, or a colleague. Translating this into a customer quote means:

  • Decoding airline codes (AI = Air India, 6E = IndiGo)
  • Looking up airport codes (DEL = Delhi, BOM = Mumbai)
  • Parsing date formats (15MAR = March 15)
  • Understanding booking classes (Y = Economy, S = Economy)
  • Calculating layover durations for multi-sector routes
  • Typing all of this into a quote or invoice manually
Common Mistake
Manual PNR transcription is error-prone. Mixing up a flight number, misreading a date, or swapping departure and arrival airports can result in wrong tickets, missed flights, and angry customers.
MoonTripMoonTrip
Manual ProcessRead cryptic GDS codesLook up airline/airport codesType flight details one by oneCalculate layover durationsCreate invoice line items manually
With MoonTripPaste raw PNR textAll segments auto-extractedAirline & airport names resolvedLayovers calculated automaticallyQuote + invoice auto-populated
Manual process vs MoonTrip — see the difference

How MoonTrip's PNR Parser Works

A GDS (Global Distribution System) is a centralized computer network used by travel agents to search, book, and manage airline reservations globally. MoonTrip's GDS PNR parser reads raw text from Amadeus, Sabre, and Galileo and converts it into structured, editable flight data. No GDS terminal connection, no API integration, no training needed — just paste and go.

MoonTripMoonTrip
Raw PNR Text1.SHAH/UTSAV MR 2.SHARMA/PRIYA MRS2 AI 865 Y 15MAR DELBOM HK2 0630 08403 AI 143 Y 15MAR BOMGOI HK2 1030 11454 6E 204 S 18MAR GOIDEL HK2 1400 1630
Passengers (2)SHAH/UTSAV MR · SHARMA/PRIYA MRS
Trip TypeMulti-City · 3 Segments
DEL → BOMAI 865 · 15 Mar · 06:30
BOM → GOIAI 143 · 15 Mar · 10:30
GOI → DEL6E 204 · 18 Mar · 14:00
Quote Auto-PopulatedFlight line items + pricing
Invoice ReadyGST-compliant with HSN codes
Raw PNR text → structured flight data → quote and invoice in seconds

Supported GDS Formats

Each GDS has its own text format. MoonTrip's parser auto-detects the format and applies the correct parsing rules:

Amadeus Format

Amadeus PNR → Parsed OutputInput: 1.SHAH/UTSAV MR 2 AI 865 Y 15MAR DELBOM HK1 0630 0840 Parsed: Passenger : SHAH/UTSAV (MR) Airline : Air India (AI) Flight : AI 865 Class : Y (Economy) Date : 15 March 2026 Route : New Delhi (DEL) → Mumbai (BOM) Departure : 06:30 Arrival : 08:40 Status : Confirmed (HK) Passengers : 1

Sabre Format

Sabre PNR → Parsed OutputInput: 1.1PATEL/AMIT MR 1 UK 835Y 20MAR BOMBOM HK1 0715 0930 2 UK 836Y 24MAR BOMDEL HK1 1800 2020 Parsed: Passenger : PATEL/AMIT (MR) Segment 1 : Vistara UK 835 · 20 Mar · BOM→DEL · 07:15-09:30 Segment 2 : Vistara UK 836 · 24 Mar · DEL→BOM · 18:00-20:20 Trip Type : Round Trip

Galileo Format

Galileo PNR → Parsed OutputInput: 1.1GUPTA/SNEHA MS 1. AI 101 Y 12MAR DELBLR HK1 1045 1330 2. SG 234 S 16MAR BLRDEL HK1 0900 1145 Parsed: Passenger : GUPTA/SNEHA (MS) Segment 1 : Air India AI 101 · 12 Mar · DEL→BLR · 10:45-13:30 Segment 2 : SpiceJet SG 234 · 16 Mar · BLR→DEL · 09:00-11:45 Trip Type : Round Trip
MoonTrip PNR parser interface showing raw GDS text input area on the left and structured flight segment output with airline names, airport names, and timings on the right
Paste raw PNR text on the left — structured flight data appears on the right instantly

What Gets Extracted

The parser doesn't just read flight numbers. It extracts and resolves everything a travel agent needs:

  • Passenger names — with title (Mr/Mrs/Ms/Mstr) and count
  • Flight segments — airline, flight number, date, departure/arrival times
  • Airport names — 3-letter IATA codes resolved to full airport names and cities
  • Airline names — 2-letter codes resolved to full airline names
  • Booking class — Y, S, V, etc. mapped to cabin type (Economy, Business, First)
  • Booking status — HK (confirmed), HL (waitlisted), UC (unable to confirm)
  • Layover detection — for multi-sector flights, layover duration and overnight stops
  • Group bookings — multiple passengers with individual or shared segments

Multi-Sector and Complex Itineraries

The PNR parser handles complex routing that would take significant time to decode manually:

Multi-Sector PNR ExampleInput (Sabre format): 1.1KUMAR/VIKRAM MR 2.1KUMAR/ANITA MRS 1 AI 101Y 10MAR DELBOM HK2 0600 0815 2 AI 143Y 10MAR BOMGOI HK2 1030 1145 3 AI 882Y 17MAR GOIBOM HK2 1400 1520 4 6E 204Y 17MAR BOMDEL HK2 1900 2115 Parsed: Passengers : KUMAR/VIKRAM (MR), KUMAR/ANITA (MRS) Mar 10: DEL → BOM AI 101 06:00–08:15 Layover: 2h 15m at Mumbai BOM → GOI AI 143 10:30–11:45 Mar 17: GOI → BOM AI 882 14:00–15:20 Layover: 3h 40m at Mumbai BOM → DEL 6E 204 19:00–21:15 Trip: Delhi → Mumbai → Goa → Mumbai → Delhi Total Segments: 4 Total Passengers: 2
Tip
The parser automatically identifies connecting flights (same-day segments through a common airport) and marks them as layovers rather than separate trips. This helps build accurate itineraries with correct city-wise day counts.

The Generic PNR Parser: Beyond GDS

Not all flight information comes in GDS format. Travel agents often receive booking confirmations as:

  • Email confirmations from airlines or OTAs
  • WhatsApp messages from consolidators
  • Printed e-tickets (as photos or screenshots)
  • PDF booking confirmations

MoonTrip's Generic PNR Parser handles all of these. It uses AI to extract flight information from any free-form text or image:

Generic Parser — Free-Form TextInput (from an email): "Dear Agent, please find below the booking details: Passenger: Mr. Rajesh Sharma Flight: Air India AI-865 Date: 15th March 2026 Delhi to Mumbai Departure: 6:30 AM, Arrival: 8:40 AM PNR: ABC123 Status: Confirmed" Parsed: Passenger : SHARMA/RAJESH (MR) Flight : Air India AI 865 Date : 15 March 2026 Route : New Delhi (DEL) → Mumbai (BOM) Departure : 06:30 Arrival : 08:40 PNR : ABC123 Status : Confirmed
Generic Parser — WhatsApp Message from ConsolidatorInput (WhatsApp forward): "Bhai, booking done ✅ 2 pax — Mr. Vikram Mehta + Mrs. Anita Mehta IndiGo 6E-2045, 22 Mar, BLR-DEL, 14:30-17:15 Return: Vistara UK-834, 26 Mar, DEL-BLR, 09:00-11:45 PNR: XKFT72 Fare: 8500 per pax + taxes" Parsed: Passengers : MEHTA/VIKRAM (MR), MEHTA/ANITA (MRS) Segment 1 : IndiGo 6E 2045 · 22 Mar · Bengaluru (BLR) → Delhi (DEL) · 14:30–17:15 Segment 2 : Vistara UK 834 · 26 Mar · Delhi (DEL) → Bengaluru (BLR) · 09:00–11:45 PNR : XKFT72 Trip Type : Round Trip Pax Count : 2
Generic Parser — OTA Booking ConfirmationInput (MakeMyTrip / Cleartrip style confirmation): "Booking Confirmed — Order #MMT98234 Passenger(s): Ms. Sneha Gupta Flight 1: SpiceJet SG-145 12 Apr 2026 · Mumbai (BOM) → Goa (GOI) Departs: 07:20 AM · Arrives: 08:35 AM Flight 2: Air India AI-684 16 Apr 2026 · Goa (GOI) → Mumbai (BOM) Departs: 19:45 · Arrives: 21:00 Booking Ref: SG-ABCD12 / AI-WXYZ89 Status: Confirmed · E-ticket issued" Parsed: Passenger : GUPTA/SNEHA (MS) Segment 1 : SpiceJet SG 145 · 12 Apr · Mumbai (BOM) → Goa (GOI) · 07:20–08:35 Segment 2 : Air India AI 684 · 16 Apr · Goa (GOI) → Mumbai (BOM) · 19:45–21:00 PNR : SG-ABCD12 / AI-WXYZ89 Trip Type : Round Trip
Tip
The generic parser works with any text format — formal emails, casual WhatsApp messages, OTA confirmations, and even forwarded airline e-tickets. MoonTrip's database covers 187 airlines across all national, domestic, and international carriers — every IATA 2-letter code is resolved to the full airline name automatically.
MoonTrip generic PNR parser accepting free-form email text and image upload with AI-powered flight information extraction for travel agents
Generic parser — paste any text or upload an image, AI extracts the flight details

From PNR Text to Quote and Invoice

Once the PNR is parsed, the structured flight data auto-populates the quote builder. From there:

  • Flight line items are added automatically with airline, route, date, and timing
  • Pricing — add the base fare, airport taxes, and your service fee
  • Air GST — the system applies the correct 5% or 18% rate based on ticket type
  • HSN/SAC codes — 996411 for air transport services, auto-tagged
  • Invoice generationGST-compliant invoice with CGST/SGST or IGST split
  • Itinerary — flight details flow into the travel itinerary document
PNR → Invoice Line ItemParsed Flight: AI 865 · DEL→BOM · 15 Mar · 06:30–08:40 Quote Line Item: Description : Air India AI 865 — New Delhi to Mumbai Date : 15 March 2026 Base Fare : ₹5,000 Airport Taxes: ₹2,500 (YQ + PSF + UDF) Service Fee : ₹500 GST @18% : ₹90 (on service fee, Pure Agent) ─────────────────────────────────────────────── Line Total : ₹8,090
The MoonTrip Way
The entire flow — from pasting raw PNR text to having a GST-compliant invoice ready — takes under 30 seconds. No manual data entry, no code lookups, no calculator. The parser handles Amadeus, Sabre, Galileo, and any free-form text or image.

Stop calculating manually

MoonTrip automates GST, invoicing, and profit tracking for Indian travel agencies.

Get Started Free