Skip to main content

Acumatica Sales Orders from iPaaS

Transfer Acumatica sales orders from iPaaS

Updated over a week ago

Summary

Acumatica Sales Orders can be transferred from iPaaS.com using an Add/Update sync method. This mapping supports the automated synchronization of sales order records from iPaaS into Acumatica via the Sales Order API (Transactions).

Integration Settings

  • Mapping Status: Enabled.

  • Trigger Events: The sync is triggered by the creation or update of stock items in Acumatica.

  • ID Format: When manually syncing, the Transaction ID from iPaaS is used. This can be resolved via an external ID or the customer's email address.

  • Conflicting Mappings: This mapping applies only to Sales Orders. Ensure no other mappings target the same Acumatica entity to prevent data from being overwritten.

Supported Child Collections

The integration supports the synchronization of the parent sales order and its related child collections:

  • Sales Order Address: Maps billing and shipping addresses.

  • Sales Order Payment: Maps payment details.

  • Sales Order Line: Maps individual product line items.

  • Sales Order Tax: Maps tax details applied to the order.

System Caveats

Acumatica

  • Financial Terms must be configured in screen CS2065PL.

  • Tax Zones must exist in screen TX2060PL.

iPaaS.com

  • Syncs will fail if there are duplicate SKUs or missing Customer IDs.

Integration-Specific

  • The customer resolution logic defaults to using the customer's email if an external ID is not found.

Setup Requirements

Acumatica Configuration

  • The Sales Order API endpoint must be enabled.

iPaaS.com Configuration

  • The Product mapping collection must be active.

  • Warehouse location ID translation logic must be enabled.

Authentication & Security

  • OAuth 2.0 or an API Key is required for authenticating to both the Acumatica and iPaaS.com endpoints.

Integration Flow

  1. Order Creation: A new sales order is created in iPaaS.

  2. Customer Resolution: The system finds the corresponding customer in Acumatica using their external ID or email address.

  3. Sales Order Creation: A new sales order record is created in Acumatica with the mapped details.

  4. Child Collections Insertion: Related child collections (Address, Payment, Line Items, and Tax) are inserted to complete the order record.

Mappings

Parent Collection: Acumatica Sales Order From iPaaS

Mapping Filter

Type == "Order"

Description

This filter Type == 'Order' is used to select only those records where the Type field is equal to "Order". This means that the system will focus on processing or fetching only the records that are classified as sales orders.

Mapping Type

Source (iPaaS.com)

Destination (Acumatica)

Description

Static

30D

Financial Terms

Terms ID (Acumatica Sales Order From iPaaS ) – Eligible terms ID values can be found in Acumatica form ID CS2065PL. It is recommended to use a dedicated term that will represent externally imported sales orders, however this may be adjusted accordingly using mappings. If a term is used which is not defined with a single installment type, Acumatica will return the following error when adding a payment to the sales order AR No applications can be created for documents with multiple installment credit terms specified.

Note: Financial Terms must be configured to a value compatible with the end user’s Acumatica installation. The provided template mapping demonstrates that this is a required field, but the default value of '30D' (30 Days) must be replaced with a client-specific value.

See your Acumatica documentation for procedures and more information.

Field

TransactionNumber

OrderNbr

Unique Sales Order number.

Field

Total

Order Total

Total order value.

Static

false

Hold

Hold must be statically set to False for this integration.

Static

true

IsTaxValid

Sets the tax status for an Acumatica Sales Order from iPaaS.com as valid. By defaulting to true. A mapping to IsTaxValid must contain a value of “true” to apply a tax override.

Field

ShippingAmount

PremiumFreightValue

Dynamic Formula

Type

ActionType

Specifies the action type for the Acumatica Sales Order from iPaaS.com. It defines the kind of action or transaction being processed, such as a sales order, return, or adjustment, helping to ensure the correct handling of each order type in the system. Assigned to the ActionType Acumatica field from iPaaS.com.

Dynamic Formula

var customerId = await GetExternalIdAsync(CustomerId, "Customer", SpaceportSystemId); if (customerId == null || customerId == "") return await GetCustomerIdByEmail(EmailAddress); else return customerId;

Customer Id

Retrieves the CustomerId for an Acumatica Sales Order from iPaaS.com by first checking if an external ID is available. It attempts to find the customer’s ID using GetExternalIdAsync, based on the customer and system ID. If no ID is found, it defaults to retrieving the customer ID by using the associated email address. This ensures that every sales order is correctly mapped to the appropriate customer, either through their unique ID or email. It is recommended to use only in Update mapping collection if separate mapping collection are being used.

Dynamic Formula

await GetTaxZoneId();

CustomerTaxZone

Retrieves the first eligible tax class from Acumatica form TX2060PL.

Dynamic Formula

EmailAddress + " placed order";

Description

Creates a simple, clear order description linking the order to the customer's email.

Dynamic Formula

True

IsTaxValid

Sets the tax status as valid. A value of true is required to apply a tax override.

Acumatica Sales Order Address From iPaaS (Child Collection)

Mapping Type

Source (iPaaS.com)

Destination (Acumatica)

Description

Field

FirstName

FirstName

Field

LastName

LastName

Field

Address1

Address1

Field

Address2

Address2

Field

City

City

Field

Country

Country

Field

Region

Region

Field

IsPrimaryBilling

IsBillToAddress

Field

IsPrimaryShipping

IsShipToAddress

Static

false

IsBillToContact

Retrieves the value of the custom field labeled from “false” iPaaS.com and assigns it to the IsBillToContact field in Acumatica.

Field

IsPrimaryShipping

IsShipToContact

Assigns false (static value) to isBillToContact field of Acumatica

Dynamic Formula

Regex.IsMatch(PostalCode, @"^\d+$") ? PostalCode : null

ZipCode

Checks the format of the PostalCode for an Acumatica Sales Order from iPaaS.com. It verifies that the postal code contains only numbers. If the postal code is purely numeric, it uses that value as the ZipCode; otherwise, it returns null. This ensures that only valid numeric zip codes are processed in the sales order.

Dynamic Formula

Parent.EmailAddress

Email

Retrieves the email address from the parent record and maps it to the Email field in an Acumatica Sales Order from iPaaS.com. This ensures that the email address associated with the customer or transaction is used in the order, making communication and order tracking easier.

Acumatica Sales Order Line From iPaaS (Child Collection)**

Mapping Filter

await CheckProductExistBySku(Sku);

Description

The integration uses the product's SKU to check if it exists in Acumatica before processing the sales order line. It sends a request to Acumatica's API to retrieve the stock item details, including warehouse information, based on the SKU. If the product is found and valid, the iPaaS.com confirms its existence and allows the sales order line to proceed. If the product is not found or an error occurs, the iPaaS.com stops processing the line item. This ensures only valid products are added to the sales order.

Mapping Type

Source (iPaaS.com)

Destination (Acumatica)

Description

Field

Description

LineDescription

Line item description.

Static

true

ManualPrice

ManualPrice must be statically set to True for this integration.

Field

Sku

InventoryID

Field

Qty

OrderQty

Dynamic Formula

ExtendedPrice

Amount

Retrieves the amount for an Acumatica Sales Order from iPaaS.com. It represents the extended price, which is typically calculated by multiplying the item’s unit price by the quantity, giving the total cost for that item on the order.

Dynamic Formula

ExtendedPrice

Extended Price

Retrieves the Extended Price for an Acumatica Sales Order from iPaaS.com. It represents the extended price, which is typically calculated by multiplying the item’s unit price by the quantity, giving the total cost for that item on the order.

Dynamic Formula

UnitPrice

DiscountedUnitPrice

Retrieves the Discounted Unit Price for an Acumatica Sales Order from iPaaS.com. It represents the price of a single unit of an item before any discounts are applied. This value is used to calculate the total cost for the item on the order.

Dynamic Formula

UnitPrice

UnitPrice

Retrieves the Discounted Unit Price for an Acumatica Sales Order from iPaaS.com. It represents the price of a single unit of an item before any discounts are applied. This value is used to calculate the total cost for the item on the order.

