Blueye HTTP API

Documentation Powered by ReDoc

# Blueye HTTP API (1.0.1)

Download OpenAPI specification:Download

# Diagnostics

## Drone information

Returns a JSON string of drone information. Using this endpoint is the easiest way to check if there is a drone connected to your network.

### Responses

200

A JSON string of drone information.

get /diagnostics/drone_info
http://192.168.1.101/diagnostics/drone_info

### Request samples

- curl
- Python

Copy

    curl -X GET "http://192.168.1.101/diagnostics/drone_info"

### Response samples

- 200

Content type
application/json
Copy
Expand all Collapse all
`
{

- "commit_id_csys": "299238949a",
- "features": "lasers,jetpack",
- "hardware_id": "ea9ac92e1817a1d4",
- "manufacturer": "Blueye Robotics",
- "model_description": "Blueye Pioneer Underwater Drone",
- "model_name": "Blueye Pioneer",
- "model_url": "https://www.blueyerobotics.com",
- "operating_system": "blunux",
- "serial_number": "BYEDP123456",
- "sw_version": "1.4.7-warrior-master"

}`

## Tether bandwidth test

Performs a bandwidth test on the connection between the surface unit and the drone. Set the test duration with the "duration"-parameter. A longer duration should yield a more accurate result.

##### query Parameters

duration | integer Default: 10 Duration of the test to perform. Unit is seconds.

### Responses

200

A JSON string with the performance test results.

post /diagnostics/iperf
http://192.168.1.101/diagnostics/iperf

### Request samples

- curl
- Python

Copy

    curl -X POST "http://192.168.1.101/diagnostics/iperf" -d duration=5

### Response samples

- 200

Content type
application/json
Copy
Expand all Collapse all
`
{

- "received_Mbps": 79.55458795899487,
- "sent_Mbps": 80.37122746322603,
- "success": true

}`

# Subtitles

## Download subtitle file

Downloads a subtitle file (srt) for a video file containing log data from the dive. The data is gathered from the videos accompanying logfile. By passing in varius queries it is possible to select which data one wants displayed, and where to display it.

##### query Parameters

file required | string Example: file=video_BYEDP123456_2019-01-01_000001.mp4 Name of the videofile to download subtitle file for.
title | string Default: "" Title of the video.
length-units | string Default: "meter" Enum: "meter" "feet" Unit to use for depth. Use "meter" for metric units, and "feet" for imperial.
temp-units | string Default: "celsius" Unit to use for temperature. Use "celsius" for metric units, and "fahrenheit" for imperial.
placement | string Default: "top" Enum: "top" "bottom" "" Where to place the subtitle. Use "top" for placing on the top, "bottom" for placing on the bottom, and "" for using the player default.
field-date | integer Default: 0 Enum: 0 1 Enable or disable the date field. "1" to enable, "0" to disable.
field-depth | integer Default: 1 Enum: 0 1 Enable or disable the depth field. "1" to enable, "0" to disable.
field-heading | integer Default: 1 Enum: 0 1 Enable or disable the heading field. "1" to enable, "0" to disable.
field-temp | integer Default: 1 Enum: 0 1 Enable or disable the temperature field. "1" to enable, "0" to disable.
date-format | string Default: "%Y-%m-%d %H:%M:%S" Format of the date/time. Python3 documentation for datetime formatting
tz-offset | integer <int32> Default: 0 The drone stores all time in UTC+0, so if you were diving in another timezone and want to correct for that in the displayed time you can add a timezone offset here. The unit is minutes and both positive and negative values are supported.
format | string Default: "srt" Enum: "srt" "vtt" Subtitles can also be retrived in the WEBVTT format. Use format=vtt to get a .vtt file instead of a .srt file.

### Responses

200

Subtitle file for the requested video file

get /srt
http://192.168.1.101/srt

### Request samples

- curl
- Python

Copy

    curl -X GET -G "http://192.168.1.101/srt" \
      -d "file=video_BYEDP123456_2019-01-01_000001.mp4" \
      -d "title=My title"

# Dive data

## Array of logs

Returns an array of logs from the drone. Each array item represents an available log file on the drone. Use the /logcsv/{filename} endpoint to get the full log.

### Responses

200

Array of logs

get /logcsv
http://192.168.1.101/logcsv

### Request samples

- curl
- Python

Copy

    curl -X GET "http://192.168.1.101/logcsv"

### Response samples

- 200

Content type
application/json
Copy
Expand all Collapse all
`
[

- {
  - "name": "ea9ac92e1817a1d4-00073.csv",
  - "binsize": 1099448,
  - "timestamp": "2019-01-01T00:00:00.000001",
  - "maxdepth": 21050
  }

]`

## CSV log-file

Downloads a comma-separated-value (CSV) log-file with the requested name.

##### path Parameters

filename required | string Filename of log to download

##### query Parameters

format | string Default: "" Example: format=dashware Add format=dashware to get a CSV file customized for use in Dashware to create video overlays

### Responses

200

Comma-separated-value file with log data

get /logcsv/{filename}
http://192.168.1.101/logcsv/{filename}

