Update api spec

This commit is contained in:
Tobias Reisinger 2026-09-07 16:06:41 +02:00
commit d9afc6b4f2
Signed by: serguzim
GPG key ID: 13AD60C237A28DFE

View file

@ -6,7 +6,7 @@
"url": "https://git.serguzim.me/emgauwa/" "url": "https://git.serguzim.me/emgauwa/"
}, },
"title": "Emgauwa API v1", "title": "Emgauwa API v1",
"version": "0.6.0", "version": "0.7.0",
"description": "Server API to manage an Emgauwa system." "description": "Server API to manage an Emgauwa system."
}, },
"tags": [ "tags": [
@ -94,8 +94,7 @@
"parameters": [ "parameters": [
{ {
"schema": { "schema": {
"type": "string", "$ref": "#/components/schemas/schedule_id"
"format": "uuid"
}, },
"name": "schedule_id", "name": "schedule_id",
"in": "path", "in": "path",
@ -684,7 +683,7 @@
"parameters": [ "parameters": [
{ {
"schema": { "schema": {
"type": "string" "$ref": "#/components/schemas/controller_id"
}, },
"name": "controller_id", "name": "controller_id",
"in": "path", "in": "path",
@ -692,7 +691,7 @@
}, },
{ {
"schema": { "schema": {
"type": "string" "type": "integer"
}, },
"name": "relay_num", "name": "relay_num",
"in": "path", "in": "path",
@ -850,7 +849,8 @@
"parameters": [ "parameters": [
{ {
"schema": { "schema": {
"type": "string" "type": "string",
"format": "uuid"
}, },
"name": "macro_id", "name": "macro_id",
"in": "path", "in": "path",
@ -1065,8 +1065,8 @@
} }
} }
}, },
"operationId": "get-relays", "operationId": "get-version",
"description": "Return a list with all relays." "description": "Return an object with the version"
}, },
"parameters": [] "parameters": []
} }
@ -1282,9 +1282,17 @@
} }
}, },
"schedule_id": { "schedule_id": {
"type": "string",
"title": "schedule_id", "title": "schedule_id",
"format": "uuid", "oneOf": [
{
"type": "string",
"format": "uuid"
},
{
"type": "string",
"pattern": "(on|off)"
}
],
"example": "6bceb29b-7d2e-4af3-a26e-11f514dc5cc1" "example": "6bceb29b-7d2e-4af3-a26e-11f514dc5cc1"
}, },
"macro": { "macro": {