Acumatica

1 Connecting to Acumatica

In order to connect to the Acumatica data source, you will first need to specify the below connection properties.

  • Url: (Required) The base URL for the Acumatica ERP instance. For example: https://domain.acumatica.com/entity/.

  • Schema: (Optional) There are two schemas which contains different data. The default one is REST which uses the Acumatica REST Contract Based API and the OData which uses the Acumatica OData API. The OData schema is used to query Acumatica Generic Inquiries.

  • Company: (Partially required) Set this to the name of your company or tenant. It is required if Schema is set to "OData".

  • EndpointVersion: (Optional) The version of the Web Services endpoint. For example: 17.200.001. This is applicable only for the "REST" schema.

  • EndpointName: (Optional) The name of the Web Services endpoint. For example: Default. This is applicable only for the "REST" schema.

To find out the EndpointVersion and EndpointName for your Acumatica instance, log into Acumatica in a web browser, and then navigate to the 'Web Service Endpoints' screen. If necessary, navigate to this screen by editing the web browser URL and replacing ScreenId=00000000 (the homepage) with ScreenId=SM207060. If you are redirected back to the homepage, this means your user does not have the necessary permissions to access web services. Under Endpoints properties get the Endpoint Name and Endpoint Version.

2 Authenticating to Acumatica

There are two authentication methods available for connecting to Acumatica data source, Basic and OAuth.

2.1 Authenticating with User Credentials

Set the AuthScheme to Basic and set the User and Password to your login credentials.

2.2 Authenticating with OAuth

The Acumatica data source also supports the OAuth 2.0 authentication standard. To authenticate using OAuth, you will need to create and configure a custom OAuth app, then set AuthScheme to OAuth and fill in the OAuth credentials.

3 Register an OAuth Application

