---
title: "Relationship commands and pipelines"
slug: "relationship-commands-and-pipelines"
abstract: ""
---
# Relationship commands and pipelines

The following table describes the relationship commands and pipelines:

> [!important]
> Some commands, like the `AssociateSellableItemToParentCommand`, change the entity version in the database. Verify the version before calling an update operation because update operations require the entity version to match the value in the database.

| **Command/Pipeline** | **Description** |
| --- | --- |
| `AssociateCategoryToParentCommand`<br><br>`AssociateCategoryToParentPipeline` | Associates a category to a parent entity.<br><br>Parameters:<br><br><ul><li>`catalogId`: identifier for the catalog to which the category belongs</li><li>`parentId`: identifier for the parent entity</li><li>`categoryID`: identifier for the category</li></ul> |
| `AssociateSellableItemToParentCommand`<br><br>`AssociateSellableItemToParentPipeline` | Associates a sellable item to a parent entity.<br><br>Parameters:<br><br><ul><li>`catalogId`: identifier for the catalog</li><li>`parentId`: identifier for the parent entity</li><li>`sellableItemID`: identifier for the sellable item</li></ul> |
| `CreateRelationshipCommand`<br><br>`CreateRelationshipPipeline` | Creates a relationship between two entities.<br><br>Parameters:<br><br><ul><li>`catalogName`: identifier for the catalog</li><li>`sourceName`: name of the source entity</li><li>`targetName` : name of the target entity</li><li>`relationshipType`: type of relationship between the two entities</li></ul> |
| `CreateRelationshipTypeCommand`<br><br>`CreateRelationshipTypePipeline` | Creates a relationship type (for the association of specific entities).<br><br>Parameters:<br><br><ul><li>`relationshipTypeName`: name of the relationship type</li><li>`relationshipTypeDisplayName`: display name for the relationship type</li><li>`relationshipTypeDescription`: description of the relationship type</li><li>`sourceType`: the type of entity for the source (e.g., catalog, category, sellable item)</li><li>`targetType`: the type of entity for the target (e.g., catalog, category, sellable item)</li><li>`renderList`: indicates whether a list is rendered on the matching entity view</li></ul> |
| `DeleteRelationshipCommand`<br><br>`DeleteRelationshipPipeline` | Deletes a relationship between two entities.<br><br>Parameters:<br><br><ul><li>`catalogName`: identifier for the catalog</li><li>`sourceName`: name of the source entity</li><li>`targetName` : name of the target entity</li><li>`relationshipType`: type of relationship between the two entities</li></ul> |
| `EditRelationshipTypeCommand`<br><br>`EditRelationshipTypePipeline` | Modifies a relationship type (for the association of specific entities).<br><br>Parameters:<br><br><ul><li>`relationshipType`: type of the relationship</li><li>`relationshipTypeDisplayName`: display name for the relationship type</li><li>`relationshipTypeDescription`: description of the relationship type</li><li>`renderList`: indicates whether a list is rendered on the matching entity view</li></ul> |
| `GetRelationshipTypeCommand`<br><br>`GetRelationshipTypePipeline` | Retrieves the specified relationship type.<br><br>Parameters:<br><br><ul><li>`arg`: the relationship type</li></ul> |
| `GetRelationshipTypesCommand`<br><br>`GetRelationshipTypesPipeline` | Retrieves a list of all relationship types defined in the system.<br><br>Parameters: none. |