Video Stream Settings API

{ "swagger": "2.0", "info": { "version": "2.2.0", "title": "Eagle Eye CameraManager API", "description": "RESTful API for the Cameramanager platform." }, "host": "rest.cameramanager.com", "schemes": [ "http", "https" ], "basePath": "/rest/v2.2", "produces": [ "application/json" ], "definitions": { "Error": { "type": "object", "description": "Generic error response, modelled after RFC 7807.", "properties": { "code": { "type": "integer", "description": "Error code within the system." }, "title": { "type": "string", "description": "This title is not meant to be shown to users and is not guaranteed to stay the same. Please use the code to parse the error." }, "detail": { "type": "string", "description": "Error details, to help developers detect what went wrong." } }, "required": [ "code", "title" ] }, "OAuth2Error": { "type": "object", "description": "Generic OAuth2 error response when there is something wrong with the OAuth2 authentication. Defined at RFC 6749.", "properties": { "error": { "type": "string", "description": "A single ASCII error code conforming the pattern." }, "error_description": { "type": "string", "description": "Human-readable ASCII text providing additional information, used to assist the client developer in understanding the error that occurred." } }, "required": [ "error" ] }, "VideoStreamSettings": { "type": "object", "properties": { "rotation": { "type": "integer", "description": "The degree rotation of the camera." }, "backlight": { "type": "string", "description": "Modes for backlight compensations. Off - No compensation BLC - Backlight compensation, emphasizes dark parts of the camera image. HLC - Highlight compensation, compensates shiny objects which can disturb the image. WDR - Wide Dynamic Range, compensates for large differences between light and dark parts in the image.\n", "enum": [ "off", "blc", "hlc", "wdr" ] }, "coloredNightview": { "type": "boolean", "description": "Set the night view mode to color (if supported)." }, "manualNightview": { "type": "string", "description": "Day night mode switching of the camera. 'auto' - Automatically switch to day and night mode. 'day' (IR led OFF) - Image is coloured and LED light are turned off. Useful if the camera is recording outwards from behind a window. 'night' (IR led ON) - Black and White image and LED light is turned on.\n", "enum": [ "Auto", "Day", "Night" ] }, "exposure": { "type": "string", "enum": [ "50hz", "60hz", "outdoor", "auto" ], "description": "Adjust camera recording frequency to the light frequency to prevent flickering.\n" }, "brightness": { "type": "integer", "minimum": 0, "maximum": 100 } } }, "VideoStreamSettingsUpdate": { "type": "object", "allOf": [ { "$ref": "#/definitions/VideoStreamSettings" } ] } }, "responses": { "resourceNotFound": { "description": "Referenced resource could not be found.", "schema": { "$ref": "#/definitions/Error" } }, "unauthorized": { "description": "You are not authenticated. Please authenticate and try again.", "schema": { "$ref": "#/definitions/OAuth2Error" } }, "forbidden": { "description": "You have no permission to access the specified resource.", "schema": { "$ref": "#/definitions/Error" } }, "validationError": { "description": "The supplied object is invalid. Error detail will contain the validation error.", "schema": { "$ref": "#/definitions/Error" } }, "notAcceptableError": { "description": "The requested resource is capable of generating only content not acceptable according to the Accept headers sent in the request.", "schema": { "$ref": "#/definitions/Error" } }, "internalServerError": { "description": "Something went wrong in the server. Please try again.", "schema": { "$ref": "#/definitions/Error" } }, "unsupportedMediaType": { "description": "The requested resource does not understand the media type sent in the request.", "schema": { "$ref": "#/definitions/Error" } }, "conflict": { "description": "There was a conflict while trying to perform your request. See error details for more information.", "schema": { "$ref": "#/definitions/Error" } } }, "parameters": { "cameraId": { "name": "cameraId", "in": "path", "description": "ID of the camera.", "required": true, "type": "integer" } }, "paths": { "/cameras/{cameraId}/video/settings": { "get": { "summary": "Get the video settings of the camera", "description": "Retrieves the video settings of the camera based on the camera id provided.", "operationId": "getVideoStreamSettings", "parameters": [ { "$ref": "#/parameters/cameraId" } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "#/definitions/VideoStreamSettings" } }, "401": { "$ref": "#/responses/unauthorized" }, "403": { "$ref": "#/responses/forbidden" }, "404": { "$ref": "#/responses/resourceNotFound" }, "500": { "$ref": "#/responses/internalServerError" } }, "tags": [ "CameraVideoStreamSettings" ] }, "patch": { "summary": "Update the video settings of the camera", "description": "To be able to change the video stream settings of the camera. If the camera doesn't support the settings provided, a conflict error is thrown. To get the supported settings of the camera, please refer to the video stream capabilities api GET /cameras/{cameraId}/video/capabilities", "operationId": "updateVideoStreamSettings", "parameters": [ { "$ref": "#/parameters/cameraId" }, { "name": "targetSettings", "in": "body", "required": true, "schema": { "$ref": "#/definitions/VideoStreamSettingsUpdate" } } ], "responses": { "204": { "description": "No Content" }, "400": { "$ref": "#/responses/validationError" }, "401": { "$ref": "#/responses/unauthorized" }, "403": { "$ref": "#/responses/forbidden" }, "404": { "$ref": "#/responses/resourceNotFound" }, "409": { "$ref": "#/responses/conflict" }, "500": { "$ref": "#/responses/internalServerError" } }, "tags": [ "CameraVideoStreamSettings" ] }, "delete": { "summary": "Reset the video stream settings of a camera back to defaults.", "description": "Remove all the video streaming settings and set back the defaults that came with the camera.", "operationId": "deleteVideoStreamSettings", "parameters": [ { "$ref": "#/parameters/cameraId" } ], "responses": { "204": { "description": "No Content" }, "401": { "$ref": "#/responses/unauthorized" }, "403": { "$ref": "#/responses/forbidden" }, "404": { "$ref": "#/responses/resourceNotFound" }, "409": { "$ref": "#/responses/conflict" }, "500": { "$ref": "#/responses/internalServerError" } }, "tags": [ "CameraVideoStreamSettings" ] } } } }

swagger-camera-video.json