# Treinta App MCP

> Treinta App MCP Server connects your small business ledger directly to any AI agent. Automate bookkeeping by writing transactions, checking client debt status (`get_client`), and auditing inventory from chat—no need to open the mobile app or spreadsheet.

## Overview
- **Category:** ecommerce
- **Price:** Free
- **Tags:** bookkeeping, smb-tools, inventory-management, debt-tracking, transactions

## Description

Treinta App connects your small business ledger straight into your AI agent. You don't gotta open the mobile app or mess with spreadsheets to run your bookkeeping; your agent handles it all.

**Managing Transactions and Books:**
When you need to log a sale or an expense, use `create_transaction` to write a new income or expense record right into your accounting books. If you make a mistake—say, you entered the wrong amount or recorded something that never happened—you can hit `delete_transaction` to reverse that bad entry and keep your ledger clean.

**Client Accounts:**
You gotta know who owes you dough. You'll use `list_clients` to get a full rundown of every active client in the system, giving you their basic details at a glance. If you need specifics on one person—like checking out Joe’s exact unpaid balance and seeing his whole transaction history—you run `get_client`. For setting up shop with new folks, you use `create_client` to add a brand-new customer record directly into the ledger.

**Inventory and Product Tracking:**
Keeping track of stock is crucial. To get a comprehensive view of what you've got on hand, run `list_products` to pull up your entire current inventory catalog. If you only care about one item—maybe checking how much Model X costs or its current specs—you use `get_product`. And if someone misplaced some widgets and you gotta update the count, you call `update_product_stock` to adjust the physical quantity for an existing product SKU. When you're starting out and haven't registered a new line of goods yet, you run `create_product` to add that brand-new item into the store’s inventory list.

**Running Financial Reports:**
Want to know if the business is making money? You call `get_business_stats` to pull up a summary of your overall Profit & Loss operations dashboard. For checking out sales over time, you use `list_sales` to get all recorded sale transactions within a specific timeframe. To see every single movement that's ever happened in the books—from deposits to write-offs—you run `list_transactions`, which gives you a full, chronological list of everything in the general ledger. For tracking overall sales activity, `list_sales` lets you review all recorded transactions over a set period.

**How It Works:**
Your agent treats this server like an extension cord for your bookkeeping. You tell it what to do—'Check out Acme Corp’s debt,' or 'Log $50 in supplies paid cash'—and the agent executes the corresponding tool call (`get_client` or `create_transaction`). It keeps everything synchronized without you having to navigate multiple apps or spreadsheets. This gives you a single chat interface for managing your money, clients, and stock.

## Tools

### create_client
Adds a new customer record to the ledger system.

### create_product
Registers a brand-new product into the store's inventory list.

### create_transaction
Writes a new business transaction (income or expense) to your accounting books.

### delete_transaction
Reverses an incorrect or erroneous financial entry from the ledger.

### get_business_stats
Retrieves a summary of your overall Profit & Loss operations dashboard.

### get_client
Fetches the specific debt profile and transaction history for one client.

### get_product
Retrieves detailed information about a single product SKU in your inventory.

### list_clients
Gathers a list of all active clients and their basic details.

### list_products
Retrieves the complete, current inventory catalog for your store.

### list_sales
Lists all recorded sales transactions over a specified period.

### list_transactions
Retrieves a full, chronological list of every movement in the general ledger.

### update_product_stock
Adjusts the physical quantity count for an existing product SKU.

## Prompt Examples

**Prompt:** 
```
Audit the store today. Check recent logged transactions and summarize our business overall dashboard stats.
```

**Response:** 
```
Running deep audit natively! From recent logs, we observed a steady 'Expense' tied to utilities and 3 minor 'Income' retail transactions. Pulling P&L Dashboard confirms an aggregated positive Net Margin resting globally at 2.5K. Cashflow looks healthy.
```

**Prompt:** 
```
Create a formal Income Transaction representing our $35 cash sale of the surplus store products.
```

**Response:** 
```
Transaction pushed successfully onto ledgers! Stamped '$35' under 'Income' tagging surplus. Refreshed data rests native on your mobile app instantly.
```

**Prompt:** 
```
Delete this transaction id 123
```

**Response:** 
```
Done.
```

## Capabilities

### Record and modify transactions
Write new income/expense records using `create_transaction`, or reverse a mistake with `delete_transaction`.

### Manage client accounts
List all registered clients (`list_clients`) and fetch specific debt profiles for any individual customer using `get_client`.

