Skip to Content

Multiple GET parameters in REST end point url

Feb 12 at 05:07 PM


avatar image
Former Member

I have a sychronous scenario with sender and receiver as REST adapter to GET employee details. Scenario description is send Global ID (GID) via REST url and receive employee details as response based on dynamice GID value. This is working fine .

Now the requirement is url can have either GID, firstname , Lastname or all of them. So with this case there is an error when one of the value GET variable is not available in source url and then endpoint url is not correct. Consider Source url with only lastname : https:/PI_HOST/RESTAdapter/endpoint service/?type=search&lastname=ebel Generic format of endpoint url : GET /endpoint service/?type=search&gid={gid}&firstname={firstname}&lastname={lastname} Expected when only lastname is given in source url : GET /endpoint service/?type=search&lastname=ebel Result : GET /endpoint service/?type=search&gid=%7Bgid%7D&firstname=%7Bfirstname%7D&lastname=ebel. So issue is unexpected characters in endpoint url which is not being processed at end system to provide response correctly

10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

1 Answer

Priyanka Anagani Feb 13 at 11:29 AM


In the REST sender communication channel Rest Resources tab, while defining the XI dynamic attribute, there is a checkbox called "optional". If you select that, the attribute will not be mandatory and even if its missing, it won't error out.


10 |10000 characters needed characters left characters exceeded