flexpool

API

The flexpoold HTTP API: health, the OpenAPI 3.1 description and problem documents.

The machine-readable description is served by every daemon at /api/v1/openapi.json (OpenAPI 3.1) and committed in the repository as openapi/flexpoold.json.

MethodPathAnswer
GET/healthz{"status":"ok","version":"…","service":"flexpoold"}
GET/api/v1/openapi.jsonThe OpenAPI 3.1 document

Sandbox (scenario mode only)πŸ”—

MethodPathAnswer
GET/api/v1/sandbox/clockThe test clock: now, scenario, day, next event, end
POST/api/v1/sandbox/clock/advance{"to":"next-gate"} or an RFC 3339 instant β†’ now and the events passed
GET/api/v1/market/day-ahead/prices?day=Day-ahead prices as known at the test clock, with time unit and rule β€” or 425 not-yet-known

See Sandbox and scenarios.

PortfolioπŸ”—

Present when portfolio.dir is set β€” see Portfolio. Peers outside auth.trusted_networks need a bearer token, or get 401 unauthorized.

MethodPathAnswer
GET/api/v1/portfolioPools with asset counts, kinds, MW and MWh, reserve groups; totals
GET/api/v1/assets?pool=&kind=&q=&after=&limit=A page of assets (limit ≀ 500, q ≀ 64 characters, matching id, MaLo, SR-ID or TR-ID) and the cursor next
GET/api/v1/assets/{id}One asset with its technical unit, reserve group, pool, owner and slices

Without a portfolio these answer 404 not-found and say why.

TelemetryπŸ”—

Present with a portfolio β€” see Telemetry. In scenario mode every answer is as of the test clock.

MethodPathAnswer
GET/api/v1/telemetryFeed-in, consumption, net, stored energy and assets by quality, per pool and in total
GET/api/v1/assets/{id}/telemetry?day=Latest values, the day's quarter hours up to now, the last 15 minutes
GET/api/v1/connectionsConnections with state, last value, counters and last errors

Asset rows carry their quality now, and /api/v1/assets?quality= filters by it.

AlarmsπŸ”—

Present with a portfolio β€” see Alarms: alarms, acknowledge, shelve, handover, notes, the journal and paging deliveries. Actions take JSON bodies only.

ForecastπŸ”—

See Forecast.

MethodPathAnswer
GET/api/v1/forecasts/day-ahead?day=&model=A day's quantile forecast (blend by default), with issued_at, gate and late
POST/api/v1/forecasts/day-aheadSubmit your model's forecast; the issue time is the server's
GET/api/v1/forecasts/day-ahead/ladder?days=Every model scored on the last 1–28 days with known prices

PlanπŸ”—

See Plan. Paper only.

MethodPathAnswer
GET/api/v1/plan/day-ahead?day=&model=&risk=Per battery pool: schedule, state of charge, water values, protective limit orders, revenue across scenarios; committed from the gate on; result per pool once prices are published
GET/api/v1/plan/day-ahead/backtest?model=&risk=The last 14 days with prices, each planned at its gate: paper, perfect foresight, capture per pool

BookπŸ”—

See Book: pre-trade checks, release, the kill switch, positions, the Fahrplan CSV and the nomination under /api/v1/book/…. Actions take JSON only.

Events and the flexibility marketπŸ”—

See Events and Flexibility market.

MethodPathWhat
POST/api/v1/eventsSigned CloudEvents, one or a batch: flexibility requests, orders and settlements, erasures
GET/api/v1/flex/requestsReceived requests and the offer drafted for each
GET/api/v1/flex/offersDrafts and sent offers, with their split per battery
POST/api/v1/flex/offers/{id}/sendSend a draft (a person's decision)
GET/api/v1/flex/ordersReceived orders
GET/api/v1/flex/settlementsSettlements and the verdict on each
GET/api/v1/flex/deliveriesThe market webhooks' delivery log
GET/api/v1/erasuresErasures and where each stands (Data protection)

MCPπŸ”—

POST /mcp serves the read operations that declare x-mcp as Model Context Protocol tools. See Agents and MCP.

ErrorsπŸ”—

Every error is application/problem+json (RFC 9457) with a stable code and the request id:

{
  "type": "https://hupe1980.github.io/flexpool/problems/not-found/",
  "title": "Not found",
  "status": 404,
  "code": "not-found",
  "request_id": "01JF…"
}

The request_id is also in the x-request-id header and in the daemon's logs, so an operator can find the matching log line. Internal detail is never returned. All codes β†’

LimitsπŸ”—

LimitDefaultAnswer when exceeded
Request body1 MiB413 payload-too-large
Request duration30 s408 timeout
Requests in flight256503 overloaded
Request headers16 KiB, read within 10 sconnection closed

Edit this page