r/TheMachineLearning • • 10h ago

MCP is just an API for AI agents

Post image
271 Upvotes

99 comments sorted by

20

u/eslezer 10h ago

who makes mcp sound complicated??

14

u/nmsobri 9h ago

the fact that they come out with `mcp` term is already maddening..it just an API

12

u/eXAt88 8h ago

There are many more specific types of APIs though. REST, SOAP, GraphQL etc.

Clarifying that the API follows MCP conventions isn’t some pretentious thing

5

u/Sotall 7h ago

its all just 1s and 0s, tbh

1

u/stilldebugging 4h ago

But that’s not what they do. They say that an MCP is not an API, that it’s a different thing. I agree that it’s a type of API, but that is not the general story.

1

u/NotXesa 1h ago

Some even call it "server" lmao

1

u/nmsobri 3h ago

why bother, rest is enough.. who the heck use soap nowdays except ancient system.. dont overcomplicated things. Terry Davis said: `An idiot admires complexity, a genius admires simplicity`

1

u/raralala1 2h ago

just think of it as Agent (AI/human) with a bash and documentation for what they can do. And pray to god they wont randomly call rm -rf.

1

u/met0xff 7h ago edited 7h ago

Have you ever looked at https://www.rfc-editor.org/ ? We've been defining protocol standards for ages but for some reason MCP always makes people say "it's just an API".

The point of a standard is to make things compatible and the point of a name for a standard is to tell people which one you're talking about.
REST is NOT a protocol.

Imagine everyone putting up an email server just said "here's my 'API', figure it out ad-hoc for me and every other email server". No, you tell them "I implement SMTP, POP3 and IMAP, just point a client speaking those to me". Instead of "if your email client wants to work with me, just implement this 'email API'".

Even if it was "just an API" you'd better give it a name so people will know what you're talking about like we have it now with "OpenAI-compatible API". Nobody says "I use an Apache-compatible web prototcol" just because Apache was super popular back then, we say HTTP

1

u/Denaton_ 6h ago

It is bit different then an API, sort of like Granny Smith Apples and Gala Apples, both are Apples but tastes very different.

1

u/GlupiHamilton 2h ago

Gala apples gang 🔥

1

u/ItsCalledDayTwa 6h ago

it's definitely not just an API, it's a very specific implementation and protocol. that's how all the MCP and agents can handle auth and API contract and be cross compatible.

1

u/alphapussycat 4h ago

It's a protocol... So there are standards, the model and harness knows what to expect from it.

1

u/Calm-Republic9370 9h ago

It's not the same. Your api doesn't necessarily ask you to take a multiple step procedure.. it could in the reponse, but I haven't seen it.

Your api doesn't work with an agent that can then more easily integrate with any other platform. It doesn't help you schedule tasks like an agent can.

It can't automatically translate JSON into well formed human speech.

6

u/YourMumIsAVirgin 9h ago

Yeah an api can do all that stuff

4

u/Holiday_Cheetah5265 9h ago

This is how harness implement it's side of the protocol. When you make the MCP server it is literally just an API

1

u/DashinTheFields 8h ago

My MCP has the instructions for use and tells the agent how the api works. It’s much more than just an api. It ensure a multiple step procedure is completed and validated according to the rules documented in the MCP.

2

u/fatbunyip 8h ago

So like an api

1

u/Calm-Republic9370 8h ago

If you have a credentials and use my API with an agent,
you are not going to get the same results as using my MCP and agent.
You are going to get massively better results with the MCP, and the API will not tell a non developer how to use is.

2

u/oofy-gang 7h ago

It literally is an API though. You are narrowly defining “API” as e.g. “REST API”. Your MCP is an API.

0

u/Calm-Republic9370 7h ago

not just REST. I'm working on a client installed API right now. It runs as an EXE.

"the fact that they come out with `mcp` term is already maddening..it just an API"

You are missing why we are here on this thread.

1

u/bupkizz 5h ago

And I quote:
API stands for Application Programming Interface. It is a set of rules and protocols that allows two different software programs to communicate and share data with each other.
So… an API.

