> For the complete documentation index, see [llms.txt](https://docs.kpnthings.com/kpn-things/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.kpnthings.com/kpn-things/building-blocks/destinations/thingsboard.md).

# ThingsBoard

This page describes how to configure a Destination in KPN Things to send your data to the ThingsBoard cloud platform

## KPN Things: Configure a ThingsBoard destination

### Name

Give your ThingsBoard Destination a name and optionally a description.

* **Destination name** (required) - the administrative name of your Destination.

  Technical name: `name`

  Example value: *Tenant X*
* **Description** - an administrative description of your Destination.

  Technical name: `description`

  Example value: *Tenant with Materieelbeheer application*

### Connection details

First you need to create a ThingsBoard Cloud account (Professional Edition) on <https://thingsboard.io>. \
Then follow the instructions below to create an integration in your ThingsBoard account. Keep your KPN Things Destination configuration screen open, as you will need to copy information from and to it later.

***

## ThingsBoard: Create an integration

Log in to your ThingsBoard account and go to *Integrations center* > *Integrations.* \
There, add a new integration (by clicking the "+"-sign) and follow the steps below.

#### 1. Basic settings

In the first step, enter the following information.

* **Integration type** (required)\
  Select *HTTP* as the integration type.
* **Name** (required)\
  Enter a descriptive name, anything you like, such as `KPN Things integration`.

Click *Next*.

#### 2. Uplink data converter

Select *Create new uplink data converter* and enter a descriptive name, such as `KPN Things converter`.

Next, replace the example code with the following code:

```
// KPN Things converter code for ThingsBoard
// (Change at you own risk ;-) 

return decodeToJson(payload);
```

Click *Next*.

#### 3. Downlink data converter

Skip this step. Yes, by clicking the *Skip* button ;-).

#### 4. Connection

In this step, you need to copy/paste information back and forth. So pay attention, please.

* **HTTP endpoint URL**\
  Copy the *HTTP endpoint URL* from ThingsBoard into the KPN Things Destination configuration.
* **Enable security (Headers filter)**\
  In ThingsBoard, switch the toggle *Enable security (Headers filter)* to on.
* **Add a set of headers**\
  Click *Add* to reveal a set of input fields.
* **Configure the Header and Value pair**\
  Go back to the KPN Things Destination configuration screen, and click the *Generate* button next to the *Security header* fields. This will generate a value for the *X-Things-Secret* header.\
  Copy/paste both the Header and generated Value to the corresponding fields in ThingsBoard.\
  Then, press *Add* the save new integration in ThingsBoard.

Lastly, go back to the KPN Things Destination configuration screen and press the *Add ThingsBoard destination* button to save the new destination in KPN Things.&#x20;

Now you are finished and good to go!


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.kpnthings.com/kpn-things/building-blocks/destinations/thingsboard.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
