InsertInterveneRule

Updated at:

Insert an intervention rule.

Debug

You can run this API directly in OpenAPI Explorer, saving you the trouble of calculating signatures. After a successful run, OpenAPI Explorer can automatically generate SDK code examples.

Debug

Authorization information

The following table describes the authorization information for this API. You can use it in the Action element of RAM permission policy statements to grant RAM users or RAM roles the permission to call this API. Details are as follows:

  • Action: the specific permission point.

  • Access level: the access level of each operation. Valid values: Write, Read, or List.

  • Resource type: the resource types that support authorization in the operation. Details are as follows:

    • Required resource types are marked with a preceding asterisk (*).
    • For operations that do not support resource-level authorization, All resources is used.
  • Condition key: the condition keys defined by the cloud service itself.

  • Dependent action: the other permissions required to successfully perform the operation. The caller must have the permissions of the dependent actions for the operation to succeed.

ActionAccess levelResource typeCondition keyDependent action
aimiaobi:InsertInterveneRulecreate
*All resources
*
    None
None

Request parameters

NameTypeRequiredDescriptionExample value
AgentKeystringYes

Unique identifier of the workspace: AgentKey

xxxxx_p_efm
InterveneRuleConfigobjectNo

Intervention rule configuration

AnswerConfigarray<object>No

Answer configuration

AnswerConfigobjectNo

Answer configuration item

AnswerTypeintegerNo

Answer type

Valid values:
  • 1-Targeted reply: 1-Targeted reply.
  • 0-Unified response: 0-Unified response.
0
MessagestringNo

Answer content

Sorry, I cannot answer
NamespacestringNo

Namespace

Valid values:
  • namespace_writing_query (writing input intervention): namespace_writing_query (writing input intervention).
  • namespace_qa_result (Q&A result intervention): namespace_qa_result (Q&A result intervention).
  • namespace_qa_query (Q&A input intervention): namespace_qa_query (Q&A input intervention).
  • namespace_writing_result (writing result intervention): namespace_writing_result (writing result intervention).
namespace_qa_query
EffectConfigobjectNo

Activation configuration

EffectTypeintegerNo

Activation type

Valid values:
  • 0-Permanently effective: 0-Permanently effective.
  • 1-Effective on schedule: 1-Effective on schedule.
0
EndTimestringNo

End time

2023-03-28 06:04:29
StartTimestringNo

Start time

2023-03-28 06:04:29
InterveneConfigListarray<object>No

Intervention configuration list

InterveneConfigListobjectNo
IdstringNo

id

37249
OperationTypeintegerNo

Operation type

Valid values:
  • 0-Create: 0-Create.
  • 1-Update: 1-Update.
  • 2-Delete: 2-Delete.
0
QuerystringNo

Intervention query configuration

Good morning
InterveneTypeintegerNo

Intervention type

Valid values:
  • 0-Similar question intervention item: 0-Similar question intervention item.
  • 2-Regular expression intervention item: 2-Regular expression intervention item.
  • 3-Keyword library intervention item: 3-Keyword library intervention item.
  • 4-URL intervention: 4-URL intervention.
  • 1-Keyword expression intervention item: 1-Keyword expression intervention item.
0
NamespaceListarrayNo

Namespace list

NamespaceListstringNo

Intervention dimension

Valid values:
  • namespace_writing_image (Smart Image Matching): namespace_writing_image (Smart Image Matching).
  • namespace_qa_query (Q&A input intervention): namespace_qa_query (Q&A input intervention).
  • namespace_qa_article (Q&A reference): namespace_qa_article (Q&A reference).
  • namespace_writing_article (writing reference): namespace_writing_article (writing reference).
  • namespace_qa_result (Q&A result intervention): namespace_qa_result (Q&A result intervention).
  • namespace_writing_result (writing result intervention): namespace_writing_result (writing result intervention).
  • namespace_writing_query (writing input intervention): namespace_writing_query (writing input intervention).
namespace_qa_query (Q&A input intervention)
RuleIdlongNo

Rule ID

2
RuleNamestringNo

Rule name

tf-test-rule

Response parameters

NameTypeDescriptionExample value
object

PlainResult

Codestring

Status code

success
Dataobject

Business data

RuleIdlong

Rule ID

12345
Codeinteger

Status code returned by the intervention service

200
HttpStatusCodeinteger

HTTP status code

200
Messagestring

Error message

successful
RequestIdstring

Unique request identifier

DD656AF9-0839-521A-A3D2-F320009F9C87
Successboolean

Indicates whether the request is successful: true for success, false for failure

true

Examples

Success response

JSON format

{
  "Code": "success",
  "Data": {
    "RuleId": 12345,
    "Code": 200
  },
  "HttpStatusCode": 200,
  "Message": "successful",
  "RequestId": "DD656AF9-0839-521A-A3D2-F320009F9C87",
  "Success": true
}

Error codes

Visit the Error Center to view more error codes.