Tables

Data preview

Returns up to 1000 rows from a table in CSV (RFC) or JSON format. Rows can be filtered by the same filters as the asynchronous export (changedSince, changedUntil, columns, whereFilters, orderBy, fulltextSearch). For a full table download use the asynchronous export.

The isTruncated flag is true if the value is >16k chars and the response type is JSON.

HTTP Compression

To enable compression of the API response traffic, include the HTTP header Accept-encoding: gzip with the request.

get/v2/storage/tables/{tableId}/data-preview

Request

Path parameters

tableIdstring required

Table string identifier (e.g. in.c-main.my-table).

Query parameters

limitinteger

Limit the number of returned rows. Maximum allowed value is 1000.

Example:100
changedSincestring nullable

Filtering by import date - the import timestamp is stored within each row. Accepts a unix timestamp or any date accepted by strtotime.

Example:-2 days
changedUntilstring nullable

Filtering by import date - the import timestamp is stored within each row. Accepts a unix timestamp or any date accepted by strtotime.

Example:2013-02-12T15:19:21+00:00
columnsstring nullable

Comma separated list of columns to export; by default all columns are exported.

Example:id,name
whereColumnstring nullable

Deprecated (use whereFilters instead). Column for exporting only matching rows.

Example:id
whereValues[]string[] nullable

Deprecated (use whereFilters instead). Values for exporting only matching rows.

[
  "26"
]
whereOperator'eq' | 'ne' nullable

Deprecated (use whereFilters instead). Operator for value comparison: eq (can be used with multiple values) or ne.

format'rfc' | 'json' nullable

Output format of the preview: rfc returns CSV, json returns JSON.

Example:json
columnstring required

Column to filter by.

operator'eq' | 'ne' | 'gt' | 'ge' | 'lt' | 'le'

eq/ne support multiple values (IN/NOT IN semantics); gt/ge/lt/le accept a single value only.

valuesstring[] required

Values to compare against.

dataTypestring nullable

Cast the column to this data type before comparing (INTEGER or DOUBLE on Snowflake; STRING, INTEGER, DOUBLE, BIGINT, REAL, DECIMAL or TIMESTAMP on BigQuery). Required for gt/ge/lt/le on numeric values; must be empty or TIMESTAMP when type is TIME_STRING.

type'SCALAR' | 'TIME_STRING'

How values are interpreted. SCALAR compares raw values; TIME_STRING interprets them as date/time strings or unix timestamps.

columnstring required

Column to sort by.

order'ASC' | 'DESC'

Sort direction.

dataTypestring nullable

Cast the column to this data type before sorting (INTEGER or DOUBLE on Snowflake; STRING, INTEGER, DOUBLE, BIGINT, REAL, DECIMAL or TIMESTAMP on BigQuery). Required when sorting a numeric column; disallowed for typed tables.

fulltextSearchstring nullable

Fulltext search over all data in the table. Cannot be combined with whereFilters. Snowflake/BigQuery only.

Example:czech
cacheboolean

A JSON preview requested without any other parameter is served from a cache that is refreshed whenever the table changes. Set to 0 to always read the data from the backend.

Response

Table data in the requested format (CSV or JSON).

columnsstring[] required

Changes

No recorded changes to this operation across all 1 revision of this API.