Forum Discussion

chathurad's avatar
chathurad
Contributor
6 years ago
Solved

How to pass schoolName parameter to this URL

https://a31k83hfp9.execute-api.us-east-1.abc.com/dev/school/detail/abc-xyz-institute-of-studies

 Above is a GET request which is available at the SWAGGERHUB.

I need to imposrt this to SOAPUI as a GET request and add different schoolNames to the last part of the URL.

But unfortunatly this URL is not geting school as a parameter like other GET requests.

 

As on the below image i cant add school name as a parameter on SOAPUI

  • When you use "New REST Service From URI" you should enter the parameters instead of a value, like this:

     

    https://a31k83hfp9.execute-api.us-east-1.abc.com/dev/school/detail/{schoolName}

    This will automatically create a parameter called "schoolName", then you can set a default value, and a different value for each Test Request Step.

     

    It's not too late to do that, just change the Resource to

    /dev/school/detail/{schoolName}

    You will be prompted for a default value, and the parameter will be added.

2 Replies

  • JHunt's avatar
    JHunt
    Community Hero

    When you use "New REST Service From URI" you should enter the parameters instead of a value, like this:

     

    https://a31k83hfp9.execute-api.us-east-1.abc.com/dev/school/detail/{schoolName}

    This will automatically create a parameter called "schoolName", then you can set a default value, and a different value for each Test Request Step.

     

    It's not too late to do that, just change the Resource to

    /dev/school/detail/{schoolName}

    You will be prompted for a default value, and the parameter will be added.