Discussion about expiration of Sanity Auth tokens causing issues with API calls and deployment
sanity login), invalidating the previous token in the process. Robot tokens (i.e., those generated under the API tab in Manage)
(for ref:
https://github.com/sanity-io/sanity/issues/3975#issue-1498244950 ,
https://github.com/sanity-io/sanity/issues/3925#issue-1471583275 )
When you talk about tokens and sessions, these are separate when it comes to CLI build commands and Sanity Logins.
Please tell me what versions for sanity you use (package.json) and which commands you tried.
"@sanity/default-layout": "^2.35.2",
"@sanity/default-login": "^2.35.2",
"@sanity/desk-tool": "^2.35.2",
"@sanity/eslint-config-studio": "^2.0.1",
"@sanity/vision": "^2.24",, and the sanity-cli version 2.34.0
You tried to login via the cli in your terminal right?
API tokens is what you would need to use in the future though if you don’t want this to happen again (session tokens are going to be even shorter lived long term I’m afraid).
Was this answer helpful?
Sanity – Build the way you think, not the way your CMS thinks
Sanity is the developer-first content operating system that gives you complete control. Schema-as-code, GROQ queries, and real-time APIs mean no more workarounds or waiting for deployments. Free to start, scale as you grow.