WooCommerce API — List Products & Prices
Documentation menu
FetchLayer FetchLayer API

List a store's products

List a WooCommerce store's products with prices, sale prices, stock, SKUs, categories, tags, brands, attributes, variations and image URLs. Filter by search text, category, tag, price range, on sale and in stock, and order by date, price, popularity, rating, title or the store's own menu order. Read the response's dataSource: on a store with no published catalog the records are read from rendered product pages, which is dramatically more expensive per product, and limit becomes a hard request budget rather than a target.

POST /products Catalog
https://api.fetchlayer.dev/woocommerce-stores/products
OpenAPI JSON

Headers

Authorization string required

Bearer token — your FetchLayer API key.

Parameters

store string required

Store domain, for example example.com, or any URL on the store. 3–255 characters.

dataSource string optional

Pin the read to one published source: catalog-api, content-api or product-pages. catalog-api carries every field, content-api carries no prices, SKUs or stock, and product-pages carries no attributes or variations and is far more expensive to read. (default: the most complete source the store offers)

limit number optional

Maximum products returned (max 250), or -1 for everything available. On a store read from rendered pages this is a budget, not a target — every product is a page fetch. (default: 30)

search string optional

Only products matching this text.

category string optional

Only products in this category, by slug or id.

tag string optional

Only products with this tag, by slug or id.

minPrice string optional

Only products at or above this price, in the store's own currency. A decimal string, for example 19.99.

maxPrice string optional

Only products at or below this price, in the store's own currency.

onSale boolean optional

Only products the store has discounted.

inStock boolean optional

Only products the store reports as in stock.

orderBy string optional

date, price, popularity, rating, title or menu_order. Follows the store's own order by default.

orderDirection string optional

asc or desc.

pages number optional

Pages of results to collect in one request (max 100), or -1 for the maximum allowed. Each page walked counts as one request.

cursor string optional

Resume from a previous response's nextCursor.

delayMs number optional

Milliseconds to wait between requests to the store (max 30000). Use it on a store you are walking deeply.

timeoutMs number optional

Per-request time limit in milliseconds (max 600000). Worth raising on a store read from rendered pages.

Response Fields

products

List a store's products

requestedUrl string

The store this result corresponds to.

scrapedAt string

ISO 8601 timestamp of the read.

blocked boolean

Always false on a successful response.

notes string[]

Caveats about this particular result — a truncated walk, an upstream limit, a field this store does not publish. Read it: a short result set is usually explained here rather than by an error.

store object

The resolved store: canonical domain and the store's own base URL.

dataSource string

catalog-api, content-api or product-pages — the source these products were read from, and the single biggest factor in what the call cost.

filters object

The filters this call actually ran with, after defaults were resolved.

products object[]

The matching products.

products[].id number | null

The store's own product id, where it publishes one.

products[].name string

Product title.

products[].slug string | null

URL slug — pass it to /product-detail as product.

products[].permalink string | null

The product page on the store.

products[].type string | null

simple, variable, grouped, external or variation, as the store reports it.

products[].sku string | null

Stock keeping unit. Absent on the content-api source.

products[].description string | null

Plain text, markup removed.

products[].shortDescription string | null

The store's own summary line, where it publishes one.

products[].prices object

currency, currencySymbol, price, regularPrice, salePrice, onSale, priceRangeMin and priceRangeMax. Amounts are exact decimal strings in the store's own currency, never floats.

products[].stockStatus string

in-stock, out-of-stock, on-backorder or unknown.

products[].stockQuantity number | null

Set only where the store publishes a number rather than a status.

products[].averageRating number | null

The rating the store displays.

products[].reviewCount number | null

How many reviews the store reports. The review text itself is not offered yet.

products[].categories object[]

Categories on the product: id, name, slug and URL.

products[].tags object[]

Tags on the product.

products[].brands object[]

Brands on the product, where the store uses them.

products[].attributes object[]

Attribute name, the store's key, its terms, and whether variations differ by it. Absent on the product-pages source.

products[].variations object[]

Each variation with its own id, SKU, option values, prices, permalink and stock status. Absent on the product-pages source.

products[].images object[]

url, thumbnailUrl, alt, title and a downloadUrl that streams the file through GET /media. Image bytes are never fetched while reading a catalog.

products[].weight string | null

Shipping weight, as the store reports it.

products[].dimensions object | null

length, width and height, as the store reports them.

products[].dateCreated string | null

When the product was published.

products[].dateModified string | null

When the product last changed — the field to diff for catalog monitoring.

products[].source string

Which published source this record came from: catalog-api, content-api or product-pages. It tells you which fields to trust and what the read cost.

productCount number

Products in this response.

totalProducts number | null

The total the store reports for these filters, where it reports one.

pagesScraped number

Pages actually collected. Each page counts as one request against your plan.

nextCursor string | null

Pass back as cursor to continue, or null when the listing is exhausted.

hasNextPage boolean

Whether more results are available beyond this response.

Request

curl -X POST "https://api.fetchlayer.dev/woocommerce-stores/products" \
  -H "Authorization: Bearer ss-your-key" \
  -H "Content-Type: application/json" \
  -d '{"store":"example-shop.com","category":"outerwear","onSale":true,"orderBy":"price","orderDirection":"asc","limit":50}'

Response

{
  "dataSource": "catalog-api",
  "productCount": 50,
  "totalProducts": 118,
  "pagesScraped": 1,
  "hasNextPage": true,
  "products": [
    {
      "id": 8842,
      "name": "Coastal Rain Shell",
      "slug": "coastal-rain-shell",
      "sku": "CRS-BLK-M",
      "prices": {
        "currency": "USD",
        "price": "129.00",
        "regularPrice": "179.00",
        "salePrice": "129.00",
        "onSale": true
      },
      "stockStatus": "in-stock",
      "source": "catalog-api"
    }
  ],
  "notes": []
}