# Streams

Each camera contains a number of sensors of different types. Each sensor (or combination of multiple sensors) provides an image **stream** which can be consumed directly as video stream, or fed as input into a neural network. Our API exposes operations through which these **streams** can be consumed or manipulated. Each stream is addresses either by its sensor name  - CAM\_(A-H)[^1] or by its combined name - DEPTH\_(A-H)\_(A-H)[^2]*.*

## Depth API

Some camera models containing multiple image sensors, support a feature called *Stereo Depth*. This feature combines data from two image sensors at a time, to calculate the depth of the image in front of it. The result is a single image stream. The image will consist of depth data calculated by the camera, lighter areas will contain objects that are closer to the camera while darker areas will contain objects further away. This stream is configurable the same way as a single sensor.

{% hint style="info" %}
Depth stream and the respective sensors it uses cannot be both active at the same time. E.g. if stream DEPTH\_B\_C is active, then streams CAM\_B and CAM\_C will be inactive and vice versa.
{% endhint %}

## API Reference

## GET /cameras/{mxid}/streams/

> List All Streams

```json
{"openapi":"3.1.0","info":{"title":"Robopipe API","version":"0.2.1.dev12"},"servers":[{"url":"http://localhost:8080","description":"Locally running server"}],"paths":{"/cameras/{mxid}/streams/":{"get":{"tags":["streams"],"summary":"List All Streams","operationId":"list_all_streams_cameras__mxid__streams__get","parameters":[{"name":"mxid","in":"path","required":true,"schema":{"type":"string","pattern":"[A-Z0-9]+","title":"Mxid"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/StreamInfo"},"title":"Response List All Streams Cameras  Mxid  Streams  Get"}}}},"404":{"description":"Camera not found"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}}},"components":{"schemas":{"StreamInfo":{"properties":{"name":{"type":"string","title":"Name"},"active":{"type":"boolean","title":"Active"}},"type":"object","required":["name","active"],"title":"StreamInfo"},"HTTPValidationError":{"properties":{"detail":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"},"ValidationError":{"properties":{"loc":{"items":{"anyOf":[{"type":"string"},{"type":"integer"}]},"type":"array","title":"Location"},"msg":{"type":"string","title":"Message"},"type":{"type":"string","title":"Error Type"}},"type":"object","required":["loc","msg","type"],"title":"ValidationError"}}}}
```

## POST /cameras/{mxid}/streams/{stream\_name}/

> Activate Stream

```json
{"openapi":"3.1.0","info":{"title":"Robopipe API","version":"0.2.1.dev12"},"servers":[{"url":"http://localhost:8080","description":"Locally running server"}],"paths":{"/cameras/{mxid}/streams/{stream_name}/":{"post":{"tags":["streams","streams"],"summary":"Activate Stream","operationId":"activate_stream_cameras__mxid__streams__stream_name___post","parameters":[{"name":"stream_name","in":"path","required":true,"schema":{"type":"string","pattern":"CAM_[A-H]|DEPTH_[A-H]_[A-H]","title":"Stream Name"}},{"name":"mxid","in":"path","required":true,"schema":{"type":"string","pattern":"[A-Z0-9]+","title":"Mxid"}}],"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"404":{"description":"Camera or stream not found"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}}},"components":{"schemas":{"HTTPValidationError":{"properties":{"detail":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"},"ValidationError":{"properties":{"loc":{"items":{"anyOf":[{"type":"string"},{"type":"integer"}]},"type":"array","title":"Location"},"msg":{"type":"string","title":"Message"},"type":{"type":"string","title":"Error Type"}},"type":"object","required":["loc","msg","type"],"title":"ValidationError"}}}}
```

## DELETE /cameras/{mxid}/streams/{stream\_name}/

> Deactivate Stream

```json
{"openapi":"3.1.0","info":{"title":"Robopipe API","version":"0.2.1.dev12"},"servers":[{"url":"http://localhost:8080","description":"Locally running server"}],"paths":{"/cameras/{mxid}/streams/{stream_name}/":{"delete":{"tags":["streams","streams"],"summary":"Deactivate Stream","operationId":"deactivate_stream_cameras__mxid__streams__stream_name___delete","parameters":[{"name":"stream_name","in":"path","required":true,"schema":{"type":"string","pattern":"CAM_[A-H]|DEPTH_[A-H]_[A-H]","title":"Stream Name"}},{"name":"mxid","in":"path","required":true,"schema":{"type":"string","pattern":"[A-Z0-9]+","title":"Mxid"}}],"responses":{"202":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"404":{"description":"Camera or stream not found"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}}},"components":{"schemas":{"HTTPValidationError":{"properties":{"detail":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"},"ValidationError":{"properties":{"loc":{"items":{"anyOf":[{"type":"string"},{"type":"integer"}]},"type":"array","title":"Location"},"msg":{"type":"string","title":"Message"},"type":{"type":"string","title":"Error Type"}},"type":"object","required":["loc","msg","type"],"title":"ValidationError"}}}}
```

