Add event requesting instructions

This commit is contained in:
arthurfranca 2024-02-09 19:22:48 -03:00
parent 1a13871566
commit ee4011d84e

16
00.md
View File

@ -41,7 +41,7 @@ It uses the custom NIP-42 event serialization for events that require `AUTH`.
The `.content` and other tags aren't fixed. The structure depends on the
kind of the public event it is protecting. For example, if it is
protecting a `kind:30023`, it should have the structure defined on [NIP-23](23.md).
protecting a `kind:30023` event, it should have the structure defined on [NIP-23](23.md).
Example:
@ -61,3 +61,17 @@ Example:
...
}
```
## Requesting the Event
The client is expected to initially request the public event. For example, a microblogging client
will request `kind:1` events as usual.
If one of these events includes a `full_event` tag,
the client should request it with a filter that includes
a `#A` filter key set to the client's user pubkey.
If the user has rights to access the full event, the relay will send it
after the NIP-42 authentication flow.
For example: `{ kinds: [30042], authors: ["abc"], #d: ["xyz"], #A: ["<client's user pubkey>"], limit: 1 }`