BCMS CLI

BCMS CLI helps you with things like scaffolding BCMS projects. It can help you quickly create anything BCMS-related. From plugins, over functions, to creating the whole codebase in your framework of choice.

Install

To install BCMS CLI globally, run npm install @becomes/cms-cli -g. After that, you should be able to run any of the following commands.

Learning the CLI

You will find a lot of commands and options on this page. Rest assured, you will only need to know and use a small fraction in a typical day.

For new users, the recommended learning path is to first go through BCMS Quickstart and Integrations. There you will learn the commands while building a sample app. Then, review the rest of the commants here.

The CLI comes with a help system too. At any point, if you're not sure what a command does and what its options are, you can add --help to the command and press enter to find out more.


--plugin <command>

Plugin

Plugin options are for when you want to create a BCMS Plugin.

  • Name
    create
    Type
    Description

    Create new plugin project

  • Name
    bundle
    Type
    Description

    Prepare plugin for deployment

  • Name
    deploy
    Type
    Description

    Deploy plugin to your BCMS instance

Example command

bcms --plugin create

Read more about creating BCMS plugins.


--function <name> <options>

Function

Function options are for when you want to create a BCMS Function.

  • Name
    --create
    Type
    boolean
    Description

    Create a function

  • Name
    --bundle
    Type
    boolean
    Description

    Make a function public

Example command

bcms --function myFunction --create

Read more about creating BCMS functions.


--login <options>

Login

Login options are for when you want to log in to a BCMS instance.

  • Name
    otp
    Type
    string
    Description

    Use a specified OTP for login

  • Name
    terminal-login
    Type
    boolean
    Description

    Prompt login in a terminal session

Example command

bcms --login terminal-login

Log out

--logout Sign out of BCMS Cloud account.

Example command

bcms --logout

--cms <command>

CMS

CMS options are for when you want to interact with a BCMS instance.

  • Name
    create
    Type
    Description

    Create a new BCMS project

  • Name
    bundle
    Type
    Description

    Prepare project for deployment

  • Name
    deploy
    Type
    Description

    Deploy the project to the BCMS Cloud

  • Name
    clone
    Type
    Description

    Create a starter project and get instance data if available

  • Name
    pull
    Type
    Description

    Pull functions, events, jobs and plugins for the current instance

  • Name
    backup
    Type
    Description

    Create local backup of the BCMS

Example command

bcms --cms create

--instance <id> <options>

Instance

Instance options are for when you want to install an instance on the current server.

  • Name
    --install
    Type
    Description

    Install instance on the current server

Example command

bcms --instance yourBcmsInstanceId install

--most <command>

Most

Most commands are for when you want to work with data from BCMS instance

  • Name
    pull-content
    Type
    Description

    Pull content from the BCMS instance

  • Name
    pull-media
    Type
    Description

    Pull media from the BCMS

  • Name
    pull-types
    Type
    Description

    Create types based on the data from the BCMS instance

  • Name
    all
    Type
    Description

    Run all commands

Example command

bcms pull-content

--cloudOrigin <url>

CloudOrigin

CloudOrigin is for when you want to set an origin of the BCMS Cloud for running commands

Example command

bcms --cloudOrigin your-bcms-url.yourbcms.com

--website <command>

Website

Website commands are for when you want to quickstart a BCMS project

  • Name
    --create
    Type
    Description

    Starts an interactive terminal guide for setting up a framework with the BCMS integration

Example command

bcms --website --create

--help

Help

Help command lists our all available BCMS CLI commands

Example command

bcms --help