### Audit product inventory
Get the full business catalog with `list_products`, check a single item's details via `get_product`, or manually correct stock levels with `update_product_stock`.

### Run financial reports
Generate macro Profit & Loss statements (`get_business_stats`) and list consolidated sales records (`list_sales`).

### Set up new data entities
Add a completely new client record using `create_client` or register a product that isn't yet in the system via `create_product`.

## Use Cases

### The End-of-Day Reconciliation
It's 5 PM and you need to close books. Instead of manually gathering sales reports from three different sources, you tell your agent: 'Audit the store today.' The agent runs `list_sales` and then uses `get_business_stats` to give you a single P&L summary, confirming if you hit your margin target.

### Finding Out Who Owes Money
You suspect Client X is late paying. You tell your agent: 'Check Client X's debt.' The agent runs `get_client` and immediately returns the exact balance owed, along with a list of all previous transactions to back it up.

### Correcting Stock Mistakes
You notice 10 units of Product B are missing from the shelf. You tell your agent: 'Update product stock for SKU 456.' The agent runs `update_product_stock`, changing the official count and updating all related inventory records.

### Cleaning Up Mistakes
You accidentally logged a transaction twice. You tell your agent: 'Delete transaction ID ABC-123.' The agent runs `delete_transaction` and removes the duplicate entry, keeping your books clean instantly.

## Benefits

- Stop manually tracking debt. Use `get_client` or `list_clients` to instantly pull up who owes money, seeing the precise unpaid balance without opening a separate client portal.
- Never lose track of cash flow again. Running `list_transactions` lets your agent pull every single entry—income and expense—into one view for easy reconciliation.
- Inventory counts are always current. When you run `update_product_stock`, the system changes the physical count record immediately, making sure your sales reports match reality.
- Get instant financial summaries. The `get_business_stats` tool runs a macro P&L report that tells you if your month's operations were profitable in seconds.
- Streamline data entry. You can use `create_transaction` to formalize any cash sale or expense right from the chat, logging it against the correct ledger codes.

## How It Works

The bottom line is: Your AI client talks to this server, which then executes specific commands against Treinta's core database, giving you immediate accounting data without leaving your chat window.

1. Append the node and integrate the official bearer Dev Token, which Treinta exports privately.
2. Instruct your agent to act like a hands-on business manager. You're not just asking questions; you're assigning it tasks.
3. The agent uses the available tools (like `list_transactions` or `get_client`) and reports back with the calculated result, updating your ledger in real time.

## Frequently Asked Questions

**How do I list all clients with Treinta App MCP Server?**
Run `list_clients`. This tool gathers a comprehensive list of every client registered in the ledger, letting you see who needs attention.

**Can I record an income sale using create_transaction?**
Yep. Just ask your agent to 'create transaction' and specify the amount and reason (e.g., $50 for surplus goods). It logs it instantly.

**What is list_transactions used for in Treinta App MCP Server?**
`list_transactions` pulls a complete chronological record of every financial movement—the whole book flow. Use this when you need to audit or verify past activity.

**Does update_product_stock affect my sales reports?**
It updates the core inventory count, which is critical for accurate reporting. When you run `get_business_stats`, it uses the most current stock data available.

**How is my data secure when I run the `get_business_stats` tool?**
The connection uses the official Treinta Bearer Token, which encrypts all transmitted data end-to-end. Your AI client never sees your raw credentials; it only sends calls to a protected endpoint.

**What happens if I call `delete_transaction` with an ID that doesn't exist?**
The system returns a clear status code indicating the ID was not found. You’ll get a specific error message, allowing your agent to immediately retry or alert you manually.

**When I use `list_products`, am I seeing the live inventory count?**
Yes, `list_products` queries the active store database in real time. This means any recent stock updates or sales recorded through other tools are reflected instantly.

**Is there a limit if I use `create_transaction` many times quickly?**
Yes, the API enforces standard rate limits to maintain system stability. For high-volume processing, we recommend breaking large transaction batches into smaller, sequential calls.

**Can I effectively add a transaction manually into my Treinta log via chat?**
Absolutely. Target the `create_transaction` pipeline expressing clearly if it is 'income' or 'expense' plus the numeral amount, and the AI correctly syncs your local digital accountant book over to proper state.

**Is the Treinta token key shielded visually so employees cannot read it out?**
Yes. Following protocol standard, all credentials marked within the SMB Accounting group carry underlying `sensitive: true` parameters natively wiping the true key from console displays.

**Are operations retroactive?**
Yes, if you fetch the right dates.