ATrium API is a Rust library that includes the definitions of XRPC requests and their associated input/output model types. These codes are generated from the Lexicon schema on atproto.com.
You can use any HTTP client that implements atrium_api::xrpc::HttpClient
to make use of the XRPC requests. Below is the simplest example using reqwest
.
```rust
struct MyClient(reqwest::Client);
impl atriumapi::xrpc::HttpClient for MyClient {
async fn send(
&self,
req: http::Request
impl atrium_api::xrpc::XrpcClient for MyClient { fn host(&self) -> &str { "https://bsky.social" } fn auth(&self) -> Option<&str> { None } }
atriumapi::impltraits!(MyClient);
async fn main() -> Result<(), Box