> ## Documentation Index
> Fetch the complete documentation index at: https://docs.atomscale.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Set Up Atomscale CLI

> Install and sign in on a Windows workstation, then set up integrations remotely in the Atomscale web app

Use the Atomscale CLI on a workstation that can't run the desktop app, such as a Windows 7 or XP instrument computer. The CLI runs as a Windows service. It starts with Windows and keeps collecting data even when nobody is signed in to Windows.

**Recommended:** Use the installer to connect and sign in, then set up and manage your integrations from the web app. You don't need to run CLI commands if you finish sign-in in the installer.

## Before you begin

* A supported workstation: 32-bit Windows XP SP3, Windows 7 SP1 (32-bit or x64), or Windows 10 or later (32-bit or x64). For Windows 10 or later, we recommend the [desktop app](https://docs.atomscale.ai/gateway/set-up.md).
* A Windows administrator to install the service for the whole computer.
* An [Atomscale API key](https://docs.atomscale.ai/api-reference/authentication.md#obtaining-an-api-key) from the organization that will own the gateway.
* If the workstation can't reach Atomscale directly, an internet-connected computer on the same subnet running as a [Connection Sharing Hub](https://docs.atomscale.ai/gateway/connection-sharing.md#set-up-a-hub). Have the Hub's address and port ready.

## Install and continue in the web app

**1. Install the Atomscale CLI**

Contact [Atomscale support](mailto:support@atomscale.ai) for the Atomscale CLI installer.

Run the installer and approve the administrator prompt. On Windows XP, sign in to Windows as an administrator before running the installer.

**2. (Optional) Set up Connection Sharing**

* If Setup shows **Share this connection**, the workstation can reach Atomscale directly. Leave sharing off unless other lab computers need to connect through this one.
* If Setup shows **Connect through another computer**, accept the Hub that Setup found or enter your Hub's address and port if Setup asks for them.

If Setup skips these screens, continue to sign-in.

**3. Sign in**

On the **Sign in** screen, provide the API key and click Next, then finish the installer.

If the workstation can't reach Atomscale, Setup skips sign-in. Finish the installer, then follow [Connect and sign in from Command Prompt](#connect-and-sign-in-from-command-prompt) when a connection is available.

**4. Set up integrations in the web app**

With [Remote Management](https://docs.atomscale.ai/gateway/remote-management.md#integrations), you can add, configure, and start integrations from your browser. The integrations still run on the workstation.

Sign in to the [Atomscale web app](https://app.atomscale.ai) with an account that belongs to the organization that owns the API key. Open **Gateways** and search for the workstation by computer name. Its **App version** starts with `[CLI]` and its status should be **Online**.

Open the gateway and click Add Integration. Choose [kSA 400](https://docs.atomscale.ai/gateway/rheed/ksa-400.md), [Tool Log Streamer](https://docs.atomscale.ai/gateway/tool-state.md), or [File Watcher](https://docs.atomscale.ai/gateway/file-watcher.md). Configure the integration with the instrument or folder on the workstation, not the computer running your browser. For growth data, link the integration to its **Growth Instrument** before starting it.

RHEED Camera (GenTL) and FilmSense FS-1 require the desktop app.

## Update or uninstall

The CLI installs under `%ProgramFiles%\Atomscale\gateway`. It updates itself, or you can run a newer installer to upgrade it.

To uninstall, remove **Atomscale CLI** from **Add or Remove Programs**. Queued data and settings stay on the workstation for a later installation.

## Alternative: Set up from Command Prompt

Use this path if you need a scripted install or prefer to manage integrations from a terminal. For routine setup, use the installer and the web app instead.

### Install silently

In an administrator Command Prompt, go to the folder containing the installer and run it with `/S`. Replace the filename if your installer has a different name.

```batch theme={null}
start /wait "" "atomscale-setup-windows.exe" /S
```

The installer installs and starts the service. It keeps existing connection settings and doesn't sign in. Open a new Command Prompt so it picks up the `atomscale` command on your `PATH`.

### Connect and sign in from Command Prompt

If the workstation can reach Atomscale directly and doesn't need to share its connection, skip to sign-in. If it needs a Hub, run this command with your Hub's address and port:

```batch theme={null}
atomscale connection setup --hub lab-hub.local:8484
```

If this workstation has direct access and needs to share its connection with other lab computers, run `atomscale connection setup --share` on it instead.

Once the workstation can reach Atomscale, run the first command and provide the API key at the prompt. Run the second command to verify the saved key.

```batch theme={null}
atomscale auth login
atomscale auth status --verify
```

You can switch to the web app at this point. Confirm that the gateway is **Online** under **Gateways**.

### Install and start an integration from Command Prompt

The CLI calls integrations *adapters*. Refresh the catalog and find the adapter ID for your integration. The following example installs File Watcher. Use the instance ID from `atomscale adapter list` in place of `INSTANCE_ID` in the remaining commands.

```batch theme={null}
atomscale catalog refresh
atomscale catalog list
atomscale adapter install filewatcher
atomscale adapter list
```

Run `atomscale adapter config schema INSTANCE_ID` to see the settings for the adapter. For File Watcher, save the following as `adapter-config.json` in your current folder, with the path to an existing folder on the workstation. Use double backslashes in Windows paths inside JSON.

```json theme={null}
{
  "watchPath": "C:\\InstrumentData"
}
```

Validate and apply the configuration while the adapter is stopped:

```batch theme={null}
atomscale adapter config validate INSTANCE_ID --file adapter-config.json
atomscale adapter config apply INSTANCE_ID --file adapter-config.json
```

If the integration collects growth data, use `atomscale instrument list` to find the instrument ID. Run `atomscale adapter link INSTANCE_ID --instrument INSTRUMENT_ID` with that ID before starting collection.

```batch theme={null}
atomscale adapter start INSTANCE_ID
atomscale adapter status INSTANCE_ID
```

For gateway settings, including upload limits and automatic updates, see [CLI Settings Reference](https://docs.atomscale.ai/gateway/reference/cli-settings.md).


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.