Search Datamart - Customer Transactions

The pricefx_acc_ag_get_datamart_customer_transactions tool returns the most recent sales transactions of one customer from the transaction Datamart that Accelerate Agents uses. You can filter the transactions by time period, location, product attribute, or a numeric condition, such as margin. You can filter the transactions by time period, date range, location, customer attribute, or a numeric condition, such as margin.

Tool Name – pricefx_acc_ag_get_datamart_customer_transactions

Title – Search Datamart: customer transactions with optional advanced filters (period, location, condition)

Type – Private

Access Profile – Configurator

This tool is only available with the Accelerate Agents 1.6.

Permissions

The tool is available only to the Configurator access profile when tool access control is on.

Parameters

Parameter

Required

Description

customerIdInput

Yes, if customerNameInput is not given

Customer ID. Not case-sensitive. Spaces are ignored.

customerNameInput

Yes, if customerIdInput is not given

Full customer name. Not case-sensitive. Spaces are ignored. The name must match exactly: part of a name does not find the customer. The tool ignores this parameter when customerIdInput is given.

periodNameInput

No

Time period unit:

  • day

  • month

  • year

Default: no time limit.

periodValueInput

No

Number of period units to look back.

Default: 1.

locationAttributeNameInput

No

Name of the location field to filter by, for example country or region.

locationValuesInput

No

Locations to include, for example Germany and France. A transaction matches when it has any of the values.

productAttributeNameInput

No

Name of the product field to filter by, for example product group.

productAttributeValueInput

No

Text that the product field contains. Not case-sensitive. Requires productAttributeNameInput.

conditionFieldNameInput

No

Name of a numeric field to compare, for example margin or discount.

conditionOperatorInput

No

Comparison: equals, greaterThan, greaterOrEqual, lessThan, or lessOrEqual.

Default: equals.

conditionValueInput

No

Value to compare with: a number (10, 0.7) or a percentage (5%). Requires conditionFieldNameInput.

maxRowsInput

No

Maximum number of transactions to return, up to 10.

Default: 10.

transactionFieldsInput

No

Names of extra Datamart fields to include in the result, in addition to the configured default fields.

dateFromInput

No

First day of the date range, in yyyy-MM-dd format, for example 2025-01-01. The tool returns transactions on or after this date.

dateToInput

No

Last day of the date range, in yyyy-MM-dd format, for example 2025-12-31. The tool returns transactions on or before this date.

Output

The tool returns a list of transactions, newest first by pricing date. Each transaction includes the default fields configured for Accelerate Agents and the fields from transactionFieldsInput, up to 20 fields in total. Money values are rounded to 2 decimal places and shown with the currency symbol.

Behavior and Limitations

  • The tool always reads the transaction Datamart that is configured for Sales Insights or, if that is not set up, for Customer Insights. You cannot choose another Datamart.

  • The tool returns at most 10 transactions per call.

  • Field names are matched loosely. The tool compares names without regard to case or spaces, and also matches part of a field name, label, or description. The tool uses the first matching field, so a short name such as margin can match a different field than you expect.

  • The time period starts at the beginning of a month or day. For example, month with 1 returns transactions from the start of the previous month, which includes the current month. day with 7 returns transactions from the start of the day 7 days ago.

  • If the location field is not found, or locationAttributeNameInput is not given, the tool looks for the location values in all text fields named like country, region, area, city, or location.

  • If the condition field is not found, the tool ignores the condition and does not report an error. The result then contains transactions without the condition.

  • A percentage in conditionValueInput is converted to a fraction: 5% becomes 0.05.

  • To get the transactions behind an Agent action item, use the Get Customer Transactions (Agent action) tool, pricefx_acc_ag_get_agents_customer_transactions.

  • The date range filters on the pricing date. You can give dateFromInput, dateToInput, or both.

  • When you give dateFromInput or dateToInput, the tool ignores periodNameInput and periodValueInput.

Errors

Situation

Error Message

No customer matches the ID or name, or neither is given

There is no customer Id can be found.

Neither Sales Insights nor Customer Insights is configured

Neither SI nor CI mapping configuration was found.

The configured Datamart does not exist

Datamart X doesn't exist.

The Datamart has no pricing date field

Datamart configuration is missing pricingDate fields.

The product attribute field is not found

Couldn’t find any Datamart field name containing 'X'.

conditionOperatorInput is not supported

Unsupported filter operator: X

conditionValueInput is not a number

Couldn't convert X to number.

dateFromInput or dateToInput is not in yyyy-MM-dd format

The date format is invalid. Only the yyyy-MM-dd format is supported.