[#wallet-DescriptorScriptPubKeyMan-HasPrivKey]
= xref:wallet.adoc[wallet]::xref:wallet/DescriptorScriptPubKeyMan.adoc[DescriptorScriptPubKeyMan]::HasPrivKey
:relfileprefix: ../../
:mrdocs:

Returns whether the private key for the given key id is present&period;

== Synopsis

Declared in `&lt;wallet&sol;scriptpubkeyman&period;h&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
&lsqb;&lsqb;requires&lowbar;capability(0x7f94fd519148), requires&lowbar;capability(0x7f95058b92e8), requires&lowbar;capability(0x7f94f1e440a8), requires&lowbar;capability(0x7f9505cb2dc8), requires&lowbar;capability(0x7f94f23e45c8), requires&lowbar;capability(0x7f94fd840d08)&rsqb;&rsqb;
bool
HasPrivKey(xref:CKeyID.adoc[CKeyID] const& keyid) const;
----

== Return Value

true if the private key is present&period;

== Parameters

[cols="1,4"]
|===
| Name| Description
| *keyid*
| The key id to look up&period;
|===


[.small]#Created with https://www.mrdocs.com[MrDocs]#
