API

Entitlements API

Check which plan an API key is on and how much grid history it can request.

Overview

The Entitlements API tells you which plan your Greenpixie API key is on and how much grid history you can request.

Request

curl "https://api.greenpixie.com/v1/entitlements" \
  -H "Authorization: Bearer $GPX_KEY"

The endpoint takes no parameters. It accepts the same API key as the Rate Card API.

Response

{
  "plan": "paid",
  "grid_history": {
    "tier": "historic",
    "earliest_period": "2020-01",
    "latest_period": "2026-10"
  }
}
FieldDescription
planThe plan the key is on: free or paid.
grid_historyThe grid periods the key can request.

Grid history

grid_history tells you which months you can pass as grid_period on the Rate Card API.

FieldDescription
tierhistoric for any period with grid data, or last_complete_month for that single month.
earliest_periodThe earliest month the key can request, as YYYY-MM.
latest_periodThe latest complete month the key can request, as YYYY-MM. Also the month used when a request sends no grid_period.

On the last_complete_month tier, earliest_period and latest_period are the same month.

Errors

StatusCodeMeaning
401key_not_recognisedThe API key is missing, not recognised, revoked or expired.
403insufficient_scopeThe API key cannot read rate cards.
403terms_not_acceptedThe key's organisation has not accepted the terms in the app.
503grid_data_unavailableGrid history cannot be reported right now. Retry later.

See the API reference for the full schema.

On this page