- Open the URL in the browser: https://{accountId}.app.netsuite.com/app/login/oauth2/authorize.nl?scope=restlets+rest_webservices&redirect_uri={redirect_uri}&response_type=code&client_id={client_id}&state=state_passthrough_parameter_value&access_type=offline
- Click on Continue. It will redirect to URL. Copy the value of URL parameter code.
- Use code to fetch refresh token
Endpoint: https://{account_id}.suitetalk.api.netsuite.com/services/rest/auth/oauth2/v1/token
Provide the code, redirect URI and grand_type on the request body. API call and fetch refresh token
- Use this refresh token to generate access token.
Endpoint : https://{account_id}.suitetalk.api.netsuite.com/services/rest/auth/oauth2/v1/token
Provide the refresh token, redirect URI and grand_type on the request body. API call and fetch access token.
Use the access token in the final endpoint.