#bitcoin #invoice #bolt11

no-std lightning-invoice

Data structures to parse and serialize BOLT11 lightning invoices

46 releases (breaking)

0.33.2 Apr 2, 2025
0.33.1 Jan 29, 2025
0.33.0-beta1 Dec 22, 2024
0.32.0 Sep 3, 2024
0.1.0 Dec 14, 2018

#11 in #invoice

Download history 4810/week @ 2024-12-29 7862/week @ 2025-01-05 8881/week @ 2025-01-12 10392/week @ 2025-01-19 10300/week @ 2025-01-26 12995/week @ 2025-02-02 10177/week @ 2025-02-09 6617/week @ 2025-02-16 6386/week @ 2025-02-23 6809/week @ 2025-03-02 6346/week @ 2025-03-09 8176/week @ 2025-03-16 8691/week @ 2025-03-23 6745/week @ 2025-03-30 6580/week @ 2025-04-06 7541/week @ 2025-04-13

30,005 downloads per month
Used in 151 crates (61 directly)

MIT/Apache

215KB
4.5K SLoC

This crate provides data structures to represent lightning BOLT11 invoices and functions to create, encode and decode these. If you just want to use the standard en-/decoding functionality this should get you started:


lightning-invoice

Docs.rs

This repo provides data structures for BOLT 11 lightning invoices and functions to parse and serialize these from and to bech32.

Please be sure to run the test suite since we need to check assumptions regarding SystemTime's bounds on your platform. You can also call check_platform on startup or in your test suite to do so.

Dependencies

~7.5MB
~93K SLoC