Endpoints of REST-API

You can test the endpoints by running this app locally and visit the docs page http://localhost:8080/docs.

Or you can use access the development deployment or the production deployment. For more information visit this page.

OpenAPI description

POST /auth/login

Login

OAuth2 compatible token login, get an access token for future requests

Status Codes:
POST /auth/register

Register

Create a new user

Status Codes:
GET /auth/test-token

Test Token

Test access token

Status Codes:
  • 200 OK – Successful Response

GET /users/

Get All Users

Retrieve all users.

Query Parameters:
  • skip (integer) –

  • limit (integer) –

Status Codes:
GET /datasets/

Get All Datasets

Retrieve all datasets.

Query Parameters:
  • skip (integer) –

  • limit (integer) –

Status Codes:
POST /datasets/

Create Dataset

Create a new dataset.

Status Codes:
GET /datasets/{dataset_id}

Get Dataset

Get a dataset by its id.

Parameters:
  • dataset_id (integer) –

Status Codes:
PUT /datasets/{dataset_id}

Update Dataset

Update a dataset.

Parameters:
  • dataset_id (integer) –

Status Codes:
DELETE /datasets/{dataset_id}

Remove Dataset

Delete a dataset.

Parameters:
  • dataset_id (integer) –

Status Codes:
POST /datasets/{dataset_id}/upload

Upload Dataset Zip

Upload a dataset as zip.

Parameters:
  • dataset_id (integer) –

Status Codes:
GET /datasets/{dataset_id}/download

Download Dataset Zip

Download a dataset as zip.

Parameters:
  • dataset_id (integer) –

Status Codes:
GET /datasets/permissions/

Get All Dataset Permissions

Retrieve all dataset permissions.

If you provide a dataset_id, only the permissions for that dataset will be returned. Otherwise, all permissions for the current user will be returned.

Query Parameters:
  • dataset_id ({'null', 'integer'}) –

Status Codes:
POST /datasets/permissions/

Create Dataset Permission

Create a new dataset_permission.

Status Codes:
PUT /datasets/permissions/

Update Dataset Permission

Update a dataset-user permission.

You can not edit your own permissions. For editing other permissions, you need grant and revoke permissions. (Might change in future.)

Status Codes:
GET /datasets/permissions/{dataset_id}

Get Dataset Permission

Retrieve a dataset permission for the current user.

Parameters:
  • dataset_id (integer) –

Status Codes:
DELETE /datasets/permissions/{permission_id}

Remove Dataset Permission

Delete a dataset-user permission.

Parameters:
  • permission_id (integer) –

Status Codes:
GET /regions/{region_id}

Get Region

Get a region by its id.

Parameters:
  • region_id (integer) –

Status Codes:
PUT /regions/{region_id}

Update Region

Update a region.

Parameters:
  • region_id (integer) –

Status Codes:
DELETE /regions/{region_id}

Remove Region

Delete a region.

Parameters:
  • region_id (integer) –

Status Codes:
GET /regions/

Get Region By Dataset

Get all regions of a dataset.

Query Parameters:
  • dataset_id (integer) – (Required)

  • skip (integer) –

  • limit (integer) –

Status Codes:
POST /regions/

Create Region

Create a new region.

Status Codes:
GET /commodities/{commodity_id}

Get Commodity

Get an energy commodity by its id.

Parameters:
  • commodity_id (integer) –

Status Codes:
PUT /commodities/{commodity_id}

Update Commodity

Update an energy commodity.

Parameters:
  • commodity_id (integer) –

Status Codes:
DELETE /commodities/{commodity_id}

Remove Commodity

Delete an energy commodity.

Parameters:
  • commodity_id (integer) –

Status Codes:
GET /commodities/

Get Commodity By Dataset

Get all energy commodities of a dataset.

Query Parameters:
  • dataset_id (integer) – (Required)

  • skip (integer) –

  • limit (integer) –

Status Codes:
POST /commodities/

Create Commodity

Create a new energy commodity.

Status Codes:
GET /conversions/

Get Energy Conversion By Dataset

Get all energy conversions of a dataset.

