48 lines
974 B
Markdown
48 lines
974 B
Markdown
# MSC2140
|
|
|
|
## V1 vs V2
|
|
In the [MSC2140](https://github.com/matrix-org/matrix-doc/pull/2140) the v2 prefix was introduced.
|
|
|
|
Default values:
|
|
```.yaml
|
|
matrix:
|
|
v1: true # deprecated
|
|
v2: true
|
|
```
|
|
|
|
To disable change value to `false`.
|
|
|
|
NOTE: the v1 is deprecated, therefore recommend to use only v2 and disable v1 (default value can be ommited):
|
|
```.yaml
|
|
matrix:
|
|
v1: false
|
|
```
|
|
|
|
## Terms
|
|
|
|
Example:
|
|
```.yaml
|
|
policy:
|
|
policies:
|
|
term_name: # term name
|
|
version: 1.0 # version
|
|
terms:
|
|
en: # lang
|
|
name: term name en # localized name
|
|
url: https://ma1sd.host.tld/term_en.html # localized url
|
|
fe: # lang
|
|
name: term name fr # localized name
|
|
url: https://ma1sd.host.tld/term_fr.html # localized url
|
|
regexp:
|
|
- '/_matrix/identity/v2/account.*'
|
|
- '/_matrix/identity/v2/hash_lookup'
|
|
```
|
|
Where:
|
|
|
|
- `term_name` -- name of the terms.
|
|
- `regexp` -- regexp patterns for API.
|
|
|
|
|
|
## Hash lookup
|
|
|