> For the complete documentation index, see [llms.txt](https://developers.make.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://developers.make.com/make-sdk/make-typescript-sdk.md).

# Make TypeScript SDK

Use the Make TypeScript SDK to work with the Make API from your application, scripts, or AI agent. The `@makehq/sdk` package provides typed methods for resources such as scenarios, connections, teams, data stores, and custom apps. It also works in JavaScript projects.

Use this SDK when you want to manage Make resources. To call an app action directly through Make Endpoints, use the [Make Endpoints SDK](/make-sdk/make-endpoints-sdk.md).

### Before you begin

You'll need:

* Node.js 20 or later for the npm package.
* A Make account with access to the API resources you want to use.
* A Make API key with the required scopes. For example, listing scenarios requires `scenarios:read`.
* Your Make zone, such as  `us1.make.com`, and the team or organization ID required by the operation.

Store the API key in an environment variable or a secrets manager on your server. Don’t commit it to source control, include it in browser code, or put it in a prompt.

### Install the SDK

Install the npm package in your project:

```bash
npm install @makehq/sdk
```

For Deno, the SDK is also available from JSR:

```bash
deno add jsr:@make/sdk
```

### Make your first request

Set `MAKE_API_KEY`, `MAKE_ZONE`, and `MAKE_TEAM_ID` as environment variables where your code runs. Enter the zone as a hostname without `https://` or `/api/v2`. The client builds the API URL.

Save the following example as `list-scenarios.mjs`. You can use the same SDK calls in TypeScript, with type checking and editor completion.

```javascript
import { Make } from '@makehq/sdk';

const apiKey = process.env.MAKE_API_KEY;
const zone = process.env.MAKE_ZONE;
const teamId = Number(process.env.MAKE_TEAM_ID);

if (!apiKey || !zone || !Number.isSafeInteger(teamId) || teamId <= 0) {
  throw new Error('Set MAKE_API_KEY, MAKE_ZONE, and a positive MAKE_TEAM_ID.');
}

const make = new Make(apiKey, zone);
const scenarios = await make.scenarios.list(teamId);
console.log(JSON.stringify(scenarios, null, 2));
```

Run it with your environment variables set:

```bash
node list-scenarios.mjs
```

Use your own team ID. The API still enforces your key's scopes and permissions in Make.

### Work with Make resources

The SDK groups methods by resource, such as `make.scenarios`, `make.connections`, `make.teams`, and `make.dataStores`. Use the generated API reference and your editor's type information to check each method's required arguments and return type.

Methods for developing custom apps are available under `make.sdk`. These methods manage app definitions and components. To call app actions, use the Endpoints SDK instead.

You can configure optional retries for rate-limit and server-error responses. They're disabled by default. Enable them only when repeating the request is safe.

### Use the SDK with AI agents

`@makehq/sdk/tools` exports `MakeTools`. Each tool includes a name, description, input schema, and a function. An agent framework can use these definitions without building Make API requests itself.

For example, choose the scenario-listing tool and give your model only its description and schema:

```javascript
import { MakeTools } from '@makehq/sdk/tools';

const selectedTools = MakeTools.filter(
  (tool) => tool.name === 'scenarios_list',
);

const toolDefinitions = selectedTools.map((tool) => ({
  name: tool.name,
  description: tool.description,
  inputSchema: tool.inputSchema,
}));

console.log(JSON.stringify(toolDefinitions, null, 2));
```

Your application must validate arguments, enforce which team or organization the agent can use, and decide which actions the agent can run.

Don't give the model access to the authenticated `Make` client, and expose only the tools the task needs.

### Resources

* [npm: @makehq/sdk](https://www.npmjs.com/package/@makehq/sdk)
* [GitHub: make-typescript-sdk](https://github.com/integromat/make-typescript-sdk)
* [TypeScript SDK API reference](https://integromat.github.io/make-typescript-sdk/)
* [Make API documentation](https://developers.make.com/api-documentation)
* [API scopes overview](https://developers.make.com/api-documentation/authentication/api-scopes-overview)


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://developers.make.com/make-sdk/make-typescript-sdk.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
