Want to send a payload in the GET API using the webservice connector

Hi All,

In the “Get a Single User” API, I need to pass a payload to retrieve the attribute value from the target application. I tried using the Account Aggregation in the HTTP operation, but I am not sure if it is actually passing the payload in the GET API call. Because of this, I am getting an error. Does anyone have any idea about this?

I also checked this with the executeGet method, but it does not support a payload either.

We’ll need more information to help you out with this.

Which Webservice connector are you using, VA-Based Direct or SaaS?

Is the “Get a Single User” API you mention the SailPoint one, or an External application you are connecting to?

Based on the Above API reference, are you trying to get a single user’s account, or all accounts? If you are trying to get a single user’s account, you’ll want to look at the Get Object HTTP Operation, Rather than the Account Aggregation.

For the operation, you would want to add your payload items on the Body page of the operation (SaaS doc linked).

Hi @gmilunich ,

It’s VA-based web service connector.

It is for an External application.

Yes, I am trying to get a single user account. I also tried using the Get Object HTTP operation but was not successful.

hi @Rohit_Sahu,

Does the API giving response in Postman?

Hi @selvasanthosh ,

Yes, I am getting a response in Postman.

What is the payload you need to send?

How did you configure it in the Get Object HTTP Operation?

How did you configure it with Postman?

the HTTP Operation in the web service connector needs to be “Get Object” - that is the operation for a single account aggregation

Hi

It is some type of user properties, like below:

{

"properties": \[

    "firstname",

    "lastname",

    "mail"

\]

}

I passed it in the Body section.

Hi @jrossicare ,

I also tried with that but was not successful.

So this is the Body section from Postman?

If so, how did you configure it in the Body section of the Get Object?

For configuring the body, it looks like you would want to use the Raw type and add your JSON to that: Body

Lastly, is this to get details of the identity, or to provision/update the data on the account on the external system?

Hi @gmilunich

So this is the Body section from Postman? – Yes

If so, how did you configure it in the Body section of the Get Object? — In the Raw section, I pasted it as it is.

For configuring the body, it looks like you would want to use the Raw type and add your JSON to that: Body

Lastly, is this to get details of the identity, or to provision/update the data on the account on the external system? – Used to get details of the user.

Can you provide details about the error you’re seeing when the operation fails?

Also, I’d like to verify your configuration - in your “Get Object” HTTP operation settings, have you set the HTTP method to POST ?

Hi @sita_ram

error: The account could not be aggregated. Try again.

I am using the Get method in the Get Object (Single account aggregation API).

Hi @Rohit_Sahu can you confirm whether your external app’s API for retrieving user details uses a GET operation ? Ideally, it should be a POST operation if it includes a payload.

Also, please ensure the API context url or payload is updated with $getObject.nativeIdentity$, so that it filters the account based on the unique account ID as defined in the account schema.

Hi @prashanthrns

It is a GET operation.

Are those slashes really in your payload or are they a copy / paste escape-character-thing? Because I’d be willing to bet that those would break something.

A quick and dirty way to see the payload in a WebServices connector is to create a Before Operation rule that looks something like the following:

Map body = requestEndPoint.getBody();
String jsonBody = (String) body.get("jsonBody");
throw Error ("jsonBody");

This will throw an error message in ISC with the actual request body as the error message. Obviously it’s a hack, but it works for a quick check.

For a GET API, you are sending request body?

If yes - I don’t think that is correct. If your API works that way, not sure if Sailpoint accepts this format.

Have you tried updating the requestBody using Before Operations rule?

No, in the Before Operation rule executeGet method does not support a body in the parameter.

Hi @KevinHarrington

slashes are not there in the body.