Assign security group
Instances
Assign security group
Assign the security group to the server.
To assign multiple security groups to all ports, use the NULL value for the port_id field
POST
Assign security group
Authorizations
API key for authentication. Make sure to include the word apikey, followed by a single space and then your token.
Example: apikey 1234$abcdef
Path Parameters
Project ID
Region ID
Instance ID
Body
application/json
Security group name, applies to all ports
Pattern:
^[a-zA-Z0-9][a-zA-Z 0-9._\-]{1,61}[a-zA-Z0-9._]$Example:
"some_name"
Port security groups mapping
Example:
[
{
"port_id": null,
"security_group_names": ["some_name"]
},
{
"port_id": "ee2402d0-f0cd-4503-9b75-69be1d11c5f1",
"security_group_names": ["name1", "name2"]
}
]Response
204
No Content