Skip to content

Conversation

@berglie
Copy link

@berglie berglie commented Oct 19, 2025

Problem
Some users experience 401 errors when Vercel deployments are complete but authentication is not properly configured. Currently, the action treats 401 errors as failures and continues retrying, which is unnecessary when the deployment is actually ready and accessible.

Solution
Added a new optional input parameter allow_unauthenticated that allows 401 errors to be treated as successful deployments. When enabled, the action will stop checking and return successfully upon encountering a 401 status code.

Changes

  • Added allow_unauthenticated input parameter in action.yml (defaults to false)
  • Modified waitForUrl function to handle 401 errors when allow_unauthenticated is true
  • Updated main run function to read and pass the new parameter
  • Updated test helper functions to support the new parameter

Usage

- uses: your-action@v1
  with:
    token: ${{ secrets.GITHUB_TOKEN }}
    allow_unauthenticated: true

Benefits

  • Allows users to proceed when deployment is complete but auth isn't configured
  • Reduces unnecessary retries and timeout failures
  • Maintains backward compatibility (defaults to false)
  • Clear, descriptive parameter name that explains the use case

This addresses the common scenario where users only care that their Vercel preview is deployed and accessible, regardless of authentication status.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants