Skip to main content

Overview

You use the Projects API to create a project, read project details, update settings, and delete projects. All project routes require Authorization: Bearer <access_token>.

Endpoints

POST /projects

Creates a new project.
  • Body fields:
  • name (required)
  • repoUrl (required)
  • framework (required)
  • port (required, integer 1-65535)
  • isPrivate, autoDeployBranch, autoDeploy, githubRepositoryId, webhookSecret (optional)
curl -X POST http://localhost:3000/projects \
  -H "Authorization: Bearer <access_token>" \
  -H "Content-Type: application/json" \
  -d '{
    "name": "my-app",
    "repoUrl": "https://github.com/acme/my-app",
    "framework": "nextjs",
    "port": 3000,
    "autoDeploy": true,
    "autoDeployBranch": "main"
  }'

GET /projects

Lists projects that belong to the authenticated user.

GET /projects/:id

Returns one project by ID for the authenticated user context.

PATCH /projects/:id/settings

Updates project settings.
  • Required fields in current DTO:
  • region
  • planName
  • envVars (array of { key, value, isSecret })
  • Optional fields:
  • startCommand, buildCommand, isPrivate, autoDeploy, autoDeployBranch, githubRepositoryId, webhookSecret
{
  "region": "eu-west-1",
  "planName": "Free",
  "envVars": [
    {
      "key": "NODE_ENV",
      "value": "production",
      "isSecret": false
    }
  ],
  "buildCommand": "npm run build",
  "startCommand": "npm run start"
}

GET /projects/:id/delete-status

Synchronizes and returns the deletion state of a project.

DELETE /projects/:id

Starts or performs project deletion.

Notes

  • Project operations are user-scoped by the backend service layer.
  • Keep your webhookSecret and any secret env vars out of client-side logs.