Creating a Custom Plug-in Implementation in an XML Definition

In SuiteCloud Development Framework (SDF), custom plug-in implementations are represented by pluginimplementation objects. A custom plug-in type (plugintype) can have multiple custom plug-in implementations. Custom plug-ins can also be referred to as alternate implementations of the custom plug-in type.

To create a pluginimplementation object, perform one of the following procedures.

Procedure

Details

In SuiteCloud IDE, create a custom plug-in implementation in a NetSuite account.

See Creating a Custom Plug-in Alternate Implementation.

In the NetSuite interface, create a custom plug-in implementation in a NetSuite account.

See Creating a Custom Plug-in Alternate Implementation.

Import the pluginimplementation object into your SuiteCloud project. See Account Component Imports to SuiteCloud Projects.

Custom Plug-in Implementation Required Fields

The following table contains fields are required for custom pluginimplementation objects. For a list of all available fields, see the reference documentation for the pluginimplementation element in SuiteCloud Development Framework XML Reference.

Note:

The scriptid attribute is required for the pluginimplementation element. The scriptid attribute value must match the filename excluding the file extension.

For SuiteScript 1.0 custom plug-in implementations, the libraries element is available. Use that element to add library files that support your implementation.

Field

Type

Description

customplugintype

single-select list

The scriptid attribute value for the plugintype object that the pluginimplementation object is implementing. In other words, the ID for the custom plug-in type that the custom plug-in implementation is implementing.

After the first time the custom plug-in implementation is deployed, its custom plug-in type cannot be changed.

name

string

A user-friendly name for the custom plug-in implementation. The name is seen by administrators when they activate or deactivate the custom plug-in implementation.

scriptfile

filereference

The script file (.js) that contains an alternate implementation for the custom plug-in type.

The SuiteScript version of a custom plug-in implementation must match the SuiteScript version of its plug-in type. For example, a SuiteScript 2.x custom plug-in type must only have SuiteScript 2.x custom plug-in implementations.

status

single-select list

The status of the custom plug-in type. Possible values are RELEASED and TESTING. Ensure the value is set to RELEASED prior to bundling the custom plug-in. See Bundling a Custom Plug-in.

For an example of a pluginimplementation object, see Custom Plug-in Implementation Object Example.

Related Topics

General Notices