Crate wallet_standard

Source
Expand description

§wallet_standard


An implementation of the solana wallet standard in rust.


Crate Docs Status Unlicense codecov

§Installation

To install you can used the following command:

cargo add wallet_standard

Or directly add the following to your Cargo.toml:

[dependencies]
wallet_standard = "0.1" # replace with the latest version

§Features

FeatureDescription
browserEnables the browser feature for the wallet_standard_browser crate.
solanaEnables the solana feature for the wallet_standard_solana crate.

§Usage

The Wallet Standard is a set of traits and conventions designed to improve the user experience and developer experience of wallets and applications for any blockchain.

This crate provides a Rust implementation of the Solana Wallet Standard, which aims to create a consistent interface for wallets and dApps to interact across different blockchain ecosystems. Here’s a brief overview of how to use this crate:

  1. Basic Setup:

All the traits can be imported using the prelude.

use wallet_standard::prelude::*;

A full example of how to use this crate can be found in the wallet_standard_browser crate and in the memory_wallet crate.

Modules§

prelude

Structs§

ExperimentalDecryptProps
ExperimentalEncryptProps
StandardConnectInput

Enums§

WalletError

Constants§

CIPHER_X25519_XSALSA20_POLY1305
Default encryption algorithm in NaCl. Curve25519 scalar multiplication, Salsa20 secret-key encryption, and Poly1305 one-time authentication.
EXPERIMENTAL_DECRYPT
EXPERIMENTAL_ENCRYPT
STANDARD_CONNECT
STANDARD_DISCONNECT
STANDARD_EVENTS

Traits§

ConnectedWalletStandardEvents
ExperimentalDecryptOutput
ExperimentalEncryptOutput
IntoWalletError
StandardConnectOutput
StandardEventProperties
Wallet
WalletAccountInfo
Interface of a WalletAccount, also referred to as an Account.
WalletExperimentalDecrypt
WalletExperimentalEncrypt
WalletInfo
WalletStandard
WalletStandardConnect
WalletStandardDisconnect

Type Aliases§

WalletResult