Metrics

The Metrics feature enables Admin Users to configure entity-based Metrics directly in the instellix webportal and make the calculated values available to external tools via API.

Overview

Metrics are designed to support different data areas. The initial release provides document-based metrics, while additional data areas will be added in upcoming releases.

Typical use cases include:

  • Counting entities, such as invoices, credit notes, or other supported records
  • Calculating revenue, tax, or net/gross amount totals
  • Filtering metrics by attributes such as currency, entity type, service country, billing group, or due date
  • Providing KPI data to external tools such as Grafana, BI solutions, or custom scripts

The feature is designed for continuously available numeric Metrics without requiring custom reports or manual data exports.

Note: In the current version, metrics can be configured and queried via API. Visualization of metrics directly in portal dashboards is not part of the initial release.


Accessing Metrics

Metrics can be accessed in the webportal via:

Reports → Metrics

The Metrics overview displays all configured metric definitions for the current tenant.
The list can be filtered, and its displayed columns can be adjusted.


Creating a Metric

To create a new metric:

  1. Navigate to Reports → Metrics
  2. Click the + button
  3. Configure the metric definition
  4. Add filters if needed
  5. Click Save

After creation, the metric is processed and becomes available for querying once its status is Ready.

Metric Definition

The following configuration options are available:

FieldDescription
IdentUnique identifier used to reference the metric, including through the API
Data areaDefines the underlying entity or data area used by the metric
Display nameHuman-readable name displayed in the webportal
TypeDefines the metric type. The initial release supports Simple and Grouped metrics
DescriptionOptional description explaining the purpose of the metric
Value typeDefines which value is evaluated, e.g. entity count or monetary value
Aggregation typeDefines how values are aggregated, e.g. Sum
Date attributeDetermines which date attribute is used when assigning values to a period

Example

A metric for counting all EUR invoices could be configured as:

Ident: All_documents
Display name: All Documents
Data area: Document
Type: Simple
Value type: Entity count
Aggregation type: Sum
Date attribute: Document date (UTC)

Filters:
Currency: EUR
Type: Invoice

This metric counts entities matching the configured filters and assigns them to the corresponding time period based on the selected date attribute.


Filters

Filters can be used to restrict which entities contribute to a metric.

Available filters depend on the selected data area and may include attributes such as:

  • Currency
  • Entity type
  • Due date
  • Service country
  • Billing group
  • Self-managed payment method
  • Operating site ident
  • Seller operating site ident

Only entities matching the configured filter criteria contribute to the metric value.

For example:

Currency = EUR
Type = Invoice

limits the metric to invoices in EUR.

The configured filters can also be viewed from the metric details page.


Querying Metric Values

Each metric provides a query endpoint that can be used by external clients.

The general endpoint is:

GET /api/v2/metrics/{ident}/values

A date range can be supplied using the from and to query parameters.

Example:

GET /api/v2/metrics/All_documents/values?from=2026-07-22T18:23:09.709Z&to=2026-08-21T18:23:09.709Z

The Metric Details page provides:

  • Query path
  • Query URL
  • cURL example

These values can be copied directly from the portal.

cURL Example

curl -X GET 'https://<host>/api/v2/metrics/All_documents/values?from=<from>&to=<to>' \
  -H 'Authorization: Bearer <ACCESS_TOKEN>' \
  -H 'Accept: application/json'

The from and to parameters can be adjusted according to the required reporting period.


Using Metrics in Dashboards

The Metrics API is designed to be consumed by external visualization and analytics tools such as:

  • Grafana
  • BI platforms
  • Monitoring solutions
  • Custom applications and scripts

For example, Grafana can use a JSON API or Infinity data source to query the metric endpoint periodically.

For production environments, the appropriate API gateway host and API credentials must be used.

This makes it possible to build continuously updated dashboards without generating Standard Report files first.


Metrics vs. Standard Reports

Metrics and Standard Reports serve different purposes.

MetricsStandard Reports
Numeric KPI valuesFile-based data reports
Designed for frequent queriesDesigned for report generation
Suitable for dashboardsSuitable for detailed reports
API-based consumptionFile-based consumption
Continuously updatedGenerated on demand or schedule
Optimized for aggregated informationSuitable for detailed datasets

Use Metrics when an application needs a numeric KPI such as:

Number of invoices
Total net amount
Average gross amount
Tax total
Entities by country

Use Standard Reports when detailed entity-level information needs to be exported.


Permissions

Metric configuration and metric querying use separate authorization concepts.

Management operations require the appropriate Metrics permissions:

metrics-management-read
metrics-management-write

Querying metrics uses the corresponding read permission for the selected data area. For document-based metrics, this is currently:

document-management-read

As additional entities and data areas are introduced, their respective domain permissions will apply.

This separation allows admin users to control who can configure metrics from the users that only need to retrieve metric values.


Example Use Cases

A tenant could configure metrics such as:

All invoices
Invoices in EUR
Number of credit notes
Total net invoice amount
Total tax amount
Average gross invoice amount
Invoices for a specific service country
Entities for a specific billing group

As additional data areas become available, similar metrics can be configured for other supported data areas.

These metric definitions can then be queried repeatedly by external systems and used to build operational dashboards and KPI monitoring.


Did this page help you?