
Security News
/Research
Popular node-ipc npm Package Infected with Credential Stealer
Socket detected malicious node-ipc versions with obfuscated stealer/backdoor behavior in a developing npm supply chain attack.
@optimizely/cms-cli
Advanced tools
The official command-line tool for Optimizely CMS that enables code-first content modeling. Sync your TypeScript content type definitions to Optimizely CMS, allowing you to manage content models alongside your code with full version control.
Install as a development dependency:
npm install -D @optimizely/cms-cli
Or using other package managers:
# pnpm
pnpm add -D @optimizely/cms-cli
# yarn
yarn add -D @optimizely/cms-cli
Create a .env file in your project root with your CMS credentials:
OPTIMIZELY_CMS_URL=https://your-cms-instance.com
OPTIMIZELY_CMS_CLIENT_ID=your-client-id
OPTIMIZELY_CMS_CLIENT_SECRET=your-client-secret
Create TypeScript definitions for your content models:
import { contentType } from '@optimizely/cms-sdk';
export const ArticlePage = contentType({
key: 'Article',
displayName: 'Article page',
baseType: '_page',
properties: {
title: {
displayName: 'Title',
type: 'string',
},
subtitle: {
type: 'string',
displayName: 'Subtitle',
},
body: {
displayName: 'body ',
type: 'richText',
},
},
});
Run the CLI to push your definitions to Optimizely CMS:
pnpm exec optimizely-cms-cli config push ./optimizely.config.mjs
Sync your TypeScript content type definitions with Optimizely CMS:
# Push content types to CMS (uses ./optimizely.config.mjs by default)
optimizely-cms-cli config push
# Push with custom config file
optimizely-cms-cli config push ./custom-config.mjs
# Force update (may result in data loss)
optimizely-cms-cli config push --force
# Pull current CMS configuration to JSON
optimizely-cms-cli config pull --output ./config.json
Verify your CMS credentials are correctly configured:
# Test your credentials from environment variables
optimizely-cms-cli login
# Show detailed authentication output
optimizely-cms-cli login --verbose
Manage individual content types:
# Delete a specific content type
optimizely-cms-cli content delete ArticlePage
# Delete with custom host
optimizely-cms-cli content delete ProductPage --host https://example.com
⚠️ Use with extreme caution - these commands are destructive:
# Delete ALL user-defined content types (interactive confirmation required)
optimizely-cms-cli danger delete-all-content-types
# Show all available commands
optimizely-cms-cli --help
# Show help for a specific command
optimizely-cms-cli config push --help
# Show help for a topic
optimizely-cms-cli config --help
For comprehensive guides and best practices:
This CLI tool works best when used alongside the @optimizely/cms-sdk for a complete type-safe development experience:
# Install both packages
npm install @optimizely/cms-sdk
npm install -D @optimizely/cms-cli
The typical workflow:
For complete setup instructions, see the main repository README.
Apache License 2.0
Built by the Optimizely CMS Team | Documentation | GitHub
FAQs
CLI application for integration with Optimizely CMS
The npm package @optimizely/cms-cli receives a total of 470 weekly downloads. As such, @optimizely/cms-cli popularity was classified as not popular.
We found that @optimizely/cms-cli demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
/Research
Socket detected malicious node-ipc versions with obfuscated stealer/backdoor behavior in a developing npm supply chain attack.

Security News
TeamPCP and BreachForums are promoting a Shai-Hulud supply chain attack contest with a $1,000 prize for the biggest package compromise.

Security News
Packagist urges PHP projects to update Composer after a GitHub token format change exposed some GitHub Actions tokens in CI logs.