Merge pull request #949 from schmijos/patch-1

Reword REQ for multiple filters
This commit is contained in:
hodlbod 2023-12-26 12:28:52 -08:00 committed by GitHub
commit 92f3a45bdc
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

4
01.md
View File

@ -101,12 +101,12 @@ Relays expose a websocket endpoint to which clients can connect. Clients SHOULD
Clients can send 3 types of messages, which must be JSON arrays, according to the following patterns:
* `["EVENT", <event JSON as defined above>]`, used to publish events.
* `["REQ", <subscription_id>, <filters JSON>, ...]`, used to request events and subscribe to new updates.
* `["REQ", <subscription_id>, <filters1>, <filters2>, ...]`, used to request events and subscribe to new updates.
* `["CLOSE", <subscription_id>]`, used to stop previous subscriptions.
`<subscription_id>` is an arbitrary, non-empty string of max length 64 chars, that should be used to represent a subscription. Relays should manage `<subscription_id>`s independently for each WebSocket connection; even if `<subscription_id>`s are the same string, they should be treated as different subscriptions for different connections.
`<filters>` is a JSON object that determines what events will be sent in that subscription, it can have the following attributes:
`<filtersX>` is a JSON object that determines what events will be sent in that subscription, it can have the following attributes:
```json
{