Domain name for API request: csip.intl.tencentcloudapi.com.
Create a DLP user rule. You can reference several system rules (SystemRuleIDList) or define a custom rule (UserRuleContent, name + regular). At least one of both is required. UserRuleInfo is a newly-added optional structured input parameter. When it is passed together with UserRuleContent, UserRuleInfo takes precedence.
A maximum of 20 requests can be initiated per second for this API.
The following request parameter list only provides API request parameters and some common parameters. For the complete common parameter list, see Common Request Parameters.
| Parameter Name | Required | Type | Description |
|---|---|---|---|
| Action | Yes | String | Common Params. The value used for this API: CreateSandboxDLPRule. |
| Version | Yes | String | Common Params. The value used for this API: 2022-11-21. |
| Region | No | String | Common Params. This parameter is not required. |
| RuleName | Yes | String | Rule name |
| Level | Yes | String | Rule level |
| RuleAction | Yes | String | Rule action |
| BelongAssetType | Yes | String | Affiliated asset type |
| EffectScope | Yes | TrafficSandboxEffectScope | Effective scope |
| Status | Yes | String | Initial status |
| SystemRuleIDList.N | No | Array of Integer | Referenced system rule ID list |
| UserRuleContent.N | No | Array of TrafficSandboxDLPRuleContentItem | User-defined rule content |
| UserRuleInfo | No | TrafficSandboxDLPUserRuleInfo | Newly-added selectable structured input parameters support 5 detection dimensions (file name/file size/file format/outbound domain name/outbound content). Each dimension is selectable and at least one must be hit. It will override when passed at the same time as UserRuleContent. |
| Parameter Name | Type | Description |
|---|---|---|
| ID | Integer | ID of the created rule |
| RequestId | String | The unique request ID, generated by the server, will be returned for every request (if the request fails to reach the server for other reasons, the request will not obtain a RequestId). RequestId is required for locating a problem. |
POST / HTTP/1.1
Host: csip.intl.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: CreateSandboxDLPRule
<Common request parameters>
{
"RuleName": "Border exit sensitive data protection",
"Level": "HIGH",
"BelongAssetType": "CONTAINER",
"UserRuleContent": [
{
"RuleName": "Identity card number",
"RuleContent": "[1-9]\\d{5}(19|20)\\d{2}(0[1-9]|1[0-2])(0[1-9]|[12]\\d|3[01])\\d{3}[0-9Xx]"
}
],
"EffectScope": {
"EffectType": "EXCLUDE"
},
"RuleAction": "BLOCK",
"Status": "ON"
}
{
"Response": {
"ID": 4001,
"RequestId": "a1b2c3d4-e5f6-7890-abcd-ef1234567890"
}
}
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call APIs.
There is no error code related to the API business logic. For other error codes, please see Common Error Codes.
Was this page helpful?
You can also Contact sales or Submit a Ticket for help.
Help us improve! Rate your documentation experience in 5 mins.
Feedback