import { FlatfileImporter } from './importer'; import { Stats } from './stats'; import { Meta, RawRecordObject, RecordObject } from './interfaces'; import { EndUser } from './user'; import { UploadFile } from './upload-file'; import { StreamedResults } from './streamed-results'; import { FlatfileResults } from './interfaces/results.interface'; export declare class Results implements FlatfileResults { /** * Information about the import */ private $meta; /** * Raw data output from the importer */ private $data; /** * Instance of importer used to manage this file */ private $importer; /** * The raw output from the importer including all deleted rows * and sequence info */ rawOutput: Array; /** * An array of valid data, key-mapped to the configuration provided * (alias of validData) */ data: Array; /** * An array of valid data, key-mapped to the configuration provided */ validData: Array; /** * Rows of data the user excluded from the final results, * key-mapped to the configuration provided */ deletedData: Array; /** * All data from the original file upload including deleted rows, * key-mapped to the configuration provided */ allData: Array; /** * The uuid of the batch assigned by Flatfile (use this in internal * references for support purposes) */ batchId: string; /** * Stats and counts about this file upload */ stats: Stats; /** * The customer provided in setCustomer */ customer: EndUser | null; /** * A File object of the originally uploaded file stored as an AWS url */ originalFile: UploadFile | null; /** * Same as originalFile unless it was uploaded in xls format, in which case this is the converted csv file stored as an AWS url */ csvFile: UploadFile | null; /** * The filename of the originally uploaded file */ fileName: string | null; /** * If the final upload is managed by a private endpoint or not */ managed: boolean; /** * If the data was entered manually instead of via file upload or not */ manual: boolean; /** * The parsed and bootstrapped config object used by this importer instance */ config: object; /** * The configuration used by the csv parser PapaParse: https://www.papaparse.com/docs#config */ parsingConfig: object; /** * The invalid rows that were skipped on submission */ skippedRows: number | null; /** * The headers before they were matched as given in the original file */ headersRaw: Array | null; /** * The headers after they are matched */ headersMatched: Array | null; /** * An array of any columns that were created during import */ customColumns: Array; /** * A mapping of source values to target category values */ categoryFieldMap: object | null; /** * The reason for the failure if there was a failure */ failureReason: string | null; /** * The time that the data was submitted */ submittedAt: string | null; /** * The time that the import failed if it failed */ failedAt: string | null; /** * The time the data began the import, whether via file upload or manual data entry */ createdAt: string; /** * The stylesheet of the cells. Make sure to use `allowFormatting=true` in the config. */ stylesheet: Meta['stylesheet'] | null; /** * Get the next chunk of records */ nextChunk: () => Promise; constructor(data: Array, meta: Meta, importer: FlatfileImporter); private getCSVFile; private getNextChunk; private blobOnly; }