# Import sheet from CSV / XLSX (deprecated) Imports CSV or XLSX data into a new sheet in the top-level "Sheets" folder. Note the following: * Both sheetName and the file name must use ASCII characters. * The source data must be basic text. To include rich formula data, import and create a sheet first, and then use Update Rows. To work with images, see Cell Images. * XLS is not supported. You must use XLSX. * Hierarchical relationships between rows in an external file won't import. DEPRECATED - The Sheets folder is being replaced by workspaces. To adapt to this change, please see Migrate from using the Sheets folder. Endpoint: POST /sheets/import Version: 2.0.0 Security: APIToken, OAuth2 ## Header parameters: - `Authorization` (string) API Access Token used to authenticate requests to Smartsheet APIs. - `smartsheet-integration-source` (string) Uses the following metadata to distinguish between human-initiated API requests and third-party service-initiated calls by AI Connectors or ITSM: - Integration source type - Organization name - Integration source name Format: TYPE,OrgName,SourceName Examples: AI,SampleOrg,My-AI-Connector-v2 SCRIPT,SampleOrg2,Accounting-updater-script APPLICATION,SampleOrg3,SheetUpdater Example: "AI,SampleOrg,My-AI-Connector-v2" - `Content-Disposition` (string) Should be equal to "attachment" to tell the API that a file is in the body of the POST request, followed by a semicolon, followed by filename= and the URL-encoded filename in quotes Example: "attachment; filename=\"ProgressReport.docx\"" - `Content-Type` (string, required) Required for POST request to import a sheet from CSV/XLSX file. * For CSV files, use: Content-Type: text/csv * For XLSX files, use: Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet Enum: "text/csv", "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet" ## Query parameters: - `sheetName` (string, required) Desired name of the sheet. - `headerRowIndex` (number) A zero-based integer indicating the row number to use for column names. Rows before this are omitted. If not specified, the default values are Column1, Column2, etc. - `primaryColumnIndex` (number) A zero-based integer indicating the column to designate as primary. ## Response 200 fields (application/json): - `message` (string) Message that indicates the outcome of the request. (One of SUCCESS or PARTIAL_SUCCESS.) Enum: "PARTIAL_SUCCESS", "SUCCESS" - `resultCode` (number) * '0' Success * '3' Partial Success of Bulk Operation Enum: 0, 3 - `result` (object) Sheet imported from CSV / XLSX file. - `result.accessLevel` (string) Enum: "ADMIN", "COMMENTER", "EDITOR", "EDITOR_SHARE", "OWNER", "VIEWER" - `result.id` (number) Sheet ID. - `result.name` (string) Sheet name. - `result.type` (string) Container type. Has 'sheet' value for the imported sheet. - `result.permalink` (string) URL that represents a direct link to the sheet in Smartsheet. ## Response default fields (application/json): - `refId` (string) The ID of the specific error occurrence. Please include this information when contacting Smartsheet support. - `errorCode` (number) Custom error code from Smartsheet. See the complete [Error Code List](/api/smartsheet/error-codes). - `message` (string) Descriptive error message.