---
# System prepended metadata

title: Flight Book

---

---
title : Flight Book
description : digunakan untuk melakukan booking tiket
---

Flight Book
===

[TOC]
#### Endpoint
> https://api-dev.fastravel.co.id/flight/book

#### Request
```
{
    "airline": "TPJT",
    "departure": "CGK",
    "arrival": "DPS",
    "departureDate": "2020-08-28",
    "returnDate": "2020-08-28",
    "adult": 1,
    "child": 0,
    "infant": 0,
    "flights": [
        "9;M0_C0_F0_S18;V;558600;07:00;lion-with-tpjts;;2020-08-28;04:10;07:00;JT34;CGK;DPS"
    ],
    "buyer": "",
    "passengers": {
        "adults": [
            "ADT;MR;REZA;ISHAQ;11/22/1988;763243434334;::623187762;::6285655141006;;;;;KTP;ID"
        ]
    },
    "token": "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiIsImp0aSI6IjhkNzNtbmc4OWVkIn0.eyJpc3MiOiJodHRwOlwvXC9hcGkuZmFzdHJhdmVsLmNvLmlkIiwiYXVkIjoiRmFzdHJhdmVsQjJCIENsaWVudCIsImp0aSI6IjhkNzNtbmc4OWVkIiwiaWF0IjoxNTk1NjA3NjA1LCJuYmYiOjE1OTU2MDc2NjQsImV4cCI6MTU5NTYxMTIwNCwib3V0bGV0SWQiOiJISDEzNDgzIiwicGluIjoiOTQwNTQ2Iiwia2V5IjoiRkFTVFBBWSJ9.Dh1srT_Z06Z2aymnt-SWLkelt5JfZ7zN9B6Av1h2NBc"
}
```

#### Response 
##### Normal Response
```
{
    "data": {
        "passengers": "ADT;MR;REZA ISHAQ ;763243434334|",
        "details": "XYALDP;2020-07-27;01-Aug-2020 23:59;-|#ADT;MR;REZA ISHAQ ;763243434334|#28-Agustus-2020;JT34;04:10;07:00;BOOKED;CGK;DPS|#546500;;558600;546500|#;lion",
        "bookingCode": "XYALDP",
        "paymentCode": "",
        "flightCode1": "JT34",
        "departureTime1": "04:10",
        "arrivalTime1": "07:00",
        "reservationDate": "27-Jul-2020",
        "timeLimit": "01-Agu-2020 23:59",
        "timeLimitYMD": "2020-08-01 23:59",
        "flightInfoGo": "2020-08-28",
        "nominal": "558600",
        "comission": "0",
        "nominalAdmin": "0",
        "transactionId": "1869458652",
        "komisi": 0
    },
    "rc": "00",
    "rd": "Success",
    "mid": "4221369504",
    "invoking": "Book Flight",
    "processingTime": "61.073297977448 Second"
}
```

##### Negative Response
```
{
    "rc": "23",
    "rd": "Booking Gagal. Terdapat data yang tidak sesuai, silahkan melakukan proses pencarian jadwal kembali.",
    "mid": "4222408141",
    "invoking": "Book Flight",
    "processingTime": "0.18353295326233 Second"
}
```