Data Management

The data management service allows you to reliably capture and sync data to the cloud where you can query data from all your machines. You can collect data from your robots, IoT devices, or any other machines, and sync all the data to one place in the cloud without needing to manually gather data from each machine.

Error

Cloud data management


Data flowing from local disk to cloud to the Viam app, SDKs, and MQL and SQL queries.

Once your data is synced to the cloud, you can view, filter, and label data, and assign data to datasets, from your Viam app DATA page. You can also interact with your data using the Viam CLI, or using the data client API.

Query your data

Once your data has synced, you can query it using the data client API. For tabular sensor data, you can also run SQL or MQL queries from the Query subtab of the Data tab in the Viam app.

Permissions

Data management permissions vary between owners and operators. For more information about who can do what with data, see Data Permissions.

API

The data client API supports the following methods:


Methods to upload data like images or sensor readings directly to the Viam Cloud:

Method NameDescription
BinaryDataCaptureUploadUpload binary data collected on your machine through a specific component and the relevant metadata to the Viam app.
TabularDataCaptureUploadUpload tabular data collected on your machine through a specific component to the Viam app.
FileUploadUpload arbitrary files stored on your machine to the Viam app by file name.
FileUploadFromPathUpload files stored on your machine to the Viam app by filepath.
StreamingDataCaptureUploadUpload the contents of streaming binary data and the relevant metadata to the Viam app.

Methods to download, filter, tag, or perform other tasks on data like images or sensor readings:

Method NameDescription
GetLatestTabularDataGets the most recent tabular data captured from the specified data source, as long as it was synced within the last year.
TabularDataByFilterRetrieve optionally filtered tabular data from the Viam app.
TabularDataBySQLObtain unified tabular data and metadata, queried with SQL.
TabularDataByMQLObtain unified tabular data and metadata, queried with MQL.
BinaryDataByFilterRetrieve optionally filtered binary data from the Viam app.
BinaryDataByIDsRetrieve binary data from the Viam app by BinaryID.
DeleteTabularDataDelete tabular data older than a specified number of days.
DeleteBinaryDataByFilterFilter and delete binary data.
DeleteBinaryDataByIDsFilter and delete binary data by ids.
AddTagsToBinaryDataByIDsAdd tags to binary data by ids.
AddTagsToBinaryDataByFilterAdd tags to binary data by filter.
RemoveTagsFromBinaryDataByIDsRemove tags from binary by ids.
RemoveTagsFromBinaryDataByFilterRemove tags from binary data by filter.
TagsByFilterGet a list of tags using a filter.
AddBoundingBoxToImageByIDAdd a bounding box to an image specified by its BinaryID.
RemoveBoundingBoxFromImageByIDRemoves a bounding box from an image specified by its BinaryID.
BoundingBoxLabelsByFilterGet a list of bounding box labels using a Filter.
GetDatabaseConnectionGet a connection to access a MongoDB Atlas Data federation instance.
ConfigureDatabaseUserConfigure a database user for the Viam organization’s MongoDB Atlas Data Federation instance.
AddBinaryDataToDatasetByIDsAdd the BinaryData to the provided dataset.
RemoveBinaryDataFromDatasetByIDsRemove the BinaryData from the provided dataset.

Methods to work with datasets:

Method NameDescription
CreateDatasetCreate a new dataset.
DeleteDatasetDelete a dataset.
RenameDatasetRename a dataset specified by the dataset ID.
ListDatasetsByOrganizationIDGet the datasets in an organization.
ListDatasetsByIDsGet a list of datasets using their IDs.

The data management API supports a separate set of methods that allow you to sync data to the Viam app. For information about that API, see Data Management API.

For the command line interface data command, see CLI.