> ## Documentation Index
> Fetch the complete documentation index at: https://www.dynamic.xyz/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Delegated Access for SVM Wallets

> Sign Solana messages on behalf of users with their permission using delegated access

## Overview

The Solana delegated client mirrors the EVM delegated client one-for-one — same auth model, same webhook decrypt helper, same revocation. Only the chain client type and the signature format differ.

For the full delegation flow (how the webhook is sent, what the encrypted envelope contains, security best practices), see [EVM Delegated Access](/rust/evm/delegated-access). This page covers only the Solana-specific bits.

## Prerequisites

* [EVM Delegated Access](/rust/evm/delegated-access) — read this first for the full flow
* An RSA private key registered with Dynamic for webhook decryption (PEM-encoded PKCS#8)

## Decrypting the Webhook

Identical to EVM:

```rust theme={"system"}
use dynamic_waas_sdk::decrypt_delegated_webhook_data;

let decrypted = decrypt_delegated_webhook_data(
    &rsa_private_key_pem,
    &payload.encrypted_share,
    &payload.encrypted_wallet_api_key,
)?;
```

## Building the Delegated SVM Client

```rust theme={"system"}
use dynamic_waas_sdk::{DelegatedWalletClient, DelegatedWalletClientOpts};
use dynamic_waas_sdk_svm::DelegatedSvmWalletClient;

let delegated = DelegatedWalletClient::new(
    DelegatedWalletClientOpts::new(env_id, decrypted.wallet_api_key.clone()),
)?;
let svm = DelegatedSvmWalletClient::new(&delegated);
```

## Signing a Solana Message

```rust theme={"system"}
use dynamic_waas_sdk::{ServerKeyShare, WalletProperties};

let wallet_properties = WalletProperties {
    chain_name: "SVM".to_string(),
    wallet_id: payload.wallet_id.clone(),
    account_address: payload.account_address.clone(),
    threshold_signature_scheme: Default::default(),
    derivation_path: None,
    address_type: None,
    external_server_key_shares_backup_info: None,
};

let external_server_key_shares = vec![ServerKeyShare {
    /* fields populated from decrypted.share — see docs.rs for the exact shape */
    ..Default::default()
}];

let signature_b58 = svm
    .sign_message(
        &wallet_properties,
        &external_server_key_shares,
        "Hello, World!",
    )
    .await?;
```

## Revoking Delegation

Same as EVM — call `revoke_delegation` on the base delegated client:

```rust theme={"system"}
delegated.revoke_delegation(&wallet_id).await?;
```

## Related

* [EVM Delegated Access](/rust/evm/delegated-access) — full flow + security guidance
* [Delegated Access Overview](/overview/wallets/embedded-wallets/mpc/delegated-access) — conceptual background
