2

I'm building a dashboard in Data Studio and want to add a 'button' like feature that basically calls/runs a python function that downloads some content locally(on the client machine). I have the python function almost ready.

The question I have is where do I host this function so that it is callable from Data Studio? Ideally, I wanted to create a Cloud function that would host the python function and get triggered when the button is clicked. This would work till this point but, will not download content locally. What options do I have to accomplish this?

Sharad
  • 51
  • 4

2 Answers2

0

Currently it is not possible to trigger Cloud Function or something similar from the Data Studio Front end, especially when you are intending to download content locally.

The only thing I can think of is, you can create a custom connector which will call the Cloud Function (via URL trigger). Then use the connector to create a data source and attach that data source to a table or chart. That way, every time that page (with the table/chart) is refreshed, the connector will call the Cloud Function and retrieve the associated data.

Minhaz Kazi
  • 3,115
  • 1
  • 10
  • 20
0

A function can be triggered by HTTP, so you can make it publicly available and just drop a link to it in a dashboard.

Just add a gray square around this link and make it look like a button. You may want to check the box to open the URL in a new tab, so your dashboard is not closed when the link is clicked.

Diego Queiroz
  • 3,198
  • 1
  • 24
  • 36