Skip to main content
Server path: /commercetools-discounts | Type: Application | PCID required: Yes

Tools

ToolDescription
commercetools_discounts_create_cart_discountsCreating a Cart Discount produces the CartDiscountCreated Message.
commercetools_discounts_create_discount_codesCreating a Discount Code produces the DiscountCodeCreated Message. Deprecated OAuth 2.0 Scope: manage_orders:{projectKey}
commercetools_discounts_create_discount_groupsCreates a DiscountGroup in the Project. This request generates the DiscountGroupCreated Message. If the limit for active Discount Groups has been reached, a MaxDiscountGroupsReached error is returned.
commercetools_discounts_create_product_discountsPOST /product-discounts
commercetools_discounts_create_product_discounts_matchingThis endpoint can be used to simulate which Product Discounts would be applied if a specified Product Variant had a specified Price. Given Product and Product Variant IDs and a Price, this endpoint will return the ProductDiscount that would have been applied to that Price. If a Product Discount could not be found that could be applied to the Price of a Product Variant, a NoMatchingProductDiscountFound error is returned.
commercetools_discounts_create_standalone_pricesCreating a Standalone Price produces the StandalonePriceCreated Message. - If the Standalone Price has the same price scope as an existing Standalone Price, a DuplicateStandalonePriceScope error is returned. - If the Standalone Price has overlapping validity periods within the same price scope, a OverlappingStandalonePriceValidity error is returned. A Price without validity period does not conflict with a Price defined for a time period. - If a modification is already in progress for the exact combination of SKU and price scope fields, an ExactLockConflict or ValidityLockConflict error is returned.
commercetools_discounts_delete_cart_discounts_by_idDeleting a Cart Discount produces the CartDiscountDeleted Message.
commercetools_discounts_delete_cart_discounts_by_keyDeleting a Cart Discount produces the CartDiscountDeleted Message.
commercetools_discounts_delete_discount_codes_by_idDeleting a Discount Code produces the DiscountCodeDeleted Message. Deprecated OAuth 2.0 Scope: manage_orders:{projectKey}
commercetools_discounts_delete_discount_codes_by_keyDeleting a Discount Code produces the DiscountCodeDeleted Message. Deprecated OAuth 2.0 Scope: manage_orders:{projectKey}
commercetools_discounts_delete_discount_groups_by_idDeletes a DiscountGroup in the Project. This request generates the DiscountGroupDeleted Message. If the DiscountGroup is referenced by a CartDiscount, a ReferenceExists error is returned.
commercetools_discounts_delete_discount_groups_by_keyDeletes a DiscountGroup in the Project. This request generates the DiscountGroupDeleted Message. If the DiscountGroup is referenced by a CartDiscount, a ReferenceExists error is returned.
commercetools_discounts_delete_product_discounts_by_idDELETE /product-discounts/{ID}
commercetools_discounts_delete_product_discounts_by_keyDELETE /product-discounts/key={key}
commercetools_discounts_delete_standalone_prices_by_idProduces the StandalonePriceDeleted Message.
commercetools_discounts_delete_standalone_prices_by_keyProduces the StandalonePriceDeleted Message.
commercetools_discounts_get_cart_discounts_by_idGET /cart-discounts/{ID}
commercetools_discounts_get_cart_discounts_by_keyGET /cart-discounts/key={key}
commercetools_discounts_get_discount_codes_by_idDeprecated OAuth 2.0 Scope: view_orders:{projectKey}
commercetools_discounts_get_discount_codes_by_keyDeprecated OAuth 2.0 Scope: view_orders:{projectKey}
commercetools_discounts_get_discount_groups_by_idRetrieves a DiscountGroup with the provided id.
commercetools_discounts_get_discount_groups_by_keyRetrieves a DiscountGroup with the provided key.
commercetools_discounts_get_product_discounts_by_idGET /product-discounts/{ID}
commercetools_discounts_get_product_discounts_by_keyGET /product-discounts/key={key}
commercetools_discounts_get_standalone_prices_by_idGET /standalone-prices/{ID}
commercetools_discounts_get_standalone_prices_by_keyGET /standalone-prices/key={key}
commercetools_discounts_list_cart_discountsGET /cart-discounts
commercetools_discounts_list_discount_codesDeprecated OAuth 2.0 Scope: view_orders:{projectKey}
commercetools_discounts_list_discount_groupsRetrieves all DiscountGroups in the Project.
commercetools_discounts_list_product_discountsGET /product-discounts
commercetools_discounts_list_standalone_pricesGET /standalone-prices
commercetools_discounts_update_cart_discounts_by_idPOST /cart-discounts/{ID}
commercetools_discounts_update_cart_discounts_by_keyPOST /cart-discounts/key={key}
commercetools_discounts_update_discount_codes_by_idDeprecated OAuth 2.0 Scope: manage_orders:{projectKey}
commercetools_discounts_update_discount_codes_by_keyDeprecated OAuth 2.0 Scope: manage_orders:{projectKey}
commercetools_discounts_update_discount_groups_by_idUpdates a DiscountGroup in the Project using one or more update actions.
commercetools_discounts_update_discount_groups_by_keyUpdates a DiscountGroup in the Project using one or more update actions.
commercetools_discounts_update_product_discounts_by_idPOST /product-discounts/{ID}
commercetools_discounts_update_product_discounts_by_keyPOST /product-discounts/key={key}
commercetools_discounts_update_standalone_prices_by_idIf a modification is already in progress for the exact combination of SKU and price scope fields, an ExactLockConflict or ValidityLockConflict error is returned.
commercetools_discounts_update_standalone_prices_by_keyIf a modification is already in progress for the exact combination of SKU and price scope fields, an ExactLockConflict or ValidityLockConflict error is returned.

