> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://fastpix.com/docs/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://fastpix.com/docs/_mcp/server.

# List raw view exports

GET https://api.fastpix.com/v1/data/exports/rawViews

This endpoint returns the daily exports of your raw view data. Each export covers one full UTC day and contains every view that completed on that date, with a time-limited URL to download it as a CSV file.

Exports are generated once a day by a scheduled job and are retained for **7 days**, after which the file is deleted and no longer returned. Only dates on or after the day your workspace enabled exports are available; earlier dates are never backfilled.

#### Enabling exports

Exports are not generated until your workspace enables them, and the **first request to this endpoint performs that enablement**. That request checks your organization's plan, records the decision, and returns an empty list together with a `message` naming the date your first file will cover.

Exports are available on paid plans. If your organization is not eligible the first request fails with **403**, and nothing is enabled. Only that first request can fail that way — once enabled, listing and downloading are never plan-checked again, and a workspace that later downgrades keeps access to files it has already generated until they expire.

Your first file is produced by the next scheduled run, and covers the whole UTC day on which you enabled exports, including views that completed earlier that day.

#### Key fields in response

* **timeFrame:** The effective query window, as unix epoch timestamps.
* **totalRowCount:** The number of export records returned.
* **message:** Present only on the request that enabled exports, confirming the date of your first file.
* **exportDate:** The UTC date the export covers.
* **status:** The state of the export. `COMPLETED` for a day with views, `EMPTY` for a day with none.
* **files:** The files for this export. Each export produces a single file, returned as a one-item array.
* **downloadUrl:** A time-limited URL that downloads the export as `views_{date}.csv`.
* **downloadUrlExpiresAt:** When the download URL stops working. This matches the moment the file itself is deleted.
* **rowCount:** The number of data rows in the file, excluding the header row.
* **version:** The CSV format version.

#### Downloading

The download gives you a plain CSV file, saved as `views_{date}.csv`. Browsers and most HTTP clients — including Python `requests`, `httpx` and JavaScript `fetch` — handle it automatically, so you can open or parse it directly.

The file is compressed in transit to save bandwidth. Clients that do not request compression, such as `curl`, `wget` and Java's `HttpClient`, receive those compressed bytes instead of the CSV. With `curl`, ask for decompression explicitly:

```
curl --compressed -o views_2026-08-16.csv "<downloadUrl>"
```

Exports can be large — a busy day of roughly 200,000 views produces several hundred megabytes of CSV. Stream the file to disk and parse it row by row rather than loading it into memory, and use a database or data warehouse rather than a spreadsheet on high-volume days.

#### Notes for consumers

* A day with no views returns `EMPTY` with `rowCount` of 0 and a valid file containing only the header row. This is a success, not an error, and needs no special handling or retry.
* Parse the CSV by column name, never by column position. New columns are appended over time.
* If you download the same date more than once, replace that date's rows rather than appending them.
* Do not store or share download URLs. Each one grants direct access to your view data and stays valid until the file itself expires.

Reference: https://fastpix.com/docs/video-data-api/exports/list-raw-view-exports

## Authentication

- `Authorization` header (basic auth, required) — FastPix APIs are secured with Basic Authentication. Use your Access Token ID as the username and Secret Key as the password in the Authorization header of each API request. * Username: Access Token ID * Password: Secret Key Activate your FastPix account to generate your API credentials. See the guide here

## Request

### Query parameters

- `timespan[]` (enum, optional, default: 7:days) — This parameter specifies the time span the exports must be retrieved for, given as a duration string. Exports are retained for 7 days, so the accepted range is narrower than on other data endpoints. When omitted, the full 7-day retention window is returned. **Accepted format is:** duration string for example `timespan[]=1:days` or `timespan[]=7:days`
  - Allowed values: `1:days`, `2:days`, `3:days`, `4:days`, `5:days`, `6:days`, `7:days`

## Response

### 200

List of raw view data exports available for download.

- `success` (boolean, optional) — Shows the request status. Returns true for success and false for failure.
- `data` (DataExportsRawViewsGetResponsesContentApplicationJsonSchemaData, optional) — Displays the result of the request.

## Types

### DataExportsRawViewsGetResponsesContentApplicationJsonSchemaData

Displays the result of the request.

- `timeFrame` (list of integer, optional) — The timespan from and to details displayed in the form of unix epoch timestamps.
- `totalRowCount` (integer, optional) — The number of export records returned.
- `message` (string, optional) — Present only on the request that enabled exports for the workspace, confirming the date your first file will cover.
- `data` (list of RawViewExportsItems, optional) — The daily exports of raw view data available for download, most recent date first.

### RawViewExportsItems

- `exportDate` (string, optional, nullable) — The UTC date this export covers.
- `status` (enum, optional, nullable) — The state of the export. `COMPLETED` for a day with views, `EMPTY` for a day with none. An `EMPTY` export is still downloadable and contains the header row.
  - Allowed values: `COMPLETED`, `EMPTY`
- `files` (list of RawViewExportsItemsFilesItems, optional) — The files for this export. Each export produces a single file, returned as a one-item array.

### RawViewExportsItemsFilesItems

- `type` (string, optional, nullable) — The file format. Currently always csv.
- `downloadUrl` (string, optional, nullable) — A time-limited URL that downloads the export directly from storage, saved as `views_{date}.csv`. The file is sent using gzip transfer encoding and arrives decompressed; clients that do not request compression, such as `curl` and `wget`, receive the compressed bytes instead. The URL path ends in `.csv.gz` because that is how the object is stored — the downloaded file is a plain CSV. Do not store or share the URL. It grants direct access to your view data and stays valid until the file itself expires.
- `version` (string, optional, nullable) — The CSV format version, also recorded in the file path.
- `rowCount` (integer, optional, nullable) — The number of data rows in this file, excluding the header row.
- `downloadUrlExpiresAt` (string, optional, nullable) — When the download URL stops working, as an RFC 3339 UTC timestamp. This matches the moment the file itself is deleted at the end of its 7-day retention.

