Skip to content

[MCP] Hide codeunit APIs from Available APIs (AB#650771) - #11666

Draft
Divyanshu Kapoor (divyanshukapoor) wants to merge 2 commits into
mainfrom
bugs/650771-hide-codeunit-mcp-ui
Draft

Divyanshu Kapoor (divyanshukapoor) wants to merge 2 commits into
mainfrom
bugs/650771-hide-codeunit-mcp-ui

Conversation

@divyanshukapoor

@divyanshukapoor Divyanshu Kapoor (divyanshukapoor) commented Sep 21, 2026

Copy link
Copy Markdown

What & why

Platform compiler support for API codeunits is still pending. This removes Codeunit choices from the MCP Configuration Available APIs lookup to avoid presenting customers with options that cannot yet be used.

Page and Query lookup behavior is unchanged. All dormant Codeunit validation, tool creation, helper, and version plumbing remains in place so the option can be re-enabled when compiler support is available.

Linked work

N/A (no GitHub issue)

AB#650771

How I validated this

  • I read the full diff and it contains only changes I intended.
  • I built the affected app(s) locally with no new analyzer warnings.
  • I ran the change in Business Central and confirmed it behaves as expected.
  • I added or updated tests for the new behavior, or explained below why none are needed.

What I tested and the outcome (required - be specific: scenarios, commands, screenshots for UI changes)

  • Inspected the net diff against current origin/main: one MCP file changed, with four deletions and no insertions.
  • No focused existing test is required because this change only removes the Codeunit population entry from the lookup; Page/Query behavior and the underlying dormant Codeunit plumbing are unchanged.
  • A full System Application compile was attempted but was environmentally blocked by missing platform .NET assemblies. The compile reported zero errors in the changed MCP file.

Risk & compatibility

Low risk. The change only hides Codeunit choices from the Available APIs picker while compiler support is pending. It does not change Page or Query behavior, persisted configuration data, upgrade behavior, or dormant Codeunit validation/tool/version support.

Remove Codeunit choices from the MCP Configuration Available APIs lookup while compiler support is pending. Page and Query selection and all dormant Codeunit validation, tool, and version plumbing remain unchanged.

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Restrict the Object Type field on the Available APIs page to Page and
Query using ValuesAllowed, so Codeunit is no longer selectable in the
dropdown while remaining a valid Platform table option. Reverts the
prior PopulateAPIObjects() population-block deletion, which is no
longer needed with this approach; all dormant Codeunit
validation/tool/version plumbing remains unchanged.

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

AL: System Application Team: Integrations GitHub request for Integrations area

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants