Deploy

Deploy and Automation CLI

The Zenifra CLI lets you list projects, create resources, and trigger deploys from terminals, scripts, and pipelines.

This page summarizes deploy and automation commands. For the full tool reference, see Zenifra CLI.

Use the CLI when you want to operate Zenifra without opening the console: create a project, inspect plan catalogs, list resources, trigger deploys, and follow builds.

Quick start

npm install -g @zenifra/cli
zenifra auth login
zenifra projects --type http --page 1 --limit 15
zenifra create project
zenifra deploy --project <project-id> --branch main
zenifra deploy watch --project <project-id> --build <build-id>

To see all available commands:

zenifra --help
zenifra help create project

Authentication

User login

Use user login to navigate between organizations:

zenifra auth login
zenifra orgs
zenifra org set

This mode is intended for interactive terminal use.

API key for automation

For CI/CD and server-side jobs, create an organization API key and use:

export ZENIFRA_API_KEY=znf_your_key
zenifra projects --type http --page 1 --limit 15
zenifra deploy --project <project-id> --branch main

You can also save the key in the local session:

zenifra auth api-key --key znf_your_key

API keys already carry their linked organization. Automation commands therefore do not require org set.

Create a project from the terminal

Run zenifra create project without flags when you want to follow the interactive wizard. It asks for the required fields, shows examples, and makes explicit which values must be provided.

$ zenifra create project

Zenifra create project

? Project name: app-api
? Description: Product main API
? Project type: http
? Plan: free
? Payment mode: hourly
? Deploy source: github
? Repository owner: my-org
? Repository name: app-api
? Branch: main
? Runtime: nodejs
? Runtime version: 24
? Auto-deploy: yes
? Start command: npm start
? Build command: npm run build
? HTTP port: 3000
? Instances: 1
? Persistent storage: no
? Environment variables: yes
? Variable name: NODE_ENV
? Variable value: production
? Add another item? no

Summary
  project: app-api | plan: free | payment: hourly
  github: my-org/app-api@main | runtime nodejs@24
  port: 3000 | instances: 1

Field    Value
-------  --------------------------------------
Project  507f1f77bcf86cd799439012
Domain   https://app-api.client.zenifra.com

The command above is a simulated flow. Real values should match your repository, plan, port, runtime, and variables.

Common examples

List HTTP projects:

zenifra projects --type http --page 1 --limit 15

Project listing is paginated by default with 15 items per page. Use --page <n> to navigate; use --limit <n> when automation needs a different page size.

Create a project from a configuration file:

zenifra create project \
  --name app-api \
  --plan free \
  --payment-mode hourly \
  --config @http-project.json

Trigger a deploy:

zenifra deploy --project <project-id> --branch main

Watch a build:

zenifra deploy watch --project <project-id> --build <build-id>

Inspect plans before creating:

zenifra plans --type http

Security

  • use ZENIFRA_API_KEY in CI provider secrets;
  • configure IP allowlists when the runner has a fixed IP;
  • grant only the required permissions;
  • rotate and revoke old keys.

Next steps