---
id: object/codeunit/8351
type: object
title: Codeunit 8351 "MCP Config Implementation"
summary: Codeunit 8351 "MCP Config Implementation" in System Application (System.MCP). 75 public procedures. Introduced in BC27, still in BC30, changed in BC28-30.
tier: official
language: en
tags:
  - codeunit
  - system application
versions:
  introduced: "27"
  last_changed: "30"
  deprecated: null
review:
  state: derived
  by: null
  at: null
  flags: []
generated:
  at: "2026-10-11T00:31:51.816Z"
  pipeline: 0.2.0
  prompts: {}
  input_hash: 7ca83c955f1c03c9bbda4ce3c1fcf5490964c8471fdfcf9ff2f6328ef36a678f
evidence:
  - kind: code
    url: https://github.com/microsoft/BCApps/blob/ea08af5ef2d6a9b5c5af4a029288abbe2c883220/src/System%20Application/App/MCP/src/Configuration/Codeunits/MCPConfigImplementation.Codeunit.al
    title: src/System Application/App/MCP/src/Configuration/Codeunits/MCPConfigImplementation.Codeunit.al (releases/29.x)
    date: null
    commit: ea08af5ef2d6a9b5c5af4a029288abbe2c883220
    t: null
    quote: null
links:
  learn: []
  objects: []
  features: []
  topics: []
  localizations: []
  videos: []
  posts: []
  guidelines: []
  changes:
    - change/bcapps/12207
    - change/bcapps/10008
    - change/bcapps/8085
object_type: codeunit
object_id: 8351
name: MCP Config Implementation
namespace: System.MCP
app: System Application
extends: null
first_version: "27"
last_version: "30"
present_in:
  - "27"
  - "28"
  - "29"
  - "30"
changed_in:
  - "28"
  - "29"
  - "30"
source_major: "29"
obsolete: null
countries: []
ms_search_form_ids: []
counts:
  fields: 0
  procedures: 101
  events: 0
  subscribers: 0
relations:
  out: 0
  referenced_by: 0
  pages: 0
  extended_by: 0
  event_subscribers: 0
  calls: 10
  called_by: 11
  implements: 0
---

# Codeunit 8351 "MCP Config Implementation"

> Codeunit 8351 "MCP Config Implementation" in System Application (System.MCP). 75 public procedures. Introduced in BC27, still in BC30, changed in BC28-30.

