# Quickstart

<Steps>
  <Step title="Install">
    Linux and macOS:

    ```bash
    curl -fsSL https://rebates.ai/install | bash
    ```

    Windows:

    ```powershell
    powershell -c "irm https://rebates.ai/install.ps1 | iex"
    ```

    Downloads the prebuilt binary for your platform, installs it to the Rebate
    bin directory, and wires up your PATH.
  </Step>

  <Step title="Turn it on">
    ```bash
    rebate
    ```

    The interactive onboarding detects Claude Code and Codex, explains exactly
    what will change, asks for consent, backs up your settings byte-for-byte, and
    enables the supported sponsored footers.

    Preview the exact file changes first:

    ```bash
    rebate on --dry-run
    ```

    For CI or scripted installs, skip the prompts:

    ```bash
    rebate --yes
    ```

    Scripted installs still refuse to touch unparseable Claude settings or Codex
    hooks.
  </Step>

  <Step title="Open Claude Code or Codex">
    ```bash
    claude
    ```

    ```bash
    codex
    ```

    Claude Code renders the sponsor in its statusline and matching thinking
    spinner text. Codex renders the sponsor in the terminal footer row. Each
    submitted user message runs a Rebate prompt hook that fetches a fresh sponsor
    for the next visible footer.
  </Step>

  <Step title="Watch earnings accrue">
    Earnings live on your dashboard. Onboarding signs you in with `rebate login`
    and connects this device to your account, so its impressions credit you from
    the first session. Track them at
    [`app.rebates.ai/dashboard/ads`](https://app.rebates.ai/dashboard/ads) — the
    same URL is printed by:

    ```bash
    rebate status
    ```

    See [Earnings](/rebates/earnings) for how impressions credit.
  </Step>

  <Step title="Visit a sponsor (optional)">
    The footer includes a credited first-party URL and is clickable in terminals
    that render hyperlinks. From any terminal you can open the current sponsor
    from your shell:

    ```bash
    rebate open
    ```

    Claude Code also gets an installed slash command:

    ```text
    /ad
    ```
  </Step>

  <Step title="Turn it off anytime">
    ```bash
    rebate off
    ```

    This removes Rebate-owned Claude Code settings, restores previous values for
    keys Rebate touched, restores the original Codex launcher, removes Rebate
    Codex hooks, and removes the `/ad` command.
  </Step>
</Steps>

## Requirements

- Claude Code or Codex installed. Onboarding checks local tool config and reports
  what it can patch.
- `curl` on Linux/macOS, or PowerShell on Windows. The CLI itself is a self-contained binary; no Node or package manager needed.

Pin a specific release by passing its tag:

```bash
curl -fsSL https://rebates.ai/install | bash -s -- @selltraces/rebate-cli@0.1.0
```

For a repair-oriented check at any time:

```bash
rebate doctor
```
