Add a past payout as a first-class action #3

Open
opened 2026-08-31 21:21:46 +00:00 by padreug · 0 comments
Owner

The gap

The original ask was "there's a payment I want to add that was from the past". Nothing in payroll does that directly:

  • pay-now settles the next unconsumed period early. It cannot reach a period already consumed, and it cannot record a payment that moved outside payroll at all.
  • backfill works, and is what actually served the need so far — but only for periods a contract has genuinely not paid yet, and only at contract-creation time.

So a one-off ("I paid Alice 200 EUR in cash on 12 June, record it") has no home, and correcting a period already settled has none either.

Proposal

An explicit Add past payout action on a contract:

  • pick a date
  • amount (defaulting to the contract's)
  • rate: looked up for that date, or stated outright
  • either move the money now (an ordinary internal transfer, back-dated in the ledger) or record only, for a payment that already happened off-platform

Record-only matters and is arguably the more common case: when the money already moved, the sat amount is a known fact and deriving it from a rate would be re-deriving something we hold. Take it as input.

Open question it forces: should this advance periods_done, or sit outside the schedule as an adjustment? Probably the latter — a correction is not a period.

While doing this, reconsider whether the pay-now dialog keeps its pricing selector. Pay-now nearly always faces a payday that is today or in the future (the scheduler settles due periods within 5 minutes), and for those only manual can change the outcome — payday and current are identical. If the real back-dating need moves here, pay-now could drop back to a simple confirm that just names the payday it is settling.

🤖 Generated with Claude Code

https://claude.ai/code/session_018jy52j9GRZ6XKa1Zt21LLj

## The gap The original ask was "there's a payment I want to add that was from the past". Nothing in payroll does that directly: - **pay-now** settles the *next unconsumed* period early. It cannot reach a period already consumed, and it cannot record a payment that moved outside payroll at all. - **backfill** works, and is what actually served the need so far — but only for periods a contract has genuinely not paid yet, and only at contract-creation time. So a one-off ("I paid Alice 200 EUR in cash on 12 June, record it") has no home, and correcting a period already settled has none either. ## Proposal An explicit **Add past payout** action on a contract: - pick a date - amount (defaulting to the contract's) - rate: looked up for that date, or stated outright - either **move the money now** (an ordinary internal transfer, back-dated in the ledger) or **record only**, for a payment that already happened off-platform Record-only matters and is arguably the more common case: when the money already moved, the sat amount is a known fact and deriving it from a rate would be re-deriving something we hold. Take it as input. Open question it forces: should this advance `periods_done`, or sit outside the schedule as an adjustment? Probably the latter — a correction is not a period. ## Related While doing this, reconsider whether the **pay-now dialog keeps its pricing selector**. Pay-now nearly always faces a payday that is today or in the future (the scheduler settles due periods within 5 minutes), and for those only `manual` can change the outcome — `payday` and `current` are identical. If the real back-dating need moves here, pay-now could drop back to a simple confirm that just names the payday it is settling. 🤖 Generated with [Claude Code](https://claude.com/claude-code) https://claude.ai/code/session_018jy52j9GRZ6XKa1Zt21LLj
Sign in to join this conversation.
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
aiolabs/payroll#3
No description provided.