Query Parameters:
  • dataset_id (integer) – (Required)

  • skip (integer) –

  • limit (integer) –

Status Codes:
POST /conversions/

Create Conversion

Create a new energy conversion.

Status Codes:
GET /sinks/

Get Energy Sink By Dataset

Get all energy sinks of a dataset.

Query Parameters:
  • dataset_id (integer) – (Required)

  • skip (integer) –

  • limit (integer) –

Status Codes:
POST /sinks/

Create Sink

Create a new energy sink.

Status Codes:
GET /sources/

Get Energy Source By Dataset

Get all energy sources of a dataset.

Query Parameters:
  • dataset_id (integer) – (Required)

  • skip (integer) –

  • limit (integer) –

Status Codes:
POST /sources/

Create Source

Create a new energy source.

Status Codes:
GET /storages/

Get Energy Storage By Dataset

Get all energy storages of a dataset.

Query Parameters:
  • dataset_id (integer) – (Required)

  • skip (integer) –

  • limit (integer) –

Status Codes:
POST /storages/

Create Storage

Create a new energy storage.

Status Codes:
GET /transmissions/

Get Energy Transmission By Dataset

Get all energy transmissions of a dataset.

Query Parameters:
  • dataset_id (integer) – (Required)

  • skip (integer) –

  • limit (integer) –

Status Codes:
POST /transmissions/

Create Transmission

Create a new energy transmission.

Status Codes:
GET /transmission-distances/{entry_id}

Get Transmission Distance

Get a TransmissionDistance by its id.

Parameters:
  • entry_id (integer) –

Status Codes:
DELETE /transmission-distances/{entry_id}

Remove Transmission Distance

Remove a TransmissionDistance.

Parameters:
  • entry_id (integer) –

Status Codes:
GET /transmission-distances/dataset/{dataset_id}

Get Transmission Distance By Dataset

Get all TransmissionDistance of a dataset.

Parameters:
  • dataset_id (integer) –

Query Parameters:
  • skip (integer) –

  • limit (integer) –

Status Codes:
GET /transmission-distances/component/{component_id}

Get Transmission Distance By Component

Get all TransmissionDistance of a component.

Parameters:
  • component_id (integer) –

Status Codes:
DELETE /transmission-distances/component/{component_id}

Remove Transmission Distance By Component

Remove all TransmissionDistance of a component.

Parameters:
  • component_id (integer) –

Status Codes:
POST /transmission-distances/

Create Transmission Distance

Create a new TransmissionDistance.

Status Codes:
POST /transmission-distances/component/{component_id}/upload

Upload Transmission Distance

Upload TransmissionDistance of a component.

Parameters:
  • component_id (integer) –

Status Codes:
GET /transmission-distances/component/{component_id}/download

Download Transmission Distance

Download TransmissionDistance of a component.

Parameters:
  • component_id (integer) –

Status Codes:
GET /transmission-losses/{entry_id}

Get Transmission Loss

Get a TransmissionLoss by its id.

Parameters:
  • entry_id (integer) –

Status Codes:
DELETE /transmission-losses/{entry_id}

Remove Transmission Loss

Remove a TransmissionLoss.

Parameters:
  • entry_id (integer) –

Status Codes:
GET /transmission-losses/dataset/{dataset_id}

Get Transmission Loss By Dataset

Get all TransmissionLoss of a dataset.

Parameters:
  • dataset_id (integer) –

Query Parameters:
  • skip (integer) –

  • limit (integer) –

Status Codes:
GET /transmission-losses/component/{component_id}

Get Transmission Loss By Component

Get all TransmissionLoss of a component.

Parameters:
  • component_id (integer) –

Status Codes:
DELETE /transmission-losses/component/{component_id}

Remove Transmission Loss By Component

Remove all TransmissionLoss of a component.

Parameters:
  • component_id (integer) –

Status Codes:
POST /transmission-losses/

Create Transmission Loss

Create a new TransmissionLoss.

Status Codes:
POST /transmission-losses/component/{component_id}/upload

Upload Transmission Loss

Upload TransmissionLoss of a component.

