I have a pre-request script that looks like:
const auth0PostRequest = {
url: 'https://burton.auth0.com/oauth/token',
method: 'POST',
header: 'Content-Type:application/json',
body: {
mode: 'raw',
raw: JSON.stringify({"client_id":"{{mgt_client_id}}",
"client_secret":"{{mgt_client_secret}}",
"audience":"{{mgt_auth0_audience}}",
"grant_type":"client_credentials"})
}
};
But when it runs I see that following request body in Postman Console.
{"client_id":"{{mgt_client_id}}","client_secret":"{{mgt_client_secret}}","audience":"{{mgt_auth0_audience}}","grant_type":"client_credentials"}
As can be seen, the script is expecting substitution of the variables between {{ }}