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

# offlineExportPrivateKey

> Exports private key offline without requiring server communication

## Function Signature

```typescript theme={"system"}
offlineExportPrivateKey(params: {
  keyShares: any[];
  derivationPath?: string;
}): Promise<string>
```

## Description

Exports private key offline without requiring server communication. This function is useful for scenarios where you need to export keys without network connectivity.

## Parameters

### Required Parameters

* **`keyShares`** (`any[]`) - Array of key shares

### Optional Parameters

* **`derivationPath`** (`string`) - Derivation path for the key (e.g., "m/44'/501'/0'/0'" for Solana)

## Returns

* **`Promise<string>`** - The exported private key

## Example

```typescript theme={"system"}
import { authenticatedSvmClient } from './client';

const svmClient = await authenticatedSvmClient();

const offlinePrivateKey = await svmClient.offlineExportPrivateKey({
  keyShares: [
    {
      chainName: 'solana',
      keyShare: '0xYourKeyShare',
    },
  ],
  derivationPath: "m/44'/501'/0'/0'", // Solana derivation path
});

console.log('Offline Private Key:', offlinePrivateKey);
```

## Error Handling

```typescript theme={"system"}
try {
  const offlinePrivateKey = await svmClient.offlineExportPrivateKey({
    keyShares,
    derivationPath: "m/44'/501'/0'/0'",
  });
  console.log('Offline private key exported successfully');
} catch (error) {
  console.error('Failed to export offline private key:', error);
}
```

## Related Functions

* [`exportPrivateKey()`](/node/reference/svm/export-private-key) - Export private key with server communication
* [`offlineExportKey()`](/node/reference/svm/offline-export-key) - Export key offline
