Get Stay Booking
curl --request GET \
--url https://api.aisa.one/apis/v1/duffel/stays/bookings/{id} \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.aisa.one/apis/v1/duffel/stays/bookings/{id}"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.aisa.one/apis/v1/duffel/stays/bookings/{id}', 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.aisa.one/apis/v1/duffel/stays/bookings/{id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.aisa.one/apis/v1/duffel/stays/bookings/{id}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.aisa.one/apis/v1/duffel/stays/bookings/{id}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.aisa.one/apis/v1/duffel/stays/bookings/{id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"data": {
"accommodation": {
"amenities": [
{
"description": "Parking",
"type": "parking"
}
],
"brand": {
"id": "bra_0000Alr8BYNsbmDMThHSbI",
"name": "Duffel Test"
},
"chain": {
"id": "chn_0000Alr8BYNsbmDMThHSbI",
"name": "Accor Hotels"
},
"check_in_information": {
"check_in_after_time": "14:30",
"check_in_before_time": "00:00",
"check_out_before_time": "11:30"
},
"description": "Ornate quarters, some with grand pianos, in a luxurious hotel offering acclaimed dining & a spa.",
"email": "reservations@duffel-hotel-group.com",
"id": "acc_0000AWr2VsUNIF1Vl91xg0",
"key_collection": {
"instructions": "Please collect the keys from accommodation's reception."
},
"location": {
"address": {
"city_name": "London",
"country_code": "GB",
"line_one": "100 Clifton Street",
"postal_code": "EC2A 4TP",
"region": "England"
},
"geographic_coordinates": {
"latitude": 51.5071,
"longitude": -0.1416
}
},
"name": "Duffel Test Hotel",
"payment_instruction_supported": false,
"phone_number": "+442074938181",
"photos": [
{
"url": "https://assets.duffel.com/img/stays/image.jpg"
}
],
"rating": 3,
"ratings": [
{
"source": "priceline",
"value": 1
}
],
"review_count": 336,
"review_score": 8.8,
"rooms": [
{
"beds": [
{
"count": 2,
"type": "king"
}
],
"name": "Double Suite",
"photos": [
{
"url": "https://assets.duffel.com/img/stays/image.jpg"
}
],
"rates": [
{
"available_payment_methods": [
[
"balance"
]
],
"base_amount": "665.83",
"base_currency": "GBP",
"benefits": [
{
"description": "Daily full breakfast for up to two guests, served in the restaurant.",
"title": "Daily breakfast",
"type": "breakfast_included"
}
],
"board_type": "room_only",
"cancellation_timeline": [
{
"before": "2023-05-23T13:00:00Z",
"currency": "GBP",
"refund_amount": "799.00"
}
],
"code": "ABC",
"conditions": [
{
"description": "Public parking is available nearby for £15 per day",
"title": "Parking"
}
],
"deal_types": [
"closed_user_group",
"corporate",
"mobile"
],
"description": "Complimentary Breakfast 2Ppl, 100Usd Htl Crdt Person Stay Or Lcl Curr Equiv Or 100 Fb Crdt, Nxt Cat Upgrd Subj To Available.",
"due_at_accommodation_amount": "39.95",
"due_at_accommodation_currency": "GBP",
"estimated_commission_amount": "100.00",
"estimated_commission_currency": "GBP",
"expires_at": "2023-05-28T12:00:00Z",
"fee_amount": "50.94",
"fee_currency": "GBP",
"id": "rat_0000BTVRuKZTavzrZDJ4cb",
"loyalty_programme_required": false,
"name": "Best Available Rate",
"negotiated_rate_id": "nre_0000ATOwpuYnZohiSmlmyz",
"payment_instruction_allowed": true,
"payment_type": "pay_now",
"public_amount": "699.99",
"public_currency": "GBP",
"quantity_available": 12,
"source": "sabre",
"supported_loyalty_programme": "duffel_hotel_group_rewards",
"tax_amount": "82.23",
"tax_currency": "GBP",
"total_amount": "799.00",
"total_currency": "GBP"
}
]
}
],
"supported_loyalty_programme": "duffel_hotel_group_rewards"
},
"cancelled_at": null,
"check_in_date": "2023-05-24",
"check_out_date": "2023-05-28",
"confirmed_at": "2023-04-13T15:48:11.642Z",
"deposit_amount": "109.99",
"deposit_currency": "GBP",
"email": "amelia.earheart@duffel.com",
"estimated_commission_amount": "100.00",
"estimated_commission_currency": "GBP",
"guest_types": [
{
"age": 7,
"type": "adult"
}
],
"guests": [
{
"family_name": "Earhart",
"given_name": "Amelia",
"user_id": "icu_00009htyDGjIfajdNBZRlw"
}
],
"id": "bok_0000BTVRuKZTavzrZDJ4cb",
"loyalty_programme_account_number": "201154908",
"metadata": {
"checkout_reference": "usr_0000AePJGl5G9ZYfmNllrs"
},
"phone_number": "+442080160509",
"reference": "AFE33SE2",
"rooms": 1,
"status": "confirmed",
"supported_loyalty_programme": "duffel_hotel_group_rewards",
"users": [
"icu_00009htyDGjIfajdNBZRlw"
]
},
"meta": {
"after": "<string>",
"before": "<string>",
"limit": 123
}
}Duffel Stays
Get Stay Booking
Get Stay Booking via the Duffel Stays API
<!-- aisa-pricing:start -->
Published reference price: $0.005 USD per successful request. Account-specific pricing and final settlement may differ.
<!-- aisa-pricing:end -->
GET
https://api.aisa.one
/
apis
/
v1
/
duffel
/
stays
/
bookings
/
{id}
Get Stay Booking
curl --request GET \
--url https://api.aisa.one/apis/v1/duffel/stays/bookings/{id} \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.aisa.one/apis/v1/duffel/stays/bookings/{id}"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.aisa.one/apis/v1/duffel/stays/bookings/{id}', 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.aisa.one/apis/v1/duffel/stays/bookings/{id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.aisa.one/apis/v1/duffel/stays/bookings/{id}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.aisa.one/apis/v1/duffel/stays/bookings/{id}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.aisa.one/apis/v1/duffel/stays/bookings/{id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"data": {
"accommodation": {
"amenities": [
{
"description": "Parking",
"type": "parking"
}
],
"brand": {
"id": "bra_0000Alr8BYNsbmDMThHSbI",
"name": "Duffel Test"
},
"chain": {
"id": "chn_0000Alr8BYNsbmDMThHSbI",
"name": "Accor Hotels"
},
"check_in_information": {
"check_in_after_time": "14:30",
"check_in_before_time": "00:00",
"check_out_before_time": "11:30"
},
"description": "Ornate quarters, some with grand pianos, in a luxurious hotel offering acclaimed dining & a spa.",
"email": "reservations@duffel-hotel-group.com",
"id": "acc_0000AWr2VsUNIF1Vl91xg0",
"key_collection": {
"instructions": "Please collect the keys from accommodation's reception."
},
"location": {
"address": {
"city_name": "London",
"country_code": "GB",
"line_one": "100 Clifton Street",
"postal_code": "EC2A 4TP",
"region": "England"
},
"geographic_coordinates": {
"latitude": 51.5071,
"longitude": -0.1416
}
},
"name": "Duffel Test Hotel",
"payment_instruction_supported": false,
"phone_number": "+442074938181",
"photos": [
{
"url": "https://assets.duffel.com/img/stays/image.jpg"
}
],
"rating": 3,
"ratings": [
{
"source": "priceline",
"value": 1
}
],
"review_count": 336,
"review_score": 8.8,
"rooms": [
{
"beds": [
{
"count": 2,
"type": "king"
}
],
"name": "Double Suite",
"photos": [
{
"url": "https://assets.duffel.com/img/stays/image.jpg"
}
],
"rates": [
{
"available_payment_methods": [
[
"balance"
]
],
"base_amount": "665.83",
"base_currency": "GBP",
"benefits": [
{
"description": "Daily full breakfast for up to two guests, served in the restaurant.",
"title": "Daily breakfast",
"type": "breakfast_included"
}
],
"board_type": "room_only",
"cancellation_timeline": [
{
"before": "2023-05-23T13:00:00Z",
"currency": "GBP",
"refund_amount": "799.00"
}
],
"code": "ABC",
"conditions": [
{
"description": "Public parking is available nearby for £15 per day",
"title": "Parking"
}
],
"deal_types": [
"closed_user_group",
"corporate",
"mobile"
],
"description": "Complimentary Breakfast 2Ppl, 100Usd Htl Crdt Person Stay Or Lcl Curr Equiv Or 100 Fb Crdt, Nxt Cat Upgrd Subj To Available.",
"due_at_accommodation_amount": "39.95",
"due_at_accommodation_currency": "GBP",
"estimated_commission_amount": "100.00",
"estimated_commission_currency": "GBP",
"expires_at": "2023-05-28T12:00:00Z",
"fee_amount": "50.94",
"fee_currency": "GBP",
"id": "rat_0000BTVRuKZTavzrZDJ4cb",
"loyalty_programme_required": false,
"name": "Best Available Rate",
"negotiated_rate_id": "nre_0000ATOwpuYnZohiSmlmyz",
"payment_instruction_allowed": true,
"payment_type": "pay_now",
"public_amount": "699.99",
"public_currency": "GBP",
"quantity_available": 12,
"source": "sabre",
"supported_loyalty_programme": "duffel_hotel_group_rewards",
"tax_amount": "82.23",
"tax_currency": "GBP",
"total_amount": "799.00",
"total_currency": "GBP"
}
]
}
],
"supported_loyalty_programme": "duffel_hotel_group_rewards"
},
"cancelled_at": null,
"check_in_date": "2023-05-24",
"check_out_date": "2023-05-28",
"confirmed_at": "2023-04-13T15:48:11.642Z",
"deposit_amount": "109.99",
"deposit_currency": "GBP",
"email": "amelia.earheart@duffel.com",
"estimated_commission_amount": "100.00",
"estimated_commission_currency": "GBP",
"guest_types": [
{
"age": 7,
"type": "adult"
}
],
"guests": [
{
"family_name": "Earhart",
"given_name": "Amelia",
"user_id": "icu_00009htyDGjIfajdNBZRlw"
}
],
"id": "bok_0000BTVRuKZTavzrZDJ4cb",
"loyalty_programme_account_number": "201154908",
"metadata": {
"checkout_reference": "usr_0000AePJGl5G9ZYfmNllrs"
},
"phone_number": "+442080160509",
"reference": "AFE33SE2",
"rooms": 1,
"status": "confirmed",
"supported_loyalty_programme": "duffel_hotel_group_rewards",
"users": [
"icu_00009htyDGjIfajdNBZRlw"
]
},
"meta": {
"after": "<string>",
"before": "<string>",
"limit": 123
}
}Request contract
- Method and path: GET /apis/v1/duffel/stays/bookings/{id}
- Availability: enabled
- Request URL template: https://api.aisa.one/apis/v1/duffel/stays/bookings/{id}
- id: path; required
- Runtime facts: 0acde870f07f2a77c4e3530faf8814f82b10ee6286c4d80ef8b1fea08763f2ee
{
"operationId": "get_duffel_stays_apis_v1_duffel_stays_bookings_id",
"method": "GET",
"path": "/apis/v1/duffel/stays/bookings/{id}",
"servers": [
{
"url": "https://api.aisa.one"
}
],
"parameters": [
{
"in": "path",
"name": "id",
"required": true,
"schema": {
"type": "string"
}
}
],
"security": [
{
"bearerAuth": []
}
],
"x-aisa-status": "enabled",
"x-aisa-pricing": {
"cost_contract": "explicit_zero",
"customer_pricing": "fixed_success",
"default_request_estimate_usd": 0.005,
"estimate_source": "profile_seed",
"evidence_source": "request_snapshot"
},
"components": {
"securitySchemes": {
"bearerAuth": {
"scheme": "bearer",
"type": "http"
}
}
}
}
Cost and request rules
Published reference price: $0.005 USD per successful request. Account-specific pricing and final settlement may differ. Published reference values are not an account-specific quote or a settled charge. For endpoints supporting X-AISA-Cost-Mode: quote, obtain a free quote for your exact request before execution; reconcile the settled cost with response metadata and Usage Logs. USD amounts use 1,000,000 integer micro-USD per dollar.- Default request reference estimate (USD): 0.005
- Cost contract: explicit_zero
- Settlement evidence source: request_snapshot
Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.