-
Notifications
You must be signed in to change notification settings - Fork 16
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
BUD-07 Paid storage #29
base: master
Are you sure you want to change the base?
BUD-07 Paid storage #29
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks great, a few formatting fixes and one comment. but I really like how simple this is
Co-authored-by: hzrd149 <8001706+hzrd149@users.noreply.github.com>
Co-authored-by: hzrd149 <8001706+hzrd149@users.noreply.github.com>
Co-authored-by: hzrd149 <8001706+hzrd149@users.noreply.github.com>
Co-authored-by: hzrd149 <8001706+hzrd149@users.noreply.github.com>
L402 has been discarded in favor of a simpler approach that maintains the overall intent while adding compatibility with any L2, and potentially even other payment methods. |
New version for the PR. This new version replaces the generic X-Payment header with dedicated headers for each supported payment method (e.g., X-Cashu, X-Lightning). This change improves clarity, scalability, and compatibility with future payment systems. |
|
Added recurring payments section with support for Cashu (NIP-61) and Lightning (NIP-57), requiring an 'x' tag for blob hash reference. |
Co-authored-by: hzrd149 <8001706+hzrd149@users.noreply.github.com>
Co-authored-by: hzrd149 <8001706+hzrd149@users.noreply.github.com>
Co-authored-by: hzrd149 <8001706+hzrd149@users.noreply.github.com>
Co-authored-by: hzrd149 <8001706+hzrd149@users.noreply.github.com>
Co-authored-by: hzrd149 <8001706+hzrd149@users.noreply.github.com>
Co-authored-by: hzrd149 <8001706+hzrd149@users.noreply.github.com>
Would it not be better to have a simple Returning |
Im looking to implement payments in |
I see what you mean, but I don’t think it’s incompatible. This BUD is just about what happens when you try to access a paid resource, it lays out the expected behavior when payment is required. In my server (which this BUD is up and running 🤓), the client does a But if you’re thinking of submitting another BUD for managing user accounts, I’ve got some ideas for As for the POST you mentioned, maybe it could be a more general |
@v0l you can try it here: |
BUD-07 paid storage
This pull request introduces
BUD-07
, a new specification outlining how servers can require and handle payments for blob storage. It defines the use of402 Payment Required
responses, with payment details provided viaX-{payment_method}
headers adhering to method-specific standards like Cashu (NIP-18) and Lightning (BOLT-11).Additionally, it introduces support for recurring payments using Nostr events (Cashu via NIP-61 and Lightning via NIP-57), requiring an x tag to reference specific blobs.
The specification is designed to be extensible for future payment methods and includes guidance on client-server interactions.
Readable version here