lnconsole / nips Goto Github PK
View Code? Open in Web Editor NEWThis project forked from nostr-protocol/nips
Nostr Implementation Possibilities
This project forked from nostr-protocol/nips
Nostr Implementation Possibilities
draft
optional
author: cjchua
superchat service request
: kind 1111
regular event with p
tag referencing service provider, e
tag referencing a kind40 channel. Clients register for a superchat service using this event.{
"kind": 1111,
"pubkey": <kind40_creator>
"tags": [
["p", <service_provider>, <relay_url>],
["e", <kind40_event_id>, <relay_url>],
],
}
superchats
: kind 33333
parameterized replaceable event with d
tag referencing the channel requesting the service. This event contains a dynamic list of active superchats.{
"kind": 33333,
"pubkey": <service_provider>,
"tags": [
["d", <kind40_event_id>],
["superchat", <amount_sat>, <created_timestamp>, <user_pubkey>, <content>], // example
["superchat", "50", "1678443555", "bfd121a3.....4f063e7", "this is a superchat"],
],
}
superchat request
: kind 22222
event with a
tag referencing superchats
payment request
: kind 22222
event with a
tag referencing superchats
and p
tag referencing user// Scenario 1: User making a `superchat request`
{
"kind": 22222,
"pubkey": <user>,
"content": <amount_sat>,
"tags": [
["a", "33333:<service_provider>:<kind40_event_id>", <relay_url>],
],
}
// Scenario 2: Service provider providing a `payment request`
{
"kind": 22222,
"pubkey": <service_provider>,
"content": "optional comment",
"tags": [
["a", "33333:<service_provider>:<kind40_event_id>", <relay_url>],
["p", <user>, <relay_url>],
["bolt11", "lnbc...."],
],
}
a. Service Provider
superchat service request
. Validate the provided kind40 event and that the requester is the channel creatorsuperchats
and subscribe to superchat request
superchat request
by replying with a payment request
payment request
is paid, update and publish superchats
superchats
at willb. Client
superchats
and display to the user. There may be more than one service provider offering this service. It is the client's prerogative to either default to a service provider, or provide more flexibility by allowing users to pick a service providersuperchat request
on user's requestpayment request
by presenting the bolt11 to the userA declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.