Projects API
Projects are the top-level organizational unit in Octokraft. Each project contains repositories, health assessments, PR analyses, and team members.List Projects
Returns all projects the authenticated user belongs to.Get Project
Returns a single project by ID.Create Project
Creates a new project and adds the authenticated user as owner.Request Body
| Field | Type | Required | Description |
|---|---|---|---|
name | string | yes | Project display name |
key | string | yes | URL-safe project key (unique) |
description | string | no | Project description |
Update Project
Updates a project’s name, description, or settings. Only provided fields are updated.Request Body
| Field | Type | Required | Description |
|---|---|---|---|
name | string | no | New project name |
description | string | no | New project description |
settings | object | no | Project settings (JSON object) |
Delete Project
Deletes a project. The authenticated user must be a project owner.204 No Content on success.
List Members
Returns all members of a project.Invite Member
Sends an invitation to join a project. The invited user receives access once they accept.Request Body
| Field | Type | Required | Description |
|---|---|---|---|
email | string | yes | Email address to invite |
role | string | no | Role to assign: owner or member (defaults to member) |
Update Member Role
Changes a member’s role in a project. The authenticated user must be a project owner.Request Body
| Field | Type | Required | Description |
|---|---|---|---|
role | string | yes | New role: owner or member |
Remove Member
Removes a user from a project. Returns409 Conflict if attempting to remove the last owner.
204 No Content on success.