electricitymaps / electricitymaps-contrib

A real-time visualisation of the CO2 emissions of electricity consumption
https://app.electricitymaps.com
GNU Affero General Public License v3.0
3.52k stars 937 forks source link

Great Britain Data Source #4735

Open simosito opened 1 year ago

simosito commented 1 year ago

There is an official GB National Grid API that can show carbon intensity for energy generation mix, including for historical data, and including breakdown between different sources.

API documentation URL: https://carbon-intensity.github.io/api-definitions/#carbon-intensity-api-v2-0-0

VIKTORVAV99 commented 1 year ago

While we can't use the carbon intensity API the website you linked has an endpoint for generation mix as well and this we can use. I'll see if I can build a parser for it this week.

Generation Mix endpoint documentation: https://carbon-intensity.github.io/api-definitions/#get-generation

VIKTORVAV99 commented 1 year ago

Okay so after looking at what the API actually returns it looks like we won't be able to use this on its own as it only returns the percentage of each fuel not the amount. On a positive note it looks like it has a regional API with generation mix as well so if we find a secondary source that has the total production we could combine the two and get regional data.

madsnedergaard commented 1 year ago

See also previous context here: https://github.com/electricitymaps/electricitymaps-contrib/issues/1894