Releases: datocms/cli
Releases · datocms/cli
v4.0.5
Changes
- New
cma:docscommand — Browse the DatoCMS Content Management API reference documentation directly from the terminal. List resources, describe actions, and expand details sections without leaving the CLI.
Examples
# List all available resources
datocms cma:docs
# Describe a specific resource and its actions
datocms cma:docs items
# Describe a specific action with examples
datocms cma:docs items create
# Expand a collapsed details section
datocms cma:docs items create --expand "Example: Basic example"v4.0.4
Changes
- Revoke OAuth token on logout —
datocms logoutnow revokes the OAuth token remotely before deleting local credentials - Detect revoked tokens — When a stored OAuth token has been revoked (e.g. from account settings), the CLI now shows a clear error message instead of a generic "could not access project" error
v4.0.3
Changes
- Hide inaccessible projects in link command — Projects where the user doesn't have access permissions are no longer shown in the project selection list during
datocms link
v4.0.2
Changes
- Allow re-login without requiring logout first — Running
datocms loginwhen already authenticated now replaces existing credentials instead of blocking - Improve OAuth token resolution — Linked projects (via
datocms link) now take priority over theDATOCMS_API_TOKENenvironment variable, so OAuth-based authentication is not silently overridden - Improve error messages — Better error message when a linked project cannot be accessed, mentioning possible OAuth permission changes
v4.0.0
Easier (and safer) project linking with OAuth
OAuth login is now the recommended way to authenticate. The new setup is fully guided: datocms login opens your browser, datocms link lets you search and select a project interactively — no tokens to copy, no environment variables to configure. Every API call is tied to your personal identity, giving teams clear visibility over who made which changes.
New commands
datocms login— authenticate your DatoCMS account via OAuthdatocms link— connect the current directory to a specific DatoCMS projectdatocms logout— remove stored credentialsdatocms whoami— check which account you're logged in asdatocms unlink— disconnect a directory from a project
What changed for existing users
Nothing breaks. The old profile:set and profile:remove commands still work — they redirect to link and unlink under the hood. Existing scripts and CI/CD pipelines using DATOCMS_API_TOKEN or the --api-token flag are completely unaffected.
@datocms/cli v3.1.3
New Features
- New
schema:generatecommand - Generate TypeScript schemas from DatoCMS models - Enhanced
migrations:newcommand - Added--schemaoption for schema-specific migrations
Bug Fixes
- Various fixes and stability improvements