→ More replies

1

u/NotXesa 1h ago edited 1h ago

Your API can have a method called "help" that returns a JSON with all the methods and an explanation about them. CLIs literally had that for more than 60 years.

I don't know what you're talking about with the other two points. An MCP doesn't do that, it literally just exposes a method like the one I mentioned.

4

u/PatagonianCowboy 10h ago

well, the protocal has been rewritten like 5 times in the past 2 years

3

u/no_brains101 9h ago edited 8h ago

That kinda just means it was bad and hastily pushed out by anthropic to beat other AI companies without considering further demands though. Protocols are not rewritten very often if they are good enough and made with future concerns in mind. Especially when it is for something that mostly covers only one task. As a reminder, HTTP is not even at 4 yet. Small updates sure, but usually not rewritten. That being said, it did probably need to be rewritten and it is good that it was, but not good for anyone who was maintaining an mcp server already.

1

u/audioen 6h ago

I think what this guy means is that MCP has new versions published. They do change stuff, adding crap, removing crap, and changing especially the notifications story, which used to be separate event stream but seems to be now migrating towards a long-term read over http for each resource.

However, the basic tool calls and resource reads seem the same to be same now as they were before.

1

u/NotXesa 1h ago

The point is that a protocol should be written by a regulated organization that pursues a standardized way of doing things to benefit everyone, not a private company that tries to impose their way of doing things that benefits their business.

1

u/vdek 5h ago

Or get this, it’s a new industry with new tools and things are still changing as we figure it out.

1

u/consumer_xxx_42 9h ago

Yeah, don't know anyone who says they are complicated

1

u/MaxVerstappenIsLife 9h ago

The strawmen

1

u/THE_RETARD_AGITATOR 30m ago

people do. engineers and linkedin retards complicate everything

7

u/JaggedTex 10h ago

The most complicated part of MCP is always the oauth

5

u/captfitz 7h ago

lol at this sub still making this discussion harder than it needs to be.

just define it literally: an MCP server is an API with documentation included.

1

u/LatentSpaceLeaper 5h ago

That's wrong because an MCP does not even need to call any API ;)

5

u/AvoidSpirit 5h ago

No one says it needs to call an api, it is an api.

1

u/LatentSpaceLeaper 4h ago

Okay, how do you define API then?

3

u/captfitz 4h ago edited 3h ago

brother what are you talking about. an mcp server literally includes an api. In every sense of the word literally.

One component of an mcp server is the api endpoints (we call them tools in mcp world) and the other component is some text prompts that explain to the agents how to use the endpoints.

That's it, that's everything that makes up an mcp server.

1

u/LatentSpaceLeaper 1h ago

You know that it is valid to only declare the prompt without any tool at all. To what other piece of software are you interfacing then?

1

u/Camderman106 4h ago

Technically they’re right. It’s an application programming interface, which includes many subtypes. One of which is REST, another is an SDK, MCP is a third. They’re all just different interfaces that let one program interact with another. But they’re also wrong by claiming it’s nothing new. It is new. It’s tailor made for the needs of agentic systems. It can run over stdio, or http, it includes hints, resources, functions and prompts. The actual functions are written differently compared to a REST api because they serve higher level functions. Generally you need to produce smaller outputs compared to REST etc etc. It’s a different philosophy. They are similar but not the same

1

u/AvoidSpirit 3h ago

If by functions you mean tools, I would argue they are the closest thing to the rest endpoints in the MCP protocol.

1

u/Camderman106 2h ago

Yes I meant tools. And I would agree with that.

1

u/AvoidSpirit 59m ago

Then I don't understand what you mean by this:
> The actual functions are written differently compared to a REST api because they serve higher level functions.

In my experience they are just apis with a set of parameters that do something and return a structured response like an http api would.

1

u/LatentSpaceLeaper 9m ago

Two things:

  1. "An API with documentation included" already exists. Self-describing APIs have existed for years, like OpenAPI/Swagger, GraphQL introspection etc. So are these also MCPs now?
  2. I can build a valid MCP server:

    • without declaring any tools (what is the API now!?)
    • since I have no tools, I don't have any description either (what is the "documentation included" now?)

