Skip to content

Private Network

All operations require authentication.

5 operationsv2/publicCloud/project
Agent setup

List networksProduction

GET
/v2/publicCloud/project/{projectId}/network

Returns the networks of the project. Filter by region with the region query parameter.

Path parameters

projectId
required
string

Project ID

Query parameters

region
string

Optional region filter

Headers

X-Pagination-Cursor
string

Pagination cursor

X-Pagination-Size
integer

Pagination size

Response

200Network[]successful operation
checksum
read-only
string

Computed hash representing the current target specification value

createdAt
read-only
stringdate-time

Creation date of the network

currentState
read-only
NetworkCurrentState

Current state of the network

currentTasks
read-only
CurrentTask[]

Ongoing asynchronous tasks related to the network

id
read-only
stringuuid

Unique identifier of the network

resourceStatus
read-only
ResourceStatusEnum

Network readiness in the system

ValuesCREATINGCREATION_PLANNEDDELETINGERROROUT_OF_SYNCREADYSUSPENDEDUNKNOWNUPDATING
targetSpec
read-only
NetworkTargetSpec

Last target specification of the network

updatedAt
read-only
stringdate-time

Last update date of the network

Example uses projectId = string

$ curl https://api.eu.ovhcloud.com/v2/publicCloud/project/{projectId}/network \
  -H "authorization: Bearer $OVH_TOKEN"
ResponseExample
[ { "checksum": "string", "createdAt": "2024-01-01T12:00:00Z", "currentState": { "description": "string", "location": { "availabilityZone": "string", "region": "string" }, "name": "string", "vlanId": 0 }, "currentTasks": [ { "errors": [ { "message": "string" } ], "id": "00000000-0000-0000-0000-000000000000", "link": "string", "status": "ERROR", "type": "string" } ], "id": "00000000-0000-0000-0000-000000000000", "resourceStatus": "CREATING", "targetSpec": { "description": "string", "location": { "availabilityZone": "string", "region": "string" }, "name": "string", "vlanId": 0 }, "updatedAt": "2024-01-01T12:00:00Z" }]

Get a networkProduction

GET
/v2/publicCloud/project/{projectId}/network/{networkId}

Returns the network, including its VLAN segmentation ID.

Path parameters

networkId
required
stringuuid

Network ID

projectId
required
string

Project ID

Response

200Networksuccessful operation
checksum
read-only
string

Computed hash representing the current target specification value

createdAt
read-only
stringdate-time

Creation date of the network

currentState
read-only
NetworkCurrentState

Current state of the network

currentTasks
read-only
CurrentTask[]

Ongoing asynchronous tasks related to the network

id
read-only
stringuuid

Unique identifier of the network

resourceStatus
read-only
ResourceStatusEnum

Network readiness in the system

ValuesCREATINGCREATION_PLANNEDDELETINGERROROUT_OF_SYNCREADYSUSPENDEDUNKNOWNUPDATING
targetSpec
read-only
NetworkTargetSpec

Last target specification of the network

updatedAt
read-only
stringdate-time

Last update date of the network

404objectError 404 response

Example uses networkId = 00000000-0000-0000-0000-000000000000, projectId = string

$ curl https://api.eu.ovhcloud.com/v2/publicCloud/project/{projectId}/network/{networkId} \
  -H "authorization: Bearer $OVH_TOKEN"
ResponseExample
{ "checksum": "string", "createdAt": "2024-01-01T12:00:00Z", "currentState": { "description": "string", "location": { "availabilityZone": "string", "region": "string" }, "name": "string", "vlanId": 0 }, "currentTasks": [ { "errors": [ { "message": "string" } ], "id": "00000000-0000-0000-0000-000000000000", "link": "string", "status": "ERROR", "type": "string" } ], "id": "00000000-0000-0000-0000-000000000000", "resourceStatus": "CREATING", "targetSpec": { "description": "string", "location": { "availabilityZone": "string", "region": "string" }, "name": "string", "vlanId": 0 }, "updatedAt": "2024-01-01T12:00:00Z"}

Create a networkProduction

POST
/v2/publicCloud/project/{projectId}/network

Creates a private network, optionally on a VLAN. VLAN segmentation is not supported on localzone regions.

Path parameters

projectId
required
string

Project ID

Request body (required)

targetSpec
required
NetworkTargetSpec

Desired target specification for the network to create

Response

200Networksuccessful operation
checksum
read-only
string

Computed hash representing the current target specification value

createdAt
read-only
stringdate-time

Creation date of the network

currentState
read-only
NetworkCurrentState

Current state of the network

currentTasks
read-only
CurrentTask[]

Ongoing asynchronous tasks related to the network

id
read-only
stringuuid

Unique identifier of the network

resourceStatus
read-only
ResourceStatusEnum

Network readiness in the system

ValuesCREATINGCREATION_PLANNEDDELETINGERROROUT_OF_SYNCREADYSUSPENDEDUNKNOWNUPDATING
targetSpec
read-only
NetworkTargetSpec

Last target specification of the network

updatedAt
read-only
stringdate-time

Last update date of the network

409objectError 409 response

Example uses projectId = string

