How to resolve the issue:- java.lang.IllegalArgumentException: Invalid uri 'https://****.****.****.*****.***:9060/***/**/****/***/ReferenceError: "name" is not defined. (<refname>': escaped absolute path not valid

swapnilagrawal
Kilo Contributor

Hello All,

I have configured REST GET Method, its working fine when I'm Testing from REST Message GET method, but the same method when I called from workflow activity it giving me this error.

java.lang.IllegalArgumentException: Invalid uri 'https://***.****.****.*****.***:9060/**/***/**/**/ReferenceError: "name" is not defined. (<refname>': escaped absolute path not valid

find_real_file.png

Please guide to resolve the issue.

Thanks & Regards,

Swapnil Agrawal

10 REPLIES 10

Goran WitchDoc
ServiceNow Employee
ServiceNow Employee

Can you show more exactly the REST message.. It sound just like the error says. That you are using "name" and it isn't defined.



//Göran


Hi Goran,



Below is the screenshot for REST message Workflow activity, the same has been configured in rest messages, there it is working fine.



Here in variables I have used name = {current.variables.name} by doing this I'm pasing the value of variable name from RITM to this name variable.


find_real_file.png



Thanks


Swapnil


sergiu_panaite
ServiceNow Employee
ServiceNow Employee

Does your HTTPS URL includes path to a directory that contains spaces in the name?


I've seen cases where a path like below example caused same error (see the 'Project Documents' directory name):



'https://xxx/xxx/xxx/xxx/Project Documents/My_List.csv'



A workaround to that is to move the file to a directory with spaces in the name.



Regards,


Hi Sergiu,



No we don't use space in name, this name is unique Username which user chooses for him/her, the only condition is he should have "@" in his name(for example: swapnil@gmail.com or agr@gmail anything works fine.)




Thanks & Regards,


Swapnil