@interiot/node-red-contrib-fiware-sth

0.8.6 • Public • Published

The node fiware-sth provides information from FIWARE Short Time Historic (STH) - Comet.

Installation

Requirements:

  • node-red
  • docker

1- Install and run Orion, STH and mongodb with:

cd StackSTH
docker-compose up

2.1- Copy folder Fiware-sth in the node_modules directory (Windows C:\Users\%username%\.node-red\node_modules or linux ~/.node-red/node_modules) and install the dependencies:

cp ./Fiware-sth PATH/TO/NODE_MODULES
... node_modules directory ...
cd Fiware-sth
npm install

2.2- Run or restart node-red server

Usage

Add an atribute "entityID" with the id of entity to search

Example

Input data

{
    ...
  "entityID":"sala1"
    ...
}

Output data

{
  "contextResponses": [
    {
      "contextElement": {
        "attributes": [
          {
            "name": "temperatura",
            "values": [
              {
                "recvTime": "2017-03-20T13:55:06.492Z",
                "attrType": "Number",
                "attrValue": 14.3
              }
            ]
          }
        ],
        "id": "sala1",
        "isPattern": false,
        "type": "Sala"
      },
      "statusCode": {
        "code": "200",
        "reasonPhrase": "OK"
      }
    }
  ]
}

Todos

  • Make a node for aggregated time series context information
  • Improve refresh token system
  • Make login easier
  • Run tests

License

ASL 2.0 license

Readme

Keywords

none

Package Sidebar

Install

npm i @interiot/node-red-contrib-fiware-sth

Weekly Downloads

0

Version

0.8.6

License

Apache-2.0

Last publish

Collaborators

  • j.martinez
  • mallorente
  • enolgor