Forum Discussion
osalonga
Occasional Contributor
To add to the info above, ID from /item/{id} is a template parameter. To summarize the question, how do we specify the mock service dispatch script/parameter if the service has a template parameter?
nmrao
8 years agoChampion Level 3
Hoping that you are using Script Dispatch.
Not tested, but give it a shot.
def id = mockRequest.path.split('/').last() log.info id
Then you can use condition send the respective response.
A sample:
Related Content
- 9 years ago
- 6 years ago
Recent Discussions
- 24 hours ago
- 6 days ago