Trax Platform APIv1

Reports and the troubleshooting log

This guide is for the nFocus admin app and the organization site. It covers reports (how a site, an organization or a client is used) and the troubleshooting log (what goes wrong on a client's portals and websites, recorded so support and the organization can see it without reading Graylog).

Reports

Every report answers in the same shape, so a new report never changes the contract. There are eight reports.

Report Counts Who runs it Groupings
site-usage Catalog searches, activity views, carts started, checkouts completed and donations started (the API's own counts), and page views, active users and analytics events from GA4 where a property is connected Organizations and nFocus day, week, month, childOrganization, client, page
sign-ins Family sign-ins and new accounts (legacy OLR and the new portal), failed sign-ins and lockouts (the new portal), staff sign-ins Organizations and nFocus day, week, month, childOrganization, client
registration-revenue Online registrations and memberships, and what online payments paid for registrations, memberships and other charges, on the new portal and legacy OLR Organizations and nFocus day, week, month, program, location, activity, channel, childOrganization, client
donation-revenue Online gifts and their amount, signed in and anonymous, by designation, on the new portal and legacy OLR Organizations and nFocus day, week, month, designation, channel, childOrganization, client
outstanding-balances What accounts have left to pay now: the balance, not yet due, past due, and 1–30, 31–60, 61–90 and over 90 days past due; detail rows by account Organizations program, location, childOrganization
waitlists Activities that haven't ended with someone waitlisted, now: waitlisted and enrolled; detail rows by participant Organizations activity, program, location, childOrganization
cart-conversion Carts started, checkouts completed, carts a reminder brought back, abandoned carts and the conversion rate Organizations day, week, month, childOrganization
platform-adoption Each client's portals by rollout status, websites by provider, nFocus templates in use, and capabilities nFocus turned off or locked on, as of now nFocus client

Listing and running

GET /v1/manage/reports lists the reports you may run, with your own scopes. GET /v1/admin/reports lists nFocus's.

The reports you may run, with your scopes

GET https://api.nfocus.solutions/v1/manage/reports → 200 OK, JSON

curl
curl -s 'https://api.nfocus.solutions/v1/manage/reports' \
  -H 'Authorization: Bearer your_keycloak_access_token'
JavaScript
const response = await fetch('https://api.nfocus.solutions/v1/manage/reports', {
  headers: {
    'Authorization': 'Bearer your_keycloak_access_token',
  },
});
const data = await response.json();
C#
using var http = new HttpClient();
using var request = new HttpRequestMessage(HttpMethod.Get, "https://api.nfocus.solutions/v1/manage/reports");
request.Headers.Authorization = new("Bearer", "your_keycloak_access_token");
using var response = await http.SendAsync(request);
var json = await response.Content.ReadAsStringAsync();

Run one with GET …/reports/{key}:

A site's sign-ins by week

GET https://api.nfocus.solutions/v1/manage/reports/sign-ins?scope=site%3A3f6b1c2e-8a4d-4e7b-9f10-5c2d7e8a9b01&from=2026-11-01&to=2026-11-30&groupBy=week → 200 OK, JSON

curl
curl -s 'https://api.nfocus.solutions/v1/manage/reports/sign-ins?scope=site%3A3f6b1c2e-8a4d-4e7b-9f10-5c2d7e8a9b01&from=2026-11-01&to=2026-11-30&groupBy=week' \
  -H 'Authorization: Bearer your_keycloak_access_token'
JavaScript
const response = await fetch('https://api.nfocus.solutions/v1/manage/reports/sign-ins?scope=site%3A3f6b1c2e-8a4d-4e7b-9f10-5c2d7e8a9b01&from=2026-11-01&to=2026-11-30&groupBy=week', {
  headers: {
    'Authorization': 'Bearer your_keycloak_access_token',
  },
});
const data = await response.json();
C#
using var http = new HttpClient();
using var request = new HttpRequestMessage(HttpMethod.Get, "https://api.nfocus.solutions/v1/manage/reports/sign-ins?scope=site%3A3f6b1c2e-8a4d-4e7b-9f10-5c2d7e8a9b01&from=2026-11-01&to=2026-11-30&groupBy=week");
request.Headers.Authorization = new("Bearer", "your_keycloak_access_token");
using var response = await http.SendAsync(request);
var json = await response.Content.ReadAsStringAsync();

The answer has:

CSV: send Accept: text/csv for every row as a CSV file, with the column keys as its header.

A client's site usage by month

GET https://api.nfocus.solutions/v1/admin/reports/site-usage?scope=client%3A101&from=2026-09-01&to=2026-11-30&groupBy=month → 200 OK, JSON

curl
curl -s 'https://api.nfocus.solutions/v1/admin/reports/site-usage?scope=client%3A101&from=2026-09-01&to=2026-11-30&groupBy=month' \
  -H 'Authorization: Bearer your_admin_app_access_token'
JavaScript
const response = await fetch('https://api.nfocus.solutions/v1/admin/reports/site-usage?scope=client%3A101&from=2026-09-01&to=2026-11-30&groupBy=month', {
  headers: {
    'Authorization': 'Bearer your_admin_app_access_token',
  },
});
const data = await response.json();
C#
using var http = new HttpClient();
using var request = new HttpRequestMessage(HttpMethod.Get, "https://api.nfocus.solutions/v1/admin/reports/site-usage?scope=client%3A101&from=2026-09-01&to=2026-11-30&groupBy=month");
request.Headers.Authorization = new("Bearer", "your_admin_app_access_token");
using var response = await http.SendAsync(request);
var json = await response.Content.ReadAsStringAsync();

A site's registration revenue by channel

GET https://api.nfocus.solutions/v1/manage/reports/registration-revenue?scope=site%3A3f6b1c2e-8a4d-4e7b-9f10-5c2d7e8a9b01&from=2026-06-01&to=2026-11-30&groupBy=channel → 200 OK, JSON

curl
curl -s 'https://api.nfocus.solutions/v1/manage/reports/registration-revenue?scope=site%3A3f6b1c2e-8a4d-4e7b-9f10-5c2d7e8a9b01&from=2026-06-01&to=2026-11-30&groupBy=channel' \
  -H 'Authorization: Bearer your_keycloak_access_token'
JavaScript
const response = await fetch('https://api.nfocus.solutions/v1/manage/reports/registration-revenue?scope=site%3A3f6b1c2e-8a4d-4e7b-9f10-5c2d7e8a9b01&from=2026-06-01&to=2026-11-30&groupBy=channel', {
  headers: {
    'Authorization': 'Bearer your_keycloak_access_token',
  },
});
const data = await response.json();
C#
using var http = new HttpClient();
using var request = new HttpRequestMessage(HttpMethod.Get, "https://api.nfocus.solutions/v1/manage/reports/registration-revenue?scope=site%3A3f6b1c2e-8a4d-4e7b-9f10-5c2d7e8a9b01&from=2026-06-01&to=2026-11-30&groupBy=channel");
request.Headers.Authorization = new("Bearer", "your_keycloak_access_token");
using var response = await http.SendAsync(request);
var json = await response.Content.ReadAsStringAsync();

A client's gifts by channel

GET https://api.nfocus.solutions/v1/admin/reports/donation-revenue?scope=client%3A101&from=2026-06-01&to=2026-11-30&groupBy=channel → 200 OK, JSON

curl
curl -s 'https://api.nfocus.solutions/v1/admin/reports/donation-revenue?scope=client%3A101&from=2026-06-01&to=2026-11-30&groupBy=channel' \
  -H 'Authorization: Bearer your_admin_app_access_token'
JavaScript
const response = await fetch('https://api.nfocus.solutions/v1/admin/reports/donation-revenue?scope=client%3A101&from=2026-06-01&to=2026-11-30&groupBy=channel', {
  headers: {
    'Authorization': 'Bearer your_admin_app_access_token',
  },
});
const data = await response.json();
C#
using var http = new HttpClient();
using var request = new HttpRequestMessage(HttpMethod.Get, "https://api.nfocus.solutions/v1/admin/reports/donation-revenue?scope=client%3A101&from=2026-06-01&to=2026-11-30&groupBy=channel");
request.Headers.Authorization = new("Bearer", "your_admin_app_access_token");
using var response = await http.SendAsync(request);
var json = await response.Content.ReadAsStringAsync();

Who may run what

Limits

A report answers within these limits, or answers 422 report-too-large with what to change:

Dates run from 1900-01-01 to 2199-12-31; others answer 400 on from or to.

A range longer than 400 days

GET https://api.nfocus.solutions/v1/admin/reports/sign-ins?scope=all&from=2025-01-01&to=2026-11-30 → 422, problem details

curl
curl -s 'https://api.nfocus.solutions/v1/admin/reports/sign-ins?scope=all&from=2025-01-01&to=2026-11-30' \
  -H 'Authorization: Bearer your_admin_app_access_token'
JavaScript
const response = await fetch('https://api.nfocus.solutions/v1/admin/reports/sign-ins?scope=all&from=2025-01-01&to=2026-11-30', {
  headers: {
    'Authorization': 'Bearer your_admin_app_access_token',
  },
});
const data = await response.json();
C#
using var http = new HttpClient();
using var request = new HttpRequestMessage(HttpMethod.Get, "https://api.nfocus.solutions/v1/admin/reports/sign-ins?scope=all&from=2025-01-01&to=2026-11-30");
request.Headers.Authorization = new("Bearer", "your_admin_app_access_token");
using var response = await http.SendAsync(request);
var json = await response.Content.ReadAsStringAsync();

Dates and time zones

Where the numbers come from

Rows that name people

Outstanding balances and waitlists can list the people behind the totals, for the organization's own staff:

The answer's groupBy is account or participant, and its totals are the grouped report's.

Who may see them, and what is refused:

Exports work as for any report, and each run is audited with detail=true. Without detail, no row names anyone.

A site's waitlisted participants, by name

GET https://api.nfocus.solutions/v1/manage/reports/waitlists?scope=site%3A3f6b1c2e-8a4d-4e7b-9f10-5c2d7e8a9b01&detail=true → 200 OK, JSON

curl
curl -s 'https://api.nfocus.solutions/v1/manage/reports/waitlists?scope=site%3A3f6b1c2e-8a4d-4e7b-9f10-5c2d7e8a9b01&detail=true' \
  -H 'Authorization: Bearer your_keycloak_access_token'
JavaScript
const response = await fetch('https://api.nfocus.solutions/v1/manage/reports/waitlists?scope=site%3A3f6b1c2e-8a4d-4e7b-9f10-5c2d7e8a9b01&detail=true', {
  headers: {
    'Authorization': 'Bearer your_keycloak_access_token',
  },
});
const data = await response.json();
C#
using var http = new HttpClient();
using var request = new HttpRequestMessage(HttpMethod.Get, "https://api.nfocus.solutions/v1/manage/reports/waitlists?scope=site%3A3f6b1c2e-8a4d-4e7b-9f10-5c2d7e8a9b01&detail=true");
request.Headers.Authorization = new("Bearer", "your_keycloak_access_token");
using var response = await http.SendAsync(request);
var json = await response.Content.ReadAsStringAsync();

nFocus asking for rows that name people

GET https://api.nfocus.solutions/v1/admin/reports/registration-revenue?scope=client%3A101&from=2026-06-01&to=2026-11-30&detail=true → 400, problem details

curl
curl -s 'https://api.nfocus.solutions/v1/admin/reports/registration-revenue?scope=client%3A101&from=2026-06-01&to=2026-11-30&detail=true' \
  -H 'Authorization: Bearer your_admin_app_access_token'
JavaScript
const response = await fetch('https://api.nfocus.solutions/v1/admin/reports/registration-revenue?scope=client%3A101&from=2026-06-01&to=2026-11-30&detail=true', {
  headers: {
    'Authorization': 'Bearer your_admin_app_access_token',
  },
});
const data = await response.json();
C#
using var http = new HttpClient();
using var request = new HttpRequestMessage(HttpMethod.Get, "https://api.nfocus.solutions/v1/admin/reports/registration-revenue?scope=client%3A101&from=2026-06-01&to=2026-11-30&detail=true");
request.Headers.Authorization = new("Bearer", "your_admin_app_access_token");
using var response = await http.SendAsync(request);
var json = await response.Content.ReadAsStringAsync();

The troubleshooting log

What the log records

The API and the worker each write an event when something goes wrong that someone may need to act on. Graylog still has the full log; the troubleshooting log keeps a short, searchable record of these events for 90 days.

Kind Written when code
request-error An answer of 500 or more, 503 tenant-unavailable included The problem's code, or unhandled
refusal A refusal worth support's attention (the list below), whatever its status The problem's code
sign-in-failed A failed sign-in on the account pages wrong-password, unknown-login, locked-out or incomplete
locked-out A login is locked after too many wrong passwords locked-out
email-failed An email delivery attempt fails, and when its retries run out The template's name; gave-up for the last
duda-sync-failed A Duda job fails an attempt or gives up Duda's error code
job-failed A worker job's pass fails The job's name
checkout-recovery A checkout found interrupted, a card settlement that fails or gives up, a void still pending interrupted, settling, settlement-failed, voiding
subscription-sync A scheduled payment's subscription fails to sync, or is set aside retrying, failing, set-aside
domain-check A custom domain's check doesn't pass, and when a domain stops serving the site The check's result: not-resolving, points-elsewhere, no-front-end-targets, ownership-not-proved, taken

The refusals recorded are:

Other refusals, such as a validation error, are the caller's own business and stay in Graylog only.

Each event has:

Repeats share a row

Repeated refusals and failed sign-ins of the same kind and code, at the same portal and endpoint, become one row while they keep coming within a minute of the row's first event:

Every other event is a row of its own.

What an event never holds

A summary is filled only with ids, codes, counts, and the names of things staff configured (a template, a job, a collection, a domain). A family appears only as a login id (userId), on sign-in events, and only nFocus sees it.

When writing fails

Each host holds its events for a few seconds and then saves them together. A failed save, or a crash, loses at most those few seconds of events; Graylog still has them. When a host's queue is full, new events are dropped, counted (metric trax.troubleshooting.dropped) and reported as a warning in Graylog. Recording an event never slows an answer and never fails one.

Searching the log (nFocus)

GET /v1/admin/logs searches every client's events, newest first. The read role is enough.

The troubleshooting log: one client's errors, newest first

GET https://api.nfocus.solutions/v1/admin/logs?databaseId=101&severity=error&pageSize=5 → 200 OK, JSON

curl
curl -s 'https://api.nfocus.solutions/v1/admin/logs?databaseId=101&severity=error&pageSize=5' \
  -H 'Authorization: Bearer your_admin_app_access_token'
JavaScript
const response = await fetch('https://api.nfocus.solutions/v1/admin/logs?databaseId=101&severity=error&pageSize=5', {
  headers: {
    'Authorization': 'Bearer your_admin_app_access_token',
  },
});
const data = await response.json();
C#
using var http = new HttpClient();
using var request = new HttpRequestMessage(HttpMethod.Get, "https://api.nfocus.solutions/v1/admin/logs?databaseId=101&severity=error&pageSize=5");
request.Headers.Authorization = new("Bearer", "your_admin_app_access_token");
using var response = await http.SendAsync(request);
var json = await response.Content.ReadAsStringAsync();
Filter What it does
databaseId, orgId One client database, and one portal's organization in it
siteId One site's portal (its events and the site's own)
kind, severity, code One kind, severity or code
traceId The 32-character id from a problem answer
from, to Instants with an offset (2026-12-01T00:00:00Z); to is exclusive, and a repeated row matches when any repeat falls in the range
includeChanges Adds the audit trails' changes (see below)
page, pageSize The usual paging, at most 200 rows a page
format=csv The newest 50,000 matching rows as a CSV file; the X-Trax-Total-Rows header says how many matched

GET /v1/admin/logs/{id} answers one event, or 404 log-event-not-found once it has been purged.

An event that isn't there (events are kept 90 days)

GET https://api.nfocus.solutions/v1/admin/logs/999999999999 → 404, problem details

curl
curl -s 'https://api.nfocus.solutions/v1/admin/logs/999999999999' \
  -H 'Authorization: Bearer your_admin_app_access_token'
JavaScript
const response = await fetch('https://api.nfocus.solutions/v1/admin/logs/999999999999', {
  headers: {
    'Authorization': 'Bearer your_admin_app_access_token',
  },
});
const data = await response.json();
C#
using var http = new HttpClient();
using var request = new HttpRequestMessage(HttpMethod.Get, "https://api.nfocus.solutions/v1/admin/logs/999999999999");
request.Headers.Authorization = new("Bearer", "your_admin_app_access_token");
using var response = await http.SendAsync(request);
var json = await response.Content.ReadAsStringAsync();

Changes beside errors

With includeChanges=true, or kind=change, the answer also lists the changes recorded in the audit trails as kind change, matched by the same filters:

A kind other than change (or a severity other than info) leaves the changes out.

A change and the errors after it line up by time and by traceId. Changes are always info.

Every search is recorded in the admin audit with its filters, never the rows it answered.

The log in the organization site

A Site Admin sees their site's log; an Organization Admin sees every portal and site at or below their organization. nFocus support can read both. Report grants don't include logs.

A site's troubleshooting log, with its audit trail's changes

GET https://api.nfocus.solutions/v1/manage/sites/3f6b1c2e-8a4d-4e7b-9f10-5c2d7e8a9b01/logs?includeChanges=true&pageSize=5 → 200 OK, JSON

curl
curl -s 'https://api.nfocus.solutions/v1/manage/sites/3f6b1c2e-8a4d-4e7b-9f10-5c2d7e8a9b01/logs?includeChanges=true&pageSize=5' \
  -H 'Authorization: Bearer your_keycloak_access_token'
JavaScript
const response = await fetch('https://api.nfocus.solutions/v1/manage/sites/3f6b1c2e-8a4d-4e7b-9f10-5c2d7e8a9b01/logs?includeChanges=true&pageSize=5', {
  headers: {
    'Authorization': 'Bearer your_keycloak_access_token',
  },
});
const data = await response.json();
C#
using var http = new HttpClient();
using var request = new HttpRequestMessage(HttpMethod.Get, "https://api.nfocus.solutions/v1/manage/sites/3f6b1c2e-8a4d-4e7b-9f10-5c2d7e8a9b01/logs?includeChanges=true&pageSize=5");
request.Headers.Authorization = new("Bearer", "your_keycloak_access_token");
using var response = await http.SendAsync(request);
var json = await response.Content.ReadAsStringAsync();

Refusals at every portal at and below an organization

GET https://api.nfocus.solutions/v1/manage/organizations/riverbend/1/logs?kind=refusal&pageSize=5 → 200 OK, JSON

curl
curl -s 'https://api.nfocus.solutions/v1/manage/organizations/riverbend/1/logs?kind=refusal&pageSize=5' \
  -H 'Authorization: Bearer your_keycloak_access_token'
JavaScript
const response = await fetch('https://api.nfocus.solutions/v1/manage/organizations/riverbend/1/logs?kind=refusal&pageSize=5', {
  headers: {
    'Authorization': 'Bearer your_keycloak_access_token',
  },
});
const data = await response.json();
C#
using var http = new HttpClient();
using var request = new HttpRequestMessage(HttpMethod.Get, "https://api.nfocus.solutions/v1/manage/organizations/riverbend/1/logs?kind=refusal&pageSize=5");
request.Headers.Authorization = new("Bearer", "your_keycloak_access_token");
using var response = await http.SendAsync(request);
var json = await response.Content.ReadAsStringAsync();

Retention

Events are kept for Troubleshooting:RetentionDays days (90 by default); the worker's purge job deletes older ones. The audit trails are never purged.