Exports the private key for the wallet identified by the supplied walletMetadata. The private key is reconstructed from the distributed key shares using password for backup decryption if shares are not provided.
When you pass externalServerKeyShares (the caller-supplied path), walletMetadata.externalServerKeySharesBackupInfo must also be present — exportPrivateKey throws if shares are supplied but backup metadata is missing. The full walletMetadata returned from createWalletAccount / importPrivateKey already includes it; identity-only metadata from fetchWalletMetadata will be rejected.
password (string) - Required if the wallet was created with backUpToDynamic: true. Used for backup decryption when externalServerKeyShares is not provided.