> 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/output-formats.md).

# Output formats

The CLI emits results in one of two formats: JSON (machine-readable) or table (human-readable). Default is JSON.

## Forcing a format

```bash
celigo flows list --format json
celigo flows list --format table
```

Or persist the choice on a profile:

```bash
celigo config set default_format table
```

Or per session:

```bash
export CELIGO_FORMAT=table
```

Priority: `--format` CLI flag > `CELIGO_FORMAT` env var > profile `default_format` > default (`json`).

## Table format

Each resource type defines its own column set — commonly `_id`, `name`, and one or two business-relevant fields. Those columns are also what a `list` command requests from the API by default, so `--format table` and the default JSON listing carry the same fields.

```
_id                        name                        disabled  lastModified
-------------------------  --------------------------  --------  --------------------
5f83a9b2c7d3e8f1a2b3c4d5   Shopify → NetSuite orders   false     2026-04-21T12:15Z
6a1b2c3d4e5f6a7b8c9d0e1f   NetSuite → Salesforce       false     2026-04-20T09:02Z
```

If a resource type doesn't define columns (mostly custom RPC-style responses), the CLI falls back to JSON.

## JSON format

For a single resource, `get` returns an object. `list` returns an array.

`get` returns the complete resource body. `list` returns a projected row by default: `_id`, `name`, and the fields behind the table columns. Pass `--fields all` for complete documents, or a comma-separated list for specific fields. See [Global flags](/cli/getting-started/global-flags.md) for the full projection rules.

```bash
# Projected rows: identity plus the table columns
celigo flows list

# Complete flow documents
celigo flows list --fields all

# Slice a projected listing further
celigo flows list --jq '.[] | {_id, name, disabled}'
```

### Indentation

JSON is indented by two spaces when stdout is a terminal, and printed compact when it is piped or redirected. The compact form avoids sending whitespace through a pipeline. Both forms parse identically:

```bash
celigo flows list                    # indented, readable
celigo flows list | jq '.[0].name'   # compact
celigo flows list > flows.json       # compact
```

## `--jq`

`--jq <expr>` runs the response through jq without piping:

```bash
celigo flows get 5f83a9b2c7d3e8f1a2b3c4d5 --jq '.pageGenerators[]._exportId'
```

`--jq` forces JSON output; it's incompatible with `--format table`.

On a `list` command, `--jq` also requests complete documents, so the expression can address any field. That holds only while `--fields` is absent — an explicit `--fields` projects the rows first, and fields outside the projection then resolve to `null`.

## Pagination and format

`list` commands auto-paginate via `Link` headers (up to 50 pages by default). The full result set is returned as one flat array.

For body-paginated endpoints (like `flows errors`), the CLI follows `nextPageURL` in the response body and concatenates pages.

To inspect pagination manually, use `--verbose` (see [Global flags](/cli/getting-started/global-flags.md)).

## Color

ANSI color is enabled when stdout is a TTY. Disable with `NO_COLOR=1` (standard) or by piping output.


---

# 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 dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

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

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
