paperclip_macros

Attribute Macro put

source
#[put]
Expand description

Creates route handler with paperclip::actix::web::Resource. In order to control the output type and status codes the return value/response must implement the trait actix_web::Responder.

§Syntax

#[put("path"[, attributes])]

§Attributes

  • "path" - Raw literal string with path for which to register handler.

§Example

/// use paperclip::actix::web::Json; /// use paperclip_macros::put; /// #[put(“/”)] /// async fn example() { /// }