Skip to content

longcipher/circle-sdk-rs

Repository files navigation

Circle SDK for Rust

DeepWiki Context7

hpx

Async Rust SDK for the Circle Web3 Services API.

Crates

Crate crates.io docs.rs Description
circle-user-controlled-wallets crates.io docs.rs User-Controlled Wallets API
circle-developer-controlled-wallets crates.io docs.rs Developer-Controlled Wallets API
circle-compliance crates.io docs.rs Compliance Engine API
circle-buidl-wallets crates.io docs.rs Modular Wallets (Buidl / ERC-4337) API
circle-cli crates.io docs.rs CLI for all services

Features

  • User-Controlled Wallets — End-users own their signing keys via PIN-protected security model
  • Developer-Controlled Wallets — Your backend manages signing keys for a seamless UX
  • Compliance Engine — Automated OFAC/AML blockchain address screening
  • Buidl Wallets — Account-Abstraction (ERC-4337) wallets with gasless operations
  • CLIcircle-cli command-line tool for all services

Installation

Add the crates you need to Cargo.toml:

[dependencies]
circle-user-controlled-wallets = "0.1"
circle-developer-controlled-wallets = "0.1"
circle-compliance = "0.1"
circle-buidl-wallets = "0.1"
tokio = { version = "1", features = ["rt-multi-thread", "macros"] }

Or install the CLI:

cargo install circle-cli

Quick Start

use circle_developer_controlled_wallets::{
    DeveloperWalletsClient, models::wallet::ListWalletsParams,
};

#[tokio::main]
async fn main() -> Result<(), circle_developer_controlled_wallets::Error> {
    let client = DeveloperWalletsClient::new("your_api_key");
    let resp = client.list_wallets(&ListWalletsParams::default()).await?;
    println!("Wallets: {:?}", resp.data.wallets);
    Ok(())
}

See each crate's README for detailed examples.

CLI Usage

export CIRCLE_API_KEY="<YOUR_API_KEY>"

# List developer wallets
circle-cli developer list-wallets

# Screen a blockchain address
circle-cli compliance screen-address --chain ETH --address 0xYourAddress

# Show all commands
circle-cli --help

See bin/circle-cli/README.md for the full command reference with verified testnet examples.

Authentication

Obtain an API key from the Circle Developer Console. Pass it via the CIRCLE_API_KEY environment variable or the --api-key flag (CLI).

License

Apache-2.0

About

Circle API Rust SDK

Topics

Resources

Stars

Watchers

Forks

Packages

 
 
 

Contributors