---
title: "Update sync rules"
method: PUT
path: "/sync-rules"
tags: ["Sync Rules"]
---

# Update sync rules

`PUT /sync-rules`

Replaces the company's full sync rule set. Send an empty array to disable rules, or null to opt into the inherited SaaS/ecommerce platform preset. This is not a partial update - fetch the current rules, edit them, and send the whole set back.

## Request body

- object
  - `syncRules` SyncRule[], nullable, required — Full replacement rule set. An empty array disables rules; null opts into the inherited SaaS/ecommerce platform preset.
    - `triggerEvent` string, required — Event name that triggers the rule.
    - `actions` object, required
      - `addTags` string[], required
      - `removeTags` string[], required
    - `conditions` object — Optional conditions that must all hold for the rule to apply.
      - `requiresTags` string[] — Rule only applies if the subscriber has ALL of these tags.
      - `requiresNotTags` string[] — Rule only applies if the subscriber has NONE of these tags.
      - `purchasedProduct` object — For commerce events with product context - rule only applies when a product on the event matches every specified selector (values within a selector are OR'd).
        - `tags` string[]
        - `collectionIds` string[]
        - `productTypes` string[]
        - `vendors` string[]

## Response `200`

Sync rules updated

- object
  - `success` boolean
  - `message` string
  - `syncRules` SyncRule[]
    - `triggerEvent` string, required — Event name that triggers the rule.
    - `actions` object, required
      - `addTags` string[], required
      - `removeTags` string[], required
    - `conditions` object — Optional conditions that must all hold for the rule to apply.
      - `requiresTags` string[] — Rule only applies if the subscriber has ALL of these tags.
      - `requiresNotTags` string[] — Rule only applies if the subscriber has NONE of these tags.
      - `purchasedProduct` object — For commerce events with product context - rule only applies when a product on the event matches every specified selector (values within a selector are OR'd).
        - `tags` string[]
        - `collectionIds` string[]
        - `productTypes` string[]
        - `vendors` string[]
  - `isDefault` boolean

## Other responses

- `400` — Invalid rules
- `401` — Unauthorized

---

[API](https://skmtc.net/sequenzy/apis/sequenzy-api.md) · [All operations](https://skmtc.net/sequenzy/apis/sequenzy-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/sequenzy/sequenzy-api/versions/af1cf9620482/schema)
