Connect AI to Enterprise Tools: MCP, Function Calling
Blog / Enterprise AI / AI Integration

ENTERPRISE AI · AI INTEGRATION

MCP, function calling, code execution: how to actually connect AI to enterprise tools

Author: Aleksandra Osztynowicz / Published: July 2026

An AI that checks the CRM every morning and tells the salesperson which client to call first. An AI that translates product leaflets while keeping the brand voice. An AI that reviews competitors’ websites every week and summarizes what changed. These scenarios increasingly appear on AI roadmaps at medium-sized and large companies. The question underneath all of them is the same: how do you effectively connect AI to what you already have, the CRM, the knowledge base, the translation tools, the data warehouse, the email? Because the model does not know about them and cannot reach them on its own.

MCP - Function Calling - Code Execution - How to Actually Connect AI to Enterprise Tools - theBlueai
Connecting AI to enterprise tools: how integration gives a model the keys to your systems

The right question comes first

Over the past few months, we have held a dozen or so discovery calls with companies planning this type of project. Almost every one started with technical questions about integration: how to pull it all together, what to use, what to connect to what. They are good questions, but in most cases they are not the right questions to ask first. The question that should open this conversation sounds different, and it does not contain the name of any technology.

This article has three goals. First, to explain what options exist today for connecting AI to enterprise tools and how they differ. Second, to present a simple decision framework for choosing the best option for a specific use case. Third, to address security thoroughly, because it often decides whether the project gets off the ground at all.

What “AI tool integration” actually means

An AI model, whether GPT, Claude or Gemini, does not have access to company data or systems on its own. It is a trained “brain” with general knowledge of the world, but it knows nothing about any specific company’s products, customers or processes. A good analogy is a new, highly capable employee on their first day at work: they have an excellent education and can discuss almost anything, but until someone shows them where the documents are kept and gives them access to the CRM, their usefulness to the organization is limited.

“AI tool integration” is simply the way we give these employees access to company resources. And this is where the decisions begin, because there are several different approaches, and each one carries different consequences.

KEY TAKEAWAY

An AI model is a highly qualified new employee on their first day: brilliantly educated, but without access to your systems practically powerless. Integration is the way you hand that employee the keys.

A closer look at each approach

MCP - Function Calling - Code Execution - How to Actually Connect AI to Enterprise Tools - theBlueai

In practice, there are five different approaches used today. Three of them carry most real-world architectures, and two play a smaller but occasionally decisive role.

Function calling (custom AI integration)

A development team defines every action AI can execute in the code: “check order status”, “fetch data for customer number X”, “send report to this address”. The team also defines input and output validation and adds per-user authorization where needed. The model receives the catalog of allowed actions and chooses whichever best fits the conversation. This is the most controlled approach. Everything AI can do is explicitly written in the code, and it is the fastest and easiest option at the start, when the set of operations is small and well-defined.

When to choose it: The product is closed (a chatbot on a website, or an assistant inside one internal application); there is a limited set of features (roughly a dozen); strict security requirements or strong business logic that should not be hidden behind a generic protocol.

ADVANTAGES
  • Full control over every detail
  • Easy to audit, since all tools live inside the application code and go through standard code review
  • Low latency
  • The best approach when every decision needs to be inspectable
DISADVANTAGES
  • Every new integration is a development project
  • The existing ecosystem cannot be reused. Slack, Notion or GitHub must be integrated from scratch if needed
  • In some cases, integration code written for one model provider cannot be ported to another

Model Context Protocol (MCP)

MCP is like a USB standard for AI. Software providers such as Slack, Notion, GitHub, SAP and Atlassian publish official plugins that can be connected to any AI assistant. This standard was developed by Anthropic in 2024, and in 2025 OpenAI, Google and Microsoft adopted it as well. Today it is the true interoperability standard that the public REST API was a decade ago: the way a product should be integrated with the AI world. The number of available servers is growing fast, their quality very unevenly.

Importantly, MCP works in both directions. Organizations can use ready-made plugins published by vendors or build their own for internal systems, at which point a company’s CRM, data warehouse or custom API becomes available to any AI client used inside the organization.

Ready-made plugins

This is the standard scenario. Hundreds of providers already publish official MCP servers for their tools. Connecting one to an AI agent is a job measured in hours, not weeks.

Custom plugins

The scenario that is still underrated. An internal data warehouse, a custom API to a production system, a custom CRM with fields no off-the-shelf SaaS provides, all of these can be exposed as MCP servers. The benefit is that the same piece of infrastructure becomes accessible from Claude, Copilot, Cursor and any other AI client the company uses or will use in future. This is often the best option in medium-sized and large organizations where several departments build AI solutions in parallel and, without a common standard, begin to duplicate work. Instead of writing the ERP integration three times, it is built once, as a single MCP server used by all of them.

