Get Metrics

GET

Get invoice metrics for an entity with the given filters. Invoices will always be grouped by currency. If none of excludePayables, excludeReceivables, payerId, vendorId, or invoiceId status filters are provided, excludeReceivables will be set to true.

Path parameters

entityIdstringRequired

Entity ID or Entity ForeignID

Query parameters

searchstringOptional

Find invoices by vendor name, invoice number, or amount. Partial matches are supported.

excludePayablesbooleanOptional

Only return invoices that are not payable by the entity. This will return only invoices that are receivable by the entity.

excludeReceivablesbooleanOptional

Only return invoices that are not receivable by the entity. This will return only invoices that are payable by the entity.

returnByDateenumOptional

Return invoice metrics grouped by date.

Allowed values: CREATION_DATEDUE_DATEINVOICE_DATEDEDUCTION_DATE
returnByDateFrequencyenumOptional

Return invoice metrics grouped by date. Defaults to daily.

Allowed values: DAILYWEEKLYMONTHLYYEARLY
groupBy"STATUS"Optional

Return invoice metrics grouped by.

Allowed values: STATUS
payerIdstringOptional

Filter invoices by payer ID.

vendorIdstringOptional

Filter invoices by vendor ID.

approverIdstringOptional

Filter invoices by assigned approver user ID.

invoiceIdstringOptional

Filter invoices by invoice ID.

statusenumOptional

Invoice status to filter on

startDatedatetimeOptional

Start date filter. Defaults to CREATED_AT unless specified the dateType is specified

endDatedatetimeOptional

End date filter. Defaults to CREATED_AT unless specified the dateType is specified

dateTypeenumOptional

Type of date to filter by if startDate and endDate filters are provided. Defaults to CREATED_AT.

currencyenumOptional

Currency to filter on

Response

This endpoint returns a list of objects.
totalAmountdouble
totalCountinteger
averageAmountdouble
currencyenum
grouplist of maps from strings to stringsOptional

If groupBy is provided, this will be the group by value.

datesmap from strings to objectsOptional