Skip to content
/ rust-sdk Public

Repository containing Rust tooling to interact with the Turnkey API

License

Notifications You must be signed in to change notification settings

tkhq/rust-sdk

Repository files navigation

Turnkey Rust SDK   Build Status

This repository contains tooling to interact with the Turnkey API using Rust, and is organized as a collection of Rust crates.

Crate Description crates.io Docs Changelog Source
turnkey_api_key_stamper Utilities to use Turnkey API keys Latest docs.rs CHANGELOG api_key_stamper
turnkey_client Rust client to interact with the Turnkey API Latest docs.rs CHANGELOG client
turnkey_enclave_encrypt Utilities to decrypt and encrypt data from and to Turnkey secure enclaves Latest docs.rs CHANGELOG enclave_encrypt
turnkey_proofs Utilities to verify Turnkey secure enclave proofs Latest docs.rs CHANGELOG proofs

Examples

For fully working code examples, see our examples folder.

Development

This project uses make to encapsulate common tasks:

  • make lint will run rust fmt and clippy
  • make test runs the unit tests
  • make examples runs the examples (requires a local .env file, see instructions)
  • make generate re-generates client::generated from the proto folder. Code generation logic lives in codegen

Releases

This project uses release-plz. Install it with:

cargo install --locked release-plz

Once you have it installed you can try a release locally, to see what the release PR would be:

release-plz update

Release flow

When PRs are merged to main, release-plz automatically opens a Release PR if it doesn't exist yet, or updates the existing one.

The PR is opened by the release-plz bot and tagged release. A human is expected to double check this PR and manually push any fixes to the release PR if necessary (usually: cosmetic changes to the CHANGELOGs).

Once the PR is merged, the release-plz release workflow is triggered and crates are published automatically.

DO NOT bump crates manually in standard PRs, let release-plz take care of this for you!

Manually re-triggering a release

If something goes wrong during a release and you want to retry, you can open a PR tagged release and with a branch named release-plz-**** to kick off the release workflow again (the release tag is necessary to trigger the workflow, and the branch name prefix is how release-plz determines that the PR is a release PR -- see this)

Feature requests and support

If you are working on a project in Rust and would benefit from improvements to this SDK, please open an issue or get in touch with us (hello@turnkey.com) and we can discuss prioritizing this.

About

Repository containing Rust tooling to interact with the Turnkey API

Topics

Resources

License

Security policy

Stars

Watchers

Forks

Contributors 14