Skip to content

Commit

Permalink
docs
Browse files Browse the repository at this point in the history
  • Loading branch information
AntoniosBarotsis committed Jun 8, 2024
1 parent afb45cf commit c34237a
Showing 1 changed file with 18 additions and 11 deletions.
29 changes: 18 additions & 11 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,28 +13,24 @@ cargo add resend-rs
cargo add tokio -F macros,rt-multi-thread
```

[action-badge]: https://img.shields.io/github/actions/workflow/status/resend/resend-rs/ci.yml
[action-url]: https://github.com/resend/resend-rs/actions/workflows/ci.yml
[crates-badge]: https://img.shields.io/crates/v/resend-rs
[crates-url]: https://crates.io/crates/resend-rs
[docs-badge]: https://img.shields.io/docsrs/resend-rs
[docs-url]: https://docs.rs/resend-rs

Emails are sent via the `Resend` client which provides both a synchronous and
asynchronous send method. The two are mutually exclusive and accessible via the
`blocking` feature. The crate uses [reqwest][reqwest] and [serde][serde]
internally.

[reqwest]: https://github.com/seanmonstar/reqwest
[serde]: https://github.com/serde-rs/serde
### Documentation

Crate documentation is available in [docsrs][docs-url]. Example usage is available in the
[get started guide][get-started] on the Resend website, you can also find examples in the
[API reference][resend-api-ref].

#### Features
### Features

- `blocking` to enable the blocking client.
- `native-tls` to use system-native TLS. **Enabled by default**.
- `rustls-tls` to use TLS backed by `rustls`.

#### Variables
### Variables

- `RESEND_API_KEY` to enable `impl Default` for a `Resend` client (Required).
- `RESEND_BASE_URL` to override the default base address:
Expand All @@ -44,3 +40,14 @@ internally.
failures. This is thread-safe (as long as you use the same `Resend` client across threads!)

> <div class="warning">WARNING: Rate limiting only works when using the async version (default) of the crate</div>
[action-badge]: https://img.shields.io/github/actions/workflow/status/resend/resend-rs/ci.yml
[action-url]: https://github.com/resend/resend-rs/actions/workflows/ci.yml
[crates-badge]: https://img.shields.io/crates/v/resend-rs
[crates-url]: https://crates.io/crates/resend-rs
[docs-badge]: https://img.shields.io/docsrs/resend-rs
[docs-url]: https://docs.rs/resend-rs
[reqwest]: https://github.com/seanmonstar/reqwest
[serde]: https://github.com/serde-rs/serde
[get-started]: https://resend.com/docs/send-with-rust
[resend-api-ref]: http://localhost:3000/api-reference

0 comments on commit c34237a

Please sign in to comment.