API Parameters & Variables

Hi,

I have created a Rest WS object in Katalon. Seems to me working fine until I try to use it from a test script. I have a parameter ‘accountNumber’ that has a value of ${acctNum} which is defined on the variables tab. This all works when executing from the object.

When I reference the above request from a test script, I am getting an error:

Any idea what is happening here?

Thanks!

Matt

Capture1.PNG

Capture2.PNG

call of WS.request should look something like:

def responseData = WS.sendRequest(findTestObject('OR/WsObject',[('acctNum'): accountNumber]))
2 Likes

That worked…thanks!

1 Like

welcome

i have similiar test case, can this test case using data binding (excel) for testing the value ?
thank you

sure it can, however i need more info