Replace recommendation page

šŸ” This endpoint requires HTTP authentication (either Basic or Bearer).
For authenticating with Bearer token, required scopes are: recommendations(w).

Beta: This endpoint is in beta and may change. It is currently available to a small group of users. To request access, contact your Customer Success Manager.

Add or replace the page configured under page_id, and return it. Every field of the page is replaced: display_name, page_type and pods are required, pods replaces the complete ordered list, and a metadata_json setting left out of the body is restored to its default rather than kept. Answers 200 whether the page was created or replaced.

Answers 404 if a pod in pods is not configured for this key and section, and 400 if pods repeats a pod or lists more pods than the page limit. pods may be empty.

Path Params
string
required
Query Params
string
required
length between 1 and 100

The key of the index to use.

string
length between 1 and 100

The section of the index to use. Defaults to Products.

string
length between 1 and 100

The ID of the client and version that the request is coming from, such as cio-js-2.90.

Body Params

The complete configuration a page is to have.

string
length between 1 and 255
^[a-z0-9][a-z0-9_-]*$

Ignored, though it must still be a valid page ID. The page replaced is the one the URL names; this field is accepted so that a page read from the API can be sent back unchanged.

string
required
length between 2 and 100

The name of the page displayed to merchandisers, between 2 and 100 characters. Surrounding whitespace is stripped.

string
enum
required

The role the page plays in the storefront. It is metadata only and does not affect retrieval behavior today.

pods
array of objects, unique
required

Pods to serve on this page, listed in the order a shopper sees them: top to bottom, then left to right for pods that sit side by side. Page results return the pods in this order, and a retrieval request cannot reorder them. Items are deduplicated between pods in the same page; which pod keeps an ordinary (non-slotted) item is decided by Constructor, so slot an item to guarantee it stays in a particular pod. Include at most 5 pods, or fewer where a lower limit is configured for the page; each must already be configured for this key and section, and no pod may appear twice. A page with no pods returns an empty pods list. A write that supplies pods replaces the complete list.

Pods*
metadata_json
object

Settings that apply to the page as a whole, rather than to an individual pod. Replaced rather than merged: a setting left out, or the whole field left out, is restored to its default.

Responses

400

Validation Error

401

Credentials are not passed or action is forbidden.

403

The supplied token does not have the required permissions.

404

Not Found

409

Conflict

429

Rate limit breached

Language
Credentials
:
LoadingLoading…
Response
Choose an example:
application/json