Help us improve CoreWeave documentation. Take the docs survey.
curl --request POST \
--url https://api.coreweave.com/v1alpha1/inference/gateways \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "<string>",
"zones": [
"<string>"
],
"id": "<string>",
"coreWeaveAuth": {},
"weightsAndBiasesAuth": {
"apiKey": "<string>",
"serverUrl": "<string>",
"enableUsageReports": true,
"enableRateLimiting": true
},
"endpointConfiguration": {
"additionalDns": [
"<string>"
]
},
"pathBasedRouting": {}
}
'{
"gateway": {
"spec": {
"id": "<string>",
"name": "<string>",
"zones": [
"<string>"
],
"coreWeaveAuth": {},
"weightsAndBiasesAuth": {
"apiKey": "<string>",
"serverUrl": "<string>",
"enableUsageReports": true,
"enableRateLimiting": true
},
"organizationId": "<string>",
"endpointConfiguration": {
"additionalDns": [
"<string>"
]
},
"bodyBasedRouting": {
"apiType": "API_TYPE_OPENAI"
},
"headerBasedRouting": {
"headerName": "<string>"
},
"pathBasedRouting": {}
},
"status": {
"createdAt": "2023-11-07T05:31:56Z",
"updatedAt": "2023-11-07T05:31:56Z",
"conditions": [
{
"type": "<string>",
"lastUpdateTime": "2023-11-07T05:31:56Z",
"reason": "<string>",
"message": "<string>",
"zone": "<string>",
"status": "True"
}
],
"endpoints": [
"<string>"
],
"status": "STATUS_CREATING"
}
}
}Create a CoreWeave inference gateway with one authentication type and one routing strategy.
curl --request POST \
--url https://api.coreweave.com/v1alpha1/inference/gateways \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "<string>",
"zones": [
"<string>"
],
"id": "<string>",
"coreWeaveAuth": {},
"weightsAndBiasesAuth": {
"apiKey": "<string>",
"serverUrl": "<string>",
"enableUsageReports": true,
"enableRateLimiting": true
},
"endpointConfiguration": {
"additionalDns": [
"<string>"
]
},
"pathBasedRouting": {}
}
'{
"gateway": {
"spec": {
"id": "<string>",
"name": "<string>",
"zones": [
"<string>"
],
"coreWeaveAuth": {},
"weightsAndBiasesAuth": {
"apiKey": "<string>",
"serverUrl": "<string>",
"enableUsageReports": true,
"enableRateLimiting": true
},
"organizationId": "<string>",
"endpointConfiguration": {
"additionalDns": [
"<string>"
]
},
"bodyBasedRouting": {
"apiType": "API_TYPE_OPENAI"
},
"headerBasedRouting": {
"headerName": "<string>"
},
"pathBasedRouting": {}
},
"status": {
"createdAt": "2023-11-07T05:31:56Z",
"updatedAt": "2023-11-07T05:31:56Z",
"conditions": [
{
"type": "<string>",
"lastUpdateTime": "2023-11-07T05:31:56Z",
"reason": "<string>",
"message": "<string>",
"zone": "<string>",
"status": "True"
}
],
"endpoints": [
"<string>"
],
"status": "STATUS_CREATING"
}
}
}Documentation Index
Fetch the complete documentation index at: https://docs.coreweave.com/llms.txt
Use this file to discover all available pages before exploring further.
https://api.coreweave.com.{API_ACCESS_TOKEN} with your CoreWeave API access token.coreWeaveAuth or weightsAndBiasesAuth)
and exactly one routing strategy (bodyBasedRouting,
headerBasedRouting, or pathBasedRouting). The available
zones for zones are returned by
GET /v1alpha1/inference/gateways/parameters.
curl -X POST https://api.coreweave.com/v1alpha1/inference/gateways \
-H "Content-Type: application/json" \
-H "Authorization: Bearer {API_ACCESS_TOKEN}" \
-d @data.json
coreWeaveAuth: validate inference requests using the
same CoreWeave API access tokens used to call the
management API. No additional configuration is required.weightsAndBiasesAuth: validate inference requests
using Weights & Biases SaaS credentials. Optional fields
include enableUsageReports and enableRateLimiting. W&B
self-hosted is not currently supported.bodyBasedRouting: the model name is read from the
model field in the JSON request body. Set
apiType: API_TYPE_OPENAI for OpenAI-compatible behavior.pathBasedRouting: the model name is the first segment
of the URL path. URL-encode model names that contain
special characters.headerBasedRouting: the model name is read from a
custom HTTP header you specify in headerName (1–100
characters).CoreWeave API access token sent as a bearer token.
Request for CreateGateway
The human readable name of the gateway
The zones to make the gateway available in, limits where deployments associated with the gateway may exist, no zones means all may be used, case insensitive.
The unique identifier of the gateway, UUID format
CoreWeave IAM
Weights & Biases
Show child attributes
Additional endpoint configuration options
Show child attributes
Body based routing
Show child attributes
Header based routing
Show child attributes
Path based routing
OK
Response for CreateGateway
The gateway that was created
Show child attributes
Was this page helpful?