API Reference
Projects
Manage Forge projects via REST API
GET
Overview
Projects are the top-level organizational unit in Forge. Each project contains tasks, attempts, and configuration. Base URL:http://localhost:8887/api/projects
List Projects
Get Project
Retrieve a specific project by ID.Example Request
Example Response
Create Project
Create a new Forge project.Project name
Project description
Repository configuration
url(string, required): GitHub repository URLbranch(string): Branch name (default: “main”)
Default AI agent (claude, gemini, gpt-4, etc.)
Response
201 Created
400 Bad Request
409 Conflict
Update Project
Update project properties.Request Body
Example Request
Example Response
Delete Project
Delete a project and all associated data.Example Request
Example Response
Get Project Tasks
Get all tasks for a specific project.Query Parameters
Same as Tasks API list parameters.Example Request
Get Project Stats
Get detailed statistics for a project.Example Response
SDK Examples
JavaScript/TypeScript
Python
Get Project Branches
List all git branches for a project.Example Response
Response Fields
| Field | Type | Description |
|---|---|---|
currentBranch | string | Currently checked out branch |
branches | array | All branches in repository |
branches[].name | string | Branch name |
branches[].commit | string | Latest commit hash |
branches[].isCurrent | boolean | Currently checked out |
branches[].isDefault | boolean | Default branch (main/master) |
branches[].isForgeWorktree | boolean | Created by Forge for task attempt |
branches[].taskId | string | Associated task ID (Forge branches only) |
branches[].attemptId | string | Associated attempt ID (Forge branches only) |
forgeBranches | array | Filtered list of Forge-created branches |
Use Cases
- List available target branches for merging
- Identify Forge worktree branches
- Check current repository state
- Find branches associated with specific tasks
Error Responses
Project Not Found
Validation Error
Conflict Error
Next Steps
Tasks API
Manage tasks within projects
Attempts API
Execute tasks with AI agents
REST Overview
API fundamentals and authentication
Authorizations
GitHub OAuth token obtained via device flow
Response
200 - application/json
List of projects
The response is of type any.

