> 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/commands/iclients.md).

# iclients

Shared OAuth2 credential stores (app registrations) that multiple connections can reference — rotate a client secret in one place instead of per connection.

**REST API**: [iClients](https://developer.celigo.com/api/api-reference/connections-and-http-connectors/iclients)

```
celigo iclients <subcommand> [args] [flags]
```

Supports all [global flags](https://developer.celigo.com/cli/getting-started/global-flags.md).

***

## Subcommands

| Subcommand             | Purpose                                                                                                              |
| ---------------------- | -------------------------------------------------------------------------------------------------------------------- |
| `list`                 | List all iClients.                                                                                                   |
| `get <id>`             | Fetch one iClient (secrets are masked as `******`).                                                                  |
| `create`               | Create an iClient from a JSON body (`--file <path>` or stdin).                                                       |
| `update <id>`          | Full-replace PUT from a JSON body (`--file <path>` or stdin). Refuses masked placeholders unless `--force`.          |
| `set <id> key=value …` | Edit the PATCH-whitelisted field, `oauth2.failPath`, via atomic `PATCH`. Every other field is refused; use `update`. |
| `delete <id>`          | Delete an iClient by ID.                                                                                             |
| `dependencies <id>`    | List resources that depend on this iClient (alias `used-by`).                                                        |
| `audit <id>`           | Show the audit log (change history) for one iClient.                                                                 |

> **`set` is limited on iClients.** Because iClients are credential-masked, `set` may only touch the PATCH-whitelisted field, `oauth2.failPath`, and never sends the masks back through a GET, modify, PUT round-trip on its own. To change any other field, send the whole iClient with `update --force`: a masked `******` value sent back keeps the stored secret. Put a new value in place of a mask only to change that secret.

***

## `celigo iclients list`

List every iClient in the current account.

**Signature**

```bash
celigo iclients list
```

**Arguments**

None.

**Flags**

| Flag              | Type    | Default   | Description                                                                                                                                                                                                                                                                           |
| ----------------- | ------- | --------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `--fields <spec>` | string  | `default` | Fields to return per row. `default` returns `_id`, `name`, and the table columns; `all` returns complete documents; a comma-separated list requests specific fields (dot notation allowed). See [field projection](https://developer.celigo.com/cli/getting-started/global-flags.md). |
| `--limit <n>`     | integer | —         | Return at most `<n>` rows, fetching a single page.                                                                                                                                                                                                                                    |

Default table columns: `_id`, `name`, `lastModified`.

**Example**

```bash
celigo iclients list --format table
```

**Corresponds to**: [`GET /v1/iClients`](https://developer.celigo.com/api/api-reference/connections-and-http-connectors/iclients#get-v1-iclients)

***

## `celigo iclients get <id>`

Fetch a single iClient by ID. Encrypted fields (e.g. `clientSecret`) are returned as `******`.

**Signature**

```bash
celigo iclients get <id>
```

**Arguments**

| Argument | Type   | Required | Description |
| -------- | ------ | -------- | ----------- |
| `<id>`   | string | Yes      | iClient ID. |

**Flags**

None beyond [global flags](https://developer.celigo.com/cli/getting-started/global-flags.md).

**Example**

```bash
celigo iclients get 5f83a9b2c7d3e8f1a2b3c4d5
```

**Corresponds to**: [`GET /v1/iClients/{_id}`](https://developer.celigo.com/api/api-reference/connections-and-http-connectors/iclients#get-v1-iclients-_id)

***

## `celigo iclients create`

Create an iClient from a JSON payload. Read the body from a file with `-f, --file` or pipe it on stdin.

**Signature**

```bash
celigo iclients create --file <path>
celigo iclients create < iclient.json     # or pipe on stdin
```

**Arguments**

None.

**Flags**

| Flag                | Type   | Default | Description                                                                                                  |
| ------------------- | ------ | ------- | ------------------------------------------------------------------------------------------------------------ |
| `-f, --file <path>` | string | —       | Read the JSON body from a file instead of stdin (`--file -` also means stdin). Added in celigo-cli 2026.6.1. |

**Request body**

Reads JSON on stdin (or from `--file`). See the `POST /v1/iClients` request schema in `dist/iclient.yml` for the full payload shape (`application`, `oauth2.clientId`, `oauth2.clientSecret`, `oauth2.authorizeURI`, `oauth2.tokenURI`, and provider-specific fields).

Since celigo-cli 2026.10.1, `create` refuses, before any request and with no override:

* a masked placeholder anywhere in the body — four or more asterisks and nothing else, such as the `******` a GET returns. A new iClient has no secret behind the mask, so the asterisks would become its credentials. Replace each with the real value, or leave the field out.
* a value that is not a string (an object, array, number, or boolean) in a field the platform encrypts, such as `oauth2.clientSecret` or `jwt.privateKey`. Send a string (`"123"`, not `123`), or `null` to clear the field.

**Example**

```bash
celigo iclients create < salesforce-iclient.json
```

**Corresponds to**: [`POST /v1/iClients`](https://developer.celigo.com/api/api-reference/connections-and-http-connectors/iclients#post-v1-iclients)

***

## `celigo iclients update <id>`

Full-replace an iClient with a JSON payload. Read the body from a file with `-f, --file` or pipe it on stdin. Refuses to submit a payload containing masked placeholders unless `--force` is passed. Since celigo-cli 2026.10.1 a mask is four or more asterisks and nothing else — a lone `*`, `**`, or `***` is a value, not a mask — and a value that is not a string in an encrypted field is refused with no override, `--force` included. Since celigo-cli 2026.10.2, the refusal says that a mask sent back keeps the stored secret, so `--force` sends the document as read; earlier releases said the masks would overwrite the secrets.

Since celigo-cli 2026.11.2, `update` reads the iClient first, and an id that matches no iClient ends with the read's `404`: nothing is sent. Earlier releases sent the `PUT`, which created a new iClient under that id and printed it as the update.

> ⚠️ **`PUT` fully replaces the iClient.** Any omitted field is erased. A secret left out is cleared for every connection that uses the iClient, except `oauth2.clientSecret`, whose omission is refused (422). Send the masked `******` back exactly as read (with `--force`) to keep the stored secret, or a new value to change it. Two providers differ: an Azure service principal keeps an omitted `clientSecret` or `certificate`, and a Google service account, whose key is never returned, needs its full JSON key on every update (422 without it).

**Signature**

```bash
celigo iclients update <id> --file <path>
celigo iclients update <id> [--force] < iclient.json     # or pipe on stdin
```

**Arguments**

| Argument | Type   | Required | Description |
| -------- | ------ | -------- | ----------- |
| `<id>`   | string | Yes      | iClient ID. |

**Flags**

| Flag                | Type    | Default | Description                                                                                                                                                                      |
| ------------------- | ------- | ------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `-f, --file <path>` | string  | —       | Read the JSON body from a file instead of stdin (`--file -` also means stdin). Added in celigo-cli 2026.6.1.                                                                     |
| `--force`           | boolean | `false` | Submit even if the body contains masked credential values (`"******"`) copied from a GET. Without it, masked fields cause the command to abort with the list of offending paths. |

**Request body**

Reads JSON on stdin (or from `--file`). Payload must be the complete iClient object — `PUT` is a full replace. See `PUT /v1/iClients/{_id}` in `dist/iclient.yml`.

**Example**

```bash
# Rename, keeping the stored secret: send the iClient as read, its mask included
celigo iclients get 5f83... --format json \
  | jq '.name = "Renamed"' \
  | celigo iclients update 5f83... --force

# Rotate the client secret: put the new value in place of the mask
celigo iclients get 5f83... --format json \
  | jq '.oauth2.clientSecret = "new-secret"' \
  | celigo iclients update 5f83...
```

**Corresponds to**: [`PUT /v1/iClients/{_id}`](https://developer.celigo.com/api/api-reference/connections-and-http-connectors/iclients#put-v1-iclients-_id), preceded since celigo-cli 2026.11.2 by [`GET /v1/iClients/{_id}`](https://developer.celigo.com/api/api-reference/connections-and-http-connectors/iclients#get-v1-iclients-_id)

***

## `celigo iclients set <id>`

Edit one or more fields on an iClient. Because iClients are credential-masked, only the PATCH-whitelisted field — `oauth2.failPath` — can be set, via an atomic `PATCH`; every other field must go through `update`, which sends the whole iClient with its masks (`--force`); a masked secret sent back keeps the stored value. Any other field is refused before any request:

```
Cannot set name on an iclient via 'set': its credentials are masked, and 'set' sends only PATCH-whitelisted fields.
Fields safe to set here (applied via PATCH): oauth2.failPath.
To change any other field, send the whole iclient with 'iclients update --force': a masked "******" value sent back keeps the stored secret.
```

Since celigo-cli 2026.10.2, the message names `iclients update --force`; earlier releases said a GET + PUT would overwrite the credentials and asked for the real values.

Since celigo-cli 2026.10.1, `oauth2.failPath=null` sends the JSON Patch `remove` operation the endpoint documents for that path, clearing the field; it used to be refused.

**Signature**

```bash
celigo iclients set <id> key=value [key2=value2 ...]
```

**Arguments**

| Argument           | Type              | Required | Description                                                                                              |
| ------------------ | ----------------- | -------- | -------------------------------------------------------------------------------------------------------- |
| `<id>`             | string            | Yes      | iClient ID.                                                                                              |
| `[assignments...]` | `key=value` pairs | Yes      | At least one assignment, to `oauth2.failPath`. Values are auto-parsed as JSON; `null` removes the field. |

**Example**

```bash
celigo iclients set 5f83a9b2c7d3e8f1a2b3c4d5 'oauth2.failPath=<value>'

# Clear it — one PATCH with a "remove" operation
celigo iclients set 5f83a9b2c7d3e8f1a2b3c4d5 oauth2.failPath=null
```

**Corresponds to**: `PATCH /v1/iClients/{_id}`

***

## `celigo iclients delete <id>`

Delete an iClient. Prompts for confirmation unless `-y` is passed.

> ⚠️ **Deleting an iClient is destructive.** Connections that reference it via `_iClientId` lose their credential store and stop authenticating. Run `dependencies` first to confirm nothing uses it.

**Signature**

```bash
celigo iclients delete <id> [-y]
```

**Arguments**

| Argument | Type   | Required | Description |
| -------- | ------ | -------- | ----------- |
| `<id>`   | string | Yes      | iClient ID. |

**Flags**

| Flag        | Type    | Default | Description                        |
| ----------- | ------- | ------- | ---------------------------------- |
| `-y, --yes` | boolean | `false` | Skip the interactive confirmation. |

**Example**

```bash
celigo iclients delete 5f83a9b2c7d3e8f1a2b3c4d5 -y
```

**Corresponds to**: [`DELETE /v1/iClients/{_id}`](https://developer.celigo.com/api/api-reference/connections-and-http-connectors/iclients#delete-v1-iclients-_id)

***

## `celigo iclients dependencies <id>`

List the resources (typically connections) that depend on this iClient. Use it to check whether the iClient is safe to delete; an empty result means no dependents. Aliased as `used-by`.

**Signature**

```bash
celigo iclients dependencies <id>
celigo iclients used-by <id>
```

**Arguments**

| Argument | Type   | Required | Description |
| -------- | ------ | -------- | ----------- |
| `<id>`   | string | Yes      | iClient ID. |

**Example**

```bash
celigo iclients dependencies 5f83a9b2c7d3e8f1a2b3c4d5
```

**Corresponds to**: `GET /v1/iClients/{_id}/dependencies`

***

## `celigo iclients audit <id>`

Show the audit log (change history) for one iClient. Since celigo-cli 2026.10.1 the command reads every page of the log, and the table shows `_id`, `resourceType`, `event`, `source`, `byUser.email`, and `time`.

**Signature**

```bash
celigo iclients audit <id>
```

**Arguments**

| Argument | Type   | Required | Description |
| -------- | ------ | -------- | ----------- |
| `<id>`   | string | Yes      | iClient ID. |

**Example**

```bash
celigo iclients audit 5f83a9b2c7d3e8f1a2b3c4d5
```

**Corresponds to**: `GET /v1/iClients/{_id}/audit`

***

## Gotchas

* **`set` only touches `oauth2.failPath`.** iClients hold OAuth client secrets, and the API masks those fields as `******` on every GET. So `set` is limited to the PATCH-whitelisted field, `oauth2.failPath`, written via an atomic `PATCH`; it cannot change the name or the client secret. To change anything else, send the whole iClient with `update --force`: each masked secret sent back keeps its stored value.
* **`update` refuses masked payloads by default.** Pipe `get | update` without replacing the masked fields and the command aborts, listing each offending path (e.g. `oauth2.clientSecret`). Pass `--force` to send the masks back — the platform keeps each stored secret — or replace a mask with a new value (or `""` to clear). Never delete a masked field to get past the check: an omitted secret is cleared for every connection that uses the iClient, and an omitted `oauth2.clientSecret` is refused (422).
* **A mask is four or more asterisks, and `create` never accepts one.** Since celigo-cli 2026.10.1 every verb uses one test: four or more asterisks and nothing else (the platform's mask is six). A lone `*` is a value. `create` refuses a masked value with no override; `update --force` is the only way to send one.
* **Encrypted fields hold only strings.** Since celigo-cli 2026.10.1, `create` and `update` (`--force` included) refuse an object, array, number, or boolean in a field the platform encrypts, such as `oauth2.clientSecret`, before any request. `null`, which clears the field, is sent.
* **iClients are shared.** One iClient can back many connections via `_iClientId`. Rotating a secret on the iClient flows to every connection pointing at it.

## Related

* [connections](https://developer.celigo.com/cli/commands/connections.md) — OAuth connections reference an iClient via `_iClientId`.
* [workspace-users](https://developer.celigo.com/cli/commands/workspace-users.md) — the other half of the former `users-iclients` page.


---

# 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/commands/iclients.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.
