NOUKAI

Tool Listing

All 45 Noukai MCP tools organized by category with parameter schemas.

Noukai exposes 45 MCP tools for programmatic flow management.

Read Tools

Inspect flows, blocks, and operation history.

list_flows

List all flows in a project with summary info: ID, name, slug, block count, and whether steps exist. Does not include block details — use get_flow or hydrate_project for that.

ParameterTypeRequiredDescription
project_idstringYesProject UUID

get_flow

Get full flow detail: metadata, annotated steps tree (with block names and processor types inline), and all block details including prompts, schemas, and configs.

ParameterTypeRequiredDescription
flow_idstringYesFlow UUID

get_flow_structure

Get just the annotated steps tree for a flow — lightweight. Returns the tree with block names and processor types inline, plus block count. Use this when you only need topology, not full block details.

ParameterTypeRequiredDescription
flow_idstringYesFlow UUID

get_block

Get a single block's full detail: prompt, model, schemas, config, processor config, and notes. Use when you need to inspect or modify one specific block.

ParameterTypeRequiredDescription
flow_idstringYesFlow UUID
step_idstringYesStep ID of the block

get_operation_history

Get recent operation history for a flow from the oplog. Returns operation type, sequence number, timestamp, request payload, and result. Useful for understanding what changes were made recently.

ParameterTypeRequiredDescription
flow_idstringYesFlow UUID
limitintegerNoMax entries to return (1-100, default 20)
offsetintegerNoNumber of entries to skip (default 0)

hydrate_project

Fetch complete project data: all flows with their blocks (including prompts, schemas, configs), checkpoints, versions, object models, and test cases. Call this first to understand a project's current state.

ParameterTypeRequiredDescription
project_idstringYesProject UUID

get_test_run_trace

Get the full trace for a test run: run summary plus per-step details including input/output snapshots, token counts, model used, cost, and error context. Use the runId returned by run_test_case to inspect what each block received and produced — essential for debugging test failures.

ParameterTypeRequiredDescription
flow_run_idstringYesFlow run UUID (the runId returned by run_test_case)

get_step_trace

Get the trace for a single step within a test run. Returns detailed input/output snapshots, token usage, model, cost, and error context for the step. Use attempt="all" to see retry history or a specific attempt number.

ParameterTypeRequiredDescription
flow_run_idstringYesFlow run UUID
step_idstringYesStep ID of the block to inspect
attemptstringNoWhich attempt to return: latest (default), all, or a number (e.g. 1)

Structural Tools

Add, remove, move, and organize blocks in the flow tree.

add_block

Add a new processing block to a flow. Two modes: (1) Sibling-relative — use target_id + direction to insert relative to an existing block (preferred). (2) Parent-absolute — use parent_id + position for exact placement. If the flow is empty, omit both to create the first block.

ParameterTypeRequiredDescription
flow_idstringYesFlow UUID
namestringYesBlock display name
processor_typestringYesOne of: llm, passthrough, code
target_idstringNoStep ID of an existing block to insert relative to (sibling-relative mode)
directionleft, right, top, bottomNoWhere to place the new block relative to target_id
parent_idstringNoParent container/loop ID (parent-absolute mode). Null for root (empty tree only)
positionintegerNo0-indexed position within parent's children (parent-absolute mode)
modelstringNoModel identifier (e.g. anthropic/claude-sonnet-4-6)
promptstringNoInitial prompt text

remove_block

Remove a block from a flow. If the block's parent container has only one child after removal, the container is automatically unwrapped.

ParameterTypeRequiredDescription
flow_idstringYesFlow UUID
step_idstringYesStep ID of the block to remove

move_block

Move a block (or container) to a new position in the flow tree.

ParameterTypeRequiredDescription
flow_idstringYesFlow UUID
step_idstringYesStep ID of the node to move
new_parent_idstringYesTarget parent container/loop ID
new_positionintegerYesPosition in new parent's children (0-indexed, post-removal)

duplicate_block

Copy a block to a new position with new IDs. Defaults to immediately after the original.

ParameterTypeRequiredDescription
flow_idstringYesFlow UUID
step_idstringYesStep ID of the block to duplicate
target_parent_idstringNoTarget parent (defaults to same parent)
target_positionintegerNoPosition (defaults to after original)

wrap_in_container

Wrap one or more adjacent sibling nodes in a new container.

ParameterTypeRequiredDescription
flow_idstringYesFlow UUID
node_idsarrayYesIDs of adjacent sibling nodes to wrap
container_typestringYesh (sequential) or v (parallel)

unwrap_container

Remove a container and promote its children to the container's parent.

