Remote Interfaces in ThingWorx for eMessage Agents
Remote interfaces are used to define endpoints on a device to connect to when initiating remote sessions.
Device Remote Interfaces
The Axeda eMessage Agents support the transmission of CLI Terminal Interfaces and CLI Application Interfaces to the platform upon device registration. The eMessage Connector supports receipt and storage of this information, starting in release 1.2.0. The CLI Terminal Interfaces and CLI Application Interfaces can both be referred to as Remote Interfaces. These Remote Interfaces include the following information:
n — The name of the terminal or application interface to display to the user.
de — A description of the interface to be displayed to the user.
co — Connection information that is formatted as a series of connection types (''C" for connect), followed by a number that indicates the ports that are to be used.
* 
While examples of the two possible connection types, "C" for connect and "L" for listen are shown in the examples in this topic, ThingWorx supports only the "C" type. You cannot use a remote interface of type "L" with ThingWorx and the ThingWorx Remote Access Client (RAC).
lo — Launch options that should be passed to the launch page.
For example:
//Terminal Interface
<De ...>
<Dint>
<In n="interface name” de=”description” co=”C8080” lo=”launch options” />
<In n="name2" de="desc2” co=”L9090-9093" lo=”launch options” />
</Dint>
</De>
//Application Interface
<De ...>
<Dapp>
<In n=”application name” de=”description” co=”C8080L8081” lo=”launch options” />
<In n=”name2” de=”desc2” co=”L9090-9093” lo=”launch options” />
</Dapp>
</De>
ThingWorx Data Format
Remote Interfaces are stored as rows on the endpoints property of an Axeda eMessage agent Thing in ThingWorx. This property is of base type INFOTABLE.
In ThingWorx, the endpoints row consists of two fields:
name—Name of the Remote Interface
providerConfig—JSON field that contains the parsed connection string, launchOption, and description.
Storage on ThingWorx Platform
The AxedaBaseModel Thing Template in the Axeda Compatibility Extension (ACE) implements a Thing Shape, called RemoteAccessible, which contains an infotable property called endpoints. This property is updated with the contents of the Emessage Dapp and Dint elements. Unlike Axeda Platform, there is no distinction between Application and Terminal Interfaces. They are treated the same way and stored in the same infotable. The endpoints infotable is of Data Shape RemoteEndpoint. This Data Shape describes the tunneling capabilities and properties of a device. It has the following fields:
name—This STRING contains the name of this TunnelEndpoint.
providerConfig—This JSON object contains the custom configuration of the provider. The connectionInformation field of providerConfig that is a JSON array of fields modeled after the ConnectionInformation Data Shape. This Data Shape defines connection information for a RemoteEndpoint. It includes the type of connection and a range of ports available for the connection. The fields defined in this Data Shape are:
startPort—The lower bound on a range or ports (base type INTEGER.
endPort—The upper bound on a range of ports.
type—The type of connection available for the port, C for "Connects to". ThingWorx and the Remote Access Client (RAC) do not support the "L" type.
Here is an example of the storage of the endpoints property for an Axeda Thing in ThingWorx. In this example, one connection connects to port 9090 and another connection listens on ports in the range 9091 to 9093.
* 
The example below is accurate for the Axeda ACA. However, the "L" connection type will NOT work with ThingWorx and the Remote Access Client. Do NOT attempt to use the providerConfig shown below with both a "C" and an "L" connection type. Replace the "L" connection type with a "C" connection type and the appropriate port for your environment.
Field
Type
Value
name
STRING
The name of the interface.
providerConfig
JSON
{
"connectionInformation":[
{
"startPort":9090,
"type":"C"
},
{
"startPort":9091,
"type":"L",
"endPort":9093
}
],
"launchOption":"Launch Options",
"description":"Interface Description"
}
Was this helpful?