# Reports

## Get the list of available reports

## Available reports

<mark style="color:blue;">`GET`</mark> `https://bottalk.io/api/reports`

Fetches a list of available report

{% tabs %}
{% tab title="200 ok" %}

```javascript
{
  "result": "ok",
  "reports": [
    {
      "name": "AvgListen",
      "title": "Average Listen Report",
      "params": {
        "date_start": "today",
        "date_end": "tomorrow"
      },
      "columns": {
        "d": "Date",
        "vg": "Average Listen Length (% of article)",
        "project_id": "Project"
      }
    },
    {
      "name": "ActiveUsers",
      "title": "Playback Started Report",
      "params": {
        "date_start": "today",
        "date_end": "tomorrow"
      },
      "columns": {
        "d": "Date",
        "au": "Active Users",
        "project_id": "Project"
      }
    },
    {
      "name": "UniqueShows",
      "title": "Unique Shows Report",
      "params": {
        "date_start": "today",
        "date_end": "tomorrow"
      },
      "columns": {
        "d": "Date",
        "imp": "Unique Users",
        "project_id": "Project"
      }
    },
    {
      "name": "CTR",
      "title": "CTR Report",
      "params": {
        "date_start": "today",
        "date_end": "tomorrow"
      },
      "columns": {
        "d": "Date",
        "imp": "Impressions",
        "au": "Clicks",
        "ctr": "CTR",
        "project_id": "Project"
      }
    },
    {
      "name": "UsersMoreThanTime",
      "title": "UsersMoreThanTime Report",
      "params": {
        "date_start": "today",
        "date_end": "tomorrow",
        "time": 60
      },
      "columns": {
        "d": "Date",
        "nu": "Number of users",
        "perc": "Percent of users",
        "project_id": "Project"
      }
    },
    {
      "name": "UsersMoreThan",
      "title": "UsersMoreThan Report",
      "params": {
        "date_start": "today",
        "date_end": "tomorrow",
        "percent": 50
      },
      "columns": {
        "d": "Date",
        "nu": "Number of users",
        "perc": "Percent of users",
        "project_id": "Project"
      }
    },
    {
      "name": "CohortListenPercent",
      "title": "Cohort average listeners report",
      "params": {
        "date_start": "today",
        "date_end": "tomorrow"
      },
      "columns": {
        "p": "Percent of article",
        "users": "Number of Users",
        "percent": "Percent of Users",
        "project_id": "Project"
      }
    },
    {
      "name": "PopularArticles",
      "title": "Popular Articles Report",
      "params": {
        "date_start": "today",
        "date_end": "tomorrow"
      },
      "columns": {
        "cnt": "Number of listeners",
        "title": "Title"
      }
    },
    {
      "name": "CohortArticles",
      "title": "Cohort Articles Report",
      "params": {
        "date_start": "today",
        "date_end": "tomorrow"
      },
      "columns": {
        "cnt": "Number of listeners",
        "title": "Title"
      }
    }
  ]
}
```

{% endtab %}

{% tab title="401 Permission denied" %}

{% endtab %}
{% endtabs %}

## Get an individual report

## Fetch the report data

<mark style="color:blue;">`GET`</mark> `https://bottalk.io/api/reports`

Get the data for individual report by `name`. The parameters vary from one report to another. See [available reports](#get-the-list-of-available-reports) section to the the parameters needed for the request.&#x20;

{% tabs %}
{% tab title="200 ok" %}

```javascript
{
  "result": "ok",
  "headers": {
    "p": "Percent of article",
    "users": "Number of Users",
    "percent": "Percent of Users",
    "project_id": "Project"
  },
  "title": "Users listening more than X% of article (2019-12-09 00:00:00 - 2019-12-10 23:59:59)",
  "report": [
    {
      "p": 0,
      "users": 0,
      "percent": "0%",
      "project_id": "My test project"
    },
    {
      "p": 10,
      "users": 0,
      "percent": "0%",
      "project_id": "My test project"
    },
    {
      "p": 20,
      "users": 0,
      "percent": "0%",
      "project_id": "My test project"
    },
    {
      "p": 30,
      "users": 0,
      "percent": "0%",
      "project_id": "My test project"
    },
    {
      "p": 40,
      "users": 0,
      "percent": "0%",
      "project_id": "My test project"
    },
    {
      "p": 50,
      "users": 0,
      "percent": "0%",
      "project_id": "My test project"
    },
    {
      "p": 60,
      "users": 0,
      "percent": "0%",
      "project_id": "My test project"
    },
    {
      "p": 70,
      "users": 0,
      "percent": "0%",
      "project_id": "My test project"
    },
    {
      "p": 80,
      "users": 0,
      "percent": "0%",
      "project_id": "My test project"
    },
    {
      "p": 90,
      "users": 0,
      "percent": "0%",
      "project_id": "My test project"
    },
    {
      "p": 100,
      "users": 0,
      "percent": "0%",
      "project_id": "My test project"
    }
  ]
}
```

{% endtab %}

{% tab title="401 Permission denied" %}

{% endtab %}
{% endtabs %}


---

# Agent Instructions: 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:

```
GET https://docs.bottalk.io/docs/help/endpoints/reports.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
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.
