Skip to content

Project Reports API

All endpoints require authentication and projects tool permissions. Routes are mounted under /api/projects.

GET /api/projects/:id/reports

Permission: projects:view

Query parameters:

ParamTypeDescription
statusstringFilter by report status
limitnumberItems per page (default: 20)
pagenumberPage number (default: 1)

Response: { reports, total }

GET /api/projects/:id/reports/latest

Permission: projects:view

Response: { report } — null if no reports exist.

POST /api/projects/:id/reports/generate

Permission: projects:update

Generates a weekly report using AI. Pulls task progress, budget data, and other project context to produce report sections.

Body:

FieldTypeRequiredDescription
week_endingstringNoWeek ending date (defaults to current Friday)

Response: { report }

GET /api/projects/:id/reports/:reportId

Permission: projects:view

Response: { report }

PATCH /api/projects/:id/reports/:reportId

Permission: projects:update

Body: Any of the following fields:

FieldTypeDescription
section_summarystringExecutive summary
section_progressstringProgress/completed items
section_in_progressstringCurrently in progress
section_next_weekstringPlanned for next week
section_issuesstringIssues and blockers
section_budgetstringBudget status
subject_linestringEmail subject line
recipient_emailsstring[]Recipient email addresses
internal_notesstringInternal-only notes
overall_statusstringOverall project status indicator
statusstringReport status (e.g. draft, sent)

Response: { report }

POST /api/projects/:id/reports/:reportId/send

Permission: projects:update

Sends the report via email to the configured recipients. Recipients can be set on the report itself or fall back to the project’s report settings.

Response: { report }

GET /api/projects/:id/reports/:reportId/preview

Permission: projects:view

Returns the rendered HTML email as it would appear to recipients.

Response: { html }


GET /api/projects/:id/report-settings

Permission: projects:view

Response: { settings } — null if not configured.

POST /api/projects/:id/report-settings

Permission: projects:update

Uses upsert — creates settings if none exist, or replaces existing settings for the project.

Body:

FieldTypeDescription
recipient_emailsstring[]Default recipient email addresses
include_budgetbooleanInclude budget section (default: true)
intro_textstringCustom intro text for report emails
outro_textstringCustom outro text for report emails
custom_section_labelsobjectOverride default section labels
auto_generatebooleanEnable automatic report generation

Response: { settings }

PATCH /api/projects/:id/report-settings

Permission: projects:update

Partial update of report settings.

Body: Any of: recipient_emails, include_budget, intro_text, outro_text, custom_section_labels, auto_generate.

Response: { settings }


GET /api/projects/reports/due

Permission: projects:view

Returns active projects with auto_generate enabled that do not have a sent report for the current week. Results are scoped by access level:

  • Employee/Lead: only projects the user is a member of.
  • Manager: projects where the user is DM, owner, or a member.
  • Head/Executive: all projects.

Response:

{
"projects": [
{
"id": "string",
"name": "string",
"company_name": "string",
"dm_name": "string",
"report_id": "string or null",
"report_status": "string or null",
"generated_at": "string or null"
}
]
}