System Application · System.MCP · BC27-30 · [source at ea08af5e](https://github.com/microsoft/BCApps/blob/ea08af5ef2d6a9b5c5af4a029288abbe2c883220/src/System%20Application/App/MCP/src/Configuration/Codeunits/MCPConfigImplementation.Codeunit.al) · facts from BC29

## Properties

| Property | Value |
|---|---|
| Access | Internal |

## Procedures

- `GetConfigurationIdByName(Name: Text[100]): Guid` (internal)
- `CreateConfiguration(Name: Text[100]; Description: Text[250]): Guid` (internal)
- `ActivateConfiguration(ConfigId: Guid; Active: Boolean)` (internal)
- `AllowCreateUpdateDeleteTools(ConfigId: Guid; Allow: Boolean)` (internal)
- `DisableCreateUpdateDeleteToolsInConfig(ConfigId: Guid)` (internal)
- `DeleteConfiguration(ConfigId: Guid)` (internal)
- `CopyConfiguration(SourceConfigId: Guid)` (internal)
- `CopyConfiguration(SourceConfigId: Guid; NewName: Text[100]; NewDescription: Text[250]): Guid` (internal)
- `EnableDynamicToolMode(ConfigId: Guid; Enable: Boolean)` (internal)
- `EnableDiscoverReadOnlyObjects(ConfigId: Guid; Enable: Boolean)` (internal)
- `EnableAPITools(ConfigId: Guid; Enable: Boolean)` (internal)
- `EnableDataQueryTools(ConfigId: Guid; Enable: Boolean)` (internal)
- `IsAPIToolsEnabled(ConfigId: Guid): Boolean` (internal)
- `IsDataQueryToolsEnabled(ConfigId: Guid): Boolean` (internal)
- `CreateDefaultConfiguration()` (internal)
- `IsDefaultConfiguration(MCPConfiguration: Record "MCP Configuration"): Boolean` (internal)
- `IsDesignatedDefaultConfiguration(MCPConfiguration: Record "MCP Configuration"): Boolean` (internal)
- `SetAsDefaultConfiguration(ConfigId: Guid)` (internal)
- `ClearDefaultConfiguration()` (internal)
- `IsConfigurationActive(ConfigId: Guid): Boolean` (internal)
- `ValidateConfiguration(var MCPConfiguration: Record "MCP Configuration"; OnActivate: Boolean)` (internal)
- `FindWarningsForConfiguration(ConfigId: Guid; var MCPConfigurationWarning: Record "MCP Config Warning"): Boolean` (internal)
- `GetWarningMessage(MCPConfigWarning: Record "MCP Config Warning"): Text` (internal)
- `GetRecommendedAction(MCPConfigWarning: Record "MCP Config Warning"): Text` (internal)
- `ApplyRecommendedActions(var MCPConfigWarning: Record "MCP Config Warning")` (internal)
- `ApplyRecommendedAction(var MCPConfigWarning: Record "MCP Config Warning")` (internal)
- `CreateAPIPageTool(ConfigId: Guid; APIPageId: Integer; ValidateAPIPublisher: Boolean): Guid` (internal)
- `GetAPIToolId(ConfigId: Guid; ObjectId: Integer; ObjectType: Option): Guid` (internal)
- `CreateAPIQueryTool(ConfigId: Guid; QueryAPIId: Integer): Guid` (internal)
- `CreateAPICodeunitTool(ConfigId: Guid; CodeunitAPIId: Integer): Guid` (internal)
- `DeleteTool(ToolId: Guid)` (internal)
- `AllowRead(ToolId: Guid; Allow: Boolean)` (internal)
- `AllowCreate(ToolId: Guid; Allow: Boolean)` (internal)
- `AllowModify(ToolId: Guid; Allow: Boolean)` (internal)
- `AllowDelete(ToolId: Guid; Allow: Boolean)` (internal)
- `AllowActions(ToolId: Guid; Allow: Boolean)` (internal)
- `LookupAPIObjects(var SelectedObjects: Record "MCP API Object Buffer"; ObjectType: Option; TypeFilter: Boolean): Boolean` (internal)
- `GetAPIPublishers(var MCPAPIPublisherGroup: Record "MCP API Publisher Group")` (internal)
- `LookupAPIPublisher(var MCPAPIPublisherGroup: Record "MCP API Publisher Group"; var APIPublisher: Text; var APIGroup: Text)` (internal)
- `LookupAPIGroup(var MCPAPIPublisherGroup: Record "MCP API Publisher Group"; APIPublisher: Text; var APIGroup: Text)` (internal)
- `ResolvePublisherForGroup(var MCPAPIPublisherGroup: Record "MCP API Publisher Group"; var APIPublisher: Text; APIGroupValue: Text)` (internal)
- `ValidateAPIPageTool(PageId: Integer; ValidateAPIPublisher: Boolean)` (internal)
- `ValidateAPIQueryTool(QueryId: Integer)` (internal)
- `ValidateAPICodeunitTool(CodeunitId: Integer)` (internal)
- `AddToolsByAPIGroup(ConfigId: Guid)` (internal)
- `AddStandardAPITools(ConfigId: Guid)` (internal)
- `CheckAPIToolExists(ConfigId: Guid; ObjectId: Integer; ObjectType: Option): Boolean` (internal)
- `GetObjectCaption(ToolId: Guid): Text[100]` (internal)
- `ValidateAPIPageVersion(ObjectId: Integer; APIVersion: Text)` (internal)
- `ValidateAPIQueryVersion(ObjectId: Integer; APIVersion: Text)` (internal)
- `ValidateAPICodeunitVersion(ObjectId: Integer; APIVersion: Text)` (internal)
- `LookupAPIPageVersions(PageId: Integer; var APIVersion: Text[30])` (internal)
- `LookupAPIQueryVersions(QueryId: Integer; var APIVersion: Text[30])` (internal)
- `LookupAPICodeunitVersions(CodeunitId: Integer; var APIVersion: Text[30])` (internal)
- `GetHighestAPIPageVersion(PageId: Integer): Text[30]` (internal)
- `GetHighestAPIQueryVersion(QueryId: Integer): Text[30]` (internal)
- `GetHighestAPICodeunitVersion(CodeunitId: Integer): Text[30]` (internal)
- `IsAPIPage(PageId: Integer): Boolean` (internal)
- `CreateVSCodeEntraApplication()` (internal)
- `ShowConnectionString(ConfigurationName: Text[100])` (internal)
- `GenerateConnectionString(ConfigurationName: Text[100]): Text` (internal)
- `EncodeForMCPHeaderIfNonAscii(Value: Text): Text` (internal)
- `CreateEntraApplication(Name: Text[100]; Description: Text[250]; ClientId: Guid)` (internal)
- `DeleteEntraApplication(Name: Text[100])` (internal)
- `ExportConfigurationToFile(ConfigId: Guid; ConfigName: Text[100])` (internal)
- `ImportConfigurationFromFile()` (internal)
- `ExportConfiguration(ConfigId: Guid; var OutStream: OutStream)` (internal)
- `ImportConfiguration(var InStream: InStream; NewName: Text[100]; NewDescription: Text[250]): Guid` (internal)
- `TriggerNoActiveConfigsFeedback()` (internal)
- `TriggerGeneralFeedback()` (internal)
- `HasNoActiveConfigurations(): Boolean` (internal)
- `GetTelemetryCategory(): Text[50]` (internal)
- `LogConfigurationCreated(MCPConfiguration: Record "MCP Configuration")` (internal)
- `LogConfigurationModified(MCPConfiguration: Record "MCP Configuration"; xMCPConfiguration: Record "MCP Configuration")` (internal)
- `LogConfigurationDeleted(MCPConfiguration: Record "MCP Configuration")` (internal)

Plus 26 local procedures.

## Calls

From the extracted call graph of BC29 (graphify-al on the snapshot checkout): calls whose target is known from a declared type or an `Object::"Name"` argument. Interface dispatch and calls through events are not counted, so the list is not complete.

- [Codeunit 4100 "Temp Blob"](../codeunit/4100.md) (4 calls: `ExportConfigurationToFile → CreateInStream`, `ExportConfigurationToFile → CreateOutStream`, `ImportConfigurationFromFile → CreateInStream`, …)
- [Codeunit 1590 "Microsoft User Feedback"](../codeunit/1590.md) (3 calls: `TriggerGeneralFeedback → RequestFeedback`, `TriggerNoActiveConfigsFeedback → RequestDislikeFeedback`, `TriggerNoActiveConfigsFeedback → WithCustomQuestion`)
- [Page 8356 "MCP API Publisher Lookup"](../page/8356.md) (3 calls: `LookupAPIGroup → (object)`, `LookupAPIPublisher → (object)`, `ResolvePublisherForGroup → (object)`)
- [Codeunit 457 "Environment Information"](../codeunit/457.md) (2 calls: `GenerateConnectionString → GetEnvironmentName`, `GenerateConnectionString → IsSaaS`)
- [Codeunit 3060 "Uri"](../codeunit/3060.md) (1 call: `IsTIEEnvironment → AreURIsHaveSameHost`)
- [Codeunit 3960 "Regex"](../codeunit/3960.md) (1 call: `EncodeForMCPHeaderIfNonAscii → IsMatch`)
- [Codeunit 4110 "Base64 Convert"](../codeunit/4110.md) (1 call: `EncodeForMCPHeaderIfNonAscii → ToBase64`)
- [Codeunit 433 "Azure AD Tenant"](../codeunit/433.md) (1 call: `GenerateConnectionString → GetAadTenantId`)
- [Page 8359 "MCP Config Warning List"](../page/8359.md) (1 call: `ValidateConfiguration → (object)`)
- [Page 8366 "MCP API Version Lookup"](../page/8366.md) (1 call: `LookupAPIObjectVersions → (object)`)

## Called by

- [Codeunit 8350 "MCP Config"](../codeunit/8350.md) (28 calls: `ActivateConfiguration → ActivateConfiguration`, `AllowActions → AllowActions`, `AllowCreate → AllowCreate`, …)
- [Page 8351 "MCP Config Card"](../page/8351.md) (4 calls: `OnAfterGetRecord → IsDefaultConfiguration`, `OnDeleteRecord → LogConfigurationDeleted`, `OnInsertRecord → LogConfigurationCreated`, …)
- [Codeunit 8354 "MCP Config Missing Parent"](../codeunit/8354.md) (3 calls: `ApplyRecommendedAction → CheckAPIToolExists`, `ApplyRecommendedAction → CreateAPIPageTool`, `CheckForWarnings → IsAPIPage`)
- [Page 8350 "MCP Config List"](../page/8350.md) (3 calls: `OnOpenPage → HasNoActiveConfigurations`, `OnQueryClosePage → HasNoActiveConfigurations`, `OnQueryClosePage → TriggerNoActiveConfigsFeedback`)
- [Page 8352 "MCP Config Tool List"](../page/8352.md) (3 calls: `AddAPIObjects → CheckAPIToolExists`, `AddAPIObjects → LookupAPIObjects`, `OnOpenPage → IsConfigurationActive`)
- [Codeunit 8352 "MCP Install"](../codeunit/8352.md) (2 calls: `OnInstallAppPerDatabase → CreateDefaultConfiguration`, `OnInstallAppPerDatabase → CreateVSCodeEntraApplication`)
- [Codeunit 8356 "MCP Upgrade"](../codeunit/8356.md) (2 calls: `UpgradeMCPAPIToolVersion → GetHighestAPIPageVersion`, `UpgradeMCPAPIToolVersion → IsAPIPage`)
- [Codeunit 8368 "MCP Data Query Tools Feature"](../codeunit/8368.md) (2 calls: `IsActive → IsDataQueryToolsEnabled`, `SetActive → EnableDataQueryTools`)
- [Codeunit 8369 "MCP API Tools Feature"](../codeunit/8369.md) (2 calls: `IsActive → IsAPIToolsEnabled`, `SetActive → EnableAPITools`)
- [Codeunit 8370 "MCP Dyn. Tool Mode Feature"](../codeunit/8370.md) (1 call: `SetActive → EnableDynamicToolMode`)
- [Page 8369 "MCP Server Feature Settings"](../page/8369.md) (1 call: `SaveChanges → EnableDiscoverReadOnlyObjects`)

## Recent changes

- 2026-10-07 [#12207 [MCP] Prepare Data Query Tools for billing](../../changes/bcapps/12207.md) (main, BC30, feature)
- 2026-08-20 [#10008 [MCP] Add codeunit APIs as MCP tools in MCP configuration](../../changes/bcapps/10008.md) (main, BC30, feature)
- 2026-07-27 [#8085 [MCP] Server Features in MCP configuration: API Tools, Dynamic Tool Mode, Data Query Tools (Preview)](../../changes/bcapps/8085.md) (main, BC30, feature)

## Across versions

- Present in: BC27-30
- Changed (declaration) in: BC28-30

Source: AL metadata extracted from the code (names, ids, signatures, properties); no code bodies (D10).

## Ask your agent

Procedure bodies are not stored here (D10). The call sections above are our own, per object, from the BC29 call graph. For a procedure body or the calls of one procedure, ask bc-code-atlas (external, by Stefan Maron, MIT; default corpus w1-28), which the bc-observatory plugin connects: `bcatlas_resolve_node(object_type: "codeunit", object_name: "MCP Config Implementation")`, then `bcatlas_get_procedure_body` or `bcatlas_get_neighbors` on the returned id.
