apps-cli for monday code
The monday-code CLI enables you to interact with monday-code using a set of predefined commands. It currently contains 12 different commands that you can implement to execute various operations:
mapps init
mapps tunnel:create
mapps app-version:list
mapps app:list
mapps autocomplete [SHELL] [-r]
mapps code:env
mapps code:logs
mapps code:push
mapps code:status
mapps help [COMMANDS]
mapps storage:search
mapps storage: export
This document will walk through each available command, its flags, and relevant code samples. You can also access the CLI here.
Please note that in order to use the CLI, you must first set your API token using the mapps init
command.
Usage
$ npm install -g @mondaycom/apps-cli
$ mapps COMMAND
running command...
$ mapps (--version)
@mondaycom/apps-cli/0.1.14 linux-x64 node-v18.12.1
$ mapps --help [COMMAND]
USAGE
$ mapps COMMAND
...
Global flags
Global flag | Description |
---|---|
--print-command | Prints the command that was executed (optional). |
--verbose | Prints advanced logs (optional). |
Commands
mapps init
mapps init
The mapps init
command initializes the mapps config file (i.e., ".mappsrc"). You can use this command to add your API token to access the CLI.
Flags
Long flag | Short flag | Description |
---|---|---|
--local | -l | Creates the configuration file locally in the current project working directory. Use this if you are using different access tokens for each of your projects. |
--token | -t | The API access token. |
Example
$ mapps init -t <SECRET_TOKEN>
mapps tunnel:create
mapps tunnel:create
The mapps tunnel:create
command creates a networking tunnel to publicly expose code running on the local machine.
Flags
Long flag | Short flag | Description |
---|---|---|
--appId | -a | The unique identifier of the app to get a unique tunnel domain for. |
--port | -p | The port to forward tunnel traffic to. The default is 8080. |
Example
$ mapps tunnel:create -p 3000 -a 123456789
mapps app-version:list
mapps app-version:list
The mapps app-version:list
command lists all versions for a particular app.
Flags
Long flag | Short flag | Description |
---|---|---|
--appId | -i | The app's unique identifier. |
Example
$ mapps app-version:list -i 1234567890
mapps app:list
mapps app:list
The mapps app:list
command lists all apps for a specific user.
Example
$ mapps app:list
mapps autocomplete [SHELL]
mapps autocomplete [SHELL]
The mapps autocomplete [SHELL]
command displays the autocomplete installation instructions.
Arguments
Argument | Description |
---|---|
SHELL | The shell type: zsh , bash , or powershell . |
Flags
Long flag | Short flag | Description |
---|---|---|
--refresh-cache | -r | Refreshes the cache (ignores displaying instructions). |
Example
$ mapps autocomplete bash
mapps code:env
mapps code:env
The mapps code:env
command manages environment variables for your app hosted on monday-code.
Flags
Long flag | Short flag | Description |
---|---|---|
--appId | -i | The app's unique identifier. |
--key | -k | The variable key (required for set and delete ). |
--mode | -m | The management mode: list-keys , set , ordelete . |
--value | -v | The variable value (required for set ). |
Example
$ mapps code:env -m set -k <KEY> -v <VALUE>
mapps code:logs
mapps code:logs
The mapps code:logs
command streams logs.
Flags
Long flag | Short flag | Description |
---|---|---|
--logsEndDate | -e | The log's end date (e.g. MM/DD/YYYY HH:mm). Only supported for history events. |
--logsStartDate | -f | The log's start date (e.g. MM/DD/YYYY HH:mm). Only supported for history events. |
--appVersionId | -i | The app's version ID. |
--logSearchFromText | -r | The regex text to search the logs for. Only supported for live events. |
--eventSource | -s | The log's source: live (live events) or history (past events). |
--logsType | -t | The log's type: http (http events) or console (stdout). |
Example
$ mapps code:logs -i <APP_VERSION_ID> -t <LOGS_TYPE>
mapps code:push
mapps code:push
The mapps code:push
command pushes your project to be hosted on monday-code.
Flags
Long flag | Short flag | Description |
---|---|---|
--directoryPath | -d | The project's directory path. If excluded, the working directory will be used. |
--appVersionId | -i | The app's version ID. |
Example
$ mapps code:push -d <PROJECT DIRECTORY PATH> -i <APP_VERSION_ID_TO_PUSH>
mapps code:status
mapps code:status
The mapps code:status
command provides the status of a specific project hosted on monday-code.
Flags
Long flag | Short flag | Description |
---|---|---|
--appVersionId | -i | The app's version ID. |
Example
$ mapps code:status -i <APP_VERSION_ID>
mapps help [COMMANDS]
mapps help [COMMANDS]
The mapps help [COMMANDS]
command displays help for mapps.
Arguments
Argument | Description |
---|---|
COMMANDS | The command to show help for. |
Flags
Long flag | Short flag | Description |
---|---|---|
--nested-commands | -n | Includes all nested commands in the output. |
Example
$ mapps help [COMMANDS] [-n]
mapps storage:search
mapps storage:search
The mapps storage:search
command searches keys and values stored on monday for a specific customer account.
Long flag | Short flag | Description |
---|---|---|
--appId | -a | The app to retrieve the key for. |
--clientAccountId | -c | The client account number. |
--term | -t | The term to search for. |
Example
$ mapps storage:search
// or
$ mapps storage:search -a 1234567890 -c 9876543210 -t keyword
mapps storage:export
mapps storage:export
The mapps storage:export
command exports all keys and values stored on monday for a specific customer account
Long flag | Short flag | Description |
---|---|---|
--appId | -a | The app to retrieve the key for. |
--clientAccountId | -c | The client account number. |
--fileDirectory | -d | The file path. Optional. If not used, it will take your current folder. |
--fileFormat | -f | The file format: CSV or JSON. Optional, the default is JSON. |
Example
$ mapps storage:export
// or
$ mapps storage:export -a 12345678790 -c 9876543210
Updated 4 days ago