> For the complete documentation index, see [llms.txt](https://projectwerk.gitbook.io/project/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://projectwerk.gitbook.io/project/assignment/listener.md).

# Listener

the listener forwards the received data from MQTT to the backand with an HTTP post

## NodeJS

Node.js® is a JavaScript runtime built on [Chrome's V8 JavaScript engine](https://developers.google.com/v8/). Node.js uses an event-driven, non-blocking I/O model that makes it lightweight and efficient. Node.js' package ecosystem, [npm](https://www.npmjs.com/), is the largest ecosystem of open source libraries in the world.

## environment variables

When interacting with your server through a shell session, there are many pieces of information that your shell compiles to determine its behavior and access to resources. Some of these settings are contained within configuration settings and others are determined by user input.

One way that the shell keeps track of all of these settings and details is through an area it maintains called the **environment**. The environment is an area that the shell builds every time that it starts a session that contains variables that define system properties.

```
TTN_APPID=
TTN_ACCESSKEY=

HTTP_HOST=
HTTP_PORT=
HTTP_PATH=
HTTP_HTTP=

```

## &#x20;the application

![](https://2007275357-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LDLySMRFlYdWwoVZLq7%2F-LDh4gz8kh-kna-xMbHM%2F-LDhLHeWwyJk1K_Whrsf%2FScreen%20Shot%202018-05-29%20at%2021.21.12.png?alt=media\&token=324fceab-de18-426d-a268-1f426569bfe2)

node server.js
