Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

The Nationaal Energie Dashboard API provides insight into the current and historical sustainable energy generation in the Netherlands.

What is

...

The Nationaal Energie Dashboard API provides insight into the current, forecasted and historical sustainable energy generation and consumption in the Netherlands.

What is an API?

An API (Application Programming Interface) is a software interface through which two applications can easily communicate with each other. By submitting a request with certain parameters such as the sustainable source and date, the NetAnders API returns the requested energy data.

What can you do with the API?

...

If you have the right authorisation, with the API you gain insight into:

...

The near real-time renewable energy production in the Netherlands

insight into:

  • Near-realtime electricity generation and gas consumption in the Netherlands. The total and broken down by energy carrier.

  • Week ahead forecast of solar energy, onshore wind energy, offshore wind energy, gas consumption of households and small businesses. For solar energy and onshore wind energy there is also a breakdown by provinces; for offshore wind energy there is a breakdown by individual offshore wind farms.

  • The production in capacity (kW) and in volume (kWh)

  • The utilization rates of sustainable energy sources expressed in percentages compared to the installed capacity

  • The various sustainable energy sources. Get insight to all of them of just a selection. We provide insights into the following sources: solar, onshore wind, offshore wind, biogas, heat pumps, geothermal energy, adding and co-firing of biomass in coal-fired power stations, biomass boilers companies, wood stoves at home, waste plants and bio-oilof just a selection.

  • The historical sustainable production from 2016, the non-sustainable electricity production from 2021

  • 10 minutes, 15 minutes, hour, day, month and year values

  • The total electricity production generated by various sources for the Netherlands

  • The gas consumption for the Netherlands, excluding feedstock and powerplant usage

  • ….

What type of API is it?

The NetAnders Nationaal Energie Dashboard API is a RESTful Open Api. The following file formats are available: jsonld, jsonhal, jsonapi, json, xml, csv and html.

Access to the API - API Key

You can make an account on ned.nl. In your account you can generate an API Key. This unique key gives access to requesting energy data from the Nationaal Energie Dashboard API. The API key must be sent with every request. Do not give the key to others.

API specifications

For the developers, the detailed specifications of the API can be found in Swagger UI or Redoc via the following links:

• Swagger UI: https://api.netanders.io/v1

• Redoc: https://api.netanders.io/v1?ui=re_doc

...

The current rate limit of the API is set at 400 requests per minute.

Submitting a request

When submitting a request, a number of parameters must be included. The table below shows and describes the available parameter values. You can enter an individual value or a collection of values ​​that refer to a series of individual values.

Example for a request

Suppose you want to receive the Dutch solar data in 10 minutes values on November 16, 2020 in json. To do this, include the following parameters in the request. Below we also highlight a request in cURL, PHP-cURL and Python.

The header

Code Block
Accept: application/ld+json: json – file format.  
X-AUTH-TOKEN: YourSuperSecretApiKey – API Key

Main message

Code Block
Point: 0 - Netherlands
Type: 2 - Solar
Granularity 3 - 10 min 
Timezone 1 - UTC 
Classification 2 – current 
Activity 1 - providing 
Validfromstrictlybefore 2020-11-16  
Validfromafter  2020-11-17

cURL

Code Block
curl --location -g --request GET 'https://api.netanders.io/v1/utilizations?point=0&type=2&granularity=3&granularitytimezone=1&classification=2&activity=10&validfrom[strictly_before]=2020-11-17&validfrom[after]=2020-11-16' \
  --header 'X-AUTH-TOKEN: YourSuperSecretApiKey ' \
  --header 'accept: application/ld+json '

PHP- cURL

Code Block
<?php
$curl = curl_init();
curl_setopt_array($curl, array(
  CURLOPT_URL => 'https://api.netanders.io/v1/utilizations?point=0&type=2&granularity=3&granularitytimezone=1&classification=2&activity=10&validfrom%5Bstrictly_before%5D=2020-11-17&validfrom%5Bafter%5D=2020-11-16',
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => '',
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 0,
  CURLOPT_FOLLOWLOCATION => true,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => 'GET',
  CURLOPT_HTTPHEADER => array(
    'X-AUTH-TOKEN: YourSuperSecretApiKey ', ),
));

$response = curl_exec($curl);

curl_close($curl);

echo $response;

Python

Code Block
import requests

url = "https://api.netanders.io/v1/utilizations?point=0&type=2&granularity=3&granularitytimezone=1&classification=2&activity=10&validfrom[strictly_before]=2020-11-17&validfrom[after]=2020-11-16"

payload={}

headers = {
  'X-AUTH-TOKEN': ' YourSuperSecretApiKey ',
  'accept: application/ld+json '}

