Opens immutable metered renewal windows from canonical Braintree renewal evidence.
Summary
Functions
@spec author_local_invoice(Ecto.UUID.t()) :: {:ok, %{ invoice: Accrue.Billing.Invoice.t(), renewal: Accrue.Billing.MeteredRenewal.t() }} | {:error, term()}
@spec mark_invoice_authored( Accrue.Billing.MeteredRenewal.t(), Accrue.Billing.Invoice.t(), map() ) :: {:ok, Accrue.Billing.MeteredRenewal.t()} | {:error, term()}
@spec open_braintree_renewal_window( String.t(), DateTime.t() | nil, String.t() | nil, String.t() ) :: {:ok, Accrue.Billing.MeteredRenewal.t() | :ignored} | {:error, term()}
@spec process_metered_renewal(Ecto.UUID.t()) :: {:ok, %{ attempt: Accrue.Billing.MeteredChargeAttempt.t() | nil, renewal: Accrue.Billing.MeteredRenewal.t() }} | {:error, term()}
@spec settle_metered_renewal( Ecto.UUID.t(), keyword() ) :: {:ok, %{ attempt: Accrue.Billing.MeteredChargeAttempt.t(), renewal: Accrue.Billing.MeteredRenewal.t() }} | {:error, term()}