Skip to main content
Accounting rules define which General Ledger (GL) accounts Hyperline uses when posting journal entries. Each rule belongs to a type that matches a specific billing event, and can be scoped to a subset of products, currencies, or payment methods using filters.

Rule types

Accounting > Settings > Rules has four tabs, one per rule type:
Rules of all types can coexist in the same ledger. Revenue recognition settings are resolved at invoice posting time alongside the Invoice posted rule — they are not triggered by a separate event.
A fifth type, accounting software sync, exists but is not configured here — see sync rules below.

Account mappings

Each rule specifies which GL account to use for each role in the journal entry. The available account roles depend on the rule type: Invoice posted
  • Accounts receivable
  • Revenue account
  • Deferred revenue
  • Output tax / VAT
  • Discount account
  • Deferred discount account
  • Contra-revenue account
  • Customer credits account
  • Bad debt / allowance for doubtful accounts
Invoice settled
  • Cash / bank account
  • Payment clearing account
  • Provider fees expense account
  • Payment processing fees account
  • Accounts receivable (cleared on settlement)
Credit note created
  • Customer credits account
  • Contra-revenue account
  • Deferred discount account
  • Revenue account (reversed)
  • Output tax account (reversed)
  • Accounts receivable (for unpaid invoices)
Revenue recognition
  • Revenue account (when recognised)
  • Deferred revenue (until recognised)
Beyond accounts, the Revenue recognition rule also carries the recognition behaviour itself:
  • The recognition method — over time, point in time, or usage-based
  • The granularity (for over-time) or the recognition date basis (for point-in-time)
  • The discount recognition mode — immediate, deferred, or use net amount
See Revenue recognition for what each of these does.

Accounting software sync rules

Accounting software sync rules map Hyperline billing records to the accounts expected by your connected accounting provider. When Hyperline sends a record to an external accounting provider, the resolved account is converted to the provider account code or internal account ID required by that provider.
These rules are not configured on the accounting Rules page. Set them up under Settings > Integrations, on the connected provider.
For invoice sync rules, the main Revenue account is used for regular invoice and credit note lines. The optional Bad Debt Expense account is used by providers that create a write-off record for uncollectible invoices. For example, NetSuite uses this account on the write-off Credit Memo created and applied to the original invoice when an invoice is marked uncollectible. Accounts can be created manually in Hyperline or fetched from your accounting provider by syncing the ledger’s chart of accounts. See Chart of accounts.

View the rule tree

Each tab of Accounting > Settings > Rules displays that type’s rules as a tree, showing which rules would apply and in what order. This is useful for auditing your rule configuration before going live.

Filters

Rules can be scoped using one or more filters. Available filters depend on the rule type. When a billing event occurs, Hyperline evaluates all matching rules and applies them in priority order. Invoice posted Invoice settled Credit note created Revenue recognition An empty filter matches everything — rules with no filters act as catch-all defaults.
Rules can also be scoped to specific customers, but only through the API — customer scoping is not offered in the rule form.

Criteria reference

The rule form can use the following criteria, depending on the selected rule type:

Priority and fallback

Priority is not something you set. Hyperline derives it from how narrowly the rule is scoped — the more filters a rule carries, the higher its priority — and displays the resulting value read-only under Advanced in the rule form. When multiple rules match the same billing event, they are applied as a priority overlay:
  1. All matching rules are collected and sorted by priority (ascending)
  2. Rules are applied in order — each rule overrides only the account roles it explicitly defines
  3. For any given account role, the highest-priority rule that defines it wins
In practice this means a broad catch-all rule acts as your default, and narrower rules override it for the specific cases they name — you get that behaviour by scoping the rules, not by numbering them.

Example 💡

You have a default invoice posted rule with no filters, mapping all revenue to account 4000 – Revenue. You then add a second rule scoped to a specific product, mapping its revenue to 4100 – Usage Revenue. The second rule is narrower, so it gets the higher priority: when an invoice is issued for that product, Hyperline uses 4100 for that product’s line items and 4000 for everything else.

Overlapping rules

Specificity is scored against the line actually being posted, not against the rule in the abstract. A customer-scoped rule only outranks a product-scoped one when the line’s customer is one of those the rule names — if it isn’t, that rule doesn’t match at all.
When two rules end up equally specific for the same line, which one wins is not guaranteed. Distinguish overlapping rules by scoping them differently rather than relying on a tie-break.

Add a rule

Go to Accounting > Settings > Rules, open the tab for the event you want to cover, and click Add rule.
  1. Pick the Rule type. Note that Invoice posted appears as Invoice issued in this dropdown — same thing.
  2. Under Applied on, optionally add filters to scope the rule.
  3. Under Configuration, map an account to each role.
  4. Advanced shows the priority Hyperline derived from your filters. It is read-only.

Edit and delete rules

Click the edit or delete icon next to any rule in the rule list. Deleting a rule does not affect already-posted journal entries.