A robot developer reviews REST, POST-only, and RPC API options for a warehouse inventory system.
If you maintain an enterprise backend that routes every write operation through POST, or one littered with verb-heavy endpoints like /updateBin and /deleteBin, chances are someone has already warned you that AI coding agents will choke on it. On paper, the argument sounds airtight: REST encodes intent cleanly into HTTP verbs like PATCH and DELETE, while non-REST and RPC-style interfaces force a language model to decipher arbitrary endpoint names. Yet according to new empirical testing published by Microsoft on November 23, 2026, that conventional wisdom collapses the moment an agent has access to documentation.

In a benchmark spanning 1,356 runs across six models from two AI vendors, Principal Developer Advocate Waldek Mastykarz tested REST, POST-only, and RPC-style APIs side by side. When the agents could read an API description or reference page, all three architectural styles tied in both reliability and token cost. Only when documentation was withheld did REST pull ahead—not because models understand REST semantics better, but because standard REST URLs are far easier to guess blindly.

A robot developer reviews REST, POST-only, and RPC API options for a warehouse inventory system. Isolating Verbs from Paths with One Mocked API​

To avoid testing against public APIs that models had already memorized during pretraining, Microsoft built a synthetic inventory service called Binstock, which manages warehouse bins and stored items. Rather than spinning up three separate backend servers, the evaluation mocked all three API shapes from a single codebase using Dev Proxy and its CrudApiPlugin. As documented on Microsoft Learn, CrudApiPlugin simulates dynamic CRUD backends using an in-memory JSON data store and configurable action mappings, returning 404 responses for undefined method-and-path pairs while logging every request.

Crucially, the experiment introduced a middle tier—POST-only—specifically to separate two variables that "non-REST" debates routinely lump together: HTTP method usage versus URL naming conventions.

OperationREST StylePOST-only StyleRPC Style
Read a binGET /bins/{code}GET /bins/{code}GET /getBin?code=…
Create a binPOST /binsPOST /binsPOST /createBin
Replace a binPUT /bins/{code}POST /bins/{code}/replacePOST /replaceBin
Partial updatePATCH /bins/{code}POST /bins/{code}/updatePOST /updateBin
Delete a binDELETE /bins/{code}POST /bins/{code}/deletePOST /deleteBin

Comparing REST against POST-only isolated the impact of dropping PUT, PATCH, and DELETE in favor of POST. Comparing POST-only against RPC isolated the effect of shifting from resource-oriented paths (like /bins/B-103) to action-named endpoints (like /updateBin?code=B-103).

The test suite ran inside Vally, Microsoft's open-source local evaluation engine—the same underlying framework recently integrated into the public preview of GitHub Copilot Evals—using the GitHub Copilot SDK as the agent harness. (Notably, Microsoft announced just days earlier at Ignite 2026 that the GitHub Copilot SDK is transitioning into the cross-platform Microsoft Copilot SDK 2.0 runtime.) Agents tackled 15 outcome-driven tasks (five reads and ten writes), phrased without leaking endpoint names—such as "Bin B-103 has been taken out of service"—including a deliberate trap requiring a single-field update where using a full replace would overwrite existing data.

Section takeaway: By pairing Dev Proxy's CrudApiPlugin with outcome-based state grading in Vally, Microsoft separated HTTP-method quirks from endpoint-naming quirks before measuring model performance.

With Documentation, Non-REST Styles Performed Just Like REST​

In the primary documented benchmark, models received the API's base URL alongside an OpenAPI specification. Notably, the OpenAPI document listed available operations without spelling out the semantic difference between a partial update and a full replace, forcing agents to deduce the right choice on their own. Four flagship models—Claude Opus 5.5, Claude Sonnet 5.5, GPT-6.1 Sol, and GPT-6.1 Terra—ran each of the 15 tasks five times per API style, totaling 900 runs.

API StyleTask Success RateRuns With Zero Failed CallsAverage Tokens per Run
REST100%82%~70,000
POST-only100%82%~70,000
RPC99.7%77%~71,000

The lone failure across all 900 documented runs was a single 10-minute timeout on the RPC interface. While RPC showed roughly five percentage points fewer zero-error runs and consumed about 700 more tokens per run (roughly 1%) than REST, Microsoft reported that those differences were statistically insignificant and fell well inside its pre-registered equivalence threshold (a 95% confidence interval within 10 percentage points).

To ensure frontier reasoning models weren't simply brute-forcing an awkward interface, Microsoft repeated the documented test with two smaller, faster models—Claude Haiku 5.5 and MAI Code 2 Flash—running each task twice per style (180 runs). Both smaller models achieved 100% completion across REST, POST-only, and RPC, with token consumption varying by only about 3% across styles.

Section takeaway: Across both flagship and lightweight coding models, non-REST conventions imposed virtually zero reliability or token penalty once an OpenAPI spec was in context.

