VPN gateways
All operations require authentication.
List VPN gatewaysAlpha
Returns the VPN gateways of the project, in every region.
Path parameters
Project ID
Headers
Pagination cursor
Pagination size
Response
Hash of the current target specification. Send it back in the update payload to detect concurrent changes.
Date and time the VPN gateway was created
Observed state of the VPN gateway. Null while the VPN gateway is being created.
Asynchronous operations ongoing on the VPN gateway
Unique identifier of the VPN gateway
Readiness of the VPN gateway: whether its observed state has converged to its target specification
CREATINGCREATION_PLANNEDDELETINGERROROUT_OF_SYNCREADYSUSPENDEDUNKNOWNUPDATINGLast target specification requested for the VPN gateway
Date and time the VPN gateway was last updated
Example uses projectId = string
$ curl https:/ / api.eu.ovhcloud.com/ v2/ publicCloud/ project/ {projectId}/ vpn/ gateway \
-H "authorization: Bearer $OVH_TOKEN"[ { "checksum": "string", "createdAt": "2024-01-01T12:00:00Z", "currentState": { "description": "string", "externalGateway": { "enabled": true }, "externalIpv4": "192.0.2.0", "externalIpv6": "192.0.2.0", "location": { "region": "string" }, "name": "string", "operatingStatus": "DISABLED", "provisioningStatus": "ACTIVE", "subnets": [ { "id": "00000000-0000-0000-0000-000000000000", "ip": "192.0.2.0", "network": { "id": "00000000-0000-0000-0000-000000000000" }, "status": "CREATING" } ] }, "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", "externalGateway": { "enabled": true }, "location": { "region": "string" }, "name": "string", "subnets": [ { "id": "00000000-0000-0000-0000-000000000000" } ] }, "updatedAt": "2024-01-01T12:00:00Z" }]
Create a VPN gatewayAlpha
Creates a VPN gateway: a router dedicated to IPsec, running on a managed instance. When targetSpec.externalGateway.enabled is true, it gets its public addresses automatically. It is plugged into the subnets of targetSpec.subnets. Creation is asynchronous: follow resourceStatus and currentTasks, then currentState.externalIpv4 and externalIpv6 for the addresses to give to the peers.
Path parameters
Project ID
Request body (required)
Desired specification of the VPN gateway to create
Response
Hash of the current target specification. Send it back in the update payload to detect concurrent changes.
Date and time the VPN gateway was created
Observed state of the VPN gateway. Null while the VPN gateway is being created.
Asynchronous operations ongoing on the VPN gateway
Unique identifier of the VPN gateway
Readiness of the VPN gateway: whether its observed state has converged to its target specification
CREATINGCREATION_PLANNEDDELETINGERROROUT_OF_SYNCREADYSUSPENDEDUNKNOWNUPDATINGLast target specification requested for the VPN gateway
Date and time the VPN gateway was last updated
Example uses projectId = string
$ curl https:/ / api.eu.ovhcloud.com/ v2/ publicCloud/ project/ {projectId}/ vpn/ gateway \
-H "authorization: Bearer $OVH_TOKEN"{ "checksum": "string", "createdAt": "2024-01-01T12:00:00Z", "currentState": { "description": "string", "externalGateway": { "enabled": true }, "externalIpv4": "192.0.2.0", "externalIpv6": "192.0.2.0", "location": { "region": "string" }, "name": "string", "operatingStatus": "DISABLED", "provisioningStatus": "ACTIVE", "subnets": [ { "id": "00000000-0000-0000-0000-000000000000", "ip": "192.0.2.0", "network": { "id": "00000000-0000-0000-0000-000000000000" }, "status": "CREATING" } ] }, "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", "externalGateway": { "enabled": true }, "location": { "region": "string" }, "name": "string", "subnets": [ { "id": "00000000-0000-0000-0000-000000000000" } ] }, "updatedAt": "2024-01-01T12:00:00Z"}
Get a VPN gatewayAlpha
Returns the VPN gateway and its observed state.
Path parameters
Gateway ID
Project ID
Response
Hash of the current target specification. Send it back in the update payload to detect concurrent changes.
Date and time the VPN gateway was created
Observed state of the VPN gateway. Null while the VPN gateway is being created.
Asynchronous operations ongoing on the VPN gateway
Unique identifier of the VPN gateway
Readiness of the VPN gateway: whether its observed state has converged to its target specification
CREATINGCREATION_PLANNEDDELETINGERROROUT_OF_SYNCREADYSUSPENDEDUNKNOWNUPDATINGLast target specification requested for the VPN gateway
Date and time the VPN gateway was last updated
Example uses gatewayId = 00000000-0000-0000-0000-000000000000, projectId = string
$ curl https:/ / api.eu.ovhcloud.com/ v2/ publicCloud/ project/ {projectId}/ vpn/ gateway/ {gatewayId} \
-H "authorization: Bearer $OVH_TOKEN"{ "checksum": "string", "createdAt": "2024-01-01T12:00:00Z", "currentState": { "description": "string", "externalGateway": { "enabled": true }, "externalIpv4": "192.0.2.0", "externalIpv6": "192.0.2.0", "location": { "region": "string" }, "name": "string", "operatingStatus": "DISABLED", "provisioningStatus": "ACTIVE", "subnets": [ { "id": "00000000-0000-0000-0000-000000000000", "ip": "192.0.2.0", "network": { "id": "00000000-0000-0000-0000-000000000000" }, "status": "CREATING" } ] }, "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", "externalGateway": { "enabled": true }, "location": { "region": "string" }, "name": "string", "subnets": [ { "id": "00000000-0000-0000-0000-000000000000" } ] }, "updatedAt": "2024-01-01T12:00:00Z"}
Update a VPN gatewayAlpha
The target specification replaces the previous one as a whole: a field left null goes back to its default. Send the checksum of the last GET to reject the update with a checksum mismatch when someone changed the resource in between. Subnets added to targetSpec.subnets are plugged and subnets removed are unplugged, which is asynchronous: follow resourceStatus and currentState.subnets. Likewise, setting targetSpec.externalGateway.enabled to true attaches the VPN gateway to the external network: follow resourceStatus. Once enabled, it cannot be disabled: create another VPN gateway instead. Refused while the VPN gateway is being created, updated or deleted: follow its resourceStatus and retry once it is READY or ERROR.
Path parameters
Gateway ID
Project ID
Request body (required)
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).
Desired specification of the VPN gateway. It replaces the previous one as a whole.
Response
Hash of the current target specification. Send it back in the update payload to detect concurrent changes.
Date and time the VPN gateway was created
Observed state of the VPN gateway. Null while the VPN gateway is being created.
Asynchronous operations ongoing on the VPN gateway
Unique identifier of the VPN gateway
Readiness of the VPN gateway: whether its observed state has converged to its target specification
CREATINGCREATION_PLANNEDDELETINGERROROUT_OF_SYNCREADYSUSPENDEDUNKNOWNUPDATINGLast target specification requested for the VPN gateway
Date and time the VPN gateway was last updated
Example uses gatewayId = 00000000-0000-0000-0000-000000000000, projectId = string
$ curl https:/ / api.eu.ovhcloud.com/ v2/ publicCloud/ project/ {projectId}/ vpn/ gateway/ {gatewayId} \
-H "authorization: Bearer $OVH_TOKEN"{ "checksum": "string", "createdAt": "2024-01-01T12:00:00Z", "currentState": { "description": "string", "externalGateway": { "enabled": true }, "externalIpv4": "192.0.2.0", "externalIpv6": "192.0.2.0", "location": { "region": "string" }, "name": "string", "operatingStatus": "DISABLED", "provisioningStatus": "ACTIVE", "subnets": [ { "id": "00000000-0000-0000-0000-000000000000", "ip": "192.0.2.0", "network": { "id": "00000000-0000-0000-0000-000000000000" }, "status": "CREATING" } ] }, "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", "externalGateway": { "enabled": true }, "location": { "region": "string" }, "name": "string", "subnets": [ { "id": "00000000-0000-0000-0000-000000000000" } ] }, "updatedAt": "2024-01-01T12:00:00Z"}
Delete a VPN gatewayAlpha
Deletes the VPN gateway, with its IPsec connections and their tunnels, and releases its public addresses. Refused while the VPN gateway is being created, updated or deleted: follow its resourceStatus and retry once it is READY or ERROR. Deletion is asynchronous: the VPN gateway stays listed with resourceStatus DELETING until it is gone.
Path parameters
Gateway ID
Project ID
Response
Hash of the current target specification. Send it back in the update payload to detect concurrent changes.
Date and time the VPN gateway was created
Observed state of the VPN gateway. Null while the VPN gateway is being created.
Asynchronous operations ongoing on the VPN gateway
Unique identifier of the VPN gateway
Readiness of the VPN gateway: whether its observed state has converged to its target specification
CREATINGCREATION_PLANNEDDELETINGERROROUT_OF_SYNCREADYSUSPENDEDUNKNOWNUPDATINGLast target specification requested for the VPN gateway
Date and time the VPN gateway was last updated
Example uses gatewayId = 00000000-0000-0000-0000-000000000000, projectId = string
$ curl https:/ / api.eu.ovhcloud.com/ v2/ publicCloud/ project/ {projectId}/ vpn/ gateway/ {gatewayId} \
-H "authorization: Bearer $OVH_TOKEN"{ "checksum": "string", "createdAt": "2024-01-01T12:00:00Z", "currentState": { "description": "string", "externalGateway": { "enabled": true }, "externalIpv4": "192.0.2.0", "externalIpv6": "192.0.2.0", "location": { "region": "string" }, "name": "string", "operatingStatus": "DISABLED", "provisioningStatus": "ACTIVE", "subnets": [ { "id": "00000000-0000-0000-0000-000000000000", "ip": "192.0.2.0", "network": { "id": "00000000-0000-0000-0000-000000000000" }, "status": "CREATING" } ] }, "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", "externalGateway": { "enabled": true }, "location": { "region": "string" }, "name": "string", "subnets": [ { "id": "00000000-0000-0000-0000-000000000000" } ] }, "updatedAt": "2024-01-01T12:00:00Z"}