## GET /cameras/{mxid}/streams/{stream\_name}/config

> Get Stream Config

```json
{"openapi":"3.1.0","info":{"title":"Robopipe API","version":"0.2.1.dev12"},"servers":[{"url":"http://localhost:8080","description":"Locally running server"}],"paths":{"/cameras/{mxid}/streams/{stream_name}/config":{"get":{"tags":["streams","streams"],"summary":"Get Stream Config","operationId":"get_stream_config_cameras__mxid__streams__stream_name__config_get","parameters":[{"name":"stream_name","in":"path","required":true,"schema":{"type":"string","pattern":"CAM_[A-H]|DEPTH_[A-H]_[A-H]","title":"Stream Name"}},{"name":"mxid","in":"path","required":true,"schema":{"type":"string","pattern":"[A-Z0-9]+","title":"Mxid"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/CameraConfigProperties"},{"$ref":"#/components/schemas/ColorCameraConfigProperties"},{"$ref":"#/components/schemas/MonoCameraConfigProperties"}],"title":"Response Get Stream Config Cameras  Mxid  Streams  Stream Name  Config Get"}}}},"404":{"description":"Camera or stream not found"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}}},"components":{"schemas":{"CameraConfigProperties":{"properties":{"resolution":{"prefixItems":[{"type":"integer"},{"type":"integer"}],"type":"array","maxItems":2,"minItems":2,"title":"Resolution"},"still_size":{"prefixItems":[{"type":"integer"},{"type":"integer"}],"type":"array","maxItems":2,"minItems":2,"title":"Still Size"},"preview_size":{"prefixItems":[{"type":"integer"},{"type":"integer"}],"type":"array","maxItems":2,"minItems":2,"title":"Preview Size"},"video_size":{"prefixItems":[{"type":"integer"},{"type":"integer"}],"type":"array","maxItems":2,"minItems":2,"title":"Video Size"},"fps":{"type":"number","title":"Fps"}},"type":"object","required":["resolution","still_size","preview_size","video_size","fps"],"title":"CameraConfigProperties"},"ColorCameraConfigProperties":{"properties":{"resolution":{"$ref":"#/components/schemas/ColorCameraResolution"},"still_size":{"prefixItems":[{"type":"integer"},{"type":"integer"}],"type":"array","maxItems":2,"minItems":2,"title":"Still Size"},"preview_size":{"prefixItems":[{"type":"integer"},{"type":"integer"}],"type":"array","maxItems":2,"minItems":2,"title":"Preview Size"},"video_size":{"prefixItems":[{"type":"integer"},{"type":"integer"}],"type":"array","maxItems":2,"minItems":2,"title":"Video Size"},"sensor_crop":{"prefixItems":[{"type":"number"},{"type":"number"}],"type":"array","maxItems":2,"minItems":2,"title":"Sensor Crop"},"fps":{"type":"number","title":"Fps"}},"type":"object","required":["resolution","still_size","preview_size","video_size","sensor_crop","fps"],"title":"ColorCameraConfigProperties"},"ColorCameraResolution":{"type":"string","enum":["THE_1080_P","THE_1200_P","THE_12_MP","THE_1352X1012","THE_13_MP","THE_1440X1080","THE_2024X1520","THE_4000X3000","THE_48_MP","THE_4_K","THE_5312X6000","THE_5_MP","THE_720_P","THE_800_P"],"title":"ColorCameraResolution"},"MonoCameraConfigProperties":{"properties":{"resolution":{"$ref":"#/components/schemas/MonoCameraResolution"},"fps":{"type":"number","title":"Fps"}},"type":"object","required":["resolution","fps"],"title":"MonoCameraConfigProperties"},"MonoCameraResolution":{"type":"string","enum":["THE_1200_P","THE_400_P","THE_480_P","THE_720_P","THE_800_P"],"title":"MonoCameraResolution"},"HTTPValidationError":{"properties":{"detail":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"},"ValidationError":{"properties":{"loc":{"items":{"anyOf":[{"type":"string"},{"type":"integer"}]},"type":"array","title":"Location"},"msg":{"type":"string","title":"Message"},"type":{"type":"string","title":"Error Type"}},"type":"object","required":["loc","msg","type"],"title":"ValidationError"}}}}
```

