This API is used to query all firewall policies accessible to the tenant submitting the request.
GET /v2.0/fwaas/firewall_policies
Example of querying policies by page
GET https://{Endpoint}/v2.0/fwaas/firewall_policies?limit=2&marker=6b70e321-0c21-4b83-bb8a-a886d1414a5f&page_reverse=False
Table 1 describes the parameters.
Name |
Mandatory |
Type |
Description |
|---|---|---|---|
id |
No |
String |
Specifies that the firewall policy ID is used as the filtering condition. |
name |
No |
String |
Specifies that the firewall policy name is used as the filtering condition. |
description |
No |
String |
Specifies that the firewall policy description is used as the filtering condition. |
tenant_id |
No |
String |
Specifies that the project ID of the firewall policy is used as the filtering condition. |
marker |
No |
String |
Specifies a resource ID for pagination query, indicating that the query starts from the next record of the specified resource ID. This parameter can work together with the parameter limit.
|
limit |
No |
Integer |
Specifies the number of records that will be returned on each page. The value is from 0 to intmax. limit can be used together with marker. For details, see the parameter description of marker. |
None
Parameter |
Type |
Description |
|---|---|---|
firewall_policies |
Array of firewall Policy object |
Specifies the firewall policies. For details, see Table 3. |
firewall_policies_links |
Array of firewall_policies_link object |
firewall_policies_link object For details, see Table 4. The value of rel will be next and that of href will be a link only when limit is used for filtering and the number of resources exceeds the value of limit or 2000 (default value of limit). |
Attribute |
Type |
Description |
|---|---|---|
id |
String |
Specifies the UUID of the firewall policy. |
name |
String |
Specifies the name of the firewall policy. |
description |
String |
Provides supplementary information about the firewall policy. |
tenant_id |
String |
Specifies the project ID. |
firewall_rules |
Array of strings |
Specifies the rules referenced by the firewall policy. |
audited |
Boolean |
Specifies the audit flag. |
public |
Boolean |
Specifies whether the policy can be shared by different tenants. |
project_id |
String |
Specifies the project ID. |
Example request
GET https://{Endpoint}/v2.0/fwaas/firewall_policies
Example response
{
"firewall_policies": [
{
"description": "",
"firewall_rules": [
"6c6803e0-ca8c-4aa9-afb3-4f89275b6c32"
],
"tenant_id": "23c8a121505047b6869edf39f3062712",
"public": false,
"id": "6b70e321-0c21-4b83-bb8a-a886d1414a5f",
"audited": false,
"name": "fwp1",
"project_id": "23c8a121505047b6869edf39f3062712"
},
{
"description": "",
"firewall_rules": [
"6c6803e0-ca8c-4aa9-afb3-4f89275b6c32"
],
"tenant_id": "23c8a121505047b6869edf39f3062712",
"public": false,
"id": "fce92002-5a15-465d-aaca-9b44453bb738",
"audited": false,
"name": "fwp2",
"project_id": "23c8a121505047b6869edf39f3062712"
}
],
"firewall_policies_links": [
{ "rel": "previous",
"href": "https://{Endpoint}/v2.0/
fwaas/firewall_policies?marker=6b70e321-0c21-4b83-bb8a-a886d1414a5f&page_reverse=True"
}
]
}
See Status Codes.
See Error Codes.