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

# TypeScript SDK

> Use the official Darwin client in Node.js and TypeScript.

## Install

```bash theme={null}
npm install @darwin-so/sdk
```

## Send a message

```typescript theme={null}
import { DarwinClient } from '@darwin-so/sdk';

const darwin = new DarwinClient({
  token: process.env.DARWIN_API_KEY,
});

const turn = await darwin.agent.createMessage({
  content: 'Help me prepare a private goal.',
});
```

Fern generates the SDK from Darwin's reviewed public OpenAPI contract. Private production controllers are not included.

<Warning>
  Keep the API key on your server. Do not ship it in browser code, mobile bundles, or model-visible prompt text.
</Warning>