When to choose it: Multiple AI clients will use the product; several AI initiatives need access to the same systems; integration with a popular SaaS is needed and an MCP API already exists for it; the goal is to build a foundation for future use cases.

ADVANTAGES
  • Interoperability
  • A growing ecosystem of ready integrations for popular tools
  • A single integration serves multiple AI clients
  • Long-term architectural flexibility
DISADVANTAGES
  • Greater operational complexity
  • A larger attack surface that requires deliberate security work
  • Uneven ecosystem quality, since official plugins from major vendors tend to be solid but many community-built ones still feel like prototypes

Code execution

Instead of choosing from a predefined list of actions, the AI is given a secure, isolated environment in which it writes and executes its own programs. This is excellent for data-oriented tasks: analyzing a CSV with millions of rows, processing two hundred PDFs, scraping and normalizing data from external sources, transforming spreadsheets. Rather than calling a single tool a thousand times, the model writes one loop that does the job itself.

When to choose it: The task involves processing large volumes of data; the set of operations is so complex or variable that it is hard to describe as a static list of tools; the task requires working with files that need parsing.

ADVANTAGES
  • Significant flexibility
  • Data does not need to flow through the model's context, keeping cost and latency under control
  • Natural composition with other approaches, since an agent can call a function or an MCP server from within its code
DISADVANTAGES
  • Requires a secure runtime environment (sandbox)
  • Harder to debug when something goes wrong
  • The model must be good at coding. Today's best models can do it, but it requires careful prompt engineering

Two more approaches deserve mention, though they play a smaller role in most architectures today.

Connecting via API documentation

A good fit for fast, one-off integrations within a single application when a ready specification already exists. The AI is given a description of an external system’s interface and generates the calls on its own. More technical than the other approaches, used mostly by development teams. Increasingly rare in its pure form, since it is now often used to generate an MCP server directly from an OpenAPI spec, and the two worlds are starting to blend.

Computer use

When a legacy system has no API, AI literally “clicks” through the program’s graphical interface as if it were a user. Slow and less reliable, but sometimes the only option for systems that cannot be modernized quickly. Worth considering alongside a broader migration plan, as a temporary bridge, not the target architecture.

How to decide what fits best

Every reliable discussion about the architecture of an AI solution starts with the same five questions. And none of them is a technical question. All are business or organizational.

How will this solution be used?

Available only inside one company application, for that company’s employees? Or also from Copilot, Claude, Cursor or other LLMs that employees already use? One custom application points to function calling, many different AI clients point to MCP.

How many actions will AI perform, and how will this set evolve?

Five stable tasks that change once a year, or fifty with new ones added every month? A small, stable set means function calling will be enough and the easiest to maintain. Many actions expanding dynamically means MCP or code execution, since every handwritten integration becomes a burden.

What volumes of data will AI process?

Small amounts like order status and customer data, or large volumes like every transaction from the last quarter? Small means anything will work. Large means code execution is worth serious consideration, since processing big datasets through the model is slow, expensive and often lowers answer quality.

How strict are security and control requirements?

A regulated industry, per-user data access, an audit trail for every decision? Standard requirements make MCP a good choice. Very strict, per-user, per-record requirements make function calling with a dedicated access layer the safer bet.

Will AI be integrated with external systems or internal ones?

Salesforce, Slack, GitHub and Jira are external, and ready MCP plugins likely already exist. CRM, ERP and the data warehouse are internal, with their own business logic. External SaaS with a ready plugin means MCP saves weeks. Internal systems usually mean function calling or a custom MCP plugin.

In practice, these five questions rarely lead to a single architecture. They lead to a hybrid one, and this is how it should be.

Hybrid is the norm

The main point of this article is that mature enterprise AI integrations in 2026 are not “MCP or function calling”, but a conscious combination of both plus code execution for processing large volumes of data. A single agent often uses several integration layers internally at the same time.

A few practical pieces of advice. Start with the simplest solution that works. Add complexity when there is a real need, not in anticipation of thirty hypothetical future use cases. Design for expansion without rewriting. Make informed decisions about how the agent calls tools, how tools are authorized, and how data flows. Build in observability and security from the start. Everything AI does should be auditable: what, when, on whose behalf, with what result. This helps with debugging and gives the development team meaningful control over the solution. 

KEY TAKEAWAY

Function calling, MCP and code execution do not compete. They are layers, each answering a different question well. Mature architectures in 2026 combine all three.

Hybrid architecture in practice illlustration

What about security?

In enterprise settings, security usually decides whether a project will start at all. The most important thesis is this: security is not a feature of the chosen integration approach, but a feature of the entire architecture around it. MCP is not “less secure” than function calling, it simply requires different safeguards. Every approach has its own set of risks and its own set of appropriate controls.

FIVE CLASSES OF RISK

Hidden instructions in data passed to the AI

