Auth
Endpoints for authentication
Enter credentials to get JWT token.
Body
Request for user authentication
usernamestringRequiredExample:
Username of the user
john_doe
passwordstringRequiredExample:
Password of the user
password123
namestringRequiredExample:
Name of the user
Joe Don
Responses
200
OK
*/*
401
Unauthorized
*/*
403
Forbidden
*/*
409
Conflict
*/*
500
Internal Server Error
*/*
post
POST /api/auth/register HTTP/1.1
Host: localhost:8080
Content-Type: application/json
Accept: */*
Content-Length: 65
{
"username": "john_doe",
"password": "password123",
"name": "Joe Don"
}
{
"token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9..."
}
Enter credentials to get JWT token.
Body
Request for user authentication
usernamestringRequiredExample:
Username of the user
john_doe
passwordstringRequiredExample:
Password of the user
password123
Responses
200
OK
*/*
401
Unauthorized
*/*
403
Forbidden
*/*
409
Conflict
*/*
500
Internal Server Error
*/*
post
POST /api/auth/login HTTP/1.1
Host: localhost:8080
Content-Type: application/json
Accept: */*
Content-Length: 48
{
"username": "john_doe",
"password": "password123"
}
{
"token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9..."
}
Was this helpful?