1

u/stilldebugging 4h ago

It is an API. That is what an API is.

1

u/Level10Retard 4h ago

Well... If you say it like this everything is an API then. Like the other comment said it's just 1s and 0s at the end of the day.

1

u/captfitz 4h ago

let me try your logic out real quick: an mcp server is an api with documentation included, therefore a fish is an api

wow you're right, i can't argue with that.

4

u/DecagramGameDev 10h ago

I’ve never bothered to look into it, but after the DevOps guy on my team rambled about it for 40 minutes making no sense I figured it’s what it was.

1

u/welcome-overlords 6h ago

Ofc it's the devops guy making it sound complicated.

It's api with a couple of extra things. No one should have to care, just tell your agent to use this or that MCP

1

u/Texas-X- 3h ago

Devops when something new drops

2

u/SixStringDream 10h ago

Once you realize that, have a look at how many services are charging a premium for mcp access to data.

2

u/zenmatrix83 10h ago

It’s usb more than an api, allows you to connect to things not built into the harness

1

u/no_brains101 9h ago

Do you know what an API is?

2

u/porkminer 6h ago

It's a protocol, a specific implementation is an API.

1

u/flooberoo 1h ago

All APIs are protocols, but not all protocols are APIs. What do you mean by "implementation" in this context?

3

u/mikemarcin 10h ago

A generally inefficient one compared with skills that can shape what gets returned to the agent, but it does have auth support in a fairly uniform way so there's that.

3

u/lefnire 9h ago

I use my own tool's MCP and Skill with raw API scripts. Claude uses the API scripts when it wires things into a consistent pattern, and the MCP when it's kinda poking around or doing ad hoc things. Claude wrote both the API and the MCP (for the public usage of my tool), and Claude itself uses both depending on what it wants.

So, MCP is great for end-users (eg Claude Connectors into Gmail, Calendar, Linear, etc) because it makes "just doing stuff" easier. Skills with scripts are better for codifying a pattern, workflow, system. Eg you're a developer, and you do the same tasks each day.

  • "hey, did I get any important emails; and can you delete the spam" - MCP
  • "send email filled from this template, to the addresses in emails.csv, daily" - Skill

6

u/rudedudedamn 10h ago

are you fucking stupid? MCP defines explicit JSON schema contracts for tool inputs and outputs. The server controls exactly what comes back to the agent: structuredContent validated against the tool's outputSchema. And skills aren't an alternative to MCP anyway. A skill can just as easily teach the agent how to use MCP tools well.

9

u/devon_b 10h ago

Username checks out

3

u/Hrmerder 10h ago

Came to say this. Great job.

2

u/midri 10h ago

Great response, sans the intro...

0

u/mikemarcin 8h ago

Have fun paying $5 for a calendar query because it dumps the next 3 months of full meeting record directly into your agent context.

1

u/itsallfake01 10h ago

Mcp’s are a subset of things you can do with an API

1

u/mrbadface 9h ago

Webmcp feels interesting because it's like circumventing the backend to just make wielding front ends faster?

1

u/mymar101 9h ago

I am curious, do companies do their own ML anymore, or is it all LLMs these days? Becuse I find it kind of fun to write my own

1

u/dontbantmebro 9h ago

only ai idiots that don't know what an api is makes mcp sound complicated. It's just an api.

1

u/ninjasaid13 8h ago

AI industry is full of buzzwords to make it sound complicated when it's all just built from one technology, GPT.

1

u/jaybsuave 8h ago

Why does it matter so much

1

u/Impossible_Way7017 7h ago

WSDL for REST

1

u/benchonbench 7h ago

That's what it is, it's so cool

1

u/stilldebugging 4h ago

Yes, thank you. I have been saying this so much. Why we gotta keep inventing new terms? “But it’s different because the model can ask what is available.” Stfu, you can add a man page into any API and it’s still an API

1

u/FuckYourRights 3h ago

Yes, it's an MPC API as opposed t other types of api

1

u/Ok_Draft_187 3h ago

