Something went wrong. Try again.
Rust CLI for tangled
Something went wrong. Try again.
2 folders · 4 files
README.md
tangled-api #
tangled-api is the low-level, lexicon-generated Rust XRPC client used by the
Tangled CLI.
It provides:
- Generated request builders and data types for Tangled and AT Protocol lexicons
- Transport helpers for JSON, unit, and byte responses
- Structured XRPC errors
- Preservation of unknown record fields during serialization round trips
The crate intentionally contains no authentication policy or multi-step orchestration. Consumers attach the required authorization headers and compose individual requests into higher-level operations.
use tangled_api::lexicon::sh::tangled::repo;
# async fn example() -> Result<(), Box<dyn std::error::Error>> {
let http = reqwest::Client::new();
let params = repo::describe_repo::Params {
repo_did: "did:plc:example".to_string(),
};
let request = repo::describe_repo(&http, "https://knot1.tangled.sh", ¶ms);
let output: repo::describe_repo::Output = tangled_api::xrpc::send(request).await?;
# Ok(())
# }
License #
Licensed under either of Apache License, Version 2.0 or MIT license at your option.