Metrics

CoreWeave manages the Prometheus cluster that will host your metrics.

To access CoreWeave's Prometheus server you'll first need a CoreWeave account and an Access Token. If you don't have an account yet, follow the steps on the Getting Started guide.

You'll be able to access the Prometheus Dashboard once you're logged into CoreWeave.

Access the Prometheus Dashboard at https://prometheus.ord1.coreweave.com

API Key Authentication

You can access the Prometheus server by sending your Access Token as the Authorization Header during your request.

  • Header: Authorization Value: Bearer <TOKEN>

  • URL: https://prometheus.ord1.coreweave.com

  • Methods: GET or POST

Replace <TOKEN> with your CoreWeave Access Token generated from https://cloud.coreweave.com/api-access.

post
Prometheus Query using Access Token

https://prometheus.ord1.coreweave.com/v1/api/query
Example usage for sending a request to the Prometheus API using your Access Token.
Request
Response
Request
Headers
Authorization
required
string
Set value to Bearer <TOKEN> as the value, replacing <TOKEN> with your CoreWeave Access Token.
Query Parameters
time
required
number
Unix timestamp of current time
query
required
string
Insert PromQL Query (kube_pod_container_info)
Response
200: OK
Prometheus Data response on a query
{
"status": "success",
"data": {
"resultType": "vector",
"result": [{
"metric": {
"__name__": "kube_pod_container_info",
"container": "example",
"container_id": "docker://1548c7ce5d717cfb9e3e797464d9fe4fbda0cea6f324fda8b9b64b2f5fd44e2f",
"endpoint": "http",
"image": "example/example_image:1.6.4",
"image_id": "docker-pullable://docker-registry-image",
"instance": "10.0.0.1:8080
"job": "kube-state-metrics",
"namespace": "tenant-example",
"pod": "example-5d796977bc-crk9m",
"service": "tenant-metrics-kube-state-metrics"
},
"value": [1629254349.447, "1"]
}]
}
}3

Metric Scraping

CoreWeave's hosted Prometheus cluster will scrape your targets using a ServiceMonitor. Annotations from the ServiceMonitor must match the Service hosting the Prometheus exporter endpoint. Usually /metrics

Below is an example of a Prometheus exporter that will be scraped by our Prometheus clusters.

servicemonitor.yaml
deployment.yaml
service.yaml
servicemonitor.yaml
apiVersion: monitoring.coreos.com/v1
kind: ServiceMonitor
metadata:
name: example
namespace: tenant-example
labels:
app: example
spec:
jobLabel: example-scraping
selector:
matchLabels:
app: example
namespaceSelector:
matchNames:
- tenant-example
endpoints:
- port: http
scheme: http
path: /metrics
interval: 15s
scrapeTimeout: 15s
deployment.yaml
apiVersion: apps/v1
kind: Deployment
metadata:
name: example
namespace: tenant-example
labels:
app: example
spec:
replicas: 1
selector:
matchLabels:
app: example
template:
metadata:
labels:
app: example
spec:
containers:
- name: example
image: "infinityworks/docker-hub-exporter:latest"
imagePullPolicy: Always
ports:
- name: http
containerPort: 9170
protocol: TCP
service.yaml
apiVersion: v1
kind: Service
metadata:
name: example
namespace: tenant-example
labels:
app: example
spec:
type: ClusterIP
ports:
- port: 8080
targetPort: 8080
protocol: TCP
name: http
selector:
app: example