ZeroCopyZeroCopy
ReferenceManagement API

Retrieve metric history

GET
/metrics/series

Requires the usage:read scope. Returns historical transaction metric buckets over up to 90 days, grouped by one dimension. Repeat filters to select several values.

Authorization

managementKey
headerAuthorizationBearer <zc_mgmt_>

Query Parameters

metric*string
Value in"transactions""landed_rate""failed_rate""expired_rate""slots_to_land""edge_time""tips""priority_fees"
group_by?string
Value in"key""metro""outcome""path""source""kind"
quantile?||
Default0.5
range?string
Default"24h"
Value in"1h""24h""7d""30d"
from?string
Formatdate-time
to?string
Formatdate-time
key_id?|array<>
metro?|array<>
outcome?|array<>

Response Body

Current transaction history, matching the console Metrics page

application/json
  1. response
metric*string
Value in"transactions""landed_rate""failed_rate""expired_rate""slots_to_land""edge_time""tips""priority_fees"
unit*string
Value in"transactions""percent""slots""microseconds""lamports"
quantile?number|number|number
step_seconds*integer
Range0 < value <= 9007199254740991
from*string

RFC 3339 time

Formatdate-time
to*string

RFC 3339 time

Formatdate-time
series*array<>
Example request
// src/bin/management_metric_history.rs
use serde_json::Value;
use swqos_examples::swqos::{Result, required};

#[tokio::main]
async fn main() -> Result<()> {
    let response = reqwest::Client::new()
        .get("https://console.zerocopy.sh/api/v1/metrics/series?metric=transactions&range=24h&group_by=outcome")
        .bearer_auth(required("MANAGEMENT_API_KEY")?)
        .send()
        .await?;
    let status = response.status();
    let body = response.text().await?;
    let reply: Value = serde_json::from_str(&body)
        .map_err(|error| format!("HTTP {status}: {error}; body: {body}"))?;
    if !status.is_success() {
        return Err(format!("HTTP {status}: {reply}").into());
    }
    println!("{}", serde_json::to_string_pretty(&reply)?);
    Ok(())
}
Example response
{
  "metric": "transactions",
  "unit": "transactions",
  "step_seconds": 60,
  "from": "2026-11-13T02:11:00.000Z",
  "to": "2026-11-13T02:14:00.000Z",
  "series": [
    {
      "labels": {
        "outcome": "landed"
      },
      "points": [
        [
          1794535860000,
          17
        ],
        [
          1794535920000,
          21
        ],
        [
          1794535980000,
          19
        ]
      ]
    },
    {
      "labels": {
        "outcome": "failed"
      },
      "points": [
        [
          1794535860000,
          1
        ],
        [
          1794535920000,
          2
        ],
        [
          1794535980000,
          1
        ]
      ]
    },
    {
      "labels": {
        "outcome": "expired"
      },
      "points": [
        [
          1794535860000,
          2
        ],
        [
          1794535920000,
          1
        ],
        [
          1794535980000,
          1
        ]
      ]
    }
  ]
}