K
knavneet
Guest
Hi - It is possible to map HTTP request BODY to an Input parameter. You may have multiple input parameters in your ABL program and you may want to receive their values from HTTP Request Body. In that case you map each input paramter to a sub-node in the "body". So in that case your Request payload will need to be wrapped in "request" node e.g.: { "request : { "p1" : {...} , "p2" : {...} , ...} However, if there is just one input parameter you can directly map it to request body and you need not wrap it in request node. So you payload will simply be (as you mention): { "stuff" : {...} } It is also possible to map the HTTP path parameter to the ABL input parameter. So, if I understand your following question correctly: 1) can you have a BODY with a PUT that uses resource mapping of the path to input AND a body. Answer) Yes 2) Is it that the base path is the same the issue ? Answer) If you want to use Path parameter and body from the same REST request, you must use the Base URL with Path parameter in the URI space i.e: taking your example: VERB: PUT URL : /manifests/someManifests/{manifestobj} Path parameter {manifestobj} can be mapped to an ABL INPUT parameter Request Body can mapped to another ABL parameter (NOTE: the JSON payload will need to be wrapped inside "request" node depending on how you map on input side - directly to body or to the sub-node) I am sorry if I didn't answer the question that you asked. Please let me know if you have further question.
Continue reading...
Continue reading...