btck_transaction_output_create

Create a transaction output from a script pubkey and an amount.

Synopsis

Declared in <kernel/bitcoinkernel.h>

[[nodiscard, __nonnull__]]
btck_TransactionOutput*
btck_transaction_output_create(
    btck_ScriptPubkey const* script_pubkey,
    int64_t amount);

Return Value

The transaction output.

NOTE

The return value should not be discarded.

Parameters

NameDescription
script_pubkey [in]Non-null.
amount [in]The amount associated with the script pubkey for this output.