aranya-example

Crates.ioaranya-example
lib.rsaranya-example
version4.0.0
created_at2025-11-14 21:55:53.735771+00
updated_at2025-11-14 21:55:53.735771+00
descriptionExample Rust program using the Aranya client library
homepage
repositoryhttps://github.com/aranya-project/aranya
max_upload_size
id1933528
size93,946
(aranya-project-bot)

documentation

README

Example Rust Application

This crate contains example code showing how to use Aranya in a Rust application.

This example shows how to use the aranya-client library to:

  • Setup a team
  • Sync Aranya graphs
  • Create and AFC (Aranya Fast Channel) and encrypt/decrypt data with open/seal operations.

During setup, the example application starts an instance of the aranya-daemon for each Aranya device in the background. The daemon handles low-level operations such as automatically syncing graph states between different devices so that the client can focus on the operations it wants to perform on the team.

Running the example with cargo-make

Install the Rust toolchain, this will install the toolchain manager rustup, the rust compiler rustc and package manager/build tool cargo.

Install cargo-make (v0.37.23).

# First, download the source code from this repository:
$ git clone git@github.com:aranya-project/aranya.git

# Change into the directory
$ cd aranya

# Run the make command
$ cargo make run-rust-example

This starts the example and automatically runs through the aforementioned steps.

Commit count: 235

cargo fmt