Data Import

You can use batch files to send user preferences, actions, award account enrollment, group enrollment, points credits, and points debits to Nitro. Importing data using batch files reduces the administrative time needed to create items individually by leveraging a common format and better enables you to output attributes and actions directly from other systems.

Data import processes data asynchronously and in no particular order. When uploading files, ensure that the data does not need to be processed sequentially. If you do need information processed in a specific order, use separate files and wait until processing of one file is complete before uploading another.

The batch load process supports comma delimited ( , ) and pipe delimited ( | ) formats. For details on file format requirements, see Batch File Requirements.

Import a File in Nitro Studio

Once files are uploaded, they will be processed and available for review.

  1. Create an OAuth client named batch-import that uses the batch_import scope. This OAuth client is required for data import.

  2. Create your import file and ensure its format matches the requirements for that specific file type.

  3. Open Nitro Studio > Tools > Data Import.

  4. On the Import tab, select your file type and click Continue.

  5. Enable the Send an email notification when upload is complete option to be notified when your file has finished processing.

    • Add the email addresses where you want to be notified. Nitro supports up to 50 email addresses.

    • Select Only send an email if the upload has errors if you do not want to receive an email for successful uploads.

  6. Load your file using drag and drop or browse, and then click Upload.

Errors that appear on the import page indicate the file was not accepted for processing. This may be because the file was too large or the system was offline.

Import a File Via API

The /uploadURLs/data-import API is available for importing batch files outside of Nitro Studio. This API returns a pre-signed URL that you can use to upload files.

  1. Create an OAuth client named batch-import that uses the batch_import scope.

  2. Access our REST APIs at https://api.bunchball.com/docs.

  3. Click Authorize (Authorize Button), enter the client_id and client_secret from the OAuth Client created in step 1, and then click Authorize.

  4. Access the /uploadURLs/data-import API and click Try it out (Try It Out Button).

  5. Enter the appropriate parameters and click Execute.

The URL is valid for 24 hours.

  1. Use the resulting upload URL with an HTTP POST call to upload a file (for more information on the POST call see Amazon's documentation). Ensure you:

    • Copy the formFields data in the response as-is.

    • Add the additional content-type field to the request formData. The value must be 'text/csv'.

    • Add the actual file blob as the last field in request formData.

Manage Uploads

You can view the status of imported files on the Uploads tab. Only files uploaded in the last 30 days are available for review.

  1. Open Nitro Studio > Tools > Data Import.

  2. Click the Uploads tab.

  3. Click a file to view the upload details. Details are only available for files that have finished processing.

Process Errors

The Uploads tab shows errors for files that have been uploaded and accepted for processing. A file is accepted when it meets size and formatting requirements. However, any errors within the file (such as an action file that contains an action name that doesn't exist) will error during processing.

When a file's status is "Complete with errors" you can download a file of the records that did not process, fix the issues, and re-upload the file containing the corrected records.

When fixing errors, use the CSV file provided by Nitro to fix any unprocessed records. DO NOT re-upload the original file as this will result in duplicate records.

  1. Open Nitro Studio > Tools > Data Import.

  2. Click the Uploads tab.

  3. Click the file to open the upload details.

  4. Click Download error records.

  5. Open the downloaded file. This file contains only the records that did not process due to an error. The errors are described in the file's DATA_IMPORT_ERROR column.

  6. Fix the errors in the file.

  7. Upload the file containing the updated records using the Import tab.

See also

Batch file requirements

User Management view