Skip to main content

AmendBookingPaxes

Overview​

The AmendBookingPaxes operation allows clients to modify the passenger (pax) information of an existing booking. This operation uses the client and supplier locators to identify the reservation and processes updates to guest details including names, ages, titles, and the composition of the traveling party.

The AmendBookingPaxes operation ensures:

  • Passenger Information Updates: Enables clients to correct or update guest names, ages, titles, and personal details.
  • Occupancy Modification: Allows changes to the number of passengers per room, accommodating party composition changes.
  • Age-Based Pricing: Automatically recalculates pricing when passenger ages change (e.g., adding children or infants).
  • Status Confirmation: Confirms the success or failure of the paxes amendment request.

When to Use:

  • Name Corrections: When guest names were entered incorrectly or need to match passport/ID information.
  • Party Composition Changes: When travelers are added or removed from the booking.
  • Age Updates: When passenger ages need correction to ensure proper pricing (adult vs. child rates).

Note: Some suppliers have strict policies regarding passenger changes. Adding or removing passengers may affect pricing and availability. Always verify the new occupancy configuration is valid for the booked rooms.

Common Scenarios:

  • Name Spelling Corrections: Fixing typos or updating names to match travel documents.
  • Adding Infants: Adding a baby to the booking without requiring an additional room.
  • Party Changes: Replacing one guest with another while maintaining the same occupancy count.
  • Title Updates: Correcting personal titles (Mr, Mrs, Ms, etc.) for formal documentation.
  • Error Handling: Common errors include:
    • BookingNotFound: Indicates the booking cannot be located with the provided locators.
    • MandatoryFieldMissing: Required passenger information (name, surname, age) is missing.
    • SupplierError: Indicates the amendment could not be processed by the supplier.

Request​

Overview​

The request operation includes the updated passenger information with occupancies, booking references, and any additional data required by the supplier.

Sample​

var amendBookingPaxesRq = new AmendBookingPaxesRq
{
Input = new AmendPaxesInput
{
Reference = new Reference
{
ClientReference = "CLIENT123456",
SupplierReference = "SUPPLIER789"
},
Occupancies = new List<AmendOccupancy>
{
new AmendOccupancy
{
OccupancyId = 1,
Paxes = new List<BookPaxInput>
{
new BookPaxInput
{
Age = 30,
Name = "John",
SurName = "Smith",
PersonalTitleType = PersonalTitleType.MR,
DateOfBirth = "1994-05-15"
},
new BookPaxInput
{
Age = 28,
Name = "Jane",
SurName = "Smith",
PersonalTitleType = PersonalTitleType.MRS,
DateOfBirth = "1996-08-22"
},
new BookPaxInput
{
Age = 0,
Name = "Baby",
SurName = "Smith",
PersonalTitleType = PersonalTitleType.NOT_SPECIFIED,
DateOfBirth = "2024-01-10"
}
}
}
},
PaymentType = PaymentType.Merchant,
PaymentCardInput = null
},
Settings = new Settings
{
Supplier = "HOTELTEST",
Platform = "HOTELTEST",
Client = "TravelAgency123",
Access = new Access
{
Code = 1001,
User = "agency_user",
Password = "secure_password",
ApiKey = "API_KEY_123456789",
Urls = new Urls
{
Book = "https://api.hotelsupplier.com/book",
Search = "https://api.hotelsupplier.com/search",
Quote = "https://api.hotelsupplier.com/quote",
Cancel = "https://api.hotelsupplier.com/cancel",
CheckBookings = "https://api.hotelsupplier.com/check",
AmendBookingBoard = "https://api.hotelsupplier.com/amend/board",
AmendBookingDates = "https://api.hotelsupplier.com/amend/dates",
AmendBookingPaxes = "https://api.hotelsupplier.com/amend/paxes",
AmendBookingRemarks = "https://api.hotelsupplier.com/amend/remarks",
AmendBookingRooms = "https://api.hotelsupplier.com/amend/rooms"
},
Parameters = new Dictionary<string, string>
{
{ "someParameter1", "50" },
{ "someParameter2", "true" },
{ "someParameter3", "5000" },
{ "someParameter4", "SupplierX" }
}
},
BusinessRules = new BusinessRules
{
OptionsQuota = 170,
BusinessRuleType = "CheaperAmount"
},
Timeout = "00:00:10",
TimeoutAsTimeSpan = TimeSpan.Parse("00:00:10"),
IncludeProviderTransactions = false
}
};

Details​

