create Rule
create Rule
Path Parameters
- contentGenerationId int64 required
The Content Generation id.
- application/json
Request Body required
fixes object[]
The list of fixes to apply when the rule validation fails.
Array [type ValidationTypeEnum requiredPossible values: [
FIND_AND_REPLACE
,OPEN_AI
,APPEND
]what string requiredwith string required]- level LevelEnum required
Possible values: [
RECOMMENDED
,REQUIRED
]The rule level.
- name string required
The rule name.
- type string required
The rule type, one of
field
,word
orcode
. By defaultfield
. - what_operand_lhs WhatOperandLhs required
Possible values: [
EVERYWHERE
,FIRST_SENTENCE
,LAST_SENTENCE
]The left hand side operand for what condition.
- what_operand_rhs string required
The right hand side operand for what condition.
- what_operator WhatOperator required
Possible values: [
CONTAINS
,DOESNT_CONTAIN
,ENDS_WITH
]The operator for what condition.
- when_operand_lhs string required
The left hand side operand for when condition.
- when_operand_rhs string required
The right hand side operand for when condition.
- when_operator WhenOperator required
Possible values: [
ALWAYS
,EQUALS
,NOT_EQUALS
]The operator for when condition.
- 200
- 401
- 404
Found.
- application/json
- Schema
- Example (from schema)
Schema
- content_generation_id int64 required
The parent content generation id.
- description string required
Description for the rule
fixes object[]
The list of fixes to apply when the rule validation fails.
Array [type ValidationTypeEnum requiredPossible values: [
FIND_AND_REPLACE
,OPEN_AI
,APPEND
]what string requiredwith string required]- id int64 required
- level LevelEnum required
Possible values: [
RECOMMENDED
,REQUIRED
]The rule level.
- name string required
The rule name.
- type string required
The rule type, one of
field
,word
orcode
. By defaultfield
. - what_operand_lhs WhatOperandLhs required
Possible values: [
EVERYWHERE
,FIRST_SENTENCE
,LAST_SENTENCE
]The left hand side operand for what condition.
- what_operand_rhs string required
The right hand side operand for what condition.
- what_operator WhatOperator required
Possible values: [
CONTAINS
,DOESNT_CONTAIN
,ENDS_WITH
]The operator for what condition.
- when_operand_lhs string required
The left hand side operand for when condition.
- when_operand_rhs string required
The right hand side operand for when condition.
- when_operator WhenOperator required
Possible values: [
ALWAYS
,EQUALS
,NOT_EQUALS
]The operator for when condition.
{
"content_generation_id": 0,
"description": "string",
"fixes": [
{
"type": "FIND_AND_REPLACE",
"what": "string",
"with": "string"
}
],
"id": 0,
"level": "RECOMMENDED",
"name": "string",
"type": "string",
"what_operand_lhs": "EVERYWHERE",
"what_operand_rhs": "string",
"what_operator": "CONTAINS",
"when_operand_lhs": "string",
"when_operand_rhs": "string",
"when_operator": "ALWAYS"
}
Authentication Failure
Not Found