Browse the docs

Agent setup guide

Invoice Ninja Client Statements

On the 1st of each month, every Invoice Ninja client with a balance gets a statement of the last 30 days, emailed by Invoice Ninja after you approve the list.

Available About 6 min to set up

What it does

On the 1st of each month, every Invoice Ninja client with a balance gets a statement of the last 30 days, emailed by Invoice Ninja after you approve the list.

  • On the 1st of each month, lists your Invoice Ninja clients with a balance.
  • AI briefs you on the list in words; it waits for your approval.
  • Invoice Ninja emails each client a statement of the last 30 days with payments and aging.
  • Which clients were sent one is counted in code.

What it needs

  • A paid plan (agents run live on paid plans).
  • An AI provider key (Settings → AI Providers).
  • Invoice Ninja (hosted Pro or Enterprise, or self-hosted), connected in Settings → Integrations.

What it doesn't do

  • It never changes invoices or balances.
  • Up to 100 clients per month.
  • It doesn't write a cover note: Invoice Ninja's statement email is used.

Availability and plans

Available

Its workflow is built and tested, and every app it needs is live. You can get it and set it up now.

Included free on the Enterprise plan; on other paid plans it's a one-time purchase per workspace (the price is on the Agents page). The Agents page in the app always shows its current status.

Before you start

  • A paid plan: agents run live, and the Free plan only runs Dry Runs.
  • An AI provider key (OpenAI, Anthropic, Google and more) in Settings → AI Providers. AI usage is billed by your provider.
  • These apps, connected in Settings → Integrations: Invoice Ninja.
  • Nothing to send: the agent runs on a schedule.
  • About 6 minutes.

Set it up step by step

Get the agent first (buy it, or it's already yours when your plan includes it), then in Agents → My agents press “Set up this agent”. That creates the agent's workflow in your workspace (it counts towards your plan's workflow limit) and opens the canvas with a setup checklist above it. Each item links to the exact place to go and ticks itself off when it's done.

1. Connect your AI provider

The AI steps run on your own key (OpenAI, Anthropic, Google and more). Add one in Settings → AI Providers.

2. Connect Invoice Ninja

Connect Invoice Ninja with an API token (Settings → Account Management → API Tokens in Invoice Ninja; hosted Pro or Enterprise, or self-hosted).

3. Pick the Invoice Ninja account

Open “Clients with a balance” and “Email the statement” and pick your Invoice Ninja connection.

SettingWhat to enterIn step
Invoice Ninja accountYour Invoice Ninja connection. Pick your connected Invoice Ninja account.“Clients with a balance”
Invoice Ninja account (statements)The same Invoice Ninja connection, to email the statements. Pick your connected Invoice Ninja account.“Email the statement”

4. Test it with Dry Run

Press Dry Run: the agent runs on sample data with no messages sent and nothing written to your apps.

5. Switch the trigger on

Open the trigger, set your time zone and switch the schedule on. It runs on the 1st of each month at 9:00.

How it works

The agent is a normal workflow with 10 steps (1 AI step, with a person approving in Reviews). You can open, edit and monitor it like any other workflow.

  • 1st of the month at 9:00 — Runs on a schedule (cron 0 9 1 * *, UTC — change it in the trigger's settings). Runs on the first morning of each month. Set your time zone on the trigger.
  • Clients with a balance — Invoice Ninja: List clients with a balance. Lists the Invoice Ninja clients who owe you money, largest balance first (up to 100).
  • Anyone owing? — Decision: picks the branch to follow. No client has a balance: nothing is sent.
  • No balances — Kept in the run history. Branch: None. No client owes you money right now.
  • Brief you on the list — AI step (runs on your AI provider key). Branch: Owing. AI writes a short note on the list for your review (who stands out and why), without typing numbers.
  • Approve the statements — A person approves or rejects it in Reviews (the run waits). The list of clients and the brief wait in Reviews: approve to have Invoice Ninja email each one a statement, or reject.
  • Each client — Repeats the steps below for each item (up to 100 per run). Branch: Approved. Emails one statement per client (up to 100).
  • [For each item — “Each client”] Email the statement — Invoice Ninja: Email a client statement (customer-facing). Invoice Ninja emails the client a statement of the last 30 days with payments and aging.
  • Count what was sent — Step. In code: which clients were sent a statement.
  • Statements sent — Kept in the run history. The run history keeps the list of clients.

Test it with Dry Run

Press Dry Run in the canvas. The agent runs on the sample data stored on its trigger (the “Sample data for Dry Run” box), so you can check every step's output before anything is live.

  • Nothing is sent or written: app actions, emails and Slack posts are simulated, and AI steps don't call your AI provider.
  • Approval steps use the Dry Run decision you pick in the step's settings (approved, rejected or timeout), so you can try each branch.
  • For-each loops repeat only the first 3 items.

Go live

  • Open the trigger, set your time zone and switch the schedule on. It runs on the 1st of each month at 9:00.
  • Scheduled runs start only once the schedule is activated, and can't repeat faster than your plan's minimum interval.
  • The setup checklist adds a “paid plan” item before activation: live runs need a paid plan (the Free plan only runs Dry Runs).
  • When every checklist item is done and the trigger is on, the checklist says “Live — this agent is running”. Follow its runs in the workflow's History tab and in Analytics → Agents.

Questions

Who sends the email?

Invoice Ninja does, to the client's contacts, with your Invoice Ninja email settings and branding.

Can a statement go out without me?

No. Each month the list of clients waits for your approval first.

Does the AI write to my clients?

No. The AI only briefs you on the list; the statements are Invoice Ninja's own.

Troubleshooting

  • “No AI provider connected” or a rejected key: connect or fix the key in Settings → AI Providers, then press Test there.
  • A checklist item stays unticked: the setting is still empty or still contains its placeholder text. Open the step from the checklist and fill it in.
  • An app step fails with “Needs reconnect”: the account's access was revoked or expired. Reconnect it in Settings → Integrations.
  • It didn't run at the expected time: the schedule must be activated, and its time is in the trigger's timezone.
  • A run shows as paused: it's waiting for someone in Reviews to approve or reject it.
  • A step failed: open the run in History and check that step in the Trace tab for the error and what it received.

Generated from the agent's own workflow, so it always matches what the agent does. Last updated .