MCP: Model Context ProtocolBeginnerModule 01 — Understanding the need for MCP
When should you use MCP in a software project?
Question 12 of 43 · Updated
On this page
- Direct answer
- 1. Begin with the problem, not the protocol
- 2. Good use cases for MCP
- A. Multiple independently developed AI applications
- B. Integrating with an existing compatible host
- C. Exposing a maintained catalog of business capabilities
- D. Supporting multiple models or agent frameworks
- E. Sharing a capability between automated and model-driven workflows
- 3. When MCP is probably unnecessary
- 4. Compare the architectural alternatives
- 5. A practical architecture-selection decision tree
- 6. Evaluate total cost rather than counting integrations
- 7. Security and operational readiness are decision gates
- 8. Tested example: a small architecture decision policy
- 9. Migrate incrementally instead of rewriting the whole application
- 10. Practical scenarios
- Scenario 1: Student project with one weather API
- Scenario 2: Shared enterprise document search
- Scenario 3: Internal financial operations assistant
- Scenario 4: High-throughput deterministic data pipeline
- Scenario 5: Existing SaaS application adding assistant integration
- 11. Define pilot success before building
- Interview-ready answer
Direct answer#
Use the Model Context Protocol (MCP) when your software needs a reusable, standardized interface to external capabilities that compatible applications can discover and invoke. It is particularly valuable when multiple AI hosts need the same tools or data, when users need to connect an existing MCP-compatible client, or when you want service integrations to evolve independently of the selected model or agent framework.
Do not introduce MCP merely because a project uses AI. If a single application already has a reliable direct API integration, a small fixed set of operations and no interoperability requirement, the direct approach may be simpler. MCP adds a protocol boundary that needs implementation, configuration, security, compatibility testing and operational ownership.
The right choice is based on the application's integration requirements, expected reuse, security constraints, total cost and operational capabilities. Start with the smallest design that satisfies those requirements; adopt MCP where it creates a measurable benefit.
Learning continuity: The preceding lessons explained the integration problem, traditional adapters, scalability, interoperability, external context, architectural boundaries and why an LLM is optional. This final introductory lesson turns those concepts into a project-selection decision. Detailed transport selection, protocol comparisons, framework-specific adapter trade-offs and enterprise architecture appear later in the roadmap.
Verification scope: Prepared under the authorized offline research and changelog exceptions. MCP 2025-06-18 is used as a historical reference baseline, not asserted to be the latest specification. Official references were not opened live. The standard-library decision example was syntax-compiled and executed using Python 3.13.5; all 12 checks passed. It is an illustrative policy, not an empirical prediction or MCP SDK implementation. Two Mermaid diagrams use standard fenced syntax and were structurally reviewed; the local Mermaid package and live website rendering were unavailable.
1. Begin with the problem, not the protocol#
Imagine two software projects.
Project A is a small internal dashboard that reads stock from an existing inventory API. Its backend performs a single fixed lookup and renders a number. The team controls both the application and the API, and no other host needs the same capability.
Project B provides an inventory capability to a developer assistant, a support agent and a warehouse operations application. The teams use different frameworks and want to add other compatible consumers later. The inventory team wants a stable tool contract that does not depend on any particular agent runtime.
For Project A, a direct API call through a well-tested backend adapter may be entirely sufficient. For Project B, an MCP server may provide a useful integration boundary that the different hosts can consume using compatible clients.
Both projects still need correct inventory data, authorization, validation, error handling and observability. MCP changes the way the capability is exposed and consumed; it does not eliminate the need for these controls.
Ask the following before choosing an architecture:
- Who will consume the capability now, and who is realistically expected to consume it later?
- Is there an explicit requirement to support an existing MCP-compatible host?
- Do consumers require discoverable tools, resources or reusable prompts?
- Can the capability be represented by a narrow, stable business contract?
- Can the team support the additional protocol, deployment and security boundary?
- What measurable improvement would justify introducing it?
An integration requirement is stronger evidence than a technology trend.
2. Good use cases for MCP#
A. Multiple independently developed AI applications#
Suppose a company wants its IDE assistant, support assistant and operational assistant to obtain authorized information from the same inventory service. A reusable MCP server can expose the stock operation while each host chooses its own compatible client and model integration.
This is valuable when the teams are genuinely independent, have different release cycles or need different frameworks. If all applications already share a suitable internal SDK, assess whether an MCP boundary provides additional interoperability rather than assuming that all existing reuse is inadequate.
B. Integrating with an existing compatible host#
A software project may need to expose a capability to a particular IDE, desktop assistant or other client that supports MCP. In this case, using MCP can be a functional product requirement even when there is only one initial consumer.
Confirm the actual supported revision, transport, authorization mechanism, capability types and result formats. A host's general claim of MCP support is not sufficient evidence that it supports the specific integration you need.
C. Exposing a maintained catalog of business capabilities#
A platform may provide operations such as searching documentation, reading authorized records or checking shipment status. When those capabilities must be discoverable through a common interface, MCP can be useful.
Design the catalog around meaningful business operations. For example, expose an authorized order-status lookup rather than unrestricted database access. Keep tool descriptions and schemas aligned with the actual implementation, and enforce permissions on the server.
D. Supporting multiple models or agent frameworks#
A team may want to experiment with different models while retaining the same downstream integrations. MCP can isolate some dependencies at the external capability boundary.
The model-facing tool representation, orchestration, prompts and state still require host-specific work. MCP does not make model providers interchangeable in every respect.
E. Sharing a capability between automated and model-driven workflows#
A scheduled reporting job may invoke a read-only capability deterministically, while an AI assistant uses it when answering a user question. Both can potentially consume the same MCP contract.
As explained in Q13, a language model is not required for ordinary protocol operations. A model-free consumer can be useful when it needs interoperability with an existing MCP service. If it is the only consumer and a direct service API already exists, the simpler direct route may be preferable.
3. When MCP is probably unnecessary#
| Situation | Simpler starting point |
|---|---|
| One backend calls one stable API | Direct API client or small adapter |
| Pure in-process calculation | Ordinary function or library |
| Fixed scheduled job with an existing SDK | Conventional task runner and SDK |
| Application only generates text from supplied input | Model API or local inference |
| Existing service integration already satisfies all consumers | Retain the existing contract |
| Very tight latency or resource constraints | Measure a direct implementation first |
| No team can operate or secure a new capability boundary | Resolve ownership and security before exposing it |
These are starting points, not absolute rules. A single consumer may require MCP because it is the interface a chosen host supports. A deterministic workflow may also benefit from a shared MCP server. Conversely, many consumers do not automatically justify MCP if they already share a reliable integration library.
Avoid using MCP as a substitute for designing the business API. A protocol wrapper over an unsafe or unstable service remains unsafe or unstable.
Do not add MCP merely to perform an ordinary model API call. The model provider already supplies its own inference interface. MCP can complement that interface by exposing external capabilities, but is not a necessary intermediary for every model request.
4. Compare the architectural alternatives#
| Approach | Best suited to | Main limitation |
|---|---|---|
| Direct REST or service SDK | Known consumer and stable service | AI-specific integration contract may remain host-specific |
| Shared library | Consumers using compatible runtimes and release practices | Distribution and language/runtime coupling |
| Internal service or gateway | Centralized business integration and policy | Requires service ownership and its own consumer contract |
| Framework-native tools | Applications staying within one agent ecosystem | May require adaptation when changing frameworks |
| MCP server | Reusable capabilities consumed by compatible MCP hosts | Adds protocol, compatibility and operational requirements |
| Hybrid | Existing APIs with selected capabilities exposed through MCP | Two interfaces must preserve consistent business semantics |
These approaches can coexist. A common pattern is to retain the existing inventory API and add an MCP server that exposes a narrow stock lookup. The service remains the authoritative source, and the MCP server adapts its interface for compatible hosts.
A framework-native tool may itself call an MCP client. A shared library may implement business validation used by both direct API adapters and MCP servers. The decision concerns the external contract and consumer requirements, not which technology replaces every other component.
5. A practical architecture-selection decision tree#
The decision tree is an engineering heuristic, not a normative MCP requirement. A required MCP interface may justify a higher integration cost, but security and compatibility requirements must still be satisfied. The direct path also requires its own security, validation and operational controls.
A pilot is not approval to deploy a production connector. It is an opportunity to verify the assumptions using a small, controlled implementation and representative clients.
6. Evaluate total cost rather than counting integrations#
The earlier scalability lesson explained why maintaining repeated adapters can be expensive. When choosing an architecture, estimate the cost over a defined time horizon rather than relying on the number of consumers alone.
For example, suppose a retailer is planning three independently developed AI hosts over six months. The team estimates the following engineering effort in hours:
| Cost category | Direct adapters | MCP-based approach |
|---|---|---|
| Build and integrate | 45 | 30 |
| Contract and compatibility testing | 18 | 12 |
| Maintenance and changes | 21 | 10 |
| Operations and support | 6 | 8 |
| Total estimated hours | 90 | 60 |
The illustrative difference is 30 hours over the chosen period. These estimates are fictional, not measured industry averages or a promise of savings. In particular, the MCP estimate includes host-side integration work, server maintenance and operational support, rather than assuming one server eliminates all host work.
If a second project has one direct adapter requiring six hours to build and maintain, while an MCP integration would require twenty hours, the result may favor the direct approach.
A real cost model should include:
- Existing reusable libraries and compatible SDKs.
- Initial development, migration and training.
- Deployment, service ownership and dependency maintenance.
- Protocol compatibility and client-specific integration tests.
- Authentication, permissions and monitoring.
- Runtime resource usage, latency and incident handling.
- Expected future consumers and uncertainty in adoption.
Avoid comparing a one-time direct adapter estimate with a multi-year MCP estimate, or excluding necessary security work from either architecture. Use the same time horizon and scope. Consider optimistic and pessimistic assumptions, then update them with measured pilot results.
7. Security and operational readiness are decision gates#
A reusable capability can reach more consumers than a narrowly scoped direct integration. That can improve reuse, but may also increase the impact of an exposed credential, vulnerable server or incorrectly authorized operation.
Before exposing a capability, identify the trusted server, required consumer identities, intended data recipients, allowed operations and business resources. For remote deployments, use appropriate transport security and the authorization mechanisms supported by the chosen revision and implementation. For local servers, constrain executable code, process permissions and environment exposure.
Critical questions include:
| Concern | Readiness question |
|---|---|
| Identity | Can the service identify the actual authorized actor? |
| Permissions | Is access checked at operation and resource level? |
| Data disclosure | Can information be limited to approved consumers and destinations? |
| Side effects | Are approvals and duplicate-prevention controls appropriate? |
| Compatibility | Have required client-server combinations actually been tested? |
| Reliability | Are deadlines, recovery paths and service limits defined? |
| Ownership | Is a team responsible for patches, monitoring and incidents? |
If these controls are not ready, introducing MCP does not solve the underlying problem. Restrict the pilot to controlled data and environments, or defer deployment until the missing controls are resolved.
Do not consider a server trusted merely because its tool metadata is well-formed. Review its implementation, configuration and dependencies. A model's proposed operation is not an authorization decision.
8. Tested example: a small architecture decision policy#
The following dependency-free Python example illustrates how an application team might encode a few architecture-review rules. It accepts project assumptions, checks security and compatibility readiness, and recommends a direct integration or MCP pilot under a deliberately narrow policy.
This is not an MCP implementation, automatic security assessment, universal adoption formula or financial model. All inputs are estimates or decisions established by the project team. The number of consumers is a proxy for expected reuse, not proof of a benefit. A production decision should account for non-financial requirements such as standards, procurement, deployment constraints and accessibility.
Save as mcp_q14.py:
PYTHONfrom dataclasses import dataclass, replace @dataclass(frozen=True) class Project: consumers: int external_host_required: bool compatible: bool controls_ready: bool direct_hours: int mcp_hours: int def recommend(p): if (type(p.consumers) is not int or p.consumers < 1 or any(type(x) is not bool for x in (p.external_host_required, p.compatible, p.controls_ready)) or any(type(x) is not int or x < 0 for x in (p.direct_hours, p.mcp_hours))): raise ValueError('Invalid assumptions') if not p.controls_ready: return 'review_security' if not p.compatible: return 'resolve_compatibility' if p.external_host_required else 'direct' if p.external_host_required: return 'pilot_mcp' if p.consumers > 1 and p.mcp_hours < p.direct_hours: return 'pilot_mcp' return 'direct' if __name__ == '__main__': base = Project(3, False, True, True, 90, 60) cases = [ (base, 'pilot_mcp'), (replace(base, consumers=1), 'direct'), (replace(base, mcp_hours=90), 'direct'), (replace(base, mcp_hours=100), 'direct'), (replace(base, consumers=1, external_host_required=True), 'pilot_mcp'), (replace(base, compatible=False), 'direct'), (replace(base, compatible=False, external_host_required=True), 'resolve_compatibility'), (replace(base, controls_ready=False), 'review_security'), (replace(base, controls_ready=False, external_host_required=True), 'review_security'), ] for project, expected in cases: assert recommend(project) == expected for invalid in (replace(base, consumers=0), replace(base, direct_hours=-1), replace(base, mcp_hours=True)): try: recommend(invalid) except ValueError: pass else: raise AssertionError('Invalid assumptions accepted') print('12 architecture-decision checks passed (9 decisions, 3 invalid inputs)')
Run:
BASHpython -m py_compile mcp_q14.py python mcp_q14.py
Actual local output using Python 3.13.5:
12 architecture-decision checks passed (9 decisions, 3 invalid inputs)The nine decision checks cover a favorable multi-consumer pilot, a single consumer, equal or greater estimated MCP cost, a required external host, optional and required incompatible hosts, and missing controls with or without an external-host requirement. Three additional tests reject zero consumers, negative effort and a boolean passed as an hour estimate.
The security gate is intentionally conservative and evaluated before cost. The controls_ready input represents readiness to proceed with the proposed integration review, not independently verified security. A return value of direct is not permission to bypass direct-integration security requirements. An explicit external-host requirement can lead to a pilot even with only one consumer; a project reviewer must still determine whether the required interface is feasible and the cost acceptable.
The local tests establish only the expected behavior of this small decision function. They do not verify a real host, protocol negotiation, authorization policy, performance or the accuracy of the cost assumptions. For real projects, validate these inputs with documented requirements, threat modeling and a representative pilot.
9. Migrate incrementally instead of rewriting the whole application#
A team with working APIs does not need to replace them to introduce MCP. Preserve the authoritative business service and expose selected operations through a compatible server interface.
The diagram shows two paths to the same business service, not two independent authoritative inventory databases. Both paths must enforce the same business rules and appropriate resource authorization. If they implement different contracts intentionally, document the differences rather than assuming all results are interchangeable.
A practical migration can follow this sequence:
- Inventory existing integrations, business contracts and consumers. Identify one capability that provides clear reuse value.
- Start with a narrowly scoped read-only operation using controlled test data.
- Extract or preserve a stable domain adapter. Avoid copying critical business rules into multiple paths.
- Expose the capability through an SDK appropriate to the supported MCP revision and intended host.
- Test discovery, invocation, schema handling, error outcomes and authorization using actual supported client-server combinations.
- Measure the pilot against the existing direct integration. Compare correct business outcomes, effort, latency and operational behavior.
- Expand only when the pilot meets its acceptance criteria. Retain or retire the direct path based on real consumer requirements.
For read-only comparisons, ensure both paths are using comparable data freshness and the same business semantics. Never blindly mirror side-effecting calls to both paths; that could duplicate payments, reservations or other writes. For write migrations, use a controlled routing strategy, authoritative operation identifiers, reconciliation and a rollback plan that accounts for already committed effects.
10. Practical scenarios#
Scenario 1: Student project with one weather API#
The application fetches a forecast and asks a model to summarize it. A direct API call with appropriate validation may be the simplest implementation. If the project is specifically intended to teach MCP or expose the same capability to a compatible assistant, adding an MCP server may be appropriate as a learning or integration objective.
Scenario 2: Shared enterprise document search#
Several teams need authorized search across internal documents from different AI applications. A reusable MCP capability may help standardize discovery and invocation. The search service still owns retrieval quality and access control, while the hosts manage context selection and disclosure. Start with a limited corpus and verify identity-specific results.
Scenario 3: Internal financial operations assistant#
MCP can expose a narrowly scoped read-only balance or reconciliation capability, but the architectural decision for write operations must be governed by approval, authorization, audit, transaction and recovery requirements. The protocol itself is not a safety guarantee. Do not expose sensitive writes until the authoritative controls have been designed and tested.
Scenario 4: High-throughput deterministic data pipeline#
A pipeline already invokes a stable service SDK and meets its throughput targets. If no compatible-host or reuse requirement exists, keeping the direct integration may avoid unnecessary complexity. If the same transformation needs to be available to multiple compatible clients, evaluate a reusable MCP interface separately and measure its actual resource cost.
Scenario 5: Existing SaaS application adding assistant integration#
A SaaS team wants compatible external assistants to read user-approved records. An MCP server may offer a useful new consumer interface over existing authorized business operations. Preserve tenant boundaries, validate credentials for the intended resource and test the target hosts rather than exposing the entire internal API.
11. Define pilot success before building#
A successful demonstration should answer more than whether a client can call a tool. Define acceptance criteria that reflect the business and architectural goal.
| Area | Example measurable criterion |
|---|---|
| Compatibility | Required host versions can discover and invoke the capability |
| Correctness | Known inputs produce correct results and controlled errors |
| Security | Unauthorized tenants and operations are rejected |
| Reuse | A second consumer can integrate without rewriting the underlying business adapter |
| Reliability | Timeouts and unavailable services produce bounded, explicit outcomes |
| Performance | Observed latency and throughput meet agreed service objectives |
| Maintenance | Owners can update, test and roll back the capability safely |
These are example criteria, not mandatory numerical thresholds. Define the relevant measurements before the pilot and use comparable workloads. A successful local fixture is not proof of production readiness.
Document the final decision, assumptions, rejected alternatives and conditions for revisiting it. If the expected additional hosts never appear or the operational burden exceeds the benefit, keeping a direct integration can be the right result.
Interview-ready answer#
I would use MCP when an application needs a reusable, discoverable capability interface across compatible hosts, must support an existing MCP consumer, or benefits from separating external integrations from the selected AI model and framework. I would not automatically use it for every AI application; a direct API, shared SDK or ordinary function may be simpler when consumers and operations are stable. I would evaluate compatibility, security, ownership, performance and total maintenance cost, then pilot one narrow business capability while preserving the existing authoritative service. MCP is an architectural choice for capability access, not a replacement for business APIs, orchestration or security.
Module transition: This concludes the introductory roadmap module on understanding the need for MCP. The next eligible lesson introduces the MCP host and its responsibilities, beginning the architecture module.
References
- 1.MCP documentationmodelcontextprotocol.io
- 2.MCP historical specification (2025-06-18)modelcontextprotocol.io
- 3.MCP toolsmodelcontextprotocol.io
- 4.MCP transportsmodelcontextprotocol.io
- 5.MCP authorizationmodelcontextprotocol.io
- 6.Official MCP Python SDKgithub.com
- 7.OpenAPI Specification 3.1.0spec.openapis.org
- 8.
Related questions
Explore other topics:Forward Deployed EngineeringAI AgentsLarge Language ModelsRetrieval-Augmented Generation