sign-in-with-vercel
Sign in with Vercel guidance — OAuth 2.0/OIDC identity provider for user authentication via Vercel accounts. Use when implementing user login with Vercel as the identity provider.
- License 许可
- MIT
- 最近更新
- 2026-03-30
- Stars
- ★ 2
- Forks
- 0
01 前言 Front Matter
- name
- sign-in-with-vercel
- chainTo
- [ { "message": "NextAuth/Auth.js detected alongside Vercel OAuth — loading Auth guidance for proper integration patterns, middleware setup, and provider configuration.", "pattern": "next-auth|NextAuth|from\\s+['\"]next-auth['\"\"]|from\\s+['\"]@auth/['\"\"]", "targetSkill": "auth", "skipIfFileContains": "clerkMiddleware|@clerk/|from\\s+['\"]@descope/" }, { "message": "Vercel OAuth environment variables detected — loading Env Vars guidance for secure configuration and vercel env management.", "pattern": "VERCEL_CLIENT_ID|VERCEL_CLIENT_SECRET", "targetSkill": "env-vars", "skipIfFileContains": "vercel\\s+env\\s+pull|process\\.env\\.VERCEL_CLIENT_ID" } ]
- metadata
- { "docs": [ "https://vercel.com/docs/sign-in-with-vercel" ], "sitemap": "https://vercel.com/sitemap/docs.xml", "priority": 6, "bashPatterns": [], "pathPatterns": [ "app/api/auth/**", "app/login/**", "src/app/api/auth/**", "src/app/login/**", "pages/api/auth/**" ] }
- retrieval
- { "aliases": [ "vercel oauth", "vercel login", "vercel identity", "oauth provider" ], "intents": [ "add vercel login", "implement oauth with vercel", "use vercel as identity provider" ], "entities": [ "OAuth 2.0", "OIDC", "Sign in with Vercel", "identity provider" ] }
- description
- Sign in with Vercel guidance — OAuth 2.0/OIDC identity provider for user authentication via Vercel accounts. Use when implementing user login with Vercel as the identity provider.
03 SKILL.md 正文
Sign in with Vercel
You are an expert in Sign in with Vercel — Vercel's OAuth 2.0 / OpenID Connect identity provider.
What It Is
Sign in with Vercel lets users log in to your application using their Vercel account. Your app does not need to handle passwords, create accounts, or manage user sessions — Vercel acts as the identity provider (IdP).
OAuth 2.0 Authorization Code Flow
1. User clicks "Sign in with Vercel"
2. Redirect to Vercel authorization URL
3. User grants consent on Vercel's consent page
4. Vercel redirects back with authorization code
5. Exchange code for tokens (ID Token + Access Token + Refresh Token)
Tokens
| Token | Lifetime | Purpose |
|---|---|---|
| ID Token | Signed JWT | Proves user identity (name, email, avatar) |
| Access Token | 1 hour | Bearer token for Vercel REST API calls |
| Refresh Token | 30 days | Silent re-authentication (rotates on use) |
Configuration
- Register your app at
https://vercel.com/dashboard/{team}/integrations/console(the Integrations Console). Click Create Integration → fill in the OAuth details → note the Client ID and Client Secret. - Configure redirect URIs and scopes
- Use any standard OAuth 2.0 client library (no Vercel-specific SDK required)
When to Use
- Build tools/dashboards that need Vercel account identity
- Grant users access to their own Vercel resources via your app
- Developer-facing apps where users already have Vercel accounts
When NOT to Use
- General-purpose user auth (not everyone has Vercel) → use Clerk, Auth0
- Machine-to-machine auth → use Vercel OIDC Federation or API tokens
- Internal team auth → use Teams & Access Control
References
04 同仓库更多 Skills
workflow
Vercel Workflow DevKit (WDK) expert guidance. Use when building durable workflows, long-running tasks, API routes or agents that need pause/resume, retries, step-based execution, or crash-safe orchestration with Vercel Workflow.
verification
Full-story verification — infers what the user is building, then verifies the complete flow end-to-end: browser → API → data → response. Triggers on dev server start and 'why isn't this working' signals.
vercel-storage
Vercel storage expert guidance — Blob, Edge Config, and Marketplace storage (Neon Postgres, Upstash Redis). Use when choosing, configuring, or using data storage with Vercel applications.
vercel-services
Vercel Services — deploy multiple services within a single Vercel project. Use for monorepo layouts or when combining a backend (Python, Go) with a frontend (Next.js, Vite) in one deployment.
vercel-sandbox
Vercel Sandbox guidance — ephemeral Firecracker microVMs for running untrusted code safely. Supports AI agents, code generation, and experimentation. Use when executing user-generated or AI-generated code in isolation.
vercel-queues
Vercel Queues guidance (public beta) — durable event streaming with topics, consumer groups, retries, and delayed delivery. $0.60/1M ops. Powers Workflow DevKit. Use when building async processing, fan-out patterns, or event-driven architectures.