Open-source Grok Bot alternative for named AI teammates. Local-first desktop, web, and mobile clients with per-bot tools, instructions, and memory. Independent fork of T3 Code.
feat(marketing): report page requests to Notra GEO (#149)
devin-ai-integration[bot]4a38ceaf6f31
diff --git a/apps/marketing/middleware.ts b/apps/marketing/middleware.tsnew file mode 100644index 000000000..4795d68a1--- /dev/null+++ b/apps/marketing/middleware.ts@@ -0,0 +1,16 @@+// Vercel routing middleware for the marketing site. Reports page requests to+// Notra GEO (AI crawler and referral analytics) and lets every request through.+import { Tracker } from "@usenotra/geo";++const tracker = new Tracker({+ token: process.env.NOTRA_GEO_TOKEN ?? "",+ endpoint: "https://app.usenotra.com",+});++export default function middleware(+ request: Request,+ context: { waitUntil(promise: Promise<unknown>): void },+): undefined {+ if (!tracker.options.token) return;+ context.waitUntil(tracker.track(request));+}diff --git a/apps/marketing/package.json b/apps/marketing/package.jsonindex 2ada40529..b49a6a4d0 100644--- a/apps/marketing/package.json+++ b/apps/marketing/package.json@@ -11,6 +11,7 @@},"dependencies": {"@t3tools/shared": "workspace:*",+ "@usenotra/geo": "0.3.0","astro": "^7.0.3"},"devDependencies": {diff --git a/pnpm-lock.yaml b/pnpm-lock.yamlindex 8967f9cf7..edbe9e894 100644--- a/pnpm-lock.yaml+++ b/pnpm-lock.yaml@@ -178,6 +178,9 @@ importers:'@t3tools/shared':specifier: workspace:*version: link:../../packages/shared+ '@usenotra/geo':+ specifier: 0.3.0+ version: 0.3.0([email protected])astro:specifier: ^7.0.3version: 7.0.3(@astrojs/[email protected])(@emnapi/[email protected])(@emnapi/[email protected])(@types/[email protected])([email protected])([email protected])([email protected])([email protected])([email protected])([email protected])([email protected])([email protected])([email protected])@@ -6292,6 +6295,15 @@ packages:peerDependencies:zod: ^3.25.0 || ^4.0.0+ '@usenotra/[email protected]':+ resolution: {integrity: sha512-8l4NKUXwtdoAqP8+ZfB95yjpjSpexBgewCsPYpUAUZ2wY/CFvIX8HHHl0GRh51+KsKe0+1deJdmZsTEqi4Qxjg==}+ engines: {node: '>=18'}+ peerDependencies:+ zod: ^4.0.0+ peerDependenciesMeta:+ zod:+ optional: true+'@vercel/[email protected]':resolution: {integrity: sha512-Tf5k5y2F478oTiQcU5R8Ntix1UejE6NdduZnI7aa1XXxjCtifX1XdRS/D2uTjiQAwIL3pLa1LSAN80ABbba+TQ==}hasBin: true@@ -16038,7 +16050,7 @@ snapshots:postcss: 8.5.26resolve-from: 5.0.0optionalDependencies:- expo: 56.0.12(8895228379997a2a064f9644cda56ed0)+ expo: 56.0.12(deb8cbf3e0f411b34ba85a995c9982ba)transitivePeerDependencies:- bufferutil- supports-color@@ -19766,6 +19778,10 @@ snapshots:zod: 4.4.3zod-to-json-schema: 3.25.2([email protected])+ '@usenotra/[email protected]([email protected])':+ optionalDependencies:+ zod: 4.4.3+'@vercel/[email protected]':dependencies:'@vercel/routing-utils': 6.2.0@@ -20694,8 +20710,8 @@ snapshots:react-refresh: 0.14.2optionalDependencies:'@babel/runtime': 7.29.7- expo: 56.0.12(8895228379997a2a064f9644cda56ed0)- expo-widgets: 56.0.19(3cdc0dde9f93166d952f1e1bd0cb25c0)+ expo: 56.0.12(deb8cbf3e0f411b34ba85a995c9982ba)+ expo-widgets: 56.0.19(32843e0c0883df8bccfa0b8323659df5)transitivePeerDependencies:- '@babel/core'- supports-color@@ -22594,6 +22610,22 @@ snapshots:expo: 56.0.12(8895228379997a2a064f9644cda56ed0)react-native: 0.85.3(@babel/[email protected])(@react-native/[email protected](@babel/[email protected])([email protected])([email protected]))(@types/[email protected])([email protected])([email protected])([email protected])+ [email protected](32843e0c0883df8bccfa0b8323659df5):+ dependencies:+ '@expo/plist': 0.7.0+ '@expo/ui': 56.0.18(32843e0c0883df8bccfa0b8323659df5)+ expo: 56.0.12(deb8cbf3e0f411b34ba85a995c9982ba)+ react: 19.2.6+ react-native: 0.85.3(@babel/[email protected])(@react-native/[email protected](@babel/[email protected])([email protected])([email protected]))(@types/[email protected])([email protected])([email protected])([email protected])+ transitivePeerDependencies:+ - '@babel/core'+ - '@types/react'+ - '@types/react-dom'+ - react-dom+ - react-native-reanimated+ - react-native-worklets+ optional: true+[email protected](3cdc0dde9f93166d952f1e1bd0cb25c0):dependencies:'@expo/plist': 0.7.0