EMS EdgeModules Resource
Go Up to EMS Administrative API
The EMS database stores data about the registered EMS EdgeModules in the EMS Server. You can access this information by using the registered EdgeModules Resource.
You can use the EMS EdgeModules resource to register, unregister or modify an EMS EdgeModule and its resources in your EMS Server.
- Note: Use the TEMSClientAPI component to register, unregister, update, or retrieve the data info of an EMS EdgeModules from the EMS Server.
Contents
- 1 EdgeModules Resource Endpoints
- 2 GetModules Endpoint
- 3 GetModule Endpoint
- 4 GetModulesFields Endpoint
- 5 GetResources Endpoint
- 6 GetModuleResources Endpoint
- 7 GetResourcesFields Endpoint
- 8 GetModuleResource Endpoint
- 9 RegisterModule Endpoint
- 10 RegisterModuleResource Endpoint
- 11 UpdateModule Endpoint
- 12 UpdateModuleResource Endpoint
- 13 UnregisterModule Endpoint
- 14 UnregisterModuleResource Endpoint
- 15 GetResourceEndpoint Endpoint
- 16 GetResourceEndpointItem Endpoint
- 17 PutResourceEndpoint Endpoint
- 18 PutResourceEndpointItem Endpoint
- 19 PostResourceEndpoint Endpoint
- 20 PostResourceEndpointItem Endpoint
- 21 PatchResourceEndpoint Endpoint
- 22 PatchResourceEndpointItem Endpoint
- 23 DeleteResourceEndpoint Endpoint
- 24 DeleteResourceEndpointItem Endpoint
- 25 EMS EdgeModules Fields
- 26 See Also
EdgeModules Resource Endpoints
EdgeModules Resource exposes the following EMS Resource Endpoints:
Endpoint Method Name | Resource Suffix | HTTP Request Type | Use |
---|---|---|---|
GetModules |
-- |
HTTP GET |
To retrieve all data from the EdgeModules Resource. |
GetModule |
|
HTTP GET |
To retrieve all data from an EdgeModule. |
GetModulesFields |
|
HTTP GET |
To retrieve the field names of all EMS EdgeModules. |
GetResources |
|
HTTP GET |
To retrieve all data from the resources of all EdgeModules. |
GetModuleResources |
|
HTTP GET |
To retrieve all data from the resources of an EdgeModule. |
GetResourcesFields |
|
HTTP GET |
To retrieve the field names of all resources of the EMS EdgeModules. |
GetModuleResource |
|
HTTP GET |
To retrieve all data from a resource of an EdgeModule. |
RegisterModule |
-- |
HTTP POST |
To add a new EMS EdgeModule to the EMS database. |
RegisterModuleResource |
|
HTTP POST |
To register a new resource from an EMS EdgeModule. |
UpdateModule |
|
HTTP PUT |
To update the data of an existing EMS EdgeModule. |
UpdateModuleResource |
|
HTTP PUT |
To update the data of an existing resource from an EMS EdgeModule. |
UnregisterModule |
|
HTTP DELETE |
To delete an existing EMS EdgeModule. |
UnregisterModuleResource |
|
HTTP DELETE |
To delete the data of an existing resource from an EMS EdgeModule. |
GetResourceEndpoint |
|
HTTP GET |
To get the data from the |
GetResourceEndpointItem |
|
HTTP GET |
To retrieve the data of a specific endpoint from an EMS EdgeModule resource. |
PutResourceEndpoint |
|
HTTP PUT |
To update the data from the resource endpoint from an existing EMS EdgeModule. |
PutResourceEndpointItem |
|
HTTP PUT |
To update the data of a specific endpoint from an EMS EdgeModule resource. |
PostResourceEndpoint |
|
HTTP POST |
To add new data to the resource endpoint from an existing EMS EdgeModule. |
PostResourceEndpointItem |
|
HTTP POST |
To add new data of a specific endpoint from an EMS EdgeModule resource. |
PatchResourceEndpoint |
|
HTTP PATCH |
To request a set of changes in the data of the resource endpoint from an existing EMS EdgeModule. |
PatchResourceEndpointItem |
|
HTTP PATCH |
To request a set of changes in the data of a specific endpoint from an EMS EdgeModule resource. |
DeleteResourceEndpoint |
|
HTTP DELETE |
To delete the data of the resource endpoint from an existing EMS EdgeModule. |
DeleteResourceEndpointItem |
|
HTTP DELETE |
To delete the data of a specific endpoint from an EMS EdgeModule resource. |
GetModules Endpoint
Returns a list of EMS EdgeModules data.
Use the QueryModules method, or the TBackendQuery components and the EdgeModule resource to retrieve the list of EMS EdgeModules.
If successful, the response from the EMS server provides a list of all EMS EdgeModules with details about each one of them.
- modulename
- _id
- protocol
- protocolprops (port and host)
- _meta (creator, created date and updated date fields)
- Custom fields (optional)
Example Response
This is an example response:
[
{
"modulename": "WinEdge1",
"_id": "34C977F1-4DCE-4412-ACE8-35339CEE7282",
"protocol": "http",
"protocolprops": "{\"port\":8082,\"host\":\"localhost\"}",
"_meta": {
"creator": "00000000-0000-0000-0000-000000000000",
"created": "2015-08-12T14:57:19.000Z"
}
},
{
"modulename": "WinEdge2",
"_id": "5B2A78B8-2599-433F-956D-720A12FFCD0B",
"protocol": "http",
"protocolprops": "{\"port\":8081,\"host\":\"localhost\"}",
"_meta": {
"creator": "00000000-0000-0000-0000-000000000000",
"created": "2015-08-13T13:54:18.000Z"
}
}
]
GetModule Endpoint
It returns the data of a specified EMS EdgeModule.
Your request must provide the following field:
- _id
Use the RetrieveModule method, or the TBackendQuery component and the EdgeModule Resource to retrieve its data.
If successful, the response from the EMS server provides an EMS EdgeModule with the following details:
- modulename
- _id
- protocol
- protocolprops (port and host)
- _meta (creator, created date and updated date fields)
- Custom fields (optional)
Example Response
This is an example response for the module "5B2A78B8-2599-433F-956D-720A12FFCD0B":
{
"modulename": "WinEdge2",
"_id": "5B2A78B8-2599-433F-956D-720A12FFCD0B",
"protocol": "http",
"protocolprops": "{\"port\":8081,\"host\":\"localhost\"}",
"_meta": {
"creator": "00000000-0000-0000-0000-000000000000",
"created": "2015-08-13T13:54:18.000Z"
}
}
GetModulesFields Endpoint
Retrieves the field names of all EMS EdgeModules from the EMS database.
Use the RetrieveModulesFields method to retrieve the fields of an EMS EdgeModule.
If successful, the response from the EMS server provides all the field names of the EMS EdgeModules.
- modulename
- _id
- protocol
- protocolprops
- _meta (creator, created and updated fields)
Example Response
This is an example response:
[
{
"name": "modulename"
},
{
"name": "_id"
},
{
"name": "protocol"
},
{
"name": "protocolprops"
},
{
"name": "_meta",
"fields": [
{
"name": "creator"
},
{
"name": "created"
},
{
"name": "updated"
}
]
}
]
GetResources Endpoint
Returns a list of resources of all EMS EdgeModules.
Use the QueryModuleResources method, or the TBackendQuery component and the EdgeModule resource to retrieve the list of resources from the EMS EdgeModules.
If successful, the response from the EMS server provides a list of resources of all EMS EdgeModules with details about each one of them.
- resourcename
- modulename
- moduleid
- _meta (creator, created date and updated date fields)
- Custom fields (optional)
Example Response
This is an example response:
[
{
"resourcename": "version",
"modulename": "WinEdge1",
"moduleid": "34C977F1-4DCE-4412-ACE8-35339CEE7282",
"_meta": {
"creator": "00000000-0000-0000-0000-000000000000",
"created": "2015-08-12T14:57:19.000Z"
}
},
{
"resourcename": "Measurements",
"modulename": "WinEdge1",
"moduleid": "34C977F1-4DCE-4412-ACE8-35339CEE7282",
"_meta": {
"creator": "00000000-0000-0000-0000-000000000000",
"created": "2015-08-12T14:57:19.000Z"
}
},
{
"resourcename": "version",
"modulename": "WinEdge2",
"moduleid": "5B2A78B8-2599-433F-956D-720A12FFCD0B",
"_meta": {
"creator": "00000000-0000-0000-0000-000000000000",
"created": "2015-08-13T13:54:18.000Z"
}
},
{
"resourcename": "Measurements",
"modulename": "WinEdge2",
"moduleid": "5B2A78B8-2599-433F-956D-720A12FFCD0B",
"_meta": {
"creator": "00000000-0000-0000-0000-000000000000",
"created": "2015-08-13T13:54:18.000Z"
}
}
]
GetModuleResources Endpoint
Returns a list of resources data for a given EMS EdgeModule.
Use the QueryModuleResource method, or the TBackendQuery component and the EdgeModule resource to retrieve the list of resources from an EMS EdgeModule.
If successful, the response from the EMS server provides a list of all resources of an EMS EdgeModule with details about each one of them.
- resourcename
- modulename
- moduleid
- _meta (creator, created date and updated date fields)
- Custom fields (optional)
Example Response
This is an example response for the module "5B2A78B8-2599-433F-956D-720A12FFCD0B":
[
{
"resourcename": "version",
"modulename": "WinEdge2",
"moduleid": "5B2A78B8-2599-433F-956D-720A12FFCD0B",
"_meta": {
"creator": "00000000-0000-0000-0000-000000000000",
"created": "2015-08-13T13:54:18.000Z"
}
},
{
"resourcename": "Measurements",
"modulename": "WinEdge2",
"moduleid": "5B2A78B8-2599-433F-956D-720A12FFCD0B",
"_meta": {
"creator": "00000000-0000-0000-0000-000000000000",
"created": "2015-08-13T13:54:18.000Z"
}
}
]
GetResourcesFields Endpoint
Retrieves the field names of all resources of all EMS EdgeModules from the EMS database.
Use the RetrieveModuleResourcesFields method to retrieve the fields of the resources from the EMS EdgeModules.
If successful, the response from the EMS server provides all the field names of resources from the EMS EdgeModules.
- resourcename
- modulename
- moduleid
- _meta (creator, created and updated fields)
- users
Example Response
This is an example response:
[
{
"name": "resourcename"
},
{
"name": "modulename"
},
{
"name": "moduleid"
},
{
"name": "_meta",
"fields": [
{
"name": "creator"
},
{
"name": "created"
},
{
"name": "updated"
}
]
}
]
GetModuleResource Endpoint
Returns the data of a given resource for an EMS EdgeModule.
Use the RetrieveModuleResource method, or the TBackendQuery component and the EdgeModule resource to retrieve the data of a resource from an EMS EdgeModule.
If successful, the response from the EMS server provides with all the data from resources of an EMS EdgeModule with details about each one of them.
- resourcename
- modulename
- moduleid
- _meta (creator, created date and updated date fields)
- Custom fields (optional)
Example Response
This is an example response for the module "5B2A78B8-2599-433F-956D-720A12FFCD0B" and the "version" resource:
{
"resourcename": "version",
"modulename": "WinEdge2",
"moduleid": "5B2A78B8-2599-433F-956D-720A12FFCD0B",
"_meta": {
"creator": "00000000-0000-0000-0000-000000000000",
"created": "2015-08-13T13:54:18.000Z"
}
}
RegisterModule Endpoint
Registers the given EMS EdgeModule in the EMS Server.
Your request must provide the following fields:
- modulename
- protocol
- protocolprops (port and host)
Use the RegisterModule method, or the TBackendQuery component and the EdgeModule resource to register a new EMS EdgeModule in the EMS Server.
RegisterModuleResource Endpoint
Registers a new resource in the EMS EdgeModule of the EMS Server.
UpdateModule Endpoint
Updates an existing EMS EdgeModule in the EMS Server.
Your request must provide the following field:
- modulename
Use the UpdateModule method to update the data from an existing EMS EdgeModule in the EMS Server.
UpdateModuleResource Endpoint
Registers an existing resource from an EMS EdgeModule in the EMS Server. Your request must provide the following fields:
- moduleid
- resourcename
Use the UpdateModuleResource method to update the resource data from an existing EdgeModule in the EMS Server.
UnregisterModule Endpoint
Deletes and unregisters an existing EMS EdgeModule in the EMS Server.
Your request must provide the following fields:
- moduleid
Use the UnregisterModule method to delete the data from an existing EMS EdgeModule in the EMS Server.
UnregisterModuleResource Endpoint
Deletes and unregisters the existing resource from an EMS EdgeModule in the EMS Server. Your request must provide the following fields:
- moduleid
- resourcename
Use the UnregisterModuleResource method to delete the resource data from an existing EdgeModule in the EMS Server.
GetResourceEndpoint Endpoint
Returns the data from the GET
endpoint from an EMS EdgeModule resource.
Example Response
This is an example response for the WinEdge1 module and the Measurements resource:
[
{
"device": "heartrate",
"time": "2015-08-17T15:53:07.075Z",
"data": {
"bpm": 68
}
},
{
"device": "bloodpressure",
"time": "2015-08-17T15:54:59.015Z",
"data": {
"systolic": 115,
"diastolic": 77
}
}
]
GetResourceEndpointItem Endpoint
Returns the data from a specific GET
endpoint (specified by the {item}
resource suffix) from an EMS EdgeModule resource.
Example Response
This is an example response for the WinEdge1 module, the Measurements resource, and the detailed
resource suffix:
[
{
"device": "heartrate",
"time": "2015-08-17T15:53:07.075Z",
"data": {
"bpm": {
"last": 68,
"mean": 69.9354838709677,
"stddev": 1.38889605732917
}
}
},
{
"device": "bloodpressure",
"time": "2015-08-17T15:54:59.015Z",
"data": {
"diastolic": {
"last": 77,
"mean": 76.875,
"stddev": 1.64208056179609
},
"systolic": {
"last": 115,
"mean": 117.125,
"stddev": 1.64208056179609
}
}
}
]
PutResourceEndpoint Endpoint
Updates the data from the resource endpoint from an existing EMS EdgeModule.
Your request must provide the following fields:
- modulename
- resourcename
PutResourceEndpointItem Endpoint
Updates the data of a specific endpoint (specified by the {item}
resource suffix) from an EMS EdgeModule resource.
Your request must provide the following fields:
- modulename
- resourcename
- Resource Suffix
PostResourceEndpoint Endpoint
Adds new data to the resource endpoint from an existing EMS EdgeModule.
Your request must provide the following fields:
- modulename
- resourcename
PostResourceEndpointItem Endpoint
Adds new data to a specific endpoint (specified by the {item}
resource suffix) from an EMS EdgeModule resource.
Your request must provide the following fields:
- modulename
- resourcename
- Resource Suffix
PatchResourceEndpoint Endpoint
Requests a set of changes in the data of the resource endpoint from an existing EMS EdgeModule.
Your request must provide the following fields:
- modulename
- resourcename
PatchResourceEndpointItem Endpoint
Requests a set of changes in the data of a specific endpoint (specified by the {item}
resource suffix) from an EMS EdgeModule resource.
Your request must provide the following fields:
- modulename
- resourcename
- Resource Suffix
DeleteResourceEndpoint Endpoint
Deletes the data of the resource endpoint from an existing EMS EdgeModule.
Your request must provide the following fields:
- modulename
- resourcename
DeleteResourceEndpointItem Endpoint
Deletes the data of a specific endpoint (specified by the {item}
resource suffix) from an EMS EdgeModule resource
Your request must provide the following fields:
- modulename
- resourcename
- Resource Suffix
EMS EdgeModules Fields
EdgeModules resource in EMS request and responses may include any combination of the following fields:
Item | Example | Description |
---|---|---|
"modulename"
|
"WinEdge1"
|
EMS EdgeModule name in the EMS database. |
"_id"
|
"34C977F1-4DCE-4412-ACE8-35339CEE7282"
|
Unique EMS EdgeModule identifier in the EMS database. |
"protocol"
|
"http"
|
Protocol name that is used for communication between the EMS EdgeModule and the EMS Server. |
"protocolprops"
|
"{
\"port\":8082,
\"host\":\"localhost\"}"
|
|
"resourcename"
|
"version"
|
Name of the resources that extend the EMS EdgeModule functionality. |
"moduleid"
|
"34C977F1-4DCE-4412-ACE8-35339CEE7282"
|
Unique EMS EdgeModule identifier ( |
"_meta"
|
{
"creator": "00000000-0000-0000-0000-000000000001",
"created": "2014-08-20T11:08:56.000Z",
"updated": "2014-08-20T11:09:56.000Z"
}
|
|
Custom fields |
"myCustomField": "My Custom Field description"
|
Additional stored information for the EMS EdgeModule. |