Get page by URL

The page endpoint is the heart of the Makaira Marketing Suite when it comes to using Enterprise features like the page editor.

It's main purpose is retrieving a page document for a given URL.
In the most simple case, the URL belongs to Landingpage that was created in the Makiara-Backend. In this case, it is enough to supply the URL and Shop-ID in the request body.

In more advanced cases, the URL may belong to a category or manufacturer page. In this case, you can and should supply additional information in the request body, e.g. for sorting or pagination.

Resolves a URL to its corresponding page editor page or search results. This is the primary endpoint for storefront routing — the storefront sends the current URL and receives back the page content or search results.

Request

POST /enterprise/page

Headers

HeaderValue
Content-Typeapplication/json
X-Makaira-InstanceYour Makaira instance identifier

Request Body

FieldTypeRequiredDescription
urlstringYesThe URL path to resolve (e.g. /men/shoes).
constraintsobjectYesMust include query.shop_id and query.language.
isSearchbooleanNoSet to true if the URL represents a search results page.
searchPhrasestringNoSearch phrase for search result pages.
enableAggregationsbooleanNoInclude filter aggregations in the response.
aggregationsobjectNoActive filter selections.
sortingobjectNoSorting configuration.
countintegerNoNumber of products per page.
offsetintegerNoPagination offset.

Example Request

{
  "url": "/men/shoes",
  "constraints": {
    "query.shop_id": "1",
    "query.language": "de"
  },
  "isSearch": false,
  "enableAggregations": true,
  "aggregations": [],
  "sorting": [],
  "count": 24,
  "offset": 0
}

Response

Returns the resolved page content including product results, page components, and metadata.

Body Params
string

The URL to search for.

boolean

Set this to true when the request is an actual search request (e.g. autosuggest) and to false when you want to perform a request for products on a category or manufacturer page.

string

The term to search for.

boolean

Set this to true when you want aggregations to be included in the response, otherwhise false.

aggregations
object

List of selected values to filter for.

sorting
object
fields
array

List of additional fields to be included in the response. When the value is an empty array, the response will include all available fields for each item.

fields
string

Number of products to be returned in the response.

string

The offset to start returning products from. In combination with the "count" property this is used for paginating the search results.

constraints
object
Headers
string
required

Makaira Instance ID

Response
200

OK

Language
Credentials
Bearer
URL
LoadingLoading…
Response
Click Try It! to start a request and see the response here!