Zero-config navigation

Automatic route discovery

For Next.js apps, yak scans your app directory and extracts page metadata automatically. The AI knows every page in your app and can navigate users there. A CLI generates the manifest for production builds.

Works withNext.js onlyApp & Pages routerChat & voiceZero-config defaultInclude/exclude filters
Route manifest
// Auto-generated from app/
[
{ path: "/", title: "Home" }
{ path: "/settings", title: "Settings" }
]
CLI: yak-nextjs generate-manifest

What you get

  • Auto-scans Next.js app and pages directories
  • Extracts title and description from static page metadata
  • CLI generates a route manifest for production builds
  • Filter routes with include/exclude regex patterns
  • Override with custom routes when you need to

How it works

1

Drop in the handler

createNextYakHandler() scans ./src/app and ./src/pages from the filesystem, skips api/ folders, and reads title and description from each page's static metadata export.

2

Generate the manifest for production

Because the compiled .next output drops source files, the yak-nextjs generate-manifest CLI pre-builds the routes at build time so scanning still works on Vercel and other serverless deploys.

3

The assistant navigates users

With every page known, a 'take me to pricing' request triggers a redirect through the same postMessage channel your onRedirect handler already uses, so navigation works in both chat and voice.

Frequently asked questions

Related features

Ship route discovery with yak

Add an AI assistant that matches your product—then turn on the features your users need.