Skip to main content

Account

POST /api/auth/signup​

Sign up for a new account.

Authorization: None

Content type: application/json

Request body schema​

KeyTypeDescription
emailstringThe email of the account
nickNamestringThe nickname of the account
gamePlayerNamestringThe username used by the account in Minecraft
passwordstringThe password of the account

Response​

Content type: application/json

201​

The user has been created without errors.

400​

Failed to create the account.

POST /api/auth/signin​

Sign in to an existing account.

Authorization: None

Content type: application/json

Request body schema​

KeyTypeDescription
gamePlayerNamestringThe username used by the account in Minecraft
passwordstringThe password of the account

Response​

Content type: application/json

Successfully validate the password, and a JWT token will be returned.

Status code: 200

Cookies:

  • authToken: A JWT token issued by the server.

Body:

KeyTypeDescription
tokenstringThe JWT token mentioned above