Get API operation not taking the body provided in IDN

Hello,
I have configured a web service connector Get Object API as following:

  • Operation type: GET Object
  • HTTP Method: GET
  • JSON body:
[
{"fieldName": "em_id",
"filterValue": "$getObject.nativeIdentity$",
"filterOperation": "=",
"relativeOperation": "AND"
}
]

The API call is supposed to search for the specific user and return the user attributes.
But in IDN the API call is running as if the JSON body did not exist.

I copied the body of my request from the logs to test it in Postman and it works as expected.

Does IDN ignore request body when the Method used is GET?

Regards,
Nadim

For any API, GET request is just like opening a URL in your browser and does not support body in the request. It has to be PUT, PATCH or POST to send a request body

Hello Nithesh,

Thank you for your answer. I understand that request bodies should not be sent in GET requests. But my question here was more concerning IDN Behavior in this case. Will it simply ignore the body even if one is provided?

Regards,

Though I would not be able to answer this question with certainty, in my opinion every API that accepts a GET request is designed to not read any payload (request body)

I’ve come across some poorly developed (usually older) REST API’s where GET requests have required playloads, for example for fetching single objects (in stead of unique identifier in the url).

For cases like these I do believe it is possible to pass the payload in a Before Provisioning rule, If I am not mistaken.

Hi @Nadim ,

Ideally, GET is used to request data from a specified resource.

Note that the query string (name/value pairs) is sent in the URL of a GET request:

You can add the filter in the context url like below -

Hope this helps.

Hello Sabstian,

I wanted to confirm if the payload is passed in a before Provisioning rule or a before Operation rule.

Can you provide an example if possible?

Regards

Hey,

Currently I don’t have any GET operation with a body, as we went to the end-system engineers and begged for updates…

I think the easiest way to test for yourself is to use a webhook and see if you get a payload (with a beforeProvisioning rule). Be careful not to send any sensitive data though.