Use Case Guide

Test Auth Middleware

Ensure your security logic is watertight. Test how your middleware handles expired sessions, missing tokens, and incorrect roles.

The Problem

Middleware logic is hard to test interactive because it happens before a page even loads, making it difficult to 'inspect' its variables.

The DevConsole Solution

DevConsole logs the headers and cookies sent to your middleware and any 'Internal-Redirect' headers it sends back.

Step-by-Step Implementation

Clear Auth Cookies

Use the cookie manager to quickly wipe your session and navigate to a protected page.

Modify Identity Tokens

Edit your JWT or session string to have 'user' role instead of 'admin' and refresh.

Monitor the Redirect

Ensure the middleware correctly bounces the request to /login or /unauthorized.

Related Questions

Does it support Next.js middleware.ts?

Yes! It's specifically optimized for Next.js and Remix middleware patterns.

Can I see 'rewrite' behavior?

Yes, DevConsole identifies when a request was rewritten internally by your server.

Founding developer offer

Use DevConsole for test auth middleware

See the workflow in the live demo, then add the complete local toolkit to your project.

Lifetime local entitlementFounding recognition12 months Solo Cloud or equivalent credit30-day guarantee
Become a Founding Developer — $29