diff options
author | Luke Barnard <lukeb@openmarket.com> | 2017-05-03 11:55:44 +0100 |
---|---|---|
committer | Luke Barnard <lukeb@openmarket.com> | 2017-05-03 12:04:12 +0100 |
commit | 34ed4f4206b4ff6830c381beabbaa7739b1a63f8 (patch) | |
tree | fc7d7f3752b1a863728e5fb7ce874ad37f339e94 /tests/test_state.py | |
parent | Merge pull request #2180 from matrix-org/rav/fix_timeout_on_timeout (diff) | |
download | synapse-34ed4f4206b4ff6830c381beabbaa7739b1a63f8.tar.xz |
Implement username availability checker
Outlined here: https://github.com/vector-im/riot-web/issues/3605#issuecomment-298679388 ```HTTP GET /_matrix/.../register/available { "username": "desiredlocalpart123" } ``` If available, the response looks like ```HTTP HTTP/1.1 200 OK { "available": true } ``` Otherwise, ```HTTP HTTP/1.1 429 { "errcode": "M_LIMIT_EXCEEDED", "error": "Too Many Requests", "retry_after_ms": 2000 } ``` or ```HTTP HTTP/1.1 400 { "errcode": "M_USER_IN_USE", "error": "User ID already taken." } ``` or ```HTTP HTTP/1.1 400 { "errcode": "M_INVALID_USERNAME", "error": "Some reason for username being invalid" } ```
Diffstat (limited to 'tests/test_state.py')
0 files changed, 0 insertions, 0 deletions