Does Redash have a REST API for managing
- users,
- groups,
- queries,
- dashboards,
- alerts,
- etc…?
Is the API documented?
Thanks!
Does Redash have a REST API for managing
Is the API documented?
Thanks!
Yes it does have a rest API. It is not feature complete, and not documented other than the actual code.
(I am developing against it now, and that development is how I gained the above knowledge)
Same here. We understood the API reading the code. In our case we use it because we developed a small tool so we can have the queries controlled on git and this way is easy deploy new instances having test and prod environments. It would be great if this API was documented.
Great thank you.
I found these to places to be the best starting places:
https://github.com/getredash/redash/blob/5aa620d1ec7af09c8a1b590fc2a2adf4b6b78faa/redash/handlers/api.py
https://github.com/getredash/redash/tree/5aa620d1ec7af09c8a1b590fc2a2adf4b6b78faa/redash/handlers
(Posted on Slack channel, copied here given the more targeted audience.)
Hi,
I think it’s the case, but I want to be sure: Can I do all of the following over the REST API:
We’re considering using redash as an analytics generator, which then our other applications (web or desktop) make REST calls against to retrieve any of the following:
Of course too we’ll need to retrieve collections of:
I already had in mind to use redis to cache results, and from a brief look at the code, it seems that redash implements some form of such caching with redis.
At present and for a while we don’t expect to be needing to send parameters and retrieve results based on those parameters, but eventually will. From my brief reading it seems that this is a priority item already under development and in some cases working. Have I understood correctly?
In summary, in addition to using redash itself for certain managment and administrative users (lesser use case), it’s important we be able to pull out of redash (ideally over REST) whatever dashboards, visualizations, or visualization element(s) we want so they can be presented elsewhere (greater use case). It seems redash can do this, and likely quite well.
But I’d be most grateful to hear from someone with experience (developer or user) to confirm or disconfirm my understanding, and, if possible, provide any pointers re: good places to start, gotcha’s and “watch out”, etc.
Thanks so much!
Doug
Oh, in addition:
We’ll be wanting to retrieve “stored” visualizations / dashboards (e.g., many of these analytics need only be generated every so many hours, days, or weeks) as well as visualizations / dashboards that are generated upon each request. We also have in mind to expire the redis cache for certain analytical results when we know they should be recomputed (e.g., regional distribution summary for a given product only need be updated when the product is sold, thus our ERP sends a message on a message queue, our control server listens for such messages and expires the relevant analytical results in the redis cache for redash, and thus upon next request regenerates the visualization, puts it back in the cache, and sends it to the requesting user or application). Something like this possible?
I should probably mention: We’ll be self hosting, and always will have to, given the sensitive nature of our data. My understanding there is at present no difference for cloud vs self hosted, but of course that could change.
Did you find out the answer to your questions?
"I think it’s the case, but I want to be sure: Can I do all of the following over the REST API:
If we can do all of that, could you please refer me to the API docs? Thanks a lot!
Hi Amit,
Redash uses a REST API behind the scenes but it isn’t formally documented (we’re working on this).
I think that clarifies a lot. Thanks Jesse.
Hey @jesse , can you clarify, are we still not able to fetch list of visualizations present in a dashboard by hitting an API ?
This has always been possible. Fetching from the dashboards
endpoint returns such a list.
If the language you’re calling from is Go, then the unofficial “Redash Go SDK” might do what you’re after: