Loan disbursements with optional two-phase hold.
Disbursements move funds from a loan into a bank account. The hold pattern lets you reserve funds and then clear or cancel later, identical to the book transfer hold pattern.
Immediate disbursement
{:ok, disb} = Column.Disbursements.create(%{
loan_id: "loan_123",
bank_account_id: "bacc_456",
amount: 500_000,
currency_code: "USD"
})Held disbursement
{:ok, disb} = Column.Disbursements.create(%{
loan_id: "loan_123",
bank_account_id: "bacc_456",
amount: 500_000,
currency_code: "USD",
hold: true
})
Column.Disbursements.clear(disb["id"])
Summary
Functions
Cancel a held disbursement.
Clear (execute) a held disbursement.
Create a loan disbursement.
Get a disbursement by ID.
List all disbursements.
Update a disbursement while it is on hold.
Types
@type id() :: String.t()
@type opts() :: keyword()
@type params() :: map()
@type result() :: {:ok, map()} | {:error, Column.Error.t()}
Functions
Cancel a held disbursement.
Clear (execute) a held disbursement.
Create a loan disbursement.
Get a disbursement by ID.
List all disbursements.
Update a disbursement while it is on hold.