Skip to main content
PUT
Save Document Validation Custom Rule

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

rule_id
string
required
tenant
string
required

The domain of the customer

Example:

"example.com"

Body

application/json
rule_id
string
required

Stable rule ID supplied by the caller.

pattern
string
required

Regular expression used to detect violations.

kind
string
default:regex
Allowed value: "regex"
display_name
string | null

Optional human-readable label for the rule.

flags
enum<string>[] | null

Optional regular expression flags.

Available options:
IGNORECASE,
MULTILINE,
DOTALL
description
string | null

Optional human-readable description of the rule.

include_violation_details
boolean
default:true

Whether the response should include matched_text and snippet for violations from this rule.

Response

Successful Response

rule_id
string
required

Stable rule ID.

kind
enum<string>
required

The executable rule kind.

Available options:
regex,
blacklist,
llm
display_name
string
required

Human-readable label for the UI.

description
string
required

Human-readable description of the rule.

requires_visual_processing
boolean
required

Whether the rule requires multimodal attachment input.

can_update
boolean
required

Whether the caller may modify the rule definition.

can_delete
boolean
required

Whether the caller may delete the rule definition.

include_violation_details
boolean
default:true

Whether violation details (matched_text, snippet) are included by default for this rule.

pattern
string | null

Regex pattern for editable custom regex rules.

flags
enum<string>[] | null

Regex flags for editable custom regex rules.

Available options:
IGNORECASE,
MULTILINE,
DOTALL
terms
string[] | null

Blacklist terms for editable custom blacklist rules.

case_sensitive
boolean | null

Blacklist case-sensitivity for editable custom blacklist rules.

rule_intent
string | null

High-level purpose of the rule, when LLM-based.

violation_definition
string | null

What counts as a violation, when LLM-based.

non_violation_definition
string | null

What should not be flagged, when LLM-based.