Skip to main content
POST
Create port

Authorizations

Authorization
string
header
required

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
integer
required

Project ID

Example:

1

Query Parameters

dry_run
boolean
default:false

Run every check of the real request and change nothing. The response has the status code and the schema of the real call, and an empty list of tasks. With false, the default, the request does the operation.

Body

application/json
region_id
integer
required

Region ID where the port is created

Example:

1

allowed_address_pairs
AllowedAddressPairRequestSerializer · object[]

A set of zero or more allowed port address pair and/or subnet masks.

Maximum array length: 10
Example:
ip_assignments
IpAssignmentRequestSerializer · object[]

IP addresses to assign. All subnets must belong to the same network. Repeat a subnet to get several addresses from it. Omit the field to get one address from an IPv4 subnet.

Required array length: 1 - 64 elements
network_id
string<uuid4>

Network to create the port in. When omitted, it is the network of the subnets in ip_assignments, or the region's public network if ip_assignments is omitted. Every subnet in ip_assignments must belong to it.

Example:

"bc688791-f1b0-44eb-97d4-07697294b1e1"

port_security_enabled
boolean

When true, the network driver enforces port security on this port (anti-spoofing checks and security-group filtering apply). Defaults to the network's setting.

security_group_ids
string<uuid4>[]

List of security group IDs to attach to the port.

Maximum array length: 10
Example:
tags
CreateTagsSerializer · object

Key-value tags to associate with the resource. A tag is a key-value pair that can be associated with a resource, enabling efficient filtering and grouping for better organization and management. Both tag keys and values have a maximum length of 255 characters. Tag keys and values cannot contain characters from U+0080 to U+00FF. Some tags are read-only and cannot be modified by the user. Tags are also integrated with cost reports, allowing cost data to be filtered based on tag keys or values.

Example:

Response

Task IDs

tasks
string[]
required

List of task IDs representing asynchronous operations. Use these IDs to monitor operation progress:

  • GET /v1/tasks/{task_id} - Check individual task status and details Poll task status until completion (FINISHED/ERROR) before proceeding with dependent operations.
Example: