list

Stream raw data (NDJSON formatted) from tables

Data list request are currently limited to tables of 100MB or less. Please use the export methods to retrieve data from larger tables.

HTTP Request

GET /api/v1/tables/:tableId/data
GET /api/v1/datasets/:datasetId/versions/:versionTag/table/data
GET /api/v1/datasets/:datasetId/versions/:versionTag/sample/data

Parameters

Parameter name

Value

Description

Path parameters

:tableId

integer

ID of the requested table

:datasetId

integer

ID of the requested dataset.

:versionTag

string

Version tag of the form v1.0 . You can also specify latest to retrieve the latest version's data.

Query parameters

maxResults

integer

Maximum number of records to return.

selectedVariables

string

List of variables to return (comma-separated). If unspecified, all variables are returned.

startIndex

integer

Zero-based index of the starting row to read.

Request body

Do not supply a request body with this method.

Data.data — You must have "data" access to the table.

Public — The data in the table must be publicly available.

Response

Returns a newline-delimited JSON array, with an entry for each record.

{ string(variable1.name): value, string(variable2.name): value } // row1
{ string(variable1.name): value, string(variable2.name): value } // row2
// ... etc
/*
"value" will be a string for non-numeric, non-boolean types
*and* integer types (to handle precision appropriately for 64-bit integers)
*/

Examples

# Stream a dataset's latest version's data
# This dataset is the public Medicare data available at https://redivis.com/StanfordPHS/datasets/116
curl -H "Authorization: Bearer $ACCESS_TOKEN" \
"https://redivis.com/api/datasets/116/latest/data"
# Stream a table's data
# This table is available at https://redivis.com/projects/1008/tables/9443
curl -H "Authorization: Bearer $ACCESS_TOKEN" \
"https://redivis.com/api/tables/9443/data"