keybase / keybase/keybase-issues
There's a limit on user name length?
- Dominant language
- No language data
- Stars
- 899
- Forks
- 40
- PR merge metrics
- No merged PRs in 30d
Description
Part bug, part question I guess. I noticed this when playing around with the HTTP API. The following returns NOT_FOUND (more or less as expected):
```
> curl 'https://keybase.io/_/api/1.0/user/lookup.json?username=abcdefghijklmnop'
{
"status": {
"code": 205,
"desc": "user not found abcdefghijklmnop",
"name": "NOT_FOUND"
},
"guest_id": "23a720cc7d9a69257ceb8ef3a504dd08",
"csrf_token": "lgHZIDIzYTcyMGNjN2Q5YTY5MjU3Y2ViOGVmM2E1MDRkZDA4zlNAmQTOAAFRgMDEIGL0fyMu6s7B5ccsuuxSG14EFptgTrVq6FBRbiLCE+eC"
}%
```
But trying a user name with 18 characters in it gives you an INPUT_ERROR:
```
> curl 'https://keybase.io/_/api/1.0/user/lookup.json?username=abcdefghijklmnopq'
{
"status": {
"code": 100,
"desc": "missing or invalid input",
"fields": {
"username": "invalid name"
},
"name": "INPUT_ERROR"
}
}%
```
That INPUT_ERROR return is consistent for all usernames >17 characters. Seems somewhat arbitrary to limit usernames but maybe there's a reason for it? In any case, mentioning this in the API docs would be a good idea. I pre-check for username length in any client that access the API could give a better error message since the one returned is somewhat ambiguous. Is it invalid because of length? The characters? Because it doesn't belong to a user who exists?
Definitely I'd consider adding this to the doc page for `signup.json` as it has an impact there as well.
Contributor guide
No contributing guide indexed for this repository
Research direction
Locate the API documentation for user/lookup.json and signup.json, then verify the reported behavior for usernames longer than 17 characters. Document the username length constraint and clarify what the INPUT_ERROR means, including the affected endpoints.
Written by the indexing model from the issue text.
Assessment
- Domain
- documentation
- Issue type
- Documentation
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100