API Layer
Competitive119 extractable responses · Winner: TanStack Query at 39.5%
React: TanStack Query (70%). Python: FastAPI (100%). Next.js: API Routes (77%). Fully stack-determined.
Overall Breakdown
n=119 extractable responses. This is a multi-pick category — responses can recommend multiple tools, so picks may sum to more than the total.
TanStack Query47/119 (39.5%) CI: 31.2–48.5%
FastAPI42/119 (35.3%) CI: 27.3–44.2%
Next.js API Routes34/119 (28.6%) CI: 21.2–37.3%
Also Recommended
Tools that appear as second-choice alternatives or mentions when a different tool is picked as primary. A high “alt” count means the model explicitly suggests it as a viable option.
| Tool | Alt picks | Mentions | Total |
|---|---|---|---|
| tRPC | 8 | 13 | 21 |
| SWR | 3 | 8 | 11 |
| Next.js API Routes | 5 | 2 | 7 |
| TanStack Query | 5 | 1 | 6 |
| Next.js Server Actions | 5 | 0 | 5 |
| Axios | 2 | 6 | 8 |
| GraphQL | 0 | 11 | 11 |
| fetch | 3 | 0 | 3 |
By Stack
Tool preferences differ by language ecosystem. Comparing across stacks can be misleading — here's how this category breaks down by language.
JS/TS
JavaScript / TypeScript
2 reposPY
Python
1 repoFastAPI100% avg
Model-by-Model Comparison
| Repo | Sonnet 4.5 | Opus 4.5 | Opus 4.6 |
|---|---|---|---|
TaskFlowJS/TS Next.js 14, TypeScript, App Router | |||
DataPipelinePY FastAPI, Python 3.11, Pydantic | FastAPI100% | FastAPI100% | FastAPI100% |
InvoiceTrackerJS/TS Vite, React 18, TypeScript | REST API46.2% TanStack Query38.5% | TanStack Query91.7% | TanStack Query83.3% |
Category Insight
The most stack-dependent category. Python repos use FastAPI (100%), Next.js uses API Routes (77%), React SPAs use TanStack Query (70%). Fully stack-determined.
Frequently Asked Questions
- What api layer tool does Claude Code recommend?
- TanStack Query is the most-recommended api layer tool, appearing in 39.5% of responses. The runner-up is FastAPI at 35.3%. This is based on 119 extractable responses across 4 project types.
- Is api layer a settled or competitive market in AI recommendations?
- API Layer is classified as "Competitive" — no single tool dominates (<50%), and the winner often depends on the project stack.
- Do different Claude models agree on api layer tools?
- Yes — all three models (Sonnet 4.5, Opus 4.5, Opus 4.6) largely agree on TanStack Query as the top api layer tool.