# Quickstart

> From sign-up to your agent's first click in about five minutes.

## 1. Get a screen

Sign in at [https://console.trykubi.com](https://console.trykubi.com) and buy your first screen, or top up credit and make a disposable one for a short run ([two kinds](/concepts/screens#two-kinds)). It is ready in seconds.

## 2. Create an API key

In the dashboard, open **API keys**, create a key and copy it. It is shown once. Give it the `read` and `control` permissions for this quickstart.

```bash
export KUBI_API_KEY=kubi_...
```

## 3. Install the SDK

```bash
npm install @trykubi/sdk
```

## 4. Look, then act

```ts
import { Kubi } from "@trykubi/sdk";

const client = new Kubi(); // reads KUBI_API_KEY
const screen = client.screen();   // your only screen; pass an id when you have several

const shot = await screen.screenshot();
console.log(shot.width, shot.height, shot.screenshot_id);

const result = await screen.click({
  x: 640,
  y: 360,
  screenshot_id: shot.screenshot_id, // refuse to click if the screen changed
  screenshot: "after",              // get the screen back once it settles
});
console.log(result.status, result.screenshot?.screenshot_id);
```

The same two calls with `curl`:

```bash
curl https://api.trykubi.com/v1/screens/scr_7f2kq9w3x8m4b6tzp1ac/screenshot \
  -H "Authorization: Bearer $KUBI_API_KEY"

curl -X POST https://api.trykubi.com/v1/screens/scr_7f2kq9w3x8m4b6tzp1ac/click \
  -H "Authorization: Bearer $KUBI_API_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{"x": 640, "y": 360, "screenshot": "after"}'
```

## 5. Watch it live

Open the screen in the dashboard to see the desktop as your agent works. Press **Take control** and confirm to use it yourself. Your agent's calls are refused until you press **Release** or 5 minutes pass with no input from you.

## Next

- Give an agent app the screen instead of writing code: [Connect your agent](/connect-your-agent)
- How looking and acting fit together: [The look and act loop](/concepts/look-and-act)
- Every endpoint: [API reference](/api)
