Note: the port 49987 depends on the device service.
URL Call by ID
For the one by ID, EdgeX provides the following REST API to get device and command ID
Note: localhost is replaced by the physical device IP.
In the above example, for Advantech-IPSM90-01 device
deviceId is 5cb809a79f8fc20001ddad32 and
Battery_Temperature’s commandId is 5cb809a79f8fc20001ddace8.
Replace "edgex-core-command" with physical device IP (for example 172.16.8.87) and use web browser to send the following command to get Advantech-IPSM90-01’s Battery_Temperature.
Examples
Get temperature from Advantech-IPSM90-01 by device ID
Get temperature from Advantech-IPSM90-01 by device name
Response
HTTP response code
Success Response:
Error Response:
Success Content Example (GET)
device field: the specified device name
name: the specified command name
value: returned value for the specified device and command
Verify Device Service APIs
There are two ways to verify device service APIs or RESTful APIs, cURL tool or Postman tool.
Example: verify the API to get temperature from Advantech-IPSM90-01 by device name
cURL
The following example use curl tool to set Battery_AlertStatus to 1