Skip to content

Commit b6253c8

Browse files
feat(vercel): add Vary: accept so CDN serves markdown to agents
The existing Accept: text/markdown rewrite was being masked by Vercel's CDN caching the first variant (HTML) and serving it for all subsequent requests regardless of Accept header. Advertising Vary: accept lets the CDN cache HTML and markdown as separate entries so agents actually get markdown back.
1 parent 6757ff2 commit b6253c8

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

vercel.json

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,10 @@
77
{
88
"key": "Link",
99
"value": "</llms.txt>; rel=\"describedby\"; type=\"text/plain\", </api-reference/introduction>; rel=\"service-doc\"; type=\"text/html\", </sitemap.xml>; rel=\"sitemap\"; type=\"application/xml\""
10+
},
11+
{
12+
"key": "Vary",
13+
"value": "accept"
1014
}
1115
]
1216
}

0 commit comments

Comments
 (0)