REST API
Projects, tasks and notes from your scripts and services, with personal tokens and per-resource scopes.
The public API is versioned under /api/v1. On the managed service the base URL is https://api.fxcode.dev/api/v1; on your own installation, it’s your API’s address followed by /api/v1.
Authentication
Create a personal token in Settings → API tokens. Pick only the scopes you need; the token is shown only once and starts with fxc_. Send it with every request:
curl -H "Authorization: Bearer fxc_TU_TOKEN" https://api.fxcode.dev/api/v1/projects
| Scope | Allows |
|---|---|
projects:read |
List and view projects |
tasks:read / tasks:write |
Read / create, edit and delete tasks |
notes:read / notes:write |
Read / create, edit and delete notes |
A token with no scopes selected has full access. You can revoke it at any time from the same screen.
You only see projects where you’re a team member. Someone else’s project returns 404, just like one that doesn’t exist.
Endpoints
| Method and path | Scope | What it does |
|---|---|---|
GET /projects |
projects:read |
Your projects (pinned first) |
GET /projects/:id |
projects:read |
A single project |
GET /projects/:id/tasks |
tasks:read |
A project’s tasks |
GET /tasks?projectId= |
tasks:read |
Tasks across your projects, optionally filtered to one |
GET /tasks/:id |
tasks:read |
A single task |
POST /tasks |
tasks:write |
Creates a task |
PUT /tasks/:id |
tasks:write |
Updates a task (only the fields you send) |
DELETE /tasks/:id |
tasks:write |
Deletes a task |
GET /projects/:id/notes |
notes:read |
A project’s notes |
POST /projects/:id/notes |
notes:write |
Creates a note |
PUT /projects/:id/notes/:noteId |
notes:write |
Updates a note |
DELETE /projects/:id/notes/:noteId |
notes:write |
Deletes a note |
Tasks
curl -X POST https://api.fxcode.dev/api/v1/tasks \
-H "Authorization: Bearer fxc_TU_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"projectId": "ID_DEL_PROYECTO",
"title": "Revisar webhooks de Stripe",
"description": "Los reintentos fallan con 409",
"tags": ["pagos"]
}'
| Field | Type | |
|---|---|---|
title |
string | Required on create |
projectId |
string | Required on create |
description |
string | Optional |
taskStatusId |
string | Optional. A status id; you’ll find it in taskStatus.id on any task |
tags |
array of strings | Optional; on update it replaces the existing tags |
A task looks like this:
{
"id": "cmvc…",
"title": "Revisar webhooks de Stripe",
"description": "Los reintentos fallan con 409",
"tags": ["pagos"],
"projectId": "ID_DEL_PROYECTO",
"taskStatus": { "id": "cmt…", "name": "Working", "color": "#14b8a6" },
"createdAt": "2026-10-17T14:00:00.000Z",
"updatedAt": "2026-10-17T14:00:00.000Z"
}
Changes you make through the API show up live in the app, just like changes made on the web.
Notes
curl -X POST https://api.fxcode.dev/api/v1/projects/<id>/notes \
-H "Authorization: Bearer fxc_TU_TOKEN" \
-H "Content-Type: application/json" \
-d '{ "title": "Decisiones de la reunión", "content": "## Acuerdos\n- …" }'
content is required on create; title is optional.
Errors
Errors return an HTTP status code and a JSON body { "error": "message" }:
| Code | When |
|---|---|
400 |
Invalid data (a required field is missing, a taskStatusId that doesn’t exist) |
401 |
The token is missing, invalid, revoked or expired |
403 |
The token lacks the scope the route requires |
404 |
The resource doesn’t exist or doesn’t belong to one of your projects |
The full OpenAPI spec lives at /docs on your API (on the managed service, api.fxcode.dev/docs).
Application API
The following routes belong to the authenticated API used by the web app, CLI and MCP, relative to the API root (without /api/v1). They use an API session; they are not additional routes for the personal fxc_ tokens described in this guide. To use them from an assistant, connect MCP.
| Method and path | Behavior |
|---|---|
GET /projects?archived=true |
Archived only; archived=all includes both, no parameter excludes archived |
PATCH /projects/:id/archive |
{ "archived": true } archives; false restores. Owner or admin |
GET /projects/:id/deletion-preview |
Counts, requiresTitle and canDelete |
POST /projects/:id/permanent-delete |
{ "confirm": true, "confirmTitle": "Exact title" }. Owner only; title required with client, payments or proposals (409 on mismatch) |
GET /projects/:id/client-board |
Read-only board for members, including clients; titles, statuses, progress and own requests without a task |
GET /agent-runners/available?projectId=<id> |
Active and inactive machines and connected sessions for the project |
GET /tasks/:id/agent-machine |
Task destination: machine and/or session |
PATCH /agent-sessions/:session |
Changes acceptsTasks and/or projectIds for an owned session |
The older DELETE /projects/:id, used by fxc projects delete, still accepts owner or admin without a preview or title confirmation. The preview flow is deletion-preview → permanent-delete. Both log who deleted the project and when.