ParameterTypeRequiredDescription
flow_idstringYesFlow UUID
container_idstringYesID of the container to unwrap

wrap_in_loop

Wrap one or more adjacent sibling nodes in a loop that iterates over an array field.

ParameterTypeRequiredDescription
flow_idstringYesFlow UUID
node_idsarrayYesIDs of adjacent sibling nodes to wrap
array_fieldstringYesName of the array field to iterate over
loop_idstringNoOptional client-generated loop ID (server generates one if omitted)

unwrap_loop

Remove a loop and promote its children to the loop's parent.

ParameterTypeRequiredDescription
flow_idstringYesFlow UUID
loop_idstringYesID of the loop to unwrap

reorder_children

Reorder the children of a container or loop. The new order must contain exactly the same child IDs.

ParameterTypeRequiredDescription
flow_idstringYesFlow UUID
parent_idstringYesContainer or loop ID
child_orderarrayYesNew order of child IDs

rename_block

Rename a block's display name.

ParameterTypeRequiredDescription
flow_idstringYesFlow UUID
step_idstringYesStep ID of the block
namestringYesNew name

change_processor_type

Change a block's processor type (llm, passthrough, or code).

ParameterTypeRequiredDescription
flow_idstringYesFlow UUID
step_idstringYesStep ID of the block
processor_typestringYesllm, passthrough, or code

Lifecycle Tools

Create and delete flows.

create_flow

Create a new empty flow in a project. This is the first step when building a new pipeline.

ParameterTypeRequiredDescription
project_idstringYesProject UUID
namestringYesFlow display name
slugstringYesURL-safe identifier (lowercase, hyphens)
descriptionstringNoFlow description

delete_flow

Delete a flow and all its blocks, checkpoints, and versions (soft-delete). This is destructive.

ParameterTypeRequiredDescription
flow_idstringYesFlow UUID

Content Tools

Update block prompts, schemas, configs, and flow metadata.

update_block_draft

Update a block's prompt text (full replacement, not a diff). Uses optimistic concurrency — omit base_version to auto-detect, or provide it for rapid sequential edits.

ParameterTypeRequiredDescription
flow_idstringYesFlow UUID
step_idstringYesStep ID of the block
contentstringYesThe new prompt text (full replacement)
base_versionintegerNoContent version to check against. Omit to auto-detect.

update_block_config

Update a block's model and configuration. At least one of model, config, or processor_config must be provided — omitted fields remain unchanged. Uses optimistic concurrency.

ParameterTypeRequiredDescription
flow_idstringYesFlow UUID
step_idstringYesStep ID of the block
modelstringNoModel identifier (e.g. 'anthropic/claude-sonnet-4-6')
configobjectNoBlock config (maxTokens, temperature, etc.)
processor_configobjectNoProcessor-specific config
base_versionintegerNoContent version to check against. Omit to auto-detect.

update_block_input_schema

Replace a block's input schema (full replacement). Uses optimistic concurrency.

ParameterTypeRequiredDescription
flow_idstringYesFlow UUID
step_idstringYesStep ID of the block
contentobjectYesThe new input schema (full replacement)
base_versionintegerNoContent version to check against. Omit to auto-detect.

update_block_output_schema

Replace a block's output schema (full replacement). Uses optimistic concurrency.

ParameterTypeRequiredDescription
flow_idstringYesFlow UUID
step_idstringYesStep ID of the block
contentobjectYesThe new output schema (full replacement)
base_versionintegerNoContent version to check against. Omit to auto-detect.

update_block_notes

Replace a block's notes text (full replacement). Uses optimistic concurrency.

ParameterTypeRequiredDescription
flow_idstringYesFlow UUID
step_idstringYesStep ID of the block
contentstringYesThe new notes text (full replacement)
base_versionintegerNoContent version to check against. Omit to auto-detect.

update_flow_meta

Update a flow's metadata. At least one of name, description, flow_settings, or notes must be provided — omitted fields remain unchanged. Uses optimistic concurrency.

ParameterTypeRequiredDescription
flow_idstringYesFlow UUID
namestringNoNew flow name
descriptionstringNoNew flow description
flow_settingsobjectNoNew flow settings
notesstringNoNew flow notes
base_versionintegerNoMeta version to check against. Omit to auto-detect.

update_flow_global_input

Replace a flow's global input schema (full replacement). Uses optimistic concurrency.

ParameterTypeRequiredDescription
flow_idstringYesFlow UUID
contentobjectYesThe new global input schema (full replacement)
base_versionintegerNoMeta version to check against. Omit to auto-detect.

update_flow_trigger

Replace a flow's trigger configuration (full replacement). Uses optimistic concurrency.