NameRelationTypeDescription
Input1AmendPaxesInputInput data for the paxes amendment operation.
Input/Reference1ReferenceBooking references for the amendment.
Input/Reference/
ClientReference
1StringThe client's internal reference for the booking.
Input/Reference/
SupplierReference
1StringThe supplier's reference for the booking.
Input/Occupancies1 . . NArray<AmendOccupancy>The updated occupancy information with new passenger details.
Input/Occupancies/OccupancyId1IntegerThe unique identifier for the occupancy being updated.
Input/Occupancies/Paxes1 . . NArray<BookPaxInput>The list of passengers in this occupancy.
Input/Occupancies/Paxes/Age1IntegerThe age of the passenger.
Input/Occupancies/Paxes/Name1StringThe first name of the passenger.
Input/Occupancies/Paxes/SurName1StringThe surname (last name) of the passenger.
Input/Occupancies/Paxes/
PersonalTitleType
0 . . 1PersonalTitleTypeThe personal title of the passenger (e.g., MR, MRS, MS, MISS, NOT_SPECIFIED).
Input/Occupancies/Paxes/
DateOfBirth
0 . . 1StringDate of birth of the passenger, represented as a string in ISO 8601 format (YYYY-MM-DD).
Input/Occupancies/Paxes/
IdentificationDocuments
0 . . NArray<IdentificationDocument>Identification documents for the passenger (e.g., passport, ID card).
Input/PaymentType0 . . 1PaymentTypePayment type for the booking (e.g., Merchant, Direct). Optional - only required if the supplier needs payment details for the amendment.
Input/PaymentCardInput0 . . 1CreditCardInputPayment card details, if applicable. Optional - only required if PaymentType is specified and card details are needed.
Settings1SettingsSettings for the amendment operation.
Settings/Supplier1StringThe identifier for the supplier in the TravelgateX platform.
Settings/Platform1StringThe platform hosting the supplier's services.
Settings/Client1StringThe client code requesting the operation.
Settings/Access1AccessAuthentication and endpoint configuration.
Settings/Access/Code1IntegerAccess code for authentication.
Settings/Access/User0 . . 1StringUsername for authentication.
Settings/Access/Password0 . . 1StringPassword for authentication.
Settings/Access/ApiKey0 . . 1StringAPI key for authentication.
Settings/Access/Urls1UrlsURLs for different operations.
Settings/Access/Parameters0 . . 1AccessParametersAdditional parameters related to the connection.
Settings/BusinessRules0 . . 1BusinessRulesSpecifies the business rules to be applied during the operation. These rules define operational constraints and behavior, such as quota limits or prioritization criteria.
Settings/BusinessRules/
OptionsQuota
0 . . 1IntegerThe maximum number of options returned for each board in the Search query.
Settings/BusinessRules/
BusinessRuleType
1BusinessRulesTypeThe business rule type that determines how Search results are prioritized or filtered.
Settings/Timeout1StringDefines the timeout period for the operation as a string value.This indicates the maximum amount of time to wait for a supplier's response before timing out.The value must be provided in timestamp format (e.g., "00:00:10" for 10 seconds).
Settings/TimeoutAsTimeSpan0 . . 1StringConverts the timeout value from the string representation (Timeout) into a TimeSpan for use in time-based operations.
Settings/
IncludeProviderTransactions
1BooleanIndicates whether detailed traces of provider transactions should be included in the operation's response. If enabled, the ProviderAudit field in responses will contain the transaction logs (e.g., requests and responses exchanged with the supplier).

Response​

Provides the amendment status, updated booking details with the new passenger information, pricing information, and any warnings or remarks.

Overview​

The AmendBookingPaxes operation provides:

  • Amendment Status:
    • Ok: The passenger amendment has been successfully processed.
    • OnRequest: The amendment request is pending supplier confirmation.
    • Unknown: The amendment status is unknown and requires verification with the supplier.
  • Updated Booking Details: Returns the booking information with the updated passenger details and any impact on pricing.
  • Warnings or Remarks: Additional details from the supplier about the amendment process.

Sample​