## POST /cameras/{mxid}/streams/{stream\_name}/config

> Update Stream Config

```json
{"openapi":"3.1.0","info":{"title":"Robopipe API","version":"0.2.1.dev12"},"servers":[{"url":"http://localhost:8080","description":"Locally running server"}],"paths":{"/cameras/{mxid}/streams/{stream_name}/config":{"post":{"tags":["streams","streams"],"summary":"Update Stream Config","operationId":"update_stream_config_cameras__mxid__streams__stream_name__config_post","parameters":[{"name":"stream_name","in":"path","required":true,"schema":{"type":"string","pattern":"CAM_[A-H]|DEPTH_[A-H]_[A-H]","title":"Stream Name"}},{"name":"mxid","in":"path","required":true,"schema":{"type":"string","pattern":"[A-Z0-9]+","title":"Mxid"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/CameraConfigProperties"},{"$ref":"#/components/schemas/ColorCameraConfigProperties"},{"$ref":"#/components/schemas/MonoCameraConfigProperties"}],"title":"Config"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/CameraConfigProperties"},{"$ref":"#/components/schemas/ColorCameraConfigProperties"},{"$ref":"#/components/schemas/MonoCameraConfigProperties"}],"title":"Response Update Stream Config Cameras  Mxid  Streams  Stream Name  Config Post"}}}},"404":{"description":"Camera or stream not found"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}}},"components":{"schemas":{"CameraConfigProperties":{"properties":{"resolution":{"prefixItems":[{"type":"integer"},{"type":"integer"}],"type":"array","maxItems":2,"minItems":2,"title":"Resolution"},"still_size":{"prefixItems":[{"type":"integer"},{"type":"integer"}],"type":"array","maxItems":2,"minItems":2,"title":"Still Size"},"preview_size":{"prefixItems":[{"type":"integer"},{"type":"integer"}],"type":"array","maxItems":2,"minItems":2,"title":"Preview Size"},"video_size":{"prefixItems":[{"type":"integer"},{"type":"integer"}],"type":"array","maxItems":2,"minItems":2,"title":"Video Size"},"fps":{"type":"number","title":"Fps"}},"type":"object","required":["resolution","still_size","preview_size","video_size","fps"],"title":"CameraConfigProperties"},"ColorCameraConfigProperties":{"properties":{"resolution":{"$ref":"#/components/schemas/ColorCameraResolution"},"still_size":{"prefixItems":[{"type":"integer"},{"type":"integer"}],"type":"array","maxItems":2,"minItems":2,"title":"Still Size"},"preview_size":{"prefixItems":[{"type":"integer"},{"type":"integer"}],"type":"array","maxItems":2,"minItems":2,"title":"Preview Size"},"video_size":{"prefixItems":[{"type":"integer"},{"type":"integer"}],"type":"array","maxItems":2,"minItems":2,"title":"Video Size"},"sensor_crop":{"prefixItems":[{"type":"number"},{"type":"number"}],"type":"array","maxItems":2,"minItems":2,"title":"Sensor Crop"},"fps":{"type":"number","title":"Fps"}},"type":"object","required":["resolution","still_size","preview_size","video_size","sensor_crop","fps"],"title":"ColorCameraConfigProperties"},"ColorCameraResolution":{"type":"string","enum":["THE_1080_P","THE_1200_P","THE_12_MP","THE_1352X1012","THE_13_MP","THE_1440X1080","THE_2024X1520","THE_4000X3000","THE_48_MP","THE_4_K","THE_5312X6000","THE_5_MP","THE_720_P","THE_800_P"],"title":"ColorCameraResolution"},"MonoCameraConfigProperties":{"properties":{"resolution":{"$ref":"#/components/schemas/MonoCameraResolution"},"fps":{"type":"number","title":"Fps"}},"type":"object","required":["resolution","fps"],"title":"MonoCameraConfigProperties"},"MonoCameraResolution":{"type":"string","enum":["THE_1200_P","THE_400_P","THE_480_P","THE_720_P","THE_800_P"],"title":"MonoCameraResolution"},"HTTPValidationError":{"properties":{"detail":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"},"ValidationError":{"properties":{"loc":{"items":{"anyOf":[{"type":"string"},{"type":"integer"}]},"type":"array","title":"Location"},"msg":{"type":"string","title":"Message"},"type":{"type":"string","title":"Error Type"}},"type":"object","required":["loc","msg","type"],"title":"ValidationError"}}}}
```

