API to retrieve the public url for the current plugin instance to serve static resources

Hello,

Is there an API to retrieve the current public URL for a plugin instance?

This would be useful because I wanted to serve some static files (images, typically).
I can write something like that in the code: public/plugins/my-plugin-id/static/path/to/my/file but I don’t think this is clean…

Thanks,
Best regards

Like you said, the plugin assets are available under:

http://grafana.staged-by-discourse.com/public/plugins/your-plugin-id/README.md

Could you share more why that’s not working for you?

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