Expand description
§Payjoin implementation in Rust
Supercharge payment batching to save you fees and preserve your privacy.
This library implements both BIP 78 Payjoin V1 and BIP 77 Payjoin V2.
Only the latest BIP 77 Payjoin V2 is enabled by default. To use BIP 78 Payjoin V1, enable the v1
feature.
The library is perfectly IO-agnostic — in fact, it does no IO by default without the io
feature.
Types relevant to a Payjoin Directory as defined in BIP 77 are available in the directory
module enabled by
the directory
feature.
§Disclaimer ⚠️ WIP
Use at your own risk. This crate has not yet been reviewed by independent Rust and Bitcoin security professionals.
Re-exports§
pub extern crate bitcoin;
Modules§
- directory
directory
- Types relevant to the Payjoin Directory as defined in BIP 77.
- error
_core
- io
io
- IO-related types and functions. Specifically, fetching OHTTP keys from a payjoin directory.
- persist
_core
andv2
- receive
_core
- Receive Payjoin
- send
_core
- Send Payjoin
- version
_core
Structs§
- Hpke
KeyPair v2
- Hpke
Public Key v2
- Ohttp
Keys v2
- PjParse
Error - Request
- Represents data that needs to be transmitted to the receiver or payjoin directory.
Ensure the
Content-Length
is set to the length ofbody
. (most libraries do this automatically) - Url
- A parsed URL record.
Enums§
- Into
UrlError - Output
Substitution v1
- Whether the receiver is allowed to substitute original outputs or not.
- Parse
Error - Errors that can occur during parsing.
- Version
- The Payjoin version
Constants§
- MAX_
CONTENT_ LENGTH _core
- 4M block size limit with base64 encoding overhead => maximum reasonable size of content-length 4_000_000 * 4 / 3 fits in u32