diff options
| author | Kieran <kieran@harkin.me> | 2024-10-15 11:15:54 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-10-15 11:15:54 +0100 |
| commit | 1e2f19863ca56754daa2466881eb22087a71b17d (patch) | |
| tree | 4f7be759dce290fea1d3ae10c403260b466ee16c /50.md | |
| parent | 53afaaece61f02e92b5ef9c3e9c32945c7ebf522 (diff) | |
| parent | e381b577c997b849fa544eea7dc9f08b360b4a33 (diff) | |
Merge branch 'master' into nip71-imeta
Diffstat (limited to '50.md')
| -rw-r--r-- | 50.md | 6 |
1 files changed, 4 insertions, 2 deletions
| @@ -15,9 +15,9 @@ extensible framework for performing such queries. | |||
| 15 | ## `search` filter field | 15 | ## `search` filter field |
| 16 | 16 | ||
| 17 | A new `search` field is introduced for `REQ` messages from clients: | 17 | A new `search` field is introduced for `REQ` messages from clients: |
| 18 | ```json | 18 | ```jsonc |
| 19 | { | 19 | { |
| 20 | ... | 20 | // other fields on filter object... |
| 21 | "search": <string> | 21 | "search": <string> |
| 22 | } | 22 | } |
| 23 | ``` | 23 | ``` |
| @@ -26,6 +26,8 @@ Relays SHOULD interpret the query to the best of their ability and return events | |||
| 26 | Relays SHOULD perform matching against `content` event field, and MAY perform | 26 | Relays SHOULD perform matching against `content` event field, and MAY perform |
| 27 | matching against other fields if that makes sense in the context of a specific kind. | 27 | matching against other fields if that makes sense in the context of a specific kind. |
| 28 | 28 | ||
| 29 | Results SHOULD be returned in descending order by quality of search result (as defined by the implementation), | ||
| 30 | not by the usual `.created_at`. The `limit` filter SHOULD be applied after sorting by matching score. | ||
| 29 | A query string may contain `key:value` pairs (two words separated by colon), these are extensions, relays SHOULD ignore | 31 | A query string may contain `key:value` pairs (two words separated by colon), these are extensions, relays SHOULD ignore |
| 30 | extensions they don't support. | 32 | extensions they don't support. |
| 31 | 33 | ||