Skip to main content
POST
/
projects
/
{projectId}
/
rules
Create a new rule
curl --request POST \
  --url https://api.engagefabric.com/projects/{projectId}/rules \
  --header 'Content-Type: application/json' \
  --data '
{
  "name": "<string>",
  "conditions": {},
  "actions": [
    "<string>"
  ],
  "description": "<string>",
  "priority": 100,
  "status": "DRAFT",
  "isActive": true,
  "metadata": {}
}
'

Path Parameters

projectId
string
required

Body

application/json
name
string
required

Rule name

Maximum string length: 255
conditions
object
required

Conditions tree (JSON)

actions
string[]
required

Actions list (JSON array)

description
string

Rule description

priority
number
default:100

Priority (lower = higher priority)

status
enum<string>

Rule status

Available options:
DRAFT,
TESTING,
PUBLISHED,
ARCHIVED
isActive
boolean
default:true

Whether the rule is active

metadata
object

Additional metadata

Response

Rule created successfully