Download a Data Table

Download a Data Table as a CSV or Excel (xlsx) file.


Permissions Required

You must have permissions to read the Data Table for this request to succeed.

Method Signature

download(id: string, format: DataTableExportFormat, path: string): Promise<void>;
download(id: string, format: DataTableExportFormat, path: string, callback: (err?: Error) => any): void;


idstringThe id of the Data Table to download
formatstringCSV or XLSX (Excel)
filePathstringThe path on disk to save the download to.
callback(err?: Error) => anyOptional The callback


 * This example demonstrates downloading a Data Table
const { CatalyticClient } = require('@catalytic/sdk');

const catalytic = new CatalyticClient();

const id = 'c9f2beec-10c0-4f2f-b4e0-1d884c7e053c';
const downloadPath = '/path/to/download/location/for/file';
await, 'CSV', downloadPath);

console.log(`DataTable downloaded to "${downloadPath}"`);