### Request samples

- curl
- Python

Copy

    # To get log with filename ea9ac92e1817a1d4-00090.csv
    curl -X GET "http://192.168.1.101/logcsv/ea9ac92e1817a1d4-00090.csv"

## Download CSV file with data for creating scaled 3D models

Download CSV file with data for creating scaled 3D models in Pix4d

##### query Parameters

file required | string Example: file=video_BYEDP123456_2019-01-01_000001.mp4 Name of the video file to download data for
frame-step | integer Example: frame-step=20 Amout of steps between each frame grab

### Responses

200

Comma-separated-value file with log data

get /pix4d
http://192.168.1.101/pix4d

### Request samples

- curl
- Python

Copy

    # To get CSV logfile for filename video_BYEDP123456_2019-01-01_000001.mp4
    curl -X GET "http://192.168.1.101/pix4d/" \
      -d "file=video_BYEDP123456_2019-01-01_000001.mp4"

## Download CSV file with data for creating scaled 3D models

Download CSV file with data for creating scaled 3D models in Agisoft

##### query Parameters

file required | string Example: file=video_BYEDP123456_2019-01-01_000001.mp4 Name of the video file to download data for
frame-step | integer Example: frame-step=20 Amout of steps between each frame grab
mag-dist | integer [ 1 .. 360 ] Default: "180" Example: mag-dist=180 Expected compass variance induced from magnetic disturbance in degrees. The most important data for an accurate 3D model are roll and pitch, which are not affected by magnetic disturbance, so the default is set quite high (180). If you trust that the data has not been skewed by magnetic interference you can set this to a medium (60) or even low (10) value.

### Responses

200

Comma-separated-value file with log data

get /agisoft
http://192.168.1.101/agisoft

### Request samples

- curl
- Python

Copy

    # To get log CSV for videofile video_BYEDP123456_2019-01-01_000001.mp4
    curl -X GET "http://192.168.1.101/agisoft \
      -d "file=video_BYEDP123456_2019-01-01_000001.mp4"

# Pictures

## Download pictures

Downloads a picture (jpg) if get param filename is specified. If no parameter is set you'll get a list of all images.

##### query Parameters

file | string Example: file=picture_BYEDP123456_2019-01-01_000001.001.jpg Name of the image file to download

### Responses

200

Picture

get /picture
http://192.168.1.101/picture

### Request samples

- curl
- Python

Copy

    curl -X GET -G "http://192.168.1.101/picture" \
      -d "file=picture_BYEDP123456_2019-01-01_000001.001.jpg"

### Response samples

- 200

Content type
application/json
Copy
Expand all Collapse all
`
[

- {
  - "name": "picture_BYEDP123456_2019-01-01_000001.001.jpg"
  }

]`

## Download a thumbnail of a picture with metadata overlay

Downloads a picture (jpg) with metadata from when the photo was captured.

##### query Parameters

file required | string Example: file=picture_BYEDP123456_2019-01-01_000001.001.jpg Name of the image file to download

### Responses

200

Picture thumbnail

get /picture/thumbnail
http://192.168.1.101/picture/thumbnail

### Request samples

- curl
- Python

Copy

    curl -X GET -G "http://192.168.1.101/picture/thumbnail" \
      -d "file=picture_BYEDP123456_2019-01-01_000001.001.jpg"

## Download pictures with metadata overlay

Downloads a picture (jpg) with metadata from when the photo was captured.

##### query Parameters

file required | string Example: file=picture_BYEDP123456_2019-01-01_000001.001.jpg Name of the image file to download
title | string Default: "" Title of the image.
subtitle | string Default: "" Subtitle of the image
length-units | string Default: "meter" Enum: "meter" "feet" Unit to use for depth. Use "meter" for metric units, and "feet" for imperial.
temp-units | string Default: "celsius" Unit to use for temperature. Use "celsius" for metric units, and "fahrenheit" for imperial.
field-date | integer Default: 1 Enum: 0 1 Enable or disable the date field. "1" to enable, "0" to disable.
field-depth | integer Default: 1 Enum: 0 1 Enable or disable the depth field. "1" to enable, "0" to disable.
field-heading | integer Default: 1 Enum: 0 1 Enable or disable the heading field. "1" to enable, "0" to disable.
field-temp | integer Default: 1 Enum: 0 1 Enable or disable the temperature field. "1" to enable, "0" to disable.
date-format | string Default: "%Y-%m-%d %H:%M:%S" Format of the date/time. Python3 documentation for datetime formatting
tz-offset | integer <int32> Default: 0 The drone stores all time in UTC+0, so if you were diving in another timezone and want to correct for that in the displayed time you can add a timezone offset here. The unit is minutes and both positive and negative values are supported.

### Responses

200

Picture with overlay metadata

get /picture/overlay
http://192.168.1.101/picture/overlay

### Request samples

- curl
- Python

Copy

    curl -X GET -G "http://192.168.1.101/picture/overlay" \
      -d "file=picture_BYEDP123456_2019-01-01_000001.001.jpg" \