Devices
URI Definition
Method | URI and Fields | |||||||||||||||||||||||||||||||||||||||||||||||||
GET
| /iap/devs | |||||||||||||||||||||||||||||||||||||||||||||||||
Returns all devices that the current user is permitted to read.
See Query Parameters below for information on filtering and sorting the devices that are returned. Query Parameters
ExamplesGET /iap/devs/nc.0/if/*/*/*/*
Returns all properties of all datapoints of all block indices of all blocks within the interface of device with ID "nc.0".
GET /iap/devs/nc.0/if/Switch/*/nvoValue/value
Returns the value property of all nvoValue datapoints in any block index of block "Switch" within the interface of device with ID "nc.0", and so on.
https://localhost/iap/devs
https://localhost/iap/devs?sts=PROVISIONED&short=true
https://localhost/iap/devs?uid=00D07111EAC0
RESPONSE
[
{
"name": "00D07111EAC0",
"category": "EDGE",
"id": "2",
"latitude": 37.33959,
"longitude": -121.99081,
"capabilities": {
"replacement": {
},
"commissioning": {
"commissionMethod": "MANUAL"
}
},
"status": {
"state": "provisioned",
"health": "normal",
"connection": "connected",
"connectionStatusSince": "2019-01-11T15:27:52.994-08:00[America/Los_Angeles]",
"action": null,
"product": "LH-PM100E_6k",
"wasProvisioned": true
},
"scName": "segment",
"scId": "Ab93fcpn",
"scState": "provisioned",
"uid": "00D07111EAC0",
"protocol": "lon",
"typeId": 128,
"createdOnGlp": true,
"deviceTypeName": "LH-PM100E_S6k",
"gpsEnabled": false,
"installationDate": "2019-03-25"
}
] | ||||||||||||||||||||||||||||||||||||||||||||||||||
/iap/devs/{id}/count | ||||||||||||||||||||||||||||||||||||||||||||||||||
Returns count of devices according to specified parameters.
Query ParametersFor a full list of possible query parameters, see GET description for /iap/devs at the top of this page. Exampleshttps://localhost/iap/devs/*/count
https://localhost/iap/devs/*+health==DOWN/count
RESPONSE:
{
"value": 2
} | ||||||||||||||||||||||||||||||||||||||||||||||||||
/iap/devs/count | ||||||||||||||||||||||||||||||||||||||||||||||||||
Returns the number of devices available for the current user to get.
See Query Parameters at the bottom of this page for information on filtering and sorting the devices that are returned. Query ParametersFor a full list of possible query parameters, see GET description for /iap/devs at the top of this page. Success ResponseNumber of devices Examplehttps://localhost/iap/devs/count Sample Response
| ||||||||||||||||||||||||||||||||||||||||||||||||||
/iap/devs/grp/{id} | ||||||||||||||||||||||||||||||||||||||||||||||||||
Returns collection of devices that assigned on the specified group. By default only devices' coordinates will be returned. In order to return full device information flag coordinatesOnly need to be set to false. Path Parameter
Query Parameters
Success ResponseCollection of devices. Examplehttps://localhost/iap/devs/grp/574
RESPONSE:
[
{
"name": "LHP_sim10",
"category": "EDGE",
"id": "22",
"geozoneId": 88,
"geozoneName": "World",
"customerId": 81,
"latitude": 40.97999,
"longitude": -103.35928,
"capabilities": {
"replacement": {
},
"commissioning": {
"commissionMethod": "MANUAL"
}
},
"status": {
"state": "unprovisioned",
"action": null,
"wasProvisioned": false
},
"scName": "segment",
"scId": "Ab93fcpn",
"scState": "provisioned",
"uid": null,
"discoveryMethod": "manual",
"protocol": "lon",
"typeId": 128,
"createdOnGlp": false,
"deviceTypeName": "LH-PM100E_S6k",
"gpsLatitude": null,
"gpsLongitude": null,
"gpsDilution": null,
"gpsEnabled": false,
"installationDate": "2019-04-04",
"ownerMAC": "11-11-11-11-11-11",
"DID": "22"
},
{
"name": "LHP_sim1",
"category": "EDGE",
"id": "13",
"geozoneId": 88,
"geozoneName": "World",
"customerId": 81,
"latitude": 40.9799,
"longitude": -103.35937,
"capabilities": {
"replacement": {
},
"commissioning": {
"commissionMethod": "MANUAL"
}
},
"status": {
"state": "unprovisioned",
"action": null,
"wasProvisioned": false
},
"scName": "segment",
"scId": "Ab93fcpn",
"scState": "provisioned",
"uid": null,
"discoveryMethod": "manual",
"protocol": "lon",
"typeId": 128,
"createdOnGlp": false,
"deviceTypeName": "LH-PM100E_S6k",
"gpsLatitude": null,
"gpsLongitude": null,
"gpsDilution": null,
"gpsEnabled": false,
"installationDate": "2019-04-04",
"ownerMAC": "11-11-11-11-11-11",
"DID": "13"
}
] | ||||||||||||||||||||||||||||||||||||||||||||||||||
/iap/devs/gz/{id} | ||||||||||||||||||||||||||||||||||||||||||||||||||
Returns all devices assigned to the specified geozone, if the current user has permission to read devices from this geozone. If recursive set to true also returns devices assigned to geozones that are children to the specified geozone. Parameter
Query Parameters
Success ResponseCollection of devices. Examplehttps://localhost/iap/devs/gz/88
RESPONSE:
[
{
"name": "LHP_sim1",
"category": "EDGE",
"id": "13",
"geozoneId": 88,
"geozoneName": "World",
"customerId": 81,
"latitude": 40.9799,
"longitude": -103.35937,
"capabilities": {
"replacement": {
},
"commissioning": {
"commissionMethod": "MANUAL"
}
},
"status": {
"state": "unprovisioned",
"action": null,
"wasProvisioned": false
},
"scName": "segment",
"scId": "Ab93fcpn",
"scState": "provisioned",
"uid": null,
"discoveryMethod": "manual",
"protocol": "lon",
"typeId": 128,
"createdOnGlp": false,
"deviceTypeName": "LH-PM100E_S6k",
"gpsLatitude": null,
"gpsLongitude": null,
"gpsDilution": null,
"gpsEnabled": false,
"installationDate": "2019-04-04",
"ownerMAC": "11-11-11-11-11-11",
"DID": "13"
},
{
"name": "sc239",
"category": "SC",
"id": "2bzzwZs",
"geozoneId": 88,
"geozoneName": "World",
"customerId": 81,
"latitude": 58.447731,
"longitude": 55.5468788,
"capabilities": {
"replacement": {
}
},
"datapoints": {
"ScRtsmTiming": {
"datapointValueType": "SC_RTSM_TIMING",
"datapointValue": {
"interval": "QUARTER_HOUR",
"multiplier": 1
},
"name": "ScRtsmTiming"
},
"about": {
"datapointValueType": "SC_ABOUT",
"datapointValue": {
"product": "SmartServer IoT",
"model": "SmartServer",
"version": "3.30.057"
},
"name": "about"
},
"location": {
"datapointValueType": "LOCATION",
"datapointValue": {
"desc": "",
"lat": 58.447731,
"lng": 55.5468788,
"elevation": 0
},
"name": "location"
},
"ScScheduleAndClockUpdate": {
"datapointValueType": "SC_SCHEDULE_CLOCK_UPDATE",
"datapointValue": {
"sendsched": null,
"ncup": 6
},
"name": "ScScheduleAndClockUpdate"
},
"ScMessaging": {
"datapointValueType": "SC_MESSAGING",
"datapointValue": {
"retries": 4,
"rtimer": 500
},
"name": "ScMessaging"
}
},
"timezone": "America/Los_Angeles",
"rtsm": "2012-12-01T15:13:45-08:00[America/Los_Angeles]",
"firmwareVersion": "1.30.047",
"status": {
"state": "provisioned",
"health": "down",
"connection": "broken",
"connectionStatusSince": "2019-04-12T00:12:33.47-07:00[America/Los_Angeles]",
"action": null,
"pingTime": "2019-04-04T08:16:06"
},
"MACaddress": "00-0C-E3-74-4F-89",
"SID": "2bzzwZs"
}
] | ||||||||||||||||||||||||||||||||||||||||||||||||||
/iap/devs/ids | ||||||||||||||||||||||||||||||||||||||||||||||||||
Returns all device IDs that current user is permitted to read.
Query ParametersFor a full list of possible query parameters, see GET description for /iap/devs at the top of this page. Success ResponseCollection of device IDs. Examplehttps://localhost/iap/devs/ids?category=EDGE
RESPONSE:
[
"17",
"18",
"2",
"19",
"20",
"21",
"22",
"7",
"12",
"13",
"14",
"15",
"16"
] | ||||||||||||||||||||||||||||||||||||||||||||||||||
/iap/devs/lon/{id} | ||||||||||||||||||||||||||||||||||||||||||||||||||
Obtains current Onnet/Offnet mode for specific segment controller. Parameter
Success ResponseJSON with string value: “Onnet”/”Offnet” Examplehttps://localhost/iap/devs/lon/Ab93fcpn
RESPONSE:
{
"value": "Onnet"
} | ||||||||||||||||||||||||||||||||||||||||||||||||||
PUT | /iap/devs/delete | |||||||||||||||||||||||||||||||||||||||||||||||||
Deletes a collection of specified devices. Request BodyContains the collection of device IDs to delete. Success ResponseCollection of Device IDs of the removed devices. Examplehttps://localhost/iap/devs/delete
REQUEST BODY:
["31","33"]
RESPONSE:
[
"31",
"33"
] | ||||||||||||||||||||||||||||||||||||||||||||||||||
/iap/devs/listByIDs | ||||||||||||||||||||||||||||||||||||||||||||||||||
Returns a collection of devices for the specified IDs, if the current user has permission to read those devices. Throws an AuthorizationException otherwise. Query Parameter
Request BodyContains the collection of device IDs. Success ResponseCollection of devices. Examplehttps://localhost/iap/devs/listByIDs?skipDP=true
REQUEST BODY:
["34","35"]
RESPONSE:
[
{
"name": "TestDevice4",
"category": "EDGE",
"id": "34",
"geozoneId": 88,
"geozoneName": "World",
"customerId": 81,
"latitude": 63.54858,
"longitude": 102.65628,
"capabilities": {
"replacement": {
},
"commissioning": {
"commissionMethod": "MANUAL"
}
},
"status": {
"state": "unprovisioned",
"action": null,
"wasProvisioned": false
},
"scName": "segment",
"scId": "Ab93fcpn",
"scState": "provisioned",
"uid": null,
"discoveryMethod": "manual",
"protocol": "lon",
"typeId": 128,
"createdOnGlp": false,
"deviceTypeName": "LH-PM100E_S6k",
"gpsLatitude": null,
"gpsLongitude": null,
"gpsDilution": null,
"gpsEnabled": false,
"installationDate": "2019-04-15",
"ownerMAC": "11-11-11-11-11-11",
"DID": "34"
},
{
"name": "TestDevice5",
"category": "EDGE",
"id": "35",
"geozoneId": 88,
"geozoneName": "World",
"customerId": 81,
"latitude": 63.54859,
"longitude": 102.65629,
"capabilities": {
"replacement": {
},
"commissioning": {
"commissionMethod": "MANUAL"
}
},
"status": {
"state": "unprovisioned",
"action": null,
"wasProvisioned": false
},
"scName": "segment",
"scId": "Ab93fcpn",
"scState": "provisioned",
"uid": null,
"discoveryMethod": "manual",
"protocol": "lon",
"typeId": 128,
"createdOnGlp": false,
"deviceTypeName": "LH-PM100E_S6k",
"gpsLatitude": null,
"gpsLongitude": null,
"gpsDilution": null,
"gpsEnabled": false,
"installationDate": "2019-04-15",
"ownerMAC": "11-11-11-11-11-11",
"DID": "35"
}
] | ||||||||||||||||||||||||||||||||||||||||||||||||||
/iap/devs/exportByIDs | ||||||||||||||||||||||||||||||||||||||||||||||||||
Returns a CSV file with the specified devices, if the current user has permission to read those devices. Throws an AuthorizationException otherwise. Request BodyContains the collection of device IDs to export. Success ResponseA CSV file with collection of exported device IDs. Examplehttps://localhost/iap/devs/delete
REQUEST BODY:
["34","35"]
RESPONSE:
Application Octet Stream
CSV file with specified devices | ||||||||||||||||||||||||||||||||||||||||||||||||||
/iap/devs/{id}/unassign/floor | ||||||||||||||||||||||||||||||||||||||||||||||||||
Removes the floor assignment from the specified device. Throws an AuthorizationException if the current user doesn't have write permission on the specified device. Parameter
Request BodyContains the collection of device IDs to export. Success ResponseReturns the status of the performed operation. True in case of success and false otherwise. Examplehttps://localhost/iap/devs/13/unassign/floor
REQUEST BODY:
{"ID":"13"}
RESPONSE:
{
"value": true
} | ||||||||||||||||||||||||||||||||||||||||||||||||||
/iap/devs/{id}/assign/floor/{floorId} | ||||||||||||||||||||||||||||||||||||||||||||||||||
Assigns the specified device to the specified floor on the specified coordinates. Parameters
Request BodyContains the coordinates of the device inside floor. Success ResponseReturns the status of the performed operation. True in case of success and false otherwise. Examplehttps://localhost/iap/devs/13/assign/floor/1641
REQUEST BODY:
{"x":194.4375,"y":299}
RESPONSE:
{
"value": true
} | ||||||||||||||||||||||||||||||||||||||||||||||||||
/iap/devs/loadForAllDevices | ||||||||||||||||||||||||||||||||||||||||||||||||||
Updates the firmware for all devices that the current user is able to get. NOTE: Currently does not support embedded inner images. This means that the manifest file must contain a URL from which the inner image can be downloaded. This URL and credentials are passed to the edge servers. Request BodyA zip archive containing the valid manifest file. Success ResponseEmpty Examplehttps://localhost/iap/devs/loadForAllDevices
REQUEST HEADER:
Content-Type: multipart/form-data
REQUEST BODY:
------WebKitFormBoundaryLV4CHbZ9f2pGxCsP
Content-Disposition: form-data; name="metafile"; filename="ControlM_V4_29_type02_with_image.glpo"
Content-Type: application/octet-stream
------WebKitFormBoundaryLV4CHbZ9f2pGxCsP--
RESPONSE:
Empty | ||||||||||||||||||||||||||||||||||||||||||||||||||
/iap/devs/{id}/changeScTo/{scId} | ||||||||||||||||||||||||||||||||||||||||||||||||||
Changes the edge server of the specified device to another specified edge server. If the device is in a group, information about this group will be transferred to the new edge server. Returns information about edge device on which this operations was performed. Parameters
Success ResponseInformation about the edge device on which this operations was performed. Examplehttps://localhost/iap/devs/13/changeScTo/2bzzwZs
RESPONSE:
{
"name": "LHP_sim1",
"category": "EDGE",
"id": "13",
"geozoneId": 88,
"geozoneName": "World",
"customerId": 81,
"latitude": 40.9799,
"longitude": -103.35937,
"capabilities": {
"replacement": {
},
"commissioning": {
"commissionMethod": "MANUAL"
}
},
"status": {
"state": "unprovisioned",
"action": null,
"wasProvisioned": false
},
"scName": "sc239",
"scId": "2bzzwZs",
"scState": "provisioned",
"uid": null,
"discoveryMethod": "manual",
"protocol": "lon",
"typeId": 128,
"createdOnGlp": false,
"deviceTypeName": "LH-PM100E_S6k",
"gpsLatitude": null,
"gpsLongitude": null,
"gpsDilution": null,
"gpsEnabled": false,
"installationDate": "2019-04-04",
"ownerMAC": "00-0C-E3-74-4F-89",
"DID": "13"
} | ||||||||||||||||||||||||||||||||||||||||||||||||||
/iap/devs/updateProperties | ||||||||||||||||||||||||||||||||||||||||||||||||||
Updates the specified device's properties. Throws an AuthorizationException if the current user does not have WRITE permission on this device. Request BodyContains the information with which the device is updated. Success ResponseInformation about the updated device. Examplehttps://localhost/iap/devs/updateProperties
REQUEST BODY:
{
"id":"13",
"name":"LHP_sim1",
"latitude":5.61599,
"longitude":24.60938,
"category":"EDGE",
"scId":"2bzzwZs",
"capabilities":{
"replacement":{},
"commissioning":{
"commissionMethod":"MANUAL"
}
},
"protocol":"lon",
"scState":"provisioned",
"scName":"sc239",
"uid":"3334ffdd3212",
"typeId":128,
"gpsLatitude":null,
"gpsLongitude":null,
"gpsDilution":null,
"installationDate":"2019-04-04",
"geozoneId":88,
"customerId":81,
"gpsEnabled":false,
"geozoneName":"World",
"ownerMAC":"00-0C-E3-74-4F-89",
"discoveryMethod":"manual",
"DID":"13",
"createdOnGlp":false
}
RESPONSE:
{
"name": "LHP_sim1",
"category": "EDGE",
"id": "13",
"geozoneId": 88,
"geozoneName": "World",
"customerId": 81,
"latitude": 5.61599,
"longitude": 24.60938,
"capabilities": {
"replacement": {
},
"commissioning": {
"commissionMethod": "MANUAL"
}
},
"status": {
"state": "unprovisioned",
"action": null,
"wasProvisioned": false
},
"scName": "sc239",
"scId": "2bzzwZs",
"scState": "provisioned",
"uid": "3334ffdd3212",
"discoveryMethod": "manual",
"protocol": "lon",
"typeId": 128,
"createdOnGlp": false,
"deviceTypeName": "LH-PM100E_S6k",
"gpsLatitude": null,
"gpsLongitude": null,
"gpsDilution": null,
"gpsEnabled": false,
"installationDate": "2019-04-04",
"ownerMAC": "00-0C-E3-74-4F-89",
"DID": "13"
} | ||||||||||||||||||||||||||||||||||||||||||||||||||
/iap/devs/dpTypeNames | ||||||||||||||||||||||||||||||||||||||||||||||||||
Returns datapoint types and names for datapoints that have set monitoring/logging settings (dla rules). Applied only to datapoints with scalar types. Request BodyContains the collection of Device IDs. Query Parameter
Success ResponseCollection of datapoint types and names. Examplehttps://localhost/iap/devs/dpTypeNames?extended=false
REQUEST BODY:
["2"]
RESPONSE:
[
{
"typeId": "SNVT_elec_kwh_l",
"name": "nvoEPpos"
},
{
"typeId": "SNVT_count",
"name": "nviPassword"
}
] | ||||||||||||||||||||||||||||||||||||||||||||||||||
/iap/devs/lon/onnet | ||||||||||||||||||||||||||||||||||||||||||||||||||
Sets the specified edge servers to the Onnet mode. If the received list of device IDs is empty then the operation will be performed on all edge servers the user has access to. Request BodyList of edge servers to set mode to on. Success ResponseEmpty. Examplehttps://localhost/iap/devs/lon/onnet
REQUEST BODY:
["Ab93fcpn"]
RESPONSE:
Empty | ||||||||||||||||||||||||||||||||||||||||||||||||||
/iap/devs/lon/offnet | ||||||||||||||||||||||||||||||||||||||||||||||||||
Sets the specified edge server to the Offnet mode. If the received list of DIDs is empty then the operation will be performed on all edge servers the user has access to. Request BodyList of edge servers to set mode to off. Success ResponseEmpty. Examplehttps://localhost/iap/devs/lon/offnet
REQUEST BODY:
["Ab93fcpn"]
RESPONSE:
Empty | ||||||||||||||||||||||||||||||||||||||||||||||||||
/iap/devs/{id}/tags/{tag_param} | ||||||||||||||||||||||||||||||||||||||||||||||||||
Updates all tags that match the provided filters with the provided value. Parameters
Query ParametersFor a full list of possible query parameters, see GET description for /iap/devs at the top of this page. PayloadNew tag value. Success Response204 No Content response code. Examplehttps://localhost/iap/devs/*/tags/*
https://localhost/iap/devs/7/tags/*
https://localhost/iap/devs/*+health==DOWN/tags/*+tag.name==tag1
PAYLOAD:
new tag value
RESPONSE:
204 No Content | ||||||||||||||||||||||||||||||||||||||||||||||||||
POST | /iap/devs | |||||||||||||||||||||||||||||||||||||||||||||||||
Creates a new device in the CMS. The device property must be set to false. Throws ValidationException if the received device information does not pass the validation. The Geozone of the new device is calculated using the device’s latitude and longitude. Returns information about the successfully created device. Request BodyContains the information from which the new device will be created. Success ResponseThe successfully created device. Examplehttps://localhost/iap/devs
REQUEST BODY:
{
"latitude":58.44773,
"longitude":75.9375,
"name":"Test Device",
"category":"EDGE",
"customerId":81,
"status":{},
"uid":"00D07111EA6B",
"discoveryMethod":"manual",
"ownerMAC":"11-11-11-11-11-11",
"scId":"Ab93fcpn",
"protocol":"lon",
"typeId":128
}
RESPONSE:
{
"name": "Test Device",
"category": "EDGE",
"id": "25",
"geozoneId": 88,
"geozoneName": "World",
"customerId": 81,
"latitude": 58.44773,
"longitude": 75.9375,
"capabilities": {
"replacement": {
},
"commissioning": {
"commissionMethod": "MANUAL"
}
},
"status": {
"state": "unprovisioned",
"action": null,
"wasProvisioned": false
},
"scName": "segment",
"scId": "Ab93fcpn",
"scState": "provisioned",
"uid": "00D07111EA6B",
"discoveryMethod": "manual",
"protocol": "lon",
"typeId": 128,
"createdOnGlp": false,
"deviceTypeName": "LH-PM100E_S6k",
"gpsLatitude": null,
"gpsLongitude": null,
"gpsDilution": null,
"gpsEnabled": false,
"installationDate": "2019-04-15",
"ownerMAC": "11-11-11-11-11-11",
"DID": "25"
} | ||||||||||||||||||||||||||||||||||||||||||||||||||
/iap/devs/bulk | ||||||||||||||||||||||||||||||||||||||||||||||||||
Creates new devices of bulk in CMS. Request Bodyinformation about the devices to be created in CMS. Success ResponseList of successfully created devices. Examplehttps://localhost/iap/devs/bulk
REQUEST BODY:
{
"namePrefix":"TestDevice",
"count":5,
"from":1,
"deviceTemplate":{
"category":"EDGE",
"customerId":81,
"latitude":63.54855,
"longitude":102.65625,
"status":{},
"discoveryMethod":"manual",
"ownerMAC":"11-11-11-11-11-11",
"scId":"Ab93fcpn",
"protocol":"lon",
"typeId":128
}
}
RESPONSE:
[
{
"name": "TestDevice4",
"category": "EDGE",
"id": "34",
"geozoneId": 88,
"geozoneName": "World",
"customerId": 81,
"latitude": 63.54858,
"longitude": 102.65628,
"capabilities": {
"replacement": {
},
"commissioning": {
"commissionMethod": "MANUAL"
}
},
"status": {
"state": "unprovisioned",
"action": null,
"wasProvisioned": false
},
"scName": "segment",
"scId": "Ab93fcpn",
"scState": "provisioned",
"uid": null,
"discoveryMethod": "manual",
"protocol": "lon",
"typeId": 128,
"createdOnGlp": false,
"deviceTypeName": "LH-PM100E_S6k",
"gpsLatitude": null,
"gpsLongitude": null,
"gpsDilution": null,
"gpsEnabled": false,
"installationDate": "2019-04-15",
"ownerMAC": "11-11-11-11-11-11",
"DID": "34"
},
{
"name": "TestDevice5",
"category": "EDGE",
"id": "35",
"geozoneId": 88,
"geozoneName": "World",
"customerId": 81,
"latitude": 63.54859,
"longitude": 102.65629,
"capabilities": {
"replacement": {
},
"commissioning": {
"commissionMethod": "MANUAL"
}
},
"status": {
"state": "unprovisioned",
"action": null,
"wasProvisioned": false
},
"scName": "segment",
"scId": "Ab93fcpn",
"scState": "provisioned",
"uid": null,
"discoveryMethod": "manual",
"protocol": "lon",
"typeId": 128,
"createdOnGlp": false,
"deviceTypeName": "LH-PM100E_S6k",
"gpsLatitude": null,
"gpsLongitude": null,
"gpsDilution": null,
"gpsEnabled": false,
"installationDate": "2019-04-15",
"ownerMAC": "11-11-11-11-11-11",
"DID": "35"
},
{
"name": "TestDevice1",
"category": "EDGE",
"id": "31",
"geozoneId": 88,
"geozoneName": "World",
"customerId": 81,
"latitude": 63.54855,
"longitude": 102.65625,
"capabilities": {
"replacement": {
},
"commissioning": {
"commissionMethod": "MANUAL"
}
},
"status": {
"state": "unprovisioned",
"action": null,
"wasProvisioned": false
},
"scName": "segment",
"scId": "Ab93fcpn",
"scState": "provisioned",
"uid": null,
"discoveryMethod": "manual",
"protocol": "lon",
"typeId": 128,
"createdOnGlp": false,
"deviceTypeName": "LH-PM100E_S6k",
"gpsLatitude": null,
"gpsLongitude": null,
"gpsDilution": null,
"gpsEnabled": false,
"installationDate": "2019-04-15",
"ownerMAC": "11-11-11-11-11-11",
"DID": "31"
},
{
"name": "TestDevice2",
"category": "EDGE",
"id": "32",
"geozoneId": 88,
"geozoneName": "World",
"customerId": 81,
"latitude": 63.54856,
"longitude": 102.65626,
"capabilities": {
"replacement": {
},
"commissioning": {
"commissionMethod": "MANUAL"
}
},
"status": {
"state": "unprovisioned",
"action": null,
"wasProvisioned": false
},
"scName": "segment",
"scId": "Ab93fcpn",
"scState": "provisioned",
"uid": null,
"discoveryMethod": "manual",
"protocol": "lon",
"typeId": 128,
"createdOnGlp": false,
"deviceTypeName": "LH-PM100E_S6k",
"gpsLatitude": null,
"gpsLongitude": null,
"gpsDilution": null,
"gpsEnabled": false,
"installationDate": "2019-04-15",
"ownerMAC": "11-11-11-11-11-11",
"DID": "32"
},
{
"name": "TestDevice3",
"category": "EDGE",
"id": "33",
"geozoneId": 88,
"geozoneName": "World",
"customerId": 81,
"latitude": 63.54857,
"longitude": 102.65627,
"capabilities": {
"replacement": {
},
"commissioning": {
"commissionMethod": "MANUAL"
}
},
"status": {
"state": "unprovisioned",
"action": null,
"wasProvisioned": false
},
"scName": "segment",
"scId": "Ab93fcpn",
"scState": "provisioned",
"uid": null,
"discoveryMethod": "manual",
"protocol": "lon",
"typeId": 128,
"createdOnGlp": false,
"deviceTypeName": "LH-PM100E_S6k",
"gpsLatitude": null,
"gpsLongitude": null,
"gpsDilution": null,
"gpsEnabled": false,
"installationDate": "2019-04-15",
"ownerMAC": "11-11-11-11-11-11",
"DID": "33"
}
] | ||||||||||||||||||||||||||||||||||||||||||||||||||
/iap/devs/create | ||||||||||||||||||||||||||||||||||||||||||||||||||
Creates multiple devices in the CMS. Throws a ValidationException if the received device information has not passed the validation. The geozone of the new devices is calculated by the device's latitude and longitude. Query Parameters
Success ResponseSuccessfully created devices. Examplehttps://localhost/iap/devs/create?prefix=device&from=1
REQUEST BODY:
[{
"latitude": 37.38481,
"longitude": -121.9848,
"name": "dev_1",
"category": "EDGE",
"status": {},
"discoveryMethod": "manual",
"uid": "123457",
"ownerMAC": "00-00-00-00-00-00",
"scId": "1",
"segmentPK": 1,
"protocol": "lon",
"typeId": 103
},
{
"latitude": 37.38481,
"longitude": -121.9848,
"name": "dev_2",
"category": "EDGE",
"status": {},
"discoveryMethod": "manual",
"uid": "123459",
"ownerMAC": "00-00-00-00-00-00",
"scId": "1",
"segmentPK": 1,
"protocol": "lon",
"typeId": 103
}]
RESPONSE:
[
{
"name": "dev_1",
"category": "EDGE",
"id": 12,
"geozoneId": 32,
"geozoneName": "World",
"customerId": 31,
"latitude": 37.38481,
"longitude": -121.9848,
"capabilities": {
"replacement": {
},
"commissioning": {
"commissionMethod": "MANUAL"
}
},
"groupName": [
],
"status": {
"state": "unprovisioned",
"action": null,
"wasProvisioned": false
},
"tags": [
],
"scName": "segment",
"segmentPK": 3,
"scId": "1",
"scState": "unprovisioned",
"uid": "123457",
"discoveryMethod": "manual",
"protocol": "lon",
"typeId": 103,
"createdOnGlp": false,
"deviceTypeName": "1U Headend",
"gpsLatitude": null,
"gpsLongitude": null,
"gpsDilution": null,
"gpsEnabled": false,
"installationDate": "2019-10-24",
"ownerMAC": "00-00-00-00-00-00",
"DID": "12"
},
{
"name": "dev_2",
"category": "EDGE",
"id": 13,
"geozoneId": 32,
"geozoneName": "World",
"customerId": 31,
"latitude": 37.38481,
"longitude": -121.9848,
"capabilities": {
"replacement": {
},
"commissioning": {
"commissionMethod": "MANUAL"
}
},
"groupName": [
],
"status": {
"state": "unprovisioned",
"action": null,
"wasProvisioned": false
},
"tags": [
],
"scName": "segment",
"segmentPK": 3,
"scId": "1",
"scState": "unprovisioned",
"uid": "123459",
"discoveryMethod": "manual",
"protocol": "lon",
"typeId": 103,
"createdOnGlp": false,
"deviceTypeName": "1U Headend",
"gpsLatitude": null,
"gpsLongitude": null,
"gpsDilution": null,
"gpsEnabled": false,
"installationDate": "2019-10-24",
"ownerMAC": "00-00-00-00-00-00",
"DID": "13"
}
] | ||||||||||||||||||||||||||||||||||||||||||||||||||
/iap/devs/floor/{id} | ||||||||||||||||||||||||||||||||||||||||||||||||||
Creates a new device on the specified floor. Throws ValidationException if the received device information hasn't pass the validation. Parameter
Request BodyInformation used to create the new device. Success ResponseList of successfully created devices. Examplehttps://localhost/iap/devs/floor/1641
REQUEST BODY:
{
"latitude":37.3847,
"longitude":-121.98507,
"floorCoordinates":{
"floorId":1641,
"x":100,
"y":427
},
"name":"Floor Test Device Second",
"category":"EDGE",
"customerId":81,
"status":{},
"uid":"1555",
"discoveryMethod":"manual",
"ownerMAC":"11-11-11-11-11-11",
"scId":"Ab93fcpn",
"protocol":"lon",
"typeId":129
}
RESPONSE:
{
"name": "Test Device",
"category": "EDGE",
"id": "25",
"geozoneId": 88,
"geozoneName": "World",
"customerId": 81,
"latitude": 58.44773,
"longitude": 75.9375,
"capabilities": {
"replacement": {
},
"commissioning": {
"commissionMethod": "MANUAL"
}
},
"status": {
"state": "unprovisioned",
"action": null,
"wasProvisioned": false
},
"scName": "segment",
"scId": "Ab93fcpn",
"scState": "provisioned",
"uid": "00D07111EA6B",
"discoveryMethod": "manual",
"protocol": "lon",
"typeId": 128,
"createdOnGlp": false,
"deviceTypeName": "LH-PM100E_S6k",
"gpsLatitude": null,
"gpsLongitude": null,
"gpsDilution": null,
"gpsEnabled": false,
"installationDate": "2019-04-15",
"ownerMAC": "11-11-11-11-11-11",
"DID": "25"
} | ||||||||||||||||||||||||||||||||||||||||||||||||||
/iap/devs/import | ||||||||||||||||||||||||||||||||||||||||||||||||||
Imports devices to the CMS from a CSV file. Request BodyThe CSV file containing the list of devices to be imported. Success ResponseCollection of imported devices Example of CSV File
Examplehttps://localhost/iap/devs/import
REQUEST HEADER:
Content-Type: multipart/form-data
REQUEST BODY:
------WebKitFormBoundaryNvCyJBh56B2oBkBw
Content-Disposition: form-data; name="file"; filename="import_devices.csv"
Content-Type: application/vnd.ms-excel
------WebKitFormBoundaryNvCyJBh56B2oBkBw--
RESPONSE:
[
{
"name": "ImportedDevice4",
"category": "EDGE",
"id": "37",
"geozoneId": 88,
"geozoneName": "World",
"customerId": 81,
"latitude": 63.54858,
"longitude": 102.65628,
"capabilities": {
"replacement": {
},
"commissioning": {
"commissionMethod": "MANUAL"
}
},
"status": {
"state": "unprovisioned",
"action": null,
"wasProvisioned": false
},
"scName": "segment",
"scId": "Ab93fcpn",
"scState": "provisioned",
"uid": "1234567890",
"discoveryMethod": "manual",
"protocol": "lon",
"typeId": 128,
"createdOnGlp": false,
"deviceTypeName": "LH-PM100E_S6k",
"gpsLatitude": null,
"gpsLongitude": null,
"gpsDilution": null,
"gpsEnabled": false,
"installationDate": "2019-04-15",
"ownerMAC": "11-11-11-11-11-11",
"DID": "37"
},
{
"name": "ImportedDevice5",
"category": "EDGE",
"id": "38",
"geozoneId": 88,
"geozoneName": "World",
"customerId": 81,
"latitude": 63.54859,
"longitude": 102.65629,
"capabilities": {
"replacement": {
},
"commissioning": {
"commissionMethod": "MANUAL"
}
},
"status": {
"state": "unprovisioned",
"action": null,
"wasProvisioned": false
},
"scName": "segment",
"scId": "Ab93fcpn",
"scState": "provisioned",
"uid": "0987654321",
"discoveryMethod": "manual",
"protocol": "lon",
"typeId": 128,
"createdOnGlp": false,
"deviceTypeName": "LH-PM100E_S6k",
"gpsLatitude": null,
"gpsLongitude": null,
"gpsDilution": null,
"gpsEnabled": false,
"installationDate": "2019-04-15",
"ownerMAC": "11-11-11-11-11-11",
"DID": "38"
}
] | ||||||||||||||||||||||||||||||||||||||||||||||||||
/iap/devs/{param}/tags | ||||||||||||||||||||||||||||||||||||||||||||||||||
Apple's provided tags to every device that matches the filters. Arguments
Success response204 No Content response code Example
| ||||||||||||||||||||||||||||||||||||||||||||||||||
DELETE | /iap/devs/{id} | |||||||||||||||||||||||||||||||||||||||||||||||||
Deletes the specified device from the CMS. Throws AuthorizationException if the user doesn't have a permission to delete the specified device. Throws ValidatorException if device cannot be deleted for some reason. Arguments
Success response Status of performed operation. True in case of success and false otherwise. Example
| ||||||||||||||||||||||||||||||||||||||||||||||||||
/iap/devs/{id}/tags/{tag_param} | ||||||||||||||||||||||||||||||||||||||||||||||||||
Deletes all tags that match provided filters. Arguments
Success response204 No Content response code. Query ParametersFor a full list of possible query parameters, see GET description for /iap/devs at the top of this table. Examples
|
Query Parameters
You can add query parameters to the end of the /iap/devs URI, following a '?' character. You can specify multiple parameters by separating each parameter with an '&' character. For example, /iap/devs?model=PM820&gzid=87 matches all PM820 meters in geozone ID 87.
Each query parameter has the form <name>=<value>, where each value can be specified as a single string value or a simple wildcard by specifying a single asterisk (“*”) as the value.
For more information, see Queries and Parameters.