79364194

Date: 2025-01-17 09:13:09
Score: 1.5
Natty:
Report link

I've resolved the issue now. There were two things I needed to consider: mikee's answer about needing to await the variable, and needing to parse the variable as JSON before I could use it in code.

The solution being:

let jwtSecret = await pm.vault.get("jwtSecret");
let jwtObject = JSON.parse(jwtSecret);
var signedJWTToken =  KJUR.jws.JWS.sign(null, header, data, jwtSecret);
Reasons:
  • Blacklisted phrase (0.5): I need
  • Has code block (-0.5):
  • Self-answer (0.5):
  • Low reputation (1):
Posted by: Magnus