From 652b87055eae0d265563caf08162b5ecd5cdc146 Mon Sep 17 00:00:00 2001 From: andig Date: Sat, 25 Oct 2025 10:31:11 +0200 Subject: [PATCH] chore: add missing api endpoints (#24721) --- server/mcp/openapi.json | 78 +++++++++++++++++++++++++++++++++++++++++ server/mcp/openapi.md | 68 +++++++++++++++++++++++++++++++++++ server/openapi.yaml | 47 +++++++++++++++++++++++++ 3 files changed, 193 insertions(+) diff --git a/server/mcp/openapi.json b/server/mcp/openapi.json index c6a4cbf03..1d664bddc 100644 --- a/server/mcp/openapi.json +++ b/server/mcp/openapi.json @@ -1594,6 +1594,49 @@ ] } }, + "/loadpoints/{id}/smartfeedinprioritylimit": { + "delete": { + "description": "Delete limit for feed-in priority optimization.", + "operationId": "deleteLoadpointSmartFeedInPriorityLimit", + "parameters": [ + { + "$ref": "#/components/parameters/id" + } + ], + "responses": { + "200": { + "$ref": "#/components/responses/NullResult" + } + }, + "summary": "Delete smart feed-in priority limit", + "tags": [ + "loadpoints" + ] + } + }, + "/loadpoints/{id}/smartfeedinprioritylimit/{cost}": { + "post": { + "description": "Set limit for feed-in priority optimization.", + "operationId": "setLoadpointSmartFeedInPriorityLimit", + "parameters": [ + { + "$ref": "#/components/parameters/id" + }, + { + "$ref": "#/components/parameters/costLimit" + } + ], + "responses": { + "200": { + "$ref": "#/components/responses/NumberResult" + } + }, + "summary": "Set smart feed-in priority limit", + "tags": [ + "loadpoints" + ] + } + }, "/loadpoints/{id}/vehicle": { "delete": { "description": "Remove vehicle from loadpoint. Connected vehicle is treated as guest vehicle.", @@ -1924,6 +1967,41 @@ ] } }, + "/smartfeedinprioritylimit": { + "delete": { + "description": "Convenience method to remove limit for all loadpoints at once. Value is applied to each individual loadpoint.", + "operationId": "removeGlobalSmartFeedInPriorityLimit", + "responses": { + "200": { + "$ref": "#/components/responses/NullResult" + } + }, + "summary": "Remove smart feed-in priority limit for all loadpoints.", + "tags": [ + "general" + ] + } + }, + "/smartfeedinprioritylimit/{cost}": { + "post": { + "description": "Convenience method to set smart feed-in priority limit for all loadpoints at once. Value is applied to each individual loadpoint.", + "operationId": "setGlobalSmartFeedInPriorityLimit", + "parameters": [ + { + "$ref": "#/components/parameters/costLimit" + } + ], + "responses": { + "200": { + "$ref": "#/components/responses/NumberResult" + } + }, + "summary": "Set smart feed-in priority limit for all loadpoints", + "tags": [ + "general" + ] + } + }, "/state": { "get": { "description": "Returns the complete state of the system. This structure is used by the UI. It can be filtered by JQ to only return a subset of the data.", diff --git a/server/mcp/openapi.md b/server/mcp/openapi.md index b96cf8ea7..c79596473 100644 --- a/server/mcp/openapi.md +++ b/server/mcp/openapi.md @@ -242,6 +242,12 @@ Convenience method to remove limit for all loadpoints at once. Value is applied **Tags:** general +## removeGlobalSmartFeedInPriorityLimit + +Convenience method to remove limit for all loadpoints at once. Value is applied to each individual loadpoint. + +**Tags:** general + ## setGlobalSmartCostLimit Convenience method to set smart charging cost limit for all loadpoints at once. Value is applied to each individual loadpoint. @@ -262,6 +268,26 @@ call setGlobalSmartCostLimit { } ``` +## setGlobalSmartFeedInPriorityLimit + +Convenience method to set smart feed-in priority limit for all loadpoints at once. Value is applied to each individual loadpoint. + +**Tags:** general + +**Arguments:** + +| Name | Type | Description | +|------|------|-------------| +| cost | number | Cost limit in configured currency (default EUR) or CO2 limit in g/kWh | + +**Example call:** + +```json +call setGlobalSmartFeedInPriorityLimit { + "cost": 123.45 +} +``` + ## assignLoadpointVehicle Assigns vehicle to loadpoint. @@ -324,6 +350,26 @@ call deleteLoadpointSmartCostLimit { } ``` +## deleteLoadpointSmartFeedInPriorityLimit + +Delete limit for feed-in priority optimization. + +**Tags:** loadpoints + +**Arguments:** + +| Name | Type | Description | +|------|------|-------------| +| id | integer | Loadpoint index starting at 1 | + +**Example call:** + +```json +call deleteLoadpointSmartFeedInPriorityLimit { + "id": 123 +} +``` + ## getLoadpointPlan Returns the current charging plan for this loadpoint. @@ -728,6 +774,28 @@ call setLoadpointSmartCostLimit { } ``` +## setLoadpointSmartFeedInPriorityLimit + +Set limit for feed-in priority optimization. + +**Tags:** loadpoints + +**Arguments:** + +| Name | Type | Description | +|------|------|-------------| +| cost | number | Cost limit in configured currency (default EUR) or CO2 limit in g/kWh | +| id | integer | Loadpoint index starting at 1 | + +**Example call:** + +```json +call setLoadpointSmartFeedInPriorityLimit { + "cost": 123.45, + "id": 123 +} +``` + ## setLoadpointSocLimit Updates the SoC limit of the loadpoint. Requires a connected vehicle with known SoC. Limit is maintained across charging sessions. diff --git a/server/openapi.yaml b/server/openapi.yaml index fb1605d0c..c5d9ce738 100644 --- a/server/openapi.yaml +++ b/server/openapi.yaml @@ -539,6 +539,31 @@ paths: responses: 200: $ref: "#/components/responses/NumberResult" + /loadpoints/{id}/smartfeedinprioritylimit: + delete: + operationId: deleteLoadpointSmartFeedInPriorityLimit + summary: Delete smart feed-in priority limit + description: "Delete limit for feed-in priority optimization." + tags: + - loadpoints + parameters: + - $ref: "#/components/parameters/id" + responses: + 200: + $ref: "#/components/responses/NullResult" + /loadpoints/{id}/smartfeedinprioritylimit/{cost}: + post: + operationId: setLoadpointSmartFeedInPriorityLimit + summary: Set smart feed-in priority limit + description: "Set limit for feed-in priority optimization." + tags: + - loadpoints + parameters: + - $ref: "#/components/parameters/id" + - $ref: "#/components/parameters/costLimit" + responses: + 200: + $ref: "#/components/responses/NumberResult" /loadpoints/{id}/vehicle: delete: operationId: removeLoadpointVehicle @@ -619,6 +644,28 @@ paths: responses: 200: $ref: "#/components/responses/NumberResult" + /smartfeedinprioritylimit: + delete: + operationId: removeGlobalSmartFeedInPriorityLimit + summary: Remove smart feed-in priority limit for all loadpoints. + description: "Convenience method to remove limit for all loadpoints at once. Value is applied to each individual loadpoint." + tags: + - general + responses: + 200: + $ref: "#/components/responses/NullResult" + /smartfeedinprioritylimit/{cost}: + post: + operationId: setGlobalSmartFeedInPriorityLimit + summary: Set smart feed-in priority limit for all loadpoints + description: "Convenience method to set smart feed-in priority limit for all loadpoints at once. Value is applied to each individual loadpoint." + tags: + - general + parameters: + - $ref: "#/components/parameters/costLimit" + responses: + 200: + $ref: "#/components/responses/NumberResult" /session/{id}: parameters: - $ref: "#/components/parameters/id"