commercetools_discounts_create_cart_discounts

Creating a Cart Discount produces the CartDiscountCreated Message. Parameters:
ParameterTypeRequiredDefaultDescription
expandstring[]NoRelated resources to expand inline
cartPredicatestringYesCart Predicate
customobjectNoThe custom value
descriptionobjectNoThe description value
discountGroupobjectNoDiscount Group
isActivebooleanNoIs Active
keystringNoThe key value
nameobjectYesThe name value
recurringOrderScopeobjectNoRecurring Order Scope
requiresDiscountCodebooleanNoRequires Discount Code
sortOrderstringNoSort Order
stackingModestringNoStacking Mode
storesany[]NoThe stores value
targetobjectNoThe target value
validFromstringNoValid From
validUntilstringNoValid Until
valueobjectYesThe value value

commercetools_discounts_create_discount_codes

Creating a Discount Code produces the DiscountCodeCreated Message. Deprecated OAuth 2.0 Scope: manage_orders:{projectKey} Parameters:
ParameterTypeRequiredDefaultDescription
expandstring[]NoRelated resources to expand inline
cartDiscountsany[]YesCart Discounts
cartPredicatestringNoCart Predicate
codestringYesThe code value
customobjectNoThe custom value
descriptionobjectNoThe description value
groupsstring[]NoThe groups value
isActivebooleanNoIs Active
keystringNoThe key value
maxApplicationsintegerNoMax Applications
maxApplicationsPerCustomerintegerNoMax Applications Per Customer
nameobjectNoThe name value
validFromstringNoValid From
validUntilstringNoValid Until

commercetools_discounts_create_discount_groups

Creates a DiscountGroup in the Project. This request generates the DiscountGroupCreated Message. If the limit for active Discount Groups has been reached, a MaxDiscountGroupsReached error is returned. Parameters:
ParameterTypeRequiredDefaultDescription
expandstring[]NoRelated resources to expand inline
descriptionobjectNoThe description value
isActivebooleanNoIs Active
keystringYesThe key value
nameobjectNoThe name value
sortOrderstringYesSort Order

commercetools_discounts_create_product_discounts

POST /product-discounts Parameters:
ParameterTypeRequiredDefaultDescription
expandstring[]NoRelated resources to expand inline
descriptionobjectNoThe description value
isActivebooleanYesIs Active
keystringNoThe key value
nameobjectYesThe name value
predicatestringYesThe predicate value
sortOrderstringYesSort Order
validFromstringNoValid From
validUntilstringNoValid Until
valueobjectYesThe value value