ParameterTypeRequiredDescription
flow_idstringYesFlow UUID
contentobjectYesThe new trigger configuration (full replacement)
base_versionintegerNoMeta version to check against. Omit to auto-detect.

Checkpoint Tools

Save and manage block-level prompt snapshots.

create_checkpoint

Save the current block prompt as a named checkpoint (snapshot). Useful for tracking prompt iterations.

ParameterTypeRequiredDescription
flow_idstringYesFlow UUID
step_idstringYesStep ID of the block
notestringNoOptional note describing this checkpoint

delete_checkpoint

Delete a checkpoint from a block.

ParameterTypeRequiredDescription
flow_idstringYesFlow UUID
step_idstringYesStep ID of the block
checkpoint_idstringYesCheckpoint UUID

Versioning Tools

Publish immutable versions and set production.

publish_version

Publish the current flow state as an immutable version. Freezes the tree structure and all block states.

ParameterTypeRequiredDescription
flow_idstringYesFlow UUID
notestringNoVersion note

set_production_version

Set which published version is the production version used when the flow is invoked via API.

ParameterTypeRequiredDescription
flow_idstringYesFlow UUID
version_idstringYesID of a published version

Object Model Tools

Manage reusable schema types at the project level.

create_object_model

Create a reusable schema type at the project level. Object models define structured data shapes that blocks can reference.

ParameterTypeRequiredDescription
project_idstringYesProject UUID
namestringYesModel name
descriptionstringNoModel description
fieldsarrayYesNon-empty array of field definitions

update_object_model

Update an existing object model's name, description, or fields. At least one field must be provided.

ParameterTypeRequiredDescription
project_idstringYesProject UUID
object_model_idstringYesObject model UUID
namestringNoNew name
descriptionstringNoNew description
fieldsarrayNoNew field definitions

delete_object_model

Delete an object model from the project.

ParameterTypeRequiredDescription
project_idstringYesProject UUID
object_model_idstringYesObject model UUID

Test Case Tools

Create, manage, and execute test cases for flows and blocks.

create_test_case

Create a new test case in a flow. Test cases can be flow-scoped or block-scoped.

ParameterTypeRequiredDescription
project_idstringYesProject UUID
flow_idstringYesFlow UUID
scopestringYes'flow' or 'block'
namestringYesTest case name
block_idstringNoBlock step ID (required when scope is 'block')
input_dataobjectNoTest input data as key-value pairs
sort_orderintegerNoSort position (0-based)

update_test_case

Update a test case's name, input data, or sort order. At least one field must be provided.

ParameterTypeRequiredDescription
project_idstringYesProject UUID
test_case_idstringYesTest case UUID
namestringNoNew name
input_dataobjectNoNew input data
sort_orderintegerNoNew sort position

delete_test_case

Soft-delete a test case.

ParameterTypeRequiredDescription
project_idstringYesProject UUID
test_case_idstringYesTest case UUID

duplicate_test_case

Duplicate a test case. The server mints the new ID and resolves a non-colliding name.

ParameterTypeRequiredDescription
project_idstringYesProject UUID
test_case_idstringYesTest case UUID to duplicate

reorder_test_cases

Reorder test cases within a flow and scope. Pass an ordered list of test case IDs; sort_order is set from list position.

ParameterTypeRequiredDescription
project_idstringYesProject UUID
flow_idstringYesFlow UUID
scopeflow, blockYesScope: 'flow' or 'block'
test_case_idsarrayYesOrdered list of test case UUIDs
block_idstringNoBlock step ID (required when scope is 'block')

run_test_case

Execute a test case and return results. Runs the test against the current draft state of the flow, streaming block-by-block execution internally and returning a summary with per-step outputs, token usage, and pass/fail status. Blocks until the run completes (may take 30-120s for multi-block pipelines).

ParameterTypeRequiredDescription
test_case_idstringYesTest case UUID
input_overrideobjectNoOverride the test case's saved input data for this run

Returns: { runId, status, durationMs, steps: [...], totalPromptTokens, totalCompletionTokens, totalCostUsd, error?, errorAtStep?, pipelineOutput? }

run_all_tests

Run all test cases for a flow and return aggregated results. Lists test cases matching the given flow_id (and optional scope/block_id filters), executes each sequentially, and returns a summary with total/passed/failed counts and per-test results. Individual test failures don't abort the batch.

ParameterTypeRequiredDescription
flow_idstringYesFlow UUID
scopeflow, block, loop, pipelineNoFilter by test case scope (omit to run all scopes)
block_idstringNoBlock step ID — required when scope is 'block' or 'loop'

Returns: { total, passed, failed, results: [{ testCaseId, testCaseName, status, durationMs, steps, ... }] }