response = requests.request("GET", url, headers=headers, data=payload, allow_redirects=False)

print(response.text)

Visualisation snippet

To get an idea of ​​the energy data that is requested, we provide a snippet with which the data can be visualized. The snippet is easy to use in for example Postman, among others. The snippet can be found via this link: https://bitbucket.org/netanders/workspace/snippets/RLpGgL/postman-test-and-visualize

Response to the request

After the request, a result will be returned in the desired file format. The following data is returned:

• Capacity - the average capacity over the selected granularity in kW

• Volume - the production volume in kWh

• Percentage - the utilization rate as a percentage of the total capacity at that moment

• Emission – the emission of CO2 in kg

• Emissionfactor – the emission factor used for this source in kg/kWh, if no value is provided the emission is zero (0)

Tip: for a visualization of the generation it is easiest to use the capacity.

Below the data that is returned by the API. This is a record from the example mentioned.

Code Block
"@id": "/v1/utilizations/3844522221",
"@type": "Utilization",
"type": "/v1/types/2",
"granularity": "/v1/granularities/3",
"granularitytimezone": "/v1/granularity_time_zones/0",
"id": 3844522221,
"point": "/v1/points/0",
"activity": "/v1/activities/1",
"classification": "/v1/classifications/2",
"capacity": 438626,
"volume": 73104,
"emission":,
"emissionfactor":,
"percentage": 0.05968400090932846,
"validfrom": "2020-11-16T14:30:00+00:00",
"validto": "2020-11-16T14:40:00+00:00",
"lastupdate": "2020-11-19T14:06:04+00:00"

...

Also note that aggregations (i.e. day, month, year) are only computed for CET and will only return values for GranularityTimeZone = 1. When GranularityTimeZone = 0 is chosen no values will be returned.

Parameter table

Parameter

Description

Values

Activity

Gives the activity type of the energy record.

1 Providing
2 Consuming

Authorisation

Gives the Authorisations for users.

True

Validfrom[mod]

Data selection, use after, strictly_after, before or strictly_before in place of mod.

Format: YYYY-MM-DD

Classification

Gives the Classification type of the energy record. (Ex. Near-realtime or Forecast)

1 Backcast
2 Current
3 Forecast

Granularity

Every Utilization data record is a grouped by a granularity. This table has the Granularity names.

3 10 minutes
4 15 minutes
5 Hour
6 Day
7 Month
8 Year

GranularityTimeZone

Every Granularity is valid for a certain timezone, this data record holds the name of this timezone.

0 UTC

1 CET (Central European Time)

Point

Gives the Point of the energy record.

0 Nederland
1 Groningen
2 Friesland
3 Drenthe
4 Overijssel
5 Flevoland
6 Gelderland
7 Utrecht
8 Noord-Holland
9 Zuid-Holland
10 Zeeland
11 Noord-Brabant
12 Limburg
14 Offshore
28 Windpark Luchterduinen
29 Windpark Princes Amalia
30 Windpark Egmond aan Zee
31 Windpark Gemini
33 Windpark Borselle I&II
34 Windpark Borselle III&IV
35 Windpark Hollandse Kust Zuid
36 Windpark Hollandse Kust Noord

Type

Gives the Type of the energy resource (for a more detailed description, see https://netanders.atlassian.net/wiki/spaces/PAD/pages/15204353 ).

0 All
1 Wind
2 Solar
3 Biogas
4 HeatPump
8 Cofiring
9 Geothermal
10 Other
11 Waste
12 BioOil
13 Biomass
14 Wood
17 WindOffshore
18 FossilGasPower
19 FossilHardCoal
20 Nuclear
21 WastePower
22 WindOffshoreB
23 NaturalGas
24 Biomethane
25 BiomassPower
26 OtherPower
27 ElectricityMix
28 GasMix
31 GasDistribution
35 WKK Total
50 SolarThermal
51 WindOffshoreC
53 IndustrialConsumersGasCombination

54 IndustrialConsumersPowerGasCombination

55 LocalDistributionCompaniesCombination

56 AllConsumingGas

Historical data updates

Sometimes historical data provided by the API gets updated. Several triggers exist, which include

  1. changes in the source data

  2. changes in model parameters

  3. changes in the model itself

Whenever a trigger has occurred the ‘lastupdate’ field is modified (note that this does not necessarily mean the interval value itself has changed). Some triggers are periodic (i.e. data gets recomputed daily) and others are manual (recomputation gets done by NetAnders’s Nationaal Energie Dashboard’s request).

Any questions, just let us know!

contact@ned.nl

Nationaal-energie-dashboard_RGB.jpg