Skip to main content
Glama
EdwardHayes91

business-central-mcp

bc_execute_action

Executes named actions or cue-tile drill-downs on open Business Central pages, including row-scoped operations and dialog flows, with an optional staleness guard.

Instructions

Executes either a named action OR a cue-tile drill-down on an open page. Pass action for header / line / system actions (Post, Delete, New, Release). Pass cue for Role Center cue tiles to open the underlying list (e.g. cue: "Sales Quotes" with section: "subpage:Activities" opens the Sales Quotes list). Requires a pageContextId from bc_open_page.

For cue drill-down, also pass section pointing at the subpage that owns the cuegroup. The returned openedPages array contains the targetPageContextId of the newly-opened list page.

For a named action: validates the action is enabled, sends the InvokeAction RPC, applies the resulting events, and returns updatedFields / changedSections / dialogsOpened / openedPages.

Use exactly one of "action" or "cue" -- passing both is an error.

If the action triggers a confirmation dialog or modal page, the response includes a dialogsOpened array with the dialog's formId and details. When requiresDialogResponse is true, you must follow up with bc_respond_dialog to confirm or cancel.

Row-scoped actions (Delete, Edit on a list row) require targeting a specific row. Use rowIndex (0-based) or bookmark to specify which row the action applies to. For Document pages, use section to disambiguate between header and line actions (e.g., "Delete" on header deletes the whole document, "Delete" on "lines" deletes one line).

Pass expectedStateVersion (from a prior bc_read_data or bc_open_page stateVersion field) to guard against acting on drifted state. If the page has been mutated by async events or a sibling operation since that read, the call is immediately rejected with code STALE_CONTEXT before touching BC. Re-read with bc_read_data to get the current stateVersion, then retry. Omit expectedStateVersion to skip the check.

Do NOT use this for writing field values -- use bc_write_data. Do NOT use this to open records from a list -- use bc_navigate with drill_down action instead.

Examples:

  • Drill into a cue tile: { "pageContextId": "rc1", "section": "subpage:Activities", "cue": "Sales Quotes" }

  • Post a sales order: { "pageContextId": "so1", "action": "Post" }

  • Delete a row: { "pageContextId": "list1", "action": "Delete", "bookmark": "..." }

  • Create new record: { "pageContextId": "abc", "action": "New" }

  • Delete a document line: { "pageContextId": "abc", "action": "Delete", "section": "lines", "rowIndex": 2 }

  • Execute with staleness guard: { "pageContextId": "abc", "action": "Post", "expectedStateVersion": 5 }

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
cueNoCue tile name to drill down on (e.g. "Sales Quotes", "Pending Approvals"). Use with section pointing at the subpage that owns the cuegroup. Use action OR cue, not both.
actionNoAction caption name to execute (case-insensitive). Use action OR cue, not both. Must match a visible, enabled action from bc_open_page response.
sectionNoSection context. Required when using cue; optional for action. Examples: "lines", "subpage:Activities".
bookmarkNoStable row identifier for row-scoped actions.
rowIndexNo0-based row position for row-scoped actions.
pageContextIdYesPage context ID returned by bc_open_page.
expectedStateVersionNoOpt-in staleness guard. Pass the stateVersion from a prior bc_read_data or bc_open_page response. If the page state has changed since that read (async events or sibling writes mutated it), the call is rejected immediately with code STALE_CONTEXT before touching BC. Omit to skip the check.
Behavior5/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. It thoroughly explains the execution flow: validates the action, sends the InvokeAction RPC, applies events, and returns updatedFields/changedSections/dialogsOpened/openedPages. It also discloses confirmation dialog behavior, row-scoped action requirements, the staleness guard with expectedStateVersion and STALE_CONTEXT rejection, and that passing both action and cue is an error. This is exemplary transparency for a mutation tool.

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

Conciseness5/5

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

Although lengthy, the description is densely informative and well-structured. It opens with a clear summary, then breaks down each mode, usage constraints, dialog handling, row targeting, staleness guard, exclusions, and ends with six concrete examples. Every sentence adds operational value; no filler or redundancy is present. The bulleted examples at the end are particularly effective for comprehension.

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 tool with two modes, 7 parameters, and complex interactions (dialogs, row targeting, staleness), the description provides comprehensive context. It covers prerequisites (pageContextId from bc_open_page), error conditions (STALE_CONTEXT, passing both action/cue), return values (updatedFields, dialogsOpened, etc.), and exclusions. Even without an output schema, the description sufficiently explains what the agent can expect and how to react (e.g., follow-up with bc_respond_dialog).

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?

Since the schema already describes all 7 parameters with 100% coverage, the baseline is 3. The description adds significant value by explaining when to use action vs cue, how section disambiguates header vs line actions, the meaning of rowIndex/bookmark for row-scoped actions, and the expectedStateVersion staleness mechanism. It also provides concrete examples mapping parameters to realistic calls, which helps the agent understand parameter interactions beyond the schema definitions.

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: 'Executes either a named action OR a cue-tile drill-down on an open page.' It clearly distinguishes two modes of operation and establishes scope (open page from bc_open_page). This differentiates it from sibling tools like bc_write_data and bc_navigate, which are explicitly mentioned as alternatives.

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?

The description provides explicit usage rules: 'Use exactly one of action or cue -- passing both is an error.' It gives clear contextual direction, such as requiring section for cue drill-down and pageContextId from bc_open_page. It also lists when NOT to use the tool: 'Do NOT use this for writing field values -- use bc_write_data. Do NOT use this to open records from a list -- use bc_navigate with drill_down action instead.' This exceeds simple guidance by identifying exact alternatives.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/EdwardHayes91/Business-Central-Mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server