Repository navigation
A Next.js 16 bot-detection diagnostic app for Vercel: verify reporting with a labeled request #101759
Unanswered
cport1
asked this question in
Show and tell
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
I build WebDecoy. We made a small Next.js 16 diagnostic app for checking whether bot detection is installed and reporting on Vercel before choosing an enforcement policy.
The app gives you an inspection endpoint that shows whether reporting is configured, the request decision and whether it would block. It keeps the API key server-side. The refreshed example uses Next.js 16.4.6 and our published SDK 0.23.0.
This is a new verification workflow following my earlier general crawler-monitor example: a Vercel-specific adapter, a diagnostic UI and two HTTP checks are included in the download.
Watch the verified live setup test
25-second WebDecoy Vercel proof. The clip is an animated summary of the verified response and dashboard fields, with English captions; it is not a screen recording.
Separately from the local fixture checks below, we deployed this example to Vercel and sent the reserved
WebDecoy-Test/1.0request to/api/inspectat 16:44 UTC on November 13, 2026. It returned HTTP 200. We matched its SDK Test record in the dedicated demo property by path, user agent and time; the dashboard showed Logged, not blocked. This confirms reporting for a controlled setup request, not real-crawler detection accuracy.Try it
Open the live diagnostic UI. It shows the interface; use your own deployment and reporting key for the request-to-dashboard check below. The public demo is not a view into customer traffic.
Download the example, extract it, then run:
Set your own
WEBDECOY_API_KEYin.env.localfor dashboard reporting. Without it, the app still runs and explicitly reports that reporting is unconfigured. It does not invent a detection result.For Next.js 16, the request hook in
proxy.tsuses:Keep the import followed by the default export: the one-line re-export fails the Next.js 16 build check. If you already have authentication or redirects in your request hook, compose with that flow rather than replacing it.
Send a labeled setup request:
curl -i -A 'WebDecoy-Test/1.0' http://127.0.0.1:3107/api/inspectFor a Vercel deployment, configure the server-side API key in the intended environment, redeploy and use your deployed hostname. Match the test request with its Test record in your WebDecoy dashboard. An HTTP 200 alone doesn't establish that reporting worked.
What we checked
The exact downloadable archive passed a clean production build and two HTTP checks. One uses the published middleware with a controlled local API fixture to verify the test signal, monitor behavior and replacement of forged verdict headers. The other starts the built Next.js app without a key and checks ordinary and test requests, including forged inbound headers.
Those local checks use a controlled fixture; the separate live reporting result is described above. Neither is an AI-bot accuracy benchmark. Requests that never reach this hook are outside its coverage. Clearance credentials and enforcement policy are separate from the reporting API key.
Walkthrough and troubleshooting · SDK source · Example source
I'd welcome feedback on the diagnostic endpoint and on composing this with existing Next.js proxy flows. After trying the example, star the Node SDK if it is useful to you.
Writing assistance: AI-assisted; implementation and claims checked against the runnable example.
All reactions