Get Baggages
Retrieve available baggage options for a selected flight.
Endpoint
- URL:
/api/v1/flight/getbaggages - Method:
POST - Auth Required: Yes (Bearer Token/X-api-key)
- Content-Type:
application/json
Authentication
This endpoint requires a valid JWT Bearer token in the Authorization header:
Authorization: Bearer <access_token>
Obtain tokens via /api/v1/sign-in (POST) with your credentials.
Request Structure
| Field | Type | Required | Description |
|---|---|---|---|
| system | string | Yes | System code (e.g., VN, VJ, 1A) |
| flightValue | string | Yes | Encoded flight value from Search Result |
| airline | string | No | Airline code (IATA 2-letter, e.g., VN, VJ, AF) |
Sample Request:
{
"system": "VN",
"flightValue": "eyJmYXJlRGF0YUlkIjoxLCJvcHRpb25JZCI6MCwiZmxpZ2h0SWQiOjAsImxlZyI6MCwiYWlybGluZSI6IlZOIiwg...",
"airline": "VN"
}
Request Constraints & Business Rules
- Before booking,
systemandflightValuemust match the values from the Search Flight response. - After booking or after ticket issuance, use the latest
flightValuefrom the Retrieve Booking response. This ensures the most up-to-date and valid flight context. - Do not reuse an old
flightValueif the booking itinerary has changed. airlinemust be a valid IATA code for the selected flight.- Only available after a successful flight search.
Response Structure
| Field | Type | Nullable | Description |
|---|---|---|---|
| system | string | Yes | Name of the airline system |
| status | boolean | No | true if successful, false if failed |
| error | ErrorCode (object) | Yes | Error details (if any) |
| description | string | Yes | Error description (if any) |
| trackingId | string | Yes | Tracking ID for request logs |
| trackingTime | string (date-time) | Yes | Time for request tracking |
| baggages | array of Baggage | Yes | List of available baggage options |
Baggage Object
| Field | Type | Nullable | Description |
|---|---|---|---|
| code | string | Yes | Baggage code |
| name | string | Yes | Baggage name (e.g., 25kg, 30kg) |
| route | string | Yes | Route the baggage applies to (e.g., HANSGN) |
| prices | array of PriceBaggageType | Yes | Price details for each passenger type |
PriceBaggageType Object
| Field | Type | Nullable | Description |
|---|---|---|---|
| passengerId | string | Yes | Passenger ID (for post-booking queries) |
| passengerType | string | Yes | Passenger type (ADT, CHD, INF) |
| price | number | No | Total price for this passenger type |
| currency | string | Yes | Currency (e.g., VND, USD) |
| value | string | Yes | Encoded baggage value |
Sample Response
{
"system": "VN",
"ancillaries": [],
"baggages": [
{
"code": "ABAG",
"name": "23KG",
"route": "SGNDAD",
"prices": [
{
"passengerId": "0",
"passengerType": "ADT",
"price": 324000,
"currency": "VND",
"value": "/GOg904J3bYNoyfIH+INiseAoQoA/JwZSEV38KxOzNJY1/q+1y1UnsrnH3A..."
}
]
}
],
"status": true,
"error": null,
"description": null,
"trackingId": "abc123",
"trackingTime": "2025-07-01T08:18:01.2638496+00:00"
}
Baggage & Price Structure
- Each baggage option represents an add-on (e.g., 25kg, 30kg) that can be purchased for the selected flight.
- The
pricesarray lists the cost for each passenger type (ADT, CHD, INF). Thevaluefield is an encoded object used for subsequent booking or add-baggage requests.
Error Codes
This endpoint may return the following error codes:
- 21000 - Baggage: Errors specific to baggage operations (21000-21004)
- 00000 - Flight Hub (General Errors): General system and authentication errors (00001-00056)
For a complete list of error codes, see Error Codes.
Security & Validation
- All input is validated for type and required fields.
- Only authenticated users can access this endpoint.
- The endpoint is protected against tampering with
flightValueandairline.
Validation Questions
- Are there any restrictions on which baggage options can be combined?
- Is the
valuefield always required for subsequent add-baggage requests? - Are there time limits for when baggage can be added before departure?
For integration support, see Contact Support.