jwtgrant returns 504

Hi,

I have the following problem after trying to set up the web sdk.
Apart from errors in the tutorial, I encountered this:

image

I followed this tutorial: https://developer.kore.ai/docs/bots/sdks/kore-ai-web-sdk-tutorial/
I noticed that the endpoint described in the tutorial (http://localhost:3000/api/users/getJWT) is wrong and it should actually be http://localhost:3000/api/users/sts.

Anyhow, I get a valid jwt but when the bot tries to use the jwt to get it’s auth grant via bots.kore.ai/api/oAuth/token/jwtgrant I get a 504 Error.

Here’s the generated jwt: eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpYXQiOjE2MzY1NDc4MTg2NjIsImV4cCI6MTYzNjYzNDIxODY2MiwiYXVkIjoiaHR0cHM6Ly9pZHByb3h5LmtvcmUuY29tL2F1dGhvcml6ZSIsImlzcyI6ImNzLWIzMmNkYmY0LWE0NzgtNWIwZC1iZTY3LTNlNjZmNDQ3OTRiNCIsImlzQW5vbnltb3VzIjoidHJ1ZSJ9

I removed the signature for opsec reasons.

I have the widget sdk and web client channels enabled and the bot published.

Help would be appreciated!

While I’m here I have another question:
Is there an easy way to customize the chatwindow? E.g. color scheme, icons etc. for CI
I’ve worked with Power Virtual Agents in the past where you can easily change some style options while setting up the chat (see here).

Cheers,
Tobi

1 Like

Hello @tobias.daum :smiley:,

Welcome to Kore Community :clap:

With respect to JWT errors, we believe the JWT token is not generated accurately. Please follow the below post and try again with the recreated JWT. Note that when creating JWT - client secret is also required.

There are other JWT related posts that you can verify for the correct process.

For customizations to chatwindow, you can make changes to customTemplate.js and customTemplate.css files of the WebSDK. Further info can be found in our documentation: GitHub - Koredotcom/web-kore-sdk: web client sdk code

chatWindow.css can be taken as reference for the required customizations.

Hope this helps! Thank you for stopping by!!