Repository navigation
marketing: add crawl and entity signals for t3.codes #30902
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Closed
+241
−6
Closed
Changes from all commits
Commits
Show all changes
4 commits
Select commit
Hold shift + click to select a range
8540c03
marketing: add crawl and entity signals for t3.codes
8baabdb
marketing: correct official channels in entity signals
b053d14
marketing: use security@t3.codes and drop the X profile from sameAs
489d325
marketing: use security@t3.codes on the security policy and drop X fr…
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,5 @@ | ||
| Contact: mailto:security@t3.codes | ||
| Policy: https://t3.codes/security-policy | ||
| Canonical: https://t3.codes/.well-known/security.txt | ||
| Preferred-Languages: en | ||
| Expires: 2027-11-01T00:00:00.000Z | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,80 @@ | ||
| import { ANDROID_PLAY_STORE_URL, GITHUB_REPOSITORY_URL, IOS_APP_STORE_URL } from "./site"; | ||
|
|
||
| export const SITE_ORIGIN = "https://t3.codes"; | ||
| export const SITE_NAME = "T3 Code"; | ||
| export const SITE_TAGLINE = "The open-source control plane for coding agents"; | ||
|
|
||
| // The canonical set of official properties. Search engines and AI answer engines read `sameAs` | ||
| // to tie an entity to its real homes, which is the signal a look-alike domain cannot copy. | ||
| export const OFFICIAL_PROFILES = [ | ||
| GITHUB_REPOSITORY_URL, | ||
| IOS_APP_STORE_URL, | ||
| ANDROID_PLAY_STORE_URL, | ||
| "https://discord.gg/jn4EGJjrvv", | ||
| ] as const; | ||
|
|
||
| export type JsonLd = Record<string, unknown>; | ||
|
|
||
| const ORGANIZATION_ID = `${SITE_ORIGIN}/#organization`; | ||
| const WEBSITE_ID = `${SITE_ORIGIN}/#website`; | ||
| const SOFTWARE_ID = `${SITE_ORIGIN}/#software`; | ||
|
|
||
| export const absoluteUrl = (pathname: string): string => new URL(pathname, SITE_ORIGIN).href; | ||
|
|
||
| export const organizationJsonLd = (): JsonLd => ({ | ||
| "@type": "Organization", | ||
| "@id": ORGANIZATION_ID, | ||
| name: "T3 Tools Inc", | ||
| url: SITE_ORIGIN, | ||
| logo: absoluteUrl("/apple-touch-icon.png"), | ||
| sameAs: ["https://github.com/pingdotgg"], | ||
| }); | ||
|
|
||
| export const websiteJsonLd = (): JsonLd => ({ | ||
| "@type": "WebSite", | ||
| "@id": WEBSITE_ID, | ||
| name: SITE_NAME, | ||
| url: SITE_ORIGIN, | ||
| publisher: { "@id": ORGANIZATION_ID }, | ||
| }); | ||
|
|
||
| export const softwareJsonLd = (): JsonLd => ({ | ||
| "@type": "SoftwareApplication", | ||
| "@id": SOFTWARE_ID, | ||
| name: SITE_NAME, | ||
| description: `${SITE_NAME}. ${SITE_TAGLINE}.`, | ||
| url: SITE_ORIGIN, | ||
| downloadUrl: absoluteUrl("/download"), | ||
| applicationCategory: "DeveloperApplication", | ||
| operatingSystem: "macOS, Windows, Linux, iOS, Android", | ||
| license: "https://opensource.org/license/mit", | ||
| isAccessibleForFree: true, | ||
| offers: { "@type": "Offer", price: "0", priceCurrency: "USD" }, | ||
| codeRepository: GITHUB_REPOSITORY_URL, | ||
| publisher: { "@id": ORGANIZATION_ID }, | ||
| sameAs: [...OFFICIAL_PROFILES], | ||
| }); | ||
|
|
||
| export const breadcrumbJsonLd = (items: ReadonlyArray<{ name: string; path: string }>): JsonLd => ({ | ||
| "@type": "BreadcrumbList", | ||
| itemListElement: items.map((item, index) => ({ | ||
| "@type": "ListItem", | ||
| position: index + 1, | ||
| name: item.name, | ||
| item: absoluteUrl(item.path), | ||
| })), | ||
| }); | ||
|
|
||
| export const jsonLdGraph = (nodes: ReadonlyArray<JsonLd>): string => | ||
| // `<` is escaped so page text inside the graph can never close the script tag. | ||
| JSON.stringify({ "@context": "https://schema.org", "@graph": nodes }).replace(/</g, "\\u003c"); | ||
|
|
||
| // Indexable static pages. The 404 (noindex) and the /95 easter egg stay out of the sitemap. | ||
| export const STATIC_PAGES = [ | ||
| { path: "/", priority: "1.0" }, | ||
| { path: "/download", priority: "0.9" }, | ||
| { path: "/legal", priority: "0.3" }, | ||
| { path: "/privacy-policy", priority: "0.3" }, | ||
| { path: "/security-policy", priority: "0.3" }, | ||
| { path: "/terms-of-service", priority: "0.3" }, | ||
| ] as const; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,44 @@ | ||
| --- | ||
| import Layout from "../layouts/Layout.astro"; | ||
| --- | ||
|
|
||
| <Layout title="Page not found | T3 Code" description="This page does not exist on t3.codes." noindex> | ||
| <section class="not-found container"> | ||
| <p class="eyebrow">404</p> | ||
| <h1 class="display">This page does not exist.</h1> | ||
| <p class="not-found-lede"> | ||
| t3.codes is the only official T3 Code website. Download builds from this site, GitHub releases, | ||
| or the app stores. | ||
| </p> | ||
| <div class="not-found-actions"> | ||
| <a class="btn btn-primary btn-lg" href="/download">Download T3 Code</a> | ||
| <a class="btn btn-ghost btn-lg" href="/">Home</a> | ||
| </div> | ||
| </section> | ||
| </Layout> | ||
|
|
||
| <style> | ||
| .not-found { | ||
| padding-top: 18vh; | ||
| padding-bottom: 18vh; | ||
| max-width: 720px; | ||
| } | ||
|
|
||
| .not-found h1 { | ||
| margin: 14px 0 18px; | ||
| font-size: clamp(2.25rem, 5vw, 3.5rem); | ||
| } | ||
|
|
||
| .not-found-lede { | ||
| color: var(--fg-muted); | ||
| font-size: 1.05rem; | ||
| line-height: 1.7; | ||
| } | ||
|
|
||
| .not-found-actions { | ||
| display: flex; | ||
| flex-wrap: wrap; | ||
| gap: 12px; | ||
| margin-top: 32px; | ||
| } | ||
| </style> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,30 @@ | ||
| import type { APIRoute } from "astro"; | ||
|
|
||
| import { ANDROID_PLAY_STORE_URL, GITHUB_REPOSITORY_URL, IOS_APP_STORE_URL } from "../lib/site"; | ||
| import { absoluteUrl, SITE_TAGLINE } from "../lib/seo"; | ||
|
|
||
| // https://llmstxt.org: a plain index that tells AI agents which domain and links are official. | ||
| export const GET: APIRoute = () => { | ||
| const body = `# T3 Code | ||
|
|
||
| > ${SITE_TAGLINE}. T3 Code is free, MIT-licensed, and built by T3 Tools Inc. It runs Claude Code, Codex, Cursor, OpenCode, Grok, Antigravity, and other coding agents from one desktop, web, and mobile app. | ||
|
|
||
| The only official website is https://t3.codes. Official builds come from ${absoluteUrl("/download")}, ${GITHUB_REPOSITORY_URL}/releases, the \`t3\` package on npm (\`npx t3@latest\`), the iOS App Store, and Google Play. Any other website that offers a T3 Code download is not affiliated with T3 Tools Inc. | ||
|
|
||
| ## Official links | ||
|
|
||
| - [Download T3 Code](${absoluteUrl("/download")}): macOS, Windows, and Linux installers | ||
| - [Source code](${GITHUB_REPOSITORY_URL}): the MIT-licensed repository | ||
| - [Releases](${GITHUB_REPOSITORY_URL}/releases): release builds and changelogs | ||
| - [npm package](https://www.npmjs.com/package/t3): run \`npx t3@latest\` | ||
| - [iOS app](${IOS_APP_STORE_URL}) | ||
| - [Android app](${ANDROID_PLAY_STORE_URL}) | ||
|
|
||
| ## Policies | ||
|
|
||
| - [Security policy](${absoluteUrl("/security-policy")}) | ||
| - [Privacy policy](${absoluteUrl("/privacy-policy")}) | ||
| - [Terms of service](${absoluteUrl("/terms-of-service")}) | ||
| `; | ||
| return new Response(body, { headers: { "Content-Type": "text/plain; charset=utf-8" } }); | ||
| }; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,29 @@ | ||
| import type { APIRoute } from "astro"; | ||
|
|
||
| import { absoluteUrl } from "../lib/seo"; | ||
|
|
||
| // Answer engines (ChatGPT search, Claude, Perplexity) cite what their crawlers can fetch. | ||
| // Naming them keeps a future blanket rule from silently locking out the official site. | ||
| const ANSWER_ENGINE_AGENTS = [ | ||
| "OAI-SearchBot", | ||
| "ChatGPT-User", | ||
| "GPTBot", | ||
| "Claude-SearchBot", | ||
| "Claude-User", | ||
| "ClaudeBot", | ||
| "PerplexityBot", | ||
| "Bingbot", | ||
| "Googlebot", | ||
| ]; | ||
|
|
||
| export const GET: APIRoute = () => { | ||
| const body = [ | ||
| ...ANSWER_ENGINE_AGENTS.flatMap((agent) => [`User-agent: ${agent}`, "Allow: /", ""]), | ||
| "User-agent: *", | ||
| "Allow: /", | ||
| "", | ||
| `Sitemap: ${absoluteUrl("/sitemap.xml")}`, | ||
| "", | ||
| ].join("\n"); | ||
| return new Response(body, { headers: { "Content-Type": "text/plain; charset=utf-8" } }); | ||
| }; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,16 @@ | ||
| import type { APIRoute } from "astro"; | ||
|
|
||
| import { absoluteUrl, STATIC_PAGES } from "../lib/seo"; | ||
|
|
||
| export const GET: APIRoute = () => { | ||
| const urls = STATIC_PAGES.map( | ||
| (page) => | ||
| ` <url><loc>${absoluteUrl(page.path)}</loc><priority>${page.priority}</priority></url>`, | ||
| ); | ||
| const body = `<?xml version="1.0" encoding="UTF-8"?> | ||
| <urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9"> | ||
| ${urls.join("\n")} | ||
| </urlset> | ||
| `; | ||
| return new Response(body, { headers: { "Content-Type": "application/xml; charset=utf-8" } }); | ||
| }; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.