Skip to content

CLI Reference

Xellu edited this page Jun 14, 2026 · 6 revisions

https://github.com/xellu/nautica-api/tree/main/nautica/cli

Nautica 3 comes with a built-in CLI for managing your projects

Note: napi is an alias for nautica, and can be used interchangeably

Quick Start

nautica create my-project
cd my-project
nautica run

To set up an existing project:

cd my-project
nautica install
nautica run

Commands

create

  • Usage: nautica create <name> [--demo]

Creates a new Nautica3 project in a new directory with the given name. Generated project tree:

new-project/
├── src/
   └── http/ //feel free to delete if not needed
├── plugins/
├── config/
├── .logs/
├── config.n3
├── package.n3
└── .gitignore

After creating a project, cd into it and run nautica run . to start it.

If ran with --demo flag, the HTTP server will be enabled automatically, and example routes will be created.

install

  • Usage: nautica install [package] (or nautica i [package])

Installs a specified package from the package registry

OR

Checks that all packages are installed, needed config files are present, onInstall() on all registered services and creates any missing configs.

Should be ran after cloning an existing N3 project, or after adding new services.

uninstall

  • Usage: nautica uninstall <package>

Removes a specified package from the project

run

  • Usage: nautica run [path]

Starts a Nautica3 project.


Package

package create

  • Usage: nautica package create <name>

Creates an empty Nautica3 package

package env

  • Usage: nautica package env

Creates a testing environment for your package. If an environment already exists, it'll be re-created.

The env (under .testenv/) is an empty nautica project under the hood, you can install dependencies, and more.

package envinstall

  • Usage: nautica package envinstall

Runs nautica install in the test environment

package envclean

Cleans up the environment by deleting logs and configs

package test

  • Usage: nautica package test

Clones your package into .testenv/plugins/ and starts the testing environment

package publish

  • Usage: nautica package publish

Publishes your package to the package registry. You may be prompted to log in

Don't forget to change the package version before publishing. Duplicates aren't allowed.

package registry

  • Usage: nautica package registry [url]

If a URL is provided, will switch to a different package registry. Otherwise it will list all available registries.

When you switch, package publishing and downloading will only be done from that specific registry.

Clone this wiki locally