## GET /cameras/{mxid}/streams/{stream\_name}/control

> Get Stream Control

```json
{"openapi":"3.1.0","info":{"title":"Robopipe API","version":"0.2.1.dev12"},"servers":[{"url":"http://localhost:8080","description":"Locally running server"}],"paths":{"/cameras/{mxid}/streams/{stream_name}/control":{"get":{"tags":["streams","streams"],"summary":"Get Stream Control","operationId":"get_stream_control_cameras__mxid__streams__stream_name__control_get","parameters":[{"name":"stream_name","in":"path","required":true,"schema":{"type":"string","pattern":"CAM_[A-H]|DEPTH_[A-H]_[A-H]","title":"Stream Name"}},{"name":"mxid","in":"path","required":true,"schema":{"type":"string","pattern":"[A-Z0-9]+","title":"Mxid"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SensorControl"}}}},"404":{"description":"Camera or stream not found"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}}},"components":{"schemas":{"SensorControl":{"properties":{"exposure_time":{"type":"integer","maximum":33000,"minimum":1,"title":"Exposure Time","description":"Exposure time in microseconds. Ignored if auto_exposure_enable is set to true. Value must be between 1 and 33000"},"sensitivity_iso":{"type":"integer","maximum":5000,"minimum":100,"title":"Sensitivity Iso","description":"Value must be between 100 and 5000"},"auto_exposure_enable":{"type":"boolean","title":"Auto Exposure Enable"},"auto_exposure_compensation":{"type":"integer","maximum":9,"minimum":-9,"title":"Auto Exposure Compensation","description":"Value must be between -9 and 9"},"auto_exposure_limit":{"type":"integer","title":"Auto Exposure Limit","description":"Maximum exposure time limit for auto-exposure in microseconds"},"auto_exposure_lock":{"type":"boolean","title":"Auto Exposure Lock"},"contrast":{"type":"integer","maximum":10,"minimum":-10,"title":"Contrast","description":"Value must be between -10 and 10"},"brightness":{"type":"integer","maximum":10,"minimum":-10,"title":"Brightness","description":"Value must be between -10 and 10"},"saturation":{"type":"integer","maximum":10,"minimum":-10,"title":"Saturation","description":"Value must be between -10 and 10"},"chroma_denoise":{"type":"integer","maximum":4,"minimum":0,"title":"Chroma Denoise","description":"Value must be between 0 and 4"},"luma_denoise":{"type":"integer","maximum":4,"minimum":0,"title":"Luma Denoise","description":"Value must be between 0 and 4"},"auto_whitebalance_lock":{"type":"boolean","title":"Auto Whitebalance Lock"},"auto_whitebalance_mode":{"$ref":"#/components/schemas/AutoWhiteBalanceMode","default":"AUTO"},"manual_whitebalance":{"type":"integer","maximum":12000,"minimum":1000,"title":"Manual Whitebalance","description":"Value must be between 1000 and 12000"},"focus":{"anyOf":[{"$ref":"#/components/schemas/SensorFocus"},{"type":"null"}]}},"type":"object","required":["exposure_time","sensitivity_iso","auto_exposure_enable","auto_exposure_compensation","auto_exposure_limit","auto_exposure_lock","contrast","brightness","saturation","chroma_denoise","luma_denoise","auto_whitebalance_lock","manual_whitebalance"],"title":"SensorControl"},"AutoWhiteBalanceMode":{"type":"string","enum":["AUTO","CLOUDY_DAYLIGHT","DAYLIGHT","FLUORESCENT","INCANDESCENT","OFF","SHADE","TWILIGHT","WARM_FLUORESCENT"],"title":"AutoWhiteBalanceMode"},"SensorFocus":{"properties":{"auto_focus_mode":{"$ref":"#/components/schemas/AutoFocusMode","default":"CONTINUOUS_VIDEO"},"auto_focus_trigger":{"type":"boolean","title":"Auto Focus Trigger","default":false},"lens_position":{"type":"number","maximum":1,"minimum":0,"title":"Lens Position","description":"Value must be between 0.0 and 1.0","default":0}},"type":"object","title":"SensorFocus"},"AutoFocusMode":{"type":"string","enum":["OFF","AUTO","MACRO","CONTINUOUS_VIDEO","CONTINUOUS_PICTURE","EDOF"],"title":"AutoFocusMode"},"HTTPValidationError":{"properties":{"detail":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"},"ValidationError":{"properties":{"loc":{"items":{"anyOf":[{"type":"string"},{"type":"integer"}]},"type":"array","title":"Location"},"msg":{"type":"string","title":"Message"},"type":{"type":"string","title":"Error Type"}},"type":"object","required":["loc","msg","type"],"title":"ValidationError"}}}}
```

