Let's see how to install contentstack-express.


You’ll need node.js v4.2.0 or later to use contentstack-express.

Note:Older versions(less than v4.2.0) of node.js are not recommended.

Install CLI

Run this command in a Terminal or Command Prompt to obtain and globally install the command line interface (CLI) on your system:

$ npm install -g contentstack-cli

Once installed, CLI can be used to execute Contentstack commands.

Connect to your stack

In the terminal, navigate to your workspace, and run the 'connect' command.

$ contentstack connect

This will prompt you to enter the stack api key and access token. You can find these details in the Settings > Stack page.

Enter your stack api key: {API_KEY}
Enter your stack access token: {ACCESS_TOKEN}

This will validate the stack. Once validated, you will be prompted to enter the project root directory and select the publishing environment ('development') which we created in earlier step.

Enter name of the directory to contain the project: (my-site)
Select the publishing environment:
1. development

This will automatically configure your project for the selected publishing environment along with basic theme for the website.

Was this article helpful?