Dashboards & Visualizations

Getting html of an existing dashboard via REST API

ozdavid
Engager

Hey, Is there any way to user the REST API to get the html of an existing dashboard?
I know I can get the XML of a dashboard but I need the html in order to render it in our application(no iframe). 

Tags (1)
1 Solution

niketn
Legend

@ozdavid, sorry I misunderstood your question. Except enabling insecure content as iFrame right now you do not have an option. With the new dashboard framework 3rd Party integration was announced last year but it is not available for general use as underlying framework is rapidly evolving to bring in features as requested.

I would request you to put ideas in ideas.splunk.com or upvote an existing one if already present (link to which is available in the top menu in this community site as well).

____________________________________________
| makeresults | eval message= "Happy Splunking!!!"

View solution in original post

ashishLSN
Explorer

Hello there,
I also want to render splunk app's dashboard on my website securely, is there any way to render splunk app's dashboard on my web site, i have successfully access an existing dashboard XML definition as per follow this guideline data/ui/views/{name}. Now my Question is how to convert Splunk app's dashboard xml to HTML so we can show that dashboard on my website.

Thanks for your support.

0 Karma

niketn
Legend

@ozdavid if you want html code for dashboard to show up via REST API, you will have to convert your Simple XML dashboard to HTML first (using the convert option on Top Right "..." button from the Edit menu options).

You have to be aware that this action will create a new dashboard (based on the name you chose). But is irreversible i.e. you can not convert HTML dashboard back to SimpleXML and also may loose out on several built in SimpleXML features which you will have to code yourself. For example Dark Theme.

REST API for data views including HTML dashboard remains the same: https://docs.splunk.com/Documentation/Splunk/latest/RESTREF/RESTknowledge#data.2Fui.2Fviews.2F.7Bnam...

____________________________________________
| makeresults | eval message= "Happy Splunking!!!"
0 Karma

ozdavid
Engager

@niketn Thanks for answering. this route will give me the XML of the dashboard, but I need to render the dashboard itself, including the results

0 Karma

niketn
Legend

@ozdavid, sorry I misunderstood your question. Except enabling insecure content as iFrame right now you do not have an option. With the new dashboard framework 3rd Party integration was announced last year but it is not available for general use as underlying framework is rapidly evolving to bring in features as requested.

I would request you to put ideas in ideas.splunk.com or upvote an existing one if already present (link to which is available in the top menu in this community site as well).

____________________________________________
| makeresults | eval message= "Happy Splunking!!!"
Get Updates on the Splunk Community!

Good Sourcetype Naming

When it comes to getting data in, one of the earliest decisions made is what to use as a sourcetype. Often, ...

See your relevant APM services, dashboards, and alerts in one place with the updated ...

As a Splunk Observability user, you have a lot of data you have to manage, prioritize, and troubleshoot on a ...

Splunk App for Anomaly Detection End of Life Announcement

Q: What is happening to the Splunk App for Anomaly Detection?A: Splunk is officially announcing the ...