Skip to main content

Manage Accounts


Create new accounts

POST /user/create
Body(Json)
keystypeDescription
usernamerequiredusername of the user
emailrequiredemail of the user
passwordrequiredpassword of the user
nameoptionalreal name of the user
biooptionalbio of the user
pronounceoptionalpronounce of the username
websiteoptionalwebsite of the user
Responses
http codecontent-typeresponse
200application/json{"statusCode":"200","message":"User created successfully","data":"$data"}
406application/json{"statusCode":"406","message":"Name cannot be less than 3 or over 150 characters","data":"null"}
406application/json{"statusCode":"406","message":"Username cannot be less than 3 or over 100 characters","data":"null"}
406application/json{"statusCode":"406","message":"Password cannot be less than 8 or over 200 characters","data":"null"}
406application/json{"statusCode":"406","message":"Invalid email","data":"null"}
406application/json{"statusCode":"406","message":"Bio cannot be over 200 characters","data":"null"}
400application/json{"statusCode":"400","message":"Username cannot contain white space",data"null"}
400application/json{"statusCode":"400","message":"Username cannot be null","data":"null"}
400application/json{"statusCode":"400","message":"Username cannot be empty","data":"null"}
400application/json{"statusCode":"400","message":"Email cannot be null","data":"null"}
400application/json{"statusCode":"400","message":"Email cannot be empty","data":"null"}
400application/json{"statusCode":"400","message":"Password cannot be null","data":"null"}
400application/json{"statusCode":"400","message":"Password cannot be empty","data":"null"}
400application/json{"statusCode":"400","message":"name cannot be empty","data":"null"}
400application/json{"statusCode":"400","message":"Password cannot be bio","data":"null"}
400application/json{"statusCode":"400","message":"Website cannot be empty","data":"null"}
400application/json{"statusCode":"400","message":"Pronounce cannot be empty","data":"null"}
409application/json{"statusCode":"400","message":"User already exists","data":"null"}
409application/json{"statusCode":"400","message":"Email already exists","data":"null"}

Authenticate Users

POST /user/auth
Body(Json)
keystypeDescription
usernamerequiredusername of the user
passwordrequiredpassword of the user
Responses
http codecontent-typeresponse
200application/json{"statusCode":"200","message":"Authenticated","data":"null"}
401application/json{"statusCode":"401","message":"Authenticated failed","data":"null"}
406application/json{"statusCode":"406","message":"Username cannot be less than 3 or over 100 characters","data":"null"}
406application/json{"statusCode":"406","message":"Password cannot be less than 8 or over 200 characters","data":"null"}
400application/json{"statusCode":"400","message":"Username cannot contain white space",data"null"}
400application/json{"statusCode":"400","message":"Username cannot be null","data":"null"}
400application/json{"statusCode":"400","message":"Username cannot be empty","data":"null"}
400application/json{"statusCode":"400","message":"Password cannot be null","data":"null"}
400application/json{"statusCode":"400","message":"Password cannot be empty","data":"null"}

See if the user is logged in or not

GET /user/logged
Responses
http codecontent-typeresponse
200application/json{"statusCode":"200","message":"Validation","data":"true"}
404application/json{"statusCode":"404","message":"TOKEN was not found","data":"false"}
404application/json{"statusCode":"404","message":"No auth info found","data":"true"}

Get info about user

GET /user/profile/$username$
Responses
http codecontent-typeresponse
200application/json{"statusCode":"200","message":"{username}","data":"{"username":"{username}","name":"","bio":"","website":"","pronounce":"","followers":"","following":""}"}
404application/json{"statusCode":"404","message":"User not found","data":"false"}

Resets the password

POST /user/password-reset
Body(Json)
keystypeDescription
uuidrequireduuid of the request
newPasswordrequirednew password of the user
Responses
http codecontent-typeresponse
200application/json{"statusCode":"200","message":"New password has been set successfully","data":"null"}
406application/json{"statusCode":"406","message":"Password cannot be less than 8 or over 200 characters","data":"null"}
406application/json{"statusCode":"406","message":"Token is expired","data":"null"}
400application/json{"statusCode":"400","message":"Username cannot contain white space",data"null"}
400application/json{"statusCode":"400","message":"UUID cannot be null","data":"null"}
400application/json{"statusCode":"400","message":"UUID cannot be empty","data":"null"}
400application/json{"statusCode":"400","message":"Password cannot be null","data":"null"}
400application/json{"statusCode":"400","message":"Password cannot be empty","data":"null"}
404application/json{"statusCode":"400","message":"Token not found","data":"null"}
404application/json{"statusCode":"400","message":"User not found","data":"null"}

Create password reset token

POST /user/password-reset-token
Parameters
nametypeDescription
emailrequiredemail of the user
Responses
http codecontent-typeresponse
200application/json{"statusCode":"200","message":"Password reset token generated","data":"null"}
404application/json{"statusCode":"400","message":"User with this email not found","data":"null"}