Error reference
needs_country
A bare booking.com slug was passed to /v1/listing without a country. Booking slugs are NOT globally unique — the same slug exists per country — so the target cannot be safely resolved.
HTTP 400invalid_requestNot retryable0 credits
HTTP 400
error.type = invalid_requestHow to fix it
Disambiguate the country: pass ?country=<cc> (ISO-3166 alpha-2, e.g. co), a "{country}/{slug}" id, or a full booking.com/hotel/{country}/{slug}.html URL. Not retryable — the bare slug is ambiguous by construction.
Example response
400 invalid_request
// HTTP 400
{
"error": {
"type": "invalid_request",
"code": "needs_country",
"message": "A bare booking.com slug was passed to /v1/listing without a country. Booking slugs are NOT globally unique — the same slug exists per country — so the target cannot be safely resolved.",
"param": null,
"requestId": "req_…",
"creditsCharged": 0,
"retryable": false,
"docUrl": "https://stayingapi.com/docs/errors/needs_country"
}
}This error is free
Like every StayingAPI error,
needs_country returns creditsCharged: 0. You are never billed for a failed, empty, blocked or not-found call.See the full error catalog or the response envelope. The canonical URL for this page is https://stayingapi.com/docs/errors/needs_country.