Updated on 2024-12-05 GMT+08:00

Batch Delete Acl Rules

Function

Batch Delete Acl Rules

Calling Method

For details, see Calling APIs.

URI

DELETE /v1/{project_id}/acl-rule

Table 1 Path Parameters

Parameter

Mandatory

Type

Description

project_id

Yes

String

project ID

Table 2 Query Parameters

Parameter

Mandatory

Type

Description

enterprise_project_id

No

String

Enterprise project id, the id generated by the enterprise project after the user supports the enterprise project.

fw_instance_id

No

String

Firewall instance ID, which is automatically generated after a CFW instance is created. You can obtain the ID by calling the API used for querying a firewall instance. For details, see the API Explorer and Help Center FAQ.By default, if fw_instance_Id is not specified, information about the first firewall under the account is returned. If fw_instance_Id is specified, information about the firewall with this fw_instance_Id is returned.If object_Id is specified, information about the firewall with this object_Id is returned by default. If both fw_instance_Id and object_Id are specified, the specified object_Id must belong to the specified firewall.

Request Parameters

Table 3 Request header parameters

Parameter

Mandatory

Type

Description

X-Auth-Token

Yes

String

User token. It can be obtained by calling the IAM API used to obtain a user token. The value of X-Subject-Token in the response header is a token.

Table 4 Request body parameters

Parameter

Mandatory

Type

Description

object_id

Yes

String

Protected object ID, which is used to distinguish Internet border protection from VPC border protection after a CFW instance is created. You can obtain the ID by calling the API used for querying a firewall instance. Note that the value 0 indicates the ID of a protected object on the Internet border, and the value 1 indicates the ID of a protected object on the VPC border. For details, see the API Explorer and Help Center FAQ.

rule_ids

Yes

Array of strings

rule ids

Response Parameters

Status code: 200

Table 5 Response body parameters

Parameter

Type

Description

data

BatchDeleteAclRulesResponseData object

Batch delete acl rules response data

Table 6 BatchDeleteAclRulesResponseData

Parameter

Type

Description

responseDatas

Array of BatchDeleteRuleInfo objects

batch delete acl rules response data

Table 7 BatchDeleteRuleInfo

Parameter

Type

Description

name

String

rule name

id

String

rule id

Example Requests

Delete the rule with the object id ae42418e-f077-41a0-9d3b-5b2f5ad9102b under the project id 9d80d070b6d44942af73c9c3d38e0429, the rule id is 0475c516-0e41-4caf-990b-0c504eebd73f and 8 662868e-fe7e-4dfc-bfb1-ca4d73081ca6

https://{Endpoint}/v1/9d80d070b6d44942af73c9c3d38e0429/acl-rule

{
  "rule_ids" : [ "0475c516-0e41-4caf-990b-0c504eebd73f", "8662868e-fe7e-4dfc-bfb1-ca4d73081ca6" ],
  "object_id" : "ae42418e-f077-41a0-9d3b-5b2f5ad9102b"
}

Example Responses

Status code: 200

Batch Delete Acl Rules Response Body

{
  "data" : {
    "responseDatas" : [ {
      "name" : "test",
      "id" : "0475c516-0e41-4caf-990b-0c504eebd73f"
    }, {
      "name" : "test2",
      "id" : "8662868e-fe7e-4dfc-bfb1-ca4d73081ca6"
    } ]
  }
}

Status Codes

Status Code

Description

200

Batch Delete Acl Rules Response Body

Error Codes

See Error Codes.