@epilot/customer-portal-client
Version:
API Client for epilot portal API
1,579 lines • 532 kB
JSON
{
"openapi": "3.0.3",
"info": {
"title": "Portal API",
"description": "Backend for epilot portals - End Customer Portal & Installer Portal",
"version": "1.0.0"
},
"tags": [
{
"name": "ECP",
"description": "APIs defined for a portal user"
},
{
"name": "ECP Admin",
"description": "APIs defined for a ECP Admin"
},
{
"name": "Public",
"description": "Public APIs"
},
{
"name": "portal_user_schema",
"x-displayName": "Portal User",
"description": "<SchemaDefinition schemaRef=\"#/components/schemas/PortalUser\" />\n"
}
],
"x-tagGroups": [
{
"name": "APIs",
"tags": [
"ECP",
"ECP Admin",
"Public"
]
},
{
"name": "Schemas",
"tags": [
"portal_user_schema"
]
}
],
"security": [
{
"EpilotAuth": []
},
{
"PortalAuth": []
},
{
"EitherAuth": []
}
],
"paths": {
"/v2/portal/portal": {
"post": {
"operationId": "upsertPortal",
"summary": "upsertPortal",
"description": "Upserts the settings for a portal of an organization.",
"security": [
{
"EpilotAuth": []
}
],
"tags": [
"ECP Admin"
],
"parameters": [
{
"in": "query",
"name": "origin",
"required": true,
"schema": {
"$ref": "#/components/schemas/Origin"
},
"description": "Origin of the portal"
},
{
"in": "query",
"name": "portal_id",
"required": false,
"schema": {
"type": "string"
},
"description": "Portal ID"
}
],
"requestBody": {
"description": "Portal payload",
"required": true,
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/UpsertPortalConfig"
}
}
}
},
"responses": {
"200": {
"description": "Portal updated successfully.",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/PortalConfig"
}
}
}
},
"201": {
"description": "Portal created successfully.",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/PortalConfig"
}
}
}
},
"400": {
"$ref": "#/components/responses/InvalidRequest"
},
"401": {
"$ref": "#/components/responses/Unauthorized"
},
"403": {
"$ref": "#/components/responses/Forbidden"
},
"500": {
"$ref": "#/components/responses/InternalServerError"
}
}
}
},
"/v2/portal/public/user": {
"post": {
"operationId": "createUser",
"summary": "createUser",
"description": "Registers a portal user",
"deprecated": true,
"security": [],
"tags": [
"Public"
],
"parameters": [
{
"in": "query",
"name": "origin",
"required": true,
"schema": {
"$ref": "#/components/schemas/Origin"
},
"description": "Origin of the portal"
}
],
"requestBody": {
"description": "Portal user payload",
"required": true,
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/CreateUserRequest"
}
}
}
},
"responses": {
"201": {
"description": "User created successfully.",
"content": {
"application/json": {
"schema": {
"type": "object",
"required": [
"message",
"response"
],
"properties": {
"message": {
"type": "string",
"enum": [
"User created successfully"
]
}
}
}
}
}
},
"400": {
"$ref": "#/components/responses/InvalidRequest"
},
"500": {
"$ref": "#/components/responses/InternalServerError"
}
}
}
},
"/v3/portal/public/user": {
"post": {
"operationId": "createUserV3",
"summary": "createUserV3",
"description": "Registers a portal user.\nSupports two identification methods:\n1. Using portal_id\n2. Using domain\n",
"security": [],
"tags": [
"Public"
],
"parameters": [
{
"in": "query",
"name": "portal_id",
"required": false,
"schema": {
"$ref": "#/components/schemas/PortalId"
},
"description": "Portal ID (required if domain is not provided)"
},
{
"in": "query",
"name": "domain",
"required": false,
"schema": {
"type": "string"
},
"description": "Portal domain for identification (alternative to portal_id)"
}
],
"requestBody": {
"description": "Portal user payload",
"required": true,
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/CreateUserRequest"
}
}
}
},
"responses": {
"201": {
"description": "User created successfully.",
"content": {
"application/json": {
"schema": {
"type": "object",
"required": [
"message",
"response"
],
"properties": {
"message": {
"type": "string",
"enum": [
"User created successfully"
]
}
}
}
}
}
},
"400": {
"$ref": "#/components/responses/InvalidRequest"
},
"500": {
"$ref": "#/components/responses/InternalServerError"
}
}
}
},
"/v2/portal/token/validate": {
"post": {
"operationId": "validateToken",
"summary": "validateToken",
"description": "Validates Portal Token is valid. Pass the token via Authorization Header.",
"tags": [
"ECP"
],
"security": [
{
"PortalAuth": []
}
],
"responses": {
"204": {
"description": "Tokens is valid for the given organization."
},
"401": {
"$ref": "#/components/responses/Unauthorized"
},
"500": {
"$ref": "#/components/responses/InternalServerError"
}
}
}
},
"/v2/portal/token/revoke": {
"post": {
"operationId": "revokeToken",
"summary": "revokeToken",
"description": "Revokes all of the access tokens for the given Refresh Token.",
"tags": [
"ECP"
],
"security": [
{
"PortalAuth": []
}
],
"requestBody": {
"description": "Token payload",
"required": true,
"content": {
"application/json": {
"schema": {
"type": "object",
"required": [
"refresh_token"
],
"properties": {
"refresh_token": {
"type": "string",
"description": "Refresh Token to be revoked",
"example": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ.SflKxwRJSMeKKF2QT4fwpMeJf36POk6yJV_adQssw5c"
}
}
}
}
}
},
"responses": {
"200": {
"description": "Access Tokens revoked successfully for the given Refresh Token.",
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {
"message": {
"type": "string",
"enum": [
"Token revoked successfully"
]
}
}
}
}
}
},
"401": {
"$ref": "#/components/responses/Unauthorized"
},
"500": {
"$ref": "#/components/responses/InternalServerError"
}
}
}
},
"/v2/portal/public/config": {
"get": {
"operationId": "getPortalConfigByDomain",
"summary": "getPortalConfigByDomain",
"description": "Retrieves the portal configuration by domain.",
"tags": [
"Public"
],
"security": [],
"parameters": [
{
"in": "query",
"name": "domain",
"required": true,
"schema": {
"type": "string",
"example": "example.com",
"description": "Domain of the portal"
}
}
],
"responses": {
"200": {
"description": "Portal config retrieved successfully.",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/PortalConfig"
}
}
}
},
"500": {
"$ref": "#/components/responses/InternalServerError"
}
}
}
},
"/v2/portal/config": {
"get": {
"operationId": "getPortalConfig",
"summary": "getPortalConfig",
"description": "Retrieves the portal configuration.",
"tags": [
"ECP Admin",
"ECP"
],
"parameters": [
{
"in": "query",
"name": "origin",
"required": false,
"schema": {
"$ref": "#/components/schemas/Origin"
},
"description": "Origin of the portal"
}
],
"security": [
{
"EitherAuth": []
}
],
"responses": {
"200": {
"description": "Portal config retrieved successfully.",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/PortalConfig"
}
}
}
},
"401": {
"$ref": "#/components/responses/Unauthorized"
},
"403": {
"$ref": "#/components/responses/Forbidden"
},
"500": {
"$ref": "#/components/responses/InternalServerError"
}
}
},
"delete": {
"operationId": "deletePortal",
"summary": "deletePortal",
"description": "Deletes the portal.",
"tags": [
"ECP Admin"
],
"parameters": [
{
"in": "query",
"name": "origin",
"required": true,
"schema": {
"$ref": "#/components/schemas/Origin"
},
"description": "Origin of the portal"
}
],
"security": [
{
"EpilotAuth": []
}
],
"responses": {
"204": {
"description": "Portal deleted successfully."
},
"401": {
"$ref": "#/components/responses/Unauthorized"
},
"403": {
"$ref": "#/components/responses/Forbidden"
},
"500": {
"$ref": "#/components/responses/InternalServerError"
}
}
}
},
"/v2/portal/extensions": {
"get": {
"operationId": "getPortalExtensions",
"summary": "getPortalExtensions",
"description": "Retrieves the installed portal extensions.",
"tags": [
"ECP Admin"
],
"parameters": [
{
"in": "query",
"name": "origin",
"required": false,
"schema": {
"$ref": "#/components/schemas/Origin"
},
"description": "Origin of the portal"
}
],
"security": [
{
"EpilotAuth": []
}
],
"responses": {
"200": {
"description": "Portal extensions retrieved successfully.",
"content": {
"application/json": {
"schema": {
"type": "array",
"items": {
"$ref": "#/components/schemas/Extension"
}
}
}
}
},
"401": {
"$ref": "#/components/responses/Unauthorized"
},
"403": {
"$ref": "#/components/responses/Forbidden"
},
"500": {
"$ref": "#/components/responses/InternalServerError"
}
}
}
},
"/v2/portal/public/extensions": {
"get": {
"operationId": "getPublicPortalExtensionDetails",
"summary": "getPublicPortalExtensionDetails",
"description": "Get public extension details shown to end customers and configuring users.",
"tags": [
"Public"
],
"security": [],
"parameters": [
{
"in": "query",
"name": "org_id",
"required": true,
"schema": {
"type": "string",
"example": 12324,
"description": "Organization ID"
}
},
{
"in": "query",
"name": "origin",
"required": true,
"schema": {
"$ref": "#/components/schemas/Origin"
},
"description": "Origin of the portal"
}
],
"responses": {
"200": {
"description": "Public details of extensions.",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/PublicExtensionCapabilities"
}
}
}
},
"401": {
"$ref": "#/components/responses/Unauthorized"
},
"403": {
"$ref": "#/components/responses/Forbidden"
},
"500": {
"$ref": "#/components/responses/InternalServerError"
}
}
}
},
"/v3/portal/extensions": {
"get": {
"operationId": "getPortalExtensionsV3",
"summary": "getPortalExtensionsV3",
"description": "Retrieves the installed portal extensions.",
"tags": [
"ECP Admin"
],
"parameters": [
{
"in": "query",
"name": "portal_id",
"required": true,
"schema": {
"$ref": "#/components/schemas/PortalId"
},
"description": "Portal ID"
}
],
"security": [
{
"EpilotAuth": []
}
],
"responses": {
"200": {
"description": "Portal extensions retrieved successfully.",
"content": {
"application/json": {
"schema": {
"type": "array",
"items": {
"$ref": "#/components/schemas/Extension"
}
}
}
}
},
"401": {
"$ref": "#/components/responses/Unauthorized"
},
"403": {
"$ref": "#/components/responses/Forbidden"
},
"500": {
"$ref": "#/components/responses/InternalServerError"
}
}
}
},
"/v3/portal/public/extensions": {
"get": {
"operationId": "getPublicPortalExtensionDetailsV3",
"summary": "getPublicPortalExtensionDetailsV3",
"description": "Get public extension details shown to end customers and configuring users.\nSupports two identification methods:\n1. Using org_id + portal_id\n2. Using domain\n",
"tags": [
"Public"
],
"security": [],
"parameters": [
{
"in": "query",
"name": "org_id",
"required": false,
"schema": {
"type": "string",
"example": 12324
},
"description": "Organization ID (required if domain is not provided)"
},
{
"in": "query",
"name": "portal_id",
"required": false,
"schema": {
"$ref": "#/components/schemas/PortalId"
},
"description": "Portal ID (required if domain is not provided)"
},
{
"in": "query",
"name": "domain",
"required": false,
"schema": {
"type": "string"
},
"description": "Portal domain for identification (alternative to org_id + portal_id)"
}
],
"responses": {
"200": {
"description": "Public details of extensions.",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/PublicExtensionCapabilities"
}
}
}
},
"401": {
"$ref": "#/components/responses/Unauthorized"
},
"403": {
"$ref": "#/components/responses/Forbidden"
},
"500": {
"$ref": "#/components/responses/InternalServerError"
}
}
}
},
"/v2/portal/consumption": {
"get": {
"operationId": "getConsumption",
"summary": "Get Consumption",
"description": "Get energy consumption data between a given time period.",
"tags": [
"ECP"
],
"security": [
{
"PortalAuth": []
}
],
"parameters": [
{
"in": "query",
"name": "app_id",
"schema": {
"type": "string"
},
"required": false,
"description": "App ID for consumption data."
},
{
"in": "query",
"name": "extensionId",
"schema": {
"type": "string"
},
"required": true,
"description": "Extension ID for consumption data."
},
{
"in": "query",
"name": "hookId",
"schema": {
"type": "string"
},
"required": false,
"description": "Optional Hook ID. If omitted, the only matching hook on the extension is used; if the extension has multiple hooks of the relevant type, this becomes required."
},
{
"in": "query",
"name": "meter_id",
"schema": {
"type": "string"
},
"required": false,
"deprecated": true,
"description": "Meter ID for consumption data. Deprecated - use context_entities instead."
},
{
"in": "query",
"name": "from",
"schema": {
"type": "string",
"format": "date-time"
},
"required": true,
"description": "Start date for consumption data (ISO 8601 format)."
},
{
"in": "query",
"name": "to",
"schema": {
"type": "string",
"format": "date-time"
},
"required": true,
"description": "End date for consumption data (ISO 8601 format)."
},
{
"in": "query",
"name": "interval",
"schema": {
"type": "string",
"enum": [
"PT15M",
"PT1H",
"P1D",
"P1M"
]
},
"required": true,
"description": "Interval between consumption data points (e.g., PT15M for 15 minutes, PT1H for hourly). Not all intervals have to be supported."
},
{
"in": "query",
"name": "context_entities",
"required": false,
"description": "Additional entities to include in the context for variable interpolation in the hook.",
"schema": {
"$ref": "#/components/schemas/ContextEntities"
}
}
],
"responses": {
"200": {
"description": "Consumption data returned successfully.",
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {
"consumptions": {
"type": "array",
"items": {
"type": "object",
"properties": {
"timestamp": {
"type": "string",
"format": "date-time",
"description": "ISO 8601 timestamp of the consumption record."
},
"value": {
"type": "number",
"description": "The consumption value."
},
"type": {
"type": "string",
"description": "Optional type of the consumption, such as 'nt' (night time) and 'ht' (high time) or 'feed-in' and 'feed-out'. Can be any string.",
"example": "nt"
},
"unit": {
"type": "string",
"description": "Optional unit of the consumption value. Defaults to unit present on the relevant Meter Counter.",
"example": "kWh"
}
},
"required": [
"value",
"timestamp"
]
}
}
}
}
}
}
},
"401": {
"$ref": "#/components/responses/Unauthorized"
},
"403": {
"$ref": "#/components/responses/Forbidden"
},
"404": {
"$ref": "#/components/responses/NotFound"
},
"500": {
"$ref": "#/components/responses/InternalServerError"
}
}
}
},
"/v2/portal/visualization:export": {
"post": {
"operationId": "prepareVisualizationExport",
"summary": "Prepare Visualization Export",
"description": "Asks an installed App to prepare a downloadable export of a visualization (consumption chart, dynamic tariff chart, etc.). The export is produced by the third-party App via a configured portal extension hook of type `dataExport` — this endpoint does not generate the file itself, it forwards the request to the configured hook and returns the descriptor the App provides (typically a `download_url`).\n",
"tags": [
"ECP"
],
"security": [
{
"PortalAuth": []
}
],
"requestBody": {
"required": true,
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {
"app_id": {
"type": "string",
"description": "App ID providing the dataExport hook."
},
"extension_id": {
"type": "string",
"description": "Extension ID providing the dataExport hook."
},
"hook_id": {
"type": "string",
"description": "Optional Hook ID. If omitted, the only `dataExport` hook on the extension is used; if the extension has multiple `dataExport` hooks, this becomes required."
},
"from": {
"type": "string",
"format": "date-time",
"description": "Optional start date for the export window (ISO 8601 format)."
},
"to": {
"type": "string",
"format": "date-time",
"description": "Optional end date for the export window (ISO 8601 format)."
},
"context_entities": {
"$ref": "#/components/schemas/ContextEntities"
}
},
"required": [
"app_id",
"extension_id"
],
"additionalProperties": false
}
}
}
},
"responses": {
"200": {
"description": "Export descriptor returned by the App.",
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {
"download_url": {
"type": "string",
"description": "URL the client can use to download the exported file. May be a pre-signed or short-lived URL."
},
"filename": {
"type": "string",
"description": "Suggested filename for the exported file."
},
"content_type": {
"type": "string",
"description": "MIME type of the exported file.",
"example": "text/csv"
},
"expires_at": {
"type": "string",
"format": "date-time",
"description": "Optional expiration timestamp for the download URL."
}
},
"required": [
"download_url"
]
}
}
}
},
"401": {
"$ref": "#/components/responses/Unauthorized"
},
"403": {
"$ref": "#/components/responses/Forbidden"
},
"404": {
"$ref": "#/components/responses/NotFound"
},
"500": {
"$ref": "#/components/responses/InternalServerError"
}
}
}
},
"/v2/portal/visualization/metadata": {
"get": {
"operationId": "getVisualizationMetadata",
"summary": "Get Visualization Metadata",
"description": "Returns runtime metadata describing how a visualization (consumption / price / cost chart) should be rendered for a given portal context (meter, contract, etc). Resolves the extension's `visualizationMetadata` hook implicitly from `app_id` + `extensionId` and invokes it. Supplies the response as a structured payload that the portal uses to configure type/aggregation options, supported intervals, and the available data range.\n",
"tags": [
"ECP"
],
"security": [
{
"PortalAuth": []
}
],
"parameters": [
{
"in": "query",
"name": "app_id",
"schema": {
"type": "string"
},
"required": true,
"description": "App ID providing the visualizationMetadata hook."
},
{
"in": "query",
"name": "extensionId",
"schema": {
"type": "string"
},
"required": true,
"description": "Extension ID providing the visualizationMetadata hook."
},
{
"in": "query",
"name": "context_entities",
"required": false,
"description": "Entities to include in the context for variable interpolation in the hook (typically the meter and any other entities that scope the visualization).",
"schema": {
"$ref": "#/components/schemas/ContextEntities"
}
}
],
"responses": {
"200": {
"description": "Visualization metadata returned successfully.",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/VisualizationMetadata"
}
}
}
},
"401": {
"$ref": "#/components/responses/Unauthorized"
},
"403": {
"$ref": "#/components/responses/Forbidden"
},
"404": {
"$ref": "#/components/responses/NotFound"
},
"500": {
"$ref": "#/components/responses/InternalServerError"
}
}
}
},
"/v2/portal/costs": {
"get": {
"operationId": "getCosts",
"summary": "Get Costs",
"description": "Get energy cost data between a given time period.",
"tags": [
"ECP"
],
"security": [
{
"PortalAuth": []
}
],
"parameters": [
{
"in": "query",
"name": "app_id",
"schema": {
"type": "string"
},
"required": false,
"description": "App ID for consumption data."
},
{
"in": "query",
"name": "extensionId",
"schema": {
"type": "string"
},
"required": true,
"description": "Extension ID for cost data."
},
{
"in": "query",
"name": "hookId",
"schema": {
"type": "string"
},
"required": false,
"description": "Optional Hook ID. If omitted, the only matching hook on the extension is used; if the extension has multiple hooks of the relevant type, this becomes required."
},
{
"in": "query",
"name": "meter_id",
"schema": {
"type": "string"
},
"required": false,
"deprecated": true,
"description": "Meter ID for cost data. Deprecated - use context_entities instead."
},
{
"in": "query",
"name": "from",
"schema": {
"type": "string",
"format": "date-time"
},
"required": true,
"description": "Start date for cost data (ISO 8601 format)."
},
{
"in": "query",
"name": "to",
"schema": {
"type": "string",
"format": "date-time"
},
"required": true,
"description": "End date for cost data (ISO 8601 format)."
},
{
"in": "query",
"name": "interval",
"schema": {
"type": "string",
"enum": [
"PT15M",
"PT1H",
"P1D",
"P1M"
]
},
"required": true,
"description": "Interval between cost data points (e.g., PT15M for 15 minutes, PT1H for hourly). Not all intervals have to be supported."
},
{
"in": "query",
"name": "context_entities",
"required": false,
"description": "Additional entities to include in the context for variable interpolation in the hook.",
"schema": {
"$ref": "#/components/schemas/ContextEntities"
}
}
],
"responses": {
"200": {
"description": "Cost data returned successfully.",
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {
"costs": {
"type": "array",
"items": {
"type": "object",
"properties": {
"timestamp": {
"type": "string",
"format": "date-time",
"description": "ISO 8601 timestamp of the cost record."
},
"unit_amount": {
"type": "integer",
"description": "Cost in cents, e.g. 1234 for 12,34 €.",
"example": 1234
},
"unit_amount_currency": {
"type": "string",
"description": "ISO 4217:2015 currency.",
"example": "EUR"
},
"unit_amount_decimal": {
"type": "string",
"description": "Cost in decimal format, e.g. \"12.34\".",
"example": "12.34"
},
"tax_behavior": {
"type": "string",
"description": "Is the tax (typically Value Added Tax) included in the amounts. Typically should NOT be included - exclusive of tax.",
"enum": [
"inclusive",
"exclusive"
],
"example": "exclusive"
},
"tax_rate": {
"type": "integer",
"description": "Tax rate in percent, e.g. 19 for 19%.",
"example": 19
}
},
"required": [
"timestamp",
"unit_amount",
"unit_amount_currency",
"unit_amount_decimal",
"tax_behavior",
"tax_rate"
]
}
}
}
}
}
}
},
"401": {
"$ref": "#/components/responses/Unauthorized"
},
"403": {
"$ref": "#/components/responses/Forbidden"
},
"404": {
"$ref": "#/components/responses/NotFound"
},
"500": {
"$ref": "#/components/responses/InternalServerError"
}
}
}
},
"/v2/portal/prices": {
"get": {
"operationId": "getPrices",
"summary": "Get Prices",
"description": "Get energy prices data between a given time period.",
"tags": [
"ECP"
],
"security": [
{
"PortalAuth": []
}
],
"parameters": [
{
"in": "query",
"name": "app_id",
"schema": {
"type": "string"
},
"required": false,
"description": "App ID for consumption data."
},
{
"in": "query",
"name": "extensionId",
"schema": {
"type": "string"
},
"required": true,
"description": "Extension ID for price data."
},
{
"in": "query",
"name": "hookId",
"schema": {
"type": "string"
},
"required": false,
"description": "Optional Hook ID. If omitted, the only matching hook on the extension is used; if the extension has multiple hooks of the relevant type, this becomes required."
},
{
"in": "query",
"name": "meter_id",
"schema": {
"type": "string"
},
"required": false,
"deprecated": true,
"description": "Meter ID for price data. Deprecated - use context_entities instead."
},
{
"in": "query",
"name": "from",
"schema": {
"type": "string",
"format": "date-time"
},
"required": true,
"description": "Start date for price data (ISO 8601 format)."
},
{
"in": "query",
"name": "to",
"schema": {
"type": "string",
"format": "date-time"
},
"required": true,
"description": "End date for price data (ISO 8601 format)."
},
{
"in": "query",
"name": "interval",
"schema": {
"type": "string",
"enum": [
"PT15M",
"PT1H",
"P1D",
"P1M"
]
},
"required": true,
"description": "Interval between price data points (e.g., PT15M for 15 minutes, PT1H for hourly). Not all intervals have to be supported."
},
{
"in": "query",
"name": "context_entities",
"required": false,
"description": "Additional entities to include in the context for variable interpolation in the hook.",
"schema": {
"$ref": "#/components/schemas/ContextEntities"
}
}
],
"responses": {
"200": {
"description": "Price data returned successfully.",
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {
"prices": {
"type": "array",
"items": {
"type": "object",
"properties": {
"timestamp": {
"type": "string",
"format": "date-time",
"description": "ISO 8601 timestamp of the price record."
},
"unit_amount": {
"type": "integer",
"description": "Cost in cents, e.g. 1234 for 12,34 €.",
"example": 1234
},
"unit_amount_currency": {
"type": "string",
"description": "ISO 4217:2015 currency.",
"example": "EUR"
},
"unit_amount_decimal": {
"type": "string",
"description": "Cost in decimal format, e.g. \"12.34\".",
"example": "12.34"
},
"components": {
"type": "object",
"description": "Optional price components.",
"properties": {
"auction_price_amount": {
"type": "integer",
"description": "Market price in cents, e.g. 1000 for 10,00 €.",
"example": 1000
},
"auction_price_amount_decimal": {
"type": "string",
"description": "Market price in decimal format, e.g. \"10.00\".",
"example": "10.00"
},
"taxes_levies_amount": {
"type": "integer",
"description": "Taxes/Levies other than tax specified on the price level in cents, e.g. 50 for 00,50 €.",
"example": 50
},
"taxes_levies_amount_decimal": {
"type": "string",
"description": "Taxes/Levies other than tax specified on the price level in decimal format, e.g. \"0.50\".",
"example": "0.50"
},
"source_fee_amount": {
"type": "integer",
"description": "Fee associated with the source, e.g. Green Energy Certificate fee in cents, e.g. 50 for 00,50 €.",
"example": 50
},
"source_fee_amount_decimal": {
"type": "string",
"description": "Fee associated with the source, e.g. Green Energy Certificate fee in decimal format, e.g. \"0.50\".",
"example": "0.50"
},
"grid_fee_amount": {
"type": "integer",
"description": "Fee associated with the transmission/distribution in cents, e.g. 100 for 1,00 €.",
"example": 100
},
"grid_fee_amount_decimal": {
"type": "string",
"description": "Fee associated with the transmission/distribution in decimal format, e.g. \"1.00\".",
"example": "1.00"
},
"margin_amount": {
"type": "integer",
"description": "Margin in cents, e.g. 34 for 0,34 €.",
"example": 34
},
"margin_amount_decimal": {
"type": "string",
"description": "Margin in decimal format, e.g. \"0.34\".",
"example": "0.34"
}
}
},
"tax_behavior": {
"type": "string",
"description": "Is the tax (typically Value Added Tax) included in the amounts. Typically should NOT be included - exclusive of tax.",
"enum": [
"inclusive",
"exclusive"
],
"example": "exclusive"
},
"tax_rate": {
"type": "integer",
"description": "Tax rate in percent, e.g. 19 for 19%.",
"example": 19
}
},
"required": [
"timestamp",
"unit_amount",
"unit_amount_currency",
"unit_amount_decimal",
"tax_behavior",
"tax_rate"
]
}
}
}
}
}
}
},
"401": {
"$ref": "#/components/responses/Unauthorized"
},
"403": {
"$ref": "#/components/responses/Forbidden"
},
"404": {
"$ref": "#/components/responses/NotFound"
},
"500": {
"$ref": "#/components/responses/InternalServerError"
}
}
}
},
"/v2/portal/external-links": {
"get": {
"operationId": "getExternalLinks",
"summary": "getExternalLinks",
"description": "Retrieves the portal configuration external links.",
"tags": [
"ECP Admin",
"ECP"
],
"parameters": [
{
"in": "query",
"name": "origin",
"required": false,
"schema": {
"$ref": "#/components/schemas/Origin"
},
"description": "Origin of the portal"
},
{
"in": "query",
"name": "contactId",
"required": false,
"schema": {
"$ref": "#/components/schemas/EntityId"
},
"description": "Contact ID of the user"
}
],
"security": [
{
"EitherAuth": []
}
],
"responses": {
"200": {
"description": "Portal config links retrieved successfully.",
"content": {
"application/json": {
"schema": {
"type": "array",
"items": {
"$ref": "#/components/schemas/ExternalLink"
}
}
}
}
},
"401": {
"$ref": "#/components/responses/Unauthorized"
},
"403": {
"$ref": "#/components/responses/Forbidden"
},
"500": {
"$ref": "#/components/responses/InternalServerError"
}
}
}
},
"/v2/portal/resolve:external-link/{id}": {
"get": {
"operationId": "getResolvedExternalLink",
"summary": "getResolvedExternalLink",
"deprecated": true,
"description": "Retrieves a resolved portal external link. Use /v2/portal/resolve:seamless-link/{id} instead.",
"tags": [
"ECP Admin",
"ECP"
],
"parameters": [
{
"in": "path",
"name": "id",
"required": true,
"schema": {
"$ref": "#/components/schemas/EntityId"
},
"description": "ID of the External Link"
},
{
"in": "query",
"name": "origin",
"required": false,
"schema": {
"$ref": "#/components/schemas/Origin"
},
"description": "Origin of the portal"
},
{
"in": "query",
"name": "contactId",
"required": false,
"schema": {
"$ref": "#/components/schemas/EntityId"
},
"description": "Contact ID of the user"
}
],
"security": [
{
"EitherAuth": []
}
],
"responses": {
"200": {
"description": "Resolved portal config link retrieved successfully.",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/ExternalLink"
}
}
}
},
"401": {
"$ref": "#/components/responses/Unauthorized"
},
"403": {
"$ref": "#/components/responses/Forbidden"
},
"500": {
"$ref": "#/components/responses/InternalServerError"
}
}
}
},
"/v3/portal/external-links": {
"get": {
"operationId": "getExternalLinksV3",
"summary": "getExternalLinksV3",
"description": "Retrieves the portal configuration external links.",
"tags": [
"ECP Admin",
"ECP"
],
"parameters": [
{
"in": "query",
"name": "portal_id",
"required": false,
"schema": {
"$ref": "#/components/schemas/PortalId"
},
"description": "PortalId of the portal"
},
{
"in": "query",
"name": "contactId",
"required": false,
"sc