Skip to content

Payjoin#2049

Draft
thesimplekid wants to merge 8 commits into
cashubtc:mainfrom
thesimplekid:payjoin
Draft

Payjoin#2049
thesimplekid wants to merge 8 commits into
cashubtc:mainfrom
thesimplekid:payjoin

Conversation

@thesimplekid

Copy link
Copy Markdown
Collaborator

Description


Notes to the reviewers


Suggested CHANGELOG Updates

CHANGED

ADDED

REMOVED

FIXED


Checklist

  • I followed the code style guidelines
  • I ran just quick-check before committing
  • If the Wallet API was modified (added/removed/changed), I have reflected those changes in the FFI bindings (crates/cdk-ffi)

Introduce NUT-30 and NUT-31 quote metadata for payjoin endpoints and thread the fields through mint, wallet, payment trait, and FFI quote types.

Expose BDK payjoin endpoint configuration in mintd and regtest wiring so onchain mints can advertise receiver support.

Document the onchain payjoin extension and cover quote-id propagation for mint and melt quotes.
Move BDK payjoin sender and receiver logic into dedicated session handling with background pollers that can resume in-flight work.

Persist payjoin quote metadata and session state across wallet backends, including SQL and Supabase migrations plus wallet database coverage.

Add CLI mint and melt payjoin flags, shared parsing helpers, fee and output validation, receive-session pruning, and regtest coverage for persisted flows.
Stop carrying deserialize support for outgoing websocket notifications and keep notification payload handling on the serialized event path.

Update Cashu and CDK pub-sub event types, including the NUT-30 payjoin notification payload, to match the reduced decoding surface.
Add chain backend support for checking whether a transaction was broadcast so payjoin recovery can distinguish unpublished and published sessions.

Persist and check broadcast state during payjoin handling, and add NUT-17 notification coverage for the broadcast status event.
Replace raw payjoin quote key strings with typed NUT-31 quote key structures across Cashu, CDK common, BDK, CLI, FFI, and docs.

Tighten quote-id tests and wallet saga plumbing so payjoin metadata is parsed and passed through consistently.
Add receive-side payjoin session records and hook them into BDK recovery so pending receiver state can be reconstructed after restart.

Persist receive session identifiers alongside payment intents and route resumed receive work through the payjoin session module.

Update integration test helpers for payjoin receive flows.
Persist sender payjoin request and response state with storage APIs and chain-backend hooks so interrupted send sessions can resume.

Rehydrate pending sender intents through recovery and send service startup, including broadcast tracking and stored payment intent metadata.
Wire startup checks, receive storage, and payment trait support for payjoin recovery so outstanding sessions are resumed when services come up.

Consolidate Payjoin send recovery onto PayjoinNegotiating send intents instead of maintaining a duplicate send-session store.

Extend onchain regtest coverage for startup recovery and persisted receive flows.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Backlog

Development

Successfully merging this pull request may close these issues.

1 participant