Skip to main content
Glama
business-central-mcp

business-central-mcp

by SShadowS

bc_wizard_navigate

Destructive

Advances, reverses, finishes, or cancels Business Central NavigatePage wizards step by step, enabling automated multi-step setup forms after opening the modal page.

Instructions

Drive a Business Central NavigatePage / wizard by semantic step. Use after bc_open_page on a page whose response has isModal: true and pageType: "NavigatePage" (Continia activation wizards, BC setup wizards, request pages with multi-step layouts). The action argument is one of: "next" (advance), "back" (return to previous step), "finish" (complete the wizard), "cancel" (abort).

bc-mcp identifies the navigation buttons by the icon resource BC's own client uses (Actions/PreviousRecord, Actions/NextRecord, Actions/Approve), not by SystemAction or caption -- so localised wizards work without changes. The response surfaces fields visible on the new step, the remaining navigation options (availableNav), and a closed flag set when the wizard finished.

Typical workflow: bc_open_page (returns isModal=true, fields for step 0) -> bc_write_data (fill step 0 inputs) -> bc_wizard_navigate { action: "next" } -> bc_write_data (fill step 1) -> ... -> bc_wizard_navigate { action: "finish" }. The wizard closes itself on finish/cancel; the pageContextId becomes invalid afterwards. A step that opens a separate dialog (e.g. "Set up SMTP Account") returns it in dialogsOpened with its own pageContextId: fill it with bc_write_data against that id and answer it with bc_respond_dialog, not through the wizard's pageContextId.

Do NOT use this for non-wizard pages -- use bc_execute_action instead. Do NOT call "next" past the last step -- use "finish" once availableNav lists it.

Example: { "pageContextId": "abc", "action": "next" }

If the action produces a file (Open in Excel, Print, export), its bytes appear in downloads[] (an operationId replay returns the metadata with error code NOT_REPLAYED instead of the bytes); links BC would open externally appear in externalUris[] and are never fetched by the server.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "pageContextId": "<pageContextId>",
      "action": "<action>"
    },
    "name": "bc_wizard_navigate"
  }
}

Input Schema

NameRequiredDescriptionDefault
actionYesWizard step navigation. "next" advances, "back" returns to previous step, "finish" completes the wizard, "cancel" aborts.
operationIdNoOptional idempotency key (e.g. a UUID you generate): a retry with the same key and arguments returns the stored result instead of re-running. See the server instructions.
pageContextIdYesPage context ID returned by bc_open_page for a NavigatePage / wizard.

Output Schema

