On this page
Summarize transactions
Filter transaction history and calculate aggregates.
Before you begin: Read account data.
Transactions
Use $transactions for the current user's site transactions. This is useful for dashboards, portfolios, and transaction history pages without writing a custom endpoint for every theme.
Transaction rows include requested payment values and actual paid values:
| Field | Meaning |
|---|---|
requestedAmount | Amount the site asked the user to pay in the platform currency. |
requestedCurrency | Platform currency for the requested amount, such as USD or NGN. |
paidAmount | Amount the user actually paid after any method conversion. |
paidCurrency | Currency or crypto asset the user paid with, such as USD, BTC, or ETH. |
status | Payment status, such as pending, failed, or successful. |
kind | Transaction direction, such as deposit. |
tag | Theme-provided label for what the payment is for. |
Transaction rows expose the stored status. Completed payments currently appear as successful in FQL transaction filters and rows. FRL payment events expose the same completion event as payment confirmed with $payment.status == "confirmed" so rule code reads like an event, while $payment.rawStatus keeps the stored transaction value available.
Transaction selectors in state use special keys such as $list, $where, $order, $limit, and $page. This keeps selector metadata separate from normal transaction fields.
Aggregates
FQL can ask Frontbacked for counts and sums for $transactions and post sources. Frontbacked returns only the computed value.
For sums, the field to sum is a normal path segment after $sum:
Parentheses run registered page functions. They do not select aggregate fields.
In that expression, Frontbacked sums requestedAmount, then the browser passes the returned value into formatMoney.
Do not use $sum(requestedAmount). Function arguments are supported, but aggregate fields are selected as path segments after $sum.
Older themes may still use $counts, but new FQL should use $count.
When summing paidAmount, filter to one currency or billing method so you do not add mixed units together:
In raw FQL attributes, dynamic roots can be written with or without quotes when the whole quoted value is a FQL special root/path:
Both forms above resolve $now to the page's current-time snapshot. In {STATE} selectors, $now may be written bare in JS-style state declarations or as "$now" in JSON-compatible state. Use the transaction field name expiresOn, not expires.
Continue with Query a list.