# sinch upgrade

Check for a newer Sinch CLI and install it. Auto-update is off by default; see
[Updating](/docs/functions/cli/installation#updating) for how it works.

## sinch upgrade

Check the registry now and act on the result.

```sh
sinch upgrade
```

Unlike the background check that runs on every command, this ignores the 30-minute rate limit and
the CI/non-TTY suppression, because you asked for it explicitly. It reports one of:

| Message | Meaning |
|  --- | --- |
| `Already on the latest version` | Nothing to do |
| `Update queued. It will install in the background...` | A helper is installing it; effective on a later run |
| `Auto-update is off. Enable it with: sinch config set autoUpdate true` | An update exists but you have not opted in |
| `This update crosses a minor version boundary...` | Pre-1.0 the minor is where breaking changes live; update by hand when ready |
| `This CLI was not installed by npm globally...` | Update it the way you installed it |
| `Automatic installs are paused for this release` | Paused centrally; update by hand if you need it now |
| `The published version has no provenance attestation` | Will not be installed automatically |
| `Could not reach the npm registry` | Transient; try later |


## sinch upgrade --status

Show what the CLI knows, without touching the network.

```sh
sinch upgrade --status
```

```
Version:      0.5.8
Auto-update:  on
Last checked: 2026-09-01T20:51:25.806Z
Pending:      0.5.9
Failures:     1
```

`Pending` and `Failures` appear only when an install is in flight or has been failing. After three
consecutive failures for the same version the CLI stops trying and falls back to notifying you.

Install output is appended to `~/.sinch/update.log`, which is the first place to look if an update
is not landing.

## JSON output

Both forms accept `--json` and print a single JSON document to stdout with no other output.

```sh
sinch upgrade --status --json
```

```json
{
  "version": "0.5.8",
  "autoUpdate": true,
  "lastCheckedAt": "2026-09-01T20:51:25.806Z",
  "pending": "0.5.9",
  "consecutiveFailures": 1
}
```

`lastCheckedAt` is `null` when the CLI has never checked. `pending` is omitted when there is no
target.

```sh
sinch upgrade --json
```

```json
{ "version": "0.5.8", "outcome": "up-to-date" }
```

`outcome` is one of `up-to-date`, `spawned`, `skipped-in-flight`, `skipped-disabled`,
`skipped-ineligible`, `skipped-not-global`, `skipped-killswitch`, `skipped-suppressed`,
`skipped-rate-limited` or `failed`.

## See also

- [Updating](/docs/functions/cli/installation#updating)
- [Configuration](/docs/functions/cli/configuration) for `autoUpdate` and the environment variables