NameRequiredDescriptionDefault
closedYes
fieldsYes
captionYes
successYes
downloadsYes
replaySafeYes
availableNavYes
externalUrisYes
dialogsOpenedYes
changedSectionsYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed7 schema fields changedv3.0.0
    • changedInput schema / properties / operationId / description
      Previous value: -"Optional idempotency key (e.g. a UUID you generate). Retrying with the same operationId and the same arguments returns the first call's stored result instead of running the change again, so a retry after a dropped connection or timeout cannot double-post. Reusing it with different arguments is rejected (OPERATION_ID_REUSED). If the first call's outcome is unknown, the retry returns OPERATION_IN_DOUBT: check the record's state before acting again under a new operationId. Every result of this tool carries replaySafe: true means BC's response proved that re-running the same call (even under a new operationId, after an unknown outcome) cannot apply the change twice -- the write was echoed as an absolute value, or the form it acted on is closed so BC rejects a re-run; false means a re-run may double-apply or nothing proved otherwise, so read the record back before retrying. Replay is time-limited: a completed entry is kept for BC_OPERATION_TTL (default 24h), after which the same operationId runs the call again; check with bc_get_operation before a late retry. A replayed result carries download metadata (fileName, contentType, sizeBytes, savedPath) but not the file bytes."New value: +"Optional idempotency key (e.g. a UUID you generate): a retry with the same key and arguments returns the stored result instead of re-running. See the server instructions."
    • changedOutput schema / properties / dialogsOpened / items / additionalProperties
      Previous value: -{}New value: +false
    • addedOutput schema / properties / dialogsOpened / items / properties / fields
      Added value: +{
      +  "items": {
      +    "additionalProperties": false,
      +    "properties": {
      +      "editable": {
      +        "type": "boolean"
      +      },
      +      "isLookup": {
      +        "type": "boolean"
      +      },
      +      "lookupCustom": {
      +        "type": "boolean"
      +      },
      +      "name": {
      +        "type": "string"
      +      },
      +      "options": {
      +        "items": {
      +          "additionalProperties": false,
      +          "properties": {
      +            "text": {
      +              "type": "string"
      +            },
      +            "value": {
      +              "type": "string"
      +            }
      +          },
      +          "required": [
      +            "text",
      +            "value"
      +          ],
      +          "type": "object"
      +        },
      +        "type": "array"
      +      },
      +      "selectedOption": {
      +        "additionalProperties": false,
      +        "properties": {
      +          "text": {
      +            "type": "string"
      +          },
      +          "value": {
      +            "type": "string"
      +          }
      +        },
      +        "type": "object"
      +      },
      +      "showMandatory": {
      +        "type": "boolean"
      +      },
      +      "tab": {
      +        "type": "string"
      +      },
      +      "type": {
      +        "type": "string"
      +      },
      +      "value": {
      +        "type": "string"
      +      }
      +    },
      +    "required": [
      +      "name",
      +      "editable",
      +      "type"
      +    ],
      +    "type": "object"
      +  },
      +  "type": "array"
      +}
    • addedOutput schema / properties / dialogsOpened / items / properties / kind
      Added value: +{
      +  "enum": [
      +    "confirm",
      +    "message",
      +    "error",
      +    "requestPage",
      +    "page"
      +  ],
      +  "type": "string"
      +}
    • addedOutput schema / properties / dialogsOpened / items / properties / responses
      Added value: +{
      +  "items": {
      +    "enum": [
      +      "ok",
      +      "cancel",
      +      "yes",
      +      "no",
      +      "abort",
      +      "print",
      +      "preview"
      +    ],
      +    "type": "string"
      +  },
      +  "type": "array"
      +}
    • addedOutput schema / properties / dialogsOpened / items / properties / title
      Added value: +{
      +  "type": "string"
      +}
    • changedOutput schema / properties / dialogsOpened / items / required
      Previous value: -[
      -  "formId",
      -  "pageContextId"
      -]New value: +[
      +  "pageContextId",
      +  "formId",
      +  "kind",
      +  "responses"
      +]
  2. Changed2 schema fields changedv2.4.7
    • addedOutput schema / properties / dialogsOpened / items / properties / pageContextId
      Added value: +{
      +  "type": "string"
      +}
    • changedOutput schema / properties / dialogsOpened / items / required
      Previous value: -[
      -  "formId"
      -]New value: +[
      +  "formId",
      +  "pageContextId"
      +]
  3. Changed2 schema fields changedv2.0.0
    • addedInput schema / properties / operationId
      Added value: +{
      +  "description": "Optional idempotency key (e.g. a UUID you generate). Retrying with the same operationId and the same arguments returns the first call's stored result instead of running the change again, so a retry after a dropped connection or timeout cannot double-post. Reusing it with different arguments is rejected (OPERATION_ID_REUSED). If the first call's outcome is unknown, the retry returns OPERATION_IN_DOUBT: check the record's state before acting again under a new operationId. Every result of this tool carries replaySafe: true means BC's response proved that re-running the same call (even under a new operationId, after an unknown outcome) cannot apply the change twice -- the write was echoed as an absolute value, or the form it acted on is closed so BC rejects a re-run; false means a re-run may double-apply or nothing proved otherwise, so read the record back before retrying. Replay is time-limited: a completed entry is kept for BC_OPERATION_TTL (default 24h), after which the same operationId runs the call again; check with bc_get_operation before a late retry. A replayed result carries download metadata (fileName, contentType, sizeBytes, savedPath) but not the file bytes.",
      +  "maxLength": 200,
      +  "minLength": 1,
      +  "type": "string"
      +}
    • changedOutput schema / (root)
      Previous value: -nullNew value: +{
      +  "$schema": "https://json-schema.org/draft/2020-12/schema",
      +  "additionalProperties": false,
      +  "properties": {
      +    "availableNav": {
      +      "items": {
      +        "type": "string"
      +      },
      +      "type": "array"
      +    },
      +    "caption": {
      +      "type": "string"
      +    },
      +    "changedSections": {
      +      "items": {
      +        "type": "string"
      +      },
      +      "type": "array"
      +    },
      +    "closed": {
      +      "type": "boolean"
      +    },
      +    "dialogsOpened": {
      +      "items": {
      +        "additionalProperties": {},
      +        "properties": {
      +          "formId": {
      +            "type": "string"
      +          },
      +          "message": {
      +            "type": "string"
      +          }
      +        },
      +        "required": [
      +          "formId"
      +        ],
      +        "type": "object"
      +      },
      +      "type": "array"
      +    },
      +    "downloads": {
      +      "items": {
      +        "additionalProperties": {},
      +        "properties": {
      +          "contentType": {
      +            "type": "string"
      +          },
      +          "fileName": {
      +            "type": "string"
      +          },
      +          "savedPath": {
      +            "type": "string"
      +          },
      +          "sizeBytes": {
      +            "type": "number"
      +          },
      +          "style": {
      +            "type": "string"
      +          }
      +        },
      +        "required": [
      +          "fileName",
      +          "contentType",
      +          "sizeBytes",
      +          "style"
      +        ],
      +        "type": "object"
      +      },
      +      "type": "array"
      +    },
      +    "externalUris": {
      +      "items": {
      +        "additionalProperties": false,
      +        "properties": {
      +          "style": {
      +            "type": "string"
      +          },
      +          "uri": {
      +            "type": "string"
      +          }
      +        },
      +        "required": [
      +          "uri",
      +          "style"
      +        ],
      +        "type": "object"
      +      },
      +      "type": "array"
      +    },
      +    "fields": {
      +      "items": {
      +        "additionalProperties": false,
      +        "properties": {
      +          "editable": {
      +            "type": "boolean"
      +          },
      +          "name": {
      +            "type": "string"
      +          },
      +          "value": {
      +            "type": "string"
      +          }
      +        },
      +        "required": [
      +          "name",
      +          "editable"
      +        ],
      +        "type": "object"
      +      },
      +      "type": "array"
      +    },
      +    "replaySafe": {
      +      "type": "boolean"
      +    },
      +    "success": {
      +      "type": "boolean"
      +    }
      +  },
      +  "required": [
      +    "success",
      +    "caption",
      +    "fields",
      +    "availableNav",
      +    "closed",
      +    "changedSections",
      +    "dialogsOpened",
      +    "downloads",
      +    "externalUris",
      +    "replaySafe"
      +  ],
      +  "type": "object"
      +}
  4. First observedv1.5.0

TDQS

A4.8/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Beyond the annotations (destructiveHint true, idempotentHint false), the description discloses the key lifecycle fact that the wizard closes itself on finish/cancel and the pageContextId becomes invalid afterwards, which is essential for a mutation tool. It also explains how buttons are located (icon resources rather than SystemAction/caption, enabling localized wizards), what the response surfaces (fields, availableNav, closed), and how downloads/externalUris and NOT_REPLAYED behave on operationId replay.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Content is front-loaded: scope and precondition first, then action semantics, then workflow, then prohibitions, then example. It is on the long side, and the trailing downloads/externalUris paragraph is somewhat generic to the server rather than specific to wizard navigation, but no sentence is truly redundant.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a three-parameter stateful mutation tool with an output schema, the description supplies everything needed to call it correctly: entry condition, ordering constraints, step-loop workflow, dialog escape hatch, and post-call invalidation of the context id. Return-value shape is described only where it affects the next decision (availableNav, closed, dialogsOpened), which is the right level given an output schema exists.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so the enum values are already documented, but the description adds genuine sequencing semantics: which action is valid at which point ("finish" only once availableNav lists it, "next" not past the last step) and what pageContextId must refer to. It does not add anything beyond the schema for operationId, though that parameter's own description is self-contained.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description opens with a specific verb and resource ("Drive a Business Central NavigatePage / wizard by semantic step") and immediately narrows the scope to pages whose response has isModal: true and pageType "NavigatePage", with concrete examples (Continria activation wizards, BC setup wizards). It also explicitly contrasts with bc_execute_action for non-wizard pages, so the agent can distinguish it from the closest sibling without opening a schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

It states the precondition (call after bc_open_page on a modal NavigatePage), the exact stepwise workflow interleaved with bc_write_data, and two explicit prohibitions: do not use it for non-wizard pages (use bc_execute_action) and do not call "next" past the last step (use "finish" once availableNav lists it). The nested-dialog case is routed to bc_respond_dialog with its own pageContextId, covering the main alternative path.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.