Connectors

/

Salesforce

/

Reconcile Salesforce account billing
Report

Explain a customer's Salesforce balance with every document tied out

For finance teams answering a customer balance question who want invoices, payments, credits and refunds tied out, by asking their AI assistant.

Try PopdockAI free
Get a live demo
Reconcile Salesforce account billing
Reconcile the billing for Contoso Ltd in Salesforce over the last year.
Contoso Ltd shows a 6,200 USD open balance, but 4,500 USD of it is offset by unapplied cash and credit. - Invoiced: 148,000 USD, paid 139,300 USD - Unapplied payment: 3,000 USD on PAY-1042 - Unapplied credit: 1,500 USD on a credit memo - Flag: an overdue invoice on an account with auto-pay on Want the table of every flagged document?
Salesforce
Sample figures. Your results come from your own account.
salesforce-get-account
salesforce-get-invoice
salesforce-get-payment
salesforce-get-credit-memo
salesforce-get-refund
salesforce-get-payment-method

On this page

The problem

The problem

The prompt

Who it's for

How it works

Tools used

Connector

Salesforce

Salesforce
Run it on your own Salesforce data.

Connect Salesforce, pick your AI tool and paste the prompt.

Try PopdockAI free

The problem

A disputed balance means hours of tying out documents

When a customer questions their balance, the invoices, payments, credit memos and refunds in Salesforce have to be tied out by hand. Unapplied amounts, oversized refunds and overdue invoices on auto-pay accounts hide in long lists.

Without PopdockAI

  • Export invoices, payments, credits and refunds separately
  • Total each in a spreadsheet
  • Hunt for unapplied payments and credits
  • Miss the overdue invoice on an auto-pay account

With PopdockAI

  • Every billing document for the period is gathered for you
  • Invoiced, paid, credited and refunded amounts are totalled
  • Unapplied amounts and other mismatches are flagged
  • Read only, with amounts used exactly as returned

The prompt

Use this prompt

Copy it into any AI tool connected to PopdockAI. Swap the values in braces for your own.

Prompt
**Objective:** Reconcile billing for account `{account-name}` over the last `{lookback-days}` days (default 365).

**Step 1: Resolve the account**

Call `salesforce-get-account` with `name` set to `{account-name}`. If nothing matches, retry with `name.contains`. If more than one account matches, list them (name, billing city, owner, account ID) and stop. Use the returned account-id for every later call.

**Step 2: Gather, by account-id, dated within the window**

* `salesforce-get-invoice` with `invoice-date.from`.
* `salesforce-get-payment` with `date.from`.
* `salesforce-get-credit-memo` with `credit-date.from`.
* `salesforce-get-refund` with `date.from`.
* `salesforce-get-payment-method`: the payment methods on file and whether auto-pay is on.

**Step 3: Tie out**

* Invoiced total, paid total, credited total, refunded total.
* Open invoice balance against the sum of unapplied payments and unapplied credits.
* Flags: payments with unapplied amounts, credit memos with unapplied balance, refunds larger than the matching payment, overdue invoices on an account with auto-pay on, no active payment method.

**Step 4: Report**

A totals table, then a table of every flagged document (type, number, date, amount, balance, flag), then a one-paragraph conclusion.

**Rules & Guidelines:**

* This prompt is read-only. Do not call any write tool: `salesforce-add-account`, `salesforce-add-contact`, `salesforce-add-lead`, `salesforce-add-opportunity`, `salesforce-add-case`, `salesforce-add-task`, `salesforce-add-asset`, `salesforce-add-campaign`, `salesforce-update-account`, `salesforce-update-contact`, `salesforce-update-lead`, `salesforce-update-opportunity`, `salesforce-update-case`, `salesforce-update-task` or `salesforce-update-asset`.
* Use the amounts as returned; do not recompute tax.

**Validation:**

* If no billing documents exist in the window, say so and stop.

Who it's for

One answer, three teams that use it

Accounts receivable

Answer balance questions with confidence

Tie out a customer's invoices, payments and credits in one pass when they question what they owe.

Why does Fabrikam's balance in Salesforce look wrong? Reconcile their billing for the last 6 months.

Billing specialists

Find unapplied payments and credits

See payments and credits that were never applied, and refunds bigger than the payment behind them.

Reconcile Northwind Traders billing in Salesforce since January and list anything unapplied.

Account managers

Prepare for a billing conversation

Know exactly where the customer's balance comes from before you get on the phone.

Give me a billing tie out for Contoso Ltd over the last 90 days, including payment methods on file.

How it works

What PopdockAI does when you ask

You name the account and a period, and your AI assistant ties out its billing documents in Salesforce. It reports the mismatches and changes nothing.

01

Ask

You name the account, and optionally a lookback window.

Your AI tool

02

Gather

It reads invoices, payments, credit memos, refunds and payment methods for the period.

salesforce-get-account
salesforce-get-invoice
salesforce-get-payment
salesforce-get-credit-memo
salesforce-get-refund
salesforce-get-payment-method

03

Tie out

It totals each and sets the open balance against unapplied payments and credits.

No items found.

04

Report

You get totals, flagged documents and a conclusion, with nothing changed.

Your AI tool

What PopdockAI provides

The tools behind the answer

Ready made tools for Salesforce and one secure connection to your AI tool. No code, no exports.

get-data

salesforce-get-account

Returns Salesforce accounts with their type, industry, owner, billing address, phone and annual revenue. Filter by name, account number, type, industry, owner, billing city or state, annual revenue and created date.
get-data

salesforce-get-invoice

Returns Salesforce billing invoices with their account, invoice and due dates, totals, tax, payments applied and balance. Filter by invoice or document number, account, status, invoice date, due date, total and balance.
get-data

salesforce-get-payment

Returns Salesforce billing payments with their account, amount, type, status, payment method and applied and unapplied amounts. Filter by payment number, gateway reference, account, type, status, date and amount.
get-data

salesforce-get-credit-memo

Returns Salesforce billing credit memos with their account, status, totals, tax and applied, unapplied and remaining balance. Filter by credit memo or document number, account, status, credit date, total and balance.
get-data

salesforce-get-refund

Returns Salesforce billing refunds with their account, amount, type, status, payment method and applied and unapplied amounts. Filter by refund number, account, type, status, date and amount.
get-data

salesforce-get-payment-method

Returns the payment methods saved on Salesforce accounts, with type, status and whether they auto-pay. Filter by account, type, status and auto-pay flag.
Read only.Nothing in Salesforce Changes

This report is built from Get data tools only. PopdockAI applies the row, field and parameter rules your admin sets, and every query is written to the audit trail.

How Popdock AI secures your data

The outcome

Explain any balance with every document accounted for

Try PopdockAI free
Get a live demo

Related use cases

More ways to put this data to work

All Ramp use cases

One prompt template with infinite possibilities.

‍

Your AI assistant adapts its approach, tone, and capabilities to match each unique context while you maintain a single, manageable workflow.

Join forward-thinking companies that are transforming their operations with intelligent, secure AI automation.

Try PopdockAI Free
See Documentation