Connection Service Overview


The connection service APIs provide management operations for products, devices, and commands. For more information on device management in EnOS, see Device Connectivity & Management Service.


The APIs in the connection service are some of the APIs EnOS provides that cover the core business processes of the system. For more information on EnOS APIs and the different APIs that EnOS provides, see About EnOS API.


For more information on how to invoke EnOS APIs, see Get Started with EnOS API.

Prerequisites


Ensure that you have read the limitations for the different modules. See Limitations.

API List


Refer to the table below for the list of APIs, and whether they can be used by EnOS Cloud and EnOS Edge.

Product


Operation Name Description URL EnOS Cloud EnOS Edge
Create Product Create a product /connect-service/v2.1/products?action=create ×
Delete Product Delete a product /connect-service/v2.1/products?action=delete ×
Get Product Get the details of a product via its productKey
  • V2.4: /connect-service/v2.4/products?action=get
  • Existing: /connect-service/v2.1/products?action=get
×
Search Product Search for products based on the search criteria
  • V2.4: /connect-service/v2.4/products?action=search
  • Existing: /connect-service/v2.1/products?action=search
×
Update Product Update a product /connect-service/v2.1/products?action=update ×

Device


Operation Name Description URL EnOS Cloud EnOS Edge
Create Device Create a device
  • V2.4: /connect-service/v2.4/devices?action=create
  • Existing: /connect-service/v2.1/devices?action=create
×
Batch Create Devices Batch create devices
  • V2.4: /connect-service/v2.4/devices?action=batchCreate
  • Existing: /connect-service/v2.0/devices?action=batchCreate
×
Delete Device Delete a device /connect-service/v2.1/devices?action=delete ×
Disable Device Disable a device /connect-service/v2.1/devices?action=disable ×
Enable Device Enable a device /connect-service/v2.1/devices?action=enable ×
Get Device Get the information of a device
  • V2.4: /connect-service/v2.4/devices?action=get
  • Existing: /connect-service/v2.1/devices?action=get
Replace Device Replace the deviceKey of a device without changing its assetId
  • V2.4: /connect-service/v2.4/devices?action=replaceDevice
  • Existing: /connect-service/v2.1/devices?action=replaceDevice
×
Search Device Search for devices based on the search criteria
  • V2.4: /connect-service/v2.4/devices?action=search
  • Existing: /connect-service/v2.1/devices?action=search
Update Device Update a device /connect-service/v2.1/devices?action=update ×
Get Device Statistics Get the device statistics of an organization or product /connect-service/v2.1/devices?action=getStats ×
Report Device Firmware Version Report the device firmware version /connect-service/v2.5/devices?action=reportFirmwareVersion ×
Modify Device Status Modify the device status /connect-service/v2.4/devices?action=modifyDeviceStatus ×

Device Group


Operation Name Description URL EnOS Cloud EnOS Edge
Add Device to Device Group Add devices to device groups /connect-service/v2.5/deviceGroups?action=addDeviceToDeviceGroup ×
Create Device Group Create device groups in batches /connect-service/v2.5/deviceGroups?action=createGroup ×
Delete Device Group Delete device groups /connect-service/v2.5/deviceGroups?action=deleteGroup ×
Get Device Group Get device groups /connect-service/v2.5/deviceGroups?action=getGroup ×
Remove Device from Device Group Remove devices from device froups /connect-service/v2.5/deviceGroups?action=removeDeviceFromDeviceGroup ×
Search Device by Device Group Serach devices by device groups /connect-service/v2.5/deviceGroups?action=searchDeviceByDeviceGroup ×
Search Device Group by Device Search device groups by devices /connect-service/v2.5/deviceGroups?action=searchDeviceGroupByDevice ×
Search Device Group Search device groups /connect-service/v2.5/deviceGroups?action=searchGroup?action=searchGroup ×
Update Device Group Update device groups /connect-service/v2.5/deviceGroups?action=updateGroup ×

Certificate


Operation Name Description URL EnOS Cloud EnOS Edge
Apply Certificate Apply for a certificate and bind it to a device /connect-service/v2.0/certificates?action=apply ×
Renew Certificate Update a certificate and bind it to a device /connect-service/v2.0/certificates?action=renew ×
Revoke Certificate Revoke a certificate bound to a device /connect-service/v2.0/certificates?action=revoke ×
List Certificate List the certificates bound to a device /connect-service/v2.0/certificates?action=list ×

Gateway and Sub-Device


Operation Name Description URL EnOS Cloud EnOS Edge
Add Sub-Device Add new sub-devices to the gateway device /connect-service/v2.1/device-topos?action=addSubDevice ×
Get Gateway Get the gateway information based on the specified sub-device
  • V2.4: /connect-service/v2.4/device-topos?action=getGateway
  • Existing: /connect-service/v2.1/device-topos?action=getGateway
×
Remove Sub-Device Remove sub-devices from the gateway /connect-service/v2.1/device-topos?action=removeSubDevice ×
Search Sub-Device Search for sub-devices under the specified gateway
  • V2.4: /connect-service/v2.4/device-topos?action=searchSubDevice
  • Existing: /connect-service/v2.1/device-topos?action=searchSubDevice
