curl --request GET \
--url https://{host}/v1/filter-pages \
--header 'Authorization: Bearer <token>'const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://{host}/v1/filter-pages', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://{host}/v1/filter-pages",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}import requests
url = "https://{host}/v1/filter-pages"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text){
"data": [
{
"type": "filter-pages",
"id": "804",
"attributes": {
"name": "Rolex",
"autocompleteName": "Rolex",
"title": "Pre-owned Rolex watches",
"subtitle": "Every Rolex on Wristler",
"breadcrumbTitle": "Rolex",
"slug": "rolex",
"locale": "en",
"url": "https://wristler.eu/watches/rolex",
"seoTitle": "Buy a pre-owned Rolex",
"seoDescription": "Certified pre-owned Rolex watches, with warranty.",
"robots": "index, follow",
"watchCount": 6243,
"search": {
"words": null,
"filters": {
"brand": [
"Rolex"
]
}
},
"breadcrumbs": [
{
"name": "Home",
"url": "https://wristler.eu"
},
{
"name": "Rolex",
"url": "https://wristler.eu/watches/rolex"
}
],
"blocks": null
}
}
],
"meta": {
"page": {
"currentPage": 1,
"from": 1,
"lastPage": 141,
"perPage": 25,
"to": 25,
"total": 3512
}
}
}{
"errors": [
{
"status": "404",
"code": "watch_reserved",
"title": "Not Found",
"detail": "<string>",
"meta": {},
"source": {
"pointer": "/data/attributes/reference",
"parameter": "<string>"
}
}
],
"jsonapi": {
"version": "1.0"
}
}{
"errors": [
{
"status": "404",
"code": "watch_reserved",
"title": "Not Found",
"detail": "<string>",
"meta": {},
"source": {
"pointer": "/data/attributes/reference",
"parameter": "<string>"
}
}
],
"jsonapi": {
"version": "1.0"
}
}{
"errors": [
{
"status": "404",
"code": "watch_reserved",
"title": "Not Found",
"detail": "<string>",
"meta": {},
"source": {
"pointer": "/data/attributes/reference",
"parameter": "<string>"
}
}
],
"jsonapi": {
"version": "1.0"
}
}List filter pages
Scope: content:read
Biggest first, which is the order somebody browsing wants them in. blocks is
null here; ask for the page itself to fill it.
filter[q] is the autocomplete: typed text, ranked by the index rather than
listed by size. See the parameter below.
Only published pages, and only in one language — every page exists as a row per locale, so a list that forgot that would be the same page nine times.
curl --request GET \
--url https://{host}/v1/filter-pages \
--header 'Authorization: Bearer <token>'const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://{host}/v1/filter-pages', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://{host}/v1/filter-pages",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}import requests
url = "https://{host}/v1/filter-pages"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text){
"data": [
{
"type": "filter-pages",
"id": "804",
"attributes": {
"name": "Rolex",
"autocompleteName": "Rolex",
"title": "Pre-owned Rolex watches",
"subtitle": "Every Rolex on Wristler",
"breadcrumbTitle": "Rolex",
"slug": "rolex",
"locale": "en",
"url": "https://wristler.eu/watches/rolex",
"seoTitle": "Buy a pre-owned Rolex",
"seoDescription": "Certified pre-owned Rolex watches, with warranty.",
"robots": "index, follow",
"watchCount": 6243,
"search": {
"words": null,
"filters": {
"brand": [
"Rolex"
]
}
},
"breadcrumbs": [
{
"name": "Home",
"url": "https://wristler.eu"
},
{
"name": "Rolex",
"url": "https://wristler.eu/watches/rolex"
}
],
"blocks": null
}
}
],
"meta": {
"page": {
"currentPage": 1,
"from": 1,
"lastPage": 141,
"perPage": 25,
"to": 25,
"total": 3512
}
}
}{
"errors": [
{
"status": "404",
"code": "watch_reserved",
"title": "Not Found",
"detail": "<string>",
"meta": {},
"source": {
"pointer": "/data/attributes/reference",
"parameter": "<string>"
}
}
],
"jsonapi": {
"version": "1.0"
}
}{
"errors": [
{
"status": "404",
"code": "watch_reserved",
"title": "Not Found",
"detail": "<string>",
"meta": {},
"source": {
"pointer": "/data/attributes/reference",
"parameter": "<string>"
}
}
],
"jsonapi": {
"version": "1.0"
}
}{
"errors": [
{
"status": "404",
"code": "watch_reserved",
"title": "Not Found",
"detail": "<string>",
"meta": {},
"source": {
"pointer": "/data/attributes/reference",
"parameter": "<string>"
}
}
],
"jsonapi": {
"version": "1.0"
}
}Authorizations
Headers
The language to answer in: specificationLabels, translatedDescription, facet
and label names, the content pages, and every other translated word in the
answer. Read on every request, whatever the endpoint. One we do not have falls
back to English rather than failing.
en, nl, de, es, fr, it, pt, fi, pl Query Parameters
Typed text, for an autocomplete. Ranked by the same index and the same relevance threshold as the search bar on the website, so the same letters offer the same pages.
Each suggestion carries autocompleteName (the short name an editor gave
it, falling back to name), watchCount, and search — so tapping one is
a /v1/watches request with exactly those words and facets. blocks is
null, as in any list.
Ordered by how well each page matches, so sort alongside it is refused
with 400 search_only_sort; filter[slug] and filter[parent] are not
applied while searching. If the index cannot be reached the answer is
503 search_unavailable, never an empty page.
Five is usually enough: page[size]=5.
Response
A page of filter pages.