{"version":"2.1.318","anchor":"warning-when-the-oauth-sign-in-is-near-its-end","canonical_anchor":"warning-when-the-oauth-sign-in-is-near-its-end","heading":"Warnings before and after your sign-in reaches its time limit","tier":"notice","area":"Auth","scope":"individual","heads_up":false,"url":"https:\/\/changelogs.core-directive.com\/v\/2.1.318\/e\/warning-when-the-oauth-sign-in-is-near-its-end","release_url":"https:\/\/changelogs.core-directive.com\/v\/2.1.318","markdown":"### Warnings before and after your sign-in reaches its time limit\n\nClaude Code now warns when your sign-in is about to expire or has expired, and points you to claude auth login or claude setup-token\n\n**Unclear.** It is not clear when, or whether, Claude Code shows this warning in practice.\n\n**What**\n\nSome sign-ins to Claude Code have a fixed end date, and renewing them does not move that date. Claude Code now tells you about this before and after it happens:\n\n- A warning appears when your sign-in is about to end or may already have ended. It says: \"Renewing it does not move those dates. Run claude auth login before then, or use claude setup-token for unattended jobs.\"\n\n- New error messages appear once the limit is reached, such as \"Login reached its time limit \u00b7 Please run \/login\". They say the login cannot be renewed and point to `claude auth login`.\n\n- For unattended jobs, such as scripts or CI pipelines (automated build systems), the messages point to `claude setup-token` together with the `CLAUDE_CODE_OAUTH_TOKEN` environment variable. An environment variable is a named value set outside Claude Code that it reads when it starts.\n\n- The sign-in's end date, `credential_expires_at`, is now included in data that Claude Code passes along, and a warning event is reported to Anthropic.\n\nThe finding that found the error messages showed only their text, so what exactly triggers each message was not traced.\n\n**Why**\n\nLong-running sessions and automated jobs get advance notice and a clear next step instead of a sudden, unexplained sign-in failure. If you run Claude Code unattended, a long-lived token from `claude setup-token` avoids this time limit.\n\n- Area: Auth\n- Names: `claude setup-token`\n- Tier: You'll notice\n- Useful: 3\/5\n- Signal: 1\/5\n- Scope: individual\n- Heads-up: no"}