Using ThingPark Location API
ThingPark Location provides developers with a comprehensive set of web-services based on the ThingPark DX framework. The following API are to be considered when interfacing with ThingPark Location.
Push locations to external application server
This section outlines the basic steps to configure ThingPark Location to send locations to external application server.
- The first step is to authenticate with ThingPark Location using your credentials. If you are using community platform, see here. For other platforms, see here. Once on swagger, click "Authorize".
- The next step will be to enter your credentials.
The client_id is DX-API-PREFIX/YOUR_LOGIN
The client_secret is your password.
DX-API Prefix is based on the platform where you created your account. If your account is on ThingPark Community, then the DX-API prefix is community-api as shown in the example below. For other platforms, visit here.
Once authenticated, you can access the ThingPark Location API documentation and swagger UI to interact with APIs.
- Goto Connector module and configure the URL of the external application server.
ThingPark Location will post JSON object ResolvedPosition to the external application server for the future positions sent by the tracker.
{
"deviceEUI" : "20635f028100003e",
"time" : "2022-09-02T08:04:25.731Z",
"customerId" : "100009247",
"modelCfg" : "1:TPX_ba3df8fb-bc93-45ee-aa0d-b2f873b9bbc6",
"dxProfileId" : "community-api",
"coordinates" : [ 103.924992, 1.3143296, 0.0 ],
"age" : 0,
"validityState" : "NEW",
"horizontalAccuracy" : 129,
"incomingSubscriberId" : "100009247",
....
}
Use Case | Example JSON Object | Object type |
---|---|---|
Example JSON geofenceAlarm object sent when entering Geofence | here | For more information on setting up Geofence, see ThingPark Location Introduction (Section: Setting up Geofencing) |
Example JSON geofenceAlarm object sent when leaving Geofence | here | For more information on setting up Geofence, see ThingPark Location Introduction (Section: Setting up Geofencing) |
Example JSON ResolvedTracker object sent when the tracker sends its configuration parameters | here | The tracker sends its configuration when either there is change of its configuration parameter by sending LoRaWAN downlink or when the parameter values are requested by sending device configuration downlink |
Example geofencingNotification JSON object sent when entering/exiting the different BLE geozones. | BLE Geozoning entry BLE Geozoning exit BLE Geozoning hazard BLE Geozoning safe | This JSON object is related to BLE Geozoning feature. For more details about BLE Geozoning feature, see BLE Geozoning and AN-011_BLE_geozoning |
Example TrackerAsAssetTracker JSON object which contains eventType object for the tracker events | Geolocation Start Event | This JSON object is sent when the tracker reports events. The geoloc_start event is configured in the tracker firmware by setting bit 6=0 in config_flags. |
Example TrackerAsAssetTracker JSON object which contains eventType object for the tracker events | Motion Start Event Motion End Event | This JSON object is sent when the tracker reports events. The motion_start and motion_end events are configured in the tracker firmware by setting bit 8=1 & bit 9=1 in config_flags. |
Example TrackerAsAssetTracker JSON object which contains eventType object for the tracker events | SoS Start Event SoS End Event | This JSON object is sent when the tracker reports events. The sos_start and sos_end events are sent when the tracker enters SoS mode. |
Example TrackerAsAssetTracker JSON object which contains messageType object for the tracker heartbeat message | Heartbeat | This JSON object is sent when the tracker reports heartbeat message. |
Example TrackerAsAssetTracker JSON object which contains messageType object for the tracker position message | BLE position GPS position GPS timeout LPGPS position LPGPS no position WiFi position | This JSON object is sent when the tracker reports position messages or Extended position messages. The filtered positions from the backend are in ResolvedPosition object |
Example TrackerAsAssetTracker JSON object which contains messageType object for the tracker Scan Collection messages | BLE Scan collection Eddystone BLE Scan collection MAC Address Wifi Scan collection | This JSON object is sent when the tracker reports Scan Collection messages. For more details about Scan Collection feature, see Scan Collection and AN-003_ScanCollection |
Example TrackerAsAssetTracker JSON object which contains messageType object for the tracker shock detection message | Shock detection | This JSON object is sent when the tracker reports shock detection message. |
Example TrackerAsAssetTracker JSON object which contains messageType object for the tracker shock detection message | Shutdown | This JSON object is sent when the tracker reports shutdown message. |
DX Admin API
DX Admin API provides a standard-based token management and administration features for the ThingPark DX API platform.
Useful links
DX Admin API | Resource |
---|---|
DX Admin Swagger UI | https://dx-api.thingpark.io/admin/latest/swagger-ui/index.html?shortUrl=tpdx-admin-api-contract.json |
DX Admin latest documentation | https://dx-api.thingpark.io/admin/latest/doc/index.html |
DX Location API
The purpose of this API is to provide the best experience for all developers who intend to interface their application with ThingPark Location features.
Modules
Module | Description |
---|---|
Binder module | API providing binder configuration and query capabilities on top of theThingPark Location solution.The Binder module has:
|
Tracker command module | Tracker command operations are used to send downlink commands to supported Abeeway trackers. |
Connector module | API providing connector configuration capabilities on top of the ThingPark Location solution.The Binder module has the northbound interface of ThingPark Location, usually interfacing with IoT application servers. |
Driver module | API providing ability to encode or decode Abeeway tracker payloads. |
Alarm configuration module | API providing operations to enable notifications on tracker parameters and configure geofences. |
Firmware Update module | API providing operations to retrieve the firmware binaries |
Key Management module | API providing operations to store the Keys for Operator interface configuration to integrate with LoRaWAN® Network servers |
Notification module | API providing operations to configure push notifications to be sent to the Abeeway Mobile APP |
Profile Management module | API providing operations to manage the profiles of Abeeway trackers |
Location Integration module | API providing operations to register/de-register the tracker to the Abeeway Mobile APP |
Useful links
You can find more information on using ThingPark Location API, ThingPark Location Training.
If you are using some other ThingPark Location platform, see ThingPark Location Platform URLs