Edit route
PUT /v1/routes/:routeID
Token scope required: routes:update
Any properties not provided in the request will be reset to their default values. If only changing one firewall rule, be sure to include the others as well, otherwise they will be removed.
Request
Path Parameters
- routeID string requiredExample: route-X47KHSCOSQJP5IOKNNKRRGHVAI
- application/json
Request Body required
- name string required
Possible values:
<= 50 characters
- description string
Possible values:
<= 255 characters
- routerHostID string
routableCIDRs object
Keys of object should be IPv4 CIDR ranges, values are an object with an 'install' boolean.
property name* object
install booleanfirewallRules object[]
Incoming firewall rules. Will replace existing list of rules.
Array [localCIDR ipv4/cidrCIDR range within the routableCIDRs this rule will apply to. Use "0.0.0.0/0" for all IP addresses.
protocol string requiredPossible values: [
ANY
,TCP
,UDP
,ICMP
]description stringPossible values:
<= 255 characters
allowedRoleID string nullableRole ID to allow with this firewall rule. If not specified, all roles are included.
allowedTags key:value[]Tags to allow with this firewall rule. An empty list allows all tags. key is max 20 characters, value is max 50 characters, no whitespace around either allowed
portRange object nullable
Range of ports for this firewall rule. If not provided or set to null, all ports are allowed.
from integer requiredPossible values:
>= 1
and<= 65535
First port number included in range.
to integer requiredPossible values:
>= 1
and<= 65535
Last port number included in range. Must be greater than
from
port.]
- 200
Successful operation
- application/json
- Schema
- Example (from schema)
Schema
data object
id stringname stringdescription stringcreatedAt date-timemodifiedAt date-timerouterHostID stringroutableCIDRs object
Keys of object should be IPv4 CIDR ranges, values are an object with an 'install' boolean.
property name* object
install booleanfirewallRules object[]
Array [localCIDR ipv4/cidrCIDR range within the routableCIDRs this rule will apply to. Use "0.0.0.0/0" for all IP addresses.
protocol string requiredPossible values: [
ANY
,TCP
,UDP
,ICMP
]description stringPossible values:
<= 255 characters
allowedRoleID string nullableRole ID to allow with this firewall rule. If not specified, all roles are included.
allowedTags key:value[]Tags to allow with this firewall rule. An empty list allows all tags. key is max 20 characters, value is max 50 characters, no whitespace around either allowed
portRange object nullable
Range of ports for this firewall rule. If not provided or set to null, all ports are allowed.
from integer requiredPossible values:
>= 1
and<= 65535
First port number included in range.
to integer requiredPossible values:
>= 1
and<= 65535
Last port number included in range. Must be greater than
from
port.]- metadata object
{
"data": {
"id": "route-X47KHSCOSQJP5IOKNNKRRGHVAI",
"name": "My edited route",
"description": "",
"routerHostID": "host-24NVITKMNU3CYCEDNFWKAOBX7I",
"routableCIDRs": {
"192.168.14.0/26": {
"install": true
}
},
"createdAt": "2024-03-10T13:59:09Z",
"modifiedAt": "2024-03-15T13:59:09Z",
"firewallRules": [
{
"protocol": "TCP",
"localCIDR": "192.168.14.56/32",
"description": "allow SSH access",
"allowedRoleID": "role-G3TWUQ4FASQEF44MGMTSRBTYKM",
"portRange": {
"from": 22,
"to": 22
}
}
]
},
"metadata": {}
}