# Install the SDK

URL: /code/sdk/guides/install · Id: `page:code/sdk/guides/install`

> Install the startup-builder package, set one key in the environment, and make a first typed call from code to a Startup's test environment.

The `startup-builder` package exports `$`, the typed client for one [Startup](/business/nouns/startup). Setup is one install and one key: there is no client to construct and no base URL to set.

## Prerequisites
- A project that installs packages with npm. The same package runs on a server, at the edge, and inside a Startup's own [Functions](/business/nouns/function).
- A test [Secret](/business/nouns/secret) key, `sk_test_...`, for the Startup. `npx startup-builder login` stores one, and [the key guide](/code/api/guides/keys) covers every kind.

The examples use `leaseline.app`, which tracks lease renewals for small property managers at $29 a month.

## Steps
1. Install the package:

   ```bash
   npm install startup-builder
   ```

2. Set the key in the environment:

   ```bash
   export STARTUP_BUILDER_API_KEY=sk_test_...
   ```

   `$` reads its key from `STARTUP_BUILDER_API_KEY`. The key selects the namespace, and its `test` prefix keeps every call in the test environment.

3. Import `$` and make a first call:

   ```ts
   import { $ } from 'startup-builder'

   const offers = await $.Offer.list({ limit: 5 })

   console.log(offers.map((offer) => offer.$id)) // https://api.sb/leaseline.app/offers/offer_1
   ```

   A list resolves to one page, an array with an `after` cursor.

4. To try a write without storing anything, prefix it with `try`:

   ```ts
   await $.try.Offer.subscribe({ offer: 'offer_1', quantity: 1 })
   ```

## Result
`$` holds a typed method for every [Verb](/business/nouns/verb) the key may run, and the editor completes each one's input. `$.Offer.subscribe(input)` is the same operation as `POST /offers/{offer}/subscribe`.

## Next steps
- [What a write returns](/code/sdk/guides/actions): one [Action](/business/nouns/action) per call.
- [The SDK overview](/code/sdk): [Modes](/business/nouns/mode), failures, and [Events](/business/nouns/event).
- [SDK methods](/code/sdk/reference): every method, by [Noun](/business/nouns/noun).