Skip to Content
0

What is the use of Dynamic Attribute in a Rest Channel Adapter in PO?

Sep 18, 2017 at 01:29 AM

70

avatar image
Former Member

Hi Masters, im working with Rest Services in PO, but i dont understand what is the use of dynamic attribute in the tab Rest Resources, as you can see in the next image:

I found that configuration on a channel, but I do not know what it does.

Can you please help me to understand what is the use of "id_part", and if I want to test my interface using a dynamic attribute, how would I do it?, to test i use postman or soapui, but i dont know how test when i have a dynamic attribute.

Thanks

id-part.png (20.8 kB)
10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

2 Answers

avatar image
Former Member Oct 31, 2017 at 07:35 AM
2

above shared blog clear your doubts.

consider you expose any back end data as rest service, for example get operation. You would allow client to send some inputs to serve them. like you ask purchase order number get details, you will ask client to send the po number. in xml based interfaces ie with soap, you will do this by adding ponumber field in the request structure. but in the rest, get operation you don't have option to send payload(request). you will only call url in rest service for get operation and get the result as response.

now how would you pass the input using url.

http://yourhost:443/RestAdapter/getorderDetails/{ordernumber}

so you add fields/variables/attributes/elements in the url itself. and fetch this 40000000007 using dynamic configuration attribute.

http://yourhost:443/RestAdapter/getorderDetails/40000000007

Share
10 |10000 characters needed characters left characters exceeded
avatar image
Former Member Sep 18, 2017 at 02:54 PM
0

Hi David;

You can get some insight from this link
https://blogs.sap.com/2014/12/18/pi-rest-adapter-exposing-a-function-module-as-restful-service/

Regards

Hasan

Share
10 |10000 characters needed characters left characters exceeded