Overview
The Doss API uses Laravel Passport for authentication. After a successful login, the server returns anaccess_token. Include this token in the Authorization header of every subsequent request:
https://your-domain.com/api
GET /check-login-via
Returns how login is configured on this instance — email only, phone only, or either.Response fields
HTTP status code.
200 on success.One of
email_only, phone_only, or email_or_phone.POST /login
Authenticates a user and returns a Passport Bearer token.Request parameters
The user’s email address. When
loginVia is phone_only, pass the phone number here instead.The user’s plaintext password.
Response fields
Error responses
| Status | Reason |
|---|---|
401 | Invalid credentials or user not found |
201 | Email not yet verified — activation link has been resent |
200 with user-status: Inactive | Account is inactive |
GET /check-user-status
Checks whether a specific user account is active, inactive, or suspended. This endpoint does not require an Authorization header.Request parameters
The ID of the user to check.
Response fields
200 on success.Account status:
Active, Inactive, or Suspended.POST /logout
Revokes the current user’s Passport access token. No request body is required — the token is identified from theAuthorization header.
Requires
Authorization: Bearer {token} header.Response fields
200 on success.Confirmation message.