## Examples

### Exports available for download

**Response**

```json
{
  "success": true,
  "data": {
    "timeFrame": [
      1786342134,
      1786946934
    ],
    "totalRowCount": 0,
    "message": "Exports are now enabled for this workspace. Your first CSV covers today (UTC) and will be generated by the scheduled job at 04:00 UTC. Dates before today are not exported.",
    "data": []
  }
}
```

**SDK Code**

```python Exports available for download
import requests

url = "https://api.fastpix.com/v1/data/exports/rawViews"

response = requests.get(url, auth=("<username>", "<password>"))

print(response.json())
```

```javascript Exports available for download
const url = 'https://api.fastpix.com/v1/data/exports/rawViews';
const credentials = btoa("<username>:<password>");

const options = {method: 'GET', headers: {Authorization: `Basic ${credentials}`}};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
```

```go Exports available for download
package main

import (
	"fmt"
	"net/http"
	"io"
)

func main() {

	url := "https://api.fastpix.com/v1/data/exports/rawViews"

	req, _ := http.NewRequest("GET", url, nil)

	req.SetBasicAuth("<username>", "<password>")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
```

```ruby Exports available for download
require 'uri'
require 'net/http'

url = URI("https://api.fastpix.com/v1/data/exports/rawViews")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)
request.basic_auth("<username>", "<password>")

response = http.request(request)
puts response.read_body
```

```java Exports available for download
import com.mashape.unirest.http.HttpResponse;
import com.mashape.unirest.http.Unirest;

HttpResponse<String> response = Unirest.get("https://api.fastpix.com/v1/data/exports/rawViews")
  .basicAuth("<username>", "<password>")
  .asString();
```

```php Exports available for download
<?php
require_once('vendor/autoload.php');

$client = new \GuzzleHttp\Client();

$response = $client->request('GET', 'https://api.fastpix.com/v1/data/exports/rawViews', [
  'headers' => [
  ],
    'auth' => ['<username>', '<password>'],
]);

echo $response->getBody();
```

```csharp Exports available for download
using RestSharp;
using RestSharp.Authenticators;

var client = new RestClient("https://api.fastpix.com/v1/data/exports/rawViews");
client.Authenticator = new HttpBasicAuthenticator("<username>", "<password>");
var request = new RestRequest(Method.GET);

IRestResponse response = client.Execute(request);
```

```swift Exports available for download
import Foundation

let credentials = Data("<username>:<password>".utf8).base64EncodedString()

let headers = ["Authorization": "Basic \(credentials)"]

let request = NSMutableURLRequest(url: NSURL(string: "https://api.fastpix.com/v1/data/exports/rawViews")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"
request.allHTTPHeaderFields = headers

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
```

### First request, which enables exports for the workspace

**Response**

```json
{
  "success": true,
  "data": {
    "timeFrame": [
      1786342134,
      1786946934
    ],
    "totalRowCount": 0,
    "message": "Exports are now enabled for this workspace. Your first CSV covers today (UTC) and will be generated by the scheduled job at 04:00 UTC. Dates before today are not exported.",
    "data": []
  }
}
```

**SDK Code**

```python First request, which enables exports for the workspace
import requests

url = "https://api.fastpix.com/v1/data/exports/rawViews"

response = requests.get(url, auth=("<username>", "<password>"))

print(response.json())
```

```javascript First request, which enables exports for the workspace
const url = 'https://api.fastpix.com/v1/data/exports/rawViews';
const credentials = btoa("<username>:<password>");

const options = {method: 'GET', headers: {Authorization: `Basic ${credentials}`}};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
```

```go First request, which enables exports for the workspace
package main

import (
	"fmt"
	"net/http"
	"io"
)

func main() {

	url := "https://api.fastpix.com/v1/data/exports/rawViews"

	req, _ := http.NewRequest("GET", url, nil)

	req.SetBasicAuth("<username>", "<password>")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
```

```ruby First request, which enables exports for the workspace
require 'uri'
require 'net/http'

url = URI("https://api.fastpix.com/v1/data/exports/rawViews")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)
request.basic_auth("<username>", "<password>")

response = http.request(request)
puts response.read_body
```

```java First request, which enables exports for the workspace
import com.mashape.unirest.http.HttpResponse;
import com.mashape.unirest.http.Unirest;

HttpResponse<String> response = Unirest.get("https://api.fastpix.com/v1/data/exports/rawViews")
  .basicAuth("<username>", "<password>")
  .asString();
```

```php First request, which enables exports for the workspace
<?php
require_once('vendor/autoload.php');

$client = new \GuzzleHttp\Client();

$response = $client->request('GET', 'https://api.fastpix.com/v1/data/exports/rawViews', [
  'headers' => [
  ],
    'auth' => ['<username>', '<password>'],
]);

echo $response->getBody();
```

```csharp First request, which enables exports for the workspace
using RestSharp;
using RestSharp.Authenticators;

var client = new RestClient("https://api.fastpix.com/v1/data/exports/rawViews");
client.Authenticator = new HttpBasicAuthenticator("<username>", "<password>");
var request = new RestRequest(Method.GET);

IRestResponse response = client.Execute(request);
```

```swift First request, which enables exports for the workspace
import Foundation

let credentials = Data("<username>:<password>".utf8).base64EncodedString()

let headers = ["Authorization": "Basic \(credentials)"]

let request = NSMutableURLRequest(url: NSURL(string: "https://api.fastpix.com/v1/data/exports/rawViews")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"
request.allHTTPHeaderFields = headers

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
```