Emil Fjellstroem

09/06/2023, 9:17 AM
Morning, I’m using the standalone version of Wiremock and I’m trying to use the response-template for
. My json looks like this 👇
Copy code
  "request": {
    "method": "POST",
    "urlPattern": "/oauth/token"
  "response": {
    "status": 200,
    "transformers": [
    "body": "{{{jwt sub='jonsmith'}}}"
But I’m receiving a 500 👇
Copy code
Error 500 inline@10512a5a:1:3: could not find helper:
		{{{jwt sub='jonsmith'}}}
Is the jwt function only available on cloud? Thanks, Emil

Oleg Nenashev

09/06/2023, 9:30 AM
Yes, it looks like so after looking into the code. For WireMock open source, there is an extension you may try, but its response templating syntax is different

Emil Fjellstroem

09/06/2023, 9:33 AM
I might be wrong here but this only extracts the contents of the jwt and doesn’t create one like what I’d assume this does?