doc: send/receive keys

This commit is contained in:
Vlad Stan 2023-04-10 13:25:15 +03:00 committed by GitHub
parent c5e91ab2c0
commit 65a44195fb
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

10
704.md
View File

@ -49,12 +49,14 @@ We notate the above derived `direct message public key` with `dmpk`. Then we ca
| Action Name | Value | Path | Derive keys for |
|-----------------------|--------|---------------------|-----------------------------------|
| **receive** | `0` | `dmpk/0/<index>` | receiving `direct messages` |
| **send** | `1` | `dmpk/1/<index>` | sending `direct messages` |
| **send** | `0` | `dmpk/0/<index>` | sending `direct messages` |
| **receive** | `1` | `dmpk/1/<index>` | receiving `direct messages` |
| `draft`: republish | `2` | `dmpk/2/<index>` | sending `republish events` |
| `draft` :market-order | `4500` | `dmpk/4500/<index>` | sending NIP45 `market orders` |
| `draft`: market-order | `4500` | `dmpk/4500/<index>` | sending NIP45 `market orders` |
send, receive, marketplace
The client (creator of the `dmpk`) must:
- use a new send key (`dmpk/0/<index>`) for each event it signs. It starts from `0` and increments after an event is signed.
- create filters for the public keys it expects to receive messages to (`dmpk/1/<index>`). It is recommended to listen for the next `10` keys.
## Exchange the `direct message parent key`
If `Alice` wants to signal `Bob` that she is ready to use this NIP (for more privacy) she must: