Auto-Generate Next.js 15/16 App Router .well-known/ard.json, SEP-2127 MCP Server Cards & /llms.txt Route Handlers
Auto-generate Next.js 15/16 App Router route.ts handlers for Chrome Lighthouse ard.json v0.91, MCP SEP-2127 Server Cards, AAIF SKILL.md, and <=50KB llms.txt.
Scan Your Website AI-Readiness Inline (0β100)
Enter your domain to inspect live /llms.txt, ACP/UCP & MCP 2026-07-28 blockers right here on this pageβand unlock your compiled 7-file bundle + git apply .patch in 1 click.
embed.js)
β Zero CWV / SEO speed impact
β Works on Shopify, WordPress, Webflow & Next.js
Production Route Metadata (LP27 β SpecPulse AI v3.4.0, Sprint #8)
| Metadata Field | Production Value | |
|---|---|---|
| Canonical Slug | /nextjs-app-router-well-known-ard-json-mcp-server-card | |
SEO Title (59 chars) | `Next.js App Router ard.json, SEP-2127 & llms.txt \ | SpecPulse` |
Meta Description (155 chars) | Auto-generate Next.js 15/16 App Router route.ts handlers for Chrome Lighthouse ard.json v0.91, MCP SEP-2127 Server Cards, AAIF SKILL.md, and <=50KB llms.txt. | |
| Target Keywords | nextjs llms.txt route handler, nextjs .well-known/ard.json, nextjs mcp-server.json SEP-2127 | |
| Release Version | https://specpulse.dev/cli.mjs & specpulse/action@v3.4 (2026-11-18) |
Zero-Boilerplate Next.js 15/16 Quickstart (5 Seconds β Free $0 Sandbox, Pro $29/mo or $290/yr Save 2 Months, Team $99/mo or $990/yr)
Scaffold type-safe Next.js App Router Route Handlers for nextjs .well-known/ard.json, nextjs mcp-server.json SEP-2127, AAIF skills/index.json, and a nextjs llms.txt route handler (<= 50KB) in one 5-second command:
curl -fsSL https://specpulse.dev/api/v1/scan?url=https://yourdomain.com
curl -fsSL https://specpulse.dev/cli.mjs -o specpulse.mjs && node specpulse.mjs ./openapi.json
Direct Self-Serve Activation & Stripe Checkout CTAs:
- Launch Free Browser & CLI Sandbox (
$0/moβ No Login, Runs In-Memory) β Validate your Next.js App Router endpoints against Chrome Lighthouse 13.5+ Agentic Browsing in 5 seconds. - Activate Pro Monthly (
$29/movia Stripe Checkout) or Activate Pro Annual ($290/yrβ$24.17/moeq., 2 Months Free) β Continuous GitHub PR generation wheneverapp/api/**/route.tsor MDX docs change, plus hosted/llms-full.txt. - Activate Team Monthly (
$99/movia Stripe Checkout) or Activate Team Annual ($990/yrβ$82.50/moeq., 2 Months Free) β Turborepo multi-app discovery federation, custom domains, and contract-drift approval gates. - Subscriptions run on Stripe Billing and Stripe Checkout with safe Stripe Subscription Proration on annual upgrades and automated 7-day (
< 5builds) Stripe Refunds.
Why Next.js 15/16 App Router Teams Need External Discovery Beyond AGENTS.md
Next.js 16.3+ bundles framework documentation inside node_modules/next/dist/docs/, manages AGENTS.md, and exposes a local dev-server MCP endpoint at /_next/mcp for coding agents working inside your repository (How Next.js Supports AI Coding Agents). However, external AI agents, IDE auto-configurators, and browser audits interacting with your deployed production domain still require standardized HTTP discovery endpoints β and hand-rolling them in app/ hits four recurring Next.js traps:
- Uncached
GETRoute Handlers & Cache Components Errors: By default, Next.js Route Handlers are not cached unless opted in viaexport const dynamic = 'force-static'or extracted into a'use cache'helper withcacheLife('hours')when Cache Components is enabled (Next.jsroute.jsReference). Readingrequest.headersnaively inside a discovery route aborts build-time prerendering and triggers serverless cold starts on every crawler hit. - Legacy
ai-catalog.json& ARD v0.91 Conformance Warnings: The Chrome Lighthouseard.jsonaudit validates domains against a JavaScript port of the ARD v0.91 conformance suite. Serving deprecated/.well-known/ai-catalog.jsonroutes, emittingapplication/mcp-server+jsoninstead ofapplication/mcp-server-card+json, omitting2β5representativeQueries, or specifying bothurlanddatadrops your Lighthouse Agentic Browsing score from1.0to0.9or0. - Misplaced Primitives in
SEP-2127Server Cards: Teams frequently paste dynamictoolsarrays into static Server Cards. Under MCPSEP-2127: MCP Server Cards (FinalExtensions Track status;Betaextension lifecycle inmodelcontextprotocol/ext-server-card), cards deliberately excludetools,resources, andpromptsprimitives so clients never rely on static files for user-scoped authorization, and reserve<streamable-http-url>/server-cardalongside domain-level.well-knowndiscovery. - Soft-404 HTML Fallbacks &
> 50KB/llms.txtPayloads: Catch-allapp/[...slug]/page.tsxroutes return200 OKHTML shells on missing.well-knownpaths, while unpruned MDX dumps exceed50KBand violate thellms.txtv2 specification.
Before vs. After: Hand-Maintained app/ Files vs. SpecPulse v3.4 Next.js Adapter
| Capability | Hand-Rolled public/ or Custom route.ts Boilerplate | SpecPulse v3.4 (--framework nextjs) |
|---|---|---|
| App Router File Layout | Manual 4β6 nested .well-known folders; prone to page.tsx vs route.ts segment conflicts (Next.js Route Resolution) | Conflict-checked app/.well-known//route.ts + app/llms.txt/route.ts generated in 5s** |
| Prerendering & Caching | Uncached per-request runtime execution or broken 'use cache' placement | Build-prerendered force-static + Cache Components helper compatibility + Cache-Control s-maxage=3600 |
Lighthouse ard.json Score | 0 or 0.9 partial credit due to missing urn:air: URNs or legacy ai-catalog.json (Lighthouse ard.json Docs) | 1.0 Pass (urn:air:<fqdn>, strict XOR(url, data), 3β5 representativeQueries, Link: rel="ard") |
MCP SEP-2127 Server Card | Static tool leaks, missing CORS, or wrong $schema URI (SEP-2127 Spec) | **Primitive-free SEP-2127 card (v1/server-card.schema.json) at /mcp/server-card & /.well-known/mcp-server.json with Access-Control-Allow-Origin: * |
| AAIF Agent Skills | Unindexed Markdown docs burning 14,000+ tokens | app/.well-known/skills/index.json/route.ts (.well-known Skills RFC) + < 5,000-token SKILL.md |
/llms.txt v2 Size & Links | Drifts past 100KB+ on doc updates; missing Markdown link headers | Hard-enforced <= 50KB /llms.txt v2 + rel="describedby" & rel="alternate" headers |
| Security & Slopsquatting | Raw MDX comments & unverified npx strings exposed to agents | OWASP LLM01 prompt-injection sanitizer + package.json allowlist verification + .map scrubbing (GTIG Q4 2026) |
Exact app/ File Tree & Generated TypeScript Route Handlers
Running curl -fsSL https://specpulse.dev/cli.mjs -o specpulse.mjs && node specpulse.mjs ./openapi.json scans your app/api/**/route.ts Web Request handlers, OpenAPI specs, and MDX docs to emit zero-dependency TypeScript Route Handlers:
app/
βββ llms.txt/
β βββ route.ts # <= 50KB llms.txt v2 (text/markdown; charset=utf-8)
βββ mcp/
β βββ server-card/
β βββ route.ts # Recommended SEP-2127 <streamable-http-url>/server-card
βββ .well-known/
βββ ard.json/
β βββ route.ts # Chrome Lighthouse 13.5+ ARD v0.91 manifest (1.0 score)
βββ mcp-server.json/
β βββ route.ts # Domain-level SEP-2127 Server Card mirror + CORS
βββ skills/
βββ index.json/
β βββ route.ts # AAIF progressive-disclosure skill index
βββ [slug]/
βββ SKILL.md/
βββ route.ts # Validated < 500-line YAML-frontmatter SKILL.md
Generated app/.well-known/ard.json/route.ts (Chrome Lighthouse 1.0 Pass)
// Auto-generated by https://specpulse.dev/cli.mjs β Do not edit manually
// Spec: https://developer.chrome.com/docs/lighthouse/agentic-browsing/ard (ARD v0.91)
export const dynamic = "force-static";
const ARD_MANIFEST = {
specVersion: "0.91",
trustManifest: {
identity: "urn:air:app.acme.dev:publisher:acme",
},
entries: [
{
identifier: "urn:air:app.acme.dev:mcp:workspace-api",
displayName: "Acme Workspace Stateless MCP Server",
type: "application/mcp-server-card+json",
url: "https://app.acme.dev/mcp/server-card",
capabilities: ["projects_list", "deployments_get", "billing_usage_read"],
representativeQueries: [
"List active projects and deployment status in Acme Workspace",
"Check current billing cycle token usage for my Acme organization",
"Inspect production webhook health in Acme Workspace",
],
},
{
identifier: "urn:air:app.acme.dev:skill:nextjs-sdk-integration",
displayName: "Acme Next.js SDK Integration Skill",
type: "text/markdown",
url: "https://app.acme.dev/.well-known/skills/nextjs-sdk-integration/SKILL.md",
representativeQueries: [
"Integrate Acme webhook signature verification in Next.js App Router",
"Configure Acme server actions with idempotency keys",
],
},
],
} as const;
export async function GET(): Promise<Response> {
return Response.json(ARD_MANIFEST, {
headers: {
"Content-Type": "application/json; charset=utf-8",
"Cache-Control": "public, max-age=300, s-maxage=3600, stale-while-revalidate=86400",
"Access-Control-Allow-Origin": "*",
"Link": "</llms.txt>; rel=\"describedby\", </.well-known/ard.json>; rel=\"ard\"",
},
});
}
Generated app/.well-known/mcp-server.json/route.ts (SEP-2127 Compliant)
// Auto-generated by https://specpulse.dev/cli.mjs β Mirrors /mcp/server-card
// Spec: https://modelcontextprotocol.io/seps/2127-mcp-server-cards & https://github.com/modelcontextprotocol/ext-server-card
export const dynamic = "force-static";
const MCP_SERVER_CARD = {
$schema: "https://static.modelcontextprotocol.io/schemas/v1/server-card.schema.json",
name: "dev.acme/workspace-mcp",
title: "Acme Workspace Remote MCP Server",
version: "3.4.0",
description: "Stateless MCP 2026-07-28 remote interface for Acme Workspace projects, deployments, and usage telemetry.",
websiteUrl: "https://app.acme.dev/docs",
remotes: [
{
type: "streamable-http",
url: "https://app.acme.dev/mcp",
supportedProtocolVersions: ["2026-07-28", "2025-11-25"],
},
],
} as const;
export async function GET(): Promise<Response> {
return Response.json(MCP_SERVER_CARD, {
headers: {
"Content-Type": "application/mcp-server-card+json; charset=utf-8",
"Cache-Control": "public, max-age=300, s-maxage=3600",
"Access-Control-Allow-Origin": "*",
},
});
}
Copy-Paste GitHub Actions Workflow (specpulse/action@v3.4)
Prevent discovery drift across every Next.js deployment using least-privilege GitHub Actions permissions (contents: read and pull-requests: write only β zero OIDC token exposure):
name: Sync Next.js App Router .well-known & llms.txt Handlers
on:
push:
branches: [main]
paths:
- "app/api/**/*.ts"
- "content/**/*.mdx"
- "package.json"
pull_request:
paths:
- "app/api/**/*.ts"
- "content/**/*.mdx"
permissions:
contents: read
pull-requests: write
jobs:
specpulse-nextjs-sync:
runs-on: ubuntu-latest
steps:
- name: Checkout Next.js Repository
uses: actions/checkout@v4
- name: Setup Node.js 22
uses: actions/setup-node@v4
with:
node-version: "22"
cache: "npm"
- name: Compile Next.js App Router Discovery Handlers (<= 50KB Enforced)
uses: specpulse/action@v3.4
with:
framework: "nextjs"
app_dir: "./app"
fqdn: "app.acme.dev"
max_llms_txt_kb: "50"
emit: "llms-txt,ard-v091,mcp-server-card,aaif-skills"
mode: "auto-pr"
specpulse_api_key: ${{ secrets.SPECPULSE_API_KEY }}
Transparent Search & Extension Lifecycle Notes
Per the Google Search Central AI Optimization Guide, /llms.txt and .well-known agent manifests do not affect Google Search rankings; standard Search Essentials govern web search visibility. Additionally, while MCP SEP-2127 is Final, its ext-server-card schema (https://static.modelcontextprotocol.io/schemas/v1/server-card.schema.json) is in the Beta extension lifecycle stage (eSEOspace SEP-2127 Analysis) β SpecPulse v3.4 tracks upstream schema revisions automatically via CI pull requests so your Next.js routes never go stale.
Pricing & Instant Stripe Checkout
| Plan | Price | Included Capabilities | Direct Activation CTA |
|---|---|---|---|
| Free Sandbox | $0 / mo | Instant Next.js route.ts generator (llms.txt <= 50KB, ard.json v0.91, SEP-2127 card, SKILL.md), Lighthouse Agentic Browsing validator | Run Free Sandbox (/playground) |
| Pro | $29 / mo or $290 / yr (2 months free β $24.17/mo eq.) | Up to 10 Next.js repos with automatic PR sync on app/api or MDX changes, hosted /llms-full.txt, 60-second SEP-2127 & MCP isError: true probes | Checkout Pro Monthly ($29/mo) Β· Checkout Pro Annual ($290/yr) |
| Team | $99 / mo or $990 / yr (2 months free β $82.50/mo eq.) | Turborepo / monorepo federated ard.json, unlimited repos, custom edge domains, breaking tool-contract revalidation gates, team RBAC | Checkout Team Monthly ($99/mo) Β· Checkout Team Annual ($990/yr) |
Structured Data (SoftwareApplication + FAQPage JSON-LD)
Stop Losing AI Search Buyers to Competitors β Go Live in 60 Seconds
No sales demos, zero lock-in, instant 1-click cancellation β’ Save 2 months on Annual plans (Pro $290/yr Β· Agency $2,990/yr)
<script src="https://specpulse.dev/embed.js" data-site="your-domain-com" defer></script>