Click HERE to see how Saviynt Intelligence is transforming the industry. |
04/10/2024 07:53 AM
Hi,
We are trying to retrieve organizations list based on orgquery filter and display as drop down in external HTML form. JSON response from {{url}}/ECM/{{path}}/getOrganization contains lot of data about each organization. However, we would like to retrieve only organizationname from the array. Is there anyway to apply filter on JSON response?
Thanks
Vijay
04/10/2024 01:10 PM - edited 04/10/2024 01:11 PM
Hi @dvijay ,
No, currently it's not working for getOrganization (like getOrganization?fields=organizationName,
We had similar requirement in past and we choose analytics.
Please create an analytic report with desired columns and use Saviynt API to fetch organizationname.
{{URL}}/ECM/{{path}}/fetchControlDetailsES
If this answers your question, please consider selecting Accept As Solution and hit Kudos
04/16/2024 08:52 AM
Thanks @PremMahadikar
I have a follow-up question...
Does /fetchControlDetailsES endpoint support attribute value based query such as "orgQuery" : "c.organizationname like '%TestOrg5%'" in /getOrganization endpoint.
Thanks
Vijay
04/16/2024 12:09 PM - edited 04/16/2024 12:09 PM
This can't be achieved by /fetchControlDetailsES endpoint.
If your requirement is to again filter based on the report generated (which is again custom query), then to achieve this - you need to use runtime report:
Endpoint: {{url}}/ECM/{{path}}/fetchRuntimeControlsData
Working Example - Let's say this is your below query:
select c.CUSTOMERNAME from customer c where c.customername='${organizationname}'
The API body would look like:
{
"requestor": "premmahadikar",
"analyticsname": "orgnizationname",
"analyticsid": "10",
"attributes": {
"organizationname": "TestOrg"
}
}
The response would be:
{
"result": [
{
"CUSTOMERNAME": "TestOrg"
}
],
"msg": "Success",
"displaycount": 1,
"total": 1,
"errorCode": 0
}
If you find the above response useful, Kindly Mark it as Accept As Solution and hit Kudos
04/23/2024 09:23 PM
Its not supported