Parameters:
  • component_id (integer) –

Status Codes:
GET /transmission-losses/component/{component_id}/download

Download Transmission Loss

Download TransmissionLoss of a component.

Parameters:
  • component_id (integer) –

Status Codes:
GET /models/{model_id}

Get Model

Get an energy model by its id.

Parameters:
  • model_id (integer) –

Status Codes:
PUT /models/{model_id}

Update Model

Update an energy model.

Parameters:
  • model_id (integer) –

Status Codes:
DELETE /models/{model_id}

Remove Model

Delete an energy model.

Parameters:
  • model_id (integer) –

Status Codes:
GET /models/

Get Energy Model By Dataset

Get all energy models of a dataset.

Query Parameters:
  • dataset_id (integer) – (Required)

  • skip (integer) –

  • limit (integer) –

Status Codes:
POST /models/

Create Model

Create a new energy model.

Status Codes:
GET /models/{model_id}/esm

Validate Model

Create FINE energy system model from model.

Might take a while. And return errors if dataset is not valid.

Parameters:
  • model_id (integer) –

Status Codes:
GET /models/{model_id}/optimize

Optimize Model

Create FINE energy system model from model and optimizes it.

Might take a while. And return errors if dataset is not valid.

Parameters:
  • model_id (integer) –

Status Codes:
GET /models/{model_id}/myopic_optimize

Myopic Optimize Model

Create FINE energy system model from model and optimizes it based on myopic approach.

Parameters:
  • model_id (integer) –

Status Codes:
GET /fix-capacities/{entry_id}

Get Capacity Fix

Get a CapacityFix by its id.

Parameters:
  • entry_id (integer) –

Status Codes:
DELETE /fix-capacities/{entry_id}

Remove Capacity Fix

Remove a CapacityFix.

Parameters:
  • entry_id (integer) –

Status Codes:
GET /fix-capacities/dataset/{dataset_id}

Get Capacity Fix By Dataset

Get all CapacityFix of a dataset.

Parameters:
  • dataset_id (integer) –

Query Parameters:
  • skip (integer) –

  • limit (integer) –

Status Codes:
GET /fix-capacities/component/{component_id}

Get Capacity Fix By Component

Get all CapacityFix of a component.

Parameters:
  • component_id (integer) –

Status Codes:
DELETE /fix-capacities/component/{component_id}

Remove Capacity Fix By Component

Remove all CapacityFix of a component.

Parameters:
  • component_id (integer) –

Status Codes:
POST /fix-capacities/

Create Capacity Fix

Create a new CapacityFix.

Status Codes:
POST /fix-capacities/component/{component_id}/upload

Upload Capacity Fix

Upload CapacityFix of a component.

Parameters:
  • component_id (integer) –

Status Codes:
GET /fix-capacities/component/{component_id}/download

Download Capacity Fix

Download CapacityFix of a component.

Parameters:
  • component_id (integer) –

Status Codes:
GET /max-capacities/{entry_id}

Get Capacity Max

Get a CapacityMax by its id.

Parameters:
  • entry_id (integer) –

Status Codes:
DELETE /max-capacities/{entry_id}

Remove Capacity Max

Remove a CapacityMax.

Parameters:
  • entry_id (integer) –

Status Codes:
GET /max-capacities/dataset/{dataset_id}

Get Capacity Max By Dataset

Get all CapacityMax of a dataset.

Parameters:
  • dataset_id (integer) –

Query Parameters:
  • skip (integer) –

  • limit (integer) –

Status Codes:
GET /max-capacities/component/{component_id}

Get Capacity Max By Component

Get all CapacityMax of a component.

Parameters:
  • component_id (integer) –

Status Codes:
DELETE /max-capacities/component/{component_id}

Remove Capacity Max By Component

Remove all CapacityMax of a component.

Parameters:
  • component_id (integer) –

Status Codes:
POST /max-capacities/

Create Capacity Max

Create a new CapacityMax.

Status Codes:
POST /max-capacities/component/{component_id}/upload

Upload Capacity Max

Upload CapacityMax of a component.

Parameters:
  • component_id (integer) –