## POST /cameras/{mxid}/streams/{stream\_name}/control

> Update Stream Control

```json
{"openapi":"3.1.0","info":{"title":"Robopipe API","version":"0.2.1.dev12"},"servers":[{"url":"http://localhost:8080","description":"Locally running server"}],"paths":{"/cameras/{mxid}/streams/{stream_name}/control":{"post":{"tags":["streams","streams"],"summary":"Update Stream Control","operationId":"update_stream_control_cameras__mxid__streams__stream_name__control_post","parameters":[{"name":"stream_name","in":"path","required":true,"schema":{"type":"string","pattern":"CAM_[A-H]|DEPTH_[A-H]_[A-H]","title":"Stream Name"}},{"name":"mxid","in":"path","required":true,"schema":{"type":"string","pattern":"[A-Z0-9]+","title":"Mxid"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SensorControlUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SensorControl"}}}},"404":{"description":"Camera or stream not found"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}}},"components":{"schemas":{"SensorControlUpdate":{"properties":{"exposure_time":{"type":"integer","maximum":33000,"minimum":1,"title":"Exposure Time","description":"Exposure time in microseconds. Ignored if auto_exposure_enable is set to true. Value must be between 1 and 33000"},"sensitivity_iso":{"type":"integer","maximum":5000,"minimum":100,"title":"Sensitivity Iso","description":"Value must be between 100 and 5000"},"auto_exposure_enable":{"type":"boolean","title":"Auto Exposure Enable"},"auto_exposure_compensation":{"type":"integer","maximum":9,"minimum":-9,"title":"Auto Exposure Compensation","description":"Value must be between -9 and 9"},"auto_exposure_limit":{"type":"integer","title":"Auto Exposure Limit","description":"Maximum exposure time limit for auto-exposure in microseconds"},"auto_exposure_lock":{"type":"boolean","title":"Auto Exposure Lock"},"contrast":{"type":"integer","maximum":10,"minimum":-10,"title":"Contrast","description":"Value must be between -10 and 10"},"brightness":{"type":"integer","maximum":10,"minimum":-10,"title":"Brightness","description":"Value must be between -10 and 10"},"saturation":{"type":"integer","maximum":10,"minimum":-10,"title":"Saturation","description":"Value must be between -10 and 10"},"chroma_denoise":{"type":"integer","maximum":4,"minimum":0,"title":"Chroma Denoise","description":"Value must be between 0 and 4"},"luma_denoise":{"type":"integer","maximum":4,"minimum":0,"title":"Luma Denoise","description":"Value must be between 0 and 4"},"auto_whitebalance_lock":{"type":"boolean","title":"Auto Whitebalance Lock"},"auto_whitebalance_mode":{"$ref":"#/components/schemas/AutoWhiteBalanceMode"},"manual_whitebalance":{"type":"integer","maximum":12000,"minimum":1000,"title":"Manual Whitebalance","description":"Value must be between 1000 and 12000"},"focus":{"anyOf":[{"$ref":"#/components/schemas/SensorFocus"},{"type":"null"}]}},"type":"object","title":"SensorControlUpdate"},"AutoWhiteBalanceMode":{"type":"string","enum":["AUTO","CLOUDY_DAYLIGHT","DAYLIGHT","FLUORESCENT","INCANDESCENT","OFF","SHADE","TWILIGHT","WARM_FLUORESCENT"],"title":"AutoWhiteBalanceMode"},"SensorFocus":{"properties":{"auto_focus_mode":{"$ref":"#/components/schemas/AutoFocusMode","default":"CONTINUOUS_VIDEO"},"auto_focus_trigger":{"type":"boolean","title":"Auto Focus Trigger","default":false},"lens_position":{"type":"number","maximum":1,"minimum":0,"title":"Lens Position","description":"Value must be between 0.0 and 1.0","default":0}},"type":"object","title":"SensorFocus"},"AutoFocusMode":{"type":"string","enum":["OFF","AUTO","MACRO","CONTINUOUS_VIDEO","CONTINUOUS_PICTURE","EDOF"],"title":"AutoFocusMode"},"SensorControl":{"properties":{"exposure_time":{"type":"integer","maximum":33000,"minimum":1,"title":"Exposure Time","description":"Exposure time in microseconds. Ignored if auto_exposure_enable is set to true. Value must be between 1 and 33000"},"sensitivity_iso":{"type":"integer","maximum":5000,"minimum":100,"title":"Sensitivity Iso","description":"Value must be between 100 and 5000"},"auto_exposure_enable":{"type":"boolean","title":"Auto Exposure Enable"},"auto_exposure_compensation":{"type":"integer","maximum":9,"minimum":-9,"title":"Auto Exposure Compensation","description":"Value must be between -9 and 9"},"auto_exposure_limit":{"type":"integer","title":"Auto Exposure Limit","description":"Maximum exposure time limit for auto-exposure in microseconds"},"auto_exposure_lock":{"type":"boolean","title":"Auto Exposure Lock"},"contrast":{"type":"integer","maximum":10,"minimum":-10,"title":"Contrast","description":"Value must be between -10 and 10"},"brightness":{"type":"integer","maximum":10,"minimum":-10,"title":"Brightness","description":"Value must be between -10 and 10"},"saturation":{"type":"integer","maximum":10,"minimum":-10,"title":"Saturation","description":"Value must be between -10 and 10"},"chroma_denoise":{"type":"integer","maximum":4,"minimum":0,"title":"Chroma Denoise","description":"Value must be between 0 and 4"},"luma_denoise":{"type":"integer","maximum":4,"minimum":0,"title":"Luma Denoise","description":"Value must be between 0 and 4"},"auto_whitebalance_lock":{"type":"boolean","title":"Auto Whitebalance Lock"},"auto_whitebalance_mode":{"$ref":"#/components/schemas/AutoWhiteBalanceMode","default":"AUTO"},"manual_whitebalance":{"type":"integer","maximum":12000,"minimum":1000,"title":"Manual Whitebalance","description":"Value must be between 1000 and 12000"},"focus":{"anyOf":[{"$ref":"#/components/schemas/SensorFocus"},{"type":"null"}]}},"type":"object","required":["exposure_time","sensitivity_iso","auto_exposure_enable","auto_exposure_compensation","auto_exposure_limit","auto_exposure_lock","contrast","brightness","saturation","chroma_denoise","luma_denoise","auto_whitebalance_lock","manual_whitebalance"],"title":"SensorControl"},"HTTPValidationError":{"properties":{"detail":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"},"ValidationError":{"properties":{"loc":{"items":{"anyOf":[{"type":"string"},{"type":"integer"}]},"type":"array","title":"Location"},"msg":{"type":"string","title":"Message"},"type":{"type":"string","title":"Error Type"}},"type":"object","required":["loc","msg","type"],"title":"ValidationError"}}}}
```

