Class: Service.Accounts
The accounts service provides various methods to create new accounts
Function: POST /accounts
Create a new account
(start code)
post {
username: "franklin",
password: "secretsauce"
}
returns {
id: 12345,
allocation: 94
}
(end)
Parameters:
username - The username. Must be between 1 and 8 characters long (idx: 1, type: <Types.username>)
password - The account password. Must be at least 1 characters long. Must match m/^[^ ]+$/ (idx: 2, type: <Types.password>)
is_admin - no docs (idx: 3, type: <Thrift.bool>, optional: 1)
Returns:
<Types.account>
Throws:
<Exceptions.insufficientResources> (idx: 1)
<Exceptions.genericCode> (idx: 2)
Function: GET /account/:username
Get an account by username
Parameters:
username - Must be between 1 and 8 characters long (idx: 1, type: <Types.username>)
Returns:
<Types.account>
Throws:
<Exceptions.genericCode> (idx: 1)