commercetools_discounts_create_product_discounts_matching

This endpoint can be used to simulate which Product Discounts would be applied if a specified Product Variant had a specified Price. Given Product and Product Variant IDs and a Price, this endpoint will return the ProductDiscount that would have been applied to that Price. If a Product Discount could not be found that could be applied to the Price of a Product Variant, a NoMatchingProductDiscountFound error is returned. Parameters:
ParameterTypeRequiredDefaultDescription
priceobjectYesThe price value
productIdstringYesProduct Id
stagedbooleanYesThe staged value
variantIdintegerYesVariant Id

commercetools_discounts_create_standalone_prices

Creating a Standalone Price produces the StandalonePriceCreated Message. - If the Standalone Price has the same price scope as an existing Standalone Price, a DuplicateStandalonePriceScope error is returned. - If the Standalone Price has overlapping validity periods within the same price scope, a OverlappingStandalonePriceValidity error is returned. A Price without validity period does not conflict with a Price defined for a time period. - If a modification is already in progress for the exact combination of SKU and price scope fields, an ExactLockConflict or ValidityLockConflict error is returned. Parameters:
ParameterTypeRequiredDefaultDescription
expandstring[]NoRelated resources to expand inline
activebooleanNoThe active value
channelobjectNoThe channel value
countrystringNoThe country value
customobjectNoThe custom value
customerGroupobjectNoCustomer Group
discountedobjectNoThe discounted value
keystringNoThe key value
recurrencePolicyobjectNoRecurrence Policy
skustringYesThe sku value
stagedobjectNoThe staged value
tiersobject[]NoThe tiers value
validFromstringNoValid From
validUntilstringNoValid Until
valueobjectYesThe value value

commercetools_discounts_delete_cart_discounts_by_id

Deleting a Cart Discount produces the CartDiscountDeleted Message. Parameters:
ParameterTypeRequiredDefaultDescription
IDstringYesThe id value
versionintegerYesThe version value
expandstring[]NoRelated resources to expand inline

commercetools_discounts_delete_cart_discounts_by_key

Deleting a Cart Discount produces the CartDiscountDeleted Message. Parameters:
ParameterTypeRequiredDefaultDescription
keystringYesThe key value
versionintegerYesThe version value
expandstring[]NoRelated resources to expand inline

commercetools_discounts_delete_discount_codes_by_id

Deleting a Discount Code produces the DiscountCodeDeleted Message. Deprecated OAuth 2.0 Scope: manage_orders:{projectKey} Parameters:
ParameterTypeRequiredDefaultDescription
IDstringYesThe id value
dataErasurebooleanNoData Erasure
versionintegerYesThe version value
expandstring[]NoRelated resources to expand inline

commercetools_discounts_delete_discount_codes_by_key

Deleting a Discount Code produces the DiscountCodeDeleted Message. Deprecated OAuth 2.0 Scope: manage_orders:{projectKey} Parameters:
ParameterTypeRequiredDefaultDescription
keystringYesThe key value
dataErasurebooleanNoData Erasure
versionintegerYesThe version value
expandstring[]NoRelated resources to expand inline

commercetools_discounts_delete_discount_groups_by_id

Deletes a DiscountGroup in the Project. This request generates the DiscountGroupDeleted Message. If the DiscountGroup is referenced by a CartDiscount, a ReferenceExists error is returned. Parameters:
ParameterTypeRequiredDefaultDescription
IDstringYesThe id value
versionintegerYesThe version value
expandstring[]NoRelated resources to expand inline

commercetools_discounts_delete_discount_groups_by_key

Deletes a DiscountGroup in the Project. This request generates the DiscountGroupDeleted Message. If the DiscountGroup is referenced by a CartDiscount, a ReferenceExists error is returned. Parameters:
ParameterTypeRequiredDefaultDescription
keystringYesThe key value
versionintegerYesThe version value
expandstring[]NoRelated resources to expand inline

commercetools_discounts_delete_product_discounts_by_id

DELETE /product-discounts/{ID} Parameters:
ParameterTypeRequiredDefaultDescription
IDstringYesThe id value
versionintegerYesThe version value
expandstring[]NoRelated resources to expand inline

