Deactivate Cart Promotion

This API is used to deactivate an already active Cart promotion

Example request

curl --location --request POST 'https://{Host}/api_gateway/v1/promotions/`{promotionId}`/deactivate?customerId=566881933&earnId=null' \
--header 'Accept: application/json' \
--header 'Content-Type: application/json' \
--header 'accept: application/json' \
--header 'Authorization: Basic Z2VvcmdlLmJ1a2w6NNDkxOGFmNDI3MGQ3YzI4ZjU4ZjY3MmNhZjY1ZmY=' \
--header 'Cookie: _cfuvid=DWAI.W93CwD8Hhdi338lKP84bJoUrRqwVps-1761979737913-0.0.1.1-604800000' \
--data ''

Prerequisites

  • Authentication: Basic or OAuth authentication.

  • Default access group

Resource information

PaginationNo
Batch supportNo

Rate limit

  • Demo and Testing Clusters: 1,000 requests per minute per API key

  • Other Organizations: The rate limit is brand-specific.

To modify the limit, create a ticket with the Capillary Product support team.

Path parameters

FieldTypeRequiredDescription
promotionIdStringYesSpecifies the unique identifier for the promotion to be deactivated.

Query parameters

FieldTypeRequiredDescription
customerIdNumberYesSpecifies the unique identifier for the customer.

Example response

{
    "data": true,
    "errors": []
}

Response parameters

FieldTypeDescription
dataBooleanIndicates the success status of the operation. true means it was successful.
errorsArrayDefines a list of error objects. Indicates it will be empty on success.

Error codes

CodeDescription
400Invalid request. Check required parameters. Ensure all required parameters, including a valid promotionId, are provided and valid.
404Promotion not found. Use a valid and existing promotionId.
706Promotion has expired. Use a valid, non-expired promotion for the deactivation operation.
707The passed promotion type is not supported. Change the promotion type to one supported by the system.
713Earned from type cannot be changed. Do not change earnedFromType on existing earned promotions.
500Internal server error. Retry the request after a short delay, and contact support if the error persists.

Language
Credentials
Basic
base64
:
URL
Click Try It! to start a request and see the response here!