We are delighted to share our new EIC Delivery Methodology for efficiently managing Saviynt Implementations and delivering quick time to value. CLICK HERE.

Pass runtime parameter in analytics job through Saviynt Rest API

suryavav
New Contributor III
New Contributor III

HI Team,

Here we have requirement where we need to pass runtime parameters to substitute endpoint name in an analytics job query when calling via the Saviynt REST API.

Can Saviynt allows to create and execute analytic jobs with run time parameters? Please advice 

Can we pass SQL query as input for invoking the analytics execution?

11 REPLIES 11

sk
All-Star
All-Star

@suryavav : You can use Run Time Analytics API for this purpose, In below screenshot statuskey is the runtime variable used in analytics query which you have replace with the variable you have used for endpoint name

sk_0-1701448671628.png

For details refer: Fetch Runtime Controls Data V2 section 


Regards,
Saathvik
If this reply answered your question, please Accept As Solution and give Kudos to help others facing similar issue.

rushikeshvartak
All-Star
All-Star

You can pass parameters

{
    "requestor""admin",
    "analyticsname": "Request Details",
    "analyticsid": "1897",
    "attributes": {
        "Get_Request_History_For_Days": "1"
    },
    "max": "10",
    "offset": "15"
}

Regards,
Rushikesh Vartak
If you find the response useful, kindly consider selecting Accept As Solution and clicking on the kudos button.

Amar_Simha
New Contributor III
New Contributor III

@rushikeshvartak @sk : I am trying the similar functionality of passing runtime params to invoke runtime analytics.

But, from API, I am getting error 520. Any idea what that error means?

From Saviynt analytics history, i can see the analytics is triggered. Please advise.

Amar_Simha_0-1701859972961.png

 

@Amar_Simha : Did you try to run the same analytics from UI and able to get the result? Based on error it looks like analytics is taking time and erroring out because of guardrail or something like that


Regards,
Saathvik
If this reply answered your question, please Accept As Solution and give Kudos to help others facing similar issue.

Amar_Simha
New Contributor III
New Contributor III

@sk : Yes, I am suspecting the same. From UI, the analytics is not completing. When you speak of guard rails, is it the number of records being returned.  The query returns only two columns and records are <100 and response is almost immediate via data analyzer.

Let me know if I am missing anything here.

@Amar_Simha : If query runs more than certain period it will error out based on backend guardrail. I believe it is around 55 secs starting v23.8 earlier it was 300 secs. Same has been mentioned in below document

Running-Analytics-Controls 


Regards,
Saathvik
If this reply answered your question, please Accept As Solution and give Kudos to help others facing similar issue.

Amar_Simha
New Contributor III
New Contributor III

@sk : Thanks for the update. We are currently in 23.3 version. I can see API call took 1 min to complete. Just wanted to know if there is any way we can check what could be cause for taking this much time for <100 records.

Please share query


Regards,
Rushikesh Vartak
If you find the response useful, kindly consider selecting Accept As Solution and clicking on the kudos button.

Amar_Simha
New Contributor III
New Contributor III

@rushikeshvartak @sk : I was using an email template for sending the file, it seems that was causing this issue. I have tested removing the template and the analytics is working fine. 

Do we have any specific format that we need to use for templates to be used in Analytics?

@Amar_Simha : You can refer to the document listed below where you have different examples provided for email templates that can be used for Analytics report 

Creating-and-Managing-Email-Templates , Refer section: Configuring Analytics Report Notification Email


Regards,
Saathvik
If this reply answered your question, please Accept As Solution and give Kudos to help others facing similar issue.

Email template variable might not be exposed.


Regards,
Rushikesh Vartak
If you find the response useful, kindly consider selecting Accept As Solution and clicking on the kudos button.