auth.v1.ProfileService
GenerateUsernameOptions
Generate five random username options for an account that has never claimed a username. Calling this method again returns a fresh set.
Method
POST
Path
auth.v1.ProfileService/GenerateUsernameOptions
Service
auth.v1.ProfileService
Visibility
Authentication
Session token
MFA Requirement
Not required
POST
auth.v1.ProfileService/GenerateUsernameOptions Request
Testnet
curl --request POST \ \
--url 'https://api.testnet.polyester.com/auth.v1.ProfileService/GenerateUsernameOptions' \
--header 'Content-Type: application/json' \
--header 'Connect-Protocol-Version: 1' \
--data '{}'Responses
{
"expiresAt": "2025-01-01T00:00:00Z",
"offerToken": "eyJ2IjoxLCJzdWIiOiI3NTYzODk3NDQ2NTQ2IiwidXNlcm5hbWVzIjpbImFscGhhX3RyYWRlciIsImJldGFfYnVpbGRlciIsImdhbW1hX21ha2VyIiwiZGVsdGFfY2hhcnQiLCJlcHNpbG9uX2Rlc2siXSwiZXhwIjoxNzY3MjI2MjAwfQ.ZXhhbXBsZS1zaWduYXR1cmU",
"usernames": [
"value"
]
}Request
auth.v1.GenerateUsernameOptionsRequestResponse
auth.v1.GenerateUsernameOptionsResponse usernames string[]
Five distinct generated usernames available when this offer was created.
offerToken string
Opaque proof required to claim one of the returned usernames.
expiresAt string (date-time)
Time in UTC after which this offer can no longer be claimed.
| Key | HTTP status | Connect code | Error | When |
|---|---|---|---|---|
| unauthenticated | 401 | unauthenticated | Unauthenticated | Authentication required. |
| permission-denied | 403 | permission_denied | Permission Denied | Permission denied. |
| invalid-argument | 400 | invalid_argument | Invalid Argument | Invalid argument. |
| not-found | 404 | not_found | Not Found | Not found. |
| unavailable | 503 | unavailable | Unavailable | Service unavailable. |