> For the complete documentation index, see [llms.txt](https://docs.carto.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.carto.com/carto-for-developers/reference/carto-api/activity-data-api.md).

# Activity Data API

Export what happened in your organization — who did what, and how much API usage it drove — as CSV or Parquet, for auditing or for loading into your own analytics.

Request a range, poll the job, then download from the returned URLs before they expire.

| Endpoint                                    | What it does                |
| ------------------------------------------- | --------------------------- |
| `POST /activity-data-jobs`                  | Create an activity data job |
| `GET /activity-data-jobs/{jobId}`           | Get an activity data job    |
| `DELETE /activity-data-jobs/{jobId}/cancel` | Cancel an activity data job |

{% hint style="warning" %}
These endpoints live on the **accounts host** — `https://accounts.app.carto.com` — not on your regional API Base URL, and their paths have **no `/v3` prefix**.
{% endhint %}

{% hint style="info" %}
These endpoints need an **OAuth Access Token** from an **Admin** or **Superadmin** user. See [Authorization](/carto-for-developers/reference/carto-api.md#authorization).
{% endhint %}

## Picking a time range

The range must be under **60 days**, start after your account was created, and end no later than the most recent ready data. Data for a day becomes available at **05:00 UTC** the following day, so a range ending today usually fails until then.

For a longer history, request consecutive ranges and stitch the exports together.

## Endpoints

{% openapi src="<https://openapi.gitbook.com/o/zP3LT2Qhlb5jPWQCfWV3/spec/carto-api>" path="/activity-data-jobs" method="post" %}
<https://openapi.gitbook.com/o/zP3LT2Qhlb5jPWQCfWV3/spec/carto-api>
{% endopenapi %}

{% openapi src="<https://openapi.gitbook.com/o/zP3LT2Qhlb5jPWQCfWV3/spec/carto-api>" path="/activity-data-jobs/{jobId}" method="get" %}
<https://openapi.gitbook.com/o/zP3LT2Qhlb5jPWQCfWV3/spec/carto-api>
{% endopenapi %}

{% openapi src="<https://openapi.gitbook.com/o/zP3LT2Qhlb5jPWQCfWV3/spec/carto-api>" path="/activity-data-jobs/{jobId}/cancel" method="delete" %}
<https://openapi.gitbook.com/o/zP3LT2Qhlb5jPWQCfWV3/spec/carto-api>
{% endopenapi %}


---

# 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 dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.carto.com/carto-for-developers/reference/carto-api/activity-data-api.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
