Skip to content
Elara One docs
Search

Search products

GET
/v1/search

Full product cards for a results page. For the same q and locale with no filters, meta.total equals the suggest endpoint's data.products.total. An empty q with a filter is a browse (e.g. every product with a tag). meta.facets counts the store's facets (Meilisearch only; empty on the database fallback), meta.facet_labels names them and meta.facet_value_labels names identifier values (brand_slug => brand names). Prices in filters are integer minor units of meta.currency. Every 200 carries X-Search-Total (equal to meta.total) and a fresh X-Search-Id header (a ULID) for click beacons, cached body or not.

Authorization

tenantKey
headerX-Tenant-Key<token>

The public store key (pk_live_…). Required on every call.

Query Parameters

q?|

Free-text search term. Empty or missing lists every published product.

Lengthlength <= 256
locale?|

A store language code (GET search/config locales[].code, e.g. en, fr). Unknown or missing: the store default. meta.locale reports the locale actually used.

Lengthlength <= 35
live?|

1 on the results page's update-as-you-type keystrokes: answered as usual, never recorded as a search. Omit it on the request the shopper settles on.

Value in"0""1""true""false"null
filter[collection]?|

Collection slug.

Lengthlength <= 255
filter[brand]?|

Brand slug. An unknown slug matches no product.

Lengthlength <= 255
filter[tag]?|

Tag value, matched exactly (letter case ignored).

Lengthlength <= 255
filter[in_stock]?|

1: only products in stock. 0 or missing: no stock constraint.

Value in"0""1""true""false"null
filter[on_sale]?|

1: only products on sale — a sale price for guests or a compare-at price above the price (the on_sale facet counts the same). 0 or missing: no constraint.

Value in"0""1""true""false"null
filter[price_min]?|

Integer minor units of the store currency (never a decimal amount). Compared with the regular price, or the sale price when the store's search settings say so.

Range0 <= value
filter[price_max]?|
Range0 <= value
filter[attr][]?array<|>|null

Header Parameters

X-Client-IP?string

Optional. IP address of the shopper (one IPv4/IPv6, no port, no list). Honoured only together with a valid X-Tenant-Secret; ignored otherwise. Used for rate limits and recorded with form submissions.

X-Tenant-Secret?string

Optional here. Server secret of the store: server-to-server only, never from a browser. Enables X-Client-IP.

Response Body

A page of results, with links and meta.

application/json
  1. response
data*array<>
links*
meta*
Example Request
curl -X GET 'https://api.elaraone.app/api/v1/search' \  -H 'X-Tenant-Key: pk_live_…' \  -H 'X-Tenant-Secret: your-server-secret'
Example Response
{  "data": [    {      "id": 0,      "status": "string",      "name": null,      "description": null,      "slug": "string",      "options": [        {          "id": 0,          "handle": "string",          "name": "string",          "label": "string",          "values": [            {              "id": 0,              "name": "string"            }          ]        }      ],      "variants": [        {          "id": 0,          "sku": "string",          "stock": 0,          "shippable": true,          "price": {            "amount": 0,            "currency": "string",            "formatted": "string"          },          "pricing": {            "price": {              "amount": 0,              "currency": "string",              "formatted": "string"            },            "sale_price": {              "amount": 0,              "currency": "string",              "formatted": "string"            },            "compare_price": {              "amount": 0,              "currency": "string",              "formatted": "string"            },            "on_sale": true,            "saving": {              "amount": {                "amount": 0,                "currency": "string",                "formatted": "string"              },              "percent_bp": 0            },            "badges": [              {                "label": "string",                "kind": "string"              }            ]          },          "options": [            {              "option_id": 0,              "option": "string",              "value_id": 0,              "value": "string"            }          ]        }      ],      "images": [        {          "id": 0,          "name": "string",          "url": "string",          "thumbnail_url": "string"        }      ],      "collections": [        {          "id": 0,          "parent_id": 0,          "name": null,          "slug": "string",          "children": [            {}          ]        }      ],      "offers": [        {          "id": 0,          "kind": "string",          "label": "string",          "badge": "string",          "banner": {            "title": "string",            "body": "string"          },          "bulk_table": [            {              "min_qty": 0,              "max_qty": 0,              "unit_price": {                "amount": 0,                "currency": "string",                "formatted": "string"              },              "percent_bp": 0            }          ],          "bulk_table_variant_id": 0,          "ends_at": "string",          "scope": "all"        }      ]    }  ],  "links": {    "first": "string",    "last": "string",    "prev": "string",    "next": "string"  },  "meta": {    "current_page": 1,    "from": 1,    "last_page": 1,    "links": [      {        "url": "string",        "label": "string",        "active": true      }    ],    "path": "string",    "per_page": 0,    "to": 1,    "total": 0,    "facets": {      "property1": {        "property1": 0,        "property2": 0      },      "property2": {        "property1": 0,        "property2": 0      }    },    "facet_labels": {      "property1": "string",      "property2": "string"    },    "facet_value_labels": {      "property1": {        "property1": "string",        "property2": "string"      },      "property2": {        "property1": "string",        "property2": "string"      }    },    "search_engine": "meilisearch",    "locale": "string",    "currency": "string"  }}