Help us improve your experience.

Let us know what you think.

Do you have time for a two-minute survey?

 
 

GET /system/servers/{server_id}/firewall_rules

SUMMARY Retrieves a list of access control firewall rules based on the supplied server ID.

Table 1: GET /system/servers/{server_id}/firewall_rules resource details:

GET /system/servers/{server_id}/firewall_rules resource details

MIME Type

application/json

Table 2: GET /system/servers/{server_id}/firewall_rules request parameter details:

GET /system/servers/{server_id}/firewall_rules request parameter details

Parameter Type Optionality Data Type MIME Type Description

server_id

path

Required

Number (Integer)

text/plain

Required - The ID of the server.

filter

query

Optional

String

text/plain

Optional - This parameter is used to restrict the elements in a list base on the contents of various fields.

Range

header

Optional

String

text/plain

Optional - Use this parameter to restrict the number of elements that are returned in the list to a specified range. The list is indexed starting at zero.

fields

query

Optional

String

text/plain

Optional - Use this parameter to specify which fields you would like to get back in the response. Fields that are not named are excluded. Specify subfields in brackets and multiple fields in the same object are separated by commas.

Table 3: GET /system/servers/{server_id}/firewall_rules response codes:

GET /system/servers/{server_id}/firewall_rules response codes

HTTP Response Code Unique Code Description

200

The rules records was retrieved.

404

1002

The requested server with the given server ID cannot be found.

422

1005

One or more parameters are invalid in request.

500

1020

An error occurred while trying to retrieve the requested access control firewall rules on the server with the given ID.

Response Description

A list of the rules. Each rule record contains the following fields:
  • is_any_source_ip - Boolean - Whether any source IP is accepted.
  • port_range - String - A port range in the format of start-end.
  • port_type - String - one of: ANY, SINGLE, RANGE.
  • protocol - String - one of: ANY, TCP, UDP.
  • single_port - String - A single port.
  • source_ip - String - A specific IP address.

Response Sample