ScriptToUniv

Fill a JSON object with a human-readable description of a script.

Synopsis

Declared in <core_io.h>

void
ScriptToUniv(
    CScript const& script,
    UniValue& out,
    bool include_hex = true,
    bool include_address = false,
    SigningProvider const* provider = nullptr);

Parameters

NameDescription
scriptScript to describe.
outJSON object populated with the script's fields.
include_hexWhen true, include the raw script as a hex string.
include_addressWhen true, include the decoded address when the script has one.
providerOptional source of keys and scripts used to resolve addresses.