Add Ancillary
Add one or more ancillary services (e.g., meals, insurance) to an existing booking.
Endpoint
- URL:
/api/v1/flight/addancillary - 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 | Booking system code (e.g., VN, VJ, 1A) |
| airline | string | No | Airline code (IATA 2-letter, e.g., VN, VJ, AF) |
| bookingCode | string | Yes | Booking code (PNR) |
| services | array of ServiceInfo | Yes | List of ancillary services to add |
ServiceInfo Object
| Field | Type | Required | Description |
|---|---|---|---|
| quantity | integer | Yes | Number of units to add |
| ancillaryValue | string | Yes | Encoded ancillary value from getancillaries |
Example Request:
{
"system": "VN",
"airline": "VN",
"bookingCode": "ABC123",
"services": [
{
"quantity": 1,
"ancillaryValue": "eyJ2YWx1ZSI6ICJNRUFMIiwgInByaWNlIjogMTUwMDAwfQ=="
}
]
}
Request Constraints & Business Rules
bookingCodemust refer to an existing, valid booking.servicesmust useancillaryValuefrom a valid getancillaries response.- Only available ancillaries for the flight/route can be added.
- Some ancillaries may have quantity or time restrictions.
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 |
Example Response:
{
"system": "VN",
"status": true,
"error": null,
"description": null,
"trackingId": "abc123",
"trackingTime": "2025-07-01T07:00:00.000Z"
}
Error Codes
See Error Codes for details on possible error responses.
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
ancillaryValueandbookingCode.
Validation Questions
- Are there limits on the number or type of ancillaries that can be added per booking?
- Is there a time window before departure when ancillaries can no longer be added?
For integration support, see Contact Support.