# Invalid device ID

**URL:** <https://forums.losant.com/t/invalid-device-id/645>\
**Category:** Help\
**Created:** [October 31, 2017, 4:35pm UTC](https://forums.losant.com/t/invalid-device-id/645 "2017-10-31T16:35:33Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Luke\_Vikas\_Vupputuri](https://avatars.discourse-cdn.com/v4/letter/l/c6cbf5/32.png) [@Luke\_Vikas\_Vupputuri](https://forums.losant.com/u/Luke_Vikas_Vupputuri)\
**Post date:** [October 31, 2017, 4:35pm UTC](https://forums.losant.com/t/invalid-device-id/645/1 "2017-10-31T16:35:33Z")

</div>

ValidationError  
Invalid device id:

I keep getting this error even though the device name in the payload is same as the device being used. The body is well structured too. Is there a reason for this error?  
I am using sigfox ready devices.

Thank you.

---

<div class="post-metadata">

**Author:** ![Brandon\_Cannaday](https://sea1.discourse-cdn.com/flex015/user_avatar/forums.losant.com/brandon_cannaday/32/14_2.png) [@Brandon\_Cannaday](https://forums.losant.com/u/Brandon_Cannaday)\
**Post date:** [November 2, 2017, 10:34pm UTC](https://forums.losant.com/t/invalid-device-id/645/2 "2017-11-02T22:34:46Z")

</div>

Hard to know based on the info provided. The first place to look is our Sigfox guide, which goes over connecting Sigfox devices to Losant.

> **[Collect, Monitor, and Visualize your Sigfox Data with Losant](https://www.losant.com/blog/collect-monitor-visualize-sigfox-data)**
>
> This guide demonstrates how to integrate Sigfox and Losant for data collection, monitoring, and visualization.

The main thing to realize is the Sigfox and Losant have their own device ids. So to connect Sigfox and Losant, you need to use [Losant device tags](https://docs.losant.com/devices/overview/#device-tags) to tag each device with their Sigfox ID. You can then lookup the Losant device based on the incoming Sigfox ID. The article above describes how to create this mapping.

---

<div class="post-metadata">

**Author:** ![Alan\_Chan](https://sea1.discourse-cdn.com/flex015/user_avatar/forums.losant.com/alan_chan/32/413_2.png) [@Alan\_Chan](https://forums.losant.com/u/Alan_Chan)\
**Post date:** [November 4, 2017, 12:06am UTC](https://forums.losant.com/t/invalid-device-id/645/3 "2017-11-04T00:06:18Z")

</div>

I did find out today that deviceId for Losant is based on a field inside their structure. After you create a Sigfox device like Brandon was saying, you can retrieve the device (Device: Get) based on the device tags, and if you check the box “Return tags as an object map instead of an array” and pass the object map then dump it into a debug you can see the fields that are returned in the object map. One of these fields returned is deviceId and it looks like a long hex string. You can then use that field in the Device State bubble.

---

<div class="post-metadata">

**Author:** ![Luke\_Vikas\_Vupputuri](https://avatars.discourse-cdn.com/v4/letter/l/c6cbf5/32.png) [@Luke\_Vikas\_Vupputuri](https://forums.losant.com/u/Luke_Vikas_Vupputuri)\
**Post date:** [November 4, 2017, 7:16pm UTC](https://forums.losant.com/t/invalid-device-id/645/4 "2017-11-04T19:16:11Z")

</div>

Thank you for the quick response.  
I have already gone through the guide and it helped a lot understand how it works.  
I will have to try it using object maps instead of an array as Alan said.  
I’m only facing this problem for certain messages one of my devices.
