CLI Setup

Install and configure the DevOur CLI to manage your projects from the command line.

Prerequisites

Installation

Install the DevOur CLI globally using npm:

npm install -g @devourapp/cli

Or using yarn:

yarn global add @devourapp/cli

Verify the installation:

devour

Get Your API Key

The CLI uses API keys for authentication. Generate one from your DevOur dashboard:

  1. Log in to your DevOur account
  2. Click your profile icon in the top navigation
  3. Select API Keys from the dropdown menu
  4. Enter a friendly name for your key (e.g., "My Laptop")
  5. Click Create API Key
  6. Copy the generated key

Keep your API key secure. Never share it or commit it to version control.

Configure the CLI

Run the setup command and paste your API key when prompted:

devour setup-key

The CLI stores your key securely in your system's user configuration directory.

Verify Setup

List your projects to confirm everything works:

devour ls

You should see a list of your DevOur projects with their IDs and names.

Basic Commands

List Projects

devour ls

Download a Project

devour fetch <projectId>

Replace <projectId> with the ID shown in the project list. The project will be extracted to your current directory.

Create a New Project

devour create

Follow the interactive prompts or provide a project name directly:

devour create "My New Project"

Remove API Key

devour logout

Get Help

devour --help
devour help <command>

After Downloading a Project

Once you download a project, navigate to its directory and install dependencies:

cd your-project-name
yarn install
yarn dev

Troubleshooting

"API key is invalid": Verify your key in the DevOur dashboard. Keys are 64 characters long. Use devour setup-key to reconfigure.

"Cannot find module" errors: Ensure Node.js 20+ is installed and the CLI was installed globally.

"Project not found": Check that the project ID exists in your account with devour ls.

Permission errors during download: Ensure you have write permissions in the target directory.

Next Steps

After setting up the CLI, you can manage your projects entirely from the command line. Use devour --help to explore all available commands.