pub struct Operation {
pub tags: Option<Vec<String>>,
pub summary: Option<String>,
pub description: Option<String>,
pub external_docs: Option<ExternalDocs>,
pub operation_id: Option<String>,
pub parameters: Option<Vec<Parameter>>,
pub request_body: Option<RequestBody>,
pub responses: Option<BTreeMap<String, Response>>,
pub callbacks: Option<BTreeMap<String, BTreeMap<String, PathItem>>>,
pub deprecated: Option<bool>,
pub security: Option<Vec<BTreeMap<String, Vec<String>>>>,
pub servers: Option<Server>,
}Expand description
A single API operation on a path.
Describes a single operation (HTTP method) available on a path, including parameters, request body, responses, and security requirements.
Fields§
Tags for logical grouping of operations.
summary: Option<String>A short summary of the operation.
description: Option<String>A detailed description of the operation. CommonMark syntax may be used.
external_docs: Option<ExternalDocs>Additional external documentation for this operation.
operation_id: Option<String>Unique identifier for the operation. Should follow naming conventions.
parameters: Option<Vec<Parameter>>Parameters applicable for this operation.
request_body: Option<RequestBody>The request body for this operation.
responses: Option<BTreeMap<String, Response>>Possible responses from this operation, keyed by HTTP status code or “default”.
callbacks: Option<BTreeMap<String, BTreeMap<String, PathItem>>>Callbacks that may be initiated by the API provider.
deprecated: Option<bool>Whether this operation is deprecated (default: false).
security: Option<Vec<BTreeMap<String, Vec<String>>>>Security requirements for this operation. Overrides global security.
servers: Option<Server>Alternative server for this operation.