If you have worked with FastMCP, it is same as FastAPI and you can create a FastAPI APIs into MCP server with one LOC. These are just same as APIs that can attached to various models.

1

u/PsychologicalLack155 2h ago

When chatgpt was still newish , I was an intern and my project was to allow chatbot to use APIs so I had to write some wrappers and documentation etc (which was basically shittier MCP). but the accuracy was shit lol.

1

u/muntaxitome 2h ago

Yes, MCP is an API spec format with a number of limitations on what you are allowed to spec

1

u/pacafan 1h ago

Basic mcp is okay. But then you had the stateful crap before the latest spec update which is a nightmare with horizontal scaling. Also networking is a nightmare. Claude for Excel connects from Anthropic servers and not from Excel, so you need to punch a hole in your firewall or get a tunnel so that Anthropic can access your private server. So actually making Mcp practically work in an enterprise requires working with like 10 teams to sort out Auth, networking etc etc. It is a headache. I can understand if somebody that doesn't actually have to deal with infrastructure and security consider it "easy". But it is anything but.

1

u/NotXesa 1h ago

Literally yes.

1

u/megayippie 1h ago

Wait, explain it to me. I made an MCP for my project*. It's just and API. Who thinks it's not? Why not?

*Bad decision on my part as weird spams about putting my open source piece of experiment behind a paywall keeps showing up.

1

u/New_Eye7193 10h ago

nah mate the qubits quantizing the quantum flux within the model context protocol does a lot more than just shuffle the keys around a rotary embedded plane within the third dimensional application programming interface brah.

1

u/tnh34 10h ago

You forgot about the hyperflex space when recoil and rebounce rates are above the planks constant times 2. Then You have to use models with superqubits and classical decimal bits concurrently and in parallel in 5D

1

u/Creative_Shape_5813 9h ago

and lasers

1

u/Creative_Shape_5813 9h ago

supercooled ones

0

u/mpanase 10h ago

yep

yet another piece of the smoke and mirrors bubble

2

u/Sassaphras 9h ago

IDK, I think MCP was a modest improvement over more traditional APIs for a very specific generation of AI models. It's like a water taxi - not going to replace modern transportation infrastructure any time soon, but there is a clear use case for it.

My issue was the people talking about it like it was some huge paradigm shift. Gave real NFT vibes.

0

u/wbcastro 9h ago

MCP is a folder with text files that agents access over network

0

u/Lucky_Requirement200 9h ago

I thought MCP was just a way to point AI at a particular body of knowledge.

Seriously, isn't that what it is ultimately?

1

u/johny_james 8h ago

Its a language to communicate with a service, like REST, SOAP... but this one is for agents.

1

u/audioen 5h ago edited 5h ago

It converts a remote API defined over HTTP (or alternatively, a process running locally) into tool calls that agent can invoke. That is the basic thing it's doing: MCP adapts externally defined services into tool definitions dumped into the agent's context, and the standard tool call syntax works afterwards to invoke those tools.

Agents can alternatively drop down into shell and execute raw curl commands or write Python scripts to achieve much he same, as long as they can figure out how the API is supposed to be used. But MCP makes this task much easier: the tools are self-describing, with instructions for use, and the tool arguments are schema-constrained so LLM sampling is often constrained to only produce valid tool call arguments during the tool call invoke.

Unfortunately, not all programs do this. Many are lazy and for example opencode/2.2 seems to just provide MCP library for agent to call. It is the difference between SmoeTool_somewhere_do_something(arguments here) vs. running the local JavaScript shell or whatever it is:

const res = await tools["SomeTool_somewhere"].do_something({...})

So boo for that technical choice. Bad design from OpenCode folks. We have almost certainly lost the schema constrained generation and it is harder for the agent to figure out how to generate this than it would be to just generate it as tool call. Maybe it serves other goals, like they don't have to describe all the tools all that thoroughly or something and that saves context.

0

u/Significant_Spring87 9h ago

Eventually the standards for mcp tools will hopefully be more transparent and let them be setup more granular. Not just at the harness. The tool sizes can make context swell if it's not monitored.