ns_transformRecord

Tool Description

Transforms an existing NetSuite record into a new record of a supported target type, such as a sales order into an invoice.

The tool creates and saves the target record and returns its internal ID.

Before calling this tool, use ns_getRecordTransformMetadata to identify a supported pair of source and target record types. Use ns_getRecordTypeMetadata to check the target record's fields and their data types.

You can provide field values in data to override values the transformation supplies. Omit data or pass '{}' as a string to keep those values unchanged.

Review and confirm the transformation with your AI client before it calls this tool. Repeating a successful call can create another record.

Annotation

Transform Record

Properties

Property

Type

Required or Optional

Description

sourceRecordType

string

Required

The existing source record type, for example salesorder.

sourceRecordId

string

Required

The internal ID of the existing source record.

targetRecordType

string

Required

The target record type to create, for example invoice.

data

string

Optional

A JSON object passed as a string, containing field values for the new target record. These values override values the transformation supplies. Omit this property or pass '{}' as a string to keep those values unchanged.

Permissions

Your role must have the following permission for this tool to appear in your AI client.

Permission ID

Permission Name

Level

ADMI_RESTWEBSERVICES

REST Web Services

Full

Your ability to transform records depends on your NetSuite role's access to the source and target records. Account configuration and the source record's eligibility also affect whether the transformation succeeds.

Related Topics

General Notices