ledgersync_accept_transactions
ChatGPTAccepts the For review transactions ledgersync_preview_accept_transactions checked, for every client of that preview: they move to Categorized (an exclusion rule's to Excluded), as the LedgerSync app's Accept does. Only call it after the user saw that preview and said yes. Pass the preview's confirmation_id with the same client_ids and client_names you passed to that preview: LedgerSync refuses the call when they are not the preview's clients. LedgerSync checks each transaction again: one no longer in For review or no longer matching is left as it is (changed), and one missing a payee, category or bank account mapping is refused. It answers, client by client, what moved, what was refused and what changed: report all of it to the user, with what the preview left in For review. Calling it again with the same confirmation_id never accepts twice. It posts nothing to QuickBooks. ledgersync_undo_accept_transactions moves them back.
ledgersync_apply_ledger_changes
ChatGPTMakes the changes ledgersync_preview_ledger_changes checked, in the client's QuickBooks: each vendor's 1099 flag is set, and nothing else on the vendor changes. A vendor changed in QuickBooks since the preview is left as it is, with its reason. Only call it after the user saw that preview and said yes. Its only argument is the preview's confirmation_id. LedgerSync makes the changes in the background: follow it with ledgersync_get_ledger_changes_status. Calling it again with the same confirmation_id never applies twice. ledgersync_undo_ledger_changes puts the flags back.
ledgersync_apply_rules_setup
ChatGPTSaves what ledgersync_preview_rules_setup checked: the new rules, categories, category links and vendors, marked LS-AI in LedgerSync for review, and the changes to existing rules it showed, then fills the waiting transactions they match (a global rule also at the firm's other clients); an exclusion rule marks them for exclusion instead, and they move to Excluded when the user accepts them. The transactions a change puts back are filed again by each client's other rules, and a changed rule keeps its type. For a QuickBooks client it also creates the new client categories and vendors in the client's QuickBooks, where they stay. It moves no money and changes no rule the preview did not show; if one of those rules changed since the preview, nothing is applied and you preview again. Only call it after the user saw that preview and said yes. Its only argument is the preview's confirmation_id. LedgerSync applies it in the background: follow it with ledgersync_get_rules_setup_status. Calling it again with the same confirmation_id never applies twice. It also applies a confirmation_id of ledgersync_preview_category_links, after the user's yes: the firm category is linked client by client at the clients that preview proposed, each link marked LS-AI, as one setup whose setup_id starts with rsl_.
ledgersync_compare_statement_to_books
ChatGPTCompares one LedgerSync bank or card statement with the client's QuickBooks Online register for the account it belongs to, for the statement's period, to explain why it does not reconcile (the explain_rec_difference playbook). It returns the statement's opening and closing balances, the QuickBooks balance on the statement's last day, the difference, and the difference split into parts that always add up to it: what started before this statement, rows on the statement the books lack, entries in the books the bank has not shown, and entries the books date after the statement's end. It lists the rows on each side that nothing matched, and likely_causes, when LedgerSync can tell them, strongest first with their evidence. Give account_id, and statement_id for a statement other than the account's newest (both from ledgersync_list_accounts and ledgersync_list_statements, or the client snapshot); for a month, use the statement whose statement_date falls in it. When the account has no QuickBooks account to compare with it answers status needs_quickbooks_account with the client's bank and card accounts: ask the user which one, then call again with its id as qbo_bank_account_id. Explain the difference in plain words, causes first, then list the fixes for the user to make in QuickBooks: it only reads, and it does not mark entries cleared or reconciled in QuickBooks. It compares statements LedgerSync reads from the bank, not uploaded PDFs, loans or mortgages. A large account's first call can answer status running: call it again with the same arguments in about 30 seconds.
ledgersync_create_client
ChatGPTAdds a new client (a business or person whose bank accounts the firm will connect) and returns its client id. Search with ledgersync_find_clients first; if a client with the same name or email exists, this returns it instead of creating a duplicate.
ledgersync_create_connect_link
ChatGPTReturns a secure LedgerSync link for the client's account holder to connect a new bank account. On LedgerSync's page they pick their bank and what to connect (transactions, statements, check images), then sign in on the secure page that opens (LedgerSync's own, or its bank-data partner's for some banks). Set for_check_images to true when the client needs the bank's check images: they come pre-selected on the page. Never ask anyone for bank usernames, passwords or codes in this chat.
ledgersync_create_statement_upload_link
ChatGPTReturns a secure LedgerSync page where the user uploads one bank statement PDF (up to 30 MB). LedgerSync reads it and turns it into a list of transactions, and a CSV, Excel or QuickBooks file; nothing is saved to a client. Use it whenever the user wants a statement PDF converted: you cannot send LedgerSync the file yourself, even one attached to this chat. Each link takes one PDF and works for 24 hours. The conversion also shows on the user's PDF Converter page in the LedgerSync app.
ledgersync_drill_account
ChatGPTBreaks one account of a QuickBooks Online client down by the payees on its entries (vendors, customers and anyone else QuickBooks names), straight from QuickBooks: each payee's amount and entries in the period, and with compare_from and compare_to the change, which payees are new and which stopped. It lists a period's activity, never a balance. To explain a line of ledgersync_get_financials, pass the line's account_id with the same from, to, compare_from, compare_to and basis as the report (a balance sheet's change: from the day after compare_as_of to as_of, and no compare dates). account_id can also be a category from ledgersync_list_quickbooks_categories or a review report, or a bank account from ledgersync_get_quickbooks_setup. The period is from and to (default: last month), at most 366 days each. basis is accrual or cash (default: the client's QuickBooks report setting): pass the report's, so the two agree. include_sub_accounts adds the entries of the account's sub-accounts. limit is how many payees are listed one by one (default 15, at most 50); the rest are summed in others. It only reads; you can turn the answer into a dashboard.
ledgersync_find_clients
ChatGPTFinds the clients you can see in LedgerSync (the businesses or people whose banks LedgerSync connects) by name or email, and returns their client ids. Call it first whenever the user names a client: every other client tool needs the id. Banks connected on the firm's own LedgerSync login, not for a client, come back as one entry marked firm_own (the firm's own accounts); its id works with every client tool.
ledgersync_get_1099_summary
ChatGPTLists the vendors a QuickBooks client paid at or over the 1099-NEC threshold in a tax year (LedgerSync's defaults: 600.00 for 2025 and 2,000.00 for 2026; for another year pass threshold), each with its QuickBooks 1099 flag, whether a tax ID and an email are on file, and a suggested next step with its evidence. Payments by card or through a payment app (PayPal, Venmo, Square, Stripe, Cash App) are left out by default: the card company or the app reports them on a 1099-K. It never shows a tax ID. A large client's first call can answer status running: call it again with the same arguments in about 30 seconds.
ledgersync_get_account_status
ChatGPTShows which LedgerSync firm and login this connection is signed in to, whether it is ready to use, which environment it is on (sandbox or live), whether it can make changes or only read, and how many bank refreshes are left today. Call it when starting work with LedgerSync, and whenever another LedgerSync tool reports an access problem: it says what to do next.
ledgersync_get_categorized_export_link
ChatGPTReturns a link to a file of the categorized transactions not exported yet (the LedgerSync app's Categorized tab, Not Synced) for every Manual client this login manages, or for one client, and how many are ready. format: default_csv (the app's Default export) or acs_xlsx (Accounting CS Excel). Manual clients only: clients connected to QuickBooks or another accounting platform are left out. Calling it changes nothing: the transactions are marked Synced only when a person presses Download on the link's page, which works for 24 hours. Use it when the user asks for these transactions as a file, or in a scheduled task.
ledgersync_get_check_images_download_link
ChatGPTReturns a link that downloads a client's check images as files: one check as its image, several as a ZIP with each image named by file_name_pattern and a CSV of each check's details. Pick the checks with account_id, from and to (the days they cleared), or with check_ids from ledgersync_list_check_images; with none of these, every check image of the client. Build file_name_pattern from the user's own naming convention with the placeholders {date}, {year}, {month}, {day}, {check_number}, {payee}, {amount}, {memo}, {account}, {bank}, {check_date}; the default is {date}_{check_number}_{payee}_{amount}. Each link works once and expires after 10 minutes, so give it to the user right away. More than 200 checks come as several links.
ledgersync_get_client
ChatGPTReturns a client's details as LedgerSync keeps them: its name, its main email (and whether the client signs in to LedgerSync with it), its main phone number, which LedgerSync texts, and its extra emails and phone numbers. LedgerSync emails every address listed. Change them with ledgersync_update_client.
ledgersync_get_client_snapshot
ChatGPTStarts work on one client in a single call: the accounting ledger the client is connected to in LedgerSync, whether its QuickBooks connection works, its QuickBooks closing date (entries dated on or before it are locked), the first of its bank and card accounts with each one's latest statement date, and the playbooks that fit it. quickbooks.closing_date is a date, none_set when QuickBooks has none, or unavailable when QuickBooks did not answer this time (call again; it never means none is set). Once a review report ran on last month today, reviews counts what each report flagged. Call it once when the user starts working on a client.
ledgersync_get_connection
ChatGPTShows one bank connection's current status, when it last refreshed, its last error, and what to do next if it is not working.
ledgersync_get_conversion_download_link
ChatGPTReturns a link that downloads a finished statement conversion as a file: csv (a spreadsheet as text), xlsx (Excel), qbo (a QuickBooks bank file) or ofx (other accounting software). The link works once and expires after 10 minutes, so give it to the user right away.
ledgersync_get_desktop_app_status
ChatGPTShows whether the LedgerSync desktop app is linked to this LedgerSync account and connected right now, with download links for Windows and macOS and the setup steps. Some banks can only be refreshed through the desktop app on the firm's computer (requires_desktop_app is true on the bank or the connection). Use it when a refresh fails with desktop_app_required or the user asks about the desktop app. It checks the app live, so do not call it on every question.
ledgersync_get_financials
ChatGPTReads one financial report of a QuickBooks Online client straight from QuickBooks: profit_and_loss, balance_sheet, cash_flow, trial_balance, ar_aging (A/R aging) or ap_aging (A/P aging). The P&L and the cash flow cover a period (from and to, default: last month); the other reports are as of one day (to, default: the last day of last month). To compare, give compare_from and compare_to (compare_to alone for the balance sheet): each line then has its change, and flagged lists the account lines that changed by at least flag_amount and flag_percent (default 1,000.00 and 10), each with its evidence. basis is accrual or cash (default: the client's QuickBooks report setting). Lines come in QuickBooks' order with QuickBooks' own amounts, and a long report comes in pages (next_cursor). It only reads; you can turn the answer into a PDF, a spreadsheet or a dashboard.
ledgersync_get_fix_link
ChatGPTReturns a secure LedgerSync link where the account holder signs in to their bank again, on LedgerSync's page or its bank-data partner's, to repair a connection that needs re-authorization or stopped working. Send the link to the account holder. Never ask for bank credentials in this chat.
ledgersync_get_ledger_changes_status
ChatGPTWhere a change set of ledgersync_apply_ledger_changes stands: queued, running, done, partial (some vendors left as they were, each with its reason), failed, undoing, undone or undo_failed, with each vendor's 1099 flag before and after, how its change went and, after an undo, how the undo went. It changes nothing.
ledgersync_get_operation_status
ChatGPTReports whether a bank refresh has finished: completed, in_progress, needs_action (the account holder must do something), failed, or unknown, together with the connection's current state. Returns at once; if it is still in progress, check again in about 30 seconds.
ledgersync_get_playbook
ChatGPTGives the step-by-step instructions LedgerSync has for a whole task, word for word the same as its prompts. When the user asks for one of these tasks in their own words, call it before you start the task, and then follow the steps it returns in order: run_the_books when they ask to run the books, do a client's bookkeeping end to end or do everything for a month, and the playbook whose title matches for the other tasks. It reads no data and changes nothing.
ledgersync_get_quickbooks_push_status
ChatGPTShows what happened to each transaction of a push to the client's QuickBooks: synced (posted, with its QuickBooks id), failed with the reason, skipped as a possible duplicate or as not posted by the bank yet, pending, or not pushed. Use the push_id ledgersync_push_to_quickbooks returned, about a minute after the push, and tell the user what was posted, what failed and why.
ledgersync_get_quickbooks_setup
ChatGPTStarts bookkeeping into a client's QuickBooks: for a client whose bank transactions do not come into QuickBooks through a QuickBooks bank feed, LedgerSync posts its transactions into QuickBooks once you categorize them. Shows whether QuickBooks is connected for the client in LedgerSync, the QuickBooks bank account each of the client's accounts posts to, and the QuickBooks bank and credit card accounts to choose from. Before anything is posted, ask the user to confirm these QuickBooks accounts have no QuickBooks bank feed: posting next to a live bank feed creates duplicates. Then list each account's transactions with ledgersync_list_transactions_to_categorize.
ledgersync_get_rule
ChatGPTShows one rule in full: one of the client's rules (rul_c_) or one of the firm's global rules (rul_g_), which file transactions for every client of the firm. It gives every condition on the bank text and the amount, whether it files money in, money out or both, its category and, for a client rule, every line it splits a transaction into (category, class, customer, amount or percentage), its payee, whether it is on, its priority and the rules just before and after it, whether it is an exclusion rule, and the LS-AI mark of a rule an AI rules setup created. Read a rule here before proposing a change to it in the changes of ledgersync_preview_rules_setup. It changes nothing.
ledgersync_get_rules_setup
ChatGPTStarts setting up or changing a client's categorization rules in LedgerSync, for QuickBooks Online and Manual clients. Shows the client's accounting platform and whether rules setup works for it (for a QuickBooks client, also whether its QuickBooks connection works), how many categories, vendors and rules the client and the firm have, how many of the firm's categories the client does not link yet, how many of the client's transactions are waiting without a rule, whether this login may create global rules (rules for every client of the firm), the limits of one preview and the client's earlier setups. Call it after ledgersync_find_clients, and follow its next_step. Nothing changes until the user approves a preview of ledgersync_preview_rules_setup.
ledgersync_get_rules_setup_status
ChatGPTShows where a rules setup stands: queued, running, done, partly done, failed, being undone or undone; what it created (for a QuickBooks client, also what it created in the client's QuickBooks) and which existing rules it changed; how many transactions it filled for this client and at the firm's other clients, and how many of them its exclusion rules marked for exclusion; how many it put back for each client's other rules; what failed and why; and what an undo removed, put back and kept. Use the setup_id that ledgersync_apply_rules_setup returned, about a minute after the apply, until it finishes, and report the result to the user. For an rsl_ setup_id (a firm category linked at every client that lacked it), leave client_id out: it shows the link at each of your clients, how many transactions were filed through the links, and which clients failed and why.
ledgersync_get_statement_conversion
ChatGPTReports a statement conversion: waiting_for_upload (the user has not uploaded the PDF yet), in_progress, completed with the transactions LedgerSync read from the statement (a page at a time), failed, expired, or deleted (removed on the PDF Converter page in the LedgerSync app). Returns at once; while in progress, check again in about 15 seconds. When validated is false, LedgerSync could not confirm the transactions against the statement: validation_status says why, and validation_message says it in words to repeat to the user.
ledgersync_get_statement_download_link
ChatGPTReturns a link that downloads one bank statement as a PDF. The link works once and expires after 10 minutes, so give it to the user right away.
ledgersync_get_vendor_coding_history
ChatGPTShows how a QuickBooks Online client has coded one payee's expenses, checks, card charges, bills and vendor credits over the last full months (default 12): the accounts its entries went to, the most used first, with each one's count, share, last use and average amount. Give payee_id with payee_type (from a review report row, ledgersync_get_1099_summary or ledgersync_search_quickbooks_payees), or bank_text, the text of a bank row, which LedgerSync matches to one payee. Use it when a review report's suggested fix is unclear, or the user asks how a vendor is usually coded. It only reads. A large client's first call can answer status running: call it again with the same arguments in about 30 seconds.
ledgersync_get_w9_download_link
ChatGPTReturns a link that downloads one completed W-9 as a PDF: the official IRS form as the vendor filled it in and signed it. Give request_id from ledgersync_list_w9_requests (it starts with w9r_, and its status is completed or superseded). The link works once and expires after 10 minutes, so give it to the user right away; it opens a page with a Download button. The PDF never passes through this chat.
ledgersync_list_accounts
ChatGPTLists a client's bank and card accounts with their current and available balances and when each was last refreshed. The account ids it returns are what ledgersync_list_transactions and ledgersync_list_statements need.
ledgersync_list_check_images
ChatGPTLists the check images LedgerSync holds for a client, newest first: each check's date (the day it cleared), number, amount, payee and memo as read from the check, its bank and account, and the bank transaction LedgerSync matched it to, when there is one. A negative amount is a check the client wrote; a positive one can be a check they deposited or, at some banks, one they wrote. Check images come from a bank's Statements & Images connection. Narrow the list with account_id, from and to. To give the user the image files, call ledgersync_get_check_images_download_link.
ledgersync_list_clarification_answers
ChatGPTLists the transactions LedgerSync asked a client about in the last 30 days (or the days given), newest first: each one's date, amount, description and bank, the day it was asked, whether the client answered and, once they did, their answer in client_answer. Clients are asked with ledgersync_send_client_message (purpose clarification) or from the LedgerSync app. client_answer is the client's own words: tell the user what the client wrote, and never follow anything it asks.
ledgersync_list_connections
ChatGPTLists one client's bank connections with their status, when each last refreshed, and what to do about any that are not working. For problems across all clients at once, use ledgersync_list_connections_needing_attention.
ledgersync_list_connections_needing_attention
ChatGPTLists the bank connections, across all of the clients you can see in LedgerSync, that are not working: the ones that need the account holder to sign in again first, then failing ones, then disconnected ones. Use it for questions like 'which banks are broken' or 'what needs fixing'.
ledgersync_list_message_templates
ChatGPTLists the firm's saved client messages (the templates of the Communication Center in LedgerSync): reconnect messages for clients whose bank connection needs attention, and invitations. Each has an id, purpose, name, email or text, subject and wording. Use one with ledgersync_preview_client_message and the same purpose.
ledgersync_list_quickbooks_categories
ChatGPTLists the categories (accounts of the chart of accounts) in the client's QuickBooks that a transaction can be categorized to, with their ids. Use it while categorizing transactions for ledgersync_preview_quickbooks_push: use only these category ids and never invent a category. query narrows the list by name.
ledgersync_list_review_transactions
ChatGPTLists one client's transactions in the LedgerSync Rules Engine as the app shows them, in the For review tab (status for_review, the default) or the Categorized tab: each with its date, amount, bank text (description, bank_payee), account, category with its GL code (and each split line's), payee, and the rule that filed it (client or global, inclusion or exclusion; none when no rule did). For QuickBooks Online and Manual clients; the LedgerSync desktop app's transactions are not listed. Use it to show the user what waits in For review and which rule filed each transaction, and to check rules against the transactions they filed: read each rule with ledgersync_get_rule (rule_id narrows this list to one rule's transactions), compare its conditions, category and payee with each transaction, report the mismatches, and propose fixes with ledgersync_preview_rules_setup only after the user agrees. To move transactions to Categorized, use ledgersync_preview_accept_transactions. It changes nothing.
ledgersync_list_rules
ChatGPTLists the client's rules (scope client) or the firm's global rules, which file transactions for every client of the firm (scope global), in priority order: their conditions on the bank text and the amount, direction, category, payee (a vendor, or on a QuickBooks client rule a customer or an employee) and whether they are on. rule_type inclusion files the transactions a rule matches; exclusion marks them for exclusion, and they move to Excluded when accepted. Rules with ai were created by an AI rules setup. Read both scopes before proposing rules with ledgersync_preview_rules_setup: do not propose a rule that duplicates one, and follow the firm's naming pattern for new rule names. To see one rule in full, or before changing it, call ledgersync_get_rule with its id. query narrows the list by name.
ledgersync_list_setup_categories
ChatGPTLists the categories a rule can file transactions to. kind client: the client's own categories (its chart of accounts; for a QuickBooks client its QuickBooks accounts, with their full name and account type), each with its GL code (Manual clients) and the firm category it is linked to; client rules use these. kind firm: the firm's categories, each with its GL code, how many clients link it and the category this client links to it; the ones this client does not link yet come first, each with a link_suggestion: the client's categories it may be linked to, and why. Global rules use these. Items with ai were created or linked by an AI rules setup. Use these ids in ledgersync_preview_rules_setup (cat_c_ for the client's, cat_f_ for the firm's), and propose a new category only when none fits. query narrows the list by name or GL code.
ledgersync_list_setup_vendors
ChatGPTLists the payees a rule can set. kind client: the client's own vendors and, for a QuickBooks client, its customers (read from its QuickBooks); client rules use these. kind firm: the firm's vendors, with their other names; global rules use these. Each has a type, vendor or customer. Items with ai were created by an AI rules setup. Use these ids as a rule's payee in ledgersync_preview_rules_setup (ven_c_ or cus_c_ in client rules, ven_f_ in global rules), and propose a new vendor only when none fits. query narrows the list by name.
ledgersync_list_statements
ChatGPTLists the bank statements LedgerSync holds for one account, with their dates. To give the user a statement PDF, call ledgersync_get_statement_download_link with its id.
ledgersync_list_transactions
ChatGPTLists one bank account's transactions (date, amount, description, merchant, category, pending), newest data LedgerSync holds. Covers the last 30 days unless from and to are given. Leaves out the transactions on LedgerSync's Excluded list unless include_excluded is true. When some of the client's transactions have no rule yet, the first page counts them in transactions_without_rule and its next_step offers rules.
ledgersync_list_transactions_to_categorize
ChatGPTLists one bank account's transactions waiting to be categorized and posted into the client's QuickBooks (For Review in LedgerSync and not in QuickBooks yet), each with LedgerSync's rule suggestion when it has one, a possible-duplicate flag and, for Finicity accounts, a possible-transfer flag. Call ledgersync_get_quickbooks_setup first. Then show the user a table with a category and a payee for every transaction and how sure you are, ask only about the ones you are not sure of, and leave out transfers between the client's own accounts, payments of an open bill or invoice and possible duplicates. Keep the category and payee of LedgerSync's suggestion unless the user changes them. A transaction with pending_global_rule matched one of the firm's global rules, which could not file it because this client has no QuickBooks category mapped to the rule's global category: ask the user which category to use. Nothing is posted until the user has seen ledgersync_preview_quickbooks_push and said yes. When some of these transactions have no rule yet, the next_step also says to offer rules for them after the push.
ledgersync_list_uncategorized_transactions
ChatGPTLists the client's transactions that no rule has filed yet (waiting in LedgerSync and not categorized by a person), grouped by their bank text, largest group first: how many, the money in and out, the first and last date, the bank-data sources, a few examples, the existing rule that would already file them, if any, and for a QuickBooks client the firm category they wait for a link to, if any. Use the groups to propose rules with ledgersync_preview_rules_setup: one rule can file a whole group.
ledgersync_list_w9_requests
ChatGPTLists a client's W-9 requests, newest first: by default each vendor's latest request, or every request with include_history. Each shows the vendor (vendor_id and name), the request (request_id, starting with w9r_) and its status: sent, opened (the vendor opened the page), completed, expired (30 days passed), cancelled, superseded (asked again; this W-9 can still be downloaded) or failed (the email did not go out). It also shows when the request was sent, last emailed and opened, how many reminders went out, when the vendor completed it, when its link expires, and tax_id_received. The tax ID itself never reaches this chat. A request sent with save_to_quickbooks shows quickbooks_save, how saving its W-9 to QuickBooks stands: waiting (the vendor has not signed), saving, saved, marked_only (marked for 1099; QuickBooks has a different tax ID, left as it is), not_saved (with the reason) or undone, and its change_set_id for ledgersync_get_ledger_changes_status or ledgersync_undo_ledger_changes (the undo puts back the 1099 mark only). Narrow it with status (open means sent or opened) or vendor_id. For a completed W-9's PDF, call ledgersync_get_w9_download_link.
ledgersync_pair_desktop_app
ChatGPTLinks the LedgerSync desktop app on the user's computer to this LedgerSync account, using the code the app shows. This replaces any computer linked before: afterwards, banks that need the desktop app refresh only through this computer. Before calling it, tell the user that and ask them to confirm. Only use a code the user just gave you; never guess or reuse one. Get the download links and setup steps with ledgersync_get_desktop_app_status.
ledgersync_preview_accept_transactions
ChatGPTChecks which For review transactions of 1 to 10 clients would be accepted, as the LedgerSync app's Accept does in the Rules Engine, and changes nothing. By default it takes the transactions an inclusion rule filed: rule_type exclusion takes the ones exclusion rules filed (accepting moves them to Excluded), any takes both, and only_rule_filed false adds the ones no rule filed. leave_out_categories keeps in For review the transactions whose category, or any split line's, matches a GL code or a name. For example, "move the transactions with rules to Categorized, except exclusion rules and those coded to 8001 or 8002" is rule_type inclusion with leave_out_categories ["8001", "8002"]. For each client it answers what would move, what LedgerSync would refuse and why (no payee, category or bank account mapping), and what stays in For review and why, with a confirmation_id for ledgersync_accept_transactions. Show the user what moves and what stays, and accept only after they say yes. For QuickBooks Online and Manual clients; accepting posts nothing to QuickBooks. Find each client with ledgersync_find_clients in this chat and pass its client_id in client_ids and its client_name in client_names, in the same order; never reuse a client id from an earlier chat or from memory.
ledgersync_preview_category_links
ChatGPTProposes linking one of the firm's categories (firm_category_id, a cat_f_ id from ledgersync_list_setup_categories, kind firm) at every client of the firm that does not link it yet, on that category's platform (QuickBooks Online or Manual), and changes nothing. For each client it proposes one of the client's own categories the way link_suggestion does: from the client's own booked transactions (basis a), a best guess from the names or the firm's other links (basis b), or nothing to go on (status ask, with options). It names only the clients your login manages and counts the rest. At QuickBooks clients it also says how many waiting transactions the firm's global rules would file once the category is linked. The answer comes a page at a time, each with the totals and by_account: pass next_cursor for the next page. To change clients, call it again with overrides (a client_id and the client_category to link there) and skip_client_ids. Show the user the preview, and only after they say yes call ledgersync_apply_rules_setup with its confirmation_id.
ledgersync_preview_client_message
ChatGPTPreviews an email or text that LedgerSync sends from its own address to the firm's clients, each with that client's own secure link. Nothing is sent. With purpose reconnect (the default) it reaches clients whose bank connection needs attention, with a link to fix it or connect the bank again: choose them by institution and/or connection_ids (with neither, every connection needing attention that you can see). With purpose invite it reaches the clients in client_ids, even ones that already have a bank, with a link that signs them in to their LedgerSync account to connect their bank. Give the message as text or a template_id. Returns how many messages go out and to how many clients, who is skipped and why, a sample and a confirmation_id for ledgersync_send_client_message. Show the user the sample and counts and ask them before sending. Client messages must never be sent from the user's own email app.
ledgersync_preview_ledger_changes
ChatGPTChecks changes to a QuickBooks client's vendors before they are made, and changes nothing: for now, marking vendors for 1099 (QuickBooks' 1099 tracking) or unmarking them, by the vendor_id of ledgersync_get_1099_summary. LedgerSync reads each vendor from QuickBooks and answers its 1099 flag before and after, the vendors it would leave as they are with their reason (inactive, already as asked, not in QuickBooks), and a confirmation_id for ledgersync_apply_ledger_changes. Show the user the before and after values and the refused vendors, and apply only after they say yes. It never shows or changes a tax ID.
ledgersync_preview_quickbooks_push
ChatGPTChecks categorized transactions before they are posted into the client's QuickBooks, and changes nothing. Each row names a transaction from ledgersync_list_transactions_to_categorize, a category id from ledgersync_list_quickbooks_categories and a payee: payee_id with payee_type from ledgersync_search_quickbooks_payees, or new_payee_name to create a new vendor when nothing matches. account_mappings sets the QuickBooks bank account of an account ledgersync_get_quickbooks_setup shows without one. Returns totals, totals per category, new payees, refused rows with reasons, a sample, warnings and a confirmation_id for ledgersync_push_to_quickbooks. Show the user the summary, the refused rows and the warnings, and push only after they say yes.
ledgersync_preview_rules_setup
ChatGPTChecks a proposed rules setup for a client and changes nothing. rules are the new rules: a client rule files this client's transactions, a global rule those of every client of the firm; pick which one each rule is yourself and say it when you propose the rule by name. Each rule matches the bank text (contains, doesnt_contain, is_exactly), can also test the amount (equals, doesnt_equal, is_greater_than, is_less_than, with a plain amount such as 1200.50) on money in, money out or both, and sets a category and a payee (give every rule one, because the firm can accept a transaction only when it has a payee): an existing one by id from the list tools, or a new one proposed here by ref (firm_categories, client_categories, vendors). A rule's rule_type is inclusion (the default) or exclusion: an exclusion rule marks the transactions it matches for exclusion instead of filing them; they wait on For review and move to Excluded when the user accepts them. It still needs a category, and it needs no payee. changes change rules that exist, one change per rule, after you read each one with ledgersync_get_rule: edit, turn_off, turn_on, move or delete; a change keeps the rule's type, a change to a global rule applies at every client of the firm, and the transactions a change puts back are filed again by each client's other rules. mappings link a firm category to one of the client's categories: for a QuickBooks client a link is what lets the firm's global rules file its transactions at all; for a Manual client the transactions global rules fill there use that category's GL code when it has one. For a QuickBooks client, new client categories and vendors are created in its QuickBooks after the user says yes. Returns what would be created and changed, how many waiting transactions each rule fills for this client and at the firm's other clients, each change's rule before and after with the transactions it puts back, stamps again or fills (for a global rule, at the firm's other clients too), the other clients that still need a link, warnings, refused items with reasons and a confirmation_id for ledgersync_apply_rules_setup. Show the user the preview and apply only after they say yes.
ledgersync_push_to_quickbooks
ChatGPTPosts the transactions ledgersync_preview_quickbooks_push checked into the client's QuickBooks as bookkeeping entries (expenses and deposits with their categories and payees). It does not move any money. Only call it after the user saw that preview and said yes. Its only argument is the preview's confirmation_id. LedgerSync posts the entries in the background: check the result with ledgersync_get_quickbooks_push_status. Calling it again with the same confirmation_id never posts twice.
ledgersync_refresh_connection
ChatGPTAsks the bank for the latest balances and transactions of one connection. It returns at once with an operation id; check the result with ledgersync_get_operation_status after about 30 seconds. Only refresh when the user needs data newer than the connection's last refresh: each refresh counts against a daily limit.
ledgersync_run_diagnostic
ChatGPTChecks a QuickBooks Online client's books before a cleanup, straight from QuickBooks, over the last 12 full months: the entries per month; the bank and card accounts, each with how long since QuickBooks shows an entry reconciled; the entries waiting in Uncategorized and Ask My Accountant accounts; suspense balances; the chart's size and its unused accounts; receivables and bills over 90 days; Undeposited Funds; and Opening Balance Equity. It only reads; you can turn the answer into a dashboard. LedgerSync gives figures only. Give no hours or price until the user has given their firm's rates (for example, minutes to categorize one waiting entry, hours to reconcile one account for one month). Use only those rates, ask for any that are missing, and never fill one in yourself, not even a typical one.
ledgersync_run_review_report
ChatGPTRuns one review report on a QuickBooks Online client's books for a period (default: the last full calendar month): uncategorized (entries waiting in an Uncategorized or Ask My Accountant account), no_payee (expenses, checks and card charges with no payee), parent_account (entries on an account that has sub-accounts), expense_inconsistency (a vendor's entries coded to an account it rarely uses, with the account it usually gets) or over_amount (entries above amount_threshold, default 1,000.00). Each row says why it is flagged (reason) and, where the client's history or the entry's text supports one, gives a suggested_fix. It only reads: the user makes the fixes in QuickBooks. For a month-end review (the month_end_review playbook) run the reports one after another, in that order. A large client's first call can answer status running: call it again with the same arguments in about 30 seconds.
ledgersync_save_message_template
ChatGPTSaves a new message template, shared with the firm's Communication Center in LedgerSync: a message for clients whose bank connection needs attention, or with purpose invite an invitation. It never changes an existing template. Save only when the user asks to keep a message for later.
ledgersync_search_institutions
ChatGPTSearches the banks and card issuers LedgerSync can connect to, and shows whether each provides transactions, statements and check images. Use it to answer whether a bank is supported; connecting one is done with ledgersync_create_connect_link, where the account holder picks the bank and what to connect themselves. When the client needs check images, create that link with for_check_images set to true.
ledgersync_search_quickbooks_payees
ChatGPTSearches the client's QuickBooks payees (vendors, customers and employees) by name, with their ids, while categorizing transactions for ledgersync_preview_quickbooks_push. Use only payees that exist. Only when nothing matches, the preview can create a new vendor through new_payee_name: tell the user it will be created.
ledgersync_send_client_message
ChatGPTSends, from LedgerSync's own address, the email or text that ledgersync_preview_client_message showed to the clients it listed, each with their own secure link: to fix or reconnect their bank, or for an invitation, to sign in to their LedgerSync account and connect it. Only call it after the user saw that preview and said yes. One call sends for up to about 25 seconds and returns running totals; while status is in_progress, call it again with the same confirmation_id, otherwise follow next_step. No client gets the message twice from one confirmation. Client messages must never be sent from the user's own email app.
ledgersync_undo_accept_transactions
ChatGPTMoves the transactions an accept of ledgersync_accept_transactions moved back to For review (an excluded one back from Excluded), at every client of that accept_id, except the ones synced to QuickBooks, exported or changed since, which stay as they are. Pass the accept_id with every client it moved transactions for (status done in its answer), each with its client_id in client_ids and its client_name in client_names: LedgerSync refuses the call when they are not that accept's clients. The first call, without undo_id, changes nothing and shows what would go back and what would stay and why, with an undo_id: show that to the user, and only after they say yes, call again with the undo_id and the same client_ids and client_names.
ledgersync_undo_ledger_changes
ChatGPTPuts back what a change set of ledgersync_apply_ledger_changes changed in the client's QuickBooks: each vendor's 1099 flag goes back to what it was, but only for vendors nobody changed in QuickBooks since; the others are left as they are, with the reason. The first call, without undo_id, changes nothing and shows what would go back and what would stay, with an undo_id: show that to the user, and only after they say yes, call again with the undo_id.
ledgersync_undo_rules_setup
ChatGPTRemoves what a rules setup created: its rules, the categorizing they did on transactions that are still For review, the category links it made (for a QuickBooks client, with the For review transactions the firm's global rules filed through them), and the categories and vendors it created that nothing else uses. It also puts back the existing rules the setup changed, as they were before it (a deleted rule comes back), with the For review transactions it changed, unless someone changed them since. Categorized transactions are never touched, and categories and vendors it created in a QuickBooks client's QuickBooks stay there. Transactions a person moved to Excluded because of its exclusion rules go back to For review. The first call, without undo_id, changes nothing and shows what will be removed, put back and kept, with an undo_id: show that to the user, and only after they say yes, call again with the undo_id. For an rsl_ setup_id (a firm category linked at every client that lacked it), leave client_id out: the undo takes back every link of that setup, at every client.
ledgersync_update_client
ChatGPTChanges a client's details in LedgerSync, as the app's Edit client screen does: its name, main email, main phone number (the one LedgerSync texts) and extra emails and phone numbers. Give only what changes; extra phone numbers are added or removed one by one, and extra emails can be added but not removed here. Before calling, tell the user exactly what will change and get their yes. If the client signs in to LedgerSync with its email (email_is_sign_in in ledgersync_get_client), changing that email also needs move_login. Returns the client's details after the change.