Search documentation
karat

+

K

User Documentation ↗

Read Table Dataset

GET/api/v2/datasets/{datasetRid}/readTable

Gets the content of a dataset as a table in the specified format.

This endpoint currently does not support views (virtual datasets composed of other datasets).

Third-party applications using this endpoint via OAuth2 must request the following operation scope: api:datasets-read.

Path parameters

datasetRid
string

The Resource Identifier (RID) of a Dataset.

Query parameters

branchName
string
optional

The name of the Branch.

startTransactionRid
string
optional

The Resource Identifier (RID) of the start Transaction.

endTransactionRid
string
optional

The Resource Identifier (RID) of the end Transaction.

format
string (enum)

The export format. Must be ARROW or CSV.

Enum values: ARROW, CSV

columns
list<string>
optional

A subset of the dataset columns to include in the result. Defaults to all columns.

rowLimit
integer
optional

A limit on the number of rows to return. Note that row ordering is non-deterministic.

Response body

body
string

Examples

Request

Copied!
1 2 3 curl \ -H "Authorization: Bearer $TOKEN" \ "https://$HOSTNAME/api/v2/datasets/ri.foundry.main.dataset.c26f11c8-cdb3-4f44-9f5d-9816ea1c82da/readTable?branchName=master&startTransactionRid=ri.foundry.main.transaction.0a0207cb-26b7-415b-bc80-66a3aa3933f4&endTransactionRid=ri.foundry.main.transaction.0a0207cb-26b7-415b-bc80-66a3aa3933f4&format=CSV&columns=%5B%22id%22%2C%22firstName%22%2C%22lastName%22%5D"

Error responses

Error Name
ReadTablePermissionDeniedError CodePERMISSION_DENIED
Status Code403
DescriptionThe provided token does not have permission to read the given dataset as a table.
ParametersdatasetRid
SchemaNotFoundError CodeNOT_FOUND
Status Code404
DescriptionA schema could not be found for the given dataset and branch, or the client token does not have access to it.
ParametersdatasetRid, branchName, transactionRid
ColumnTypesNotSupportedError CodeINVALID_ARGUMENT
Status Code400
DescriptionThe dataset contains column types that are not supported.
ParametersdatasetRid
ReadTableDatasetPermissionDeniedError CodePERMISSION_DENIED
Status Code403
DescriptionCould not readTable the Dataset.
ParametersdatasetRid