Doctor Logout (v1)
Method & Path
POST /api/v1/doctors/logout
Actual backend path: /v1/doctors/logout
Description
End the current doctor session by revoking the refresh token and clearing authentication cookies.
Authentication
Required: Bearer token in Authorization header or refresh token in cookie
Required Permissions:
- Doctor authentication
Headers
| Header | Type | Required | Description |
|---|---|---|---|
Authorization | string | Yes | Bearer token: Bearer <token> |
| Cookie | string | Yes | refreshToken cookie (HTTP-only) |
Request Body
No request body required.
Response 204 No Content
The response has no content. Authentication cookies are cleared.
Common Errors
- 401 Unauthorized: Missing or invalid authentication token, or invalid refresh token
- 500 Internal Server Error: Server error