So that packages can ship multiple plumber routers, users should store their Plumber APIs
in the inst
subfolder plumber
(./inst/plumber/API_1/plumber.R
).
plumb_api(package = NULL, name = NULL, edit = FALSE)available_apis(package = NULL)
A Plumber
object. If either package
or name
is null, the appropriate available_apis()
will be returned.
Package to inspect
Name of the package folder to plumb()
.
Whether or not to open the API source code for viewing / editing
plumb_api()
: plumb()
s a package's Plumber API. Returns a Plumber
router object
available_apis()
: Displays all available package Plumber APIs. Returns a data.frame
of package
, name
, and source_directory
information.
To view all available Plumber APIs across all packages, please call available_apis()
.
A package
value may be provided to only display a particular package's Plumber APIs.