> For the complete documentation index, see [llms.txt](https://docs.redivis.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.redivis.com/api/rest-api/exports/post.md).

# post

## Overview

This endpoint is used for preparing an export of a table on Redivis.

## HTTP Request

```http
POST /tables/:tableReference/exports
POST /workflows/:workflowReference/tables/:tableReference/exports
```

{% hint style="info" %}
When using the `/workflows/:workflowReference/tables/:tableReference` form, `tableReference` may be the table's name (and optional reference id) alone, and can refer to any table in the workflow, including tables from the workflow's datasources. See [referencing tables within a workflow](https://docs.redivis.com/api/referencing-resources.md#referencing-tables-within-a-workflow).
{% endhint %}

```http
POST /tables/:tableReference/uploads/:uploadName/exports
```

{% hint style="info" %}
Uploads can only be exported from unreleased versions.
{% endhint %}

```http
POST /queries/:queryId/exports
```

{% hint style="info" %}
Queries can only be exported within 24 hours after the query has completed.
{% endhint %}

## Path parameters

<table><thead><tr><th width="302.5">Parameter</th><th></th></tr></thead><tbody><tr><td>tableReference</td><td>A qualified reference to the table to be exported. See <a href="https://docs.redivis.com/api/referencing-resources.md">referencing resources</a> for more information.</td></tr><tr><td>workflowReference</td><td>A qualified reference to a workflow. When provided, <code>tableReference</code> may be the table's name alone, and can refer to any table in the workflow, including tables from the workflow's datasources.</td></tr></tbody></table>

{% hint style="info" %}
This endpoint extends the [general API structure](https://docs.redivis.com/api/rest-api/general-structure.md)
{% endhint %}

## Request body

Provide a JSON object with information about the dataset.

<table><thead><tr><th width="172.66666666666669">Property name</th><th width="134">Type</th><th>Description</th></tr></thead><tbody><tr><td><strong>format</strong></td><td><strong>string</strong></td><td>The type output format of the export. Must be one of <code>"csv" | "parquet" | "jsonl" | "avro" | "sas7bdat" | "dta" | "sav"</code>.<br><br>If not specified, "csv" will be used.</td></tr></tbody></table>

## Authorization

Data access to all tables referenced by the query is required. If a table's data is not public, your access token must have one of the following scopes:

* data.data
* data.edit

[Learn more about authorization.](https://docs.redivis.com/api/rest-api/authorization.md)

## Response body

Returns the JSON-encoded "get" representation of an [export resource](https://docs.redivis.com/api/resource-definitions/export.md).


---

# 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://docs.redivis.com/api/rest-api/exports/post.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.
