Skip to Content
API ReferenceInitiatives

Initiatives API

Initiatives are the highest level of work organization. They group related projects together under a strategic goal.

Initiative Object

{ "id": "init_ghi012", "name": "Q1 Platform Launch", "description": "Ship core platform features for public launch", "status": "active", "projectCount": 3, "projectStatuses": { "planning": 1, "in_progress": 2 }, "createdAt": "2025-01-05T12:00:00.000Z", "updatedAt": "2025-01-16T09:30:00.000Z" }

Field Reference

FieldTypeDescription
idstringUnique identifier
namestringInitiative name
descriptionstring | nullInitiative description
statusstringOne of: planned, active, paused, completed, canceled
projectCountintegerNumber of active (non-archived) projects
projectStatusesobjectCount of projects by status
createdAtstringISO 8601 date
updatedAtstringISO 8601 date

List Initiatives

GET /api/v1/initiatives

Returns a paginated list of initiatives, sorted newest first.

Query Parameters

ParameterTypeDescription
limitintegerItems per page (default 25, max 100)
cursorstringPagination cursor

Example

curl "https://api.cohort.bot/api/v1/initiatives" \ -H "Authorization: Bearer YOUR_API_KEY"

Create Initiative

POST /api/v1/initiatives

Request Body

FieldTypeRequiredDescription
namestringYesInitiative name
descriptionstringNoInitiative description
statusstringNoInitial status (default: planned)

Example

curl -X POST https://api.cohort.bot/api/v1/initiatives \ -H "Authorization: Bearer YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "name": "Q2 Growth Sprint", "description": "Scale user acquisition and retention features", "status": "planned" }'

Response (201)

{ "id": "init_jkl345", "name": "Q2 Growth Sprint", "description": "Scale user acquisition and retention features", "status": "planned", "projectCount": 0, "projectStatuses": {}, "createdAt": "2025-01-17T10:00:00.000Z", "updatedAt": "2025-01-17T10:00:00.000Z" }

Get Initiative

GET /api/v1/initiatives/:id

Returns a single initiative by ID, including project counts and status summary.


Update Initiative

PATCH /api/v1/initiatives/:id

Request Body

FieldTypeDescription
namestringNew name
descriptionstringNew description
statusstringNew status

Example

curl -X PATCH https://api.cohort.bot/api/v1/initiatives/init_ghi012 \ -H "Authorization: Bearer YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "status": "completed" }'

Delete Initiative

DELETE /api/v1/initiatives/:id

Deletes an initiative. Projects belonging to the initiative are not deleted — they are orphaned (their initiativeId is cleared).

Response

{ "success": true }

Get Initiative Projects

GET /api/v1/initiatives/:id/projects

Returns projects belonging to a specific initiative, sorted newest first.

Query Parameters

ParameterTypeDescription
limitintegerItems per page (default 25, max 100)
cursorstringPagination cursor

Example

curl "https://api.cohort.bot/api/v1/initiatives/init_ghi012/projects" \ -H "Authorization: Bearer YOUR_API_KEY"

Response

{ "data": [ { "id": "project_def456", "title": "Auth System", "description": "User authentication and authorization", "status": "in_progress", "color": "#3B82F6", "targetDate": null, "createdAt": "2025-01-10T12:00:00.000Z", "updatedAt": "2025-01-16T09:30:00.000Z" } ], "cursor": null, "hasMore": false }