[][src]Crate rocket_okapi_codegen

Macros

routes_and_spec_with_openapi
routes_with_openapi

A replacement macro for rocket::routes. The key differences are that this macro will add an additional element to the resulting Vec<rocket::Route>, which serves a static file called openapi.json. This file can then be used to display the routes in the swagger ui.

Attribute Macros

openapi

A proc macro to be used in tandem with one of Rocket's endpoint macros. It requires that all of the arguments of the route implement one of the traits in rocket_okapi::request, and that the return type implements OpenApiResponder.