# JWT generator utility
Generate a set of headers, including a valid JWT, to be used in Postman or GraphQL playground. 

This is a clone of Raed's work https://github.com/theorchard/collab/tree/master/ratoui/jwt-generator but modified to work better for NR.

## Background
This script is intended to work with pre-existing service identities used in integration testing.
Details are here https://www.notion.so/How-to-configure-a-machine-to-have-a-dedicated-Auth0-M2M-Client-and-Automated-JWT-Token-Refresh-2e00d3e763ce497abaf6d2e9a0e947ff#13797177520f807aa780f364c2f21f69

## Installation
Install the dependencies
```
npm i
```

Copy the `.env.shadow` file to `.env`

## Run
### Set your aws credentials
You need that so you can retrieve the secrets from the secrets manager.
```
awsume prod
```
Then you can run the script
```
npm run generate-headers
```

