RStudio Server does not show run API/Publish button for plumber API


I am running RStudio Server (Pro 1.2.5001-3). Whenever I create a new plumber API file from the template or using annotations, the 'run API' and 'Publish to RStudio Connect' buttons appear automatically. However the same does not occur when I start a fresh file and do:


pr <- plumber$new()

pr$handle("GET", "/", function(req, res) {
  "Hello world"


I imagine that it is because this functionality is not implemented in RStudio and I intend to raise an issue on that... Now my question is: is there a way to "trick" RStudio to make the aforementioned buttons appear with minor modifications? I am thinking on adding some api annotation that makes it work or define one endpoint in the file with annotations...

This is important in my opinion to make large APIs maintainable via routes.


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