ANS-1404 · SUITESCRIPT DEVELOPMENT

How to Resolve ‘SyntaxError: Unexpected token <' After TLD SuiteApp Installation?

This guide explains how to resolve a specific JSON parsing error that prevents transaction creation in NetSuite after the Transaction Line Distribution (TLD) SuiteApp is installed.

Short answer

To resolve the 'SyntaxError: Unexpected token <' when creating transactions after installing the TLD SuiteApp, navigate to Script Deployments. Edit the customdeploy_vid_sl_vendorbillform deployment, go to the Audience subtab, and select 'Online Form User' under External roles. Save the changes to enable transaction entry.

Scenario

Users attempting to open or create new transactions, such as vendor bills or invoices, encounter a "SyntaxError: Unexpected token < in JSON at position 0 [at JSON.parse (native), at VendorBillFormGateway.triggerHttpsPostRequest (/SuiteApps/com.netsuite.vendorinvoicedistribution/app/common/gateways/BaseGateway.js:308:25)]" message. This error specifically appears after the installation of the Transaction Line Distribution (TLD) SuiteApp and prevents the successful creation of transactions.

Solution

To resolve the SyntaxError preventing transaction creation after the TLD SuiteApp installation, adjust the audience settings for a specific script deployment.

  1. Navigate to Customization > Scripting > Script Deployments.

  2. Locate and edit the deployment with the ID: customdeploy_vid_sl_vendorbillform.

  3. Go to the Audience subtab.

  4. Under External roles, select Online Form User.

  5. Save the deployment.

Expert NetSuite Support

Need help with this NetSuite issue?

SuiteScript Development consulting and configuration support

Talk to a consultant