[#wallet-CWallet-AddWalletDescriptor] = xref:wallet.adoc[wallet]::xref:wallet/CWallet.adoc[CWallet]::AddWalletDescriptor :relfileprefix: ../../ :mrdocs: Add a descriptor to the wallet, return a ScriptPubKeyMan & associated output type == Synopsis Declared in `<wallet/wallet.h>` [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- [[requires_capability(0x7f2e1e59a728), requires_capability(0x7f2e11aab4e8), requires_capability(0x7f2e16a012d8), requires_capability(0x7f2e15f30778), requires_capability(0x7f2e12c6f408)]] xref:util/Result.adoc[util::Result<std::reference_wrapper<DescriptorScriptPubKeyMan>>] AddWalletDescriptor( xref:wallet/WalletDescriptor.adoc[WalletDescriptor]& desc, xref:FlatSigningProvider.adoc[FlatSigningProvider] const& signing_provider, std::string const& label, bool internal); ---- == Return Value The added descriptor ScriptPubKeyMan, or an error on failure. == Parameters [cols="1,4"] |=== | Name| Description | *desc* | The wallet descriptor to add. | *signing_provider* | Keys and scripts needed to solve the descriptor. | *label* | The label to assign to generated addresses. | *internal* | Whether the descriptor manages internal (change) addresses. |=== [.small]#Created with https://www.mrdocs.com[MrDocs]#