commercetools icon

commercetools

Interact with the commercetools API. Operations are auto-generated from the official Postman collection.

Actions671

Store Business Unit → Delete BusinessUnit in Store by ID

AI-generated

Summary

Delete a specific business unit within a designated store in the commercetools platform using its unique ID and version number.

Inputs

  • Store Key (required) — The unique key of the store that contains the business unit to delete.
  • Store Business Unit Key (required) — The unique key identifying the business unit resource (though the operation primarily uses Business Unit ID).
  • Business Unit ID (required) — The unique identifier of the business unit within the store to delete.
  • Version (required) — The current version number of the business unit resource, required for concurrency control during deletion.

Output shape

a single JSON object representing the deleted business unit resource as returned by the commercetools API.

Requires passing the correct version to successfully delete; if the version is stale or incorrect, the API will reject the request. Errors produce an exception unless 'Continue on Fail' is set.

Examples

Example 1: To remove a business unit by its ID within a specific store, specify the store's key, the business unit's key and ID, and provide the current version of that business unit. The node sends a DELETE request to the commercetools API and returns the deleted resource's details.

Set 'resource' to 'Store Business Unit', 'operation' to 'Delete BusinessUnit in Store by ID', then supply the required 'storeKey', 'resourceKey' (business unit key), 'secondaryId' (business unit ID), and 'version' parameters.

Links

Discussion