pub enum Error {
ObjectNotFound {
message: String,
},
ObjectAlreadyExists {
message: String,
},
InvalidRequest {
message: String,
},
Unauthenticated {
internal_message: String,
},
InvalidValue {
message: String,
},
Forbidden,
InternalError {
internal_message: String,
},
ServiceUnavailable {
internal_message: String,
},
MethodNotAllowed {
internal_message: String,
},
}
Variants§
ObjectNotFound
An object needed as part of this operation was not found.
ObjectAlreadyExists
An object already exists with the specified name or identifier.
InvalidRequest
The request was well-formed, but the operation cannot be completed given the current state of the system.
Unauthenticated
Authentication credentials were required but either missing or invalid. The HTTP status code is called “Unauthorized”, but it’s more accurate to call it “Unauthenticated”.
InvalidValue
The specified input field is not valid.
Forbidden
The request is not authorized to perform the requested operation.
InternalError
The system encountered an unhandled operational error.
The system (or part of it) is unavailable.
MethodNotAllowed
Method Not Allowed
Implementations§
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Error
impl<'de> Deserialize<'de> for Error
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Source§impl Error for Error
impl Error for Error
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
Source§impl From<ErrorResponse> for Error
impl From<ErrorResponse> for Error
Source§fn from(error: ErrorResponse) -> Error
fn from(error: ErrorResponse) -> Error
Converts an Error
error into an HttpError
. This defines how
errors that are represented internally using Error
are ultimately
exposed to clients over HTTP.