[#blockheaderToJSON]
= blockheaderToJSON
:mrdocs:

Block header to JSON

== Synopsis

Declared in `&lt;rpc&sol;blockchain&period;h&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
&lsqb;&lsqb;locks&lowbar;excluded(0x7f2e2991a498)&rsqb;&rsqb;
xref:UniValue.adoc[UniValue]
blockheaderToJSON(
    xref:CBlockIndex.adoc[CBlockIndex] const& tip,
    xref:CBlockIndex.adoc[CBlockIndex] const& blockindex,
    xref:uint256.adoc[uint256] pow&lowbar;limit);
----

== Return Value

A JSON representation of the block header&period;

== Parameters

[cols="1,4"]
|===
| Name| Description
| *tip*
| The current chain tip, used to compute confirmations&period;
| *blockindex*
| The block index entry of the header&period;
| *pow&lowbar;limit*
| The proof&hyphen;of&hyphen;work limit used to compute difficulty&period;
|===


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