unosend 1.0.0

Official Rust SDK for Unosend - Email API for developers
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
use thiserror::Error;

/// Error type for Unosend API operations.
#[derive(Error, Debug)]
pub enum UnosendError {
    /// API returned an error response.
    #[error("API error: {message} (status: {status_code})")]
    Api { message: String, status_code: u16 },

    /// Network error during request.
    #[error("Network error: {0}")]
    Network(#[from] reqwest::Error),

    /// Failed to parse response.
    #[error("Parse error: {0}")]
    Parse(String),
}