acwi-preview-auth

Post a password to /api/auth to set the acwi_preview_session cookie.

Updated Aug 23, 2026
One-click install
npx skills add https://github.com/brp00005/site2 --skill acwi-preview-auth
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: acwi-preview-auth
Source: https://github.com/brp00005/site2/tree/main/.cursor/skills/acwi-preview-auth%20copy
Command: npx skills add https://github.com/brp00005/site2 --skill acwi-preview-auth

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Access to internal ACWI preview sections is gated by a cookie-based authentication flow; this skill provides a clear, repeatable method to obtain preview access without manually navigating security barriers.

Core Features & Use Cases

  • Understand how the ACWI preview auth flow works and where the credentials are validated.
  • Perform the core steps to obtain the acwi_preview_session cookie and access protected routes (e.g., /about#team).
  • Apply in development scenarios where gated preview pages are necessary for QA and stakeholder reviews.

Quick Start

Run the Next.js development server, post a password to /api/auth to set the acwi_preview_session cookie, and then navigate to a protected route such as /about#team.

Frequently Asked Questions about acwi-preview-auth

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I set the acwi_preview_session cookie for Next.js preview routes?

To set the acwi_preview_session cookie, you post a password to the /api/auth endpoint. This action creates the cookie with a 7-day expiry, enabling access to gated development preview pages like /about and /home.

What is cookie-based middleware authentication for development preview areas?

Cookie-based middleware authentication for development preview areas validates access by checking for a specific session cookie. If unauthenticated, the middleware redirects users away from protected routes to ensure only authorized access.

How does Next.js middleware redirect unauthenticated users from gated routes?

Next.js middleware redirects unauthenticated users by enforcing cookie gating on protected routes. When the required session cookie is missing, the middleware intercepts the request and redirects the user to the root path.

Can I use this preview auth flow for stakeholder QA reviews in a development environment?

Yes, you can use this preview auth flow for stakeholder QA reviews in a development environment. It provides a repeatable method to obtain access to internal preview pages without manually navigating security barriers.

How long does the acwi_preview_session cookie last before expiring?

The acwi_preview_session cookie lasts for 7 days before expiring. This 7-day expiry is set during cookie creation when the password is posted to the authentication endpoint.