Querying the Protection Status of a North-south Firewall
Function
This API is used to query the protection status of a north-south firewall.
URI
GET /v1/{project_id}/eip/protection-status/{fw_instance_id}
| Parameter | Mandatory | Type | Description |
|---|---|---|---|
| project_id | Yes | String | Definition Project ID, which is used to specify the project that an asset belongs to. You can query the assets of a project by project ID. You can obtain the project ID from the API or console. For details, see Obtaining a Project ID. Constraints N/A Range 32-bit UUID. Default Value N/A |
| fw_instance_id | Yes | String | Definition Firewall ID. It is a unique ID generated after a firewall instance is created. You can obtain the firewall ID by referring to Obtaining a Firewall ID. Constraints N/A Range 32-bit UUID. Default Value N/A |
Request Parameters
None
Response Parameters
Status code: 200
| Parameter | Type | Description |
|---|---|---|
| data | FirewallProtectionStatusVO object | Definition Data in the response to the query of the protection status of a north-south firewall. Constraints N/A Range N/A Default Value N/A |
| Parameter | Type | Description |
|---|---|---|
| protection_status | Integer | Definition Firewall protection status. 0: normal; 1: bypassing; 2: bypassing succeeded; 3: bypassing failed; 4: restoring; 5: restoration failed. Range N/A |
| id | String | Definition Firewall ID. It is a unique ID generated after a firewall instance is created. You can obtain the firewall ID by referring to Obtaining a Firewall ID. Constraints N/A Range 32-bit UUID. Default Value N/A |
| object_id | String | Definition Protected object ID, which is used to distinguish between Internet border protection and VPC border protection after a cloud firewall is created. You can obtain the ID by calling the API for querying firewall instances. In the return value, find the ID in data.records.protect_objects.object_id (The period [.] is used to separate different levels of objects). If the value of type is 0, the protected object ID belongs to the Internet border. If the value of type is 1, the protected object ID belongs to the VPC border. Constraints N/A Range 32-bit UUID. Default Value N/A |
| failed_eip_list | Array of strings | Definition List of EIPs that failed to be bypassed. Constraints N/A Range N/A Default Value N/A |
| failed_eip_id_list | Array of strings | Definition ID list of EIPs that failed to be bypassed. Constraints N/A Range N/A Default Value N/A |
Status code: 400
| Parameter | Type | Description |
|---|---|---|
| error_code | String | Definition Error code. Range N/A |
| error_msg | String | Definition Error message. Range N/A |
Example Requests
Query the protection status of the firewall whose project ID is eefb11b22d5944f2aa067954516df1cf and firewall instance ID is 175572ed-67e8-4837-9776-e2e07080ea45.
https://{Endpoint}/v1/eefb11b22d5944f2aa067954516df1cf/eip/protection-status/175572ed-67e8-4837-9776-e2e07080ea45 Example Responses
Status code: 200
OK
{
"data" : {
"protection_status" : 0,
"id" : "175572ed-67e8-4837-9776-e2e07080ea45",
"object_id" : "af30c598-b185-4b3e-9271-3d1393acd43e"
}
} Status Codes
| Status Code | Description |
|---|---|
| 200 | OK |
| 400 | Bad Request |
Error Codes
See Error Codes.
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot