.png)
Integrate NetSuite with Martini
Integrate NetSuite with other enterprise systems through Martini by consuming SuiteTalk REST Web Services, SuiteTalk SOAP Web Services, RESTlets, and supported SuiteQL queries. Martini can receive HTTP notifications generated by NetSuite scripts or workflows, schedule incremental synchronization, transform NetSuite JSON or XML payloads, and apply account-specific business rules before writing to CRM, commerce, logistics, databases, queues, or files. CSV and configured SFTP exchanges can support bulk migration and batch processing. Martini also exposes usable REST services around NetSuite operations, while OAuth 2.0 or token-based authentication protects access according to NetSuite roles and permissions.
NetSuite integration options at a glance
| Integration point | Supported by NetSuite? | Common use cases | How Martini supports it |
|---|---|---|---|
| REST API | Yes | NetSuite SuiteTalk REST Web Services supports many standard and custom records, record operations, metadata discovery, and supported query scenarios such as SuiteQL. It is suited to modern JSON integrations and account-specific synchronization workflows. | Martini can consume the NetSuite REST API, map JSON payloads, resolve internal or external IDs, and expose REST services around selected NetSuite operations. Workflows can add validation, routing, retries, and writes to databases, queues, files, or other APIs. |
| SOAP API | Yes | SuiteTalk SOAP Web Services supports strongly typed NetSuite objects, CRUD operations, searches, transactions, and selected asynchronous processing. SOAP can be appropriate where typed WSDL contracts or an operation with stronger SOAP support is required. | Martini can consume NetSuite SOAP services using the WSDL and authentication configuration appropriate to the account. It can transform XML responses and requests, orchestrate searches or transactions, and handle operation-specific errors and retry decisions. |
| Webhooks | Limited | NetSuite does not provide a universal webhook stream for every record change. SuiteScript, workflows, or selected NetSuite features can send outbound HTTP notifications for configured events such as changes to Customers, Sales Orders, or Invoices. | Martini can receive webhook-style HTTP notifications at a secured endpoint. Because delivery and payload completeness depend on the NetSuite customization, Martini can validate the notification, deduplicate it, retrieve the authoritative record, and route failures for controlled retry. |
| Events / triggers | Limited | User-event scripts and workflows can react to selected lifecycle events, including create, edit, or delete, but coverage depends on deployment, event stage, account configuration, and script governance. Scheduled polling using timestamps, saved searches, SuiteQL, or custom queues is often more predictable for broad change capture. | Martini supports scheduled triggers, HTTP-triggered workflows, routing, and asynchronous processing. It can combine a NetSuite notification with a follow-up API read, or poll using a persisted synchronization point and overlap window. |
| Bulk API / batch export | Yes, with selected methods | NetSuite supports CSV import and export for bulk loading and extraction. SuiteTalk SOAP or REST asynchronous processing is available for selected operations, while large API synchronizations require pagination, batching, and concurrency control. | Martini can orchestrate paginated or batched API calls, process CSV files, track job or extraction state, and control concurrency. Workflows can route transient throttling or service failures to bounded retries rather than repeatedly submitting invalid data. |
| Database access | Limited | NetSuite exposes SuiteAnalytics Connect for analytics and extraction scenarios, but the supplied research does not establish a general transactional database interface for application integration. Query access, permissions, and availability depend on the enabled NetSuite service and account configuration. | Martini can connect NetSuite-derived data to databases through supported database connectivity and can consume applicable NetSuite query or analytics services over their documented interfaces. It should not be treated as direct transactional access to NetSuite’s underlying application database. |
| File import/export | Yes, with configuration | NetSuite supports CSV import and export, and can participate in SFTP or other file-based exchanges through SuiteCloud and related configured patterns. File jobs require mapping, validation, transfer configuration, and status handling. | Martini can process CSV or other supported file payloads, transform rows into NetSuite or downstream schemas, and orchestrate file-based workflows. It can also combine file intake with API lookups and database or queue writes. |
| Authentication | Yes | NetSuite supports OAuth 2.0 for supported REST Web Services and RESTlets, and Token-Based Authentication for REST, SOAP, and RESTlets. Access is constrained by integration records, roles, permissions, scopes, subsidiaries, locations, and other account settings. | Martini can store credentials and secrets securely and configure authenticated API consumption or secured inbound services. Implementations should use least-privilege NetSuite roles, account-appropriate OAuth or TBA settings, and refresh or reacquire expiring OAuth tokens as required. |
How NetSuite exposes data and business events
NetSuite REST APIs
NetSuite SuiteTalk REST Web Services provides REST access to many standard and custom records, metadata discovery, record operations, and supported query scenarios including SuiteQL. REST responses are generally paginated and remain subject to account configuration, permissions, and service limits.
How This works in Martini
How this works in Martini: Martini consumes the NetSuite REST definition or configured HTTP endpoints, authenticates with OAuth 2.0 or TBA, maps JSON payloads, resolves references, and invokes downstream services or target systems. A scheduled workflow can persist an incremental cursor and use overlapping modification-time windows.
Example Martini workflow
NetSuite SOAP APIs
SuiteTalk SOAP Web Services provides strongly typed objects, searches, transactions, CRUD operations, and selected asynchronous processing. The WSDL version and available operations must match the target NetSuite account and release configuration.
How This works in Martini
How this works in Martini: Martini consumes the SOAP service, constructs typed XML requests, and transforms XML responses into internal or downstream schemas. Workflows can distinguish transient service or concurrency errors from validation, permission, and duplicate-record failures.
Example Martini workflow
NetSuite RESTlets
RESTlets are custom HTTP endpoints implemented with SuiteScript. They are useful when standard REST Web Services do not expose the required business logic, record combination, validation, or payload shape.
How This works in Martini
How this works in Martini: Martini calls the configured RESTlet endpoint using NetSuite-supported authentication, sends a contract-specific payload, and maps the response into a reusable service. The RESTlet remains NetSuite-side custom code, while Martini provides orchestration, transformation, routing, and monitoring.
Example Martini workflow
NetSuite notifications
NetSuite does not provide universal webhook coverage for all records. SuiteScript user-event deployments, workflows, or selected features can send HTTP notifications for configured changes, but timing, delivery, duplicates, and payload completeness depend on the implementation.
How This works in Martini
How this works in Martini: Martini exposes a secured HTTP endpoint to receive the notification, validates its signature or authentication arrangement where configured, deduplicates the event, and retrieves the changed NetSuite record before downstream processing. The notification is treated as a signal rather than a guaranteed complete record representation.
Example Martini workflow
CSV and file exchange
NetSuite supports CSV import and export for bulk data loading and extraction. SFTP and related file-transfer patterns are supported with configuration through applicable NetSuite features and deployment architecture.
How This works in Martini
How this works in Martini: Martini receives or produces configured files, parses and maps CSV rows, validates references and required fields, and invokes NetSuite or downstream file endpoints. Batch status, rejected rows, and transfer failures can be separated for operational review and retry.
Example Martini workflow
Common NetSuite integration patterns
Pattern 1
When to use this pattern
Use this pattern when an e-commerce, CRM, or marketplace platform must create NetSuite orders while preserving source identifiers for safe retries. The workflow resolves account-specific references and returns NetSuite identifiers after successful creation.
Data Flow
Example Mapping
| NetSuite Field | Canonical Field | Target Field |
|---|---|---|
| sourceOrderId | externalOrderId | externalId |
| customerId | customerReference | Customer.internalId |
| lineItems[].sku | orderLines[].itemReference | Sales Order.item |
| orderTotal | totalAmount | Sales Order.total |
Martini Implementation
Martini receives the source order through an API or scheduled retrieval, looks up Customer and Item references, validates subsidiary, location, currency, and required custom fields, and creates the Sales Order through REST, SOAP, or a RESTlet. It uses the source order ID or NetSuite external ID for idempotency, retries only transient failures with bounded backoff, and returns the NetSuite internal ID and order number.
Martini features used:
- REST or SOAP API consumption
- data mapper
- conditional routing
- idempotency checks
- error handling and retry
Pattern 2
When to use this pattern
Use this pattern to synchronize NetSuite fulfillment and receivables updates with commerce, logistics, billing, or customer-support systems. It is appropriate when downstream systems need changed Item Fulfillment, Invoice, or Customer Payment data without exporting the entire account.
Data Flow
Example Mapping
| NetSuite Field | Canonical Field | Target Field |
|---|---|---|
| internalId | sourceRecordId | externalReference |
| lastModifiedDate | changedAt | updatedAt |
| tranId | documentNumber | fulfillmentOrInvoiceNumber |
| status | processingStatus | status |
Martini Implementation
A scheduled Martini workflow queries by last-modified timestamp, saved search, SuiteQL, or another account-specific change-tracking method. It uses stable ordering and an overlap window, transforms the selected object, writes it to the target, and persists the last successful extraction point. Duplicate delivery is controlled with record identifiers and timestamps; throttling and temporary service errors use bounded retries.
Martini features used:
- scheduler trigger
- REST or SOAP query
- pagination
- data mapper
- state persistence
- retry handling
Pattern 3
When to use this pattern
Use this pattern for supplier and procurement exchanges where NetSuite master data and purchasing transactions must be shared with a supplier or procurement platform. It supports inbound acknowledgements, shipment details, or invoice information that must update NetSuite transactions.
Data Flow
Example Mapping
| NetSuite Field | Canonical Field | Target Field |
|---|---|---|
| Vendor.internalId | supplierId | supplierReference |
| Item.itemId | productReference | supplierItemId |
| Purchase Order.tranId | purchaseOrderNumber | acknowledgementOrderNumber |
| shipmentDate | expectedOrActualShipDate | Purchase Order or Item Receipt date |
Martini Implementation
Martini exports Vendor, Item, and Purchase Order data, maps it to the procurement contract, and receives supplier acknowledgements or shipment updates through an API or configured file exchange. Before updating Purchase Order, Item Receipt, or Vendor Bill records, it validates subsidiary, location, currency, tax, and item mappings. Invalid references are quarantined for correction, while transport or throttling failures are retried safely.
Martini features used:
- API and file integration
- CSV processing
- mapping and transformation
- business-rule validation
- error queue and replay
Pattern 4
When to use this pattern
Use this pattern when selected NetSuite changes should initiate downstream workflows but a universal event stream is not available. It combines NetSuite customization with Martini so the notification starts processing while NetSuite remains the authoritative source.
Data Flow
Example Mapping
| NetSuite Field | Canonical Field | Target Field |
|---|---|---|
| recordType | objectType | workflowRoute |
| recordId | sourceRecordId | lookupIdentifier |
| eventType | changeType | processingAction |
| lastModifiedDate | changedAt | downstreamUpdatedAt |
Martini Implementation
A NetSuite user-event script or workflow sends an HTTP notification for a selected Customer, Sales Order, or Invoice change. Martini authenticates and validates the request, deduplicates it, retrieves the authoritative record, applies routing and transformation, and writes to downstream systems. Because event timing and delivery are implementation-dependent, the workflow uses duplicate detection, delayed re-read where appropriate, and retry or replay handling.
Martini features used:
- secured REST endpoint
- webhook-style intake
- deduplication
- follow-up API read
- conditional routing
- monitoring
How to build a NetSuite integration in Martini
Objective
Establish the NetSuite service and identity model before building record flows. Confirm whether REST, SOAP, RESTlets, CSV, or a configured file exchange is the appropriate mechanism and align the Martini configuration with the target account.
Instructions in Martini
- Choose SuiteTalk REST, SOAP, RESTlet, or file exchange.
- Configure a NetSuite integration record and least-privilege role.
- Use OAuth 2.0 or TBA according to the selected service.
- Store tokens, keys, secrets, and account identifiers securely.
- Confirm record, subsidiary, location, and custom-field permissions.
Objective
Select an invocation model that matches NetSuite’s event coverage and volume requirements. Use notifications for selected configured events, and scheduled polling or files for broader or batch-oriented synchronization.
Instructions in Martini
- Use an HTTP endpoint for configured NetSuite notifications.
- Use a scheduler for timestamp, saved-search, or SuiteQL polling.
- Use file intake for CSV or SFTP-based exchanges.
- Persist the last successful extraction point.
- Plan overlap windows for modification-time queries.
Objective
Convert NetSuite JSON, XML, or CSV structures into a canonical model and the target system’s contract. Account for internal IDs, external IDs, sublists, custom fields, dates, currencies, and subsidiary-specific values.
Instructions in Martini
- Inspect the target account’s metadata and field IDs.
- Map Customer, Item, transaction, and line-level references.
- Normalize dates with an explicit timezone strategy.
- Transform JSON, XML, or CSV payloads.
- Validate required fields and reference values before submission.
Objective
Make account-specific NetSuite rules explicit before creating or updating records. This reduces failures caused by approvals, tax, inventory, subsidiaries, accounting books, custom forms, and required custom fields.
Instructions in Martini
- Resolve internal IDs deterministically.
- Check subsidiary, location, currency, and accounting constraints.
- Apply duplicate and idempotency checks.
- Route invalid records for correction rather than retrying them.
- Separate transient failures from authorization and validation errors.
Objective
Submit validated data to NetSuite or downstream systems while controlling request volume and preserving processing state. Return meaningful identifiers and statuses to the originating workflow where required.
Instructions in Martini
- Create or update records through the selected NetSuite service.
- Use pagination and bounded concurrency for large jobs.
- Write normalized data to APIs, databases, queues, or files.
- Persist NetSuite internal IDs, external IDs, and synchronization status.
- Track batch or asynchronous job status where applicable.
Objective
Operate the integration as a managed workflow with observable outcomes and safe replay. Retries must account for NetSuite concurrency, governance, duplicate risk, and the distinction between transient and permanent errors.
Instructions in Martini
- Log correlation IDs without exposing credentials.
- Apply bounded exponential backoff to transient failures.
- Handle throttling and concurrency responses as retryable when appropriate.
- Quarantine validation, permission, malformed-request, and duplicate errors.
- Monitor executions and replay corrected failures deliberately.
Common NetSuite data objects used in integrations
| Object | Typical Use | Common target systems | Martini handling |
|---|---|---|---|
| Customer | Synchronize customer or account identity, contact details, subsidiary relationships, and billing information between NetSuite and commerce, CRM, support, or finance systems. | CRM, e-commerce, customer support, data warehouse | Martini maps source identifiers to NetSuite internal or external IDs, validates subsidiary and required fields, and uses timestamps or saved searches for incremental extraction. |
| Vendor | Exchange supplier master data with procurement, supplier-management, logistics, and accounts-payable platforms. | Procurement, supplier portal, ERP adjuncts, data warehouse | Martini normalizes supplier fields, validates account-specific references, and routes permission, duplicate, or business-rule errors separately from transient API failures. |
| Sales Order | Create customer orders from commerce, CRM, or marketplace systems and return the NetSuite order number and internal ID to the source. | E-commerce, CRM, fulfillment, logistics, customer support | Martini resolves Customer, Item, subsidiary, location, currency, and other references; applies external-ID idempotency checks; and maps line-level data before submission. |
| Invoice | Synchronize accounts-receivable transactions with billing, commerce, customer-support, and reporting systems. | Billing, e-commerce, finance, customer support, data warehouse | Martini polls or receives selected notifications, retrieves authoritative details when needed, transforms dates and currencies, and prevents duplicate delivery using source identifiers and modification timestamps. |
| Item | Distribute product, service, inventory, assembly, and purchasable-item information to commerce, procurement, inventory, and logistics platforms. | E-commerce, PIM, procurement, inventory, logistics | Martini maps item identifiers and account-specific lists, processes paginated results, and validates subsidiary, location, availability, and custom-field requirements. |
| Employee | Exchange authorized employee or internal-user information with identity, HR, workforce, and reporting systems. | HR, identity management, workforce management, data warehouse | Martini handles Employee data according to role and privacy permissions, applies field-level mapping, and limits exposed data to the integration’s business requirement. |
Authentication and security considerations
Use account-controlled authentication
NetSuite supports OAuth 2.0 for supported REST Web Services and RESTlets, and Token-Based Authentication for REST, SOAP, and RESTlets. SOAP requests can use token-based authentication through a TokenPassport.
- Configure a dedicated NetSuite integration record and least-privilege role.
- Grant only the required Lists, Transactions, Reports, Setup, Web Services, REST Web Services, and RESTlet permissions.
- Account for subsidiary, location, accounting-book, and other role restrictions.
- Store OAuth credentials, TBA secrets, tokens, and account identifiers in Martini secrets rather than payloads or logs.
- Secure Martini inbound notification endpoints with appropriate authentication and authorization.
Authentication does not by itself grant record access. OAuth scopes, role permissions, account features, customizations, and token expiry all affect the effective integration boundary.
Operational considerations for NetSuite integrations
Design for NetSuite operating constraints
- Control concurrency and use bounded backoff for throttling or 429 responses.
- Handle REST pagination, SOAP result windows, and asynchronous job retrieval explicitly.
- Use external IDs, source identifiers, and deterministic lookups to make Sales Order and Invoice retries idempotent.
- Persist extraction cursors and use stable ordering with overlap windows for timestamp-based synchronization.
- Test custom fields, forms, WSDL versions, record permissions, subsidiary rules, tax, currency, inventory, and workflow behavior in the target account.
- Separate transient failures from authentication, permission, validation, malformed-request, and duplicate errors.
- Treat NetSuite metadata, customizations, enumerations, and API versions as account-dependent and monitor for schema changes.
Why use Martini instead of scripts or point-to-point integrations?
Build a maintainable integration layer
Point-to-point scripts often combine authentication, pagination, transformation, business rules, retries, and monitoring in code that is difficult to reuse. Martini provides a managed integration layer in which developers can consume NetSuite API definitions, compose reusable services, and expose consistent APIs to other applications.
- Centralize REST, SOAP, RESTlet, webhook-style, and file-based orchestration.
- Map NetSuite JSON, XML, and CSV structures into canonical and target schemas.
- Apply reusable validation, routing, idempotency, and error-handling services.
- Combine scheduled polling with event notifications and asynchronous workflows.
- Connect NetSuite data to APIs, databases, queues, and files without duplicating integration logic.
- Monitor executions and replay corrected failures through operational workflows.
Martini does not replace NetSuite-side SuiteScript or workflows where custom ERP logic is required; it complements them by coordinating cross-system behavior outside NetSuite.
Frequently asked questions
No native NetSuite connector is documented in the supplied Martini materials. Martini can consume NetSuite SuiteTalk REST or SOAP APIs, call RESTlets, receive HTTP notifications from NetSuite customizations, and coordinate configured CSV or file exchanges.
Use SuiteTalk REST for modern HTTP/JSON integrations, supported record operations, and applicable SuiteQL queries. SOAP may be preferable for strongly typed WSDL contracts, operations with stronger SOAP support, or selected asynchronous SOAP processing.
Yes, when the selected NetSuite service, role, subsidiary configuration, and required fields permit the operation. The workflow should resolve valid Customer, Item, subsidiary, location, currency, and other account-specific references and use an external identifier or lookup to prevent duplicates.
Martini can receive HTTP notifications sent by NetSuite scripts, workflows, or other configured mechanisms. NetSuite should not be assumed to provide universal webhook coverage, so Martini should validate, deduplicate, and commonly re-read the authoritative record before downstream processing.
Use a scheduled workflow that queries by a modification timestamp, saved search, SuiteQL, or custom change-tracking strategy. Persist the last successful synchronization point, use stable ordering and overlap windows where necessary, and avoid assuming every object has the same incremental-sync behavior.
Martini can map custom fields and records when the target account exposes them through the selected service. The implementation must inspect field IDs, data types, required status, sublists, custom lists, forms, and whether the field is available through REST, SOAP, SuiteQL, or a RESTlet.
Yes. Martini can expose its own REST services around NetSuite operations, applying authentication, validation, transformation, routing, and consistent response handling while consuming NetSuite REST, SOAP, or RESTlet endpoints behind the service.
Retry transient transport, throttling, concurrency, and temporary service errors with bounded exponential backoff. Do not blindly retry permission, validation, malformed-request, or duplicate-record errors; route those failures for correction and deliberate replay.
Related Martini documentation
Transformation
Connect NetSuite to your enterprise systems
Use Martini to design, deploy, and monitor reliable NetSuite integrations across APIs, workflows, databases, queues, and file exchanges.