cancel
Showing results for 
Search instead for 
Did you mean: 

Validating request parameter in VS request with datasource property

SOLVED
rahuldutta
Occasional Contributor

Validating request parameter in VS request with datasource property

Hi,

I want to validate the query parameter from the incoming request to my virtual service with an excel datasource property and then dispatch a response if they match. Can someone suggest how to that? If this would require script style of dispatching, then what is the code to validate that the query param is part of the propery values in the excel?

Please send me your remarks. Thanks!

 

Tags (1)
1 ACCEPTED SOLUTION

Accepted Solutions
TanyaYatskovska
Community Manager

Re: Validating request parameter in VS request with datasource property

Hi @rahuldutta,

 

As far as I understand, you'll need to write a custom script to make it possible. Please take a look at the following sample - I think it should help you:

A Dispatching script to get responses based on the values in Request Body

 

---------
Tanya Yatskovskaya
SmartBear Community and Education Manager

Did my reply answer your question? Give Kudos or Accept it as a Solution to help others. ⬇️⬇️⬇️

View solution in original post

1 REPLY 1
TanyaYatskovska
Community Manager

Re: Validating request parameter in VS request with datasource property

Hi @rahuldutta,

 

As far as I understand, you'll need to write a custom script to make it possible. Please take a look at the following sample - I think it should help you:

A Dispatching script to get responses based on the values in Request Body

 

---------
Tanya Yatskovskaya
SmartBear Community and Education Manager

Did my reply answer your question? Give Kudos or Accept it as a Solution to help others. ⬇️⬇️⬇️

View solution in original post

New Here?
Join us and watch the welcome video: