createproof

createproof -- Create a BOLT12 payer proof (EXPERIMENTAL)

SYNOPSIS

createproof invstring [note] [include]

DESCRIPTION

Command added in v26.06.

NOTE: The proof format is still a draft: IT MAY CHANGE IN INCOMPATIBLE WAYS IN FUTURE.

The createproof RPC command creates a proofs that we have made a BOLT12 payment according to the current draft specification.
In case we have made multiple payments to the same thing, we will create multiple proofs.
Each returned proof includes enough fields from the offer and invoice itself that a reader can verify it: see decode.

  • invstring (string): bolt12 invoice, a bolt12 (non-recursive) offer or a BIP353 name.
  • note (string, optional): A note to include in the proof: someone can challenge you to create a proof with a given note, and so you can demonstrate that you can indeed make a new proof. Default is an empty string.
  • include (array, optional): An explicit list of TLV field names or numbers to include in the proof if they are present. The default values are:
  • 10 (offer_description): identifies what was purchased
  • 22 (offer_issuer_id): identifies who issued the offer being proved
  • 164 (invoice_created_at): timestamp of invoice
  • 170 (invoice_amount): the amount actually paid

Note that the following fields are always included: 88 (invreq_payer_id), 168 (invoice_payment_hash), 174 (invoice_features), 176 (invoice_node_id) and 240 (signature).:
- (string): Name of an offer, invoice_request or invoice field to include
- (u64): Number of an offer, invoice_request or invoice field to include (allows reference to unknown fields)

RETURN VALUE

On success, an object containing proofs is returned. It is an array of objects, where each object contains:

  • bolt12 (string): The payer_proof.
  • offer_fields_included (array):
    • (string): The name of the field from the offer we included in the proof.
    • (u64): The number of the field from the offer we included in the proof (if we don't know the name).
  • invreq_fields_included (array):
    • (string): The name of the field from the invoice_request we included in the proof.
    • (u64): The number of the field from the invoice_request we included in the proof (if we don't know the name).
  • invoice_fields_included (array):
    • (string): The name of the field from the invoice we included in the proof.
    • (u64): The number of the field from the invoice we included in the proof (if we don't know the name).

ERRORS

The following error codes may occur:

  • -1: Catchall nonspecific error.
  • 1700: We could not find a successful payment for that invstring.

AUTHOR

Rusty Russell [email protected] is mainly responsible.

SEE ALSO

lightning-xpay(7), lightning-decode(7)

RESOURCES

Main web site: https://github.com/ElementsProject/lightning

Core Lightning is Blockstream's open-source implementation of the Lightning Network optimised for performance. It is highly customizable through modular expandability.

© 2026 Core Lightning, a Blockstream project.
All rights reserved.

X Twitter Logo Streamline Icon: https://streamlinehq.com

X

The official Core Lightning X(Twitter) handle to follow project updates and announcements.

Github Logo 2 Streamline Icon: https://streamlinehq.com

Github

Github repository for source code, issues, and contributions. Visit our project here to explore or contibute.

Telegram

Community-driven telegram group where most of the node operators hang out. Go to https://t.me/lightningd to join.

Discord

Community-driven discord server where the devs flock together. Go to https://discord.gg/V6ay9yNhBQ to join.