Setting Up NetSuite Accounts in SuiteCloud Extension for Visual Studio Code

You can set up the NetSuite accounts you want to customize. If you have set up domains in addition to the default NetSuite ones, you need to configure account-specific details for these additional domains you added.

The following tasks are available for account setup:

Adding an Account in SuiteCloud Extension for Visual Studio Code

SuiteCloud Extension for VS Code passes your account information to NetSuite during the SuiteCloud extension authentication process. For more information, see OAuth 2.0 Authentication for SuiteCloud SDK.

As a prerequisite to adding an account, a SuiteCloud project must be open in VS Code. For more information, see Creating a SuiteCloud Project in SuiteCloud Extension for Visual Studio Code.

To add an account:

Note:

You can also add an account by clicking Set Up Account in the status bar when you have a specific file from a project open in the editor.

  1. In VS Code, open the Command Palette and enter suitecloud.

  2. From the dropdown list, select SuiteCloud: Set Up Account.

  3. From the dropdown list, select New authentication ID.

  4. From the dropdown list, select one of the following options:

    • Browser-based authentication – This option opens a new window or tab from your default browser, so you can authenticate your account-role combination.

    • Machine-to-machine authentication – This option opens a window so you can authenticate your account-role combination. For the machine-to-machine authentication, you are asked to enter the following parameters:

      • Account ID – References the NetSuite account ID.

      • Certificate ID – References the certificate ID obtained from NetSuite after uploading the public key file.

      • Private key file – References the local path to the private key file matching the certificate in NetSuite. For example: d:/path/private-key.pem.

        Note:

        To obtain the certificate ID, you need to generate an RSA certificate. The RSA certificate has two parts: the public key and the private key.

        Upload the public key into the OAuth 2.0 Client Credentials Setup by specifying SuiteCloud Development Integration Application and select the desired role. That action generates a new row that will provide the certificate ID value.

        The private key path value is the location where the private key is saved.

        For more information about how to generate the RSA certificate, see Certificate Conditions.

        For more information about how to upload the public key, follow the steps in OAuth 2.0 Client Credentials Setup.

  5. In the text field, enter an authentication ID.

    Note:

    An authentication ID is a custom alias you give to a specific account-role combination, for example: testaccountadmin.

  6. Perform the next steps based on the authentication option you selected in Step 4.

    • If you selected Browser-based authentication, in the text field, press Enter to use the production domain or enter your custom domain. Next, follow the instructions in the browser prompt.

    • If you selected Machine-to-machine authentication, do the following in the corresponding fields:

      • Press Enter to use the production domain or enter your custom domain.

      • Enter the account ID.

      • Enter the certificate ID.

      • Press Enter to continue with the selection of the private key file.

    If the entered information is correct, your account is successfully set up and ready to be used in SuiteCloud Extension for VS Code.

Setting an Account as Default in SuiteCloud Extension for Visual Studio Code

In addition to set up your accounts in SuiteCloud Extension for VS Code, you can also set a specific account as default for a project. The default account is used for all the NetSuite actions, such as deploy, list SDF custom objects, and upload files.

To set up an account as default:

  1. In VS Code, open the Command Palette and enter suitecloud.

  2. From the dropdown list, select SuiteCloud: Set Up Account.

  3. From the dropdown list, select the authentication ID of the account you want to set as default.

    The selected authentication ID is set as default for the project.

Note:

You can also set up an account as default by clicking Set Up Account in the status bar when you have a specific file from a project open in the editor.

Related Topics

General Notices