# Add a method for a fictional "hello_block" that makes the api say hello when
# it starts
apply_plumber2_block.hello_block <- function(block, api, route_name, root, ...) {
api$on("start", function(...) {
message("Hello")
})
api
}
Run the code above in your browser using DataLab