---
name: cosyra-cli-setup
description: Install or update the native Cosyra CLI on macOS or Linux, verify the installation, and help the user sign in and connect to their cloud workspace.
---

# Set up the Cosyra CLI

1. Check the OS and architecture. Supported: macOS/Linux, ARM64/AMD64.
   Check for an existing `cosyra` executable, alias, or function.
2. Use the public installer:

   ```sh
   curl -fsSL https://cosyra.com/install.sh | bash
   ```

   It installs to `~/.local/bin/cosyra` without Node, npm, Go, or repository
   access. Preserve existing installations unless the user intends an upgrade;
   use the installer's `--replace` option for an explicit upgrade. Preserve
   existing aliases and shell configuration. Follow the installer's PATH setup
   instructions; use the absolute binary path to avoid conflicts.

3. Verify with `"$HOME/.local/bin/cosyra" version` and
   `"$HOME/.local/bin/cosyra" --help`. A new terminal may be needed to load PATH
   changes. In the current terminal, follow the printed export command or use
   the absolute path; do not remove an existing alias.
4. To connect to production, run:

   ```sh
   "$HOME/.local/bin/cosyra" connect --api-url https://api.cosyra.com
   ```

   The user completes browser OAuth and any required payment. Never print or
   transfer credentials. Connecting may take terminal control from another
   device. `Ctrl+]` detaches; `Ctrl+C` interrupts the remote command.

5. Report the installed version and path, local checks, and whether sign-in
   and connection actually succeeded. An install/help check alone is not a
   live connection test.

Bare `cosyra` opens the menu. `qr` and `link` belong to the separate handover
package; do not install an npm package to obtain this native CLI.
