The National and GSP API endpoints are documented here and here (swagger)

The Site API endpoints are documented here and here (swagger)

Bash

Example URL calls to the API are below

export AUTH=$(curl --request POST \\
   --url <https://nowcasting-pro.eu.auth0.com/oauth/token> \\
   --header 'content-type: application/json' \\
   --data '{"client_id":"QLMdXCCHMS9Zl5W2tDG3otpdcY7GeEnJ", "audience":"<https://api.nowcasting.io/>", "grant_type":"password", "username":"username", "password":"password"}'
)
export TOKEN=$(echo "${AUTH}" | jq '.access_token' | tr -d '"')

Run API command

curl -X GET '<https://api.quartz.solar/v0/solar/GB/national/forecast?historic=true&only_forecast_values=true>' -H "Authorization: Bearer $TOKEN"

Python

A python example to get access_token

import requests
import json

client_id = "QLMdXCCHMS9Zl5W2tDG3otpdcY7GeEnJ"
username="username"
pwd = "pwd"
domain = "nowcasting-pro.eu.auth0.com"
grant_type="password"

url = f"https://{domain}/oauth/token"
header = {'content-type': 'application/json'}
data = json.dumps({"client_id":client_id,"username":username,"password":pwd,"grant_type":grant_type,"audience":"<https://api.nowcasting.io/>"})

r = requests.post(url, data=data, headers=header)
access_token = r.json()['access_token']

Python example to get data from the API:

import requests
# need to get the access_token for the code above

url = "<https://api.quartz.solar/v0/solar/GB/national/forecast?historic=true&>"
r = requests.get(url=url,headers={"Authorization": "Bearer "+access_token})

data = r.json()