Acumatica Sales Order Payment From iPaaS (Child Collection

Mapping Type

Source (iPaaS.com)

Destination (Acumatica)

Description

Field

Amount

AppliedToOrder

The payment amount applied to the order.

Field

Amount

PaymentAmount

The payment amount.

Static

ONLINE

PaymentMethod

PaymentMethod (Acumatica Sales Order Payment From iPaaS) - Template mappings currently assign a placeholder payment method for all external orders uploaded to Acumatica. The payment method name used will need to exist in Acumatica (payment methods can be found in screen CA2040PL).

Create a translation or mapping formula to assign other payment method names based on the source payment method. At this time, the transfer of Acumatica payment methods to iPaaS.com is not supported by this integration.

IMPORTANT: All payment method requirements must be provided. A payment reference is included in the template mappings which are required for many payments (the iPaaS transaction payment id is provided).

Dynamic Formula

"iPaaS.com " + Id

PaymentRef

This formula, "iPaaS.com"+Id, creates a unique payment reference for an Acumatica Sales Order from iPaaS.com. It combines the label "iPaaS.com" with the order or transaction ID, ensuring each payment is easily identifiable and linked to the specific transaction within the system.

Acumatica Sales Order Tax From iPaaS (Child Collection)

Mapping Type

Source (iPaaS.com)

Destination (Acumatica)

Description

Field

Amount

TaxAmount

Field

TaxPercent

TaxRate

Dynamic Formula

await GetTaxId();

SpaceportSystemId

Used to provide system id (subscription id) in integration code.

Dynamic Formula

await GetTaxId();

TaxID

Provided in the template mappings that will return the first tax id found.
Tax ID (Acumatica Sales Order Tax From iPaaS) – To upload taxes collected externally when creating Acumatica sales orders, a tax Id must be provided, that tax Id must exist as an eligible tax code for the tax category assigned to the products on the order:

IMPORTANT: The tax zones assigned to products can be found in Acumatica screen ID TX2060PL and inside each eligible tax zone, the Tax ID that will be designated for imported orders must be added.

Acumatica Sales Order Tracking Number From iPaaS (Child Collection)

Mapping Filter

var boxId = GetCustomFieldValue(CustomFields, "BoxId"); var warehouseId = GetCustomFieldValue(CustomFields, "WarehouseId"); if(boxId!= null && boxId!="" && warehouseId!= null && warehouseId!=""){ return true; } return false;

Description

The code checks whether both custom fields, BoxId and WareHouseId, have values. If they do, it triggers the transaction tracking flow in iPaaS. Also, only shipments with the status Open can be created in Acumatica, otherwise Acumatica throws an exception.

The setting Hold Shipments on Entry checkbox must be deactivated in the Sales Orders Preferences (SO101000) screen.

Mapping Type

Source (iPaaS.com)

Destination (Acumatica)

Description

Field

WarehouseId

WarehouseId

This mapping field represents the location of the shipment and can be set using a custom field. Eligible WareHouseId values can be found in Acumatica Screen ID IN2040PL. For procedures and more information, see your Acumatica documentation.

Static

Issue

Operation

Controls the inventory direction (issue, receipt, transfer) and is critical for ensuring proper inventory tracking and transaction type in Acumatica. In Sales Order Shipments, the Operation is always Issue

Dynamic Formula

var customerId = await GetExternalIdAsync(Parent.CustomerId, "Customer", SpaceportSystemId); if (customerId == null || customerId == "") return await GetCustomerIdByEmail(Parent.EmailAddress); else return customerId;

CustomerID

This mapping first attempts to get the customer ID if the Acumatica customer ID exists in iPaaS as an external ID; if not, it retrieves the Acumatica customer ID using the customer's email address.

Dynamic Formula

Parent.TransactionNumber

OrderNbr

Retrieves the transaction number from the parent transaction.

Static

SO

OrderType

A static value (SO) that sets the Sales Order Type in Acumatica.

Static

Open

Status

"Open" is statically mapped to the mapping Status.

Note: Only shipments with the status Open can be created in Acumatica.

Field

BoxId

BoxID_Package

Field

Cost

DeclaredValue_Package

The declared value of the package for shipping and insurance.

Field

ShippingMethodDescription

Description_Package

A description of the shipping method.

Field

TrackingNumber

TrackingNbr_Package

The carrier-provided tracking number.

Field

ShippingMethod

Type_Package

The shipping method or carrier (e.g., FedEx, UPS).

Acumatica Sales Order Tracking Number From iPaaS (Standalone)

Mapping Filter

var boxId = GetCustomFieldValue(CustomFields, "BoxId");
var warehouseId = GetCustomFieldValue(CustomFields, "WarehouseId");
if(string.IsNullOrEmpty(boxId)){
throw new exception("Required: BoxId.");
}
if(string.IsNullOrEmpty(warehouseId)){
throw new exception("Required: WarehouseId.");
}
return true;

Description

The code checks whether the custom field BoxId has a value; if not, it throws an "Required: BoxId."
Similarly, it checks whether the custom field WareHouseId has a value; if not, it throws an "Required: WareHouseId." Only shipments with the status Open can be created in Acumatica, otherwise Acumatica throws an exception.

The setting Hold Shipments on Entry checkbox must be deactivated in the Sales Orders Preferences (SO101000) screen.

Mapping Type

Source (Acumatica)

Destination (iPaaS.com)

Description

Field

WarehouseId

WarehouseId

Represents the location of the shipment and can be set using a custom field.

Eligible WareHouseId values can be found in Acumatica Screen ID IN2040PL. For procedures and more information, see your Acumatica documentation.

Static

Issue

Operation

The Operation field controls the inventory direction (issue, receipt, transfer) and is critical for ensuring proper inventory tracking and transaction type in Acumatica. In Sales Order Shipments, the Operation is almost always Issue.

Dynamic Formula

string CustomerId=""; CustomerId =await GetAcumaticaCustomerId(Id); return CustomerId;

CustomerID

This method asynchronously retrieves the Acumatica customer Id from iPaaS for a given transaction ID.

Field

return await GetIPaaSTransactionNoById(Id);

OrderNbr

Asynchronously retrieves the transaction number from iPaaS using the provided transaction ID.

Field

SO

OrderType

"SO" is statically mapped to the mapping OrderType

Static

Open

Status

Field

BoxId

BoxID_Package

The Custom field BoxId is mapped to the BoxID_Package. It is required for creating packages.
Eligible BoxId values can be found in Acumatica Screen ID CS207600. For procedures and more information, see your Acumatica documentation.

Field

Cost

DeclaredValue_Package

Field

ShippingMethodDescription

Description_Package

Field

TrackingNumber

TrackingNbr_Package

Field

ShippingMethod

Type_Package

Field

iPaaS_LineItemId

iPaaS_LineItemId

The Custom field iPaaS_LineItemId is used to link iPaaS Lines and Trackings. This link will help to maintain the correct processing sequence and reference for the shipment packages in Acumatica when process partial shipments. The format of the field should be TransactionId|TransactionLineId.

Note: iPaaS_LineItemId package contents. This will allow user to know which Acumatica shipment line is shipped in which package.is required for creating

Error Handling

Collection: Sales Order (Parent)

Invalid Customer ID

  • Description: The provided CustomerId does not exist in Acumatica.

  • Resolution: Ensure an external ID mapping exists or provide a valid email for the fallback lookup.

Unsupported Financial Terms

Description: The specified term is not configured in Acumatica (CS2065PL).

  • Resolution: Configure the appropriate credit terms in Acumatica before syncing.

Invalid Tax Zone

  • Description: The Tax Zone ID is not found in Acumatica (TX2060PL).

  • Resolution: Add or correct the tax zone in Acumatica.

Collection: Sales Order Address

Missing Required Fields

  • Description: FirstName, LastName, City, or Country is null.

  • Resolution: Validate all address fields in iPaaS before syncing.

Invalid Postal Code

  • Description: The PostalCode format fails the regex check for numeric values.

  • Resolution: Correct the postal code to a valid format.

Collection: Sales Order Line

Invalid SKU

  • Description: The SKU (InventoryID) is not found in Acumatica.

  • Resolution: Verify the product exists in Acumatica before the order sync.

Quantity Zero or Negative

  • Description: OrderQty is less than or equal to 0.

  • Resolution: Provide a valid quantity greater than 0.

Collection: Sales Order Payment

Payment Method Not Found

  • Description: The payment method (e.g., ONLINE) is not configured in Acumatica.

  • Resolution: Add the payment method in Acumatica or update the mapping.

Collection: Sales Order Tax

TaxID Not Found

  • Description: The TaxID lookup fails to find a matching ID in Acumatica.

  • Resolution: Configure a matching TaxID in Acumatica.

Validation Rules & Testing

Validation Checklist

  • Customer ID is resolved (via external ID or email).

  • Financial Terms and Tax Zone are assigned and valid in Acumatica.

  • At least one Billing and one Shipping address are present.

  • The Payment Method is valid and active.

  • Each SKU exists in Acumatica.

  • The order Quantity is greater than 0.

Test Scenarios

  • Valid Sales Order: Syncs successfully.

  • Invalid Customer ID: The order is rejected, and an error is logged.

  • SKU not found: The order line is rejected.

  • Missing Billing Address: The order is not created, and an error is logged.

Additional Notes

  • Parent Sales Order validation must pass before any child collections can be synchronized.

  • Errors in a child collection (e.g., an invalid line item) may prevent the entire order from being created, depending on the Acumatica configuration.

  • To prevent sync errors, it is crucial that Financial Terms and Tax Zones are pre-configured in Acumatica.

  • Using external ID lookups is the most reliable mapping method across systems.

Did this answer your question?