Skip to content

Skill: Query AR Invoice Items

The Query AR Invoice Items skill retrieves aggregated accounts receivable invoice item data from Sage Intacct. It is used for revenue analysis, customer billing inquiries, and AR reporting by grouping invoice line items along one or more dimensions.

ParameterTypeRequiredDescription
group_bystringYesHow to group results. Options: customer, glaccount, project, department, location, class, item, employee, vendor. Multiple values can be comma-separated.
start_datestringNoFilter invoice items with a date on or after this value (YYYY-MM-DD).
end_datestringNoFilter invoice items with a date on or before this value (YYYY-MM-DD).
customer_idstringNoFilter by customer ID.
department_idstringNoFilter by department ID.
location_idstringNoFilter by location ID.
project_idstringNoFilter by project ID.
class_idstringNoFilter by class ID.
glaccountstringNoFilter by GL account number.
item_idstringNoFilter by item ID.
employee_idstringNoFilter by employee ID.
vendor_idstringNoFilter by vendor ID.
offsetintegerNoNumber of records to skip for pagination. Defaults to 0.
limitintegerNoMaximum number of grouped records to return. Defaults to 100.

The skill automatically computes these aggregates for each group:

AggregateDescription
SUM(AMOUNT)Total invoiced amount in base currency.
SUM(TRX_AMOUNT)Total invoiced amount in transaction currency.
SUM(QUANTITY)Total quantity across all invoice items in the group.
COUNT(RECORDNO)Number of invoice items in the group.

“How much have we invoiced each customer this quarter?”

The agent would invoke:

  • group_by: customer
  • start_date: 2026-01-01
  • end_date: 2026-03-31

“Show me the AR breakdown by item for the consulting department.”

The agent would invoke:

  • group_by: item
  • department_id: CONSULT

The skill returns an array of grouped records, each containing:

  • Group key(s) — the dimension value(s) used for grouping (e.g., customer name, item name).
  • SUM_AMOUNT — total base-currency invoiced amount.
  • SUM_TRX_AMOUNT — total transaction-currency invoiced amount.
  • SUM_QUANTITY — total quantity invoiced.
  • COUNT_RECORDNO — count of invoice line items.

Results are sorted by SUM_AMOUNT in descending order by default.

POST /api/sage-intacct/v1.0/query-arinvoiceitem


Related skills: Query AP Bill Items | Query GL Detail | Query Projects