> ## Documentation Index
> Fetch the complete documentation index at: https://docs.jelou.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# CLI

> Complete reference for the Jelou Functions CLI: all commands, flags, and environment variables.

## Installation

```bash theme={null}
npm install -g @jelou/cli
jelou --version
```

## Authentication

| Command                    | Description                                               |
| -------------------------- | --------------------------------------------------------- |
| `jelou login`              | Authenticate with PAT or API key (`--token`, `--profile`) |
| `jelou logout`             | Remove credentials (`--all`, `--profile`)                 |
| `jelou whoami`             | Show current identity                                     |
| `jelou auth list`          | List saved profiles                                       |
| `jelou auth switch [name]` | Switch active profile                                     |
| `jelou auth remove <name>` | Remove a profile (`-y`)                                   |

## Projects

| Command                | Description                                                        |
| ---------------------- | ------------------------------------------------------------------ |
| `jelou functions init` | Scaffold a new function project (`--slug`, `--mode`)               |
| `jelou functions dev`  | Local dev server with hot reload (`--port`, `--env`, `--no-watch`) |

## Deployment

| Command                                            | Description                                       |
| -------------------------------------------------- | ------------------------------------------------- |
| `jelou functions deploy`                           | Deploy to production (`--no-confirm`, `--follow`) |
| `jelou functions rollback [slug] [id]`             | Revert to a previous deployment                   |
| `jelou functions deployments list [slug]`          | List deployment history                           |
| `jelou functions deployments info <slug> <id>`     | Deployment details                                |
| `jelou functions deployments download <slug> <id>` | Download artifact (`-o`)                          |

## Functions

| Command                         | Description                                   |
| ------------------------------- | --------------------------------------------- |
| `jelou functions list`          | List all functions                            |
| `jelou functions info <slug>`   | Show function details                         |
| `jelou functions create`        | Create a remote function (`--slug`, `--name`) |
| `jelou functions delete <slug>` | Delete a function (`-y`)                      |

## Secrets

| Command                             | Description                                     |
| ----------------------------------- | ----------------------------------------------- |
| `jelou secrets list <slug>`         | List secrets                                    |
| `jelou secrets set <slug>`          | Set secrets (inline, `--from-env`, interactive) |
| `jelou secrets delete <slug> <key>` | Delete a secret                                 |

## Tokens

| Command                           | Description             |
| --------------------------------- | ----------------------- |
| `jelou tokens list [slug]`        | List runtime tokens     |
| `jelou tokens create [slug]`      | Create token (`--name`) |
| `jelou tokens revoke <slug> <id>` | Revoke token (`-y`)     |

## Logs

| Command                                 | Description                                 |
| --------------------------------------- | ------------------------------------------- |
| `jelou functions logs [slug]`           | Stream live logs (default)                  |
| `jelou functions logs [slug] --history` | Fetch historical logs                       |
| `jelou functions cron list [slug]`      | List cron schedules                         |
| `jelou functions cron logs [slug]`      | Cron execution logs (`--state`, `--cursor`) |

## Other

| Command               | Description                                     |
| --------------------- | ----------------------------------------------- |
| `jelou skill install` | Install AI agent workflow (`--global`, `--api`) |

## Global flags

| Flag               | Description                 |
| ------------------ | --------------------------- |
| `--json`           | JSON output to stdout       |
| `--no-input`       | Disable interactive prompts |
| `--profile <name>` | Use a specific profile      |

## Environment variables

| Variable         | Description                          |
| ---------------- | ------------------------------------ |
| `JELOU_TOKEN`    | Auth token (no `jelou login` needed) |
| `JELOU_NO_INPUT` | `1` for non-interactive mode         |
| `CI`             | `true` for non-interactive mode      |
| `JELOU_PROFILE`  | Default profile                      |

<Tip>
  In CI pipelines, use `JELOU_TOKEN` and `--json` for parseable output:

  ```bash theme={null}
  export JELOU_TOKEN=${{ secrets.JELOU_TOKEN }}
  jelou functions deploy --no-confirm --json | jq -r '.data.url'
  ```
</Tip>
