Staff Login (v1)
Method + Path
POST /v1/workspace/:workspaceId/staff/login
Actual backend path: /v1/workspace/:workspaceId/staff/login
Description
Authenticate a staff member and receive a JWT token for subsequent API requests.
Authentication
Not required - This endpoint is used for authentication
Headers
| Header | Type | Required | Description |
|---|---|---|---|
Content-Type | string | Yes | application/json |
Path Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
workspaceId | string | Yes | Workspace identifier |
Request Body
{
"email": "john@example.com",
"password": "securepassword123"
}
Body Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
email | string | Yes | Staff member's email address |
password | string | Yes | Staff member's password (minimum 8 characters) |
Response (200)
{
"token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9...",
"staff": {
"id": "507f1f77bcf86cd799439011",
"fullName": "John Doe",
"email": "john@example.com",
"permissions": ["sessions.view", "sessions.create"],
"status": "active"
}
}
Common Errors
- 400 Bad Request: Invalid request body
- 401 Unauthorized: Invalid email or password
- 403 Forbidden: Staff member is suspended
- 404 Not Found: Workspace not found or staff member not found
- 500 Internal Server Error: Server error