All releases
Feature

Import users from Node: dry run and upload with @productcraft/auth

@productcraft/auth 1.8.0 checks and uploads a user import file in two calls: imports.dryRun() for the counts, imports.create() for the job.

Pass the CSV or NDJSON file as it is, a string, Buffer, Blob or stream, with its content type and charset (text/csv; charset=windows-1252 for Excel files saved on Windows). imports.dryRun() answers with how many rows are valid and what the import would create, update or skip, without writing anything. imports.create() starts the import and returns the job to poll with imports.retrieve(). Saved column mappings and the list of recent imports are in the SDK too. See Migrating users.