commercetools_discounts_delete_product_discounts_by_key

DELETE /product-discounts/key={key} Parameters:
ParameterTypeRequiredDefaultDescription
keystringYesThe key value
versionintegerYesThe version value
expandstring[]NoRelated resources to expand inline

commercetools_discounts_delete_standalone_prices_by_id

Produces the StandalonePriceDeleted Message. Parameters:
ParameterTypeRequiredDefaultDescription
IDstringYesThe id value
versionintegerYesThe version value
expandstring[]NoRelated resources to expand inline

commercetools_discounts_delete_standalone_prices_by_key

Produces the StandalonePriceDeleted Message. Parameters:
ParameterTypeRequiredDefaultDescription
keystringYesThe key value
versionintegerYesThe version value
expandstring[]NoRelated resources to expand inline

commercetools_discounts_get_cart_discounts_by_id

GET /cart-discounts/{ID} Parameters:
ParameterTypeRequiredDefaultDescription
IDstringYesThe id value
expandstring[]NoRelated resources to expand inline

commercetools_discounts_get_cart_discounts_by_key

GET /cart-discounts/key={key} Parameters:
ParameterTypeRequiredDefaultDescription
keystringYesThe key value
expandstring[]NoRelated resources to expand inline

commercetools_discounts_get_discount_codes_by_id

Deprecated OAuth 2.0 Scope: view_orders:{projectKey} Parameters:
ParameterTypeRequiredDefaultDescription
IDstringYesThe id value
expandstring[]NoRelated resources to expand inline

commercetools_discounts_get_discount_codes_by_key

Deprecated OAuth 2.0 Scope: view_orders:{projectKey} Parameters:
ParameterTypeRequiredDefaultDescription
keystringYesThe key value
expandstring[]NoRelated resources to expand inline

commercetools_discounts_get_discount_groups_by_id

Retrieves a DiscountGroup with the provided id. Parameters:
ParameterTypeRequiredDefaultDescription
IDstringYesThe id value
expandstring[]NoRelated resources to expand inline

commercetools_discounts_get_discount_groups_by_key

Retrieves a DiscountGroup with the provided key. Parameters:
ParameterTypeRequiredDefaultDescription
keystringYesThe key value
expandstring[]NoRelated resources to expand inline

commercetools_discounts_get_product_discounts_by_id

GET /product-discounts/{ID} Parameters:
ParameterTypeRequiredDefaultDescription
IDstringYesThe id value
expandstring[]NoRelated resources to expand inline

commercetools_discounts_get_product_discounts_by_key

GET /product-discounts/key={key} Parameters:
ParameterTypeRequiredDefaultDescription
keystringYesThe key value
expandstring[]NoRelated resources to expand inline

commercetools_discounts_get_standalone_prices_by_id

GET /standalone-prices/{ID} Parameters:
ParameterTypeRequiredDefaultDescription
IDstringYesThe id value
expandstring[]NoRelated resources to expand inline

commercetools_discounts_get_standalone_prices_by_key

GET /standalone-prices/key={key} Parameters:
ParameterTypeRequiredDefaultDescription
keystringYesThe key value
expandstring[]NoRelated resources to expand inline

commercetools_discounts_list_cart_discounts

GET /cart-discounts Parameters:
ParameterTypeRequiredDefaultDescription
expandstring[]NoRelated resources to expand inline
sortstring[]NoSort order for results
limitintegerNoMaximum number of results to return
offsetintegerNoThe offset value
withTotalbooleanNoWith Total
wherestring[]NoThe where value

commercetools_discounts_list_discount_codes

Deprecated OAuth 2.0 Scope: view_orders:{projectKey} Parameters:
ParameterTypeRequiredDefaultDescription
expandstring[]NoRelated resources to expand inline
sortstring[]NoSort order for results
limitintegerNoMaximum number of results to return
offsetintegerNoThe offset value
withTotalbooleanNoWith Total
wherestring[]NoThe where value

commercetools_discounts_list_discount_groups

