Define Field Sets

You can expose information from the item records in NetSuite to your website by defining field sets. After you define the field sets, a web developer can use the Item Search API to access field values in the field sets.

For example, you might create a field set for the product details page, which includes fields that display product name, product images, product description, product availability details, and price. You could also create a different field set for the search results page, which includes fields that display an image thumbnail, product name, and price.


Field Sets are made public on the internet. Since any field type can be selected for use in field sets, you must consider which fields you choose to expose.

You can leverage the Field Set Setup Script to quickly populate your site with required Field Sets. To run a script to create the field sets, see Set Up Initial Field Sets.

You can also define your own field sets on the Web Site Setup page. To define your own field sets, follow the inline procedure.

To define your own field sets:

  1. Complete the prerequisite tasks as described in Prerequisites.

  2. Go to Commerce > Websites > Website List.

  3. Click Edit next to your SuiteCommerce Advanced site.

  4. Click the Field Sets subtab.

  5. In the Name field, enter a name for the new Field Set. This name is only displayed internally on the Field Sets list page and in dropdown lists on the Web Site Setup page. Name each Field Set based on the product views you create for your site.


    The Field Set to return item details is typically named details. If a different name is used, you must update the searchApiMasterOptions property. See Search Results Subtab for more details on configuring this property.

  6. In the Field Set ID field, enter an ID, which you need to later use with the Item Search API as an input parameter to specify the field set. The Field Set ID must be alphanumeric, lowercase, and contain no spaces or special characters. The Field Set ID is displayed internally, on the Field Sets list page and in dropdown lists on the Web Site Setup page.

  7. The Record Type field is pre–populated with the value Item as only item records are supported.

  8. The Description field is an optional field where you can enter a description of this field set. The description only shows on Field Set records, the Field Set list page, and on the Web Site Setup page.

  9. To populate the Fields Included in Field Set field, click the Set icon next to this field. A Field Set window opens.

  10. In the Field Set window, select the item record fields from the Field Name dropdown one by one and click Add. After you have selected all the fields, click Submit. The values of the Field ID and Field Type fields are auto populated for the selected field. You can use the Field ID to refer to specific fields when writing SuiteScript. This is also the field ID returned in the JSON response when using the Item Search API. The Field Type refers to the NetSuite field type. Field types provide information about the type of data web developers can expect in the JSON response to Item Search API queries.

  11. After you have selected fields for this field set, click Submit. The Field Set window closes.

  12. Click Add to add the new field set.

  13. Click Save on the Web Site Setup page to save your changes.

Defining field sets is the final task in configuring item search settings. When you click Save on the Web Site Setup page after defining field sets, the item search indexing process is triggered. For more information, see Search Index Overview and Check the Search Index Job Status.

Field Set Reference

We have provided a Microsoft Excel worksheet listing all the fields available for field sets. You can use this list to find information such as, field IDs and field types. The list also identifies fields that are available for faceting, sorting, and keyword search. In addition to the fields on the item records, there are additional fields that include derived values. These fields are identified on the worksheet as Synthetic fields.

To access the worksheet, click this link: FieldSetsList.xls


Depending on the features enabled in your account, some of the fields in the spreadsheet may or may not appear in your account.

Related Topics

Derived Fields for Field Sets
Search Settings Overview

General Notices