JellyFaaS Web Tokens
Before you can call out to a function you need a WebToken, in this case (like a JWT) a JellyFaaS webtoken.
These, like JWT's have an expiry time on then, usually around 24 hours.
Getting a token via the JellyFaaS website
-
Login to app.jellyfaas.com and navigate to your profile page.
-
Generate a token.
Getting a token via the API
To generate a JFWT (JellyFaaS Web Token) you need to call out to the following auth endpoint:
This needs an header set with your Secret Key (from you profile page HERE) called x-jf-apikey
set.
Request
For example (using curl):
curl --location 'https://api.jellyfaas.com/auth-service/v1/validate' --header 'x-jf-apikey: <my secret key>'
This will return the following json object :
The token is used in the next steps to call out to a function.
Copying the token into the copy buffer:
curl -sS --location '<https://api.jellyfaas.com/auth-service/v1/validate>' --header 'x-jf-apikey: <my secret key>' | jq -r '.token' |pbcopy