Create Metadata for your Sensor Fleet
Define the meta data structures to help you manage your sensor fleet.
This page conains:
- All the info you need to create the metadata structures that Eratos/Senaps need to make the most out of your sensor fleet
- API methods for creating metadata
Metadata: Group
A group is collection type for streams and platforms. Datastreams, platforms and other groups can all be part of groups and can help you organise your sensor systems.
Create a Group
To create a group, navigate to the group section in senaps, under the data tab. Senaps Group Link.
Then click "+Add a New Group". You should see the screen below. Fill in the required information (Id
,Name
and Organisation
at minimum) and click create platform.

Where,
Id
: A unique id for the platform. The eratos convention is to organisation.group.platformName
: A user readable nameDescription
: A user readable description as a string.Organisation
: The organisation this platform will be associated with.Groups
: A metadata structure to help organise associated platforms, datastreams and locations..Metadata(Optional)
:A place to store custom metadata about the platform as a JSON
Metadata: Platform
The platform is the ground level metadata grouping of datastreams, and is best thought as the physical "sensor station" that several sensors are situated in, like a weather station. Platforms are a rich metadata object in Eratos, allowing you to add metadata to several streams at once, like a location.
Create a platform
To create a platform, navigate to the platform section in senaps, under the data tab. Senaps Platforms Link.
Then click "+Add a New Platform. You should see the screen below. Fill in the required information (Id
and Organisation
at minimum) and click create platform.

Where,
Id
: A unique id for the platform. The eratos convention is: organisation.group.platformName
: A user readable nameOrganisation
: The organisation this platform will be associated with.Groups
: A metadata structure to help organise associated platforms, datastreams and locations..Metadata(Optional)
:A place to store custom metadata about the platform as a JSON
Add Datastreams to your platform
To add datastreams to your platform, find your new platform in the platform list and click its Platform Id.
Scroll down until you see the streams section. There should be a search bar to allows you to search for datastreams and a green add button that allows you to add them.
You can also remove Datastreams from a platform without deleting the Datastream if you wish to reconfigure your metadata structures.
Metadata: Location/ Deployment
A Location is a metadata object that allows you to define a point in 3D space. Platforms can then inherit the location to correlate a deployment of a sensor station to a point in space. Defining a platforms location can enable more detailed mapping and analysis of your sensor network. They also define all your related streams to a location for more powerful geospatial analysis, such as the ability to display the BOM forecast for a given location.
When you apply a Location to a Platform it is called a Deployment. Deployments let you track where this sensor has been so you can accurately record the location of origin of your sensor measurements across time.

Create a Location
To create a Location, navigate to the Location section in senaps, under the data tab. Senaps Location Link.
Then click "+Add a New Location. You should see the screen below. Fill in the required information (Id
, Longitude
,Latitude
and Organisation
at minimum) and click create platform. You can also click a point on the map to define a location's lat and lon.

Where,
Id
: A unique id for the platform. The eratos convention is: organisation."location".name-of-location- ie. eratos.location.hobart
Description
: A user readable description of the location as a string.Longitude
: The longitude value of the location.Latitude
: The latitude value of the location.Elevation
: The elevation of the location in metres.Organisation
: The organisation this platform will be associated with.Groups
: A metadata structure to help organise associated platforms, datastreams and locations.Metadata(Optional)
:A place to store custom metadata about the platform as a JSON
API methods
Detailed documentation on Senaps API can be found here./
Create a Group
#User Data
group_id = "eratos-internal.example-group
group_name = "Example Group"
description = "This is a group"
org_id = "eratos-internal"
group_ids = ["eratos-internal.example-parent-group.one","eratos-internal.example-parent-group.two"]
user_metadata = {"metadata" : "here"}
#Senaps API PUT Request
url = f"https://senaps.eratos.com/api/sensor/v2/groups/{group_id}"
headers = {
'apikey': senaps_key
}
payload = {
"id": group_id,
"name": group_name,
"organisationid": org_id,
"description":description ,
"groupids": group_ids,
"usermetadata": user_metadata
}
response = requests.request("PUT", url, headers=headers, json=payload)
response.raise_for_status()
print(platform_id, "Done")
Create a Platform
#User Data
platform_id = "eratos-internal.example-group.example-platform
platform_name = "Example Platform"
org_id = "eratos-internal"
group_ids = ["eratos-internal.example-group"]
stream_ids = ["eratos-internal.example-group.example-platform.stream.one",
"eratos-internal.example-group.example-platform.stream.two"]
locations = "eratos-internal.location.hobart"
user_metadata = {"metadata" : "here"}
#Senaps API PUT Request
url = f"https://senaps.eratos.com/api/sensor/v2/platforms/{platform_id}"
headers = {
'apikey': senaps_key
}
payload = {
"id": platform_id,
"name": platform_name,
"organisationid": org_id,
"groupids": group_ids,
"streamids":stream_ids,
"deployments": [locations],
"usermetadata": user_metadata
}
response = requests.request("PUT", url, headers=headers, json=payload)
response.raise_for_status()
print(platform_id, "Done")
Create a Location
location_id = "eratos-internal.location.hobart"
org_id = "eratos-internal"
lat = -25.0
lon = 140.0
elevation = 25 #Not required
#Senaps API PUT Request
url = f"https://senaps.eratos.com/api/sensor/v2/locations/{location_id}"
headers = {
'apikey': senaps_key
}
payload = {
{
"id": location_id,
"organisationid": org_id,
"geoJson": {
"type": "Point",
"coordinates": [lon, lat, elevation]
}
}
}
response = requests.request("PUT", url, headers=headers, json=payload)
response.raise_for_status()
print(platform_id, "Done")
Updated 8 days ago