delete

Attribute Macro delete 

Source
#[delete]
Expand description

A procedural macro for building an HTTP DELETE method of trait. It includes the following attributes:

  • path - a part of the URL path (String)
  • consumes - content type for request, support: application/json, application/xml, application/x-www-form-urlencoded (String)
  • produces - accept type for response, support: application/json, application/xml, application/x-www-form-urlencoded (String)

DELETE method supports argument macros:

  • #[segment] - maps method arguments to path segments and header placeholders (simple types, String)
  • #[query] - maps method arguments to query parameters (simple types, String)
  • #header - maps method arguments to request headers (simple types, String)
  • #[body] - maps method arguments to request body (object implemented #data_transfer)