Tags: 
API, NetSuite

Overview

These public interfaces are used in NetSuite components. They are provided for implementing advanced functionality in your scripts. In order for you to use these interfaces in your project, you have to reference CozyRoc.SSISPlus.dll and CozyRoc.NetSuite.dll libraries. Also include CozyRoc.SqlServer.SSIS, CozyRoc.NetSuite and CozyRoc.NetSuite.Service namespaces.


IConnection / INetSuiteConnection

When you call NetSuite Connection Manager AcquireConnection method, it returns object implementing IConnection interface. This is the interface used for interaction with NetSuite service.

Connects to NetSuite service. The method result is object implementing NetSuite SuiteTalk web services.

Closes the connection to NetSuite service. Use always after you finish working with the service.

Returns true if connected to the service.

Get NetSuite web service object.

Returns list of available NetSuite records for specific operation. These are the method parameters:

  • operation (uint) - It can be one of the options listed in the following table.
    Value Description
    0 Return records, which can be read.
    1 Return records, which support adding.
    2 Return records, which can be updated.
    3 Return records, which support remove.
    4 Return records, which support upsert.

Gets specified record composite records list. These are the method parameters:

  • root (string) - record name.

Get object used to manage NetSuite record. The method returns IRecord object. These are the method parameters:

  • record (object) - record name or NetSuite Record object.

Get search result for specified record. The method returns SearchResult object. These are the method parameters:

  • record (string) - record name.
  • criteria (IDictionary) - optional. Set to retrieve records for specified criteria.

Retrieves records from NetSuite service. These are the method parameters:

  • criteriaXML (string) - Specify NetSuite search record statement. The statement should be the same XML format used in NetSuite search method.
  • validateOnly (bool) - if true, the specified search statement is validated and no search against the service is performed.

Get object used to manage NetSuite search row. The method returns ISearchRow object. These are the method parameters:

  • searchRow (object) - NetSuite SearchRow object.

Returns array of saved search identifiers for specified type. These are the method parameters:

  • searchType (Type) - type object.

Properties

Specify NetSuite service URL. This property should be explicitly specified when doing sandbox testing.

Specify user name to access the NetSuite service.

Specify user password to access the NetSuite service.

Specify accountID to access the NetSuite service.

Specify role to access the NetSuite service. If you don't specify a role, the user's default role is used.

Specify the number of seconds before timing out session connect. The default value of this property is 100 seconds.

Specify if all clients should use the same connection. This property has the options listed in the following table.

Value Description
True All clients use same connection (default).
False Every client uses different connection.

Specify the name or IP address of the proxy server.

Specify the port number on the proxy server to use for the connection.

Specify user name to access the proxy server.

Specify password to access the proxy server.


IField / INetSuiteField

This interface is used to retrieve NetSuite record field information.

Properties

Returns field name.

Returns true if field is record key.

Returns field type.

Returns field length.

Returns field precision.

Returns field scale.


IRecord / INetSuiteRecord

This interface is used for NetSuite record management.

Methods

Returns the NetSuite RecordType.

Get record fields. The method returns array of IField objects.

Constructs new in-memory NetSuite record instance.

Sets field value in a record. These are the method parameters:

  • record (object) - record instance.
  • field (string) - field name.
  • value (object) - field value.

Returns field value from record object. These are the method parameters:

  • record (object) - record instance.
  • field (string) - field name.

Retrieves records of composite object. These are the method parameters:

  • record (object) - instance to main NetSuite record object.
  • id (string) - composite object identifier. Multiple identifiers are separated with semicolon (;).

Updates composite object. These are the method parameters:

  • record (object) - NetSuite record object.
  • id (string) - composite object identifier. Multiple identifiers are separated with semicolon (;).
  • list (object array) - array of composite NetSuite objects.

Properties

Returns the NetSuite record name.

Returns true if composite object.


ISearchRow 1.6 SR-2

This interface is used for NetSuite search row.

Methods

Get search row fields. The method returns array of IField objects.

Returns field value from search row object. These are the method parameters:

  • searchRow (object) - searchRow instance.
  • field (string) - field name.

Properties

Returns the NetSuite record name.


Related documentation