# JWT Library on Python for API

**URL:** <https://forum.inductiveautomation.com/t/jwt-library-on-python-for-api/36845>\
**Category:** Ignition\
**Created:** [July 18, 2020, 11:03am UTC](https://forum.inductiveautomation.com/t/jwt-library-on-python-for-api/36845 "2020-07-18T11:03:23Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Rendi.Yohanes](https://avatars.discourse-cdn.com/v4/letter/r/a183cd/32.png) [@Rendi.Yohanes](https://forum.inductiveautomation.com/u/Rendi.Yohanes)\
**Post date:** [July 18, 2020, 11:03am UTC](https://forum.inductiveautomation.com/t/jwt-library-on-python-for-api/36845/1 "2020-07-18T11:03:23Z")

</div>

Hi all, I need a little bit of help on JWT Library on Python for API.  
First of all, please pardon me if I use some wrong terminology, as my background is on PLC/SCADA and I’m relatively new to Python and scripting in general.

The requirement is as follows: I need to send some data (let’s say PLC tags) from Ignition to a third party web API using JWT, in a periodical manner. The JWT is to be encoded using SH256.

As of now, I am able to convert the PLC tags into JSON format in Ignition scripting. And I also have the secret key for encoding.

When looking at online resources, it seems that I need to do a “import JWT” and use the “jwt.encode()” function with the corresponding secret key and SH256. But, I can’t seem to find the JWT library in Ignition.

Can anybody kindly advise if some other library / function is available or do I need to import the JWT library manually to Ignition library folder?

Any help would me much appreciated!!

---

<div class="post-metadata">

**Author:** ![Kevin.Herron](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/kevin.herron/32/7259_2.png) [@Kevin.Herron](https://forum.inductiveautomation.com/u/Kevin.Herron)\
**Post date:** [July 18, 2020, 4:44pm UTC](https://forum.inductiveautomation.com/t/jwt-library-on-python-for-api/36845/2 "2020-07-18T16:44:22Z")

</div>

You’ll need to find a Python/Jython 2.7 compatible library that handles JWT and then add it to Ignition.

See “Importing 3rd Party Libraries” in [https://docs.inductiveautomation.com/display/DOC80/Libraries](https://docs.inductiveautomation.com/display/DOC80/Libraries)

---

<div class="post-metadata">

**Author:** ![rafael\_rodriguez](https://avatars.discourse-cdn.com/v4/letter/r/e480ec/32.png) [@rafael\_rodriguez](https://forum.inductiveautomation.com/u/rafael_rodriguez)\
**Post date:** [February 2, 2022, 6:53pm UTC](https://forum.inductiveautomation.com/t/jwt-library-on-python-for-api/36845/3 "2022-02-02T18:53:54Z")

</div>

Hello, I have exactly the same problem. Could you help me?

I need to import the JWT library to python ignition
