auth

User login

Authenticate user with email and password, returns JWT token

post/auth/login

Request

  • Base URL
    https://api.tonewow.com (the document declares no server; this is the origin it was published from)
  • URL
    https://api.tonewow.com/auth/login
  • Auth
    none declared

Request body

emailstring required

User email address

passwordstring required

User password

Example request

{
  "email": "admin@example.com",
  "password": "password123"
}

Response

Login successful

access_tokenstring required
user_idnumber required
namestring required
emailstring required
rolesstring[] required

Example response

{
  "access_token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9...",
  "user_id": 1,
  "name": "John Doe",
  "email": "admin@example.com",
  "roles": [
    "admin"
  ]
}

Changes

No recorded changes to this operation across all 6 revisions of this API.