VPC API Reference
Users with administrative permissions can interact with the VPC API using curl
or any other HTTP client. The API allows users to create, list, update, and delete VPCs.
- The API server is
https://api.coreweave.com
. - Replace
{API_ACCESS_TOKEN}
in the examples below with your CoreWeave API access token.
Reference table
Endpoint | Method | Description |
---|---|---|
/v1/networking/vpcs | GET | List all VPCs. |
/v1/networking/vpcs | POST | Create a VPC. |
/v1/networking/vpcs/{id} | GET | Get VPC information by ID. |
/v1/networking/vpcs/{id} | DELETE | Delete a VPC by ID. |
/v1/networking/vpcs/{id} | PATCH | Update a VPC by ID. |
VPCs
To list or create VPCs, use the /v1/networking/vpcs
endpoint. The API supports the GET
and POST
methods.
GET /v1/networking/vpcs
To list all VPCs, use the GET
method with the /v1/networking/vpcs
endpoint.
$curl -X GET https://api.coreweave.com/v1/networking/vpcs \-H "Content-Type: application/json" \-H "Authorization: Bearer {API_ACCESS_TOKEN}"
A successful response returns an array of VPC objects.
{"items": [{"id": string,"name": string,"status": integer <enum>,"zone": string,"pubImport": boolean,"hostPrefixes": [string],"vpcPrefixes": [{"name": string,"value": string,"disableExternalPropagate": boolean,"disableHostBgpPeering": boolean,"hostDhcpRoute": boolean,"public": boolean,"createdAt": string <date-time>,"updatedAt": string <date-time>,"status": integer <enum>}],"dnsServers": [string],"createdAt": string <date-time>,"updatedAt": string <date-time>}]}
POST /v1/networking/vpcs
To create a VPC, use the POST
method with the /v1/networking/vpcs
endpoint. The VPC configuration must be supplied as a JSON object in the request body.
The supported fields and their data types are as follows.
{"name": string,"zone": string,"pubImport": boolean,"hostPrefixes": [string],"vpcPrefixes": [{"name": string,"value": string,"disableExternalPropagate": boolean,"disableHostBgpPeering": boolean,"hostDhcpRoute": boolean,"public": boolean,"createdAt": string <date-time>,"updatedAt": string <date-time>,"status": integer <enum>}],"dnsServers": [string]}
Submit the request, passing the JSON object in the body as data.json
.
$curl -X POST https://api.coreweave.com/v1/networking/vpcs \-H "Content-Type: application/json" \-H "Authorization: Bearer {API_ACCESS_TOKEN}" \-d @data.json
A successful response returns a VPC object, with the newly-assigned id
.
{"vpc": {"id": string,"name": string,"status": integer <enum>,"zone": string,"pubImport": boolean,"hostPrefixes": [string],"vpcPrefixes": [{"name": string,"value": string,"disableExternalPropagate": boolean,"disableHostBgpPeering": boolean,"hostDhcpRoute": boolean,"public": boolean,"createdAt": string <date-time>,"updatedAt": string <date-time>,"status": integer <enum>}],"dnsServers": [string],"createdAt": string <date-time>,"updatedAt": string <date-time>}}
VPCs by ID
To retrieve, update, or delete a VPC by ID, use the /v1/networking/vpcs/{id}
endpoint. The API supports the GET
, PATCH
, and DELETE
methods.
GET /v1/networking/vpcs/{id}
To get information about a VPC, use the GET
method with the /v1/networking/vpcs/{id}
endpoint. Substitute {id}
with the VPC ID.
$curl -X GET https://api.coreweave.com/v1/networking/vpcs/{id} \-H "Content-Type: application/json" \-H "Authorization: Bearer {API_ACCESS_TOKEN}"
A successful response returns the VPC object.
{"vpc": {"id": string,"name": string,"status": integer <enum>,"zone": string,"pubImport": boolean,"hostPrefixes": [string],"vpcPrefixes": [{"name": string,"value": string,"disableExternalPropagate": boolean,"disableHostBgpPeering": boolean,"hostDhcpRoute": boolean,"public": boolean,"createdAt": string <date-time>,"updatedAt": string <date-time>,"status": integer <enum>}],"dnsServers": [string],"createdAt": string <date-time>,"updatedAt": string <date-time>}}
DELETE /v1/networking/vpcs/{id}
To delete a VPC, use the DELETE
method with the /v1/networking/vpcs/{id}
endpoint. Substitute {id}
with the VPC ID.
$curl -X DELETE https://api.coreweave.com/v1/networking/vpcs/{id} \-H "Content-Type: application/json" \-H "Authorization: Bearer {API_ACCESS_TOKEN}"
A successful response returns the deleted VPC object.
{"vpc": {"id": string,"name": string,"status": integer <enum>,"zone": string,"pubImport": boolean,"hostPrefixes": [string],"vpcPrefixes": [{"name": string,"value": string,"disableExternalPropagate": boolean,"disableHostBgpPeering": boolean,"hostDhcpRoute": boolean,"public": boolean,"createdAt": string <date-time>,"updatedAt": string <date-time>,"status": integer <enum>}],"dnsServers": [string],"createdAt": string <date-time>,"updatedAt": string <date-time>}}
PATCH /v1/networking/vpcs/{id}
To update a VPC, use the PATCH
method with the /v1/networking/vpcs/{id}
endpoint. Substitute {id}
with the VPC ID.
The cluster configuration must be supplied as a JSON object in the request body. The supported fields and their data types are as follows.
{"updateMask": string <field-mask>,"id": string,"pubImport": boolean,"hostPrefixes": [string],"vpcPrefixes": [{"name": string,"value": string,"disableExternalPropagate": boolean,"disableHostBgpPeering": boolean,"hostDhcpRoute": boolean,"public": boolean,"createdAt": string <date-time>,"updatedAt": string <date-time>,"status": integer <enum>}],"dnsServers": [string],}
Submit the request, passing the JSON object in the body as data.json
.
$curl -X PATCH https://api.coreweave.com/v1/networking/vpcs/{id} \-H "Content-Type: application/json" \-H "Authorization: Bearer {API_ACCESS_TOKEN}" \-d @data.json
A successful response returns the updated cluster object.
{"vpc": {"id": string,"name": string,"status": integer <enum>,"zone": string,"pubImport": boolean,"hostPrefixes": [string],"vpcPrefixes": [{"name": string,"value": string,"disableExternalPropagate": boolean,"disableHostBgpPeering": boolean,"hostDhcpRoute": boolean,"public": boolean,"createdAt": string <date-time>,"updatedAt": string <date-time>,"status": integer <enum>}],"dnsServers": [string],"createdAt": string <date-time>,"updatedAt": string <date-time>}}