# Wayfair — Wrapped API

> **You are on:** `https://api.paywithlocus.com/api` | [llms.txt](https://paywithlocus.com/llms.txt) | [docs](https://docs.paywithlocus.com)
>
> Locus runs on multiple environments -- make sure every URL you call matches your expected environment.
> | Environment | Landing | API | Docs |
> |---|---|---|---|
> | Production | paywithlocus.com | api.paywithlocus.com | docs.paywithlocus.com |
> | Beta | beta.paywithlocus.com | api.beta.paywithlocus.com | docs.paywithlocus.com |
> | Stage | stage.paywithlocus.com | api.stage.paywithlocus.com | docs.paywithlocus.com |
>
> If the API URL above doesn't match your expected environment, re-fetch this file from the correct domain.

> Browse and search Wayfair's product catalog. Retrieve product details by SKU or URL, explore daily sales and promotions, browse categories, and filter products by keyword, price, and physical dimensions.

**Category:** E-commerce | **Website:** [wayfair.com/](https://wayfair.com/) | **Docs:** [parse.bot/marketplace/4eb8c9eb-565a-405e-9da3-6aa4a5942458/wayfair-com-api](https://parse.bot/marketplace/4eb8c9eb-565a-405e-9da3-6aa4a5942458/wayfair-com-api)

Pay-per-use API proxy. Each call is automatically billed to your wallet in USDC.

## Access

**Base URL:** `https://api.paywithlocus.com/api/wrapped/parse-wayfair-com-api-4eb8c9eb/`
**Auth:** `Authorization: Bearer <LOCUS_API_KEY>`

## Endpoints

### filter_products_by_dimensions

Search for products and filter by dimensions and price. Searches for products by keyword, then fetches detail pages for the first 10 results to check dimension specifications against the provided maximums. Returns only products whose dimensions and price fall within the specified limits. Makes up to 11 requests (1 search + up to 10 detail pages).

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `depth_max` | number | No | Maximum depth in inches. |
| `height_max` | number | No | Maximum height in inches. |
| `price_max` | number | No | Maximum price in USD. |
| `query` | string | No | Search keyword. |
| `width_max` | number | No | Maximum width in inches. |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-wayfair-com-api-4eb8c9eb/filter_products_by_dimensions \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"depth_max":"<number>","height_max":"<number>","price_max":"<number>","query":"<string>","width_max":"<number>"}'
```

### get_categories

Get top-level product categories from the Wayfair homepage navigation. Returns category names and URLs for major departments like Furniture, Outdoor, Bedding & Bath, Rugs, Lighting, etc.

**Estimated cost:** Metered

_No parameters required._

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-wayfair-com-api-4eb8c9eb/get_categories \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{}'
```

### get_daily_deals

Retrieve current daily sales events and promotions from the Wayfair daily-sales page. Returns named sale events with URLs. Results change daily as Wayfair rotates promotions.

**Estimated cost:** Metered

_No parameters required._

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-wayfair-com-api-4eb8c9eb/get_daily_deals \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{}'
```

### get_product_details

Get detailed information for a specific product by its SKU or full product page URL. Returns name, brand, price, description, images, specifications, and ratings. When called with a SKU, Wayfair redirects to the product detail page automatically.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `sku` | string | No | Product SKU (e.g. 'W006113311'). Either sku or url must be provided. |
| `url` | string | No | Full product page URL. Either url or sku must be provided. |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-wayfair-com-api-4eb8c9eb/get_product_details \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"sku":"<string>","url":"<string>"}'
```

### search_products

Search for products by keyword on Wayfair with optional pagination. Returns a list of product summaries including name, SKU, price, rating, review count, and URL. Each page returns up to ~50 products. Paginated via a page number parameter. Image URLs are not available in search results; use get_product_details for images.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `page` | integer | No | Page number for pagination. |
| `query` | string | Yes | Search keyword (e.g. 'sofa', 'desk', 'bookshelf') |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-wayfair-com-api-4eb8c9eb/search_products \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"page":"<integer>","query":"<string>"}'
```
