Authentication
All requests use your FetchLayer API key as a Bearer token. No Tripadvisor partner account, content API licence, or per-property credential is required.
Sending requests
bash
curl -X POST https://api.fetchlayer.dev/tripadvisor/location-reviews \
-H "Authorization: Bearer ss-your-key" \
-H "Content-Type: application/json" \
-d '{"location":"307368","pages":2}'Keep your key secret
Only use API keys in server-side code and rotate a key immediately if it is exposed.
Downloading photos
The photo download endpoint is a GET, and carries the same Bearer header. Because the key travels in a header rather than the URL, a photo URL cannot be shared without also sharing the key.
bash
curl -X GET "https://api.fetchlayer.dev/tripadvisor/media?url=https%3A%2F%2Fsummer-heart-0930.chufeiyun1688.workers.dev%3A443%2Fhttps%2Fmedia-cdn.tripadvisor.com%2Fmedia%2Fphoto-o%2F…%2Froom.jpg&filename=room.jpg" \
-H "Authorization: Bearer ss-your-key" \
-H "Range: bytes=0-65535" \
--output room.jpgAuthentication errors
A missing or invalid key returns HTTP 401.
json
{
"error": "Invalid API key"
}