PHPackages                             do-it-well/magento2-module-cms-command - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. do-it-well/magento2-module-cms-command

ActiveMagento2-module[Utility &amp; Helpers](/categories/utility)

do-it-well/magento2-module-cms-command
======================================

CMS import/export commands for Magento2

1.0.1(6y ago)118.2k↓50%MITPHP

Since Aug 15Pushed 6y ago1 watchersCompare

[ Source](https://github.com/do-it-well/magento2-module-cms-command)[ Packagist](https://packagist.org/packages/do-it-well/magento2-module-cms-command)[ RSS](/packages/do-it-well-magento2-module-cms-command/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (2)DependenciesVersions (3)Used By (0)

CMS Commands for Magento2
=========================

[](#cms-commands-for-magento2)

A Magento2 Module providing CMS-related command-line tools.

Installation
------------

[](#installation)

This module can be installed via composer and the Magento2 command-line tool. For example:

```
composer require do-it-well/magento2-module-cms-command
./bin/magento module:enable DIW_CmsCommand
./bin/magento setup:upgrade

```

Commands
--------

[](#commands)

- **cms:block:list** list available CMS block IDs
- **cms:block:dump** dump (as JSON) either all CMS block data, or (if specified) the CMS block data of a specific `block_id`
- **cms:block:load** load (from a JSON object, or array of JSON objects), CMS block data
- **cms:page:list** list available CMS page IDs
- **cms:page:dump** dump (as JSON) either all CMS page data, or (if specified) the CMS page data of a specific `page_id`
- **cms:page:load** load (from a JSON object, or array of JSON objects), CMS page data

What It Does
------------

[](#what-it-does)

The `cms:*:dump` commands dump either a single model, or each of a collection of models, and directly output the result of `$model->getData()` as a JSON object to STDOUT.

The `cms:*:load` commands read a JSON object (or each object from a JSON array of objects). If a relevant `*_id` attribute is set within the JSON object, that object is loaded; otherwise, an empty model is created. In either case, the decoded JSON object is passed to `$model->setData()` directly, and the model is saved. ie: if the `*_id` field is not set, a new page/block will be created.

As should be obvious, this method of dumping / loading CMS data is very basic, and there are many situations in which these methods would not be appropriate or safe. No guarantees are made. You should perform both dumps and loads only with a complete understanding of the limitations of this implementation.

Examples
--------

[](#examples)

**You can dump a specific page or block as a single json object to STDOUT, by identifier**

```
$ bin/magento cms:page:dump home
{"page_id":"2","title":"My eCommerce Site","page_layout":...

```

**...or by numeric id**

```
$ bin/magento cms:page:dump 2
{"page_id":"2","title":"My eCommerce Site","page_layout":...

```

**You can also dump *all* pages / blocks, as a json array of json objects, by omitting the id/identifier**

```
$ bin/magento cms:page:dump
[
{"page_id":"1","title":"404 Not Found","page_layout":...},
{"page_id":"2","title":"My eCommerce Site","page_layout":...},
...

```

**The same format can also be used to re-import a dumped page or block**

```
$ bin/magento cms:page:dump home > home.json
... edit home.json ...
$ bin/magento cms:page:load < home.json

```

**...or a list of multiple pages or blocks**

```
$ bin/magento cms:page:dump > pages.json
... edit pages.json ...
$ bin/magento cms:page:load < pages.json

```

License
-------

[](#license)

All module code within this repository is licensed under the MIT license. See the MIT-LICENSE.txt file for details.

Support
-------

[](#support)

If you encounter any problems with this module, you may open an issue on GitHub at

Premium support, assistance in module installation or configuration, or other development services, can be obtained by contacting [Do It Well Limited](https://do-it-well.co.uk/)

###  Health Score

32

—

LowBetter than 72% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity26

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity60

Established project with proven stability

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~0 days

Total

2

Last Release

2468d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/6b8e2fa6face61daa12caeebb903a743d55f1ae1a8b1a27ac261a0b609b10908?d=identicon)[do-it-well](/maintainers/do-it-well)

---

Top Contributors

[![wpalmer](https://avatars.githubusercontent.com/u/357044?v=4)](https://github.com/wpalmer "wpalmer (2 commits)")

### Embed Badge

![Health badge](/badges/do-it-well-magento2-module-cms-command/health.svg)

```
[![Health](https://phpackages.com/badges/do-it-well-magento2-module-cms-command/health.svg)](https://phpackages.com/packages/do-it-well-magento2-module-cms-command)
```

###  Alternatives

[werd/ivona-speechcloud-sdk-php

IVONA SpeechCloud SDK for PHP

102.1k](/packages/werd-ivona-speechcloud-sdk-php)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
