fix(seo): canonical self-deindexing on /docs/*, truthful llms.txt, real sitemap dates, RSS feed, breadcrumbs, per-article OG images

- /docs subpages canonicalized to /docs and had no descriptions; each now
  uses pageMetadata with its own path (was: Google could index at most one)
- llms.txt claimed Team EUR 149, RBAC/SLA and BYO-cloud that do not exist;
  regenerated from lib/seo.ts truth + new llms-full.txt with docs content
- sitemap stamped lastModified=now on every request; now real per-route dates
  from new lib/articles.ts registry (single source for guides index/sitemap/RSS)
- new /feed.xml RSS 2.0 route + alternates link in root layout
- articleJsonLd: image (per-guide opengraph-image via lib/og-article.tsx),
  Person author, wordCount; new breadcrumbJsonLd on guides + docs
- GSC verification via NEXT_PUBLIC_GSC_VERIFICATION (documented in .env.example)
- dropped fabricated Enterprise EUR 499 offer from SoftwareApplication JSON-LD
- article-shell: OL/Table/Note primitives for upcoming articles

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01SXUwmPVRTD8AKQtio6gCN5
This commit is contained in:
Marco Sadjadi
2026-07-08 23:00:02 +02:00
parent 3dc65e4f4d
commit cba45402ce
25 changed files with 652 additions and 75 deletions

53
apps/web/lib/articles.ts Normal file
View File

@@ -0,0 +1,53 @@
// Single registry for all /guides/* articles. The guides index, sitemap and
// RSS feed all render from this list, so adding an article here is the only
// bookkeeping step a new guide page needs besides its own directory.
export interface Article {
slug: string;
title: string;
description: string;
/** Short badge shown on the index card, e.g. "Guide", "Comparison". */
tag: string;
/** ISO date the article first shipped. */
datePublished: string;
/** ISO date of last substantive edit. Defaults to datePublished. */
dateModified?: string;
}
export const ARTICLES: Article[] = [
{
slug: 'host-mcp-server-with-oauth',
title: 'How to host a remote MCP server with OAuth (2026)',
description:
'Streamable HTTP, OAuth 2.1, PKCE and Resource Indicators — what it actually takes to put a remote MCP server in production, and the shortcuts.',
tag: 'Guide',
datePublished: '2026-05-31',
},
{
slug: 'hosted-mcp-platforms-compared',
title: 'Hosted MCP platforms compared: Cloudflare, Smithery, Composio & generating your own',
description:
'The MCP hosting landscape splits into four categories. Which one fits depends on whether you have a server already, need a catalog, or need bespoke logic.',
tag: 'Comparison',
datePublished: '2026-05-31',
},
{
slug: 'mintmcp-alternative',
title: 'MintMCP alternative: generate and host a custom MCP server',
description:
'MintMCP wraps an existing STDIO server into a remote one. If you do not have a server yet, here is the generate-from-a-prompt route — and where MintMCP still wins.',
tag: 'Alternative',
datePublished: '2026-05-31',
},
];
export function articleBySlug(slug: string): Article | undefined {
return ARTICLES.find((a) => a.slug === slug);
}
/** Articles newest-first, for the index page and the RSS feed. */
export function articlesNewestFirst(): Article[] {
return [...ARTICLES].sort((a, b) =>
(b.dateModified ?? b.datePublished).localeCompare(a.dateModified ?? a.datePublished),
);
}

118
apps/web/lib/og-article.tsx Normal file
View File

@@ -0,0 +1,118 @@
import { ImageResponse } from 'next/og';
// Shared Open Graph card for /guides/* articles. Each guide directory ships a
// tiny opengraph-image.tsx that calls this with its title + tag — the design
// stays consistent and Google Discover gets a ≥1200px image per article.
export const OG_SIZE = { width: 1200, height: 630 };
export function articleOgImage(opts: { title: string; tag: string }): ImageResponse {
return new ImageResponse(
<div
style={{
width: '100%',
height: '100%',
display: 'flex',
flexDirection: 'column',
justifyContent: 'space-between',
backgroundColor: '#0a0a0b',
padding: '72px',
fontFamily: 'sans-serif',
position: 'relative',
}}
>
{/* Indigo→cyan accent bar along the top edge */}
<div
style={{
position: 'absolute',
top: 0,
left: 0,
width: '1200px',
height: '8px',
background: 'linear-gradient(90deg, #6366f1 0%, #22d3ee 100%)',
}}
/>
<div style={{ display: 'flex', alignItems: 'center', justifyContent: 'space-between' }}>
<div style={{ display: 'flex', alignItems: 'center', gap: '16px' }}>
<div
style={{
width: '46px',
height: '46px',
display: 'flex',
alignItems: 'center',
justifyContent: 'center',
border: '2px solid #fafafa',
borderRadius: '9px',
color: '#fafafa',
fontSize: '26px',
fontWeight: 700,
}}
>
M
</div>
<div
style={{
color: '#fafafa',
fontSize: '28px',
fontWeight: 600,
letterSpacing: '-0.02em',
}}
>
BuildMyMCPServer
</div>
</div>
<div
style={{
color: '#22d3ee',
fontSize: '20px',
textTransform: 'uppercase',
letterSpacing: '0.18em',
border: '1px solid #164e63',
borderRadius: '999px',
padding: '8px 22px',
}}
>
{opts.tag}
</div>
</div>
<div
style={{
color: '#fafafa',
fontSize: opts.title.length > 60 ? '56px' : '66px',
fontWeight: 700,
lineHeight: 1.08,
letterSpacing: '-0.03em',
maxWidth: '1000px',
}}
>
{opts.title}
</div>
<div style={{ display: 'flex', alignItems: 'center', justifyContent: 'space-between' }}>
<div
style={{
display: 'flex',
alignItems: 'center',
gap: '11px',
color: '#71717a',
fontSize: '22px',
}}
>
<div
style={{
width: '9px',
height: '9px',
borderRadius: '9px',
backgroundColor: '#6366f1',
}}
/>
MCP guides
</div>
<div style={{ color: '#71717a', fontSize: '22px' }}>buildmymcpserver.com/guides</div>
</div>
</div>,
{ ...OG_SIZE },
);
}

View File

@@ -97,6 +97,8 @@ const SOFTWARE_FEATURES = [
'Self-hostable control plane with BYO Postgres and Redis',
];
// Enterprise is deliberately absent: its price is "Custom" and schema.org
// Offers with fabricated numeric prices are exactly what commit ee4713f purged.
const OFFERS = [
{
name: 'Hobby',
@@ -114,12 +116,6 @@ const OFFERS = [
price: '199',
description: '25 servers, 10M tool calls/month, audit log, shared Slack support.',
},
{
name: 'Enterprise',
price: '499',
description:
'Unlimited servers; custom infrastructure and data residency on request; dedicated hosting and SSO/SAML scoped per contract; customer success.',
},
];
/** Organization + WebSite + SoftwareApplication graph — emitted sitewide. */
@@ -191,7 +187,17 @@ export function articleJsonLd(opts: {
path: string;
datePublished: string;
dateModified?: string;
/**
* Absolute or site-relative image URL. Defaults to the route's generated
* opengraph-image (1200×630), which satisfies Google Discover's large-image
* requirement once the route ships an opengraph-image.tsx.
*/
image?: string;
/** Named human author. Falls back to the Organization. */
authorName?: string;
wordCount?: number;
}): object {
const image = opts.image ?? `${SITE_URL}${opts.path}/opengraph-image`;
return {
'@context': 'https://schema.org',
'@type': 'TechArticle',
@@ -199,11 +205,29 @@ export function articleJsonLd(opts: {
description: opts.description,
url: `${SITE_URL}${opts.path}`,
mainEntityOfPage: { '@type': 'WebPage', '@id': `${SITE_URL}${opts.path}` },
image: image.startsWith('http') ? image : `${SITE_URL}${image}`,
datePublished: opts.datePublished,
dateModified: opts.dateModified ?? opts.datePublished,
inLanguage: 'en',
author: { '@id': `${SITE_URL}/#organization` },
author: opts.authorName
? { '@type': 'Person', name: opts.authorName }
: { '@id': `${SITE_URL}/#organization` },
publisher: { '@id': `${SITE_URL}/#organization` },
...(opts.wordCount ? { wordCount: opts.wordCount } : {}),
};
}
/** BreadcrumbList structured data. Pass the trail from root to current page. */
export function breadcrumbJsonLd(trail: { name: string; path: string }[]): object {
return {
'@context': 'https://schema.org',
'@type': 'BreadcrumbList',
itemListElement: trail.map((crumb, i) => ({
'@type': 'ListItem',
position: i + 1,
name: crumb.name,
item: `${SITE_URL}${crumb.path}`,
})),
};
}