User GuideGetting Started
Integrating NetSuite
Connect SuitePortal with your NetSuite instance using the SuiteBundle
Integrating NetSuite
SuitePortal connects to NetSuite via a SuiteBundle that runs Map/Reduce scripts to sync data.
Prerequisites
- NetSuite administrator access
- Permission to install SuiteBundles
- Role with "Log in using OAuth 2.0 Access Tokens" permission (if using OAuth)
Integration Method
SuitePortal uses Token-Based Authentication (TBA) to authenticate with NetSuite. TBA credentials are entered directly in the organization settings.
Installation Steps
1. Install the SuiteBundle
- In NetSuite, navigate to Customization → SuiteBundler → Search & Install Bundles
- Search for Bundle ID: 581756
- Click Install
- Follow the installation wizard
2. Configure Global Settings
After installation, the bundle creates a Global Settings record. Configure:
| Setting | Description |
|---|---|
| Tenant ID | Your SuitePortal organization's tenantId |
| Webhook URL | https://suiteportal.io/api/ingest/{tenantId} |
| API Key | Generated from SuitePortal dashboard |
3. Enter TBA Credentials in SuitePortal
In your SuitePortal dashboard, navigate to Settings → NetSuite Integration and enter:
| Field | Description |
|---|---|
| Account ID | NetSuite account number (e.g., 1234567 or 1234567_SB1 for sandbox) |
| Consumer Key | From NetSuite Integration record |
| Consumer Secret | From NetSuite Integration record |
| Token ID | From NetSuite Access Token record |
| Token Secret | From NetSuite Access Token record |
Bundle Components
The SuiteBundle includes:
Custom Fields
| Field ID | Description |
|---|---|
custbody_sp_flag | Transaction body field to flag records for sync |
custentity_sp_flag | Entity field to flag records for sync |
Map/Reduce Scripts
| Script | Record Type |
|---|---|
SP_MR_Customers.js | Customer sync |
SP_MR_Contacts.js | Contact sync |
SP_MR_Vendors.js | Vendor sync |
SP_MR_Employees.js | Employee sync |
SP_MR_Invoices.js | Invoice sync |
SP_MR_SalesOrders.js | Sales order sync |
SP_MR_PurchaseOrders.js | Purchase order sync |
SP_MR_ItemFulfillments.js | Item fulfillment sync |
Integration Endpoints
| Endpoint | Purpose |
|---|---|
/api/ingest/{tenantId} | Receives batch data from NetSuite |
/api/ingest/finalize | Optional finalization after sync batch |
/api/check-in/{tenantId} | Health check endpoint |
Verifying Integration
After configuration:
- In NetSuite, run the Check-In Suitelet (
SP_SL_Check_In.js) - Verify the response shows successful connection
- In SuitePortal, check that
integrationCompleteflag istrue
Data Flow
NetSuite SuitePortal
│ │
├─ Map/Reduce runs ──────────────► │
│ (batches of 500 records) │
│ │
├─ POST /api/ingest/{tenantId} ──► │
│ ├─ Store in database
│ │
├─ POST /api/ingest/finalize ────► │
│ (optional) ├─ Mark sync complete
│ │Next step: Invite Team Members