# cli-cm-import-abhnv

> Contentstack CLI plugin to import content into stack

Latest version **1.8.2** (published 2023-08-29) · MIT license · 0 weekly downloads

## Install

```sh
npm install cli-cm-import-abhnv
pnpm add cli-cm-import-abhnv
yarn add cli-cm-import-abhnv
bun add cli-cm-import-abhnv
```

## Health

**Score 40/100 (D)** — status: abandoned.

Positive: has types; no vulnerabilities; high maintenance score; high quality score.

Warnings: low downloads; no esm support.

Negative: abandoned.

## Facts

| | |
|---|---|
| Version | 1.8.2 |
| Published | 2023-08-29 |
| First published | 2023-08-29 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | CommonJS |
| Node | >=14.0.0 |
| Dependencies | 17 |
| Unpacked size | 479.9 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 14 |
| Author | Contentstack |
| Maintainers | abhinav-from-contentstack |
| Keywords | contentstack, cli, plugin |

## Links

- npm: https://www.npmjs.com/package/cli-cm-import-abhnv
- Repository: https://github.com/contentstack/cli
- Issues: https://github.com/contentstack/cli/issues
- npm.io page: https://npm.io/package/cli-cm-import-abhnv

## Dependencies (17)

- [ncp](https://npm.io/package/ncp.md) ^2.0.0
- [chalk](https://npm.io/package/chalk.md) ^4.1.2
- [debug](https://npm.io/package/debug.md) ^4.1.0
- [merge](https://npm.io/package/merge.md) ^2.1.1
- [tslib](https://npm.io/package/tslib.md) ^2.4.1
- [lodash](https://npm.io/package/lodash.md) ^4.17.20
- [marked](https://npm.io/package/marked.md) ^4.0.17
- [mkdirp](https://npm.io/package/mkdirp.md) ^1.0.4
- [winston](https://npm.io/package/winston.md) ^3.7.2
- [big-json](https://npm.io/package/big-json.md) ^3.2.0
- [bluebird](https://npm.io/package/bluebird.md) ^3.7.2
- [@oclif/core](https://npm.io/package/@oclif/core.md) ^2.9.3
- [@oclif/config](https://npm.io/package/@oclif/config.md) ^1.18.3
- [promise-limit](https://npm.io/package/promise-limit.md) ^2.7.0
- [@contentstack/management](https://npm.io/package/@contentstack/management.md) ~1.10.0
- [@contentstack/cli-command](https://npm.io/package/@contentstack/cli-command.md) ~1.2.11
- [@contentstack/cli-utilities](https://npm.io/package/@contentstack/cli-utilities.md) ~1.5.1

## Alternatives

- [@salesforce/cli](https://npm.io/package/@salesforce/cli.md) — 389.7K weekly downloads
- [@mintlify/cli](https://npm.io/package/@mintlify/cli.md) — 208.9K weekly downloads
- [@grafana/e2e-selectors](https://npm.io/package/@grafana/e2e-selectors.md) — 128.7K weekly downloads
- [mintlify](https://npm.io/package/mintlify.md) — 112.0K weekly downloads
- [@intlayer/cli](https://npm.io/package/@intlayer/cli.md) — 22.8K weekly downloads

## Recent versions

- 1.8.2 (latest) — 2023-08-29

## README

@contentstack/cli-cm-import

It is Contentstack’s CLI plugin to import content in the stack. To learn how to export and import content in Contentstack, refer to the [Migration guide](https://www.contentstack.com/docs/developers/cli/migration/).

[![License](https://img.shields.io/npm/l/@contentstack/cli)](https://github.com/contentstack/cli/blob/main/LICENSE)

<!-- toc -->
* [Usage](#usage)
* [Commands](#commands)
<!-- tocstop -->

For switching to EU region update the hosts at config/default.js

```js
{
  host:'https://eu-api.contentstack.com/v3',
  cdn: 'https://eu-cdn.contentstack.com/v3',
 ...
}
```

For switching to AZURE-NA region update the hosts at config/default.js

```js
{
  host:'https://azure-na-api.contentstack.com/v3',
  cdn: 'https://azure-na-cdn.contentstack.com/v3'
 ...
}
```

For switching to AZURE-EU region update the hosts at config/default.js

```js
{
  host:'https://azure-eu-api.contentstack.com/v3',
  cdn: 'https://azure-eu-cdn.contentstack.com/v3'
 ...
}
```

# Usage

<!-- usage -->
```sh-session
$ npm install -g cli-cm-import-abhnv
$ csdx COMMAND
running command...
$ csdx (--version)
cli-cm-import-abhnv/1.8.2 linux-x64 node-v18.17.1
$ csdx --help [COMMAND]
USAGE
  $ csdx COMMAND
...
```
<!-- usagestop -->

# Commands

<!-- commands -->
* [`csdx cm:stacks:import [-c <value>] [-k <value>] [-d <value>] [-a <value>] [--module <value>] [--backup-dir <value>] [--branch <value>] [--import-webhook-status disable|current]`](#csdx-cmstacksimport--c-value--k-value--d-value--a-value---module-value---backup-dir-value---branch-value---import-webhook-status-disablecurrent)
* [`csdx cm:stacks:import [-c <value>] [-k <value>] [-d <value>] [-a <value>] [--module <value>] [--backup-dir <value>] [--branch <value>] [--import-webhook-status disable|current]`](#csdx-cmstacksimport--c-value--k-value--d-value--a-value---module-value---backup-dir-value---branch-value---import-webhook-status-disablecurrent-1)

## `csdx cm:stacks:import [-c <value>] [-k <value>] [-d <value>] [-a <value>] [--module <value>] [--backup-dir <value>] [--branch <value>] [--import-webhook-status disable|current]`

Import content from a stack

```
USAGE
  $ csdx cm:stacks:import [-c <value>] [-k <value>] [-d <value>] [-a <value>] [--module <value>] [--backup-dir <value>]
    [--branch <value>] [--import-webhook-status disable|current]

FLAGS
  -B, --branch=<value>              [optional] branch name
  -a, --alias=<value>               alias of the management token
  -b, --backup-dir=<value>          [optional] backup directory name when using specific module
  -c, --config=<value>              [optional] path of config file
  -d, --data-dir=<value>            path and location where data is stored
  -k, --stack-api-key=<value>       API key of the target stack
  -m, --module=<value>              [optional] specific module name
  -y, --yes                         [optional] Override marketplace prompts
  --import-webhook-status=<option>  [default: disable] [optional] Webhook state
                                    <options: disable|current>

DESCRIPTION
  Import content from a stack

ALIASES
  $ csdx cm:import

EXAMPLES
  $ csdx cm:stacks:import --stack-api-key <stack_api_key> --data-dir <path/of/export/destination/dir>

  $ csdx cm:stacks:import --config <path/of/config/dir>

  $ csdx cm:stacks:import --module <single module name>

  $ csdx cm:stacks:import --module <single module name> --backup-dir <backup dir>

  $ csdx cm:stacks:import --alias <management_token_alias>

  $ csdx cm:stacks:import --alias <management_token_alias> --data-dir <path/of/export/destination/dir>

  $ csdx cm:stacks:import --alias <management_token_alias> --config <path/of/config/file>

  $ csdx cm:stacks:import --branch <branch name>  --yes
```

## `csdx cm:stacks:import [-c <value>] [-k <value>] [-d <value>] [-a <value>] [--module <value>] [--backup-dir <value>] [--branch <value>] [--import-webhook-status disable|current]`

Import content from a stack

```
USAGE
  $ csdx cm:stacks:import [-c <value>] [-k <value>] [-d <value>] [-a <value>] [--module <value>] [--backup-dir <value>]
    [--branch <value>] [--import-webhook-status disable|current]

FLAGS
  -B, --branch=<value>              [optional] branch name
  -a, --alias=<value>               alias of the management token
  -b, --backup-dir=<value>          [optional] backup directory name when using specific module
  -c, --config=<value>              [optional] path of config file
  -d, --data-dir=<value>            path and location where data is stored
  -k, --stack-api-key=<value>       API key of the target stack
  -m, --module=<value>              [optional] specific module name
  -y, --yes                         [optional] Override marketplace prompts
  --import-webhook-status=<option>  [default: disable] [optional] Webhook state
                                    <options: disable|current>

DESCRIPTION
  Import content from a stack

ALIASES
  $ csdx cm:import

EXAMPLES
  $ csdx cm:stacks:import --stack-api-key <stack_api_key> --data-dir <path/of/export/destination/dir>

  $ csdx cm:stacks:import --config <path/of/config/dir>

  $ csdx cm:stacks:import --module <single module name>

  $ csdx cm:stacks:import --module <single module name> --backup-dir <backup dir>

  $ csdx cm:stacks:import --alias <management_token_alias>

  $ csdx cm:stacks:import --alias <management_token_alias> --data-dir <path/of/export/destination/dir>

  $ csdx cm:stacks:import --alias <management_token_alias> --config <path/of/config/file>

  $ csdx cm:stacks:import --branch <branch name>  --yes
```

_See code: [src/commands/cm/stacks/import.ts](https://github.com/contentstack/cli/blob/main/packages/contentstack-import/src/commands/cm/stacks/import.ts)_
<!-- commandsstop -->

---
_Source: https://npm.io/package/cli-cm-import-abhnv · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
