# Workflow for auto importing devices from TTN

**URL:** <https://forums.losant.com/t/workflow-for-auto-importing-devices-from-ttn/4453>\
**Category:** Help\
**Tags:** workflow, devices\
**Created:** [April 8, 2022, 9:11pm UTC](https://forums.losant.com/t/workflow-for-auto-importing-devices-from-ttn/4453 "2022-04-08T21:11:31Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Paolo\_Proxy](https://avatars.discourse-cdn.com/v4/letter/p/b5ac83/32.png) [@Paolo\_Proxy](https://forums.losant.com/u/Paolo_Proxy)\
**Post date:** [April 8, 2022, 9:11pm UTC](https://forums.losant.com/t/workflow-for-auto-importing-devices-from-ttn/4453/1 "2022-04-08T21:11:31Z")

</div>

Hi there,  
we use TTN where we have a variety of Gateways and Applications (containing devices).  
If I do it manually it will take me months, so it needs to be via scripting/workflows.  
I want to import them into Losant with the corresponding Applications and Gateways + Devices.  
It sounds to me I will have to leverage all the API of TTN to import them via a Workflow into the corresponding entities.  
So I am asking whether somebody in the tech team or community has written a module I can re-use without going through the pain of doing it myself.  
Thanks!

---

<div class="post-metadata">

**Author:** ![Heath](https://sea1.discourse-cdn.com/flex015/user_avatar/forums.losant.com/heath/32/3036_2.png) [@Heath](https://forums.losant.com/u/Heath)\
**Post date:** [April 11, 2022, 2:32pm UTC](https://forums.losant.com/t/workflow-for-auto-importing-devices-from-ttn/4453/2 "2022-04-11T14:32:14Z")

</div>

Hey @Paolo_Proxy,

I don’t have anything to send over right now, but I will follow up with you if someone does pass something my way.

Just out of curiosity, are you using, or did you start from, the [TTN Application Template](https://docs.losant.com/templates/the-things-network/)? How are you ingesting data from TTN if not? With some additional context, I might be able to provide some guidance on how to build the workflow to automate this process.

Thank you,  
Heath

---

<div class="post-metadata">

**Author:** ![Paolo\_Proxy](https://avatars.discourse-cdn.com/v4/letter/p/b5ac83/32.png) [@Paolo\_Proxy](https://forums.losant.com/u/Paolo_Proxy)\
**Post date:** [April 11, 2022, 8:07pm UTC](https://forums.losant.com/t/workflow-for-auto-importing-devices-from-ttn/4453/3 "2022-04-11T20:07:07Z")

</div>

Hi there, yes I did see the TTN Application Template, but for example I would need to auto generate first all my devices via TTN APIs and add the attribute dev\_id automatically just to mention one task.

Yes all data is ingested via TTN right now, for future deployment I would also be interested in feeding my Lora gateway data directly into your Lorawan Server (but I couldn’t find an info is this already possible)?

Cheers.
