## Problem The steps to build a Supabase integration are spread across five pages: the Partner Catalog page, creating an OAuth app, OAuth scopes, the partner install flow, and the Management API reference. A partner has no single page that says where to start or what to do next. Linear: DOCS-1720. ## Solution Add one guide, **Build a Supabase integration**, as the first item under **Build Your Own** in the integrations sidebar. It does not repeat the detail on the other pages. It links to them. - **The path at a glance:** two short paths. Partner Catalog: apply, build a landing page, publish. Integration: apply, build the OAuth flow, build the integration, publish. - **Apply to the Partners program**, then **Choose: Partner Catalog or Integration**, a comparison table with wireframe images (SVG, light and dark). - **Partner Catalog: Build your landing page** and **Integration** (build the OAuth flow, build the integration), each with "Build it" cards that link to the top of the existing page. - **Publish:** ask the partner manager to list the partner on the Partner Catalog or the Integrations page. - Removes the redirect from `/docs/guides/integrations/build-a-supabase-integration` to the OAuth guide, so the new page is reachable at that URL. The old `/oauth-scopes` redirect stays. - The progression and card data is in `apps/docs/data/content-listings/build-a-supabase-integration.data.ts`. Not in this PR: edits to the existing pages. The cards link to page tops, so nothing here depends on those edits. ## Please check - The five progression icons are placeholders from the built-in set. New icons are coming. - The table images sit inside table cells with a fixed width. I checked them in the dev server only. - I rendered the page with `pnpm dev` and ran `oxfmt --check` on the changed files. I did not run the docs tests or `build:guides-markdown`. - Two details are unverified: how partners hand their public key to Supabase for a signed redirect, and partner status callbacks. The guide does not describe either. - The Dashboard Integrations tab wireframe is a drawing, not a screenshot. ## Preview links | Site | Live | Preview | Search for | | ---- | ---- | ------- | ---------- | | Docs | [/docs/guides/integrations/build-a-supabase-integration](https://supabase.com/docs/guides/integrations/build-a-supabase-integration) (redirects to the OAuth guide until this merges) | Vercel bot comment | `The path at a glance` | 🤖 Generated with [Claude Code](https://claude.com/claude-code) --------- Co-authored-by: John Stokvis <345546350+stokvis-at-supabase@users.noreply.github.com> Co-authored-by: Claude Sonnet 5.5 <noreply@anthropic.com> Co-authored-by: Nik Richers <nik@validmind.ai> Co-authored-by: John Stokvis <johnstokvis@Johns-MacBook-Pro.local>
Docs redirects
Redirects for /docs URLs live here. Before this folder existed, most of them were in apps/www/lib/redirects.js, because www serves the docs zone through a rewrite.
Both files use full public paths, including the /docs prefix (for example /docs/guides/...).
| File | Contains | Served by |
|---|---|---|
static-redirects.json |
One-to-one mappings: a fixed source maps to a fixed destination, with no params, splats, regex, or has/missing. |
Source only. Hand-edited. |
generated/static-redirects-md-variants.json |
Build output: static-redirects.json plus the generated .md variants. Gitignored. |
Vercel bulk redirects, through bulkRedirectsPath in apps/docs/vercel.json |
dynamic-redirects.js |
Anything with conditional logic: :param, * / :path* splats, regex groups, has, or missing. |
Next.js redirects() in apps/docs/next.config.mjs |
Dev and preview only redirects (/, /dashboard/*, /blog/*) are in a separate section at the end of dynamic-redirects.js.
Adding a redirect
-
If it has no params, splats, regex, or conditions, add it to
static-redirects.json. Otherwise add it todynamic-redirects.js. -
In
static-redirects.json, use the same shape as the existing entries:{ "source": "/docs/guides/old-path", "destination": "/docs/guides/new-path", "permanent": true }Do not add a
.mdentry by hand. The generator creates it for every/docs/guides/entry. -
To preview the Vercel file locally, run:
pnpm run redirects:generateThe build (
redirects:generateis a turbo dependency ofbuild) regenerates it on every deploy, so do not commit it. -
In
dynamic-redirects.js, includebasePath: false, because the sources are full public paths and Next must not add/docsagain..mdvariants for/docs/guides/entries are generated innext.config.mjs, so do not add them here:{ basePath: false, permanent: true, source: '/docs/guides/old-path/:slug', destination: '/docs/guides/new-path/:slug', }, -
Use
permanent: truefor permanent (308) redirects andpermanent: falsefor temporary (307) redirects. -
JSON does not support comments, so put the reason for a static entry in the PR description.
-
Keep each source unique within its file.
-
Run
pnpm testinapps/docsto confirm thatnext.config.mjsstill loads.
Generator
scripts/generate-static-redirects-md-variants.mjs builds generated/static-redirects-md-variants.json from static-redirects.json:
- It adds a
.mdvariant for every/docs/guides/entry with a string destination. - It fails if a hand-written
.mdentry conflicts with a generated variant, or if a source is duplicated. - It groups each base entry with its
.mdvariant, base first, and sorts the groups by base path.
The generator runs as a turbo dependency of build, so an invalid source fails the build before anything deploys. The output is gitignored, so generated redirects do not appear in PR diffs. Run pnpm run redirects:generate to review them.
Notes
- Bulk redirects ignore Next's
basePath, which is why the JSON uses the/docsprefix. .mdvariants for dynamic/docs/guides/entries are generated at runtime innext.config.mjs. Static variants are generated by the script intogenerated/static-redirects-md-variants.json.apps/wwwruns its own redirects before it rewrites/docsto this app. Where the same source exists in both places, thewwwrule wins./docs/guides/database/inspectis one case:wwwsends it to/docs/guides/observability/inspect, and the docs config used to send it to/docs/guides/monitoring-and-debugging/inspect. This folder keeps thewwwdestination.