Retrieves all DiscountGroups in the Project. Parameters:
ParameterTypeRequiredDefaultDescription
expandstring[]NoRelated resources to expand inline
sortstring[]NoSort order for results
limitintegerNoMaximum number of results to return
offsetintegerNoThe offset value
withTotalbooleanNoWith Total
wherestring[]NoThe where value

commercetools_discounts_list_product_discounts

GET /product-discounts Parameters:
ParameterTypeRequiredDefaultDescription
expandstring[]NoRelated resources to expand inline
sortstring[]NoSort order for results
limitintegerNoMaximum number of results to return
offsetintegerNoThe offset value
withTotalbooleanNoWith Total
wherestring[]NoThe where value

commercetools_discounts_list_standalone_prices

GET /standalone-prices Parameters:
ParameterTypeRequiredDefaultDescription
expandstring[]NoRelated resources to expand inline
sortstring[]NoSort order for results
limitintegerNoMaximum number of results to return
offsetintegerNoThe offset value
withTotalbooleanNoWith Total
wherestring[]NoThe where value

commercetools_discounts_update_cart_discounts_by_id

POST /cart-discounts/{ID} Parameters:
ParameterTypeRequiredDefaultDescription
IDstringYesThe id value
expandstring[]NoRelated resources to expand inline
actionsobject[]YesThe actions value
versionintegerYesThe version value

commercetools_discounts_update_cart_discounts_by_key

POST /cart-discounts/key={key} Parameters:
ParameterTypeRequiredDefaultDescription
keystringYesThe key value
expandstring[]NoRelated resources to expand inline
actionsobject[]YesThe actions value
versionintegerYesThe version value

commercetools_discounts_update_discount_codes_by_id

Deprecated OAuth 2.0 Scope: manage_orders:{projectKey} Parameters:
ParameterTypeRequiredDefaultDescription
IDstringYesThe id value
expandstring[]NoRelated resources to expand inline
actionsobject[]YesThe actions value
versionintegerYesThe version value

commercetools_discounts_update_discount_codes_by_key

Deprecated OAuth 2.0 Scope: manage_orders:{projectKey} Parameters:
ParameterTypeRequiredDefaultDescription
keystringYesThe key value
expandstring[]NoRelated resources to expand inline
actionsobject[]YesThe actions value
versionintegerYesThe version value

commercetools_discounts_update_discount_groups_by_id

Updates a DiscountGroup in the Project using one or more update actions. Parameters:
ParameterTypeRequiredDefaultDescription
IDstringYesThe id value
expandstring[]NoRelated resources to expand inline
actionsobject[]YesThe actions value
versionintegerYesThe version value

commercetools_discounts_update_discount_groups_by_key

Updates a DiscountGroup in the Project using one or more update actions. Parameters:
ParameterTypeRequiredDefaultDescription
keystringYesThe key value
expandstring[]NoRelated resources to expand inline
actionsobject[]YesThe actions value
versionintegerYesThe version value

commercetools_discounts_update_product_discounts_by_id

POST /product-discounts/{ID} Parameters:
ParameterTypeRequiredDefaultDescription
IDstringYesThe id value
expandstring[]NoRelated resources to expand inline
actionsobject[]YesThe actions value
versionintegerYesThe version value

commercetools_discounts_update_product_discounts_by_key

POST /product-discounts/key={key} Parameters:
ParameterTypeRequiredDefaultDescription
keystringYesThe key value
expandstring[]NoRelated resources to expand inline
actionsobject[]YesThe actions value
versionintegerYesThe version value

commercetools_discounts_update_standalone_prices_by_id

If a modification is already in progress for the exact combination of SKU and price scope fields, an ExactLockConflict or ValidityLockConflict error is returned. Parameters:
ParameterTypeRequiredDefaultDescription
IDstringYesThe id value
expandstring[]NoRelated resources to expand inline
actionsobject[]YesThe actions value
versionintegerYesThe version value

commercetools_discounts_update_standalone_prices_by_key

If a modification is already in progress for the exact combination of SKU and price scope fields, an ExactLockConflict or ValidityLockConflict error is returned. Parameters:
ParameterTypeRequiredDefaultDescription
keystringYesThe key value
expandstring[]NoRelated resources to expand inline
actionsobject[]YesThe actions value
versionintegerYesThe version value