VideohatiDocs
API referenceAuthentication

Log in with email and password

Log in with email and password

POST/v1/auth/login

On success sets the better_auth.session_token cookie (HttpOnly, Secure, SameSite=Lax). Rate limit: 30 requests per 60 s per IP.

Error codes: bad_credentials (401), email_not_verified (403), rate_limit_exceeded (429).

Authentication

  • This operation needs no authentication.

Parameters

This operation takes no parameters.

Request body

required

Content type: application/json

Schema: LoginRequest

{
  "email": "founder@academy.example",
  "password": "correct-horse-battery"
}

Responses

StatusMeaning
200Logged in; session cookie set.
401No valid credential was presented.
403The credential is valid but does not permit this action. The per-operation description lists the exact error.code values.
429Rate limit exceeded.

Example request

{
  "email": "founder@academy.example",
  "password": "correct-horse-battery"
}

Try it

POST
/v1/auth/login
No authentication

API playground

Send a live request to the Videohati API; this operation needs no authentication.

https://api.staging.videohati.com/v1/auth/login