Measure recurring inflows from bank credits
well_measure_recurring_inflowsMeasure who pays the workspace on a regular cadence, from its bank and credit card inflows: each recurring payer, its cadence, what it brings in per month, and the total per currency. It draws no card.
Call it when a cash forecast should count the inflows that keep arriving, or when the user asks which customers pay them regularly. For a forecast, pass the forecast_inflows entry of the forecast's currency to well_render_cash_forecast as recurring_inflow, as it is. When forecast_inflows holds no entry in that currency, no recurring inflow was found: draw the worst case with no recurring_inflow and say so.
The server applies every rule, and the result states each one in rules. Quote the figures as returned: never recompute an amount, a total or a cadence, never add a payer the person expects, and never add a one-off payment, an invoice not yet paid or a deal to the figure.
Every amount in the result is in the major units of its currency, never in cents: 1860 is 1,860.00 EUR, not 18.60 EUR.
The window is fixed: the last 24 complete calendar months in UTC and the running month. measured_through is the last complete month.
What the result is:
recurring_inflows: the payers on a cadence (monthly, bimonthly, quarterly, yearly), largest amount per month first, at most 50;recurring_inflow_countis the full count. Each carries its cadence evidence, its amount pattern (fixed, changed, varying), the amount per month, its latest month,possibly_endedand its category.totals: per currency, the payer count, the amount per month of every recurring payer (a quarterly or yearly payment spread over its months), the part from payers flagged as possibly ended, andforecast_floor_per_month, the inflow that arrives in every month.forecast_inflows: per currency with a positiveforecast_floor_per_month, the{ amount, currency, measured_through }the cash forecast takes. It is a floor that holds month by month, so it counts only payers on a MONTHLY cadence that may not have stopped and that paid in every month of their span: every payer counts at its smallest month (the smallest amount it paid in a month of the window), never the mean. Payers on a bimonthly, quarterly or yearly cadence, and monthly payers that skipped a month (a gap of 2 in their evidence), are intotalsand NOT inforecast_inflows, because they pay in some months only. A payer whose latest payment is neither in the last complete month nor in the running month is not in it either. Payers that may have stopped, payments on no cadence, possible duplicates and unattributed inflows are not in it either. Say that these were left out.not_recurring_count,possible_duplicate_countandunattributed: what was paid in but is in no total.excluded: what fell out, counted apart.internal_transfersare movements between the workspace's own accounts.payments_from_own_accountsare drawdowns from an owned loan,own_companymoney in from the workspace's own company,category_excludedthe inflows whose category is a transfer, treasury, financing or tax key (category_keys),unreadable_rowsrows with no readable amount or currency,no_asset_movementrows with no leg on an owned bank account or credit card. Anullcount was not measured, which is not zero.
partial: true means nothing was measured: the read was cut short, or the workspace holds no bank account and no credit card. forecast_inflows is then empty: say so rather than reporting no recurring inflow. rows_truncated: true means the smallest counterparties were not read, so every total is a floor.
scope is required: own_and_adopted is the population the burn counts, own the workspace's own rows only. Use the scope the forecast's burn used.
When the token authorizes one workspace, call this directly — no workspace call is needed first. When it authorizes several, this read will not guess which one you mean: pass workspace_id on the call.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| scope | Yes | Which rows are this workspace's: `own_and_adopted` for the population the burn counts, `own` for its own rows only. Required; see the description. | |
| workspace_id | No | Target workspace. Omit when the token authorizes one workspace. Required when it authorizes several: this read reports one workspace's own figures and will not choose which. | |
| conversation_id | No | The conversation id returned by the previous Well result, in its meta under well/conversation_id, in its structuredContent, or in its JSON text block. Pass it back on every call in the same conversation, including a call a card makes, so the chosen workspace and the earlier answers still apply. It decides the conversation on its own: nothing the host states about the session replaces it. Omit it only on the first call of a conversation. | |
| workspace_scope | No | Restrict this call to the family: the token's primary workspace plus the company workspaces under it that you are a member of. Unrelated authorized workspaces drop out of the read; row reads merge across the family, while a per-workspace figure still reports exactly one workspace. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| error | No | ||
| rules | Yes | ||
| scope | Yes | ||
| totals | Yes | ||
| window | Yes | ||
| partial | Yes | ||
| success | Yes | ||
| excluded | Yes | ||
| unattributed | Yes | ||
| current_month | Yes | ||
| rows_truncated | Yes | ||
| conversation_id | No | The conversation this result belongs to. Pass it back as the conversation_id argument on every later Well call in the same conversation. | |
| newly_connected | No | Tools that connected to this workspace since the last result and that no session was told about yet, oldest first. Present only when at least one tool is new. The connected-line rule says when to tell an entry; when it does, one line per entry, in the person's language: "<name> is connected.". Never fold several entries into one sentence. Each entry comes back once, on one result only: never repeat its line later. | |
| forecast_inflows | Yes | ||
| measured_through | Yes | ||
| recurring_inflows | Yes | ||
| resolved_workspace | No | The workspace that answered, when the caller named none and the token authorizes several. | |
| not_recurring_count | Yes | ||
| conversation_id_note | No | Present only when the server opened a fresh lane, stating that no choice recorded earlier was read. | |
| conversation_id_source | No | Where the conversation id came from: the host's own request meta, the caller's argument, or a fresh lane the server opened. | |
| recurring_inflow_count | Yes | ||
| possible_duplicate_count | Yes | ||
| recurring_inflows_truncated | Yes |