Exporting Sensor metadata¶
Sensor metadata can be found can be found via the GraphQL API.
Strategy¶
Find all the sensors in the organization using following paginated query. Use the paginationDetails to make repeated calls as necessary. See the GraphQL documentation for the fields available on an Asset.
Query
query FindAllSensors($limit: Int = 100, $offset: Int = 0) {
organization {
search(type: SENSOR, limit: $limit, offset: $offset) {
paginationDetails {
total
offset
limit
}
results {
... on Sensor {
id
externalId
name
displayName
description
ontologyType {
id
name
}
measures {
id
name
}
}
}
}
}
}
Considerations¶
- Organizations with a large number of sensors