Without Documentation, Guessing Favors REST by Design​

Most production workflows expose some form of documentation, making the OpenAPI test the baseline reality. Still, what happens when an agent only receives a base URL? To find out, Microsoft tested Claude Sonnet 5.5 and GPT-6.1 Terra without any API docs across 180 runs (two runs per task per style).

The results diverged dramatically:

  • REST: Claude Sonnet 5.5 succeeded on 93% of tasks, and GPT-6.1 Terra hit 97%. Even then, agents averaged roughly 10 failed calls per task, using HTTP 404 responses as sonar to refine conventional URL guesses.
  • POST-only: Success dropped to 40% for Claude Sonnet 5.5 and 60% for GPT-6.1 Terra. Because reads shared REST paths, agents solved read tasks easily, then stalled on /update and /delete write routes—burning 48% to 56% more tokens than REST overall, and around 230,000 tokens per correct result versus ~80,000 for REST.
  • RPC: Both models scored 0%. Neither model ever guessed an endpoint such as /updateBin, averaging around 28 failed HTTP calls before abandoning the task.

That failure mode highlights a blind spot in how teams evaluate AI integrations. Handing an agent documentation measures API usage; omitting documentation measures API discovery. Because REST paths follow widespread conventions baked into LLM training weights, unguided discovery naturally rewards REST and punishes bespoke RPC schemas.

Section takeaway: Agents did not fail RPC because they struggled to use action endpoints—they failed because no model can guess arbitrary verb paths without a map.

Inside a Realistic Node.js Project, All Styles Still Tied​

Short, isolated API benchmarks can flatter models compared to real engineering sessions where API calls sit buried inside broader debugging work. To test a more realistic workflow, Microsoft built a small Node.js repository featuring a handover.md task file, a failing unit test caused by an off-by-one getMonth() JavaScript bug, two to four inventory floor events to apply, and a daily report to generate. Instead of pasting an OpenAPI spec directly into the prompt, the project's README linked to the API base URL and an HTML prose reference page modeled after Dev Proxy's own documentation.

Running eight handover scenarios twice per style with Claude Sonnet 5.5 and GPT-6.1 Terra (96 runs total), every single run across REST, POST-only, and RPC succeeded. Every agent located the prose reference link in the README and executed the updates accurately. Token consumption stayed within 3% across all three styles—dominated by code editing and report writing rather than API calls—and zero-error run rates (84% REST, 72% POST-only, 81% RPC) showed no statistically significant gap.

What This Means for API Teams and Agent Experience (AX)​

This API study fits into a wider pattern in Microsoft's recent Agent Experience (AX) research. Earlier in July 2026, Mastykarz tested whether CLI tools need to be rewritten to accept --json payloads instead of traditional flags, finding that flat CLI arguments actually beat JSON in both correctness and cost. Likewise, his November 2026 evaluations of Semantic Versioning and agent execution trajectories showed that subtle environmental cues—like patch-level version labels or missing documentation links—trip up coding agents far more often than syntactic quirks.

Before declaring RPC immune to every agent failure, though, IT architects and developer-tools teams should note the study's explicit boundaries:

  • Small API surface: Binstock exposed only five operations. An enterprise RPC gateway with 100 endpoints—especially near-collisions like updateBin and updateBinItems—could still trigger selection errors.
  • Missing production friction: Authentication headers, OAuth flows, pagination, and multi-dozen-call dependency chains were not part of the Binstock test.
  • Single harness and confounded variables: All 1,356 runs executed via the GitHub Copilot SDK inside Vally, and the handover experiment changed task scope and documentation format (OpenAPI to HTML prose) simultaneously.

For Windows, Azure, and enterprise development teams maintaining legacy SOAP/RPC gateways or POST-heavy internal services, the practical takeaway is clear: skip the expensive REST rewrite if your only motivation is AI compatibility. Instead, invest that engineering budget into discoverable documentation:

  1. Link specs at the front door: Reference your OpenAPI definition or prose API guide prominently inside repository README files and developer portals.
  2. Audit agent trajectories: Inspect logs for repeated 404 probes—even REST APIs triggered ~10 blind guesses per task when docs were missing—to spot where agents expect endpoints to live.
  3. Explore self-describing responses: While still untested in Microsoft's follow-up queue, returning a list of supported operations at the API root URL or inside 404 error bodies could give documentation-starved agents a clean fallback path without changing a single production endpoint.

Final takeaway: AI coding agents don't choke on non-REST APIs; they choke on missing directions—making clear, easy-to-find documentation far more valuable than rewriting working backend architectures.

 

References

  1. Do AI coding agents struggle with non-REST APIs? Microsoft Developer Blogs 2026-11-23T10:25:28+00:00
  2. microsoft.com developer.microsoft.com
  3. github.com github.com