Request ZWT token in OAUTH2 credential

I need to connect to an API that uses OAUTH2 authentication, and has been working fine for the last month.
However, it now requires JWT to be the encoding of the token to work.

in Postman, I got it working by adding this:

But I have no idea how I can do this in N8n… there are no fields in the OAUTH2 credential wizard to insert those values.

Thank you for any help


It looks like your topic is missing some important information. Could you provide the following if applicable.

  • n8n version:
  • Database (default: SQLite):
  • n8n EXECUTIONS_PROCESS setting (default: own, main):
  • Running n8n via (Docker, npm, n8n cloud, desktop app):
  • Operating system:
  • n8n version: 1.42.1
  • Database: SQLite
  • n8n EXECUTIONS_PROCESS setting own
  • Running n8n via Docker
  • Operating system: QNAP

Hey @Afonso_Costa,

Welcome to the community :tada:

Which API are you using? It feels odd to suddenly change an oauth option, Are they instead just moving to JWT instead of oauth?

It was an certaintly an odd change on their part…

I am trying to connect to the API
(it’s romania’s government invoice and transport documents control platform)

It specifically requires JWT + OAUTH2 authentication

Thanks for the help