younifyd
Menu

Update Promotion

Update a promotion with the specified information.

PATCH/organizations/{organizationId}/promotions/{id}

Use it in a workflow

  1. Add a step and choose the Salesforce Commerce Cloud connector.
  2. Pick the Update Promotion action (under Promotions (Data API)).
  3. Fill in the fields below, then reference the result from later steps as {{updatePromotion.response.data}}.

Request

Path parameters

idstringrequired

The ID of the promotion to create.

organizationIdstringrequired

An identifier for the organization the request is being made by

Query parameters

siteIdstringrequired

The identifier of the site that a request is being made in the context of. Attributes might have site specific values, and some objects may only be assigned to specific sites.

Request body

Enter the body as JSON in the step's Body field.

archivedboolean

Determines if this promotion is archived. This attribute is allowed to be updated when using the Open Commerce API to update multiple promotions at once.

assignmentInformationany

Information about the assignments and assignment schedules of this promotion.

creationDatestring (date-time)

Returns the value of attribute 'creationDate'.

currencyCodestring

The ISO 4217 mnemonic code of the currency this promotion is restricted to. If not populated, then there is no currency restriction on the promotion.

disableGloballyExcludedboolean

Determines if this promotion ignores the global product exclusions for promotions.

enabledboolean

Determines if this promotion is enabled. This attribute is allowed to be updated when using the Open Commerce API to update multiple promotions at once.

exclusivitystring

Determines if the promotion can be combined with other promotions of the same promotion class or if it cannot be combined with any other promotions. This attribute is allowed to be updated when using the Open Commerce API to update multiple promotions at once.

One ofnoclassglobal

idstring

The ID for the promotion.

lastModifiedstring (date-time)

Returns the value of attribute 'lastModified'.

nameobject

The user supplied name of this promotion, which can be localized.

promotionClassstring

The class of the promotion. If the promotion class is modified, then the promotion rule and all of its values, such as whether or not to disable global product exclusions, are reset.

One ofproductshippingorder

tagsarray<object>

Returns the list of tags assigned to this promotion. If used to set the tags on a promotion, the promotion will only have the tags passed in the input. Any existing tags are removed.

tagIdstringrequired

The ID of the tag.

json
{
  "archived": true,
  "assignmentInformation": null,
  "creationDate": "2025-01-01T00:00:00Z",
  "currencyCode": "string",
  "disableGloballyExcluded": true,
  "enabled": true,
  "exclusivity": "no",
  "id": "string",
  "lastModified": "2025-01-01T00:00:00Z",
  "name": {},
  "promotionClass": "product",
  "tags": [
    {
      "tagId": "string"
    }
  ]
}

Response

Returns 200 with an object. Read it in later steps with {{updatePromotion.response.data.<field>}}.

archivedboolean

Determines if this promotion is archived. This attribute is allowed to be updated when using the Open Commerce API to update multiple promotions at once.

assignmentInformationany

Information about the assignments and assignment schedules of this promotion.

creationDatestring (date-time)

Returns the value of attribute 'creationDate'.

currencyCodestring

The ISO 4217 mnemonic code of the currency this promotion is restricted to. If not populated, then there is no currency restriction on the promotion.

disableGloballyExcludedboolean

Determines if this promotion ignores the global product exclusions for promotions.

enabledboolean

Determines if this promotion is enabled. This attribute is allowed to be updated when using the Open Commerce API to update multiple promotions at once.

exclusivitystring

Determines if the promotion can be combined with other promotions of the same promotion class or if it cannot be combined with any other promotions. This attribute is allowed to be updated when using the Open Commerce API to update multiple promotions at once.

One ofnoclassglobal

idstring

The ID for the promotion.

lastModifiedstring (date-time)

Returns the value of attribute 'lastModified'.

nameobject

The user supplied name of this promotion, which can be localized.

promotionClassstring

The class of the promotion. If the promotion class is modified, then the promotion rule and all of its values, such as whether or not to disable global product exclusions, are reset.

One ofproductshippingorder

tagsarray<object>

Returns the list of tags assigned to this promotion. If used to set the tags on a promotion, the promotion will only have the tags passed in the input. Any existing tags are removed.

tagIdstringrequired

The ID of the tag.

json
{
  "archived": true,
  "assignmentInformation": null,
  "creationDate": "2025-01-01T00:00:00Z",
  "currencyCode": "string",
  "disableGloballyExcluded": true,
  "enabled": true,
  "exclusivity": "no",
  "id": "string",
  "lastModified": "2025-01-01T00:00:00Z",
  "name": {},
  "promotionClass": "product",
  "tags": [
    {
      "tagId": "string"
    }
  ]
}

Need more? See the Salesforce Commerce Cloud guide for connection setup and behaviour shared by every action.