ThingWorx WebSocket-based Edge MicroServer (WS EMS) and Lua Script Resource (LSR) > REST Web Services Supported by WS EMS > AddEdgeThing
The AddEdgeThing service adds an edge device to the devices that are currently connected to the WS EMS.
Pass in TW_INFOTABLE that has one row and two columns. The row object must contain the following parameters:
The name of the device (thing) that you want to add. Keep in mind that the device must exist on the ThingWorx platform as a thing that was created with the RemoteThing thing template. For example: {"name":"NameOfThing"}
persist, which specifies whether the device should be added to the list of devices that are automatically bound to the corresponding thing on the ThingWorx platform. The format for this parameter is "persist": true | false.
This service returns an HTTP response only. If the operation was successful, it returns HTTP 200. Otherwise, it returns an HTTP error.
Here is an example of a REST call that adds an Edge thing:
AddEdgeThing{"name" : "acmeEdgeThing1"}"persist":true