# Wayfair — Wrapped API

> **You are on:** `https://api.beta.paywithlocus.com/api` | [llms.txt](https://beta.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 for Locus Pro. Each call burns credits from your workspace balance.

## Access

**Base URL:** `https://api.beta.paywithlocus.com/api/wrapped/credits/wayfair/`
**Auth:** `Authorization: Bearer <LOCUS_CREDITS_SECRET_KEY>` (an `lcr_` secret key or a scoped `lcac_` agent credential)
**Required header:** `Idempotency-Key: <fresh UUID per call>`. A retry with the same key replays the stored result without a new charge.
**Response:** the provider response after any endpoint-specific normalization. `X-Locus-Credits-Charged` carries the charge and `X-Locus-Credits-Balance` the remaining balance. Insufficient credits return `402` before the provider is called.
**Pricing:** estimated costs below are USD. Locus debits the credit equivalent at your workspace rate.

Full call contract: https://docs.paywithlocus.com/api-reference/introduction

> Using a Pay With Locus wallet key (`claw_` prefix)? Wallet routes are documented separately: https://docs.paywithlocus.com/wrapped-apis/for-agents

## 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.beta.paywithlocus.com/api/wrapped/credits/wayfair/filter-products-by-dimensions \
  -H "Authorization: Bearer $LOCUS_CREDITS_SECRET_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -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.beta.paywithlocus.com/api/wrapped/credits/wayfair/get-categories \
  -H "Authorization: Bearer $LOCUS_CREDITS_SECRET_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -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.beta.paywithlocus.com/api/wrapped/credits/wayfair/get-daily-deals \
  -H "Authorization: Bearer $LOCUS_CREDITS_SECRET_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -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.beta.paywithlocus.com/api/wrapped/credits/wayfair/get-product-details \
  -H "Authorization: Bearer $LOCUS_CREDITS_SECRET_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -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.beta.paywithlocus.com/api/wrapped/credits/wayfair/search-products \
  -H "Authorization: Bearer $LOCUS_CREDITS_SECRET_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{"page":"<integer>","query":"<string>"}'
```

## Next steps

- [All wrapped API providers](https://beta.paywithlocus.com/wapi/index.md): pick another provider.
- [Find and call tools](https://beta.paywithlocus.com/agent/tools.md): price ceilings, async results, and errors.
- [Credits and billing](https://beta.paywithlocus.com/agent/billing.md): what a call costs and how to add credits.
- [Agent docs index](https://beta.paywithlocus.com/agent/index.md): every Locus agent page.