# Farfetch API scraper — the luxury fashion marketplace of boutiques (farfetch.com): search ~70 country storefronts with local prices, read the full product (every size with the boutique that sells it, its price, stock and ship-from, composition, made-in, duties/VAT basis) and autocomplete. No account, no browser.

> Search Farfetch in any storefront country by keyword and/or designer/category, with the site's own sorts and filters (department, on-sale, price range, colour). Each row: item id, designer, name, the price a shopper pays in that country's currency, the struck price + sale %, the discounted offer of another size/boutique when one exists, the boutique id, the search-index stock quantity, sizes in stock, pre-owned + condition, members-only flag, and images. A query with no genuine match returns empty (padding counted in fallback_results_dropped).
> ReefAPI engine `farfetch` · 3 endpoints · clean JSON, no scraping or browsers to manage.

## How to call
- **Endpoint:** `POST https://api.reefapi.com/farfetch/v1/<action>` with a JSON body.
- **Auth:** header `x-api-key: <YOUR_REEFAPI_KEY>` — create one free (1,000 credits, no card): https://reefapi.com/signup
- **Response (every call):** `{ ok: boolean, data: ..., meta: { record_count, credits, ... }, error: { code, message } }` — branch on `ok`. Failed calls are free except verified SHEIN NOT_FOUND on product/detail and price (4 credits).
- **One key + one shared credit pool** across every ReefAPI API. Per-call credits are listed on each endpoint below.
- **Use it from an AI agent (MCP):** connect `https://api.reefapi.com/mcp` (remote streamable-http, `Authorization: Bearer <key>`) and your assistant can call these actions directly.

## Endpoints

### POST /farfetch/v1/search — 1 credit
Search Farfetch in any storefront country by keyword and/or designer/category, with the site's own sorts and filters (department, on-sale, price range, colour). Each row: item id, designer, name, the price a shopper pays in that country's currency, the struck price + sale %, the discounted offer of another size/boutique when one exists, the boutique id, the search-index stock quantity, sizes in stock, pre-owned + condition, members-only flag, and images. A query with no genuine match returns empty (padding counted in fallback_results_dropped).

