Work
Project management: projects, epics, deliveries, tasks, business units, and member placement against the work schema.
- Connector
https://mcp.devfellowship.com/mcp
- Tools
- 48 in 11 groups
- Package
packages/dfl-mcp-work- Auth
- Sign in once on the DFL connector. Every call runs as you, under RLS and your IAM role. See Auth & security.
Connect
Add the one DFL connector, https://mcp.devfellowship.com/mcp, to your client. Sign in once. On the consent page
choose the work domain: read gives the scope work.read, and write gives
work.write. The steps for each client are on
Connect the DFL MCP.
Then find a tool of this domain with the router tools of the connector:
-
search_toolswith a keyword or an exact tool name. Each result giveswork.<tool>and its mode (read or write).{ "query": "list_projects" } -
describe_toolwith that id for the description and the input schema.{ "tool": "work.list_projects" } -
call_read_toolfor a read tool, orcall_write_toolfor a write tool, with the id and the arguments.
Scripts and agents that sign in with a token: see Getting started, For scripts.
| Backing data | work schema (projects, epics, deliveries, tasks, business units, placements). |
Projects
Section titled “Projects”Find, create and edit projects.
list_projects
List all projects with optional filters.read
list_projectsList Projects
List all projects with optional filters.
| Parameter | Type | Required | Description |
|---|---|---|---|
limit | number | no | Maximum number of projects to return (default: 50, max: 100) |
offset | number | no | Number of projects to skip (for pagination) |
business_unit_id | string | no | Filter by business unit ID. |
search | string | no | Search by project name. |
get_project
Get a specific project by ID with its epics.read
get_projectGet Project
Get a specific project by ID with its epics.
| Parameter | Type | Required | Description |
|---|---|---|---|
id | string | yes | The UUID of the project. |
create_project
Create a new project. The database also creates its long-lived default epic in the same transaction.write
create_projectCreate Project
Create a new project. The database also creates its long-lived default epic in the same transaction. The write runs on the DFL OS command service (create_project) as the caller.
| Parameter | Type | Required | Description |
|---|---|---|---|
name | string | yes | Project name. |
business_unit_id | string | no | Business unit ID. |
update_project
Update an existing project.write
update_projectUpdate Project
Update an existing project. The write runs on the DFL OS command service (update_project) as the caller.
| Parameter | Type | Required | Description |
|---|---|---|---|
id | string | yes | The UUID of the project to update. |
name | string | no | Project name. |
business_unit_id | string | no | Business unit ID. |
delete_project
Delete a project. Its epics keep no project (project_id set to null).write
delete_projectDelete Project
Delete a project. Its epics keep no project (project_id set to null). The write runs on the DFL OS command service (delete_project) as the caller.
| Parameter | Type | Required | Description |
|---|---|---|---|
id | string | yes | The UUID of the project to delete. |
The epics of a project, with their deliveries and tasks.
list_epics
List all epics with optional filters.read
list_epicsList Epics
List all epics with optional filters.
| Parameter | Type | Required | Description |
|---|---|---|---|
limit | number | no | Maximum number of epics to return (default: 50, max: 100) |
offset | number | no | Number of epics to skip (for pagination) |
project_id | string | no | Filter by project ID. |
status | enum | no | Filter by status. One of: pending, in_progress, done, no_longer_needed. |
search | string | no | Search by epic name. |
get_epic
Get a specific epic by ID with its deliveries and tasks.read
get_epicGet Epic
Get a specific epic by ID with its deliveries and tasks.
| Parameter | Type | Required | Description |
|---|---|---|---|
id | string | yes | The UUID of the epic. |
create_epic
Create a new epic. 🔴 AN EPIC CANNOT BE SHOWN ON A PLAN — do not tell anyone you linked one.write
create_epicCreate Epic
Create a new epic. 🔴 AN EPIC CANNOT BE SHOWN ON A PLAN — do not tell anyone you linked one. The plans-app renders bound TASKS only (it reads work.entity_connections filtered to target_type='task'), so an epic connection would be a row nothing displays. What to do instead: create the epic here, create its tasks with create_task, then bind THOSE tasks to the plan with set_plan_tasks on the PLANS MCP (the plans domain) — that is what makes the work visible on the plan. Name the epic in the plan body if a reader needs to know which epic holds the tasks. The write runs on the DFL OS command service (create_epic) as the caller.
| Parameter | Type | Required | Description |
|---|---|---|---|
name | string | yes | Epic name. |
project_id | string | no | Project ID. |
notes | string | no | Epic notes/description. |
status | enum | no | Epic status. One of: pending, in_progress, in_review, done, no_longer_needed. |
is_long_lived | boolean | no | Whether this is a long-lived epic. |
responsible_id | string | no | Responsible member ID. |
reviewer_id | string | no | Reviewer member ID. |
estimated_points | number | no | Estimated points of the epic. |
update_epic
Update an existing epic. The write runs on the DFL OS command service (update_epic) as the caller.write
update_epicUpdate Epic
Update an existing epic. The write runs on the DFL OS command service (update_epic) as the caller.
| Parameter | Type | Required | Description |
|---|---|---|---|
id | string | yes | The UUID of the epic to update. |
name | string | no | Epic name. |
project_id | string | no | Project ID. |
notes | string | no | Epic notes/description. |
status | enum | no | Epic status. One of: pending, in_progress, in_review, done, no_longer_needed. |
is_long_lived | boolean | no | Whether this is a long-lived epic. |
responsible_id | string | no | Responsible member ID. |
reviewer_id | string | no | Reviewer member ID. |
estimated_points | number | no | Estimated points of the epic. |
delete_epic
Delete an epic. Its deliveries are deleted with it (ON DELETE CASCADE) and its tasks keep no epic (epic_id set to null).write
delete_epicDelete Epic
Delete an epic. Its deliveries are deleted with it (ON DELETE CASCADE) and its tasks keep no epic (epic_id set to null). A design task route that targets the epic refuses the delete (409). The write runs on the DFL OS command service (delete_epic) as the caller.
| Parameter | Type | Required | Description |
|---|---|---|---|
id | string | yes | The UUID of the epic to delete. |
Deliveries
Section titled “Deliveries”The deliveries of an epic, with their tasks.
list_deliveries
List all deliveries with optional filters.read
list_deliveriesList Deliveries
List all deliveries with optional filters.
| Parameter | Type | Required | Description |
|---|---|---|---|
limit | number | no | Maximum number of results (default 50) |
offset | number | no | Number of results to skip. |
epic_id | string | no | Filter by epic ID. |
owner_id | string | no | Filter by owner (member) ID. |
status | enum | no | Filter by status. One of: pending, in_progress, completed, canceled, no_longer_needed. |
search | string | no | Search in name and notes. |
get_delivery
Get a specific delivery by ID with its epic and tasks.read
get_deliveryGet Delivery
Get a specific delivery by ID with its epic and tasks.
| Parameter | Type | Required | Description |
|---|---|---|---|
id | string | yes | The UUID of the delivery. |
create_delivery
Create a new delivery. The write runs on the DFL OS command service (create_delivery) as the caller.write
create_deliveryCreate Delivery
Create a new delivery. The write runs on the DFL OS command service (create_delivery) as the caller.
| Parameter | Type | Required | Description |
|---|---|---|---|
name | string | yes | Delivery name. |
notes | string | no | Delivery notes. |
epic_id | string | yes | Epic ID (required) |
owner_id | string | no | Owner (member) ID. |
status | enum | no | Delivery status. One of: pending, in_progress, completed, canceled, no_longer_needed. |
price_per_point | number | no | Price per story point. |
transaction_id | string | no | Transaction ID. |
update_delivery
Update an existing delivery.write
update_deliveryUpdate Delivery
Update an existing delivery. The write runs on the DFL OS command service (update_delivery) as the caller.
| Parameter | Type | Required | Description |
|---|---|---|---|
id | string | yes | The UUID of the delivery to update. |
name | string | no | Delivery name. |
notes | string | no | Delivery notes. |
epic_id | string | no | Epic ID. |
owner_id | string | no | Owner (member) ID. |
status | enum | no | Delivery status. One of: pending, in_progress, completed, canceled, no_longer_needed. |
price_per_point | number | no | Price per story point. |
transaction_id | string | no | Transaction ID. |
delete_delivery
Delete a delivery. Its tasks keep no delivery (delivery_id set to null).write
delete_deliveryDelete Delivery
Delete a delivery. Its tasks keep no delivery (delivery_id set to null). The write runs on the DFL OS command service (delete_delivery) as the caller.
| Parameter | Type | Required | Description |
|---|---|---|---|
id | string | yes | The UUID of the delivery to delete. |
Find tasks by owner, status, epic or delivery; each task carries its estimated date, so you can see who is late and what is overdue. Get the Git branch name of a task.
list_tasks
List all tasks with optional filters.read
list_tasksList Tasks
List all tasks with optional filters. Each task row carries its owner_id, status and estimated_date (the planned completion date). To answer "who is late" or "which tasks are overdue", list the open tasks (status not done / no_longer_needed) and keep the rows whose estimated_date is before today. There is no overdue filter: compare the dates yourself. done_since returns the tasks that reached done at or after an ISO date-time (read from status_timestamps.done_at), newest first, so "what was closed yesterday" is one call. For a Sao Paulo day use 03:00Z. Page with offset; total is the full count.
| Parameter | Type | Required | Description |
|---|---|---|---|
limit | number | no | Maximum number of tasks to return (default: 50, max: 100) |
offset | number | no | Number of tasks to skip (for pagination) |
epic_id | string | no | Filter by epic ID. |
delivery_id | string | no | Filter by delivery ID. |
owner_id | string | no | Filter by owner (member) ID. |
status | enum | no | Filter by status. One of: to_do, in_progress, dev_completed, done, no_longer_needed, blocked. |
search | string | no | Search by task name. |
done_since | string | no | Only tasks with status done whose done_at is at/after this ISO date-time. Newest done first. |
get_task
Get a specific task by ID with its epic and delivery.read
get_taskGet Task
Get a specific task by ID with its epic and delivery.
| Parameter | Type | Required | Description |
|---|---|---|---|
id | string | yes | The UUID of the task. |
create_task
Create a new task. Requires a context package (why/what) so the task is readable by whoever was not in the conversation it came from.write
create_taskCreate Task
Create a new task. Requires a context package (why/what) so the task is readable by whoever was not in the conversation it came from. 🔴 IF THIS TASK BELONGS TO A PLAN, CREATING IT IS ONLY HALF THE JOB. This tool writes work.tasks and NOTHING ELSE — it does not attach the task to a plan, and no tool on this server does. A plan renders its execution checklist from work.entity_connections, so the task stays invisible to the plan until you call set_plan_tasks on the PLANS MCP (the plans domain) with the plan slug and EVERY task id the plan should show: set_plan_tasks({ slug, tasks: [{ task_id }, ...] }). It REPLACES the plan's task set, so pass the full desired list, not just the new ids. The failure mode is silent and has already happened: 18 tasks created under an epic for a plan, reported as linked, and the plan page showed nothing (2026-08-12). A created task is a complete, valid row on its own, so there is no error to notice — the only signal is an empty rail on the plan, which reads as "no work started". Verify by reading the plan back and seeing your tasks in its links. OWNER: omit owner_id and the owner is the caller. An agent login has no public.members row, so for an agent the owner falls back to the owner of the plan named by plan_slug, then the owner of delivery_id, then the responsible of epic_id; with none of them the call is refused. AUTHOR (actor_links): actor_slug when given; else, in an OAuth (connector) session, the agent actor of the grant; else the agent of an agent login; else none (a human task). PLANNED MODEL: context.planned_model is REQUIRED (the model id the task is planned to run on: opus, sonnet, gemma4:26b). A create without it is refused and nothing is written (Tainan Q 6399046c = B, 2026-11-18). CONTEXT KEYS: only why, what, pr_url, storybook_url, playground_url, files, repo, plan_ref, input, executor, planned_model. Any other key (source too: the server writes it) REJECTS the call, and nothing is written. TEXT LINT (warn only, never refuses): a successful answer carries warnings[] ({code: "task_text", rule, field, message}; D06 actor warnings share the array) when context.why has fewer than 40 chars or is a bare id, context.what has fewer than 60 chars, is a placeholder or points to another task, acceptance_criteria is empty or an item names no command, endpoint, tool or observation, the name is longer than 120 chars, or (with plan_slug) the name has no plan key prefix. Fix the task with update_task when a warning is real.
| Parameter | Type | Required | Description |
|---|---|---|---|
name | string | yes | Task name. |
description | string | no | Task description. |
epic_id | string | no | Epic ID. |
delivery_id | string | no | Delivery ID. |
owner_id | string | no | Owner (public.members.id). Omitir atribui a task a quem chamou a tool. Uma task sem dono some do board, entao nao existe caminho que grave null aqui. An agent login has no public.members row: when it omits owner_id, the owner is the owner of plan_slug, else the owner of delivery_id, else the responsible of epic_id; with none of them the call is refused. |
plan_slug | string | no | The plan this task belongs to. USED ONLY to pick the default owner (the plan owner) when owner_id is absent and the caller has no public.members row, which is the case for every agent login. It does NOT bind the task to the plan: call set_plan_tasks on the plans MCP for that. A plan you cannot read refuses the call. |
status | enum | no | Task status. One of: to_do, in_progress, dev_completed, done, no_longer_needed, blocked. |
points | number | no | Story points. |
priority | number | no | Priority (lower = higher priority) |
estimated_date | string | no | Estimated completion date (ISO format) |
attachments | string[] | no | Array of attachment URLs. |
acceptance_criteria | string[] | no | What has to be true for this task to be done, ONE criterion per array entry. The column is text[], not text — do not pass a single blob with numbered lines, because nothing can then render or check a criterion on its own. Write each entry so it can be verified without asking the author: name the command, the endpoint, or the observation that settles it. |
stage_id | enum | yes | What kind of work this is. Required: a task without a stage is invisible on the kanban board, and 1160 of them accumulated that way while this was optional. This is a DIFFERENT AXIS from status — pick where the work starts, not how far along it is. design (board: Ideation) for exploring references and alternatives, decision (board: Design Review) for a proposal waiting on someone to call it, qa (board: QA / Test) for finish work like copy and edge states, spec for shaping the requirement, execution for work ready to be built, review (board: QA / Test) for final validation of work already built. qa and review share the QA / Test column and are told apart by a badge on the card: qa shows Design, review shows Engineering. One of: spec, design, execution, review, decision, qa. |
context | object | yes | Context package: why the task exists, what was done, and the links. Required keys: why, what, planned_model. Allowed keys: why, what, pr_url, storybook_url, playground_url, files, repo, plan_ref, input, executor, planned_model. Any other key is REJECTED and nothing is written (source is written by the server). |
actor_slug | string | no | The agent/service slug that DID this work (e.g. 'claude-main'). ABSENT = the author is the first of these that applies: the OAuth grant actor (a dfl connector session whose grant is not 'myself'), the agent of an agent login (linked via public.actor_links), or no author link (a human task). PRESENT = the slug MUST resolve to an existing actor AND be the caller's own actor or an agent the caller delegates to (an active public.actor_delegations row from the caller's human actor); otherwise the call is REJECTED and nothing is written. An agent token can never name another actor. |
request_id | string | no | Optional caller request UUID. Disabled by default. When enabled, retain this UUID and the same input for a safe retry. A missing task returns uncertainty, not recreation. |
update_task
Update an existing task. Every write moves the task's updated_at, which the plans calendar counts as WORK activity of the plans the task is bound to.write
update_taskUpdate Task
Update an existing task. Every write moves the task's updated_at, which the plans calendar counts as WORK activity of the plans the task is bound to. For a bulk repair or a re-set that only restores a damaged row, pass activity_class: "housekeeping" with activity_reason: the calendar then keeps the task's previous real work time, and shows this write only when housekeeping is included. CONTEXT: pass context to add or change context keys after the create (for example a pr_url). It MERGES: a key you send replaces that key, every other stored key stays. Same keys and rules as create_task; an unknown key REJECTS the call and nothing is written. STATUS: the status write runs in the DFL OS command service (set_task_status), the same one the Plans App uses. With other fields in the same call, the status is written first; a refusal of the status writes nothing.
| Parameter | Type | Required | Description |
|---|---|---|---|
id | string | yes | The UUID of the task to update. |
name | string | no | Task name. |
description | string | no | Task description. |
epic_id | string | no | Epic ID. |
delivery_id | string | no | Delivery ID. |
owner_id | string | no | Owner (member) ID. |
status | enum | no | Task status. One of: to_do, in_progress, dev_completed, done, no_longer_needed, blocked. |
points | number | no | Story points. |
priority | number | no | Priority (lower = higher priority) |
estimated_date | string | no | Estimated completion date (ISO format) |
attachments | string[] | no | Array of attachment URLs. |
acceptance_criteria | string[] | no | What has to be true for this task to be done, ONE criterion per array entry. REPLACES the whole list — send every criterion you want to keep, not only the new one. The column is text[], not text. |
stage_id | enum | no | Stage ID (a task without one is invisible on the kanban board) One of: spec, design, execution, review, decision, qa. |
expected_updated_at | string | no | Stale-write guard: the updated_at you read for this task (ISO timestamp). When the task changed since, the call is refused with a conflict and NOTHING is written; read the task again and retry. Omit it for no guard. With status AND other fields, the guard checks the status write (the first write of the call). |
context | object | no | Context keys to add or change. MERGES into the stored context (a sent key replaces that key; every other stored key, source too, stays). Allowed keys: why, what, pr_url, storybook_url, playground_url, files, repo, plan_ref, input, executor, planned_model. Any other key is REJECTED and nothing is written. |
actor_slug | string | no | Executor: a fleet agent slug. |
run_id | string | no | A work.task_runs run_id of this task. |
model | string | no | The model of the run that closes the task (for example claude-sonnet-5-5). Used with status "done": it is written on the run row of the call, and fills a NULL model on the existing run row. A stored value is never replaced. |
subagent_type | string | no | The subagent type of that run. Same rule as model. Used with status "done". |
host | string | no | The host that ran it (best effort). Same rule as model. Used with status "done". |
activity_class | enum | no | Class of THIS write on the plans calendar. Default "work". Use "housekeeping" for a repair, a bulk re-set or a cleanup that is not real progress; then activity_reason is required. One of: work, housekeeping. |
activity_reason | string | no | Why this write is housekeeping (1-500 chars). Required with activity_class "housekeeping". |
delete_task
Delete a task. Also deletes the public.actor_links rows that attribute the task to an actor, the PR links of the task (review_request.review_request_task_links; pr_links_deleted), and the plan bindings of the task…write
delete_taskDelete Task
Delete a task. Also deletes the public.actor_links rows that attribute the task to an actor, the PR links of the task (review_request.review_request_task_links; pr_links_deleted), and the plan bindings of the task (work.entity_connections), so no link is left pointing at a deleted task. The task, its actor_links and its PR links go in ONE transaction of the DFL OS command service (delete_task), as the caller. Plan bindings: the rows that the caller created, and every binding of a plan that the caller may edit (owner, delegate or admin), are deleted as the caller. The result carries plan_links_deleted and plan_links_left (0 = clean; above 0 = bindings of plans the caller may not edit, named in plan_links_notes).
| Parameter | Type | Required | Description |
|---|---|---|---|
id | string | yes | The UUID of the task to delete. |
get_task_branch_name
Returns the suggested Git branch name for a task based on its identifier and name.read
get_task_branch_nameGet Task Branch Name
Returns the suggested Git branch name for a task based on its identifier and name. Format: feat/DFL-XXXX-slug-of-name.
| Parameter | Type | Required | Description |
|---|---|---|---|
id | string | yes | The UUID of the task. |
set_task_classification
Write the use-case class of a task for one taxonomy version (work.task_classifications).write
set_task_classificationSet Task Classification
Write the use-case class of a task for one taxonomy version (work.task_classifications). One row per (task_id, taxonomy_version); a second call for the same pair REPLACES the row, so a label you do not send becomes empty. Needs cluster_id or work_type (a classifier whose quality gate failed writes only cluster_id). Only an AGENT actor writes: the row is stamped with your actor (work.current_actor()). A call with no actor, or as a human actor, is refused before the write. A row recorded by another actor is refused with a clear error. Rows cannot be deleted. Read it back with get_task_classification.
| Parameter | Type | Required | Description |
|---|---|---|---|
task_id | string | yes | The UUID of the task to classify. |
taxonomy_version | string | yes | Taxonomy version of the labels, for example "v2" or "v3". One row per (task, taxonomy_version). |
cluster_id | string | no | Cluster id from the cluster run (for example "K007"). Alone it is valid: the classifier writes only this when the 80 percent gate fails. |
work_type | string | no | Work type. Lowercase a-z, 0-9, "_" or "-", 1-64 chars. The closed list lives in dfl-harness. |
work_subtype | string | no | Work subtype. Needs work_type. Lowercase a-z, 0-9, "_" or "-", 1-64 chars. The closed list lives in dfl-harness. |
domain | string | no | Domain. Lowercase a-z, 0-9, "_" or "-", 1-64 chars. The closed list lives in dfl-harness. |
capability | string | no | Capability the task needs. Lowercase a-z, 0-9, "_" or "-", 1-64 chars. The closed list lives in dfl-harness. |
difficulty | number | no | Difficulty 1 (easy) to 5 (hard). |
cheaper_model_could_do | enum | no | Could a cheaper model do this task. One of: yes, partly, no. |
classified_by | string | yes | The classifier engine, for example "alien01/gemma4:26b", or "human". |
reviewed | boolean | no | True when a person checked the class. Default false. |
set_task_classifications
Write the use-case class of up to 100 tasks in one call: the batch form of set_task_classification, for a classifier run.write
set_task_classificationsSet Task Classifications (batch)
Write the use-case class of up to 100 tasks in one call: the batch form of set_task_classification, for a classifier run. Each item has the input of set_task_classification (task_id, taxonomy_version, cluster_id or work_type, the other labels, classified_by) and the same rules: one row per (task_id, taxonomy_version), a second write REPLACES the row, only an AGENT actor writes, a row recorded by another actor is refused. Each item gets one outcome: written (created true|false) | refused (code: the set_task_classification error code) | error (a server or transport failure; nothing is known to be written, send that item again). One bad item never stops the others. Caller user JWT, RLS applies.
| Parameter | Type | Required | Description |
|---|---|---|---|
items | object[] | yes | 1 to 100 classifications. |
get_task_classification
Read task classes (work.task_classifications).read
get_task_classificationGet Task Classification
Read task classes (work.task_classifications). With task_id: the rows of that task, one per taxonomy version (add taxonomy_version for one). Without task_id, pass taxonomy_version to list that version, optionally filtered by cluster_id or work_type, paged with limit and offset. An empty list means no class is stored, not an error.
| Parameter | Type | Required | Description |
|---|---|---|---|
task_id | string | no | The UUID of a task. Returns its class rows, one per taxonomy version. |
taxonomy_version | string | no | Only this taxonomy version. Without task_id it is required (list mode). |
cluster_id | string | no | List mode: only rows of this cluster. |
work_type | string | no | List mode: only rows of this work type. |
limit | number | no | List mode: page size (default 100, max 500). |
offset | number | no | List mode: rows to skip (default 0). |
list_task_prs
List the pull requests linked to a task, newest link first.read
list_task_prsList Task PRs
List the pull requests linked to a task, newest link first. Each entry carries the PR URL, title, pr_state (open | closed | merged; null until the GitHub intake has filled it), is_draft, base_sha, head_sha, merge_commit_sha, ci_state (pending | success | failure | none), ci_head_sha, ci_current (true only when ci_state describes the current head_sha), the link role (delivers | relates), link_source (trailer | branch | keyword | rule | judged | manual | webhook_v1), confidence (declared | rule | judged | manual) and linked_by_actor_id. A link whose PR row is gone carries pr_missing true. Read the PR state here instead of polling the GitHub API. Caller user JWT, RLS applies (members read).
| Parameter | Type | Required | Description |
|---|---|---|---|
task_id | string | yes | The UUID of the task. |
add_task_pr
Add a link between a task and a GitHub pull request, by hand.write
add_task_prAdd Task PR
Add a link between a task and a GitHub pull request, by hand. Writes ONE row of review_request.review_request_task_links with link_source "manual", confidence "manual", created_by = the caller, and linked_by_actor_id = the agent actor of the session (the OAuth grant actor, else the agent of an agent login, else null for a human). pr_url must be https://github.com/<owner>/<repo>/pull/<number>. The PR must already be in the PR mirror (the GitHub intake writes it): a PR that is not there is REFUSED, and this tool never creates a PR row. role: "delivers" (default) = the PR delivers the task; "relates" = context only. APPROVAL RULE (ADR-2): only a "delivers" link may move a task when a review is approved or rejected; a "relates" link is context only. The database functions approve_review_request and reject_review_request do not yet exclude "relates" links, so link with "relates" a task that is not dev_completed, or the answer carries a relates_on_dev_completed warning. IDEMPOTENT: a link that exists is never changed (the table has no UPDATE); the answer returns the stored row with already_linked true, and role_differs true when its role is not the one asked for. Read the link back with list_task_prs. Caller user JWT, RLS applies (members write).
| Parameter | Type | Required | Description |
|---|---|---|---|
task_id | string | yes | The UUID of the task. |
pr_url | string | yes | The PR URL: https://github.com/<owner>/<repo>/pull/<number>. |
role | enum | no | delivers (default) or relates. One of: delivers, relates. |
add_task_prs
Add up to 100 links between tasks and GitHub pull requests in one call, each with an honest link_source and confidence.write
add_task_prsAdd Task PRs (batch)
Add up to 100 links between tasks and GitHub pull requests in one call, each with an honest link_source and confidence. For a backfill or a reconcile of old PRs; for one link by hand use add_task_pr. Each item: task_id, pr_url (https://github.com/<owner>/<repo>/pull/<number>), role (delivers default | relates), link_source (trailer | branch | keyword | rule | judged | manual) and confidence (declared | rule | judged | manual). Pairs: judged only with judged, manual only with manual, declared only with trailer, branch or keyword (the PR declares the task). The PR must already be in the PR mirror (write it first with upsert_pull_requests); this tool never creates a PR row. A link that exists is never changed. Each item gets one outcome: linked | already_linked | pr_missing | task_missing | invalid | error; one bad item never stops the others. Writes created_by = the caller and linked_by_actor_id = the agent actor of the session. Same ADR-2 rule as add_task_pr: only a delivers link may move a task. Caller user JWT, RLS applies (members write).
| Parameter | Type | Required | Description |
|---|---|---|---|
links | object[] | yes | 1 to 100 links. |
remove_task_pr
Remove links between tasks and GitHub pull requests: DELETES rows of review_request.review_request_task_links.write
remove_task_prRemove Task PR
Remove links between tasks and GitHub pull requests: DELETES rows of review_request.review_request_task_links. It never deletes a task or a PR row. Two forms, exactly one per call: (1) link_ids = 1 to 100 link UUIDs (the link_id that list_task_prs returns). This form also removes an ORPHAN link, whose task or PR row no longer exists; (2) task_id + pr_url (https://github.com/<owner>/<repo>/pull/<number>) = the one link of that pair. The answer lists removed rows (each with task_found, pr_found and orphan), not_found (ids or pairs with no link) and not_removed (rows that the delete policy kept). success is false when a row was kept. A wrong link is fixed by remove_task_pr, then add_task_pr (a link is never updated). Caller user JWT, RLS applies (members delete).
| Parameter | Type | Required | Description |
|---|---|---|---|
link_ids | string[] | no | Link UUIDs to remove (1 to 100). Do not combine with task_id / pr_url. |
task_id | string | no | The UUID of the task (with pr_url) |
pr_url | string | no | The PR URL (with task_id): https://github.com/<owner>/<repo>/pull/<number>. |
upsert_pull_requests
Reconcile the PR mirror (review_request.review_requests) from GitHub pull request objects that YOU read from GitHub (gh api repos/<owner>/<repo>/pulls?state=open|closed, or pulls/<n>).write
upsert_pull_requestsUpsert Pull Requests
Reconcile the PR mirror (review_request.review_requests) from GitHub pull request objects that YOU read from GitHub (gh api repos/<owner>/<repo>/pulls?state=open|closed, or pulls/<n>). Generic and repeatable: send the same PRs again and nothing changes. For each PR it writes pr_state (open | closed | merged), is_draft, base_sha, head_sha, merge_commit_sha (merged only), labels, mergeable_state, github_updated_at, title, branch names and sync_source "backfill". The natural key is (repo, number); the row is found by github_pr_id first. OUT-OF-ORDER GUARD: a row changes only when its github_updated_at is empty or not newer than the PR you send, so an older read never overwrites a webhook event (those PRs return outcome stale). The review status moves only in the obvious direction (open to merged or closed) and never over a human verdict. create_missing (default true; false = update only, a PR the mirror does not hold is counted as skipped) inserts a row for a PR the mirror does not hold, with created_by = the caller and context.review_list false (it stays out of the dfl-reviews lists). Up to 100 PRs per call; an item with a bad shape is reported in results and does not stop the others. Needs a GLOBAL ADMIN caller (the facts are caller-supplied); the caller user JWT applies, RLS applies. This tool does not call GitHub and never links a task: use add_task_pr for that. The GitHub App poll of dfl-github-webhook does the same job on a timer once the App is configured. Read the result back with list_task_prs.
| Parameter | Type | Required | Description |
|---|---|---|---|
pull_requests | object[] | yes | GitHub pulls API objects. Needs id, number, state; also read: title, html_url, draft, merged, merged_at, closed_at, created_at, updated_at, merge_commit_sha, mergeable_state, user, head{sha,ref}, base{sha,ref,repo.full_name}, labels. Or give repo_full_name on the item. |
create_missing | boolean | no | Insert a row for a PR that the mirror does not hold (default true) |
list_pull_requests
Read PR and CI state from the PR mirror (review_request.review_requests), which the GitHub intake fills from PR, check and status events.read
list_pull_requestsList Pull Requests (PR mirror)
Read PR and CI state from the PR mirror (review_request.review_requests), which the GitHub intake fills from PR, check and status events. Use it INSTEAD of polling the GitHub API (gh pr view / gh pr list / pr checks). One call answers many PRs: filter by repo_full_names (up to 50, case-insensitive), branch_names (head branch, up to 200), numbers (with repo_full_names), pr_state (open | closed | merged), include_draft (default true), updated_since (ISO, by synced_at); limit default 100, max 500, newest GitHub update first; truncated true when more rows match. Each row: repo, number, URL, title, pr_state, is_draft, branch_name, head/base/merge SHAs, merged_at, closed_at, ci_state, ci_head_sha, ci_current, mergeable_state, labels, author_login, github_updated_at, synced_at, sync_age_seconds, sync_source. TRUST RULE: merged/closed is terminal; ci_state describes the head only when ci_current is true; a row is the last GitHub event, so verify on GitHub once before a merge (safe-admin-merge does); no row = ask GitHub. Read only. Caller user JWT, RLS applies (members read).
| Parameter | Type | Required | Description |
|---|---|---|---|
repo_full_names | string[] | no | owner/name, case-insensitive. |
branch_names | string[] | no | Head branch names. |
numbers | number[] | no | PR numbers (needs repo_full_names) |
pr_state | enum | no | One of: open, closed, merged. |
include_draft | boolean | no | false = leave out drafts (default true) |
updated_since | string | no | ISO timestamp: rows synced at or after it. |
limit | number | no | — |
Optional task request UUID
Section titled “Optional task request UUID”create_task accepts an optional request_id UUID. The keyed path defaults to disabled.
A supplied UUID returns not_configured without a write while WORK_CREATE_TASK_REQUEST_IDS is not true.
Calls without request_id keep the existing behavior.
A refusal before a write describes only the current call. An earlier attempt with that UUID can already exist.
Retain the request UUID when an earlier outcome is unknown.
When enabled, retain the UUID and the same accepted task input after a lost response. The server hashes the original validated input before it resolves owner or actor defaults. Object key order does not change the hash. Array order and absent fields do change it. The server normalizes the request UUID to lowercase. It excludes that UUID from the payload hash.
The original public.activity_logs creation snapshot binds the caller, operation, request UUID, and payload hash.
Task edits do not change this binding. A different input returns conflict without a write.
A matching visible task returns success: true with status: reconciled.
A missing or inaccessible task returns uncertain. The server does not recreate it.
Invalid audit proof and unknown insert outcomes also return uncertain.
An explicit database refusal returns rejected when no original binding is visible.
Actor attribution uses a separate request. The original snapshot stores the resolved actor in server-owned context.creation_actor.
A retry uses that identity, even if the slug mapping changes.
The server reconciles the existing unique actor link. It does not overwrite the link or delete the task.
Missing or unverified attribution returns success: false, status: attribution_pending, task_id, and request_id.
This is not a claim of one transaction across task creation and actor attribution.
Clients must retain the request UUID for uncertain and attribution_pending outcomes.
Clients must not treat those outcomes as a completed task operation.
context.source, context.creation_request, and context.creation_actor are server-owned.
Supply only the documented context fields. The keyed path rejects unsupported context fields. Legacy calls retain their previous context filtering.
The creation request metadata contains exactly operation, request_id, and payload_sha256.
Activation gate
Section titled “Activation gate”Set WORK_CREATE_TASK_REQUEST_IDS=true only after all these checks:
- A human merges and applies the
dfl-schemamigration20261006150201_public_activity_logs_creation_requests.sql. - Confirm
activity_logs_creation_request_metadata_check,activity_logs_creation_request_key, and the audit ACL changes exist in production. - Complete the production metadata validity and uniqueness preflight in the schema contract.
- Confirm runtime retention excludes keyed original creation events from every audit purge.
- Prove a real caller fixture can reconcile a lost response without a duplicate task or actor link.
- Prove changed input returns conflict. Prove a deleted task does not return or reappear.
The flag does not detect schema deployment. Local transport tests do not prove production activation. The current service change does not prove a Mac ChatGPT or Codex retry. Plan T6 remains open until the schema, service, and client evidence are complete.
Task runs
Section titled “Task runs”One row per agent run that worked on a task (work.task_runs, DFL OS sub-plan c). Ids, counts, tokens and times only: no prompt and no transcript text. Only an agent actor writes a run, and only the actor that recorded a run updates it. Every member reads them.
Which agent runs worked on a task: record a run (model, host, tokens, times, PR) and list the runs of a task, plan or session.
upsert_task_run
Record one agent run that worked on a task (work.task_runs), or update it.write
upsert_task_runUpsert Task Run
Record one agent run that worked on a task (work.task_runs), or update it. Upsert on (task_id, run_id): the first call inserts the row (send the start: run_kind, session_id, executor, started_at); a later call with the same key updates only the measurement fields that it sends (ended_at, tokens, counts, cost, model, host, PR). A field you omit keeps its value. started_at is set once: a later call keeps the stored started_at and ignores the one that it sends (the stored value is replaced only when the row has none). Ids, counts, tokens and times only: there is no text field. The caller must be an AGENT actor (an agent login, or a connector grant that acts as an agent); the tool stamps the row with that actor as the writer, and only that actor can update the row. A human session is refused. The executor is a fleet actor slug (claude-main, clawd, deck, codex), not necessarily the caller.
| Parameter | Type | Required | Description |
|---|---|---|---|
task_id | string | yes | The UUID of the task that this run worked on. |
run_id | string | yes | The run's own id at its source: the Claude Code agent id for a subagent, the session id for a session, the Codex or opencode session id. With task_id it is the upsert key. |
run_kind | enum | yes | session | subagent | headless | workflow. One of: session, subagent, headless, workflow. |
session_id | string | yes | The Claude Code (or Codex / opencode) session id that holds the run. It cannot change after the first record. |
executor | string | yes | The slug of the fleet agent actor that executed the run: claude-main, clawd, deck or codex (any agent actor slug works). A slug, not a UUID. |
agent_id | string | no | The subagent id (Claude Code agent id), when the run is a subagent. |
parent_session_id | string | no | The session that dispatched this run, when there is one. |
model | string | no | The model id, for example claude-opus-5-5. |
subagent_type | string | no | The subagent type, for example general-purpose or Explore. |
host | string | no | The host that ran it, for example openclaw-tainan or alien01. |
tokens_in | number | no | Input tokens. |
tokens_out | number | no | Output tokens. |
tokens_cache_read | number | no | Cache read tokens. |
tokens_cache_write | number | no | Cache write tokens. |
tool_call_count | number | no | Number of tool calls. |
turn_count | number | no | Number of turns. |
cost_usd | number | no | Cost in USD. |
cost_is_estimate | boolean | no | true (the default on the first record) when cost_usd is an estimate from tokens. |
started_at | string | yes | When the run started (ISO 8601 with an offset). Set once: a later call keeps the stored value. |
ended_at | string | no | When the run ended. Omit on the start record; send it on the end record. |
pr_repo | string | no | owner/name of the delivered PR. Send it together with pr_number. |
pr_number | number | no | Number of the delivered PR. Send it together with pr_repo. |
link_kind | enum | no | declared (the run named the task uuid; the default) or inferred (a backfill matched it by plan slug). One of: declared, inferred. |
list_task_runs
List the agent runs recorded for tasks (work.task_runs), newest first.read
list_task_runsList Task Runs
List the agent runs recorded for tasks (work.task_runs), newest first. Filter by task_id, plan_slug (the tasks bound to the plan), session_id, executor (fleet actor slug), since (started_at) and link_kind. Each run carries its executor and writer actor slugs, model, host, tokens, counts, cost estimate, times and the delivered PR. Read-only, under your own login: a member reads every run.
| Parameter | Type | Required | Description |
|---|---|---|---|
task_id | string | no | Only the runs of this task. |
plan_slug | string | no | Only the runs of the tasks bound to this plan (work.entity_connections). |
session_id | string | no | Only the runs of this session. |
executor | string | no | Only the runs that this fleet actor executed (slug: claude-main, clawd, deck, codex). |
since | string | no | Only the runs that started at or after this time (ISO 8601). |
link_kind | enum | no | Only declared or only inferred links. One of: declared, inferred. |
limit | number | no | Maximum rows (default 50, max 200). |
offset | number | no | Rows to skip, for paging (default 0). |
list_task_model_matches
Planned versus actual model per task.read
list_task_model_matchesList Task Model Matches
Planned versus actual model per task. For each task (default: done tasks, newest first) it returns the planned executor and model (context.executor, context.planned_model), the models and executors of its runs (work.task_runs), the use-case class (work.task_classifications, newest taxonomy version), and two flags: model_match and executor_match, each one of match | partial | mismatch | no_planned | no_run. Models compare by family (opus, sonnet, haiku, fable): "sonnet" matches "claude-sonnet-5-5". "partial" = the planned family ran, with another family beside it. The summary counts the flags in total, per class and per planned model, and gives coverage_pct = the share of tasks that have both a planned model and a run model. Filters: done_since, created_since, plan_slug, status, only_mismatches. For the coverage measure pass created_since = the MODEL-AT-CREATE cut-off: only tasks made after the rule count. Read-only, under your own login (RLS applies). Page with limit and offset; the summary covers the rows read, not the whole set.
| Parameter | Type | Required | Description |
|---|---|---|---|
done_since | string | no | Only tasks that reached done at or after this time (ISO 8601). Used when status is "done". |
created_since | string | no | Only tasks CREATED at or after this time (ISO 8601). The model coverage measure passes the cut-off of the MODEL-AT-CREATE rule (create_task requires planned_model since then; Tainan Q 6399046c = B), so tasks made before the rule do not count. |
plan_slug | string | no | Only the tasks bound to this plan. |
status | string | no | Task status to read (default "done"). |
only_mismatches | boolean | no | Return only the tasks whose model_match is "mismatch" or "partial" (default false). The summary still covers every row read. |
include_session_runs | boolean | no | Count the claude-main session rows as runs too (default false: only subagent, headless and workflow runs). |
limit | number | no | Maximum tasks to read, newest done first (default 100, max 200). |
offset | number | no | Tasks to skip, for paging (default 0). |
Business Units
Section titled “Business Units”Find, create and edit business units.
list_business_units
List all business units with optional filters.read
list_business_unitsList Business Units
List all business units with optional filters. Requires finance/admin/owner role.
| Parameter | Type | Required | Description |
|---|---|---|---|
limit | number | no | Maximum number of business units to return (default: 50, max: 100) |
offset | number | no | Number of business units to skip (for pagination) |
search | string | no | Search by business unit name. |
tag | string | no | Filter by tag. |
get_business_unit
Get a specific business unit by ID.read
get_business_unitGet Business Unit
Get a specific business unit by ID. Requires finance/admin/owner role.
| Parameter | Type | Required | Description |
|---|---|---|---|
id | string | yes | Business unit ID (UUID) |
create_business_unit
Create a new business unit.write
create_business_unitCreate Business Unit
Create a new business unit. Requires finance/admin/owner role.
| Parameter | Type | Required | Description |
|---|---|---|---|
name | string | yes | Business unit name. |
profile_image_url | string | no | Profile image URL. |
tags | string[] | no | Array of tags. |
update_business_unit
Update an existing business unit.write
update_business_unitUpdate Business Unit
Update an existing business unit. Requires finance/admin/owner role.
| Parameter | Type | Required | Description |
|---|---|---|---|
id | string | yes | Business unit ID (UUID) |
name | string | no | Business unit name. |
profile_image_url | string | no | Profile image URL, null to remove. |
tags | string[] | no | Array of tags, null to remove. |
delete_business_unit
Delete a business unit by ID.write
delete_business_unitDelete Business Unit
Delete a business unit by ID. Requires finance/admin/owner role.
| Parameter | Type | Required | Description |
|---|---|---|---|
id | string | yes | Business unit ID (UUID) |
Placements
Section titled “Placements”Record where a fellow got placed (job, freelance, internal), and map a speaker name to a member.
create_placement
Record a DFL fellow placement (job/freelance/internal) in work.placements.write
create_placementCreate Placement
Record a DFL fellow placement (job/freelance/internal) in work.placements. Tier A = external employment (vaga em empresa terceira). Tier B = external paid freelance/project. Tier C = internal DFL/Revera paid project. Provide member_id directly, or resolve a fellow name to its public.members.id with lookup_member (in the learn MCP) first. All fields (incl. reason_we_helped, is_internal_hire_promoted, had_prior_tech_background, consent_to_report) are applied in the current prod schema. Runs under the caller JWT — RLS enforces global-admin write access.
| Parameter | Type | Required | Description |
|---|---|---|---|
member_id | string | yes | public.members.id of the fellow (resolve a name via lookup_member in the learn MCP). FK -> public.members(id). |
company | string | yes | Employer / company / org name (column: company). |
role | string | yes | Role / job title (column: role). |
type | enum | no | Kind of placement. DB default: employed. (column: type / work.placement_type) One of: employed, freelance, founded, internship. |
started_at | string | yes | Start date (ISO date, e.g. 2025-03-01). (column: started_at) |
ended_at | string | no | End date (ISO date); omit if still active. (column: ended_at) |
placement_tier | enum | no | A = external employment; B = external paid freelance; C = internal DFL/Revera paid project. Optional (nullable in schema), but should be set for the UNICEF-headline slicing. One of: A, B, C. |
source_of_record | enum | no | Confidence of the record source (low→high). Defaults to self_report (DB default). (column: source_of_record / work.placement_source) One of: self_report, mentor_confirmed, contract_doc, employer_confirmed. |
reason_we_helped | enum[] | no | How DFL helped the fellow land this placement (enum array). ⚠️ Requires pending migration dfl-schema #397 — omit until applied or the insert will error. |
is_internal_hire_promoted | boolean | no | TRUE for the Samuel/William case: DFL hired a non-dev as a full-time dev. (column: is_internal_hire_promoted; NOT NULL default false) |
had_prior_tech_background | boolean | no | Whether the fellow already had a tech background before this placement. FALSE for internal hires who "não eram da área" (Samuel/William). (column: had_prior_tech_background; nullable) |
consent_to_report | boolean | no | LGPD consent to use this placement in external/UNICEF reports. Defaults to false (DB default) — rows exist but are excluded from external reports until consent is recorded. (column: consent_to_report; NOT NULL default false) |
evidence_url | string | no | Evidence link (LinkedIn, offer letter, contract photo, etc.). (column: evidence_url) |
notes | string | no | Free-form notes / context. (column: notes) |
created_by | string | no | auth.users.id of who logged this record (FK -> auth.users.id). Optional. (column: created_by) |
create_member_label_alias
Map a raw speaker/label string to a member by upserting into work.member_label_aliases.write
create_member_label_aliasCreate Member Label Alias
Map a raw speaker/label string to a member by upserting into work.member_label_aliases. Used to resolve attendance/meeting_participants raw_label values (transcript spellings, first-name-only, etc.) back to a fellow. Idempotent: upserts on the UNIQUE (alias, member_id) constraint, so re-running the same mapping is a no-op (refreshes source/confidence/context). Provide member_id directly, or resolve a fellow name to its id with lookup_member (in the learn MCP) first. Match the alias to the EXACT raw_label string used in work.meeting_participants.
| Parameter | Type | Required | Description |
|---|---|---|---|
alias | string | yes | The raw label / speaker string to map (e.g. the exact raw_label in work.meeting_participants). (column: alias) |
member_id | string | yes | work.members.id the alias maps to (resolve a name via lookup_member in the learn MCP). FK -> work.members(id). |
source | string | no | Origin of the mapping: manual | extractor | fireflies | gmail_signature | ... DB default: 'manual'. (column: source) |
confidence | number | no | Confidence of the mapping, 0..1. DB default: 1.00. (column: confidence) |
context | string | no | Free-text traceability note, e.g. "Tainan TG msg 6515" or "attendance audit 2026-06-14 — HIGH confidence". (column: context) |
Meetings
Section titled “Meetings”Fix recurring meetings: merge duplicates, set their time window and their template.
merge_meetings
Dedup a duplicate recurring-meeting cluster by MERGING a skeleton meeting into a canonical meeting, then removing the skeleton.write
merge_meetingsMerge Duplicate Recurring Meetings
Dedup a duplicate recurring-meeting cluster by MERGING a skeleton meeting into a canonical meeting, then removing the skeleton. LOSSLESS on duplicate-date collisions: it NEVER drops a transcription-bearing occurrence in favor of an empty one. For a date both meetings have, it compares transcripts on BOTH sides — if the canonical occurrence is EMPTY but the skeleton one carries a real transcript, it RE-PARENTS the skeleton occurrence onto the canonical and DELETES the empty canonical duplicate (the real transcript survives). If BOTH carry transcripts it reports a CONFLICT, keeps both, and does NOT remove the skeleton row (manual review needed). Empty skeleton duplicates of a transcript-bearing (or empty) canonical date are dropped; skeleton occurrences on a NEW date are re-parented. Other meeting_id child rows (participants/concepts/expertise/tools/underlines) are re-parented too, guarding the meeting_participants UNIQUE constraint. The skeleton meetings row is removed only when there are ZERO unresolved conflicts. Transcriptions live per-occurrence so nothing is concatenated. It also PRESERVES the work.meetings.template field: if the canonical is null/"default" and the skeleton carries a non-default template (e.g. "weekly_leaders"), the canonical is updated to the skeleton's template (carry the more-specific value forward; never downgrade). ALWAYS run with dry_run:true first on prod data to preview the change.
| Parameter | Type | Required | Description |
|---|---|---|---|
canonical_meeting_id | string | yes | work.meetings.id of the CANONICAL meeting that SURVIVES (the Fireflies-sourced row that usually holds the real transcriptions on its occurrences). |
skeleton_meeting_id | string | yes | work.meetings.id of the SKELETON meeting to merge in and then REMOVE (the empty Google-Calendar-invite row, e.g. "Updated invitation: …" or a title-variant with no cal-id). If a duplicate-date collision is resolved in the skeleton's favor (its occurrence carries the real transcript), that occurrence is re-parented onto the canonical before the skeleton is removed. |
dry_run | boolean | no | When true (recommended first), report what WOULD change without writing anything. Default: false. |
set_meeting_recurrence_time
Set the time-of-day window (recurrence_start_time / recurrence_end_time) on a single recurring meeting series in work.meetings, so its recurring occurrences render at the right hour on the /meetings time-grid.write
set_meeting_recurrence_timeSet Meeting Recurrence Time Window
Set the time-of-day window (recurrence_start_time / recurrence_end_time) on a single recurring meeting series in work.meetings, so its recurring occurrences render at the right hour on the /meetings time-grid. Times are 24h wall-clock "HH:MM" or "HH:MM:SS" (Postgres time). The meeting must already be a recurring series (is_recurring = true); recurrence_day_of_week is set separately. Returns the updated row.
| Parameter | Type | Required | Description |
|---|---|---|---|
meeting_id | string | yes | work.meetings.id of the recurring series to update. |
recurrence_start_time | string | yes | Series start time-of-day, 24h "HH:MM" or "HH:MM:SS" (e.g. "12:30"). |
recurrence_end_time | string | yes | Series end time-of-day, 24h "HH:MM" or "HH:MM:SS" (e.g. "13:30"). |
set_meeting_template
Set the UI template (work.meetings.template) on a single meeting in work.meetings.write
set_meeting_templateSet Meeting Template
Set the UI template (work.meetings.template) on a single meeting in work.meetings. The template selects which structured-underline UI the dfl-learn /meetings view renders — the weekly-leaders structured form is gated on template = "weekly_leaders". Allowed values: "default" | "weekly_leaders" (mirrors the dfl-learn UnderlineTemplate enum). Unknown values are rejected. Returns the updated row (id, title, template). Primary use: restore a meeting's template after a dedup-merge collapsed it to "default".
| Parameter | Type | Required | Description |
|---|---|---|---|
meeting_id | string | yes | work.meetings.id of the meeting whose template to set. |
template | enum | yes | The UI template to set. One of: "default", "weekly_leaders". One of: default, weekly_leaders. |
Meeting series data-ops
Section titled “Meeting series data-ops”Clean up recurring meeting series without losing their transcripts.
list_meeting_series
READ-ONLY discovery of recurring meeting SERIES PARENTS in work.meetings (is_recurring = true), so an operator can find duplicate/dedup targets without psql.read
list_meeting_seriesList Recurring Meeting Series
READ-ONLY discovery of recurring meeting SERIES PARENTS in work.meetings (is_recurring = true), so an operator can find duplicate/dedup targets without psql. Filter by creation window (created_after / created_before), title substring, or fireflies_calendar_id substring. Each result carries the series id, title, fireflies_calendar_id, meeting_date, created_at and an occurrence accounting: occurrence_count, occurrences_with_transcript (real transcript TEXT) and occurrences_with_transcript_id (a Fireflies transcript id). Set include_occurrences:true to also get the per-occurrence rows (id, occurrence_date, status, has_transcript, fireflies_transcript_id). Transcript TEXT is NEVER returned — it is tens/hundreds of KB per occurrence. Results are sorted by created_at ascending. Use this before remove_meeting_series to confirm exactly which series you are about to remove and how much real content hangs off it.
| Parameter | Type | Required | Description |
|---|---|---|---|
created_after | string | no | Only series created at or after this ISO-8601 timestamp (e.g. "2026-07-28T00:00:00Z"). The canonical way to answer "which series were created today?". |
created_before | string | no | Only series created at or before this ISO-8601 timestamp. |
title_contains | string | no | Case-insensitive substring match on work.meetings.title. |
fireflies_calendar_id_contains | string | no | Case-insensitive substring match on fireflies_calendar_id. Useful to group the "_R<instance>" forks Google mints for the same base calendar id (e.g. pass the base id without the suffix). |
include_occurrences | boolean | no | When true, include the per-occurrence rows for each series (id, occurrence_date, status, has_transcript, fireflies_transcript_id). Never includes transcript text. Default: false. |
limit | number | no | Maximum number of series to return. Default: 100. |
remove_meeting_series
Remove ONE recurring meeting SERIES PARENT from work.meetings, promoting its occurrences to standalone ("avulsa") meetings FIRST so the ON DELETE CASCADE can never destroy a transcript.write
remove_meeting_seriesRemove Recurring Meeting Series (data-ops)
Remove ONE recurring meeting SERIES PARENT from work.meetings, promoting its occurrences to standalone ("avulsa") meetings FIRST so the ON DELETE CASCADE can never destroy a transcript. Transcripts live PER-OCCURRENCE and all 7 FKs onto work.meetings(id) are ON DELETE CASCADE, so the order promote -> verify -> delete IS the safety mechanism (an MCP tool cannot hold a Postgres transaction across calls). Guards, all of which ABORT rather than guess: (a) UNTRACKABLE — any occurrence with transcript text but no fireflies_transcript_id; (b) ALREADY-PROMOTED — occurrences whose transcript id already exists on a meetings row are skipped, not re-inserted (partial UNIQUE uq_meetings_fireflies_transcript_id), which also makes the tool idempotent on retry; (c) CASCADE — refuses when meeting_participants / meeting_concepts / meeting_expertise / meeting_tools / meeting_transcript_segments / meeting_underlines have rows on this parent or its occurrences (use merge_meetings instead, it knows how to re-parent those); (d) a post-promotion ASSERT that every surviving occurrence has a standalone counterpart before anything is deleted. Promoted rows get is_recurring:false and fireflies_calendar_id:null (deliberately detached from any series), the parent's title, the occurrence's content, and a meeting_date rebuilt from the occurrence date plus the parent's time-of-day. SIDE EFFECT: work.meetings has an AFTER INSERT trigger (meetings_to_n8n) that POSTs each new row to the n8n process_devfellowship_meetings webhook; a user-JWT tool cannot disable it, so every promotion fires one n8n workflow — the count is reported as n8n_webhook_inserts. ALWAYS run with dry_run:true first on prod: it returns the exact same result shape with nothing written.
| Parameter | Type | Required | Description |
|---|---|---|---|
series_meeting_id | string | yes | work.meetings.id of the recurring SERIES PARENT to remove. Find it with list_meeting_series. |
occurrence_policy | enum | no | How to treat the series occurrences. "promote_real_discard_empty" (DEFAULT): occurrences carrying transcript TEXT or a fireflies_transcript_id are PROMOTED to standalone meetings; occurrences with neither (empty materializer placeholders, typically future-dated) are DELETED — recreating those would only manufacture junk rows. "promote_all": every occurrence is promoted, even the empty placeholders. "require_empty": pure safety mode — refuse to do anything unless the series has ZERO occurrences. One of: promote_real_discard_empty, promote_all, require_empty. |
allow_non_recurring | boolean | no | By default the tool REFUSES a meeting with is_recurring = false, so it can never be pointed at a standalone ("avulsa") meeting by mistake. Set true to override deliberately. Default: false. |
dry_run | boolean | no | When true, NOTHING is written — returns the exact same result shape describing what WOULD happen (including n8n_webhook_inserts). ALWAYS run dry_run:true first on prod. Default: false. |
promote_occurrence_to_standalone
Promote ONE work.meeting_occurrences row to a standalone ("avulsa") work.meetings row and then detach/delete the occurrence.write
promote_occurrence_to_standalonePromote Meeting Occurrence to Standalone Meeting
Promote ONE work.meeting_occurrences row to a standalone ("avulsa") work.meetings row and then detach/delete the occurrence. The generic primitive underneath remove_meeting_series; use it to pull a single meeting out of a recurring series. The new meeting gets is_recurring:false, fireflies_calendar_id:null (deliberately detached), the parent series' title (or title_override), the occurrence's content, and a meeting_date rebuilt from the occurrence date plus the parent's time-of-day. Guards: it refuses an occurrence carrying transcript text with NO fireflies_transcript_id unless keep_occurrence:true (the copy could not be verified by transcript id, so deleting the source would be unsound); it never mints a second meetings row for a transcript id that already exists (partial UNIQUE uq_meetings_fireflies_transcript_id) and reports the existing meeting instead, which makes it idempotent; and it refuses when meeting_participants / meeting_underlines rows FK on this occurrence, since those are ON DELETE CASCADE and would be destroyed. Order is the safety mechanism: INSERT and confirm, then delete. SIDE EFFECT: the meetings_to_n8n AFTER INSERT trigger POSTs each new row to the n8n process_devfellowship_meetings webhook and a user-JWT tool cannot disable it, so one n8n workflow fires per promotion (reported as n8n_webhook_inserts). Run dry_run:true first on prod.
| Parameter | Type | Required | Description |
|---|---|---|---|
occurrence_id | string | yes | work.meeting_occurrences.id to promote. Find it with list_meeting_series({include_occurrences:true}). |
title_override | string | no | Title for the new standalone meeting. Defaults to the parent series' title (occurrences have no title of their own). |
keep_occurrence | boolean | no | When true, create the standalone meeting but LEAVE the occurrence in place — a copy-then-review flow where nothing is destroyed. Also the escape hatch for an occurrence whose transcript has no fireflies_transcript_id, or one that still has participant/underline rows attached. Default: false (the occurrence is deleted after the copy is confirmed). |
dry_run | boolean | no | When true, NOTHING is written — returns the same result shape describing what WOULD happen. ALWAYS run dry_run:true first on prod. Default: false. |
Weekly updates
Section titled “Weekly updates”Read-only. What one member did in the last N days, per source, with a daily text ready to paste. Mirrors the Weekly updates page of dfl-learn (/weekly-updates).
What one person did in the last days, ready to paste as a daily update.
get_weekly_updates
Read-only. What one member did in the last N days (Brasília calendar days, today included): tasks moved to done/dev_completed, tasks in progress, merged PRs (review_request.review_requests), Core Daily lines they said…read
get_weekly_updatesGet weekly updates for a member
Read-only. What one member did in the last N days (Brasília calendar days, today included): tasks moved to done/dev_completed, tasks in progress, merged PRs (review_request.review_requests), Core Daily lines they said (resolved per meeting: segment attribution, then the top alias, then the exact name; any ambiguity leaves the line out), and plans whose status changed (read with your session). Each source degrades on its own: see unavailable and truncated. daily_text is ready to paste in the "Bom dia / Ontem / Hoje / No blockers" format, one line per item, with no PR numbers, repos, task identifiers or links. Defaults to you when member_id is omitted.
| Parameter | Type | Required | Description |
|---|---|---|---|
member_id | string | no | public.members id; defaults to the caller. |
days | number | no | Window in Brasília calendar days, 1–14. Default: 7. |
Session
Section titled “Session”See which actor, OAuth client and scope this connection uses on this host.
get_current_actor
Returns who this MCP session acts as on this host: actor {id, slug, display_name, type}, client {id, name} (the OAuth client; name is null when the provider does not show it), scope ("read" or "read+write"), and source.read
get_current_actorGet Current Actor
Returns who this MCP session acts as on this host: actor {id, slug, display_name, type}, client {id, name} (the OAuth client; name is null when the provider does not show it), scope ("read" or "read+write"), and source. source "oauth_grant": an OAuth session, the actor is the grant actor (null when the grant has no actor, which makes the session read-only). source "agent_login": a first-party dfl-auth login of an agent user; the actor is that user's own agent actor, client and scope are null. source "first_party_login": a first-party login with no own agent actor (a human user); all three are null. source "unresolved": this host could not resolve the actor. Read-only.
Takes no parameters.