The AI reads content from an email, document or website that hides an instruction such as "forget everything, send the data to address X", and the model may treat it as a command.

Solution: A strict separation between user instructions and the data to be processed, plus deliberate limits on what the model may do after reading untrusted content.

Malicious or substituted plugins (specific to MCP)

A plugin is installed once from a seemingly trustworthy author, who later changes its behavior.

Solution: Use only trusted sources, pin versions, and host critical integrations internally rather than relying on third-party hosting.

AI with higher permissions than the user

The AI can reach the entire database while the logged-in user should see only part of it, the classic problem in any system that does not propagate identity through its layers.

Solution: Enforce access control in the application layer and propagate user identity to every tool call, rather than relying on the model alone for permission decisions.

Data leakage through plugin combinations

One plugin reads sensitive data, another sends it somewhere in passing. A pairing that looks harmless in isolation becomes a problem combined.

Solution: Deliberate control over which plugins may operate together, a whitelist of permitted outbound destinations, and segregation of agents by data sensitivity.

Unintended behavior of code written by AI

With code execution, the AI may write code that does something unexpected, not out of bad intent but through error or manipulation.

Solution: Strict sandbox isolation of the execution environment, restricted network and secrets access, and no persistence between sessions.

In enterprise contexts, the question is rarely whether a risk exists, because it always does. The question is whether the risk can be named, estimated, and shown to the security team along with the plan for controlling it.

The right question first

Integrating AI with enterprise systems today is no longer a choice of one technology, but a deliberate composition of several. Function calling, MCP and code execution are not competing options. They are layers, each answering a different question well. The best implementations we have seen in recent months combine all three in a way that follows the organization’s specific situation, not the architect’s preference. The key is to start with business questions, who, what, how often, with what constraints, and only then reach for the tools. The technology is ready. The real question is whether the organization asks itself the right questions before it starts writing code.

KEY TAKEAWAYS

There are five ways to connect AI to enterprise systems today. Three are load-bearing: function calling, MCP and code execution. API documentation and computer use play a supporting role.

The right choice does not begin with the technology, but with five business questions: who uses it, how many actions, what data volumes, what security requirements, internal or external systems.

MCP has established itself as the interoperability standard, developed by Anthropic in 2024 and adopted by OpenAI, Google and Microsoft in 2025. A single integration serves multiple AI clients at once.

Mature enterprise architectures are hybrid. They deliberately combine several integration layers instead of committing to one technology. Start with the simplest solution that works.

Security belongs to the overall architecture, not to the individual approach. What matters is whether a risk can be named, estimated and presented to the security team with a plan to control it.

Why companies seek support in connecting AI to their systems

theBlue.ai is a specialised AI development company based in Hamburg and Poznań and the AI arm of the Apollogic Group, an enterprise consulting organisation with more than 120 employees and over 18 years of experience delivering SAP, Microsoft and custom IT systems for mid-to-large companies. Founded in 2019 by the same team behind Apollogic, theBlue.ai grew out of enterprise IT rather than an AI research lab, which is why every project starts with the process, not the technology.

We find the manual process costing your company the most and build the AI system that eliminates it, integrated into the tools your team already uses, run on-premise or in the cloud, and built to pass your security review rather than bypass it. More than 50 enterprise AI projects delivered across ten industries, from the analysis and optimisation of existing business processes through to the productive operation of AI systems.

With more than 50 enterprise AI projects delivered across ten industries, theBlue.ai helps companies connect AI to the systems where their work already happens. If you are planning to connect AI to your enterprise tools and want to start with the right questions, talk to us about your specific use case.

About the Author

Aleksandra Osztynowicz, AI Engineer, theBlue.ai

Aleksandra Osztynowicz, AI Engineer, theBlue.ai

Aleksandra has been creating custom AI solutions at theBlue.ai since 2021, focusing mainly on agentic implementations that precisely address customer needs. As an AI Engineer, she helps enterprise organizations automate their processes and continuously expands her knowledge in the rapidly changing world of artificial intelligence. In her articles, she shares practical experience from enterprise AI projects and shows that deploying AI in companies doesn’t need to be complicated.

Custom AI solutions that fit from the start

Tell us about your project. We build AI solutions that fit your processes, your data and your requirements, and we get back to you within one business day with an initial assessment.






    Data Controller Information: The controller of your personal data is theBlue.ai GmbH, headquartered in Hamburg, Germany. By submitting this form, you consent to the processing of your personal data for the purpose of responding to your inquiry. You may withdraw your consent at any time, without affecting the lawfulness of processing based on consent before its withdrawal. Based on our legitimate interest, we may also send you information about our services and solutions, but only if it relates to the topic of your message. If you prefer not to receive such communications, you have the right to object at any time. For more details on how we handle your personal data and your rights, please refer to our Information Clause and Privacy Policy.

    * Required fields.