You can follow the procedure below to obtain the OAuth client credentials, the OAuthClientId and OAuthClientSecret.

  1. You use the Connected Applications (SM303010) form to register an OAuth 2.0 or OpenID Connect client application. To register a client application in Acumatica ERP, you need to know the OAuth 2.0 flow that this application implements.

  2. When you are registering the client application, you have to be logged in to the tenant whose data the client application needs to access.

  3. On the System tab, click Integration. In the navigation pane, navigate to Configure > Connected Applications.

  4. In the Client Name box, type the name of the registered application.

  5. In the OAuth 2.0 Flow box, select Authorization Code.

  6. On the Secrets tab, do the following for each client secret you want to add:

    1. On the tab toolbar, click Add Shared Secret. The Add Shared Secret dialog box opens.

    2. In the Description box, type the description of the shared secret.

    3. Optional: In the Expires On (UTC) box, enter the date and time on which the secret expires.

    4. Copy and save the value that is displayed in the Value box. The client application should use this client secret for authentication in Acumatica ERP.

  7. Click OK to save the secret and close the dialog box.

  8. On the Redirect URIs tab, do the following for each redirect URI you want to add: On the tab toolbar, click Add Row. In the Redirect URI column of the new row, type the exact redirect URI to which Acumatica ERP should redirect the client application after the client application has been authorized. The redirect URI must be absolute and must not have the fragment part (the part preceded with #). On the form toolbar, click Save. Notice that the client ID has been generated in the Client ID box. The client application should use this client ID along with the client secret for authentication in Acumatica ERP.

In order to obtain a token, the client application needs to call the Oauth2 endpoint using various grants depending on the authentication scenarios required. The default OAuthGrantType is CODE, which requires you to follow the steps below. After setting the following connection properties, you are ready to connect:

  • OAuthClientId: Set this to your clientId.

  • OAuthClientSecret: Set this to your clientSecret.

  • InitiateOAuth: Set this to GETANDREFRESH. You can use InitiateOAuth to avoid repeating the OAuth exchange and manually setting the OAuthAccessToken connection property.

  • CallbackURL: Set this to the redirect URI configured in the oauth application.

When you connect, the connector completes the OAuth process:

  1. Extracts the access token from the CallbackURL.

  2. Obtains a new access token when the old one expires.

  3. Saves OAuth values along with geolocation in OAuthSettingsLocation to be persisted across connections.

The following are the connection properties for Acumatica. Not all properties are required. Enter only property values pertaining to your installation. Several properties will be automatically initialized with the appRules defaults.

Property

Description

Authentication

Company

Your Acumatica Company.

Password

Your Acumatica password that goes with the $rpUser;.

URL

Url parameter is used to Authenticate the driver with the Acumatica API.

User

Your Acumatica username.

Caching

AutoCache

Automatically caches the results of SELECT queries into a cache database specified by either CacheLocation or both of CacheConnection and CacheProvider .

CacheConnection

The connection string for the cache database. This property is always used in conjunction with CacheProvider . Setting both properties will override the value set for CacheLocation for caching data.

CacheLocation

Specifies the path to the cache when caching to a file.

CacheMetadata

This property determines whether or not to cache the table metadata to a file store.

CacheProvider

The name of the provider to be used to cache data.

CacheTolerance

The tolerance for stale data in the cache specified in seconds when using AutoCache .

Offline

Use offline mode to get the data from the cache instead of the live source.

Firewall

FirewallPassword

A password used to authenticate to a proxy-based firewall.

FirewallPort

The TCP port for a proxy-based firewall.

FirewallServer

The name or IP address of a proxy-based firewall.

FirewallType

The protocol used by a proxy-based firewall.

FirewallUser

The user name to use to authenticate with a proxy-based firewall.

Logging

Logfile

A path to the log file.

MaxLogFileCount

A string specifying the maximum file count of log files. When the limit is hit, a new log is created in the same folder with the date and time appended to the end and the oldest log file will be deleted.

MaxLogFileSize

A string specifying the maximum size in bytes for a log file (for example, 10 MB). When the limit is hit, a new log is created in the same folder with the date and time appended to the end.

Verbosity

The verbosity level that determines the amount of detail included in the log file.

Misc

ConnectionLifeTime

The maximum lifetime of a connection in seconds. Once the time has elapsed, the connection object is disposed.

ConnectionString

***

GenerateSchemaFiles

Indicates the user preference as to when schemas should be generated and saved.

IncludeCustomFields

Whether or not to retrieve custom fields that are added to Acumatica Screens.

InquiryTables

Comma seperated Inquiry Tables. Inquiry tables in Contract 3 Acumatica API version 17.200.001 are: AccountByPeriodInquiry, AccountBySubaccountInquiry, AccountDetailsInquiry, AccountSummaryInquiry, InventoryAllocationInquiry, InventorySummaryInquiry, InvoicedItemsInquiry, SalesPricesInquiry,VendorPricesInquiry.

MaxRows

Limits the number of rows returned rows when no aggregation or group by is used in the query. This helps avoid performance issues at design time.

Other

These hidden properties are used only in specific use cases.

PoolIdleTimeout

The allowed idle time for a connection before it is closed.

PoolMaxSize

The maximum connections in the pool.

PoolMinSize

The minimum number of connections in the pool.

PoolWaitTime

The max seconds to wait for an available connection.

PseudoColumns

This property indicates whether or not to include pseudo columns as columns to the table.

Readonly

You can use this property to enforce read-only access to Acumatica from the provider.

SSLServerCert

The certificate to be accepted from the server when connecting using TLS/SSL.

SupportEnhancedSQL

This property enhances SQL functionality beyond what can be supported through the API directly, by enabling in-memory client-side processing.

Timeout

The value in seconds until the timeout error is thrown, canceling the operation.

UseConnectionPooling

This property enables connection pooling.

Proxy

ProxyAuthScheme

The authentication type to use to authenticate to the ProxyServer proxy.

ProxyAutoDetect

This indicates whether to use the system proxy settings or not. This takes precedence over other proxy settings, so you'll need to set ProxyAutoDetect to FALSE in order use custom proxy settings.

ProxyExceptions

A semicolon separated list of hosts or IPs that are exempt from connecting through the ProxyServer .

ProxyPassword

A password to be used to authenticate to the ProxyServer proxy.

ProxyPort

The TCP port the ProxyServer proxy is running on.

ProxyServer

The hostname or IP address of a proxy to route HTTP traffic through.

ProxySSLType

The SSL type to use when connecting to the ProxyServer proxy.

ProxyUser

A user name to be used to authenticate to the ProxyServer proxy.

Schema

Location

A path to the directory that contains the schema files defining tables, views, and stored procedures.

Schema

Used to specify what Acumatica Api to use. The default one is the REST Contact API. When OData is specified the OData API will be used and all the Generic Inquires exposed via OData will be dynamically retrieved.

Tables

This property restricts the tables reported to a subset of the available tables. For example, Tables=TableA,TableB,TableC.

Views

Restricts the views reported to a subset of the available tables. For example, Views=ViewA,ViewB,ViewC.

Last updated