Hopp til innhold

Delivery Charge API
(Nettleie-API)

Distribution Systems Operators (DSO) - på norsk, nettselskap - provide the physical power grid from suppliers to households. They charge fees for usage which are covered in the ecomon API. Read more about delivery charge here, and see status for all DSO model implementations here.

With the deliveryChargeModel query on https://api.ecomon.no one can get prices, capacity levels, and other model info from a DSO.

In order to make it easy to use for developers, we’ve put all the models into the same query, and split the model up into parts to reflect the price model used by DSOs.

note

You can use the docs and schemas in the GraphQL Playground make your own queries to deliveryChargeModel, but you can also copy the complete query example found further down and modify it to fit your needs.

If you have questions, ask us on Slack, chat or send us a mail on support@harktech.no

We always try to keep up with merging of DSOs and consequently the name changes, but occasionally, we choose to keep the old names. For example, we will use the old names if two DSOs merge together, but continue using the old prices and/or GLN numbers for the different geographic areas, corresponding to the old DSOs. This is the case for the following DSOs:

  • Linja: Mørenett and Linja merged to Linja, but the prices are still different and based on the old DSOs. In the API you will find them under the old DSO names.

  • Noranett is the name of the merged DSO of Hålogaland kraftnett, Andøy nett and Trollfjord. Since the prices are still the same as the old DSOs, you will find them under the old DSO names.

Prerequisites

You need an API key to do deliveryChargeModel queries. Use it in our GraphQL Playground to test and explore queries, similarly to what you might have done in the Getting started guide.

If you have already been in contact with us you should have an API key with the correct permissions - if you haven't been in contact with us, feel free to send us a message on Slack, chat or send us a mail on support@harktech.no.

Model structure introduction

DSO price models have one capacityModel and one energyModel. Below is a list of all price models in use. Each of these models have a different structure describing the full price model.

  • capacityModel:
    • MonthlyPeaksAtDifferentDays
    • MonthlyPeaksAtDifferentDaysLinearWithBase
    • WeightedYearlyRollingPeaksInDifferentWeeks
    • FuseAndVoltageSize
  • energyModel:
    • ConstantPrice
    • DifferentPricesDayAndNight
    • DifferentPricesSeasonalDayAndNight
    • DifferentSeasonal
    • SelectableEnergyModel (made up by two or more of the above)

