How to render parameters in url when using Build With Parameters Plugin

i was trying to automate the testing of an api which was successful in postman. Running the samething in Jenkins was also successful without being parameterized. To run it with parameters will enable me to run the same test in different environments: QA and UAT. i installed the Build With Parameters plugin which enables me to enter name of the parameter as env and its two values as QA and UAT. Then i tried to append the name of the parameter to the url of the environment: ${Env}. i tried other formats like β€œ${Env}”, $β€œ{Env}” but none of them work out as i received the consol message:

error: could not load environment
ENOENT: no such file or directory, open β€˜C:\Users\ALABI.jenkins\workspace\POSTMAN EXECUTION${Env}.postman_environment.json’

Please what is the proper way of rendering such parameter

see steps to reproduce in images

Please note: apply parameter name to url before saving at item 5

Windows environment variables are referenced via %var% so you might want to try

1 Like