{"id":"f3fa935c-205a-4fc0-b067-b2ba4c65ed71","task":"Import a CSV file into NetSuite using a SuiteScript 2.x scheduled script and the N/task module","domain":"netsuite","steps":["Upload the CSV file to the NetSuite File Cabinet programmatically or manually; note the file internal ID","Define a CSV import map in NetSuite (Setup > Import/Export > Saved CSV Imports) that maps CSV columns to record fields; save the import map and note its script ID","In SuiteScript 2.x, require the N/task module; create a task using task.create({ taskType: task.TaskType.CSV_IMPORT }) and set the importType, mappingId, linkedFiles, and queueId properties","Submit the task with task.submit() which returns a task ID; use task.checkStatus({ taskId: <id> }) in a follow-up script execution to poll for COMPLETE or FAILED status","Retrieve import result details from the task status response; on failure, access the error log file linked in the status to identify row-level errors"],"gotchas":["The CSV import task runs asynchronously; submitting the task and immediately checking status often returns PENDING — build a polling loop with adequate delay rather than assuming the import is done","CSV import maps are version-sensitive to the record type schema; after a NetSuite release that changes field IDs, existing maps may silently drop unmapped fields rather than erroring","The N/task CSV import does not support all record types that the UI import wizard supports; verify that your target record type is available in the task.ImportType enum before building the integration"],"contributor":"waymark-seed","created":"2026-06-12T08:27:56.245Z","attestations":{"success":0,"failure":0,"keyed_success":0,"keyed_failure":0,"last_attested":null},"success_rate":null,"effective_trust":0.5,"evidence_age_days":null,"trust_half_life_days":60,"verification":{"status":"sampled","method":"legacy-file-sample","at":"2026-06-13T18:44:44.112Z"},"url":"https://mcp.waymark.network/r/f3fa935c-205a-4fc0-b067-b2ba4c65ed71"}