Device Types & Decoders
Learn how to create custom device types, write payload decoders, and activate them within your data flows.
If your IoT devices are not supported by KPN Things out of the box, you can easily integrate them by defining a custom Device Type and creating a Decoder to parse their incoming payloads.
Step 1: Manage Custom Device Types
Create a New Device Type
From the Things Creator menu, click All Device Types.
Click Add new Device Type.
Fill in the required details, such as Name, Description, and any specific properties.
Click Add Device Type to save.
Once created, this custom device type will immediately become available in the Things Manager when adding new devices to your projects.
Edit or Delete a Device Type
If you need to make changes, navigate to All Device Types, select the device type from the list, and click Edit or Delete on its details page.
Step 2: Create and Test a Decoder
Decoders translate raw, device-specific payload data into a structured format. You can create multiple decoders for a single device type.
Create a New Decoder
From the Things Creator menu, click All Decoders.
Click Add new Decoder.
Select your custom device type from the drop-down menu.
Enter a Name and Description for the decoder, then click Add Decoder.
Write and Test the Decoder Script
On the decoder details page, locate the Script section and click Create.
Write your JavaScript parsing logic in the provided editor.
To test your script, use the built-in test payload section. You can use the provided sample payloads or paste your own raw device payload.
Click Run script with test payload to review the output and logs.
Once your script is validating data correctly, click Save.
For advanced guidance on writing decoder logic, please refer to the DIY Decoder Scripts Documentation.
Edit or Delete a Decoder Script
To update a script, open the decoder's details page and click Edit. Make your adjustments and click Save. If you wish to remove the script entirely, click Delete within the edit dialog.
Step 3: Activate the Decoder in Your Flow
After creating your device type and writing its decoder, you must activate the decoder within your project's data flow using the Things Manager application.
Open the Things Manager and navigate to your project.
Select the specific Flow where your custom devices are active.
Click on Data Processing.
Locate your custom device type in the list and toggle on the decoder you wish to use.
Last updated
Was this helpful?
