This operation allows you to cancel a previously confirmed reservation. You can use either the clientConfirmationCode or htConfirmationCode to submit a cancellation request.
See the DOCS tab on the Reservation GraphQL Docs for detailed information about the type definitions.
Schema
mutation cancel($Cancel: CancelRequestInput) {
cancel(cancelRequest: $Cancel) {
htConfirmationCode
clientConfirmationCode
allRoomsCancelled
rooms {
htRoomConfirmationCode
clientRoomConfirmationCode
cancelled
currency
cancellationDate
}
}
}
Request
Using htConfirmationCode
{
"Cancel": {
"htConfirmationCode": "HT-MOKVKY"
}
}
Using clientConfirmationCode
{
"Cancel": {
"clientConfirmationCode": "ProdTestReservation1001252"
}
}
Response
For more information on the list of error codes, see the Error Codes page.
Single Room
{
"data": {
"cancel": {
"htConfirmationCode": "HT-MOKVKY",
"clientConfirmationCode": "ProdTestReservation1001252",
"allRoomsCancelled": true,
"rooms": [
{
"htRoomConfirmationCode": "HT-MOKVKY-1",
"clientRoomConfirmationCode": "ProdTestReservation1001252-1",
"cancelled": true,
"cancellationDate": "2025-01-10T12:08:00.000-0500",
"cancellationAmount": 0.00,
"currency": "USD"
}
]
}
}
}
Multi-Room
{
"data": {
"cancel": {
"htConfirmationCode": "HT-VFBLEY",
"clientConfirmationCode": "tc-test-1406",
"allRoomsCancelled": true,
"rooms": [
{
"htRoomConfirmationCode": "HT-VFBLEY-1",
"clientRoomConfirmationCode": "tc-test-1406-1",
"cancelled": true,
"cancellationDate": "2023-06-19T10:31:10.000-0400",
"currency": "USD",
"cancellationAmount": 115.05
},
{
"htRoomConfirmationCode": "HT-VFBLEY-2",
"clientRoomConfirmationCode": "tc-test-1406-2",
"cancelled": true,
"cancellationDate": "2023-06-19T10:31:10.000-0400",
"currency": "USD",
"cancellationAmount": 115.05
}
]
}
}
}
Error
{
"errors": [
{
"message": "Reservation not found",
"extensions": {
"errorCode": 1602
}
}
],
"data": {
"cancel": null
}
}