input/output methods

This commit is contained in:
Cedric Verstraeten
2023-12-25 20:55:51 +01:00
parent 698b9c6b54
commit 67064879e4
10 changed files with 861 additions and 271 deletions

View File

@@ -98,12 +98,12 @@ const docTemplate = `{
"operationId": "get-digital-inputs",
"parameters": [
{
"description": "Camera Config",
"name": "cameraConfig",
"description": "OnvifCredentials",
"name": "config",
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/models.OnvifPreset"
"$ref": "#/definitions/models.OnvifCredentials"
}
}
],
@@ -146,6 +146,81 @@ const docTemplate = `{
}
}
},
"/api/camera/onvif/outputs": {
"post": {
"security": [
{
"Bearer": []
}
],
"description": "Will get the relay outputs from the ONVIF device.",
"tags": [
"camera"
],
"summary": "Will get the relay outputs from the ONVIF device.",
"operationId": "get-relay-outputs",
"parameters": [
{
"description": "OnvifCredentials",
"name": "config",
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/models.OnvifCredentials"
}
}
],
"responses": {
"200": {
"description": "OK",
"schema": {
"$ref": "#/definitions/models.APIResponse"
}
}
}
}
},
"/api/camera/onvif/outputs/{output}": {
"post": {
"security": [
{
"Bearer": []
}
],
"description": "Will trigger the relay output from the ONVIF device.",
"tags": [
"camera"
],
"summary": "Will trigger the relay output from the ONVIF device.",
"operationId": "trigger-relay-output",
"parameters": [
{
"description": "OnvifCredentials",
"name": "config",
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/models.OnvifCredentials"
}
},
{
"type": "string",
"description": "Output",
"name": "output",
"in": "path",
"required": true
}
],
"responses": {
"200": {
"description": "OK",
"schema": {
"$ref": "#/definitions/models.APIResponse"
}
}
}
}
},
"/api/camera/onvif/pantilt": {
"post": {
"description": "Panning or/and tilting the camera using a direction (x,y).",