> For the complete documentation index, see [llms.txt](https://developer.celigo.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://developer.celigo.com/cli/using-the-cli/troubleshooting.md). Agents can also search and read this documentation through its [MCP server](https://developer.celigo.com/~gitbook/mcp).

# Troubleshooting

Common CLI failure modes, in rough order of how often they come up.

## `celigo: command not found`

Your shell can't find the `celigo` command. Either the CLI isn't installed, or the folder npm installs commands into isn't on your `PATH`. Each shell words the error differently:

| Shell                                    | Error                                                                                            |
| ---------------------------------------- | ------------------------------------------------------------------------------------------------ |
| bash or zsh: macOS, Linux, WSL, Git Bash | `celigo: command not found`                                                                      |
| PowerShell                               | `The term 'celigo' is not recognized …`                                                          |
| Command Prompt (`cmd.exe`)               | `'celigo' is not recognized as an internal or external command, operable program or batch file.` |

A coding agent reports the error of the shell it runs commands in. On Windows, an agent that runs commands in Git Bash reports `celigo: command not found`.

### Windows

Run these steps in PowerShell. They call `npm.cmd` rather than `npm`, because `npm.cmd` runs under any PowerShell execution policy.

1. Close every terminal window, and quit every app you ran `celigo` from, such as VS Code, Cursor, Windows Terminal, or a coding agent.

   Each program reads `PATH` when it starts, and a terminal inside an app uses the app's copy. A window that was already open when Node.js was installed, or when your `PATH` changed, can't find `celigo`.
2. Open a new PowerShell window and run `celigo --version`.

   If the version prints, the CLI is ready. If PowerShell says that `celigo.ps1` cannot be loaded, the CLI was found: see [`running scripts is disabled on this system`](#running-scripts-is-disabled-on-this-system).
3. Check the Node.js version:

   ```powershell
   node --version
   ```

   It must print `v22.12.0` or later. If `node` isn't recognized or the version is older, install Node.js with the Windows installer from [nodejs.org](https://nodejs.org/en/download), keeping **Add to PATH** selected. Then repeat steps 1 and 2.
4. Check that the CLI is installed:

   ```powershell
   npm.cmd ls -g @celigo/celigo-cli
   ```

   The output lists `@celigo/celigo-cli@<version>`. If it shows `(empty)`, run `npm.cmd install -g @celigo/celigo-cli`, then repeat steps 1 and 2.
5. Print the folder npm installs commands into:

   ```powershell
   npm.cmd prefix -g
   ```

   It's usually `C:\Users\<you>\AppData\Roaming\npm`. npm puts three files for the CLI there: `celigo.cmd`, `celigo.ps1`, and `celigo`.
6. Run the CLI from that folder:

   ```powershell
   & "$(npm.cmd prefix -g)\celigo.cmd" --version
   ```

   If it prints a version, the CLI works, and only your `PATH` is missing the folder.
7. Add the folder from step 5 to your user `PATH`:

   1. Press **Windows+R**, enter `rundll32 sysdm.cpl,EditEnvironmentVariables`, and select **OK**. You can also search the Start menu for **Edit environment variables for your account**.
   2. Under **User variables**, select **Path**, and then select **Edit**.
   3. Select **New**, paste the folder, and select **OK**.
   4. Select **OK** to close **Environment Variables**.

   Changing your user `PATH` needs no administrator rights. The Node.js installer adds this folder only for the Windows account that ran it. If IT or another administrator account installed Node.js, the folder can be missing from yours.

   **Don't add the folder with `setx PATH`.** `setx` cuts off any value longer than 1,024 characters, and `setx PATH "%PATH%;…"` copies the system `PATH` into your user `PATH`.
8. Repeat steps 1 and 2. If `celigo` still isn't found, sign out of Windows and sign in again.

Other setups on Windows:

* **Git Bash** reads the Windows `PATH`, so the steps above fix it too.
* **WSL** runs a separate Linux system with its own Node.js and npm. Install Node.js 22.12 or later and the CLI inside it, then follow the macOS and Linux steps there. Its profiles are separate as well: WSL's `~/.celigo` isn't `%USERPROFILE%\.celigo`.
* **nvm-windows and fnm** keep separate global packages for each Node.js version. After `nvm use` or `fnm use` switches the version, install the CLI again.
* **If you can't change `PATH`**, run each command through npx, which needs only Node.js: `npx --yes @celigo/celigo-cli <command>`.

### macOS and Linux

1. Check that the CLI is installed:

   ```bash
   npm ls -g @celigo/celigo-cli
   ```

   If it shows `(empty)`, run `npm install -g @celigo/celigo-cli`.
2. Print npm's global prefix. Commands live in `<prefix>/bin`:

   ```bash
   npm prefix -g
   ```
3. Add `<prefix>/bin` to `PATH` in your shell's startup file:

   ```bash
   echo 'export PATH="$(npm prefix -g)/bin:$PATH"' >> ~/.zshrc    # zsh, the macOS default
   echo 'export PATH="$(npm prefix -g)/bin:$PATH"' >> ~/.bashrc   # bash
   ```
4. Open a new terminal and run `celigo --version`.

Or install Node.js with a version manager, such as nvm or Volta, that manages `PATH` for you.

## `running scripts is disabled on this system`

```
celigo : File C:\Users\<you>\AppData\Roaming\npm\celigo.ps1 cannot be loaded because running scripts is disabled on this system.
```

PowerShell found the CLI, but its execution policy blocks `celigo.ps1`, the PowerShell wrapper npm installs for the CLI. The same policy blocks `npm.ps1` and `npx.ps1`, so `npm` can fail the same way. On Windows 10 and 11, Windows PowerShell uses the `Restricted` policy until a policy is set, and `Restricted` runs no scripts. Under the `AllSigned` policy, the error says that `celigo.ps1` is not digitally signed.

Run the `.cmd` wrappers instead. The execution policy applies only to PowerShell scripts, so these run under any policy:

```powershell
npm.cmd install -g @celigo/celigo-cli
celigo.cmd --version
```

`celigo.cmd` takes the same arguments as `celigo`. In Command Prompt (`cmd.exe`), `celigo` already runs `celigo.cmd`.

To run `celigo` itself in PowerShell, allow local scripts for your account.

> ⚠️ **This lets PowerShell run unsigned scripts for your account.** `RemoteSigned` runs scripts created on this computer without a signature, and still requires one on scripts downloaded from the internet. Check your organization's policy before you change it.

```powershell
Set-ExecutionPolicy -Scope CurrentUser -ExecutionPolicy RemoteSigned
```

When Group Policy sets the execution policy, your setting has no effect. Use the `.cmd` wrappers instead.

## `401 Unauthorized`

With an API token, the error reads:

```
(401): Authentication failed. Check your API token with `celigo config show`.
```

* Token is missing, expired, or revoked.
* You're pointing at the wrong region. A token authenticates only against its own region's base URL.

Inspect the active config:

```bash
celigo config show
celigo profile list
```

Rotate the token with `celigo config set api_token <new>` and retry. See [Authenticate](https://developer.celigo.com/cli/getting-started/authenticate.md).

A profile signed in with `celigo login` holds an OAuth session instead, and `config set api_token` does not apply to it (a profile holds one credential). Since celigo-cli 2026.10.1 the CLI renews the session once after a `401` — or after a `400` that refuses the token itself, which is how the platform can answer a revoked session — and reports the failure only when that does not help:

```
(401): Session expired for profile 'acme-corp-production'. Run: celigo login --profile acme-corp-production
(401): The API refused the session of profile 'acme-corp-production' even after the CLI renewed it: Bearer Authentication Failed. The session is current, so signing in again is unlikely to help — check that this user can still reach the account and environment the profile is for.
```

The first means the session can no longer be renewed: sign in again with the command it names. The second means the session is current and the API refuses it for another reason, such as the user's access to the account. For the other session messages, see [Messages about a `celigo login` session](#messages-about-a-celigo-login-session).

A `401` can also be a permission answer. The platform accepted the credential, and this request is closed to it:

```
(401): Not permitted: You don't have the required permissions to perform the action.
Hint: The credential was accepted and this request is closed to it — for example, to an API token with a custom scope — so sending it again gets the same answer. celigo profile whoami shows which credential this is.
```

The credential is valid, so sending the request again gets the same answer. Run `celigo profile whoami` to see which credential the profile uses. Since celigo-cli 2026.11.2 the CLI reports this answer as the platform words it. Earlier releases reported it as `Authentication failed`, and a signed-in session renewed its token once for it.

`celigo pull` names a listing that is closed this way by its folder, `skipped on-premise-agents: (401): Not permitted: …`, and prints the hint once below its skipped lines. See [What a pull warns about](https://developer.celigo.com/cli/local-tree/pull.md#what-a-pull-warns-about).

## `No credentials configured`

```
No credentials configured.
Run: celigo login, set CELIGO_API_TOKEN, or run: celigo config set api_token <token>
```

No credential reached the command: no `--token`, no `CELIGO_API_TOKEN`, and the profile holds neither an API token nor a sign-in. Sign in with `celigo login`, or give the CLI an API token. When `--profile` or `CELIGO_PROFILE` selected the profile, or the active profile exists, both commands in the message add `--profile <name>`, so the credential lands on that profile. See [Authenticate](https://developer.celigo.com/cli/getting-started/authenticate.md).

## `The --token value is empty`

```
The --token value is empty. Provide a token (this usually means a shell variable was unset), or drop --token to use CELIGO_API_TOKEN or the profile's credential.
```

The command line passed `--token` with a blank value, usually `--token "$TOKEN"` with the variable unset. Since celigo-cli 2026.11.2 the CLI refuses it before any command runs, and a blank `--base-url` the same way (`The --base-url value is empty. …`). Set the variable, or drop the flag to use the fallback that the message names.

Earlier releases read a blank value as the flag left out. The command then ran, writes included, with `CELIGO_API_TOKEN` or the profile's credential, against the account that credential reaches.

## Messages about a `celigo login` session

A profile signed in with `celigo login` holds an OAuth session, which the CLI renews on its own. Since celigo-cli 2026.10.1 these messages say what happened to it:

```
(401): Could not renew the session for profile 'acme-corp-production': Timed out waiting for the OAuth refresh lock. Retry the command. The sign-in is kept; retry the command, and sign in again (celigo login --profile acme-corp-production) only if this persists.
```

The session needed renewing and the renewal could not run: the authorization server was down or unreachable, or another `celigo` process was renewing the same session. The session is still stored, so retry the command first.

```
Profile 'acme-corp-production' is signed out — its session was cleared while this command ran. Run: celigo login --profile acme-corp-production
```

A `celigo logout` ran in another terminal while this command was working. Sign in again if you still need the profile.

```
Profile 'acme-corp-production' no longer exists — it was renamed or deleted while this command ran, taking its session with it. Run the command again under the profile's current name (celigo profile list).
```

A `celigo profile rename` or `delete` ran while this command was working. Use the name `celigo profile list` shows; signing in under the old name would create a second profile.

```
Profile 'acme-corp-production' is signed in to api.integrator.io, and its OAuth session is sent to no other host — but --base-url points this command at api.eu.integrator.io. Drop --base-url to use the sign-in, or reach api.eu.integrator.io with a profile signed in there (celigo login --profile <name> --base-url https://api.eu.integrator.io) or an API token for it (--token / CELIGO_API_TOKEN).
```

A session is sent only to the host it was issued for, and the CLI refuses the command before any request. The message names what pointed it elsewhere — `--base-url`, `CELIGO_BASE_URL`, `CELIGO_TARGET_BASE_URL` for a promote target, or the profile's own `base_url` — and how to undo it. API tokens are not held to this rule.

```
Profile 'acme-corp-production' holds both an API token and an OAuth sign-in, and a profile holds one credential — the two may be different accounts, so neither is used. To keep the API token: celigo logout --profile acme-corp-production. To keep the sign-in: celigo config unset api_token --profile acme-corp-production.
```

A profile holds one credential, so the CLI uses neither until you keep one with the command the message names. Only a pre-release build of `celigo login` could leave both behind.

## `Profile 'x' does not exist`

```
Profile 'x' does not exist. Available: prod, eu (run 'celigo profile list').
```

The profile NAME is wrong, not the token. Since celigo-cli 2026.9.1 a `--profile` flag or a `CELIGO_PROFILE` value that names no profile fails before any request — even when `CELIGO_API_TOKEN` or `--token` would supply a token — instead of resolving to an empty profile and failing later.

* Pick a name from `celigo profile list`.
* Check the session: `echo $CELIGO_PROFILE`. A stale value bound in a shell rc file or an agent harness selects the wrong profile for every command.
* Do **not** write a token in response. `celigo config set api_token <token> --profile x` creates the misspelled profile (or overwrites another profile's token) — that is the failure chain this check exists to stop.

The `profile`, `config`, `skills`, and `login` commands and the offline tree verbs (`status`, `lint`, `resolve`) do not check — `profile whoami` does — so `celigo config set api_token <token> --profile <new>` and `celigo login --profile <new>` still bootstrap a profile you mean to create.

An empty value — `--profile ""`, usually a shell variable that was never set — is refused before any command runs (since celigo-cli 2026.10.1): `The --profile value is empty. Provide a profile name (this usually means a shell variable was unset), or drop --profile to use the active profile.`

## Which account a write targets

Every command that writes to the account prints the target on stderr before the write, since celigo-cli 2026.9.1:

```
celigo: profile 'acme-sandbox' → api.integrator.io
```

Confirmation prompts carry the same label (`[profile 'acme-sandbox' → api.integrator.io] Delete flow 123? [y/N]`). Read that line — or run `celigo profile whoami` — before the first mutating command of a session. If it names the wrong account, stop: the machine-wide active profile may have been switched by `celigo profile use` in another terminal. Bind the session with `export CELIGO_PROFILE=<name>`. See [Profiles & regions](https://developer.celigo.com/cli/getting-started/profiles.md#selecting-a-profile).

Since celigo-cli 2026.9.5 the line also appears on reads when the session is pinned to a profile other than the machine's active one, with the divergence spelled out:

```
celigo: profile 'acme-sandbox' → api.integrator.io (pinned with --profile; the active profile is 'acme-prod')
```

(`pinned with CELIGO_PROFILE` when the variable selected it.) That parenthesis means someone ran `celigo profile use acme-prod` and this session's `--profile` or `CELIGO_PROFILE` did not follow — a `profile use` never redirects a pinned session. Decide which account is meant: drop the pin (or `unset CELIGO_PROFILE`) to work on the active profile, or keep it if the pinned profile is the one you want. An agent that sees the line should ask the person before its next command. A pin that names the active profile prints nothing extra. See [A profile pinned away from the active one](https://developer.celigo.com/cli/getting-started/profiles.md#a-profile-pinned-away-from-the-active-one).

## `…is not the active profile… (profile_pin_policy = strict)`

```
Profile 'acme-sandbox' (pinned with --profile) is not the active profile ('acme-prod'), and this machine refuses pinned profiles that differ from it (profile_pin_policy = strict). Drop --profile to target 'acme-prod'. If 'acme-sandbox' is the account you mean, a person switches to it with 'celigo profile use acme-sandbox'; an agent must not switch profiles or change profile_pin_policy to get past this refusal.
```

This machine has `profile_pin_policy = strict` (since celigo-cli 2026.9.5), so a `--profile` or `CELIGO_PROFILE` value that differs from the active profile is refused before any request, exit `1`; `celigo profile use` is the only way an account gets selected here. The message says `Unset CELIGO_PROFILE` when the variable set the pin, and `(profile_pin_policy = strict, managed by /etc/celigo/policy.json)` when the managed policy file forces the policy. Two ways out, both the person's:

* Drop `--profile` (or `unset CELIGO_PROFILE`) and work on the active profile, `acme-prod` here.
* If the pinned profile is the account you mean, a **person** switches the machine to it: `celigo profile use acme-sandbox`.

Never change the policy to get past it — `celigo config set profile_pin_policy allow` is itself refused off a terminal and asks a person to type `allow` on one; when the managed policy file forces `strict`, it cannot be changed with `config set` at all. An agent must not run `profile use` or touch `profile_pin_policy` in response to this refusal: the setting exists to keep that decision with the person at the machine. `profile whoami --profile acme-sandbox` still answers, so "which account is this?" can be checked first. See [Refusing a pinned profile](https://developer.celigo.com/cli/getting-started/profiles.md#refusing-a-pinned-profile).

## `Confirmation needs a person, and stdin is not a terminal`

```
[profile 'acme-sandbox' → api.integrator.io] Delete flow 5f83a9b2c7d3e8f1a2b3c4d5?
Confirmation needs a person, and stdin is not a terminal. An agent must not answer for the person: ask them in the conversation, and re-run with --yes only once they have approved this exact command. Scripts and CI pipelines pass --yes.
```

A command with a `[y/N]` prompt — `delete`, the purge and cancel verbs, the `rotate-token` verbs, `push --prune`, `promote --prune` — ran with stdin that is not a terminal (a pipe, a CI step, an agent's shell), so the prompt could not be asked. Nothing was changed; the exit code is `1`. What to do depends on who is running it:

* **A script or CI pipeline** passes `--yes` (`-y`) on that command, deliberately. See [Confirmation prompts in scripts and CI](https://developer.celigo.com/cli/using-the-cli/scripting.md#confirmation-prompts-in-scripts-and-ci).
* **An agent** does not add `--yes` on its own. The answer belongs to the person: quote the exact command back in the conversation, wait for their approval, then re-run it with `--yes`.
* **A person** at a terminal whose stdin is redirected runs the command again with stdin attached, or passes `--yes`.

Since celigo-cli 2026.9.6. The earlier message, `Confirmation requires a TTY; pass --yes to proceed.`, was an instruction an agent could follow on its own, so the refusal now sends the question to the person instead. The check is on stdin being a TTY, not on who is typing: it states the rule, it does not enforce it.

## `… holds the error output of a failed 'celigo …'`

```
Stdin holds the error output of a failed 'celigo flows get', not a body, so nothing was sent. That command failed with: (404): Not found: …
```

The command read a body, and the body is the error document of another `celigo` command that failed. Since celigo-cli 2026.11.2, a command that fails in JSON format, with stdout not a terminal, prints its error on stdout as one JSON document, so a pipeline such as `celigo flows get <id> | celigo flows update <id>` hands that document to its second command. The CLI refuses it wherever it reads one, and sends nothing: a `--file` body reads `File '<path>' holds the error output …`, and a `set` value reads `… not a value for <field>, so nothing was written.`

The first command's own error follows `That command failed with:`. Fix that failure, and check the exit status of a command before you use its output; see [Check the exit status before you use the output](https://developer.celigo.com/cli/using-the-cli/scripting.md#check-the-exit-status-before-you-use-the-output). For a tree file that holds such a document, `push` and `promote` refuse the file at plan time; `celigo pull --force <path>` restores a tracked document.

## `… cannot be read as text`

```
The file 'body.json' cannot be read as text: line 1 holds bytes that are not UTF-8 — a file saved in another encoding, such as Windows-1252. Reopen it in the encoding it was saved in and save it as UTF-8 — a tool that opens it as UTF-8 and saves it again writes U+FFFD for each such byte, valid UTF-8.
```

Since celigo-cli 2026.11.2, a file that a command reads — a `--file` body, a `file://` value in `set`, a body on stdin — must be UTF-8, with or without a byte-order mark, or UTF-16 with one. Windows PowerShell 5.1's `>` and `Out-File` write UTF-16 with a byte-order mark, which the CLI reads. A file in another encoding is refused before any request. So is UTF-16 without a byte-order mark, which reads `it holds NUL bytes — UTF-16 without a byte-order mark, or not a text file`.

Save the file again as UTF-8 from the editor or tool that wrote it. Earlier releases read such a file as UTF-8, and sent U+FFFD in place of the bytes that are not UTF-8.

The local tree's own files are held to UTF-8. A `.celigoignore` in another encoding stops every tree verb before any request, with `.celigoignore cannot be read as UTF-8 text: …`; see [`.celigoignore`](https://developer.celigo.com/cli/local-tree.md#celigoignore).

## `403 Forbidden`

Token is valid but lacks the capability the request needs. Either broaden the token's scope in the UI, or switch to a profile whose token has admin access. A profile signed in with `celigo login` acts with the signed-in user's own permissions, like a personal access token.

Since celigo-cli 2026.10.2, a `403` from a resource's state route says which types keep state. The route answers `invalid_ref` for every type but exports, imports, and integrations, whatever the id — for a flow's state read through `celigo platform get`, for example:

```
(403): Forbidden: State not available for the given model.
Hint: Only exports, imports and integrations keep resource-scoped state, so flows have none, whatever the id: use an export's, import's or integration's (celigo state list --resource-type exports --resource-id <id>), or global state (celigo state list).
```

[`celigo state`](https://developer.celigo.com/cli/commands/state.md#celigo-state-list) refuses the other types before it sends anything.

## `Read mode: blocked …` / `requires full mode`

```
Command 'flows run' cannot run in read mode (it writes to the account). Current mode: read. A person raises this profile's mode to operate or full at a terminal ('celigo config set mode <mode>') to run operational actions; an agent must not raise it, or switch profiles, to get past this refusal.
Command 'flows create' requires full mode. Current mode: operate. A person raises this profile's mode to full at a terminal ('celigo config set mode full'); an agent must not raise it, or switch profiles, to get past this refusal.
Read mode: blocked PUT v1/flows/5f83a9b2c7d3e8f1a2b3c4d5. A person raises this profile's mode to operate or full at a terminal ('celigo config set mode <mode>'); an agent must not raise it, or switch profiles, to get past this refusal.
```

The profile's permission mode refused the command before any request left your machine. Since celigo-cli 2026.10.1 read mode refuses every operational action — runs, invokes, error management, debug toggles, data loads — at the start, before the reads it would begin with; earlier releases ran those reads and could exit `0` when there was nothing to change. The `Read mode: blocked …` form is the HTTP client's backstop for a write the command level does not name. Nine verbs need full mode since the same release: `environments enable`/`disable`, `workspace-users enable`/`disable`, `stacks rotate-token`, `on-premise-agents rotate-token`, and `storage create-folder`, `move`, and `copy`. Since celigo-cli 2026.10.2, `processors invoke` needs operate mode, because the catalog's `javascript` processor runs a hook whose integrator-api calls write for real; in read mode, run `processors parse`, `generate`, `render`, or `filter` instead.

The hint is addressed to the person who decides the mode, not to the session that was refused (since celigo-cli 2026.10.1; earlier releases told the session to switch modes or profiles). Raising a profile's mode — `celigo config set mode operate` or `full` — needs a person at a terminal, who types the new mode back; an agent must not raise it, or switch to another profile, to get past the refusal. Otherwise use a profile whose mode allows the action. See [Permission modes](https://developer.celigo.com/cli/getting-started/profiles.md#permission-modes).

```
Command 'flows run' cannot run in read mode (it writes to the account). Current mode: read (from CELIGO_MODE). CELIGO_MODE tightens the profile's mode and never raises it: whoever set it in this environment unsets it, or sets it to operate or full, to run operational actions; an agent must not change it to get past this refusal.
Read mode (from CELIGO_MODE): blocked PUT v1/flows/5f83a9b2c7d3e8f1a2b3c4d5. CELIGO_MODE tightens the profile's mode and never raises it: whoever set it in this environment unsets it, or sets it to operate or full; an agent must not change it to get past this refusal.
```

When the refusal says `(from CELIGO_MODE)`, the environment variable made the mode stricter than the profile's, and `celigo config set mode` changes nothing while it is set. Since celigo-cli 2026.10.1 the variable only tightens: a session runs in the stricter of the profile's stored mode and `CELIGO_MODE`, so `CELIGO_MODE=full` no longer lifts a profile stored in `read`. Whoever set the variable unsets it or loosens it, up to the profile's stored mode. Since celigo-cli 2026.9.1 the refusal names the source; earlier releases always hinted at `config set mode`.

A `CELIGO_MODE` that is not a mode counts as `read`, with a warning on stderr (since celigo-cli 2026.10.1):

```
warning: CELIGO_MODE is set to 'readonly', which is not a mode — it counts as read mode until it is unset or set to read, operate, full.
```

A stored `mode` that is not a mode makes the profile run in `read` the same way, with `warning: profile 'acme-sandbox' stores mode 'readonly', which is not a mode — the profile runs in read mode until a person fixes it with 'celigo config set mode <read|operate|full> --profile acme-sandbox' at a terminal.`

## `Raising profile '…'s permission mode … needs a person at a terminal`

```
Raising profile 'acme-sandbox's permission mode from read to full needs a person at a terminal: run this command in an interactive shell. An agent must not raise the mode on the person's behalf, nor get past this refusal another way (another profile, an edit of the config file; CELIGO_MODE never raises a profile's mode).
```

Since celigo-cli 2026.10.1, `celigo config set mode` to a looser mode (`read` to `operate` or `full`, `operate` to `full`), and `celigo config unset mode` on a `read` or `operate` profile (which leaves the default, `full`), need a person at a terminal, who types the new mode back; off a terminal they are refused, exit `1`. Run the command yourself in an interactive shell. Tightening a mode never asks. An agent that meets this refusal tells the person rather than looking for another way around it.

## `CELIGO_MODE is set but empty`

```
CELIGO_MODE is set but empty (this usually means a shell variable was unset). Unset it to use the profile's mode, or set it to read, operate or full.
```

The environment sets `CELIGO_MODE` to an empty string — typically a CI template or a shell script whose variable was never filled in. Every command fails closed, `config` and `profile` included, rather than run in the profile's mode. Unset the variable, or give it a mode. Since celigo-cli 2026.10.1 every command's refusal names the variable; the `config` commands used to say `Invalid mode ''`.

## `404 Not Found` on a resource you know exists

* Wrong base URL — the resource lives in a different region's tenant.
* Wrong profile — check `celigo profile list`.
* Custom-scoped token doesn't see the resource (the API returns `404 Not Found` to avoid leaking existence).

Since celigo-cli 2026.10.1 a `Hint:` line under the error says which case it is: an id no resource has (check it against the group's `list` — an id from another account or environment is not found either), or a resource that sits in the recycle bin (`celigo recycle-bin list` shows it). An id that is not shaped like one comes back as a `400`, with a hint saying what an id looks like.

Since celigo-cli 2026.10.2, a `404` from a flow step's error routes — `jobs errors`, `flows errors`, and the other step-error commands — says the step may no longer be one of the flow's steps. `jobs errors` reads the steps a past run used, and a step detached from the flow since then answers `404`, as a missing flow does:

```
Hint: Step 6a1b2c3d4e5f6a7b8c9d0e1f is not one of flow 5f83a9b2c7d3e8f1a2b3c4d5's steps now, or the flow does not exist. A step detached from its flow keeps its open errors out of sight until it is attached again; celigo flows get 5f83a9b2c7d3e8f1a2b3c4d5 shows the flow's steps.
```

Since celigo-cli 2026.11.1, a `404` from a `connections` command says the id may be an end user's copy of an MCP server's connection. Such a copy holds the credentials an end user supplied. `connections get`, `audit`, and `debug-logs` answer `404` for it, as for an id nothing holds, and `connections list` never shows one:

```
(404): Not found: Connection not found.
Hint: If 7b2c3d4e5f6a7b8c9d0e1f2a is an end user's copy of an MCP server's connection (connectionRole mcpChild), the connections routes never serve it: read it with celigo end-users connection 7b2c3d4e5f6a7b8c9d0e1f2a (celigo mcp-servers connections <serverId> --end-users lists the copies). Otherwise no connection has that id: check it against celigo connections list (an id from another account or environment, or one purged from the recycle bin, is not found either).
```

When the `404` answers a `connections delete`, the hint names `celigo end-users delete-connection <id>` instead. Earlier releases said only that no resource had the id, and sent you to `connections list`. See [end-users](https://developer.celigo.com/cli/commands/end-users.md#celigo-end-users-connection-less-than-connectionid-greater-than).

Since celigo-cli 2026.11.2, when the `404` answers `connections debug-logs --resource <id>` for an export or import id that nothing holds, the hint names that id instead of the connection:

```
Hint: No export or import has the id 6a1b2c3d4e5f6a7b8c9d0e1f: --resource takes the id of an export or import that sends its traffic through connection 7b2c3d4e5f6a7b8c9d0e1f2a (celigo exports list, celigo imports list), which was found.
```

## `429 Too Many Requests`

The HTTP client retries a `429` automatically, up to 3 times, on every request but one that creates or starts something (see below). Since celigo-cli 2026.9.1 it honors the server's `Retry-After` header (delay-seconds or an HTTP-date, capped at 60 seconds) instead of guessing with exponential backoff; without the header it backs off exponentially. `--verbose` prints each retry with its cause (`Retry 1/3 after 2000ms (HTTP 429, Retry-After)...`).

A create, clone, install, run, or invoke is sent once, and since celigo-cli 2026.11.1 a `429` fails it at once, because the platform may have carried out the request before it answered:

```
(429): Rate limited — not resent: the platform may have carried out the request before it answered, so check for the result before running the command again.
```

Earlier releases resent it after the `429`; one `integrations create` made two integrations that way. Check whether the request landed before you run the command again: `jobs list` for a run, a `list` by name for a create (see [After a timeout, check before you retry](https://developer.celigo.com/cli/using-the-cli/scripting.md#after-a-timeout-check-before-you-retry)). `push` and `promote` keep a create's intent marker after a `429`, so their next run adopts the resource if it landed.

If you're still being throttled:

* Run with lower parallelism — serialize shell loops instead of `xargs -P`. For `pull`, `diff`, `push`, and `promote`, lower `--concurrency` (or `CELIGO_CONCURRENCY`; default 8).
* Filter `jobs list` / `audit list` queries so they return fewer pages.
* Batch writes at the source rather than looping one `POST` per record.

See [Rate limits](https://developer.celigo.com/api/using-the-api/rate-limits) in the API section.

## `timed out after 30s`

```
note: PUT v1/flows/5f83a9b2c7d3e8f1a2b3c4d5 timed out after 30s — retrying up to 3 more times (a write that timed out may still have landed).
```

A request has a 30-second budget by default; long-running operations — invokes, previews, test runs, clones, `docs search`, and `file-definition-rules` submissions — get a 6-minute budget that matches the server's own ceiling. A read, a read-only `POST`, or a `PUT`, `PATCH`, or `DELETE` that times out is retried up to 3 times, and since celigo-cli 2026.9.1 the CLI says so once, verbose or not, before the first retry; `--verbose` names the retry cause (`timed out` or `HTTP 5xx`). Note the parenthesis: a write that timed out may already have landed. Since celigo-cli 2026.10.1 it appears only for a write, never for a `GET` or a read-only request.

Since celigo-cli 2026.10.1 a request that creates or starts something — a `create`, `clone`, `templates install`, run, invoke, or `ai-agents chat` turn — is sent once and never resent after a timeout or a `5xx`, because the first attempt may have landed (a resend could make a second resource or a second run). Since celigo-cli 2026.11.1 it is not resent after a `429` either (see [`429 Too Many Requests`](#id-429-too-many-requests)). The `enable` and `disable` toggles of `environments` and `workspace-users` are not resent after a timeout or a `5xx` either, though they still retry a `429`. The error says so:

```
Request timed out after 30s: POST https://api.integrator.io/v1/flows/5f83a9b2c7d3e8f1a2b3c4d5/run — the request may have reached the server, which may have carried it out; it is not resent, so check for the result before running the command again.
```

Since celigo-cli 2026.11.1 a `5xx` answer to such a request says the same after the platform's message: `(502): <message> — not resent: the platform may have carried out the request before it answered, so check for the result before running the command again.` Since celigo-cli 2026.11.2 a `5xx` answer to one of the `enable` or `disable` toggles says it too.

A write that is resent can be answered for its first attempt. A `DELETE` whose first attempt deleted the resource before it timed out answers `404` on the resend. Since celigo-cli 2026.11.2, a `4xx` that answers the resend of a write says so:

```
(404): Not found: … — the answer to a resend: an earlier attempt ended in a timeout and may have been carried out, so check for its result before running the command again.
```

Check the account before you run the command again — `jobs list` for a run, a `list` by name for a create; see [After a timeout, check before you retry](https://developer.celigo.com/cli/using-the-cli/scripting.md#after-a-timeout-check-before-you-retry). `push` and `promote` handle it on their own: a later run adopts what landed instead of duplicating it. A response cut off after its headers is reported the same way (`… was cut off after its headers (…) — the request reached the server, which may have carried it out.`), and a response body that stalls is cut off by the same budget.

Retries exhausted on a timeout or a `5xx` exit `1` with the last error. Re-run with `--verbose` to see each attempt.

## `(field: name)` at the end of an API error

```
(422): Validation error: Script fields are invalid. (field: name)
```

Since celigo-cli 2026.10.2, when the platform's message does not name the field it refused, the error adds it in parentheses, from the error's `field`. Here a `scripts update` body had no `name`: a body whose `name` is missing or empty is refused and nothing is saved, so send `name` with every script update. See [scripts](https://developer.celigo.com/cli/commands/scripts.md#celigo-scripts-update).

## `not stored` after `set`

```
not stored  <field>  the server answered the PUT but still holds its previous value <value>
celigo: exports set: the platform kept its own value for name, filter — the Integration App locks them
```

Since celigo-cli 2026.10.1, `set` checks the server's reply after a GET + PUT. The platform answers `200` for a change it ignores, so each field the reply still holds at its previous value is named on stderr, and the command exits `1`.

* **`not stored`** — the platform ignored the field. An export's legacy `filter.rules` is the common case: the platform rebuilds it from `filter.expression.rules` on every save, and the line says to set that instead.
* **`the platform kept its own value for …`** — the document belongs to an Integration App (`_connectorId`), and the app locks those fields. `update` and `exports reset-cursor --snapshot-mode` report the same way. For an app's settings, `celigo integrations persist-settings` saves through the app's own code; see [integrations](https://developer.celigo.com/cli/commands/integrations.md).

A field the reply leaves out, masks, or nulls is not reported, and neither is a value the platform only normalized — a `"20"` it holds as `20`, an `http.method=post` it holds as `POST`.

## `Cannot set filter to a bare rules array`

```
Cannot set filter to a bare rules array: filter holds a filter object, and the platform answers 200 to an array there, stores no filter and drops the one held, so every record would pass. Send the rules in the expression form: celigo exports set <id> 'filter={"type":"expression","expression":{"version":"1","rules":[…]}}' (filter=null removes the filter).
```

Since celigo-cli 2026.10.2, `set` refuses a bare rules array for an export's `filter` or `inputFilter`, or an import's `filter`, before any request. Each field holds a filter object. The platform answers `200` to an array there, stores no filter, and drops the one the step held, so the step then passes every record. Send the rules wrapped as the message shows; `filter=null` still removes a filter. Earlier releases sent the array with only a spec-check warning and exited `0`, so check the filter of a step you set that way (`celigo exports get <id> --jq .filter`).

## `Flow Builder crashes opening that router`

```
Refusing to update flow 5f83a9b2c7d3e8f1a2b3c4d5: routers[1].script (router 'rsnRouter01') is null — the platform stores it, but Flow Builder crashes opening that router. Leave the key out: a router with no script has no "script" field.
```

Since celigo-cli 2026.10.2, every write refuses a router whose `script` is `null`, with no override: `create`, `update`, `set`, the verbs that send back the flow, tool, or API they read (`add-processor`, `remove-processor`, `add-generator`, `remove-generator`), and `push` and `promote` at plan time. The platform stores `"script": null` and answers `2xx`, but Flow Builder's router editor crashes the whole app opening that router, and a reload crashes again. Every `routers` array is checked: a flow's, a tool's, an API's `builder.routers`, and an instance flow's `overrides.routers`.

The refusal's last sentence says where the key goes:

* **A body you send** (`create`, `update`): leave the key out.
* **`set`**: add the assignment the message names, such as `'routers[1].script=null'`, to the same `set`. Assigning `null` removes the key.
* **A verb that sends back the copy it read**: run the `set` the message names first, such as `celigo flows set 5f83a9b2c7d3e8f1a2b3c4d5 'routers[1].script=null'`.
* **A tree file** (`push`, `promote`): delete the key from the file.

That `set`, or a push of a pulled flow with the key deleted, is also how a flow that already holds one is repaired. A `set` that goes through the PATCH (`disabled`, `schedule`, `name`, …) never sends the routers, so it still works on such a flow.

## `a PUT that carries upstreamMcpConnections approves every upstream definition`

```
Refusing to set permissionSets on mcp-server 5f83a9b2c7d3e8f1a2b3c4d5: this field needs a PUT of the whole server, and a PUT that carries upstreamMcpConnections approves every upstream definition that changed since it was last approved (crm tool search_contacts), so those changes would be served without review. Nothing was sent. Approving them is a decision for a person who has reviewed them: an agent must not approve them itself, with 'mcp-servers update' or any other write. Run the set again once they are approved. name, disabled, policies, _networkPolicyId, logging.mode and logging.debugUntil need no PUT — 'set' sends them as a PATCH, which approves nothing.
```

The MCP server proxies remote MCP servers, and an upstream tool, prompt, or resource it serves changed since an administrator approved its definition (`changedSinceApproval`). A `PUT` that carries `upstreamMcpConnections` approves every such change, and the document a GET returns always carries it. So since celigo-cli 2026.10.2, `mcp-servers set` refuses its GET + PUT while any upstream row is flagged, and sends nothing; the refusal names each changed row as `<alias> <kind> <name>`. `push` and `promote` refuse the same update at plan time, so their `--dry-run` shows it and exits `1`, and `--force-remote` does not lift it. See [MCP servers and upstream approval](https://developer.celigo.com/cli/local-tree/push.md#mcp-servers-and-upstream-approval).

Approving the changes is a decision for the person who reviews them. An agent that meets this refusal tells the person, rather than approving the changes with `mcp-servers update` or another write. `name`, `disabled`, `policies`, and `_networkPolicyId` still apply in the meantime, because `set` sends them as a PATCH. Since celigo-cli 2026.11.2 the PATCH also carries `logging.mode` and `logging.debugUntil`, so the refusal names them too.

## `Refusing to create an event report: it takes its flows as _flowIds`

```
Refusing to create an event report: it takes its flows as _flowIds, an array of flow ids, and has no flowIds field, which the platform does not read. Rename flowIds to _flowIds: {"_flowIds": ["<flowId>"]}.
```

Since celigo-cli 2026.10.2, `event-reports create` refuses a body with a `flowIds`, `flowId`, or `_flowId` key before the request. The create reads its flows only from `_flowIds`, so a body that named them another way was refused by the platform as a report without flows (`422`). Rename the key as the message says. See [event-reports](https://developer.celigo.com/cli/commands/event-reports.md#celigo-event-reports-create).

## `… already exists; refusing to overwrite it`

```
orders.csv already exists; refusing to overwrite it. Pass --force to replace it, or choose another destination.
```

Since celigo-cli 2026.10.1 a command that writes a local file never replaces one you did not ask it to: `storage download`, `storage query -o`, `storage query-results -o`, `jobs download-files -o`, and `integrations`/`apis`/`tools`/`mcp-servers download` refuse an existing destination. A stored file's name comes from the server, so a download named `.bashrc` could otherwise replace yours. Pass `--force` to replace the file, or name another path. A directory is refused even with `--force`, and so is a path whose directory does not exist — create the directory first.

## `Cannot reach <host>`, an HTML page, or a redirect

```
Cannot reach https://api.integrator.io (SELF_SIGNED_CERT_IN_CHAIN: self-signed certificate in certificate chain). Check your network and base URL.
```

The request got no answer. Since celigo-cli 2026.10.1 the parenthesis carries the reason the network layer gave: a certificate your machine does not trust (a TLS-inspecting proxy — see the next entry), a host name that does not resolve (a typo in the base URL), or a proxy refusing the connection. Check `celigo config show`, `CELIGO_BASE_URL`, `--base-url`, and `HTTPS_PROXY`.

Since celigo-cli 2026.11.2 the parenthesis names a proxy's own answer. A proxy that refuses the tunnel reads `Proxy response (407) …`, where it read `Request was cancelled.` A proxy that closes the connection without an answer reads `the proxy closed the connection without answering the tunnel request`, and the request fails at once. Earlier releases kept opening connections to such a proxy until the request timed out. A proxy variable whose value is not a URL is refused by its name, and the value is never printed:

```
HTTPS_PROXY is not a proxy URL the CLI can use (Invalid URL protocol: the URL must start with `http:` or `https:`). Set it to the proxy's full URL, scheme included: http://host:port.
```

```
GET v1/flows/5f83a9b2c7d3e8f1a2b3c4d5 was answered with an HTML page (HTTP 200), not the API's JSON — a proxy, captive portal or sign-in page answered in its place, so the request cannot be assumed to have reached the API. Check the network (a sign-in page for it, HTTPS_PROXY) and try again.
```

A proxy, a captive portal, or a network sign-in page answered instead of the API, often with a `200`. Since celigo-cli 2026.10.1 the CLI reports it as a failure instead of printing the page or reporting a write as done. Sign in to the network or fix the proxy settings, then run the command again. An error status with an HTML body reads `an HTML page, not the API's JSON (a proxy, gateway or sign-in page answered in the API's place)`.

```
GET v1/flows/5f83a9b2c7d3e8f1a2b3c4d5 was answered with a redirect (HTTP 302 to login.example.com). The CLI never follows a redirect with its credentials or a request body — the base URL may be wrong (check 'celigo config show', CELIGO_BASE_URL and --base-url), or a proxy or captive portal answered in the API's place.
```

The API answers with data or an error, never a redirect, so a redirect means a wrong base URL or something between you and the API. Since celigo-cli 2026.10.1 no request that carries the token or a body follows one; the message names the status and the host it pointed to. A presigned download URL, which carries no credential, is still followed.

## `Error: self-signed certificate in certificate chain`

Behind a corporate proxy with TLS interception. Since celigo-cli 2026.10.1 the reason arrives inside the `Cannot reach` message: `Cannot reach https://api.integrator.io (SELF_SIGNED_CERT_IN_CHAIN: self-signed certificate in certificate chain). Check your network and base URL.` Point Node at your organization's CA bundle:

```bash
export NODE_EXTRA_CA_CERTS=/path/to/corp-root-ca.pem
```

> ⚠️ **Never disable TLS certificate validation.** Do not set `NODE_TLS_REJECT_UNAUTHORIZED=0` — it disables cert checking account-wide in your shell and is a silent-failure vector.

## `The API token holds a character an HTTP header cannot carry`

```
The API token holds a character an HTTP header cannot carry (U+200B at position 41, e.g. a line break, a zero-width space or a typographic quote picked up when it was pasted) — check the stored token (celigo config show), CELIGO_API_TOKEN or --token, and store it as plain text on one line.
```

The token picked up a character when it was copied — a line break, a zero-width space, a typographic quote. Since celigo-cli 2026.10.1 the CLI refuses it before any request and names the character's code point and position, never the token itself; earlier releases reported a network failure, or printed the token in the error. Store the token again as plain text on one line (`celigo config set api_token <token>`), or fix `CELIGO_API_TOKEN` or `--token`.

## `EACCES` when installing globally

On macOS/Linux without `sudo`, the default global prefix isn't writable. Either:

```bash
# Use a user-local npm prefix
mkdir -p ~/.npm-global
npm config set prefix ~/.npm-global
export PATH=~/.npm-global/bin:$PATH
npm install -g @celigo/celigo-cli
```

Or use [nvm](https://github.com/nvm-sh/nvm) / [volta](https://volta.sh) — both handle the prefix for you.

## `jq: no jq to run`

```
jq: no jq to run. The CLI's own jq is downloaded by its install script, which was skipped or blocked (npm install --ignore-scripts, an install-script policy, or no access to github.com at install time) or found no jq binary published for this platform, and there is no jq on PATH. Install jq (https://jqlang.org/download/), set JQ_PATH to a jq binary, or run the script where github.com is reachable — with --foreground-scripts, which shows its reason if it leaves no jq again: npm rebuild -g @celigo/celigo-cli --foreground-scripts (npm 11 may ask for --allow-scripts=@celigo/celigo-cli with it), or in a project npm rebuild @celigo/celigo-cli --foreground-scripts (npm 11 approves a project's scripts with npm install-scripts approve, and refuses --allow-scripts there). A list command's --fields <spec> projects its output without jq, except these lists, which take none: audit, connectors licenses, datasets, edi-transactions, end-users, event-reports, file-server accounts, jobs, processors, profile, recycle-bin, skills, state, storage, sync-jobs, templates.
```

`--jq` found no jq to run. The CLI's install script did not download its own, and neither `JQ_PATH` nor `PATH` names one. `npm install --ignore-scripts` or an install-script policy skips the script, and without access to github.com it cannot download the binary; the install succeeds either way. Since celigo-cli 2026.11.1 the script is the CLI's own, so an `allow-scripts` entry must name `@celigo/celigo-cli`, not `node-jq`. Run the script again in place where github.com is reachable:

```bash
npm rebuild -g @celigo/celigo-cli --foreground-scripts
```

Or install jq on `PATH`, or point `JQ_PATH` at a jq binary. An agent that cannot change the install shapes a list command's output with `--fields <spec>` instead, which needs no jq. See [Install](https://developer.celigo.com/cli/getting-started/install.md#npm-install-scripts-and-jq).

Since celigo-cli 2026.11.2 the message adds `--foreground-scripts`, which shows the script's reason if it leaves no jq again, and names the lists that take no `--fields`.

A jq that exists but does not run is another error. Since celigo-cli 2026.11.2 it names where that jq came from. When it is the CLI's own — a package installed on one platform and run on another, such as a host's `node_modules` mounted into a container — the fix is the same rebuild, on the machine that runs the CLI:

```
jq: '<path>' does not run like jq (a --version probe failed). It is the CLI's own jq, which its install script downloads for the platform it runs on — was the package installed on another one? Download this machine's with npm rebuild -g @celigo/celigo-cli --foreground-scripts (npm rebuild @celigo/celigo-cli --foreground-scripts in a project), or set JQ_PATH to a jq binary.
```

Earlier releases said to point `JQ_PATH` at a jq binary, whichever jq had failed.

## `Assertion failed` on Windows

```
Assertion failed: !(handle->flags & UV_HANDLE_CLOSING), file src\win\async.c
```

With Node 24 on Windows, releases before celigo-cli 2026.10.2 printed this line after an API error's message and then crashed, ending with a crash exit code instead of `1`. The error above the line is the real failure. Upgrade with `npm install -g @celigo/celigo-cli@latest`: since celigo-cli 2026.10.2 a failed command exits `1` there, a `--jq` that fails on the answer included.

## CLI says "A new version is available"

The CLI checks npm for a newer version at most every four hours and installs it in the background, saying so on stderr. If the update did not apply, or you want to force it, run the command the CLI printed, or:

```bash
npm install -g @celigo/celigo-cli@latest
```

Since celigo-cli 2026.10.1, when your `celigo` sits under a prefix npm is not configured for — a second install earlier on `PATH`, or a `prefix` setting changed since — the background update and every command it prints add `--prefix <dir>`, so the update reaches the copy you run. A plain `npm install -g` would update the other copy; use the printed command. See [Install](https://developer.celigo.com/cli/getting-started/install.md#upgrading).

Suppress the check: `export CELIGO_NO_UPDATE=1`.

## Still stuck?

* Re-run with `--verbose` — prints each request's method and URL and every retry, never the token or a body. Paste that into a support ticket along with `celigo --version`.
* Community: [connective.celigo.com](https://connective.celigo.com).
* Production incidents: [status.celigo.com](https://status.celigo.com).


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://developer.celigo.com/cli/using-the-cli/troubleshooting.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