×

Device Data


Operation Name Description URL EnOS Cloud EnOS Edge
Cancel Command Cancel cached commands /connect-service/v2.1/commands?action=cancel ×
Get Command Get the details of a command /connect-service/v2.1/commands?action=get ×
Get Event Get the details of an event via eventId /connect-service/v2.1/events?action=get ×
Get Latest Measurement Points Obtain the latest measurement point data uploaded from a device /connect-service/v2.1/measurepoints?action=queryLatest
Invoke Service Service invocation for the device /connect-service/v2.1/commands?action=invokeService ×
Search Command Search for commands /connect-service/v2.1/commands?action=search ×
Search Event Search for events based on the search criteria /connect-service/v2.1/events?action=search ×
Set Measurement Point Measurement point setting for the device /connect-service/v2.1/commands?action=setMeasurepoint
Get File Get the information of a file /connect-service/v2.1/files?action=getFileInfo ×
Download File Download a file from a device /connect-service/v2.1/files?action=download ×
Delete File Delete a file from a device /connect-service/v2.1/files?action=delete ×
Create Command Jobs Create command jobs /connect-service/v2.5/commands?action=createJob ×
Search Command Jobs Search command jobs by filters /connect-service/v2.5/commands?action=searchJob ×
Get Command Jobs Search command job details /connect-service/v2.5/commands?action=getJob ×
Delete Command Jobs Delete command jobs /connect-service/v2.5/commands?action=deleteJob ×
Query Command Job Statistics Query the command job statistics /connect-service/v2.5/commands?action=queryStatistics ×
Get Command Tasks Get command tasks /connect-service//v2.5/commands?action=getTask ×
Search Command Tasks Serach the command task details, execution progress and statuses /connect-service/v2.5/commands?action=searchTask ×
Retry Command Task Retry command tasks /connect-service/v2.5/commands?action=retryTask ×
Cancel Command Tasks Cancel command tasks /connect-service/v2.5/commands?action=cancelTask ×

HTTP Message Integration


Operation Name Description URL EnOS Cloud EnOS Edge
Upload Attributes Upload the attribute data of a device, including file-type data /connect-service/v2.1/integration?action=postAttribute ×
Upload Events Upload the event data of a device, including file-type data /connect-service/v2.1/integration?action=postEvent ×
Upload Measurement Points Upload the measurement point data of a device, including file-type data /connect-service/v2.1/integration?action=postMeasurepoint

Firmware Management


Operation Name Description URL EnOS Cloud EnOS Edge
Create Firmware File Create a firmware file for a product /connect-service/v2.1/ota-firmwares?action=create ×
Get Firmware File Get the file of the specified firmware /connect-service/v2.1/ota-firmwares?action=get ×
List Device Current Firmware List the firmware versions of all devices under the specified product /connect-service/v2.1/ota-firmwares?action=listVersion ×
Search Firmware File Search for firmware files under an OU based on the search criteria /connect-service/v2.1/ota-firmwares?action=search ×
Search Device Upgrade Search for the firmware and upgrade status of the device based on the search criteria /connect-service/v2.1/ota-firmwares?action=searchDeviceUpgrade ×
Delete Firmware Delete a firmware /connect-service/v2.1/ota-firmwares?action=delete ×

Firmware OTA Upgrade Management


Operation Name Description URL EnOS Cloud EnOS Edge
Create OTA Job Create an OTA job for batch verification or upgrading /connect-service/v2.1/ota-jobs?action=create ×
Get OTA Job Get the details of an OTA job /connect-service/v2.1/ota-jobs?action=get ×
Search OTA Job Search for OTA jobs based on the search criteria /connect-service/v2.1/ota-jobs?action=search ×
Search OTA Task Search for OTA tasks based on the search criteria /connect-service/v2.1/ota-jobs?action=searchTask ×
Start OTA Job Start an OTA job /connect-service/v2.1/ota-jobs?action=start ×
Stop OTA Job Stop an OTA job /connect-service/v2.1/ota-jobs?action=stop ×
Delete OTA Job Delete an OTA job /connect-service/v2.1/ota-jobs?action=delete ×
Cancel OTA Task Cancel OTA tasks under the specified OTA job /connect-service/v2.1/ota-jobs?action=cancelTask ×
Retry OTA Task Retry OTA tasks under the specified OTA job /connect-service/v2.1/ota-jobs?action=retryTask ×
Download Firmware File Download firmware files /connect-service/v2.5/files?action=downloadFirmwareFile ×

API Editions


The following table lists the API services included in Connection Service Enterprise and Lightweight editions.

Category Enterprise Lightweight
Product
Device
Certificate
Gateway and Sub-Device
Device Data
HTTP Message Integration
Firmware Management
Firmware OTA Upgrade Management

Decrypting Product/Device Secret


Product/Device secrets obtained from V2.4 APIs are encrypted. For how to decrypt, see Decrypting Product/Device Secret.

SDK Samples


You can access the SDK samples for Connection Service on GitHub: