GET
# Airbnb Reviews From URL API

Extract listing reviews directly from any Airbnb URL without extracting the listing ID first.

## Overview

#### Simplified Workflow

Automatically extracts listing ID from URL and retrieves reviews in one API call.

This endpoint simplifies the review extraction process by accepting any Airbnb listing URL. It automatically parses the listing ID and retrieves the comprehensive review data, eliminating the need for manual ID extraction.

### Endpoint URL

GET https://api.stayapi.com/v1/airbnb/listing/reviews-from-url 

## Query Parameters

| Parameter | Type | Required | Description |
| --- | --- | --- | --- |
| url | string | Required | Full Airbnb listing URL |
| limit | integer | Optional | Number of reviews per page (1-50, default: 10) |
| offset | string | Optional | Pagination offset (default: "0") |
| sort\_by | string | Optional | Sort order: BEST\_QUALITY or MOST\_RECENT (default: BEST\_QUALITY) |
| check\_in | string | Optional | Check-in date for contextual reviews (YYYY-MM-DD) |
| check\_out | string | Optional | Check-out date for contextual reviews (YYYY-MM-DD) |

## Supported URL Formats

### Accepted Airbnb URL Patterns

`https://www.airbnb.com/rooms/22120898`- Standard listing URL

`https://airbnb.co.uk/rooms/22120898?check_in=2025-10-31`- With parameters

`https://m.airbnb.com/rooms/22120898`- Mobile URL

`https://www.airbnb.de/listing/22120898`- Alternative format

## Response Structure

The response structure is identical to the standard listing reviews endpoint, with the addition of the extracted listing ID.

### Response Fields

- `listing_id` - Extracted listing ID
- `total_count` - Total number of reviews
- `review_count` - Reviews in current response
- `has_more` - Whether more reviews exist
- `reviews` - Array of review objects

## Usage Tips

#### URL Encoding

Always URL-encode the Airbnb URL parameter to handle special characters and query parameters correctly.

### URL Validation

The endpoint automatically validates and normalizes Airbnb URLs, supporting various international domains and URL formats.

### Pagination

Use the offset parameter to paginate through large review sets. Check the has\_more field to determine if additional pages exist.

### Date Filtering

Provide check\_in and check\_out dates to get reviews most relevant to specific booking periods.

Request

```curl
curl -X GET "https://api.stayapi.com/v1/airbnb/listing/reviews-from-url?url=https://www.airbnb.com/rooms/22120898&limit=5" \
  -H "x-api-key: YOUR_API_KEY"
```

Response

```json
{
  "success": true,
  "listing_id": "22120898",
  "total_count": 321,
  "review_count": 5,
  "has_more": true,
  "reviews": [
    {
      "id": "1092837465",
      "rating": 5,
      "text": "Absolutely perfect stay! The apartment exceeded our expectations in every way. The location was ideal for exploring the city, and the host was incredibly responsive and helpful.",
      "language": "en",
      "created_at": "2024-03-20",
      "reviewer": {
        "id": "user_789012",
        "name": "Emma Wilson",
        "picture_url": "https://a0.muscache.com/im/pictures/user/789012.jpg"
      },
      "host_response": {
        "text": "Thank you Emma! It was a pleasure hosting you. You're welcome back anytime!",
        "created_at": "2024-03-21",
        "author": "Host"
      }
    },
    {
      "id": "1092736284",
      "rating": 4,
      "text": "Great apartment with beautiful views. Everything was clean and well-maintained. The only minor issue was the Wi-Fi speed could be better for remote work.",
      "language": "en",
      "created_at": "2024-03-18",
      "reviewer": {
        "id": "user_345678",
        "name": "David Martinez",
        "picture_url": "https://a0.muscache.com/im/pictures/user/345678.jpg"
      },
      "host_response": null
    }
  ]
}
```

```json
{
  "error": "Invalid URL",
  "detail": "The provided URL is not a valid Airbnb listing URL",
  "status_code": 400
}
```
