Back

Publishing a NetSuite Real-Time trigger

Published: Jan 16, 2024
Post Author Written by Ethan Sorenson

The SmartConnect NetSuite Real-Time trigger works in conjunction with the native NetSuite SuiteScript file. The SuiteScript file is generated dynamically when clicking the Register button on the NetSuite Real-Time Data Source and is specific to NetSuite Real-Time Data Source and NetSuite entity.

Create the Script Record in NetSuite

  1. Log into NetSuite as a user with access to publish Scripts.
  2. Navigate to Customization > Scripting > Scripts > New.
  1. Click New button to upload a new Script file.
  1. Choose ATTACH FROM Computer.
  2. Enter a FILE NAME that is exactly the same as your JavaScript file downloaded from SmartConnect.
  3. Click Choose File and upload the SmartConnect SuiteScript file contained in the zip file downloaded from the SmartConnect NetSuite Real-Time Data Source.
  1. Click Save.
  2. Click on Create Script Record.
  1. Enter a value for NAME.
  2. Enter a value for DESCRIPTION.
  3. Click Save.

Deploy the script

After creating the Script Record we can deploy this script to activate it in NetSuite.

  1. Click Deploy Script on the Script Record.
deploy
  1. Set APPLIES TO as the base Record Type being tracked by the data source.
  2. Set the STATUS to Released.

If you set the STATUS to Testing, only the user the created the deployment will trigger the data source.

  1. Set the Audience to the appropriate roles.

Select All can be used to apply the script globally to all users.

  1. Click Save.

Test the Real-Time data source

With our Script Record created and deployed, we can now run a test to make sure our trigger is firing and calling SmartConnect Successfully.

  1. In NetSuite update the record you are tracking, in my case this is Customer.
  2. Click Save on the record.
  3. Log into SmartConnect.
  4. Check your SmartConnect Dashboard for recent runs. If your integration is in the list, then the trigger fired successfully.

If the Real-Time data source is failing please reference our troubleshooting guide.

Feeling stuck? Get the support and guidance you need to help you power through any data challenge

We're on your integration team. Connect with our people and let us know how we can help you.