Confirm a TripJack held booking
curl --request POST \
--url https://api-sandbox.unifystays.com/hotels/book/{booking_id}/confirm-hold \
--header 'Content-Type: application/json' \
--header 'x-api-key: <api-key>' \
--data '
{
"accepted_offer_id": "<string>"
}
'import requests
url = "https://api-sandbox.unifystays.com/hotels/book/{booking_id}/confirm-hold"
payload = { "accepted_offer_id": "<string>" }
headers = {
"x-api-key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'x-api-key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({accepted_offer_id: '<string>'})
};
fetch('https://api-sandbox.unifystays.com/hotels/book/{booking_id}/confirm-hold', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api-sandbox.unifystays.com/hotels/book/{booking_id}/confirm-hold",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'accepted_offer_id' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"x-api-key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api-sandbox.unifystays.com/hotels/book/{booking_id}/confirm-hold"
payload := strings.NewReader("{\n \"accepted_offer_id\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("x-api-key", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api-sandbox.unifystays.com/hotels/book/{booking_id}/confirm-hold")
.header("x-api-key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"accepted_offer_id\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api-sandbox.unifystays.com/hotels/book/{booking_id}/confirm-hold")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["x-api-key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"accepted_offer_id\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"contract_version": "1",
"success": true,
"message": "Booking request accepted and is being processed.",
"data": {
"booking_id": "ubk_eGQ0dW9uV1Vi",
"accepted_offer_id": "off_01J...",
"status": "PROCESSING",
"is_terminal": false,
"provider": {
"code": "TBO",
"booking_id": "100055869",
"booking_code": "REZ6A5A81E9",
"hotel_confirmation_number": "HCN-482910",
"hotel_confirmation_status": "Confirmed",
"hotel_confirmation_note": {},
"hotel_contact_phone": {},
"hotel_contact_name": {}
},
"next_poll_after_ms": 5000,
"processing_reason": "SUPPLIER_CONFIRMATION_PENDING",
"action_required": true,
"available_actions": [
"GET_STATUS"
],
"hold_deadline_at": "<string>",
"created_at": "2026-04-15T12:12:11.000Z",
"updated_at": "2026-04-15T12:12:11.000Z"
}
}Bookings
Confirm Hold
Confirm a TripJack held booking before its supplier deadline.
POST
/
hotels
/
book
/
{booking_id}
/
confirm-hold
Confirm a TripJack held booking
curl --request POST \
--url https://api-sandbox.unifystays.com/hotels/book/{booking_id}/confirm-hold \
--header 'Content-Type: application/json' \
--header 'x-api-key: <api-key>' \
--data '
{
"accepted_offer_id": "<string>"
}
'import requests
url = "https://api-sandbox.unifystays.com/hotels/book/{booking_id}/confirm-hold"
payload = { "accepted_offer_id": "<string>" }
headers = {
"x-api-key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'x-api-key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({accepted_offer_id: '<string>'})
};
fetch('https://api-sandbox.unifystays.com/hotels/book/{booking_id}/confirm-hold', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api-sandbox.unifystays.com/hotels/book/{booking_id}/confirm-hold",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'accepted_offer_id' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"x-api-key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api-sandbox.unifystays.com/hotels/book/{booking_id}/confirm-hold"
payload := strings.NewReader("{\n \"accepted_offer_id\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("x-api-key", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api-sandbox.unifystays.com/hotels/book/{booking_id}/confirm-hold")
.header("x-api-key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"accepted_offer_id\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api-sandbox.unifystays.com/hotels/book/{booking_id}/confirm-hold")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["x-api-key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"accepted_offer_id\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"contract_version": "1",
"success": true,
"message": "Booking request accepted and is being processed.",
"data": {
"booking_id": "ubk_eGQ0dW9uV1Vi",
"accepted_offer_id": "off_01J...",
"status": "PROCESSING",
"is_terminal": false,
"provider": {
"code": "TBO",
"booking_id": "100055869",
"booking_code": "REZ6A5A81E9",
"hotel_confirmation_number": "HCN-482910",
"hotel_confirmation_status": "Confirmed",
"hotel_confirmation_note": {},
"hotel_contact_phone": {},
"hotel_contact_name": {}
},
"next_poll_after_ms": 5000,
"processing_reason": "SUPPLIER_CONFIRMATION_PENDING",
"action_required": true,
"available_actions": [
"GET_STATUS"
],
"hold_deadline_at": "<string>",
"created_at": "2026-04-15T12:12:11.000Z",
"updated_at": "2026-04-15T12:12:11.000Z"
}
}This action exists only for TripJack offers whose prebook lifecycle contains
available_booking_modes: ["INSTANT", "HOLD"]. Create the booking with
booking_mode: "HOLD", then call this endpoint when booking status is
ON_HOLD and available_actions contains CONFIRM_HOLD.
Send the booking’s exact accepted_offer_id. Confirmation uses the supplier
amount already bound to the accepted offer. Confirm before hold_deadline_at;
TripJack may automatically cancel an unconfirmed hold after that deadline.
This follows TripJack Hotel API v3: omitting paymentInfos creates the hold,
and /oms/v3/hotel/confirm-book confirms it before the review response’s
deadline. See the TripJack API documentation.Authorizations
Environment-specific API key created in the Unifystays portal
Headers
Hotel API contract version. Missing defaults to v1.
Available options:
1 Path Parameters
Body
application/json
The accepted offer ID stored with this held booking. Prevents confirming a different revision accidentally.