Enum threema_gateway::errors::ApiError
[−]
pub enum ApiError { BadSenderOrRecipient, BadCredentials, NoCredits, IdNotFound, MessageTooLong, ServerError, BadHashLength, BadBlob, BadBlobId, RequestError(ReqwestError), IoError(IoError), ParseError(String), Other(String), }
Errors when interacting with the API.
Variants
BadSenderOrRecipient
The recipient identity is invalid or the account is not set up for basic mode
BadCredentials
API identity or secret is incorrect
NoCredits
No credits remain
IdNotFound
Target ID not found
MessageTooLong
Message is too long
ServerError
Internal server error
BadHashLength
Wrong hash length
BadBlob
Bad blob
BadBlobId
Invalid blob ID
RequestError(ReqwestError)
Error when sending request (via reqwest)
IoError(IoError)
Error when reading response
ParseError(String)
Error while parsing response
Other(String)
Other
Trait Implementations
impl Debug for ApiError
[src]
impl Display for ApiError
impl Error for ApiError
fn description(&self) -> &str
A short description of the error. Read more
fn cause(&self) -> Option<&Error>
The lower-level cause of this error, if any. Read more
impl From<ReqwestError> for ApiError
fn from(err: ReqwestError) -> ApiError
Performs the conversion.