# Fetch Kibana Dashboard links from Canvas Plugin

**URL:** <https://discuss.elastic.co/t/fetch-kibana-dashboard-links-from-canvas-plugin/175774>\
**Category:** Kibana\
**Tags:** canvas\
**Created:** [April 8, 2019, 7:28am UTC](https://discuss.elastic.co/t/fetch-kibana-dashboard-links-from-canvas-plugin/175774 "2019-04-08T07:28:13Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![tarkin67](https://avatars.discourse-cdn.com/v4/letter/t/8797f3/32.png) [@tarkin67](https://discuss.elastic.co/u/tarkin67)\
**Post date:** [April 8, 2019, 7:28am UTC](https://discuss.elastic.co/t/fetch-kibana-dashboard-links-from-canvas-plugin/175774/1 "2019-04-08T07:28:13Z")

</div>

Hi,

We are running **Elasticsearch and Kibana 6.6.1** want to have a landing page as a canvas workpad that displays a set of other canvas workpads and kibana dashboards with the corresponding links. For this we need to be able to dynamically fetch the links/IDs of our kibana dashboards and canvas workpads.  
For the canvas workpads we solved it by using the `find()` method provided by the `workpadService` code from canvas. We then proceed to construct the link based on the workpad-id that was fetched.

What would be the best way/API to programmatically fetch the links to standard Kibana dashboards from a canvas plugin?

Thanks in advance!

---

<div class="post-metadata">

**Author:** ![tsullivan](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/tsullivan/32/31077_2.png) [@tsullivan](https://discuss.elastic.co/u/tsullivan)\
**Post date:** [April 8, 2019, 7:20pm UTC](https://discuss.elastic.co/t/fetch-kibana-dashboard-links-from-canvas-plugin/175774/2 "2019-04-08T19:20:36Z")

</div>

> [@tarkin67](#):
>
> What would be the best way/API to programmatically fetch the links to standard Kibana dashboards from a canvas plugin?

To programatically get some information / data into Canvas, the best way would be to make a new Canvas plugin (every Canvas plugin is a function) which provides a new Data Source. Your Data Source function could have a server-side implementation that queries the `.kibana` index, doing a terms aggregation on the `type` field, to get all of saved objects that you're interested in, per-type (workpad, dashboard, etc). It could also add a column to the resulting data table for the `href` that links to that saved object.

Then in a Canvas Workpad, you'd be able to create a new element, change the data source from `demodata` to `my-kibana-objects` and pipe that to render a Table or Markdown visualization. I think Markdown element might be best for making links clickable.

---

<div class="post-metadata">

**Author:** ![tarkin67](https://avatars.discourse-cdn.com/v4/letter/t/8797f3/32.png) [@tarkin67](https://discuss.elastic.co/u/tarkin67)\
**Post date:** [April 15, 2019, 7:05am UTC](https://discuss.elastic.co/t/fetch-kibana-dashboard-links-from-canvas-plugin/175774/3 "2019-04-15T07:05:08Z")

</div>

So the way to go would be to query the `.kibana` index huh? I will try that, thanks a lot for your answer!

Kind regards

---

<div class="post-metadata">

**Author:** ![tarkin67](https://avatars.discourse-cdn.com/v4/letter/t/8797f3/32.png) [@tarkin67](https://discuss.elastic.co/u/tarkin67)\
**Post date:** [April 15, 2019, 1:50pm UTC](https://discuss.elastic.co/t/fetch-kibana-dashboard-links-from-canvas-plugin/175774/4 "2019-04-15T13:50:52Z")

</div>

Thanks @tsullivan, this works like a charm:

 ![grafik](https://us1.discourse-cdn.com/elastic/original/3X/5/3/53d31c35f8376a8239112ddef297f3854d4a89de.png)

Best regards

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [May 13, 2019, 1:50pm UTC](https://discuss.elastic.co/t/fetch-kibana-dashboard-links-from-canvas-plugin/175774/5 "2019-05-13T13:50:52Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
