Skip to main content
PUT
/
api
/
data-platform
/
alerts
/
{id}
Update an alert configuration
curl --request PUT \
  --url https://app.solya.app/api/data-platform/alerts/{id} \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "frequency": "DAILY",
  "isActive": true,
  "name": "Low stock alert",
  "organizationId": "org-uuid-1",
  "storesIds": [
    "store-uuid-1",
    "store-uuid-2"
  ],
  "tagOperator": "AND",
  "tagRules": [
    {
      "mode": "INCLUDE",
      "tagId": "tag-uuid-low-stock"
    }
  ]
}
'
{
  "createdAt": "2026-01-10T08:00:00.000Z",
  "frequency": "DAILY",
  "id": "alert-uuid-1",
  "isActive": true,
  "name": "Low stock alert",
  "organizationId": "org-uuid-1",
  "storesIds": [
    "store-uuid-1",
    "store-uuid-2"
  ],
  "tagOperator": "AND",
  "tagRules": [
    {
      "mode": "INCLUDE",
      "tagId": "tag-uuid-low-stock"
    }
  ],
  "updatedAt": "2026-05-01T12:00:00.000Z"
}

Authorizations

Authorization
string
header
required

Static internal-ops token used by the data platform and internal cron jobs (e.g. zombie-run sweep). Validated via requireBearerToken inside the handler against a service-specific environment variable.

Path Parameters

id
string<uuid>
required

UUID of the alert to update

Pattern: ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$

Body

application/json
name
string
required

Human-readable alert name

Minimum string length: 1
organizationId
string
required

Organization ID the alert belongs to

Minimum string length: 1
tagRules
object[]
required

Tag-based conditions that determine which entities trigger this alert (at least one required)

Minimum array length: 1
brandIds
string[]

Restrict alert evaluation to these brand IDs; omit for all brands

checkLevel
enum<string>

Granularity at which the alert is evaluated (e.g. VARIANT, PRODUCT, BRAND)

Available options:
SHOP,
BRAND,
PRODUCT,
VARIANT,
INVENTORY_ITEM
collections
string[]

Restrict alert evaluation to entities in these collection IDs

description
string | null

Optional free-text description of the alert's purpose

frequency
enum<string>
default:DAILY

How often the alert is evaluated (DAILY, WEEKLY, etc.)

Available options:
IMMEDIATELY,
HOURLY,
DAILY,
WEEKLY,
MONTHLY
isActive
boolean

Whether the alert is active and will be evaluated; defaults to true

mediums
string[]

Notification channels for delivery (e.g. EMAIL, SLACK)

productIds
string[]

Restrict alert evaluation to these product IDs; omit for all products

recipientIds
string[]

User IDs that should receive alert notifications

storesIds
string[]

Restrict alert evaluation to these store IDs; omit for all stores

tagOperator
enum<string>
default:AND

How multiple tag rules are combined: AND requires all tags, OR requires any tag

Available options:
AND,
OR
taxonomies
object[]

Restrict alert evaluation to entities matching these taxonomy filters

Response

Successful response

data
object
required
success
enum<boolean>
required
Available options:
true