0 people focusing right now

GET /api/all-projects

Get combined view of all projects (individual + team)

Projects System Overview

RegardingWork has three project types:

Get a unified view of all projects (both individual and team projects) accessible to the authenticated user.

Comprehensive View: This endpoint combines data from both /api/projects and /api/team-projects for convenience.
Endpoint URL
GET https://game.regardingwork.com/api/all-projects
Authentication
JWT Bearer token required
Status
✅ Available
Available Now

This endpoint is live and combines data from both individual and team projects in one convenient call.

  • Perfect for Mac/Windows apps that need all projects at once
  • Includes both personal (👤) and team (🫂) projects with type indicators
  • Eliminates need for multiple API calls

📤 Request

Headers
Authorization: Bearer <your_jwt_token>
Optional Query Parameters
  • include_inactive - Include inactive projects (true/false, default: false)
  • sort - Sort by: "recent", "name", "sessions", "type" (default: type)
  • group_by_type - Group results by project type (true/false, default: true)

✅ Response (200 OK)

{
  "success": true,
  "projects": [
    {
      "id": "4",
      "name": "Personal Website",
      "type": "personal",
      "team_name": null,
      "source": "project",
      "project_id": 4,
      "project_tag": "Personal Website",
      "is_formal_project": true
    },
    {
      "id": "session_Innovemind",
      "name": "Innovemind",
      "type": "personal",
      "team_name": null,
      "session_count": 7,
      "source": "session_history",
      "project_id": null,
      "project_tag": "Innovemind",
      "is_formal_project": false
    },
    {
      "id": "team_6",
      "name": "Core Product",
      "type": "team",
      "team_name": "Development Team",
      "source": "team_project",
      "team_project_id": 6,
      "project_tag": "team_6"
    }
  ]
}
Response Fields
Field Type Description
success boolean Request success status
projects[] array Flat list of formal personal projects, legacy session-history projects, and team projects
source string "project", "session_history", or "team_project"
project_id number or null Numeric ID for formal personal projects; null for session-history projects
team_project_id number Numeric ID for team projects
is_formal_project boolean True for Project rows, false for legacy session-history projects
id string Legacy-compatible display/submission identifier. Use source plus numeric IDs for type-safe identity.

🔧 Client Identity Handling

Use source to identify the origin of each row. Keep reading id for backward-compatible display/submission behavior, but branch on the explicit metadata for stable client logic.

JavaScript Example
async function getAllProjects() {
  const token = localStorage.getItem('jwt_token');
  const headers = { 'Authorization': 'Bearer ' + token };

  const response = await fetch('https://game.regardingwork.com/api/all-projects', { headers });
  const data = await response.json();

  return (data.projects || []).map(project => ({
    legacyId: project.id,
    name: project.name,
    source: project.source,
    projectId: project.project_id,
    teamProjectId: project.team_project_id,
    isFormalProject: project.is_formal_project === true
  }));
}

🔗 Related Endpoints