> 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/api-documentation/getting-started/making-your-first-api-request.md).

# Making your first API request

This start guide will take you through making your first request to the Make API.

*Example:* *Let's imagine that you would like to list all data stores available in your team. Your team ID is 35. Returned data should be ordered in descending order.*

To make your first API call, you need to perform the following actions:

{% stepper %}
{% step %}
**Create an authentication token**. The token gives you access to Make API resources depending on your [Make role and assigned scopes](/api-documentation/authentication/api-scopes-overview.md). You must include the token in the **Authorization** header of all requests. Add the word **Token** and a space before the token itself:

```
'Authorization: Token {Your authentication token}'
```

{% endstep %}

{% step %}
**Choose the** [endpoint](/api-documentation/getting-started/resources.md) **that corresponds to the resource you want to interact with.** For this example, you need the `/data-stores` endpoint. The endpoint requires the `teamId` query parameter. Place the parameter after the question mark in the endpoint URL. To filter results, you also need the [parameter for ordering data](/api-documentation/pagination-sorting-filtering/pagination-and-sorting.md) - `pg[sortDir]`:

```
{zone_url}/api/v2/data-stores?teamId={teamId}&pg%5BsortDir%5D=asc
```

{% hint style="warning" %}
The `zone_url` refers to the Make zone you interact with. For example, `https://eu1.make.com.`
{% endhint %}
{% endstep %}

{% step %}
**Prepare the full request and send it.** In this case, use cURL to making the request. You want to retrieve data without modifying it - use the `GET` method. Let's put elements from the previous steps together.

{% hint style="warning" %}
The following request example contains a sample authentication token. Don't use it in your requests. [Generate your own token](/api-documentation/authentication/create-authentication-token.md).
{% endhint %}

Request:

```bash
curl --location \
--request GET 'https://eu1.make.com/api/v2/data-stores?teamId=35&pg%5BsortDir%5D=asc' \
--header 'Content-Type: application/json' \
--header 'Authorization: Token 93dc8837-2911-4711-a766-59c1167a974d'
```

Response:

```json
{
  "dataStores": [
    {
      "id": 15043,
      "name": "Old data store",
      "records": 10,
      "size": "620",
      "maxSize": "1048576",
      "teamId": 35
    },
    {
      "id": 13433,
      "name": "New data store",
      "records": 1,
      "size": "48",
      "maxSize": "1048576",
      "teamId": 35
    }
  ],
  "pg": {
    "sortBy": "name",
    "limit": 10000,
    "sortDir": "asc",
    "offset": 0
  }
}
```

Always include a request body in `POST`, `PUT`, or `PATCH` requests.
{% endstep %}

{% step %}
**Evaluate the response.** The API returns `200 OK` and a list of all data stores for the specified team. If your request failed, you receive an error code. Refer to [Troubleshooting and error handling](/api-documentation/troubleshooting.md) to troubleshoot the issue.
{% endstep %}
{% endstepper %}


---

# 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/api-documentation/getting-started/making-your-first-api-request.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.
