Nue Knowledge Center

Nue Docs navigation

search
clear
/

Collections Scenarios - Write Off

Collection Scenarios - Write off

This document outlines the various scenarios in which businesses may choose to write off the outstanding amount as bad debt when an invoice becomes uncollectible.

 

As a finance ops user, I can write off invoices for bad debts.

 

A credit memo is created to offset an invoice by writing off the remaining balance. The items on the credit memo are then applied to the corresponding items on the invoice. When an invoice is written off, the balance of each invoice item and invoice taxation item must be zero. Users are only allowed to write off the remaining balances of an invoice. If an invoice is fully paid, the write-off operation is not allowed.

 

When a finance ops user writes off an invoice, the following actions occur in an atomic operation: 

  • A credit memo with a “WriteOff” payment status is created and associated with the invoice. The transaction amount of the credit memo is equal to the remaining balance of the invoice.
  • A credit memo application for the write-off credit memo is created.
  • The balance of the invoice is zeroed out and its payment status is set to “Written Off”.
  • If there are debit memos applied to the invoice, the debit memos will be automatically written off once the invoice is written off.

The following business logic will be applied:

  • Only active invoices with remaining balances or associated debit memos with remaining balances can be written off.
  • The credit memo used for writing off an invoice can be canceled only along with the cancellation of the invoice.
  • Canceling the write-off invoice will automatically cancel the associated write-off credit memos.

Case 1 Write off an open invoice

 
Invoice INV-001 has a total amount of $100 with all positive items.  A user now writes off the invoice. 

 

The following shows the details of the Credit Memo Application: 

PAYMENT APPLICATION ITEM

INVOICE ID

RECORD TYPE

AMOUNT

PAYMENT TYPE

OPERATION

PAYMENT ID

Credit Memo Application: CMA-001

Invoice INV-001

Credit Memo

$100

Credit Memo

WriteOff

CMA-001

After the credit memo application is created, both the invoice and the credit memo have the balance set to $0.  The payment status of the invoice is set to ”Written Off”.

 

INVOICE ITEM (INV-001)

AMOUNT

BALANCE BEFORE WRITE-OFF

BALANCE AFTER WRITE-OFF

II-001

$20

$20

$0

II-002

$30

$30

$0

II-003

$50

$50

$0

 

CREDIT MEMO ITEM (CMA-001)

AMOUNT

BALANCE

CMI-001

$20

$0

CMI-002

$30

$0

CMI-003

$50

$0

 

Invoice INV-002 has a total amount of $100 with negative items.  A user now writes off the invoice. 

 

The following shows the details of the Credit Memo Application: 

PAYMENT APPLICATION ITEM

INVOICE ID

RECORD TYPE

AMOUNT

PAYMENT TYPE

OPERATION

PAYMENT ID

Credit Memo Application: CMA-002

Invoice INV-002

Credit Memo

$100

Credit Memo

WriteOff

CMA-002

After the credit memo application is created, both the invoice and the credit memo have the balance set to $0.  The payment status of the invoice is set to ”Written Off”.

 

INVOICE ITEM (INV-002)

AMOUNT

BALANCE BEFORE WRITE-OFF

BALANCE AFTER WRITE-OFF

II-001

$90

$90

$0

II-002

$20

$20

$0

II-003

-$10

-$10

$0

 

CREDIT MEMO ITEM (CMA-002)

AMOUNT

BALANCE

CMI-001

$90

$0

CMI-002

$20

$0

CMI-003

-$10

$0

 


Case 2 Write off a partially paid invoice

 

Invoice INV-003 has a total amount of $100 with all positive items and received Payment #1 of $30.  A user now writes off the invoice. 

 

The following shows the details of the Credit Memo Application: 

PAYMENT APPLICATION ITEM

INVOICE ID

RECORD TYPE

AMOUNT

PAYMENT TYPE

OPERATION

PAYMENT ID

Credit Memo Application: CMA-003

Invoice INV-003

Credit Memo

$70

Credit Memo

WriteOff

CMA-003

After the credit memo application is created, both the invoice and the credit memo have the balance set to $0.  The payment status of the invoice is set to ”Written Off”.

 

INVOICE ITEM (INV-003)

AMOUNT

BALANCE BEFORE WRITE-OFF

BALANCE AFTER WRITE-OFF

II-001

$20

$0

$0

II-002

$30

$20

$0

II-003

$50

$50

$0

 

CREDIT MEMO ITEM (CMA-003)

AMOUNT

BALANCE

CMI-001

$20

$0

CMI-002

$50

$0

 

In this case, the payment can be refunded, the balance of the invoice will not change, and its payment status is “Written Off”

 

 

Invoice INV-004 has a total amount of $100 with negative items and applied Credit Memo #CM_001 of $40.  A user now writes off the invoice. 

 

The following shows the details of the Credit Memo Application: 

PAYMENT APPLICATION ITEM

INVOICE ID

RECORD TYPE

AMOUNT

PAYMENT TYPE

OPERATION

PAYMENT ID

Credit Memo Application: CMA-004

Invoice INV-004

Credit Memo

$60

Credit Memo

WriteOff

CMA-004

After the credit memo application is created, both the invoice and the credit memo have the balance set to $0.  The payment status of the invoice is set to ”Written Off”.

 

INVOICE ITEM (INV-004)

AMOUNT

BALANCE BEFORE WRITE-OFF

BALANCE AFTER WRITE-OFF

II-001

-$10

$0

$0

II-002

$20

$0

$0

II-003

$90

$60

$0

 

CREDIT MEMO ITEM (CMA-004)

AMOUNT

BALANCE

CMI-001

$60

$0

 

In this case, the credit memo can be unapplied from the invoice. When fully unapply Credit Memo #CM_001, the invoice balance will change to $40, and the payment status of the invoice change to “Partially Written Off”

 

 

Case 3 Write off the invoice-associated debit memos

 

When a finance operations user writes off invoice-associated debit memos, the following actions occur in an atomic operation:

1. Create a credit memo with a "WriteOff" payment status associated with the debit memo. The transaction amount of the credit memo is equal to the remaining balance of the debit memo.

2. Create a credit memo application for the write-off credit memo.

3. Zero out the balance of the debit memo and set its payment status to "Written Off."

 

As a finance ops user, I can reverse a written-off invoice


When the finance ops user cancels the invoice, the associated credit memos are automatically canceled. The following actions will take place:
1. If the invoice has been partially paid before, we will automatically refund the invoice and then cancel the associated credit memos.

2. If the invoice has been applied to credit memos, we will automatically unapply the credit memos and then write off the remaining balance to ensure the invoice balance is 0 and the payment status is "Written Off."

3. If the invoice status is "Partially Written Off," we will automatically write off the remaining balance and then process the cancellation.

 

 

 

Implementation Guide

 

  • API Doc
  • Webhook: When an invoice is written-off, an invoice.writeoff Webhook event is raised with the payload containing the invoice and invoice items.
  • Error Handling: When the invoice is not 'Active' or the balance is not 0, write off the invoice is NOT allowed