bitcoin-cli-ts
Version:
Auto-generated Bitcoin client library for bitcoind JSON-RPC API
24 lines (23 loc) • 1.16 kB
JavaScript
;
// Auto synced from github actions. Don't change this file
Object.defineProperty(exports, "__esModule", { value: true });
exports.migrateWallet = void 0;
var tslib_1 = require("tslib");
var rpc_request_1 = tslib_1.__importDefault(require("../../rpc-request"));
/**
* migratewallet ( "wallet_name" "passphrase" )
*
* Migrate the wallet to a descriptor wallet.
* A new wallet backup will need to be made.
* The migration process will create a backup of the wallet before migrating. This backup
* file will be named <wallet name>-<timestamp>.legacy.bak and can be found in the directory
* for this wallet. In the event of an incorrect migration, the backup can be restored using restorewallet.
* Encrypted wallets must have the passphrase provided as an argument to this call.
* This RPC may take a long time to complete. Increasing the RPC client timeout is recommended.
*
*/
function migrateWallet(params) {
var bitcoind = params.bitcoind, methodParams = tslib_1.__rest(params, ["bitcoind"]);
return (0, rpc_request_1.default)({ method: 'migratewallet', params: methodParams }, bitcoind);
}
exports.migrateWallet = migrateWallet;