Replies: 3 comments 3 replies
-
@adri1g Could you provide more details ? The variables are defined in the environment and get automatically resolved before making the request. In the URL that you shared "https://passport.{{host}}:{{port}}/3dpassport/login?service=https://space.{{host}}:{{port}}/3dspace", You will have define the |
Beta Was this translation helpful? Give feedback.
-
This is how I have solved it for the url so far, maybe it will help:
|
Beta Was this translation helpful? Give feedback.
-
This is how I solved it:
And the pre-request script looks like: const { v4: uuidv4 } = require('uuid');
const user_id = uuidv4()
bru.setEnvVar('user_id', user_id); // we need it for future requests
req.setUrl(req.getUrl().replace("$randomUserId", user_id)) |
Beta Was this translation helpful? Give feedback.
-
Hello community,
How can I automatically resolve variables from url, body or headers when I get them a pre or post request script using following APIs : req.getUrl(), req.getBody(), req.getHeaders().
Here an example for url : https://passport.{{host}}:{{port}}/3dpassport/login?service=https://space.{{host}}:{{port}}/3dspace
Thanks for your help,
Adrien
Beta Was this translation helpful? Give feedback.
All reactions