Contentstack is a headless CMS with an API-first approach that puts content at the centre. It is designed to simplify the process of publication by separating code from content.
This utility helps you to export content from Contentstack. The data is exported in JSON format and stored in file system.
Download this project and install all the modules using following command.
npm install
Update configuration details at config/index.js
{
master_locale: {
name: '', // Stack's master locale. ex: 'English - United States'
code: '' // Stack master locale's code. ex: 'en-us'
},
email: '', // Your registered email id
password: '', // Account password
source_stack: '' // Stack api_key
access_token: '' // Stack access_token
data: '' // Relative path to the directory, where exported data is to be stored. ex: './contents'
...
}
After setting the configuration, you'll can run the below given commands!
- Export all modules [ assets, locales, environments, extensions, webhooks, global_fields, content_types and entries ]
$ npm run export
- Export a specific module
$ npm run export-assets
$ npm run export-env
$ npm run export-locales
$ npm run export-extensions
$ npm run export-webhooks
$ npm run export-globalfields
$ npm run export-contenttypes
$ npm run export-entries
Note: Before exporting entries, you must export locales, assets and content types.
- If 2 assets share same uid and filename, only the first version of the asset would be available
- The following contents are not supported
- Roles
- Users
- Releases
- Workflow
This project is licensed under MIT license