Developers
Basic Examples

Examples

⚠️

There will be a breaking SDK upgrade in the coming months. This upgrade will make the SDK a lot easier to build with.

This upgrade will affect the interface of the SDK dramatically, and will be coupled with a protocol change - stay tuned for information on early access to the new protocol testnet.

It will also be coupled with the documentation of the SDK on crates.io (opens in a new tab).

All the following examples can be found in the nym-sdk examples directory (opens in a new tab) in the monorepo. Just navigate to nym/sdk/rust/nym-sdk/examples/ and run the files from there with:

cargo run --example <NAME_OF_FILE>

If you wish to run these outside of the workspace - such as if you want to use one as the basis for your own project - then make sure to import the sdk, tokio, and nym_bin_common crates.