Skip to main content

Add New Rule

POST 

/rulesets/:rulesetId/rules

Creates a new rule; available as an Add-On Module

Request

Path Parameters

    rulesetId stringrequired

    Ruleset Identifier

Query Parameters

    siteId string

    Site Identifier

Body

required

    rule

    object

    priority number

    Rule priority

    description string

    Rule description

    workflowId string

    Workflow to start on matching of conditions

    status RulesetStatus (string)

    Status of the Ruleset

    Possible values: [ACTIVE, INACTIVE]

    conditions

    object

    must

    object[]

    List of rule conditions

  • Array [

  • attribute RuleConditionAttribute (string)

    Rule condition attribute (deprecated, use Criterion)

    Possible values: [TEXT, CONTENT_TYPE, BARCODE, FIELD, ATTRIBUTE]

    criterion RuleConditionCriterion (string)

    Rule condition attribute

    Possible values: [TEXT, CONTENT_TYPE, BARCODE, FIELD, ATTRIBUTE]

    attributeKey string

    Rule attribute key (only required for ATTRIBUTE criterion)

    fieldName string

    Rule field name (only required for FIELD criterion)

    value string

    Rule condition value

    operation RuleConditionOperation (string)

    Rule condition attribute

    Possible values: [EQ, CONTAINS]

  • ]

Responses

201 CREATED

Response Headers

  • Access-Control-Allow-Origin

    string

  • Access-Control-Allow-Methods

    string

  • Access-Control-Allow-Headers

    string

Schema

    ruleId string

    Rule Identifier

Loading...