Sparklines

Returns 12 months of weekly closing prices for all FX pairs. Ideal for rendering sparkline charts or mini trend visualisations.

Request

curl https://api.bytetree.io/api/rates/sparklines

Query Parameters

NameTypeRequiredDescription
formatstringNoResponse format: json (default), csv, or toon

Response

FieldTypeDescription
dataobjectMap of pair code to array of weekly closes

Each key is a currency pair code. Each value is an array of number values representing the closing price for that ISO week, ordered chronologically (oldest first).

{
  "data": {
    "GBPUSD": [1.2545, 1.2567, 1.2589, 1.2601, 1.2615, 1.2631, 1.2650, 1.2680, 1.2710, 1.2731],
    "EURUSD": [1.0820, 1.0845, 1.0867, 1.0890, 1.0912, 1.0935, 1.0950, 1.0970, 1.0985, 1.1002],
    "USDJPY": [150.20, 150.45, 150.78, 151.02, 151.15, 151.35, 151.50, 151.70, 151.85, 152.00]
  }
}

Notes