var amendRs = new AmendRs
{
AuditData = new AuditData
{
Request = new List<RequestItem>
{
new RequestItem
{
Data = "<x>SupplierRequest</x>",
Headers = new Dictionary<string, string>
{
{ "Accept", "application/x-protobuf" },
{ "Accept-Encoding", "gzip,deflate," }
},
HttpMethod = new HttpMethodType
{
Method = "POST"
},
SendAt = DateTime.Parse("2024-07-10T08:21:49Z"),
Url = "http://travelgate.com"
}
},
Response = new List<ResponseItem>
{
new ResponseItem
{
Data = "<x>SupplierResponse</x>",
Headers = new Dictionary<string, string>
{
{ "Content-Encoding", "gzip," }
},
HttpMethod = new HttpMethodType
{
Method = "POST"
},
ReceivedAt = DateTime.Parse("2024-07-10T08:21:49Z"),
StatusCode = 200
}
}
},
BookDetails = new List<BookDetails>
{
new BookDetails
{
Status = BookStatus.Ok,
Reference = new Reference
{
ClientReference = "CLIENT123456",
SupplierReference = "SUPPLIER789"
},
Holder = new Holder
{
Name = "John",
SurName = "Smith"
},
Price = Price.BuildNetPrice(Currency.EUR, 450.00, 450.00),
Hotel = new HotelDetail
{
Code = "HOTEL001",
Name = "Grand Plaza Hotel",
CheckIn = DateTime.Parse("2024-07-10"),
CheckOut = DateTime.Parse("2024-07-15"),
BoardCode = "BB",
Occupancies = new List<BookOccupancy>
{
new BookOccupancy
{
OccupancyId = 1,
Paxes = new List<BookPax>
{
new BookPax
{
Age = 30,
Name = "John",
SurName = "Smith",
PersonalTitleType = PersonalTitleType.MR,
DateOfBirth = DateTime.Parse("1994-05-15")
},
new BookPax
{
Age = 28,
Name = "Jane",
SurName = "Smith",
PersonalTitleType = PersonalTitleType.MRS,
DateOfBirth = DateTime.Parse("1996-08-22")
},
new BookPax
{
Age = 0,
Name = "Baby",
SurName = "Smith",
PersonalTitleType = PersonalTitleType.NOT_SPECIFIED,
DateOfBirth = DateTime.Parse("2024-01-10")
}
}
}
},
Rooms = new List<Room>
{
new Room
{
OccupancyRefId = 1,
Code = "DBL",
Description = "Double Room",
RoomPrice = new RoomPrice
{
Price = Price.BuildNetPrice(Currency.EUR, 450.00, 450.00)
}
}
}
},
CancelPolicy = new OptionCancelPolicy
{
Refundable = true,
CancelPenalties = new List<CancelPenalty>
{
new CancelPenalty
{
HoursBefore = 24,
Type = PenaltyType.Percent,
Value = 100
}
}
}
}
}
};

Details​

NameRelationTypeDescription
BookDetails1BookDetailsThe updated booking details after the paxes amendment.
BookDetails/Status1StringStatus of the amended booking (e.g., "OK", "KO", "PENDING").
BookDetails/Reference1ReferenceReferences for the booking.
BookDetails/Reference/
ClientReference
1StringThe client's internal reference for the booking.
BookDetails/Reference/
SupplierReference
1StringThe supplier's reference for the booking.
BookDetails/Holder1HolderPrimary guest information (typically the first passenger).
BookDetails/Holder/Name1StringFirst name of the primary guest.
BookDetails/Holder/SurName1StringSurname of the primary guest.
BookDetails/Hotel1HotelDetailHotel booking information.
BookDetails/Hotel/CheckIn1StringThe check-in date in ISO 8601 format (YYYY-MM-DD).
BookDetails/Hotel/CheckOut1StringThe check-out date in ISO 8601 format (YYYY-MM-DD).
BookDetails/Hotel/Code1StringHotel code.
BookDetails/Hotel/Name0 . . 1StringHotel name.
BookDetails/Hotel/BoardCode1StringBoard/meal plan code.
BookDetails/Hotel/Occupancies1 . . NArray<BookOccupancy>The updated occupancy information with new passenger details.
BookDetails/Hotel/Rooms1 . . NArray<Room>Room information for the booking.
BookDetails/Price1PricePricing information for the booking.
BookDetails/Price/Currency1StringCurrency code (e.g., "EUR", "USD").
BookDetails/Price/Binding1BooleanIndicates if the price is binding.
BookDetails/Price/Net1DoubleNet price.
BookDetails/Price/Gross1DoubleGross price.
BookDetails/Price/
MinimumSellingPrice
1DoubleMinimum selling price.
BookDetails/CancelPolicy0 . . 1CancelPolicyCancellation policy for the amended booking.
ProviderAudit0 . . 1ProviderAuditProvider transaction logs if IncludeProviderTransactions is enabled.