openapi: 3.1.0
info:
version: 25.1126.6886238
x-version-timestamp: 2025-11-26 19:10:23+00:00
title: Addresses Introduction Account Addresses Hierarchies API
description: 'The Addresses API allows you to organize account addresses. Addresses are a sub-resource of `account` resources, an account can have multiple addresses, such as home, work, and neighbour.
You can use an account address with either [client_credentials access token](/docs/api/authentication/create-an-access-token) or a combination of [implicit access token](/docs/api/authentication/create-an-access-token) and [Account Management authentication](/docs/api/accounts/post-v-2-account-members-tokens) token.
'
contact:
name: Elastic Path
url: https://www.elasticpath.com
email: support@elasticpath.com
license:
url: https://elasticpath.dev
name: MIT
servers:
- url: https://useast.api.elasticpath.com
description: US East
- url: https://euwest.api.elasticpath.com
description: EU West
security:
- BearerToken: []
tags:
- name: Hierarchies
description: "```mdx-code-block\nimport HierarchyOverview from '/docs/partials/pxm/hierarchies/hierarchies.mdx';\nimport HierarchyCatalog from '/docs/partials/pxm/hierarchies/hierarchycatalogs.mdx';\n\n<HierarchyOverview />\n\n## Creating Hierarchies and Nodes\n\nYou can create the **Major Appliances** hierarchy by performing the following steps.\n\n1. Using [**Create a Hierarchy**](/docs/api/pxm/products/create-hierarchy), create a hierarchy whose name is **Major Appliances**. Each hierarchy has a hierarchy ID. In other words, the hierarchy ID is the ID of the root node.\n1. Using [**Create a Node in a hierarchy**](/docs/api/pxm/products/create-node), create the following child nodes. When you create a node in a hierarchy, by default, the node is a child of the root node. Specify `sort_order` to configure the order of the nodes.\n - **Ranges**\n - **Refrigerators**\n - **Dishwashers**\n1. Using [**Create a Node in a hierarchy**](/docs/api/pxm/products/create-node), create the **Electric Ranges** node, specifying **Ranges** as the parent node.\n1. Using [**Create a Node in a hierarchy**](/docs/api/pxm/products/create-node), create the following nodes, specifying **Electric Ranges** as the parent node.\n - **Electric Ranges 24ˮ**\n - **Electric Ranges 30ˮ**\n - **Double Oven**\n1. Using [**Create a Node in a hierarchy**](/docs/api/pxm/products/create-node), create the **Gas Ranges** node, specifying **Ranges** as the parent node.\n1. Using [**Create a Node in a hierarchy**](/docs/api/pxm/products/create-node), create the following nodes, specifying **Gas Ranges** as the parent node.\n - **Gas Ranges 24ˮ**\n - **Gas Ranges 30ˮ**\n - **Gas Ranges 32\"**\n - **Double Oven**\n1. Using [**Create a Node in a hierarchy**](/docs/api/pxm/products/create-node), create the following nodes, specifying **Dishwashers** as the parent node.\n - **Built-in**\n - **Standalone**\n\n## Hierarchies and Catalogs\n\n<HierarchyCatalog />\n\n```\n"
paths:
/pcm/hierarchies:
post:
summary: Create a hierarchy
description: '```mdx-code-block
import CASummary from ''/docs/partials/pxm/custom-attributes/custom-attribute-spec-summary.mdx'';
Creates a hierarchy with a name, description, and slug to organize products in your catalog.
<CASummary />
```
'
operationId: createHierarchy
tags:
- Hierarchies
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/create_hierarchy'
examples:
create-hierarchy:
$ref: '#/components/examples/create_hierarchy'
required: true
responses:
'201':
description: Returns a created hierarchy with the following attributes.
content:
application/json:
schema:
$ref: '#/components/schemas/single_hierarchy'
examples:
created-hierarchy:
$ref: '#/components/examples/hierarchy_created'
'422':
$ref: '#/components/responses/unprocessable_entity'
'500':
$ref: '#/components/responses/internal'
get:
operationId: getHierarchy
parameters:
- $ref: '#/components/parameters/page_offset'
- $ref: '#/components/parameters/page_limit'
- $ref: '#/components/parameters/filter_nodes'
summary: Get all hierarchies
description: "Get all hierarchies\n\n#### Pagination\n\nThis endpoint supports offset-based pagination using `page[offset]` and `page[limit]` query parameters.\n\n:::caution Planned pagination changes — on or after 1 September 2026\n\nThe pagination links returned by this endpoint currently differ from the Elastic Path Commerce Cloud platform standard. Specifically, the `current` link is not returned, `first`/`last` are not always present, `prev` is incorrectly omitted on the second page, and `next` is incorrectly omitted on the second-to-last page.\n\nOn or after **1 September 2026**, this endpoint will be updated so that `current` and `first` are always present, `last` is present on every page except the final page, `next` is present on every page except the last, and `prev` is present on every page except the first. See the [links](#links) schema for full details.\n\nIf your integration iterates through pages using these links, please verify that it will handle the updated behaviour correctly before this date.\n\n:::\n\n#### Filtering\n \nMany Commerce API endpoints support filtering. The general syntax is described in [**Filtering**](/guides/Getting-Started/filtering).\n\nThe following attributes and operators are supported.\n\n| Operator | Attribute | Description | Example |\n|----------------|------------------------------------------------------------------------------------------|------------------------------------------------------------------------------------------------|------------------------------------------|\n| `eq` | `id`, `hierarchy_id`, `owner`, `parent_id`, `name`, `slug`, `description`, `has_children`, `created_at`, `updated_at`, `locales.[locale].name`, `locales.[locale].description`, `breadcrumbs.id`, `breadcrumbs.name`, `breadcrumbs.slug`, `breadcrumbs.locales.[locale].name` | Equals. Checks if the value of the attribute matches the specified value. | `filter=eq(name,some-name)`, `filter=eq(locales.fr-FR.name,Nom-du-produit)` |\n| `in` | `id`, `hierarchy_id`, `parent_id`, `breadcrumbs.id` | Checks if the value of the attribute is included in the specified list. | `filter=in(id,1,2,3,4)` |\n| `lt`, `le`, `gt`, `ge` | `id`, `hierarchy_id`, `parent_id`, `created_at`, `updated_at` | Comparison operators. `lt`: Less than, `le`: Less than or equal to, `gt`: Greater than, `ge`: Greater than or equal to. | `filter=lt(id,100)`, `filter=ge(created_at,2022-01-01)` |\n| `like` | `name`, `slug`, `description`, `locales.[locale].name`, `locales.[locale].description`, `breadcrumbs.name`, `breadcrumbs.slug`, `breadcrumbs.locales.[locale].name` | Like. Checks if the attribute contains the specified string (wildcards supported). | `filter=like(name,*some-name*)`, `filter=like(locales.es-ES.description,*descripción*)` |\n"
tags:
- Hierarchies
responses:
'200':
description: Returns a list of all hierarchies.
content:
application/json:
schema:
$ref: '#/components/schemas/multi_hierarchy'
examples:
list-hierarchies:
$ref: '#/components/examples/resp_multi_hierarchy'
'400':
$ref: '#/components/responses/bad_request'
'500':
$ref: '#/components/responses/internal'
/pcm/hierarchies/nodes:
get:
parameters:
- $ref: '#/components/parameters/page_offset'
- $ref: '#/components/parameters/filter_nodes'
- $ref: '#/components/parameters/page_limit'
- $ref: '#/components/parameters/include_hierarchies'
summary: List all nodes
operationId: getAllNodes
description: 'A fully paginated view of all nodes in all hierarchies regardless of depth.
#### Filtering
Many Commerce API endpoints support filtering. The general syntax is described in [**Filtering**](/guides/Getting-Started/filtering).
The following attributes and operators are supported.
| Operator | Attribute | Description | Example |
|----------------|------------------------------------------------------------------------------------------|------------------------------------------------------------------------------------------------|------------------------------------------|
| `eq` | `id`, `hierarchy_id`, `owner`, `parent_id`, `name`, `slug`, `description`, `has_children`, `created_at`, `updated_at`, `locales.[locale].name`, `locales.[locale].description`, `breadcrumbs.id`, `breadcrumbs.name`, `breadcrumbs.slug`, `breadcrumbs.locales.[locale].name` | Equals. Checks if the value of the attribute matches the specified value. | `filter=eq(name,some-name)`, `filter=eq(locales.fr-FR.name,Nom-du-produit)` |
| `in` | `id`, `hierarchy_id`, `parent_id`, `breadcrumbs.id` | Checks if the value of the attribute is included in the specified list. | `filter=in(id,1,2,3,4)` |
| `lt`, `le`, `gt`, `ge` | `id`, `hierarchy_id`, `parent_id`, `created_at`, `updated_at` | Comparison operators. `lt`: Less than, `le`: Less than or equal to, `gt`: Greater than, `ge`: Greater than or equal to. | `filter=lt(id,100)`, `filter=ge(created_at,2022-01-01)` |
| `like` | `name`, `slug`, `description`, `locales.[locale].name`, `locales.[locale].description`, `breadcrumbs.name`, `breadcrumbs.slug`, `breadcrumbs.locales.[locale].name` | Like. Checks if the attribute contains the specified string (wildcards supported). | `filter=like(name,*some-name*)`, `filter=like(locales.es-ES.description,*descripción*)` |
| `ilike` | `name`, `slug`, `description`, `locales.[locale].name`, `locales.[locale].description`, `breadcrumbs.name`, `breadcrumbs.slug`, `breadcrumbs.locales.[locale].name` | Case-insensitive like. Same as `like` but ignores case when matching. | `filter=ilike(name,*some-name*)` |
'
tags:
- Hierarchies
responses:
'200':
description: Returns a list of nodes
content:
application/json:
schema:
$ref: '#/components/schemas/nodes_or_hierarchies'
examples:
get-all-nodes:
$ref: '#/components/examples/resp_multi_nodes_or_hierarchies'
'400':
$ref: '#/components/responses/bad_request'
'404':
$ref: '#/components/responses/not_found'
'500':
$ref: '#/components/responses/internal'
/pcm/hierarchies/{hierarchyID}:
get:
parameters:
- $ref: '#/components/parameters/hierarchy_id'
summary: Get a hierarchy
description: Retrieves the specified hierarchy.
operationId: getHierarchyChild
tags:
- Hierarchies
responses:
'200':
description: Returns a hierarchy with the following attributes.
content:
application/json:
schema:
$ref: '#/components/schemas/single_hierarchy'
examples:
get-hierarchy:
$ref: '#/components/examples/hierarchy_created'
'400':
$ref: '#/components/responses/bad_request'
'404':
$ref: '#/components/responses/not_found'
'500':
$ref: '#/components/responses/internal'
put:
operationId: updateHierarchy
parameters:
- $ref: '#/components/parameters/hierarchy_id'
summary: Update a hierarchy
description: '```mdx-code-block
import CASummary from ''/docs/partials/pxm/custom-attributes/custom-attribute-spec-summary.mdx'';
Updates a hierarchy. You can do a partial update, where you specify only the field value to change.
<CASummary />
```
'
tags:
- Hierarchies
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/update_hierarchy'
examples:
update-hierarchy:
$ref: '#/components/examples/update_hierarchy'
required: true
responses:
'200':
description: Successfully returns the updated hierarchy
content:
application/json:
schema:
$ref: '#/components/schemas/single_hierarchy'
examples:
updated-hierarchy:
$ref: '#/components/examples/hierarchy_updated'
'403':
$ref: '#/components/responses/forbidden'
'404':
$ref: '#/components/responses/not_found'
'422':
$ref: '#/components/responses/unprocessable_entity'
'500':
$ref: '#/components/responses/internal'
delete:
operationId: deleteHierarchy
parameters:
- $ref: '#/components/parameters/hierarchy_id'
summary: Delete a hierarchy
description: Deletes the specified hierarchy and all its children.
tags:
- Hierarchies
responses:
'204':
description: No Content
'403':
$ref: '#/components/responses/forbidden'
'500':
$ref: '#/components/responses/internal'
/pcm/hierarchies/{hierarchyID}/nodes:
post:
parameters:
- $ref: '#/components/parameters/hierarchy_id'
summary: Create a node
description: "```mdx-code-block\nimport CASummary from '/docs/partials/pxm/custom-attributes/custom-attribute-spec-summary.mdx';\n\nCreates a node in the specified hierarchy.\n\n<CASummary /> \n```\n\n ### Sorting Nodes in a Hierarchy\n \n You can sort the order of your nodes, regardless of where the nodes are in the hierarchy.\n\n You can do this by adding a `meta` object to the body of your request and specifying a `sort_order` value.\n \n The node with the highest value of `sort_order` is displayed first. For example, a node with a `sort_order` value of `3` appears before a node with a `sort_order` value of `2`.\n\n - If you don’t provide `sort_order` when creating nodes, all child nodes in the response for Get a Node’s Children request are ordered by the `updated_at` time in descending order, with the most recently updated child node first.\n - If you set `sort_order` for only a few child nodes, the child nodes with a `sort_order` value appear first and then other child nodes appear in the order of `updated_at` time.\n\n You can also specify a `sort_order` when creating a node relationship.\n\n - If you create a node (**Node A**) with a `sort_order` and then you create a relationship for **Node A** with another node (**Node B**), the `sort_order` you specified when creating **Node A** is overwritten.\n - If you create **Node A** and then you create a relationship with **Node B** but do not configure a `sort_order`, the `sort_order` you specified when you created **Node A** is not overwritten.\n \n ### Curating Products in a Node\n \n You can curate the products in a node. Product curation allows you to promote specific products within each node of your hierarchies, enabling you to create unique product collections in your storefront. For example, you may find you have an abundance of cotton T-Shirts and you want to promote these products to the top of the product list. When a shopper navigates to T-shirts, the cotton T-Shirts are displayed first.\n \n You can do this by adding a `curated_products` attribute to the body of your request and adding an array of product IDs to the attribute. You should add the products IDs in the order you want them to be displayed in your node. The first product ID is displayed first in the product list.\n \n You can only curate 20 products or less. You cannot have more than 20 curated products.\n \n - The product IDs you provide must exist in the specified node.\n - If a curated product is removed from a node, the product is also removed from the curated_products list.\n - Once you have curated the products in a node, you can use the get node products endpoint to retrieve a list of curated products.\n \n You can then display your curated products in your catalogs using the following catalog endpoints.\n \n - Get a node in your latest catalog release.\n - Get a node in a catalog.\n - Get all nodes in your latest catalog release.\n - Get all nodes in a catalog.\n - Get node children in your latest catalog release.\n - Get node children in a catalog.\n"
operationId: createNode
tags:
- Hierarchies
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/create_node'
examples:
create-node:
$ref: '#/components/examples/create_node'
responses:
'201':
description: Successfully returns the created node
content:
application/json:
schema:
$ref: '#/components/schemas/single_node'
examples:
created-node:
$ref: '#/components/examples/node_created'
'403':
$ref: '#/components/responses/forbidden'
'404':
$ref: '#/components/responses/not_found'
'422':
$ref: '#/components/responses/unprocessable_entity'
'500':
$ref: '#/components/responses/internal'
get:
parameters:
- $ref: '#/components/parameters/hierarchy_id'
- $ref: '#/components/parameters/filter_nodes'
- $ref: '#/components/parameters/page_offset'
- $ref: '#/components/parameters/page_limit'
summary: Get all nodes in a hierarchy
description: 'A fully paginated view of all nodes in a hierarchy regardless of depth.
#### Filtering
Many Commerce API endpoints support filtering. The general syntax is described in [**Filtering**](/guides/Getting-Started/filtering).
The following attributes and operators are supported.
| Operator | Attribute | Description | Example |
|----------------|------------------------------------------------------------------------------------------|------------------------------------------------------------------------------------------------|------------------------------------------|
| `eq` | `id`, `hierarchy_id`, `owner`, `parent_id`, `name`, `slug`, `description`, `has_children`, `created_at`, `updated_at`, `locales.[locale].name`, `locales.[locale].description`, `breadcrumbs.id`, `breadcrumbs.name`, `breadcrumbs.slug`, `breadcrumbs.locales.[locale].name` | Equals. Checks if the value of the attribute matches the specified value. | `filter=eq(name,some-name)`, `filter=eq(locales.fr-FR.name,Nom-du-produit)` |
| `in` | `id`, `hierarchy_id`, `parent_id`, `breadcrumbs.id` | Checks if the value of the attribute is included in the specified list. | `filter=in(id,1,2,3,4)` |
| `lt`, `le`, `gt`, `ge` | `id`, `hierarchy_id`, `parent_id`, `created_at`, `updated_at` | Comparison operators. `lt`: Less than, `le`: Less than or equal to, `gt`: Greater than, `ge`: Greater than or equal to. | `filter=lt(id,100)`, `filter=ge(created_at,2022-01-01)` |
| `like` | `name`, `slug`, `description`, `locales.[locale].name`, `locales.[locale].description`, `breadcrumbs.name`, `breadcrumbs.slug`, `breadcrumbs.locales.[locale].name` | Like. Checks if the attribute contains the specified string (wildcards supported). | `filter=like(name,*some-name*)`, `filter=like(locales.es-ES.description,*descripción*)` |
| `ilike` | `name`, `slug`, `description`, `locales.[locale].name`, `locales.[locale].description`, `breadcrumbs.name`, `breadcrumbs.slug`, `breadcrumbs.locales.[locale].name` | Case-insensitive like. Same as `like` but ignores case when matching. | `filter=ilike(name,*some-name*)` |
'
operationId: getAllNodesInHierarchy
tags:
- Hierarchies
responses:
'200':
description: Successfully returns the node's children
content:
application/json:
schema:
$ref: '#/components/schemas/multi_nodes'
examples:
get-all-nodes:
$ref: '#/components/examples/resp_multi_nodes'
'400':
$ref: '#/components/responses/bad_request'
'404':
$ref: '#/components/responses/not_found'
'500':
$ref: '#/components/responses/internal'
/pcm/hierarchies/{hierarchyID}/nodes/{nodeID}:
get:
parameters:
- $ref: '#/components/parameters/hierarchy_id'
- $ref: '#/components/parameters/node_id'
summary: Get a node
description: Retrieves a node from a hierarchy.
operationId: getHierarchyNode
tags:
- Hierarchies
responses:
'200':
description: Returns a node with the following attributes.
content:
application/json:
schema:
$ref: '#/components/schemas/single_node'
examples:
get-node:
$ref: '#/components/examples/node_created'
'400':
$ref: '#/components/responses/bad_request'
'404':
$ref: '#/components/responses/not_found'
'500':
$ref: '#/components/responses/internal'
put:
parameters:
- $ref: '#/components/parameters/hierarchy_id'
- $ref: '#/components/parameters/node_id'
summary: Update a node
description: "```mdx-code-block\nimport CASummary from '/docs/partials/pxm/custom-attributes/custom-attribute-spec-summary.mdx';\n\nUpdates the specified node in a hierarchy. You can do a partial update, where you specify only the field value to change.\n\n<CASummary /> \n```\n\n### Sorting Nodes in a Hierarchy\n\nYou can sort the order of your nodes, regardless of where the nodes are in the hierarchy.\n \n The node with the highest value of sort_order is displayed first. For example, a node with a `sort_order` value of `3` appears before a node with a `sort_order` value of `2`.\n \n - If you don’t provide `sort_order` when creating nodes, all child nodes in the response for Get a Node’s Children request are ordered by the `updated_at` time in descending order, with the most recently updated child node first.\n - If you set `sort_order` for only a few child nodes or not all, the child nodes with a `sort_order` value appear first and then other child nodes appear in the order of `updated_at` time.\n \n You can also specify a sort_order when creating a node relationship.\n\n - If you update a node (**Node A**) with a `sort_order` and then you create a relationship for **Node A** with another node (**Node B**), the `sort_order` you specified when updating **Node A** is overwritten.\n - If you have updated **Node A** and then you create a relationship with **Node B** but do not configure a `sort_order`, the `sort_order` you specified when you updated **Node A** is not overwritten.\n \n ### Curating Products in a Node\n\n You can curate the products in a node. Product curation allows you to promote specific products within each node of your hierarchies, enabling you to create unique product collections in your storefront. For example, you may find you have an abundance of cotton T-Shirts and you want to promote these products to the top of the product list. When a shopper navigates to T-shirts, the cotton T-Shirts are displayed first.\n\n You can do this by adding a `curated_products` attribute to the body of your request and adding an array of product IDs to the attribute. You should add the products IDs in the order you want them to be displayed in your node. The first product ID is displayed first in the product list.\n\n You can only curate 20 products or less. You cannot have more than 20 curated products.\n \n - The product IDs you provide must exist in the specified node.\n - If a curated product is removed from a node, the product is also removed from the curated_products list.\n - Once you have curated the products in a node, you can use the get node products endpoint to retrieve a list of curated products.\n \n You can then display your curated products in your catalogs using the following catalog endpoints.\n \n - [Get a node in your latest catalog release](/docs/api/pxm/catalog/get-node)\n - [Get a node in a catalog](/docs/api/pxm/catalog/get-by-context-node)\n - [Get all nodes in your latest catalog release](/docs/api/pxm/catalog/get-all-nodes)\n - [Get all nodes in a catalog](/docs/api/pxm/catalog/get-by-context-all-nodes)\n - [Get node children in your latest catalog release](/docs/api/pxm/catalog/get-child-nodes)\n - [Get node children in a catalog](/docs/api/pxm/catalog/get-by-context-child-nodes)\n"
operationId: updateNode
tags:
- Hierarchies
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/update_node'
examples:
update-node:
$ref: '#/components/examples/update_node'
responses:
'200':
description: Successfully returns the updated node
content:
application/json:
schema:
$ref: '#/components/schemas/single_node'
examples:
updated-node:
$ref: '#/components/examples/node_updated'
'403':
$ref: '#/components/responses/forbidden'
'404':
$ref: '#/components/responses/not_found'
'422':
$ref: '#/components/responses/unprocessable_entity'
'500':
$ref: '#/components/responses/internal'
delete:
parameters:
- $ref: '#/components/parameters/hierarchy_id'
- $ref: '#/components/parameters/node_id'
summary: Deletes a node
description: Deletes a node by the node ID
operationId: deleteNode
tags:
- Hierarchies
responses:
'204':
description: No Content
'403':
$ref: '#/components/responses/forbidden'
'422':
$ref: '#/components/responses/unprocessable_entity'
'500':
$ref: '#/components/responses/internal'
/pcm/hierarchies/{hierarchyID}/children:
get:
parameters:
- $ref: '#/components/parameters/hierarchy_id'
- $ref: '#/components/parameters/filter_nodes'
- $ref: '#/components/parameters/page_offset'
- $ref: '#/components/parameters/page_limit'
summary: Get a hierarchy's children
description: 'Get a hierarchy''s children
#### Filtering
Many Commerce API endpoints support filtering. The general syntax is described in [**Filtering**](/guides/Getting-Started/filtering).
The following attributes and operators are supported.
| Operator | Attribute | Description | Example |
|----------------|------------------------------------------------------------------------------------------|------------------------------------------------------------------------------------------------|------------------------------------------|
| `eq` | `id`, `hierarchy_id`, `owner`, `parent_id`, `name`, `slug`, `description`, `has_children`, `created_at`, `updated_at`, `locales.[locale].name`, `locales.[locale].description`, `breadcrumbs.id`, `breadcrumbs.name`, `breadcrumbs.slug`, `breadcrumbs.locales.[locale].name` | Equals. Checks if the value of the attribute matches the specified value. | `filter=eq(name,some-name)`, `filter=eq(locales.fr-FR.name,Nom-du-produit)` |
| `in` | `id`, `hierarchy_id`, `parent_id`, `breadcrumbs.id` | Checks if the value of the attribute is included in the specified list. | `filter=in(id,1,2,3,4)` |
| `lt`, `le`, `gt`, `ge` | `id`, `hierarchy_id`, `parent_id`, `created_at`, `updated_at` | Comparison operators. `lt`: Less than, `le`: Less than or equal to, `gt`: Greater than, `ge`: Greater than or equal to. | `filter=lt(id,100)`, `filter=ge(created_at,2022-01-01)` |
| `like` | `name`, `slug`, `description`, `locales.[locale].name`, `locales.[locale].description`, `breadcrumbs.name`, `breadcrumbs.slug`, `breadcrumbs.locales.[locale].name` | Like. Checks if the attribute contains the specified string (wildcards supported). | `filter=like(name,*some-name*)`, `filter=like(locales.es-ES.description,*descripción*)` |
| `ilike` | `name`, `slug`, `description`, `locales.[locale].name`, `locales.[locale].description`, `breadcrumbs.name`, `breadcrumbs.slug`, `breadcrumbs.locales.[locale].name` | Case-insensitive like. Same as `like` but ignores case when matching. | `filter=ilike(name,*some-name*)` |
'
operationId: getAllChildren
tags:
- Hierarchies
responses:
'200':
description: Returns the hierarchy's children.
content:
application/json:
schema:
$ref: '#/components/schemas/multi_nodes'
examples:
get-hierarchy-children:
$ref: '#/components/examples/resp_multi_nodes'
'400':
$ref: '#/components/responses/bad_request'
'404':
$ref: '#/components/responses/not_found'
'500':
$ref: '#/components/responses/internal'
/pcm/hierarchies/{hierarchyID}/relationships/children:
post:
parameters:
- $ref: '#/components/parameters/hierarchy_id'
summary: Create relationships between a hierarchy and child nodes
description: 'Use this endpoint to create relationships between a hierarchy and one or more child nodes. You can create a relationship only if:
- All child nodes already exist.
- Every child node in the request body must belong to this hierarchy.
- All siblings in a hierarchy must have a unique `name` and `slug`. Siblings are the child nodes that are related to the same parent.
### Sort Order
You can also provide `sort_order` information when you create a relationship by adding a `meta` object to the array of node reference objects for each child node that requires sorting.
The node with the highest value of `sort_order` appears at the top of the response. For example, a node with a `sort_order` value of `3` appears before a node with a `sort_order` value of `2`.
- If you don’t provide `sort_order` when creating relationships, all child nodes in the response for Get a Hierarchy’s Children request are ordered by the `updated_at` time in descending order. The most recently updated child node appears at the top of the response.
- If you set `sort_order` for only a few child nodes or not all, the child nodes with `sort_order` value appear first in the response and then other child nodes appear in the order of `updated_at` time.
You can also specify a `sort_order` when creating and updating a node.
-
# --- truncated at 32 KB (127 KB total) ---
# Full source: https://raw.githubusercontent.com/api-evangelist/elastic-path/refs/heads/main/openapi/elastic-path-hierarchies-api-openapi.yml