curl --request POST \
--url https://api.anysite.io/api/hostelworld/properties \
--header 'Content-Type: application/json' \
--header 'access-token: <api-key>' \
--data '
{
"property": "<string>",
"timeout": 300
}
'import requests
url = "https://api.anysite.io/api/hostelworld/properties"
payload = {
"property": "<string>",
"timeout": 300
}
headers = {
"access-token": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'access-token': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({property: '<string>', timeout: 300})
};
fetch('https://api.anysite.io/api/hostelworld/properties', 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.anysite.io/api/hostelworld/properties",
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([
'property' => '<string>',
'timeout' => 300
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"access-token: <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.anysite.io/api/hostelworld/properties"
payload := strings.NewReader("{\n \"property\": \"<string>\",\n \"timeout\": 300\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("access-token", "<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.anysite.io/api/hostelworld/properties")
.header("access-token", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"property\": \"<string>\",\n \"timeout\": 300\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.anysite.io/api/hostelworld/properties")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["access-token"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"property\": \"<string>\",\n \"timeout\": 300\n}"
response = http.request(request)
puts response.read_body[
{
"id": "<string>",
"@type": "HostelworldProperty",
"url": "<string>",
"name": "<string>",
"property_type": "<string>",
"hostelworld_says": "<string>",
"directions": "<string>",
"house_rules": "<string>",
"star_rating": 123,
"is_new": true,
"is_featured": true,
"is_promoted": true,
"is_hostelworld_recommended": true,
"best_for": [],
"policies": [],
"sustainability_levels": [],
"currency": "<string>",
"business_number": "<string>",
"address": "<string>",
"city": {
"@type": "HostelworldCity",
"id": "<string>",
"name": "<string>",
"country": "<string>"
},
"region": "<string>",
"latitude": 123,
"longitude": 123,
"distance_from_center_km": 123,
"distance_from_center_miles": 123,
"review_count": 123,
"rating": {
"@type": "HostelworldRating",
"overall": 123,
"value": 123,
"security": 123,
"location": 123,
"staff": 123,
"atmosphere": 123,
"cleanliness": 123,
"facilities": 123
},
"deposit_percentage": 123,
"max_guests_per_booking": 123,
"check_in_from": "<string>",
"check_in_until": "<string>",
"latest_checkout": "<string>",
"has_free_cancellation": true,
"free_cancellation_days": 123,
"cancellation_policy": {
"@type": "HostelworldPropertyCancellationPolicy",
"deposit_only": {
"@type": "HostelworldCancellationSubPolicy",
"days": 123
},
"non_refundable": {
"@type": "HostelworldCancellationSubPolicy",
"days": 123
},
"free_cancellation": {
"@type": "HostelworldCancellationSubPolicy",
"days": 123
}
},
"is_tax_included": true,
"taxes": [],
"is_fee_included": true,
"fees": [],
"group_info": {
"@type": "HostelworldGroupInfo",
"additional_terms": "<string>",
"cancellation_terms": "<string>",
"group_terms": "<string>",
"remainder_due": "<string>",
"group_max_pax": 123,
"group_types": [],
"age_ranges": []
},
"facilities": [],
"images": [],
"videos": [],
"payment_methods": [],
"awards": []
}
]{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}/hostelworld/properties
Get full Hostelworld property details by property id (or property URL): name, type (hostel/hotel/B&B), description, editorial overview, what the property is best for, directions, address, city, region, coordinates, distance from city centre, rating breakdown (overall, value, security, location, staff, atmosphere, cleanliness, facilities), review count, facilities by category, policies, sustainability levels, group-booking terms, photos, videos, payment methods, check-in window, cancellation policy (deposit-only, non-refundable and free-cancellation terms), tax and fee details, deposit, Hoscar awards and house rules.
Price: 1 credit
⚠️ Common errors: 412: Property not found (well-formed but nonexistent property id)
curl --request POST \
--url https://api.anysite.io/api/hostelworld/properties \
--header 'Content-Type: application/json' \
--header 'access-token: <api-key>' \
--data '
{
"property": "<string>",
"timeout": 300
}
'import requests
url = "https://api.anysite.io/api/hostelworld/properties"
payload = {
"property": "<string>",
"timeout": 300
}
headers = {
"access-token": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'access-token': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({property: '<string>', timeout: 300})
};
fetch('https://api.anysite.io/api/hostelworld/properties', 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.anysite.io/api/hostelworld/properties",
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([
'property' => '<string>',
'timeout' => 300
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"access-token: <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.anysite.io/api/hostelworld/properties"
payload := strings.NewReader("{\n \"property\": \"<string>\",\n \"timeout\": 300\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("access-token", "<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.anysite.io/api/hostelworld/properties")
.header("access-token", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"property\": \"<string>\",\n \"timeout\": 300\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.anysite.io/api/hostelworld/properties")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["access-token"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"property\": \"<string>\",\n \"timeout\": 300\n}"
response = http.request(request)
puts response.read_body[
{
"id": "<string>",
"@type": "HostelworldProperty",
"url": "<string>",
"name": "<string>",
"property_type": "<string>",
"hostelworld_says": "<string>",
"directions": "<string>",
"house_rules": "<string>",
"star_rating": 123,
"is_new": true,
"is_featured": true,
"is_promoted": true,
"is_hostelworld_recommended": true,
"best_for": [],
"policies": [],
"sustainability_levels": [],
"currency": "<string>",
"business_number": "<string>",
"address": "<string>",
"city": {
"@type": "HostelworldCity",
"id": "<string>",
"name": "<string>",
"country": "<string>"
},
"region": "<string>",
"latitude": 123,
"longitude": 123,
"distance_from_center_km": 123,
"distance_from_center_miles": 123,
"review_count": 123,
"rating": {
"@type": "HostelworldRating",
"overall": 123,
"value": 123,
"security": 123,
"location": 123,
"staff": 123,
"atmosphere": 123,
"cleanliness": 123,
"facilities": 123
},
"deposit_percentage": 123,
"max_guests_per_booking": 123,
"check_in_from": "<string>",
"check_in_until": "<string>",
"latest_checkout": "<string>",
"has_free_cancellation": true,
"free_cancellation_days": 123,
"cancellation_policy": {
"@type": "HostelworldPropertyCancellationPolicy",
"deposit_only": {
"@type": "HostelworldCancellationSubPolicy",
"days": 123
},
"non_refundable": {
"@type": "HostelworldCancellationSubPolicy",
"days": 123
},
"free_cancellation": {
"@type": "HostelworldCancellationSubPolicy",
"days": 123
}
},
"is_tax_included": true,
"taxes": [],
"is_fee_included": true,
"fees": [],
"group_info": {
"@type": "HostelworldGroupInfo",
"additional_terms": "<string>",
"cancellation_terms": "<string>",
"group_terms": "<string>",
"remainder_due": "<string>",
"group_max_pax": 123,
"group_types": [],
"age_ranges": []
},
"facilities": [],
"images": [],
"videos": [],
"payment_methods": [],
"awards": []
}
]{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}Authorizations
API token from the dashboard
Headers
Body
Response
Successful Response
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes