---
title: "Remote write"
method: POST
path: "/api/v1/write"
---

# Remote write

`POST /api/v1/write`

Ingest time series data using the
[Prometheus Remote Write 1.0](https://prometheus.io/docs/specs/prw/remote_write_spec/)
protocol.

The request body must be a **Snappy-compressed** protobuf `WriteRequest`
message (as defined by the Prometheus remote write specification). Each
`WriteRequest` contains one or more `TimeSeries` messages, each with a
set of labels and one or more timestamp/value sample pairs.

This endpoint is designed for integration with Prometheus remote-write
compatible agents and collectors. It is not intended as a general-purpose
high-throughput ingestion path — for bulk data loading, prefer dedicated
import tooling.

This endpoint is only available when the server is built with
the `remote-write` feature.

## Headers

- `Content-Type` 'application/x-protobuf', required
- `Content-Encoding` 'snappy', required

## Response `204`

Samples ingested successfully (empty body).

## Other responses

- `400` — Invalid request. Possible causes include wrong `Content-Type`, Snappy decompression failure, protobuf decode error, or invalid sample data (e.g. missing labels). The `errorType` will be `bad_data`.
- `500` — Internal server error. The `errorType` will be `internal`.
- `503` — Service unavailable. The server is under backpressure and cannot accept writes at this time. Clients should back off and retry. The `errorType` will be `unavailable`.

---

[API](https://skmtc.dev/opendata-oss/apis/opendata-timeseries-api.md) · [All operations](https://skmtc.dev/opendata-oss/apis/opendata-timeseries-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/opendata-oss/opendata-timeseries-api/revisions/6e511aad037c/schema)