A detailed and more technical description for each of these models are found in the docs and schema on GraphQL Playground (https://api.ecomon.no). You will find the structure and types of both the input needed to query, and also the price models one can get in the response under Queries and deliveryChargeModel(...).

When you query for the model, you get it back as an object that includes an id, capacityModel and energyModel. Then you can check the type of energyModel and capacityModel by inspecting the field __typename.

Simple query example

A simple query to get the capacity levels from ELVERKET_HOLAND could like something like this:

query {
deliveryChargeModel(input: { id: ELVERKET_HOLAND }) {
id
capacityModel {
... on MonthlyPeaksAtDifferentDays {
peaksPerMonth
capacitySteps {
rangeInWh {
from
to
}
}
}
}
}
}

Which will give you this response:

{
"data": {
"deliveryChargeModel": {
"id": "ELVERKET_HOLAND",
"capacityModel": {
"peaksPerMonth": 3,
"capacitySteps": [
{
"rangeInWh": {
"from": 0,
"to": 1999
}
},
{
"rangeInWh": {
"from": 2000,
"to": 4999
}
},
{
"rangeInWh": {
"from": 5000,
"to": 9999
}
},

// ...

]
}
}
}
}

... one might want to query for more than just capacity levels. Look further down to find a complete query you can use for any DSO and to get all data.

Input

When querying for a model, you can query either with a GLN or with the DSO’s ID. These IDs can be found in the API by opening the docs in the GraphQL Playground deliveryChargeModel-->input-->id.

Complete query example

Since the API is in GraphQL, you can specify which fields you want to have returned. So don’t be alarmed by the output in the example below; it contains all the fields for demonstration purposes, and can be trimmed down for your needs.

query deliveryChargeModelExample {
deliveryChargeModel(input: { id: SUNETT }) {
id
gln
validFrom
timezone
capacityModel {
... on MonthlyPeaksAtDifferentDays {
__typename
peaksPerMonth
priceAboveCapacitySteps {
price
priceCurrency
vat
priceExcludingVat
}
capacitySteps {
rangeInWh {
from
to
}
capacityStepPrice {
price
priceCurrency
vat
priceExcludingVat
}
}
}
... on WeightedYearlyRollingPeaksInDifferentWeeks {
__typename
baseFeePerYear {
price
priceCurrency
priceExcludingVat
vat
}
monthWeights {
january
february
march
april
may
june
july
august
september
october
november
december
}
pricePerKwhForAverageOfPeaks {
price
priceCurrency
vat
priceExcludingVat
}
weekPeaksPerYear
}
... on MonthlyPeaksAtDifferentDaysLinearWithBase {
__typename
baseFeePerYear {
price
priceCurrency
priceExcludingVat
vat
}
peaksPerMonth
pricePerKwhForAverageOfPeaks {
price
priceCurrency
vat
priceExcludingVat
}
}

... on FuseAndVoltageSize {
__typename
onePhasePrices {
voltage230 {
currentRangePrices {
yearlyPrice {
price
priceCurrency
vat
priceExcludingVat
}
}
yearlyPriceAboveCurrentRanges {
price
priceCurrency
vat
priceExcludingVat
}
}
voltage400 {
currentRangePrices {
yearlyPrice {
price
priceCurrency
vat
priceExcludingVat
}
}
yearlyPriceAboveCurrentRanges {
price
priceCurrency
vat
priceExcludingVat
}
}
}
threePhasePrices {
voltage230 {
currentRangePrices {
yearlyPrice {
price
priceCurrency
vat
priceExcludingVat
}
}
yearlyPriceAboveCurrentRanges {
price
priceCurrency
vat
priceExcludingVat
}
}
voltage400 {
currentRangePrices {
yearlyPrice {
price
priceCurrency
vat
priceExcludingVat
}
}
yearlyPriceAboveCurrentRanges {
price
priceCurrency
vat
priceExcludingVat
}
}
}
}
}
energyModel {
... on ConstantPrice {
__typename
pricesAndTaxes {
priceIncludingEnergyTaxes {
price
priceCurrency
vat
priceExcludingVat
}
priceExcludingEnergyTaxes {
price
priceCurrency
vat
priceExcludingVat
}
taxes {
electricalPowerTax {
price
priceCurrency
vat
priceExcludingVat
}
energyFund {
price
priceCurrency
vat
priceExcludingVat
}
}
}
}
... on DifferentPricesDayAndNight {
__typename
prices {
day {
hours {
from
until
}
pricesAndTaxes {
priceIncludingEnergyTaxes {
price
priceCurrency
vat
priceExcludingVat
}
priceExcludingEnergyTaxes {
price
priceCurrency
vat
priceExcludingVat
}
taxes {
electricalPowerTax {
price
priceCurrency
vat
priceExcludingVat
}
energyFund {
price
priceCurrency
vat
priceExcludingVat
}
}
}
}
night {
hours {
from
until
}
pricesAndTaxes {
priceIncludingEnergyTaxes {
price
priceCurrency
vat
priceExcludingVat
}
priceExcludingEnergyTaxes {
price
priceCurrency
vat
priceExcludingVat
}
taxes {
electricalPowerTax {
price
priceCurrency
vat
priceExcludingVat
}
energyFund {
price
priceCurrency
vat
priceExcludingVat
}
}
}
}
}
weekendPricesFollowNightPrices
holidayPricesFollowNightPrices
}
... on DifferentPricesSeasonalDayAndNight {
__typename
weekendPricesFollowNightPrices
holidayPricesFollowNightPrices
seasons {
summer {
months {
from
until
}
prices {
day {
hours {
from
until
}
pricesAndTaxes {
priceIncludingEnergyTaxes {
price
priceCurrency
vat
priceExcludingVat
}
priceExcludingEnergyTaxes {
price
priceCurrency
vat
priceExcludingVat
}
taxes {
electricalPowerTax {
price
priceCurrency
vat
priceExcludingVat
}
energyFund {
price
priceCurrency
vat
priceExcludingVat
}
}
}
}
night {
hours {
from
until
}
pricesAndTaxes {
priceIncludingEnergyTaxes {
price
priceCurrency
vat
priceExcludingVat
}
priceExcludingEnergyTaxes {
price
priceCurrency
vat
priceExcludingVat
}
taxes {
electricalPowerTax {
price
priceCurrency
vat
priceExcludingVat
}
energyFund {
price
priceCurrency
vat
priceExcludingVat
}
}
}
}
}
}
}
}
... on DifferentPricesSeasonal {
__typename
seasons {
summer {
months {
from
until
}

pricesAndTaxes {
priceIncludingEnergyTaxes {
price
priceCurrency
vat
priceExcludingVat
}
priceExcludingEnergyTaxes {
price
priceCurrency
vat
priceExcludingVat
}
taxes {
electricalPowerTax {
price
priceCurrency
vat
priceExcludingVat
}
energyFund {
price
priceCurrency
vat
priceExcludingVat
}
}
}
}
}
}
... on SelectableEnergyModel {
differentPricesSeasonal {
seasons {
summer {
months {
from
until
}

pricesAndTaxes {
priceIncludingEnergyTaxes {
price
priceCurrency
vat
priceExcludingVat
}
priceExcludingEnergyTaxes {
price
priceCurrency
vat
priceExcludingVat
}
taxes {
electricalPowerTax {
price
priceCurrency
vat
priceExcludingVat
}
energyFund {
price
priceCurrency
vat
priceExcludingVat
}
}
}
}
}
}
differentPricesSeasonalDayAndNight {
__typename
weekendPricesFollowNightPrices
holidayPricesFollowNightPrices
seasons {
summer {
months {
from
until
}
prices {
day {
hours {
from
until
}
pricesAndTaxes {
priceIncludingEnergyTaxes {
price
priceCurrency
vat
priceExcludingVat
}
priceExcludingEnergyTaxes {
price
priceCurrency
vat
priceExcludingVat
}
taxes {
electricalPowerTax {
price
priceCurrency
vat
priceExcludingVat
}
energyFund {
price
priceCurrency
vat
priceExcludingVat
}
}
}
}
night {
hours {
from
until
}
pricesAndTaxes {
priceIncludingEnergyTaxes {
price
priceCurrency
vat
priceExcludingVat
}
priceExcludingEnergyTaxes {
price
priceCurrency
vat
priceExcludingVat
}
taxes {
electricalPowerTax {
price
priceCurrency
vat
priceExcludingVat
}
energyFund {
price
priceCurrency
vat
priceExcludingVat
}
}
}
}
}
}
}
}
differentPricesDayAndNight {
__typename
prices {
day {
hours {
from
until
}
pricesAndTaxes {
priceIncludingEnergyTaxes {
price
priceCurrency
vat
priceExcludingVat
}
priceExcludingEnergyTaxes {
price
priceCurrency
vat
priceExcludingVat
}
taxes {
electricalPowerTax {
price
priceCurrency
vat
priceExcludingVat
}
energyFund {
price
priceCurrency
vat
priceExcludingVat
}
}
}
}
night {
hours {
from
until
}
pricesAndTaxes {
priceIncludingEnergyTaxes {
price
priceCurrency
vat
priceExcludingVat
}
priceExcludingEnergyTaxes {
price
priceCurrency
vat
priceExcludingVat
}
taxes {
electricalPowerTax {
price
priceCurrency
vat
priceExcludingVat
}
energyFund {
price
priceCurrency
vat
priceExcludingVat
}
}
}
}
}
weekendPricesFollowNightPrices
holidayPricesFollowNightPrices
}
constantPrice {
__typename
pricesAndTaxes {
priceIncludingEnergyTaxes {
price
priceCurrency
vat
priceExcludingVat
}
priceExcludingEnergyTaxes {
price
priceCurrency
vat
priceExcludingVat
}
taxes {
electricalPowerTax {
price
priceCurrency
vat
priceExcludingVat
}
energyFund {
price
priceCurrency
vat
priceExcludingVat
}
}
}
}
}
}
}
}