Booking | Commit
Commit the request data which is made in previous steps.
Notice:
Product Scope : TechHub, FareMarket
2, AeroHub will perform availability checking everytime when this API is called.
3, Maximum response time is 30 seconds.
POST
/flight/booking
Parameter
Field | Mandatory | Type | Scope | Description |
---|---|---|---|---|
action | required |
String | Commit | |
key | required |
String | API security key applied from AeroHub | |
signature | required |
String | Refer to Guideline to generate. | |
timestamp | required |
Int | The ‘timestamp’ field should be a 10-digit Unix timestamp in seconds, used for encryption and data verification. | |
version | optional |
String | API version information, e.g. 3.0.0 | |
request | required |
Object | ||
sessionId | required |
String | SessionId: generated from AirPricing | |
timeout | optional |
String | Maximum response time setting, by seconds. e.g. 10 |
Request_Example:
{ "action": "Commit", "key": "51QEowqeQsRu2MK87xXYQa", "signature": "TIzve3ZOioewqeqABeaccv8x0GnOs/hlS4aAqHgSyAml0x0zM6Q5=", "timestamp": 1685116516, "request": { "sessionId": "78b53781fc514ffde1aee517b3673218", "timeout": 200 } }
Response
Field | Type | Description |
---|---|---|
status | int | 0 for success, others for failure, refer to status error appendix for details |
msg | String | Return message, maximum 64 char |
contentStatus | int | Return the original code from airlines or suppliers. |
contentMsg | String | Return the original message from airlines or suppliers, maximum 64 char |
balanceDue | Float | Amount to be paid |
isPriceChanged | Boolean | “Under development”; response price is changed comparing to AirPricing True: changed False: remain same. |
orderNum | String | Order number generated by Aerohub |
orderStatus | String | AeroHub Order status: TICKETED: ticketing success. refer orderStatus enum from Appendix |
pnr | String | TechHub: returns PNR information generated by airline. FareMarket: returns “ “, since tickets are ansync issued afterward . |
amount | Float | Total cost for payment |
currency | String | Currency information, 3_letter code e.g. USD |
originalAmount | Float | Total cost for payment |
originalCurrency | String | Currency information, 3_letter code e.g. USD |
Success-Response:
{ "status": 0, "msg": "success", "originalCurrency": "TWD", "originalAmount": 13320.00, "currency": "JPY", "amount": 59805.02, "balanceDue": 13320.00, "orderNum": "1684888866336538624", "pnr": "Y42NAN", "orderStatus": "NEED_PAYMENT", "isPriceChanged": false, "contentStatus": 0, "contentMsg": "success" }
Status Code
Name | Description |
---|---|
423 | Error returned by hub airline |
1000 | General system error |
1001 | Request parameters or part of parameters missing |
1002 | Invalid Action |
1003 | API request timeout, please request again |
1004 | Invalid request parameter |
1005 | Service system error |
1006 | System busy, please try again |
1040 | Traffic has exceeded daily limitation |
1101 | Authentication fail, wrong signature |
1102 | Account disabled, please contact with account administrator |
1201 | Insufficient balance in account (Commit after SetPaymentToBooking) |
2002 | No valid Journey in the session |
2003 | No passengers in the current session |
2012 | This flight is sold out (Commit with no payment set) |
2013 | Price is not available, please order again (Commit with payment set) |
Error-Response
{ "status": 1000, "msg": "Letslfy flight internal error" }
Author:admin Create time:2023-05-24 16:09
Last editor:AeroHub Update time:2024-09-10 16:26
Last editor:AeroHub Update time:2024-09-10 16:26