## GET /cameras/{mxid}/streams/{stream\_name}/still

> Capture Still Image

```json
{"openapi":"3.1.0","info":{"title":"Robopipe API","version":"0.2.1.dev12"},"servers":[{"url":"http://localhost:8080","description":"Locally running server"}],"paths":{"/cameras/{mxid}/streams/{stream_name}/still":{"get":{"tags":["streams","streams"],"summary":"Capture Still Image","operationId":"capture_still_image_cameras__mxid__streams__stream_name__still_get","parameters":[{"name":"stream_name","in":"path","required":true,"schema":{"type":"string","pattern":"CAM_[A-H]|DEPTH_[A-H]_[A-H]","title":"Stream Name"}},{"name":"mxid","in":"path","required":true,"schema":{"type":"string","pattern":"[A-Z0-9]+","title":"Mxid"}},{"name":"format","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"default":"jpeg","title":"Format"}}],"responses":{"200":{"description":"Image bytes in the selected format","content":{"image/*":{"schema":{"type":"string"}}}},"404":{"description":"Camera or stream not found"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}}},"components":{"schemas":{"HTTPValidationError":{"properties":{"detail":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"},"ValidationError":{"properties":{"loc":{"items":{"anyOf":[{"type":"string"},{"type":"integer"}]},"type":"array","title":"Location"},"msg":{"type":"string","title":"Message"},"type":{"type":"string","title":"Error Type"}},"type":"object","required":["loc","msg","type"],"title":"ValidationError"}}}}
```

[^1]: This means that there are up to **8**

    available sensor, with names CAM\_A,

    CAM\_B, CAM\_C, ... depending on you camera model.

[^2]: The first and second capital letters A-H in the stream name correspond to the left and right image sensor respectively.