$ curl https://api.eu.ovhcloud.com/v2/publicCloud/project/{projectId}/network \
  -H "authorization: Bearer $OVH_TOKEN"
ResponseExample
{ "checksum": "string", "createdAt": "2024-01-01T12:00:00Z", "currentState": { "description": "string", "location": { "availabilityZone": "string", "region": "string" }, "name": "string", "vlanId": 0 }, "currentTasks": [ { "errors": [ { "message": "string" } ], "id": "00000000-0000-0000-0000-000000000000", "link": "string", "status": "ERROR", "type": "string" } ], "id": "00000000-0000-0000-0000-000000000000", "resourceStatus": "CREATING", "targetSpec": { "description": "string", "location": { "availabilityZone": "string", "region": "string" }, "name": "string", "vlanId": 0 }, "updatedAt": "2024-01-01T12:00:00Z"}

Delete a networkProduction

DELETE
/v2/publicCloud/project/{projectId}/network/{networkId}

Deletes the network.

Path parameters

networkId
required
stringuuid

Network ID

projectId
required
string

Project ID

Response

200Networksuccessful operation
checksum
read-only
string

Computed hash representing the current target specification value

createdAt
read-only
stringdate-time

Creation date of the network

currentState
read-only
NetworkCurrentState

Current state of the network

currentTasks
read-only
CurrentTask[]

Ongoing asynchronous tasks related to the network

id
read-only
stringuuid

Unique identifier of the network

resourceStatus
read-only
ResourceStatusEnum

Network readiness in the system

ValuesCREATINGCREATION_PLANNEDDELETINGERROROUT_OF_SYNCREADYSUSPENDEDUNKNOWNUPDATING
targetSpec
read-only
NetworkTargetSpec

Last target specification of the network

updatedAt
read-only
stringdate-time

Last update date of the network

404objectError 404 response
409objectError 409 response

Example uses networkId = 00000000-0000-0000-0000-000000000000, projectId = string

$ curl https://api.eu.ovhcloud.com/v2/publicCloud/project/{projectId}/network/{networkId} \
  -H "authorization: Bearer $OVH_TOKEN"
ResponseExample
{ "checksum": "string", "createdAt": "2024-01-01T12:00:00Z", "currentState": { "description": "string", "location": { "availabilityZone": "string", "region": "string" }, "name": "string", "vlanId": 0 }, "currentTasks": [ { "errors": [ { "message": "string" } ], "id": "00000000-0000-0000-0000-000000000000", "link": "string", "status": "ERROR", "type": "string" } ], "id": "00000000-0000-0000-0000-000000000000", "resourceStatus": "CREATING", "targetSpec": { "description": "string", "location": { "availabilityZone": "string", "region": "string" }, "name": "string", "vlanId": 0 }, "updatedAt": "2024-01-01T12:00:00Z"}

Update a networkProduction

PUT
/v2/publicCloud/project/{projectId}/network/{networkId}

Updates the network's name. Description, location and VLAN ID are immutable after creation.

Path parameters

networkId
required
stringuuid

Network ID

projectId
required
string

Project ID

Request body (required)

checksum
string

Optional concurrency-control checksum. When supplied, it must match the resource's current checksum or the request is rejected with a 409 checksum-mismatch conflict. When omitted or empty, the concurrency check is skipped and the write is forced (last-write-wins).

targetSpec
required
NetworkPutTargetSpec

Desired target specification for the network

Response

200Networksuccessful operation
checksum
read-only
string

Computed hash representing the current target specification value

createdAt
read-only
stringdate-time

Creation date of the network

currentState
read-only
NetworkCurrentState

Current state of the network

currentTasks
read-only
CurrentTask[]

Ongoing asynchronous tasks related to the network

id
read-only
stringuuid

Unique identifier of the network

resourceStatus
read-only
ResourceStatusEnum

Network readiness in the system

ValuesCREATINGCREATION_PLANNEDDELETINGERROROUT_OF_SYNCREADYSUSPENDEDUNKNOWNUPDATING
targetSpec
read-only
NetworkTargetSpec

Last target specification of the network

updatedAt
read-only
stringdate-time

Last update date of the network

404objectError 404 response
409objectError 409 response

Example uses networkId = 00000000-0000-0000-0000-000000000000, projectId = string

$ curl https://api.eu.ovhcloud.com/v2/publicCloud/project/{projectId}/network/{networkId} \
  -H "authorization: Bearer $OVH_TOKEN"
ResponseExample
{ "checksum": "string", "createdAt": "2024-01-01T12:00:00Z", "currentState": { "description": "string", "location": { "availabilityZone": "string", "region": "string" }, "name": "string", "vlanId": 0 }, "currentTasks": [ { "errors": [ { "message": "string" } ], "id": "00000000-0000-0000-0000-000000000000", "link": "string", "status": "ERROR", "type": "string" } ], "id": "00000000-0000-0000-0000-000000000000", "resourceStatus": "CREATING", "targetSpec": { "description": "string", "location": { "availabilityZone": "string", "region": "string" }, "name": "string", "vlanId": 0 }, "updatedAt": "2024-01-01T12:00:00Z"}