Skip to main content

NetSuite Overview

Oracle NetSuite is accounting and business management software commonly integrated with UniFi. This is usually done via the SuiteTalk set of API's which allow for OAuth authentication to be used.

Overview of the process

In order to read or write data from/to NetSuite the data connector must do the following:

  • Authenticate using OAuth credentials.
  • Send a request for the required information via http.
  • Return the response in JSON format back to UniFi.

Adapting existing data connectors

If you already have some advanced data connectors that work with NetSuite you will probably find its better to use these as a starting point rather than build one from scratch. The steps needed to adapt an existing data connector to work with your own instance of NetSuite are detailed below, if you want to get a more thorough understanding of how it actually works then full details are in the next section.

If the data connector is already doing what you need but you want to use it in another app, then you can simply re-use it by selecting it when you create an external dropdown. If you want to take an existing data connector and make it look at a different NetSuite account you will need the following information:

  • Consumer Key
  • Consumer Secret
  • Token ID
  • Secret

This information is usually shown when NetSuite is first configured for integration. This is done from the 'Setup' > 'Integrations' > 'Manage Integrations' screen from within NetSuite, so if you are doing this for the first time be sure to make a note of these details. You can use the same integration credentials for all NetSuite integrations.

The first step would be to make a copy of the existing data connector to work on, in this example we are using the 'Supplier' data connector. You can then edit this data connector and make the following changes:

  1. Edit the first 'AddSecurityOAuth1' step described as 'OAuth' and change the relevant fields. The 'realm' is the first part of your NetSuite URL, so in the URL https://64807.app.netsuite.com/... the realm would be 64807 (this can include letters as well as numbers). The consumer key and secret, token ID and secret are from your NetSuite integration as described above, other values can stay the same.

 alt image

  1. Edit the second RestHttpClient step described as 'Vendor' and change the relevant parts of the URL to point to your Netsuite realm as described above.

 alt image

Other values should stay the same, although if you want to change the fields being returned you can edit query in the 'Content' field as necessary.

caution

Do not edit the content field of an existing data connector without knowing what other apps may be using it. As data connectors can be shared among multiple apps, if you are not sure its always safer to make a duplicate and work with that instead.

Your new data connector is now ready to test. Once successfully tested it can be used to populate a dropdown field in the form designer of the app builder.