GET /api/deep-work/projects/{project_id}/plan Bearer

Get Deep Work Plan

Retrieve the generated plan for a Deep Work project including the PRD document, task list with dependencies, execution levels for DAG visualization, and overall progress metrics.

Overview

Returns the full plan for a Deep Work project including the PRD, task list with dependencies, execution levels, and progress.

Path Parameters

project_id string

The project ID.

Response

project object

The project object with all fields.

tasks array

List of all tasks in the project with status, priority, assignees, and dependencies.

progress object

Progress summary.

total integer
Total task count.
completed integer
Done tasks.
in_progress integer
Currently executing.
blocked integer
Blocked tasks.
percent number
Completion percentage.

prd object

The PRD document (title, content, type) or null if not yet generated.

execution_levels array

Task IDs grouped by dependency level for DAG visualization.

task_level_map object

Mapping of task ID to its dependency level index.

Terminal window
curl http://localhost:8000/api/deep-work/projects/PROJECT_ID/plan \
-H "Authorization: Bearer YOUR_TOKEN"
const res = await fetch(`http://localhost:8000/api/deep-work/projects/${projectId}/plan`, {
headers: { 'Authorization': 'Bearer YOUR_TOKEN' },
});
const data = await res.json();
import httpx
res = httpx.get(
f"http://localhost:8000/api/deep-work/projects/{project_id}/plan",
headers={"Authorization": "Bearer YOUR_TOKEN"},
)
data = res.json()
{
"project": {
"id": "a1b2c3d4...",
"title": "Recipe Management API",
"status": "awaiting_approval"
},
"tasks": [
{
"id": "task-1",
"title": "Set up project structure",
"status": "inbox",
"priority": "high",
"blocked_by": [],
"task_type": "agent",
"estimated_minutes": 30
}
],
"progress": {
"total": 8,
"completed": 0,
"in_progress": 0,
"blocked": 0,
"percent": 0
},
"prd": {
"title": "PRD: Recipe Management API",
"content": "## Problem Statement\n...",
"type": "protocol"
},
"execution_levels": [["task-1", "task-2"], ["task-3"]],
"task_level_map": {"task-1": 0, "task-2": 0, "task-3": 1}
}
Request
curl -X GET "http://localhost:8000/api/deep-work/projects/{project_id}/plan" \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer <token>"
const response = await fetch("http://localhost:8000/api/deep-work/projects/{project_id}/plan", {
  method: "GET",
  headers: {
    "Content-Type": "application/json",
    "Authorization": "Bearer <token>"
},
});

const data = await response.json();
console.log(data);
import requests

response = requests.get(
    "http://localhost:8000/api/deep-work/projects/{project_id}/plan",
    headers={'Content-Type':'application/json','Authorization':'Bearer <token>'},
)

print(response.json())
package main

import (
    "fmt"
    "net/http"
    "io"
)

func main() {
    req, _ := http.NewRequest("GET", "http://localhost:8000/api/deep-work/projects/{project_id}/plan", nil)
    req.Header.Set("Content-Type", "application/json")
    req.Header.Set("Authorization", "Bearer <token>")

    client := &http.Client{}
    resp, _ := client.Do(req)
    defer resp.Body.Close()

    body, _ := io.ReadAll(resp.Body)
    fmt.Println(string(body))
}
Response
Send a request to see the response