Netsuite documentation for REST
https://system.netsuite.com/help/helpcenter/en_US/APIs/REST_API_Browser/record/v1/2024.1/index.html
To activate and use the REST API in NetSuite, you'll need to follow a series of steps to ensure everything is set up correctly. Here’s a general guide to help you get started:
Add the url the one that has suitetalk.api.netsuite.com
1. Enable Features
First, you need to enable the necessary features in your NetSuite account:
- Log in to your NetSuite account.
- Go to Setup > Company > Enable Features.
- Click the SuiteCloud tab.
- Under the SuiteTalk (Web Services) section, check the boxes for REST Web Services and Token-Based Authentication.
- Click Save.
2. Create an Integration Record
Next, create an integration record for the application that will be using the REST API:
- Go to Setup > Integrations > Manage Integrations > New.
- Enter a name for the integration.
- Make sure the State is set to Enabled.
- Under the Authentication tab, check Token-Based Authentication ONLY (uncheck TBA: AUTHORIZATION FLOW and Oauth 2.0 remove any checkboxes)
- Hit Save.
- Note the Client ID and Client Secret provided upon saving the record. You’ll need these for authentication.
3. Find the Account ID and Company URL
- Go to Setup > Company > Company Information
- Scroll down to the Company URLs tab
- The COMPANY URL is under: SUITETALK (SOAP AND REST WEB SERVICES) (no need to include https, just the url)
- The **Account ID** is in the general section right hand side. (If it is alphanumeric use uppercase)
4. Create a Role with Permissions
Create a role with appropriate permissions for accessing the REST API:
- Go to Setup > Users/Roles > Manage Roles > New Role. Type inSitu Sales integration in the name and then scroll down to the permissions tab.
- Assign permissions relevant to the data you wish to access via the API. Ensure to include Web Services and REST Web Services permissions.
Check the following tabs:
NOTE: Use FULL to all permissions.
Transactions:
- Find Transaction
- All the records needed, such us:
invoice
sales order
Lists:
- Perform search
- All the records needed
Customers
Items
Item collection
Customer profile
Employees
Employee record
Locations (Warehouse)
Shipping Methods
Units
Vendors
Contact
Setup:
REST WEB Services
Log in using Access Tokens
User access token
Reports:
SuiteAnalytics WorkBook
Sales
Sales order reports
- Save the role.
4. Assign Role to a User
Assign the newly created role to a user:
- Go to Lists > Employees > Employees. or Setup > Manage Useres
- Edit the user who will use the REST API.
- Under the Access tab, add the new role.
- Save the changes.
5. Generate Tokens
For token-based authentication, generate tokens for the user:
- Go to Setup > Users/Roles > Access Tokens > New.
- Select the application, user, and role you created.
- Note the Token ID and Token Secret provided. You’ll use these tokens for authentication when making API calls.
6. Make API Calls
With REST enabled and authentication tokens created, you can now make API calls:
- Use the endpoint URL, which typically looks like `https://<account_id>.suitetalk.api.netsuite.com/services/rest/record/v1/`.
- Authenticate using the tokens or other methods you’ve set up.
Comments
0 comments
Please sign in to leave a comment.