Identity Handling

In order to integrate AirTrace infrastructure with your devices, you need first to understand how the identity generation and linking process works

Identities can only be generated by IoT System Integrators. As such, generation and linking of identities may be conducted only by this role in the platform. You will need a token bearer issued at login and to belong to this role (IoT System Integrator). Make sure to have this ready once you handle this.

Identity creation

In order to create an identity for the device you want to insert into the platform, you need to issue the following API call:

  • primary_identifier corresponds to the string that contains the unique identifier of the physical device you are deploying. For example, you might decide to use an IMEI to uniquely identify your device in the physical network.

  • id_sensor defines the unique identification number corresponding to the IoT device whose identity you are assigning. NOTE: in order to know the id_sensor of your device in database, you can visit Sensors for more information.

Identity linking

Once the identity has been generated for the first time, you will need to assign it programmatically or via UI to the specific sensorspot that holds the instance of the sensor that will be linked to this identity. There are actually two ways to assign the identity just created:

Identity linking via project, deployment and spot setup

Remember that each sensorspot must be found under a project_id, for a deployment_id and a sensorspot. The specific API call that must be used is the following:

  • id represents the identification number of the project where this sensor is located.

  • id_deployment identifies the number of the deployment inside the project for which his sensor will operate.

  • id_spot is the representation of the physical location where this sensor is to be located

  • id_sensor represents the identification number of the sensor that will be linked to this identity.

  • id_identity holds the identifying integer in database of the identifier that will represent the device in the platform and that will link it to the physical world.

Identity linking via plain project and sensor-project setup

Assigns an identity to a sensor in a plain project

POST https://api.airtrace.io/v1/plain/{id_project}/sensorproject/{id_sensor_project}/identities

Path Parameters

Name
Type
Description

id_project*

String

id of the plain project containing the sensor

id_sensor_project*

String

id of the sensor-project relationship the identity will be assigned to

Request Body

Name
Type
Description

id_identity*

String

id of the previously created identity which will be assigned to the specified sensor

  • id_project represents the identification number of the project where this sensor is located.

  • id_sensor_project represents the identification number of the sensor-project relationship that will be linked to this identity.

  • id_identity holds the identifying integer in database of the identifier that will represent the device in the platform and that will link it to the physical world.

Identity linking by default

This option bypasses the need to generate the project, deployment and spot instances, just need to inject id_sensor and id_identity from Identity creation:

  • id_sensor represents the identification number of the sensor that will be linked to this identity.

  • id_identity holds the identifying integer in database of the identifier that will represent the device in the platform and that will link it to the physical world.

Last updated