Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/eggarcia98/auth-backend/llms.txt

Use this file to discover all available pages before exploring further.

POST /api/v1/auth/logout Invalidates the current access token and clears the accessToken and refreshToken cookies.

Request

Headers

Authorization
string
required
Bearer token for authentication. Format: Bearer <accessToken>.

Response

success
boolean
Whether the request succeeded.
data
object

Cookies cleared

On success, the server clears the following cookies:
CookieAction
accessTokenCleared
refreshTokenCleared

Examples

curl --request POST \
  --url https://your-api.example.com/api/v1/auth/logout \
  --header 'Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9...'

Success response (200)

{
  "success": true,
  "data": {
    "message": "Logged out successfully"
  }
}

Errors

HTTP statusCodeDescription
401UNAUTHORIZEDThe Authorization header is missing or the token is invalid.

Build docs developers (and LLMs) love