When creating tasks, the frontend receives a 422 validation error:
{
"field": "columnId",
"message": "Valid column ID is required",
"value": "todo"
}The backend requires a valid column ID (UUID from the database), but the frontend has no way to fetch the available columns for a project.
Please implement the following endpoints for managing project columns:
Endpoint: GET /api/v1/projects/:projectId/columns
Description: Returns all columns (statuses) for a specific project.
Response:
{
"success": true,
"data": [
{
"id": "uuid-column-1",
"title": "To Do",
"color": "#6366f1",
"projectId": "uuid-project-1",
"position": 0,
"createdAt": "2024-01-01T00:00:00.000Z",
"updatedAt": "2024-01-01T00:00:00.000Z"
},
{
"id": "uuid-column-2",
"title": "In Progress",
"color": "#f59e0b",
"projectId": "uuid-project-1",
"position": 1,
"createdAt": "2024-01-01T00:00:00.000Z",
"updatedAt": "2024-01-01T00:00:00.000Z"
}
]
}Endpoint: POST /api/v1/projects/:projectId/columns
Request Body:
{
"title": "In Review",
"color": "#8b5cf6",
"position": 2
}Response:
{
"success": true,
"data": {
"id": "uuid-column-3",
"title": "In Review",
"color": "#8b5cf6",
"projectId": "uuid-project-1",
"position": 2,
"createdAt": "2024-01-01T00:00:00.000Z",
"updatedAt": "2024-01-01T00:00:00.000Z"
}
}Endpoint: PATCH /api/v1/projects/:projectId/columns/:columnId
Request Body:
{
"title": "Done",
"color": "#10b981"
}Endpoint: DELETE /api/v1/projects/:projectId/columns/:columnId
Response:
{
"success": true,
"message": "Column deleted successfully"
}When a project is created, please create these default columns automatically:
- To Do -
#6366f1(indigo) - In Progress -
#f59e0b(amber) - In Review -
#8b5cf6(purple) - Done -
#10b981(green)
interface Column {
id: string // UUID
title: string // Column name
color: string // Hex color code
projectId: string // Reference to project
position: number // Order in the board (0-indexed)
createdAt: string // ISO timestamp
updatedAt: string // ISO timestamp
}HIGH - This is blocking task creation. The frontend cannot create tasks without valid column IDs.
Until these endpoints are implemented, please provide:
- The column IDs that were created for existing projects
- OR make
columnIdoptional in task creation and auto-assign to the first column - OR return column IDs in the project details response
The frontend already has:
- Column type definitions (
lib/types.ts) - Column service stub (
services/columns.service.ts) - Column context for state management
Once the backend endpoints are available, we can immediately integrate them.
Please let me know if you need any clarification on the required endpoints or data structures.