Authentication
Every request must be authenticated with your API key. The key is passed in the
Authorization header as the raw key — there is no Bearer prefix.
Authorization: your_api_key
import requests
headers = {"Authorization": "your_api_key"}
resp = requests.get(
"https://api.rebase.energy/weather/v2/point/operational",
headers=headers,
params={
"model": "DWD_ICON-EU",
"latitude": 60.1,
"longitude": 16.5,
"variables": "Temperature",
},
)
Query-parameter fallback
Some HTTP clients drop the Authorization header when following redirects (the /query
endpoint redirects internally to the operational or historical handler). For those clients
you can pass the key as an api_key query parameter instead:
https://api.rebase.energy/weather/v2/query?api_key=your_api_key&model=...
Prefer the header where possible; the query parameter is only a fallback because URLs (and their query strings) are more likely to be logged.
Getting and managing a key
API keys are issued from your Rebase account. If you don't have one yet, contact Rebase to get access.
Errors
A missing or invalid key returns 401 Unauthorized; a key without access to the requested
resource returns 403 Forbidden. See Errors for the full list of status codes.