Status Codes:
GET /max-capacities/component/{component_id}/download

Download Capacity Max

Download CapacityMax of a component.

Parameters:
  • component_id (integer) –

Status Codes:
GET /min-capacities/{entry_id}

Get Capacity Min

Get a CapacityMin by its id.

Parameters:
  • entry_id (integer) –

Status Codes:
DELETE /min-capacities/{entry_id}

Remove Capacity Min

Remove a CapacityMin.

Parameters:
  • entry_id (integer) –

Status Codes:
GET /min-capacities/dataset/{dataset_id}

Get Capacity Min By Dataset

Get all CapacityMin of a dataset.

Parameters:
  • dataset_id (integer) –

Query Parameters:
  • skip (integer) –

  • limit (integer) –

Status Codes:
GET /min-capacities/component/{component_id}

Get Capacity Min By Component

Get all CapacityMin of a component.

Parameters:
  • component_id (integer) –

Status Codes:
DELETE /min-capacities/component/{component_id}

Remove Capacity Min By Component

Remove all CapacityMin of a component.

Parameters:
  • component_id (integer) –

Status Codes:
POST /min-capacities/

Create Capacity Min

Create a new CapacityMin.

Status Codes:
POST /min-capacities/component/{component_id}/upload

Upload Capacity Min

Upload CapacityMin of a component.

Parameters:
  • component_id (integer) –

Status Codes:
GET /min-capacities/component/{component_id}/download

Download Capacity Min

Download CapacityMin of a component.

Parameters:
  • component_id (integer) –

Status Codes:
GET /fix-operation-rates/{entry_id}

Get Operation Rate Fix

Get a OperationRateFix by its id.

Parameters:
  • entry_id (integer) –

Status Codes:
DELETE /fix-operation-rates/{entry_id}

Remove Operation Rate Fix

Remove a OperationRateFix.

Parameters:
  • entry_id (integer) –

Status Codes:
GET /fix-operation-rates/dataset/{dataset_id}

Get Operation Rate Fix By Dataset

Get all OperationRateFix of a dataset.

Parameters:
  • dataset_id (integer) –

Query Parameters:
  • skip (integer) –

  • limit (integer) –

Status Codes:
GET /fix-operation-rates/component/{component_id}

Get Operation Rate Fix By Component

Get all OperationRateFix of a component.

Parameters:
  • component_id (integer) –

Status Codes:
DELETE /fix-operation-rates/component/{component_id}

Remove Operation Rate Fix By Component

Remove all OperationRateFix of a component.

Parameters:
  • component_id (integer) –

Status Codes:
POST /fix-operation-rates/

Create Operation Rate Fix

Create a new OperationRateFix.

Status Codes:
POST /fix-operation-rates/component/{component_id}/upload

Upload Operation Rate Fix

Upload OperationRateFix of a component.

Parameters:
  • component_id (integer) –

Status Codes:
GET /fix-operation-rates/component/{component_id}/download

Download Operation Rate Fix

Download OperationRateFix of a component.

Parameters:
  • component_id (integer) –

Status Codes:
GET /max-operation-rates/{entry_id}

Get Operation Rate Max

Get a OperationRateMax by its id.

Parameters:
  • entry_id (integer) –

Status Codes:
DELETE /max-operation-rates/{entry_id}

Remove Operation Rate Max

Remove a OperationRateMax.

Parameters:
  • entry_id (integer) –

Status Codes:
GET /max-operation-rates/dataset/{dataset_id}

Get Operation Rate Max By Dataset

Get all OperationRateMax of a dataset.

Parameters:
  • dataset_id (integer) –

Query Parameters:
  • skip (integer) –

  • limit (integer) –

Status Codes:
GET /max-operation-rates/component/{component_id}

Get Operation Rate Max By Component

Get all OperationRateMax of a component.

Parameters:
  • component_id (integer) –

Status Codes:
DELETE /max-operation-rates/component/{component_id}

Remove Operation Rate Max By Component

Remove all OperationRateMax of a component.

Parameters:
  • component_id (integer) –

Status Codes:
POST /max-operation-rates/

