Skip to main content

Get all Nodes

GET 

https://euwest.api.elasticpath.com/catalog/nodes

Returns all nodes in the catalog.

If you have multiple catalog rules defined, the rule that best matches the shoppers context is used to determine which catalog is retrieved. For information about how rules are matched, see Resolving Catalog Rules.

You can see the parent nodes a node is associated with in the breadcrumbs metadata for each node. This is useful if you want to improve how your shoppers search your store, for example. See Product and Node Associations in Breadcrumb Metadata.

In a catalog, you can use a filter to return a list of nodes in a hierarchy structure that a product belongs to. You can use this to build breadcrumbs in your storefront. For more information, see Building breadcrumbs in a storefront.

The response lists the products associated with the nodes. If products are curated, they are displayed in curated_products. Product curation allows you to promote specific products within each of your hierarchies, enabling you to create unique product collections in your storefront.

  • You can only curate 20 products or less. You cannot have more than 20 curated products.
  • If a curated product is removed from a node, the product is also removed from the curated_products list.

Filtering

This endpoint supports filtering. For general syntax, see Filtering. The following operators and attributes are available.

OperatorDescriptionAttributesExample
EqChecks if the values of two operands are equal. If they are, the condition is true.name, slugfilter=eq(name,some-name)
inChecks if the values are included in the specified string. If they are, the condition is true.
Idfilter=in(id,9214719b-17fe-4ea7-896c-d61e60fc0d05,e104d541-2c52-47fa-8a9a-c4382480d97c,65daaf68-ff2e-4632-8944-370de835967d)

Building breadcrumbs in a storefront

In a catalog, you can use the nodes directly attached to a product to build breadcrumbs in your storefront. This eliminates the need for additional queries to fetch hierarchy or parent node details. Each node contains all the necessary information in breadcrumbs metadata, such as its own details and the details of its parent hierarchy/node(s), to construct the complete breadcrumb path without requiring additional queries.

An example is shown below:

filter=in(id,c83bfe55-0d87-4302-a86d-ab19e7e323f1,6003d7ef-84f3-49bb-a8bd-4cbfa203dcbb)

  • Specify the node IDs directly attached to the product in the filter expression.
  • You can include as many node IDs as required.
  • It does not matter what order you specify the node IDs. The nodes are returned in the order they were last updated.

Request

Responses

The nodes of the catalog.

Authorization: Authorization

name: Authorizationtype: httpin: headerscheme: bearer
var client = new HttpClient();
var request = new HttpRequestMessage(HttpMethod.Get, "https://euwest.api.elasticpath.com/catalog/nodes");
request.Headers.Add("Accept", "application/json");
request.Headers.Add("Authorization", "Bearer <Authorization>");
var response = await client.SendAsync(request);
response.EnsureSuccessStatusCode();
Console.WriteLine(await response.Content.ReadAsStringAsync());
Request Collapse all
Base URL
https://euwest.api.elasticpath.com
Auth
Parameters
— query
— query
— query
— header
— header
— header
ResponseClear

Click the Send API Request button above and see the response here!