• 10 Jan 2024
  • 3 Minutes to read
  • Dark


  • Dark

Article Summary

There are two core objects: Invoice and Line Item. Line Items work as a related object to the Invoice.

You can send invoices to your customers for payment over the web using DocumentLink.
H_01_11 Invoice DocumentLink

Before Creating an Invoice

Before creating an Invoice, you should create a Company Info record with your logo and company information and complete the Payments Setup Wizard.

  1. Complete the Payments Setup Wizard
  2. Create a Company Info record. (The address, name, and logo that you enter here are rendered on the Invoice.)
  3. Create a DocumentLink Template record. Set lookups to the Payment Gateway and Company Info. When you create your Invoice, set the lookup to the DocumentLink template to default your Invoice's configuration and merge fields.
  4. Authorize DocumentLink.
Is the date format on your Invoice incorrect?

Check your browser's location setting. All date fields on an Invoice will reflect the appropriate date format based on your browser's location setting.

Create an Invoice

  1. In the app launcher field, search for and click "Invoice" (the Blackthorn Custom Object, not the SF Standard Object).

  2. Click New in the top-right corner.

  3. Select either the "Stripe Invoice" or "Invoice" record type.

  4. Set the values for:

    • Name
      The Name field is automatically generated with an "INV" prefix and an ordered numeric string. For example, your first Invoice will be named "INV-1". This can be edited for any custom needs. This value will be rendered beneath the word "Invoice" on the DocumentLink document. This value is also written to the Description field of the related Transaction record(s).
    • Subject
    • PO Number
    • Payment Term
    • Due Date
    • Payment Gateway
      Defining the Payment Gateway tells the system which Stripe account the money should go to.
    • Enabled Payment Methods 
      Define how you would like to be paid for the Invoice - Card, ACH or both. Keep in mind that ACH transactions have a $5.00 capped fee which is an inexpensive fee compared to cards which have a percentage based fee.
    • Company Info
    • Discount Code
      If a discount Code has been created, define the record here.
    • Contact (Bill To)  The Email and Phone fields will automatically pull in the related Contact's email and phone values.
    • Account (Bill To)
      The address fields will automatically pull in the related Account's billing address.
    • Account (Ship To) 
      The address fields will automatically pull in the related Account's shipping address.
    • DocumentLink Template 
      The DocumentLink fields will automatically pull in the related DocumentLink Template fields.
    • Tax Amount 
      The Tax Amount field can be manually defined to calculate the percentage of taxes you want added to a Transaction.
    • Write Off Amount
      If write-off Transactions are related, the Write Off Amount field is automatically populated. If there are no write-off Transactions present, then the field will be blank.
  5. The Currency ISOStatus and Payment Status fields are automatically defined with default values.

    • Currency ISO = "USD"
    • Status = "Draft"
    • Payment Status = "Unpaid" (only on Invoices)
  6. The DocumentLink field is automatically generated with a random alphanumeric link. This link is used to render the Invoice online.

  7. Click Save.
    H_01_11 Create an Invoice 1

  8. Click the DocumentLink link.
    H_01_11 Create an Invoice 2

Once your Invoice is completed, you are ready to view the Invoice through the web-based and mobile responsive DocumentLink.

H_01_11 Create an Invoice 3

Additional Field Worth Noting

Allocation Rollup: Sum of all Allocations for this Invoice.

Auto-convert Opportunities to Invoices

You can convert an existing Opportunity object to an Invoice. The Opportunity Line Items will be converted to Line Items in the Invoice. The newly created Invoice will be linked to the originating Opportunity using the Opportunity lookup field.

We have a lookup field Line Item on the Opportunity Product. This will facilitate mapping the Invoice Line Item directly with the Opportunity Product Line Item. So when an Invoice is created from Opportunities using the Create Invoice button, you can self map additional Opportunity Line Item fields (Example - custom tax field) to the Invoice using a process builder.

Add the Create Invoice button

Manually add the Create Invoice button to your Opportunity layout.

Receive a notification when the status changes

Create a process builder that notifies the record owner when the Invoice's Status updates to accepted or rejected.

Invoice Payment

Once the Transaction related to the Invoice has been captured (manually or with DocumentLink) and if the Invoice Balance Due = "0", then the related Invoice Payment Status = "Paid", the Status = "Completed", and Paid In Full = the current date/time.

H_01_11 invoice payment


Sometimes you will need to refund an Invoice. A refund can be either a full or partial refund. Refunding part or all of an Invoice won’t trigger a change to the original Invoice. The Invoice’s Payment Status will show "Paid", the Balance Paid will show the amount of the original Transaction, and the Balance Due will be "0.00". A new Transaction will be created with the Amount equal to the refund amount, showing that part or all of the original Transaction was refunded.

H_01_11 refunds 1

H_01_11 refunds 2

What's Next