[▲ Vercel Community](/) · [Categories](/categories) · [Latest](/latest) · [Top](/top) · [Live](/live) [Help](/c/help/9) # Facing OIDC Token Verification issue in prod 264 views · 0 likes · 4 posts ashlooz (@ashwinprabou) · 2025-11-30 I’m playing around with the AI Gateway and everything was working normally when running locally. When I attempted to deploy it via vercel, I’m running into this error: AI Gateway error response: {“error”:{“message”:“Error verifying OIDC token\\nThe AI Gateway OIDC authentication token is expected to be provided via the ‘VERCEL_OIDC_TOKEN’ environment variable. It expires every 12 hours.\\n- make sure your Vercel project settings have OIDC enabled (already on for new projects by default)\\n- if you’re running locally with ‘vercel dev’ the token is automatically obtained and refreshed for you\\n- if you’re running locally with your own dev server script you can fetch/update the token by running ‘vercel env pull’\\n- in production or preview the token is automatically obtained and refreshed for you”,“type”:“authentication_error”}} I have provided the VERCEL_OIDC_TOKEN env variable but still face this error after redeployment. My Vercel project settings have OIDC enabled by default, and I tried running ‘vercel env pull’ as well, which updated my .env too. Anyone know what else I should try? <!-- Current versus Expected behavior --> <!-- Code, configuration, and steps that reproduce this issue --> <!-- Project information (URL, framework, environment, project settings) --> ashlooz (@ashwinprabou) · 2025-11-30 Fixed: Make sure to use the OIDC token rather than the AI Gatway token Jacob Paris (@jacobparis) · 2025-12-01 Thanks for sharing your solution! ashlooz (@ashwinprabou) · 2025-12-01 Ok so… that worked for a couple hours and then stopped. Im aware that it expires every 12 hours, but I have not touched any part of the code since changing it and ran into that same error again. If anyone has a solution do let me know.