Registration Endpoint POST
The register endpoint allows users to create a new account by providing their desired username and password.
POST
/user/register
content_copy
Request Body Parameters
Parameter
Type
Description
username
String
The desired unique username for the new account.
password
String
The password for the new account.
Responses
Successful Registration
- Status Code: 200 Ok
- Response Body:
json
{
"message"
:
"Registration Successful for [username]."
}
Username Already Registered
- Status Code: 409 Conflict
- Response Body:
json
{
"error"
:
"Username already registered"
}
Validation Error
- Status Code: 422 Bad Request
- Response Body:
json
{
"error"
:
"[Validation Error Message]"
}
Change Username Endpoint PATCH
The username endpoint allows users to change their account's username.
PATCH
/user/change-username
content_copy
Authorization Header
This endpoint uses Basic Authentication for the changing of account's username.
Parameter
Type
Description
username
String
The registered username of the user.
password
String
The registered password of the user.
Request Body Parameters
Parameter
Type
Description
new_username
String
The desired new username of the user.
Response
Successful Username Change
- Status Code: 200 Ok
- Response Body:
json
{
"message"
:
"Successful username update."
,
}
Change Password Endpoint PATCH
The password endpoint allows users to change their account's password.
PATCH
/user/change-password
content_copy
Authorization Header
This endpoint uses Basic Authentication for the changing of account's password.
Parameter
Type
Description
username
String
The registered username of the user.
password
String
The registered password of the user.
Request Body Parameters
Parameter
Type
Description
new_password
String
The desired new password of the user.
Response
Successful Password Change
- Status Code: 200 Ok
- Response Body:
json
{
"message"
:
"Successful password update."
,
}