**Parameters:**
- `country` (enum, optional, default "us") — Farfetch storefront country (ISO-2; 'uk' for the United Kingdom). Prices, the currency and the duties/VAT basis follow it. Default us. [one of: us, uk, de, fr, it, es, nl, at, ch, se, dk, no, fi, pl, be, lu, pt, ie, gr, cz, sk, si, hr, bg, ee, lv, lt, ro, hu, cy, mt, ae, sa, qa, kw, bh, om, jo, eg, ma, il, jp, kr, au, nz, ca, mx, br, ar, cl, co, pe, sg, hk, mo, tw, in, cn, th, my, id, ph, vn, za, ng, ke, kz, is]
- `language` (enum, optional, default "en") — Language of names, labels, composition and made-in — and of the keyword index (search a Spanish word with language=es). Independent of country. Default en. [one of: en, de, fr, it, es, ja, ko, zh, ru]
- `query` (string, optional) — Keyword (designer, product, type). Optional when brand_id or category_id is given.
- `gender` (enum, optional, default "all") — Department. [one of: all, women, men, kids]
- `sort` (enum, optional, default "relevance") — Result order. best_discount restricts to sale items (the site's discount order only exists inside sale). [one of: relevance, newest, price_asc, price_desc, best_discount]
- `page` (integer, optional, default 1) — 1-based page.
- `page_size` (integer, optional, default 48) — Rows per page (Farfetch allows up to 180).
- `brand_id` (string, optional) — Farfetch designer id (search rows return brand_id; facets list them).
- `category_id` (string, optional) — Farfetch category id (from facets or product/detail category_paths), e.g. 135967 women's clothing.
- `color_id` (string, optional) — Colour facet id (from include_facets).
- `on_sale` (boolean, optional, default false) — Only products with at least one discounted offer (Farfetch's sale listing is product-level; a row's own on_sale says whether its page price is the discounted one).
- `price_min` (number, optional) — Minimum price in the storefront currency.
- `price_max` (number, optional) — Maximum price in the storefront currency.
- `include_facets` (boolean, optional, default false) — Also return facets (designers, categories, colours, price and discount ranges) with their ids and counts.
- `include_fallback_results` (boolean, optional, default false) — When a query matches nothing, Farfetch sometimes pads the page with unrelated products. By default they are dropped (fallback_results_dropped counts them); true returns them apart in fallback_results.

**Returns:** results[]{product_id, url, brand, brand_id, name, label, price, currency, was_price, discount_percent, on_sale, price_type, promotion_offer{price,full_price,discount_percent,type}, purchasable, boutique_id, search_index_stock_quantity, sizes_in_stock[], size_count, color_count, pre_owned, condition, members_only, image, images[]}, count, total_results, page, page_size, has_more, sort, query, gender, on_sale, country, language, currency, keyword_matches_on_page, fallback_results_dropped, facets[] (include_facets)

**Example request body:**
```json
{
  "country": "us",
  "query": "gucci"
}
```

### POST /farfetch/v1/product/detail — 1 credit
The full Farfetch product by item id or URL in a storefront country: designer, name, the highlights list, season, gender, colour, designer style id, made-in, composition, care, measurements, condition for pre-owned, category path, the page price with struck price/sale %, the discounted offer of another size/boutique, and the duties/VAT basis, the boutique that sells it (name, country, city), total stock, and every size with the boutique offers for it (each boutique's own price, quantity and ship-from), plus the lowest/highest offer price and images.

**Parameters:**
- `country` (enum, optional, default "us") — Farfetch storefront country (ISO-2; 'uk' for the United Kingdom). Prices, the currency and the duties/VAT basis follow it. Default us. [one of: us, uk, de, fr, it, es, nl, at, ch, se, dk, no, fi, pl, be, lu, pt, ie, gr, cz, sk, si, hr, bg, ee, lv, lt, ro, hu, cy, mt, ae, sa, qa, kw, bh, om, jo, eg, ma, il, jp, kr, au, nz, ca, mx, br, ar, cl, co, pe, sg, hk, mo, tw, in, cn, th, my, id, ph, vn, za, ng, ke, kz, is]
- `language` (enum, optional, default "en") — Language of names, labels, composition and made-in — and of the keyword index (search a Spanish word with language=es). Independent of country. Default en. [one of: en, de, fr, it, es, ja, ko, zh, ru]
- `product_id` (string, optional) — Farfetch item id (the number in …-item-<id>.aspx; search rows return product_id).
- `url` (string, optional) — A farfetch.com product URL instead of product_id. Its /<country>/ subfolder sets the country unless country is given.

**Returns:** product{product_id, url, brand, brand_id, name, highlights[], label, season, gender, color, designer_style_id, made_in, composition[{part,materials[{material,percentage}]}], care[{type,procedures[]}], measurements[{name,metric,imperial}], pre_owned, condition, breadcrumb[{id,name}], category_paths[[…]], price, currency, was_price, discount_percent, on_sale, price_type, promotion_offer, purchasable, taxes_and_duties{type,label}, boutique{id,name,country_code,country,city,stock_type}, available, stock_quantity, lowest_price, highest_price, boutique_count, size_scale{id,name,one_size}, sizes[{id,size,size_alt,scale,available,quantity,offers[{boutique_id,boutique_name,ships_from_country_code,ships_from_country,ships_from_city,stock_type,quantity,price,was_price,discount_percent,on_sale,purchasable}]}], colors[], images[], image}, country, language

**Example request body:**
```json
{
  "country": "uk",
  "product_id": "28060177"
}
```

### POST /farfetch/v1/suggest — 1 credit
Farfetch autocomplete for a partial keyword: designer, category and phrase suggestions with the designer/category id and the storefront URL.

**Parameters:**
- `query` (string, required) — Partial keyword.
- `country` (enum, optional, default "us") — Farfetch storefront country (ISO-2; 'uk' for the United Kingdom). Prices, the currency and the duties/VAT basis follow it. Default us. [one of: us, uk, de, fr, it, es, nl, at, ch, se, dk, no, fi, pl, be, lu, pt, ie, gr, cz, sk, si, hr, bg, ee, lv, lt, ro, hu, cy, mt, ae, sa, qa, kw, bh, om, jo, eg, ma, il, jp, kr, au, nz, ca, mx, br, ar, cl, co, pe, sg, hk, mo, tw, in, cn, th, my, id, ph, vn, za, ng, ke, kz, is]
- `language` (enum, optional, default "en") — Language of names, labels, composition and made-in — and of the keyword index (search a Spanish word with language=es). Independent of country. Default en. [one of: en, de, fr, it, es, ja, ko, zh, ru]
- `gender` (enum, optional, default "all") — Department. [one of: all, women, men, kids]

**Returns:** suggestions[{text, type, reference_type, reference_id, url}], count, country, gender

**Example request body:**
```json
{
  "country": "de",
  "query": "guc"
}
```

## More
- Try it live, no code: https://reefapi.com/playground?engine=farfetch
- Human docs page: https://reefapi.com/docs/farfetch
- Overview page: https://reefapi.com/farfetch-api
- Every ReefAPI API in one file (for your AI): https://reefapi.com/llms-full.txt