Create Operation Rate Max

Create a new OperationRateMax.

Status Codes:
POST /max-operation-rates/component/{component_id}/upload

Upload Operation Rate Max

Upload OperationRateMax of a component.

Parameters:
  • component_id (integer) –

Status Codes:
GET /max-operation-rates/component/{component_id}/download

Download Operation Rate Max

Download OperationRateMax of a component.

Parameters:
  • component_id (integer) –

Status Codes:
GET /max-yearly-full-load-hours/{entry_id}

Get Yearly Full Load Hours Max

Get a YearlyFullLoadHoursMax by its id.

Parameters:
  • entry_id (integer) –

Status Codes:
DELETE /max-yearly-full-load-hours/{entry_id}

Remove Yearly Full Load Hours Max

Remove a YearlyFullLoadHoursMax.

Parameters:
  • entry_id (integer) –

Status Codes:
GET /max-yearly-full-load-hours/dataset/{dataset_id}

Get Yearly Full Load Hours Max By Dataset

Get all YearlyFullLoadHoursMax of a dataset.

Parameters:
  • dataset_id (integer) –

Query Parameters:
  • skip (integer) –

  • limit (integer) –

Status Codes:
GET /max-yearly-full-load-hours/component/{component_id}

Get Yearly Full Load Hours Max By Component

Get all YearlyFullLoadHoursMax of a component.

Parameters:
  • component_id (integer) –

Status Codes:
DELETE /max-yearly-full-load-hours/component/{component_id}

Remove Yearly Full Load Hours Max By Component

Remove all YearlyFullLoadHoursMax of a component.

Parameters:
  • component_id (integer) –

Status Codes:
POST /max-yearly-full-load-hours/

Create Yearly Full Load Hours Max

Create a new YearlyFullLoadHoursMax.

Status Codes:
POST /max-yearly-full-load-hours/component/{component_id}/upload

Upload Yearly Full Load Hours Max

Upload YearlyFullLoadHoursMax of a component.

Parameters:
  • component_id (integer) –

Status Codes:
GET /max-yearly-full-load-hours/component/{component_id}/download

Download Yearly Full Load Hours Max

Download YearlyFullLoadHoursMax of a component.

Parameters:
  • component_id (integer) –

Status Codes:
GET /min-yearly-full-load-hours/{entry_id}

Get Yearly Full Load Hours Min

Get a YearlyFullLoadHoursMin by its id.

Parameters:
  • entry_id (integer) –

Status Codes:
DELETE /min-yearly-full-load-hours/{entry_id}

Remove Yearly Full Load Hours Min

Remove a YearlyFullLoadHoursMin.

Parameters:
  • entry_id (integer) –

Status Codes:
GET /min-yearly-full-load-hours/dataset/{dataset_id}

Get Yearly Full Load Hours Min By Dataset

Get all YearlyFullLoadHoursMin of a dataset.

Parameters:
  • dataset_id (integer) –

Query Parameters:
  • skip (integer) –

  • limit (integer) –

Status Codes:
GET /min-yearly-full-load-hours/component/{component_id}

Get Yearly Full Load Hours Min By Component

Get all YearlyFullLoadHoursMin of a component.

Parameters:
  • component_id (integer) –

Status Codes:
DELETE /min-yearly-full-load-hours/component/{component_id}

Remove Yearly Full Load Hours Min By Component

Remove all YearlyFullLoadHoursMin of a component.

Parameters:
  • component_id (integer) –

Status Codes:
POST /min-yearly-full-load-hours/

Create Yearly Full Load Hours Min

Create a new YearlyFullLoadHoursMin.

Status Codes:
POST /min-yearly-full-load-hours/component/{component_id}/upload

Upload Yearly Full Load Hours Min

Upload YearlyFullLoadHoursMin of a component.

Parameters:
  • component_id (integer) –

Status Codes:
GET /min-yearly-full-load-hours/component/{component_id}/download

Download Yearly Full Load Hours Min

Download YearlyFullLoadHoursMin of a component.

Parameters:
  • component_id (integer) –

Status Codes: