# Alegra MCP MCP

> Alegra lets your AI agent manage professional billing, track inventory levels, and handle customer data for Latin American business operations. Connect your accounting records and run financial reports using natural conversation—no more switching between apps.

## Overview
- **Category:** productivity
- **Price:** Free
- **Tags:** billing-software, inventory-management, invoicing, crm-software, fintech-api, alegra

## Description

Managing a small business means juggling invoices, checking stock counts, and keeping tabs on client balances. Traditionally, this meant logging into separate CRMs and accounting platforms just to find one piece of data. Now, you don't have to do that.

This MCP connects your Alegra account directly to any AI agent, consolidating all your core business functions into a single conversational interface. Need to know if John Doe has an overdue balance? Just ask. Want to see the current stock count for professional desks before creating a quote? The agent handles it. You can manage everything from creating new sales invoices and listing payments to pulling basic company data—all without leaving your chat window. Since Vinkius hosts this MCP, you get instant access to all these functions via any compatible AI client.

It’s about getting answers fast. Your agent acts as the direct conduit to your books, giving you clear oversight of billing cycles and inventory status.

## Tools

### create_contact
Creates a new contact profile within the Alegra system.

### create_invoice
Generates and records a brand new sales invoice in your account.

### get_contact_details
Fetches all specific information associated with a named contact, whether they are a client or supplier.

### get_invoice_details
Retrieves the full record and status details for any specified sales invoice number.

### get_item_details
Gets specific pricing, stock, and descriptive data about an individual inventory product or service item.

### get_company_info
Retrieves general operational metadata about the Alegra company profile.

### list_contacts
Provides a list of all contacts (both clients and suppliers) maintained in Alegra.

### list_estimates
Lists all sales estimates or quotes that have been sent to potential customers.

### list_invoices
Lists all sales invoices recorded in Alegra, allowing you to see their status at a glance.

### list_inventory_items
Provides a comprehensive list of every product and service item cataloged in the system.

### list_payments
Retrieves a list of payments that have been successfully recorded in the system.

## Prompt Examples

**Prompt:** 
```
List all active invoices in my Alegra account.
```

**Response:** 
```
I've retrieved your invoices. You have 3 active sales documents: #INV-001 ($150.00, Paid), #INV-002 ($450.00, Open), and #INV-003 ($1,200.00, Overdue). Which one would you like more details on?
```

**Prompt:** 
```
Show me the details for contact 'John Doe' (ID: 10293).
```

**Response:** 
```
I've fetched John Doe's profile. He is a 'Client' and has an outstanding balance of $450.00 from invoice #INV-002. Shall I retrieve his full contact history?
```

**Prompt:** 
```
What is the stock level for 'Professional Desk'?
```

**Response:** 
```
Checking inventory... The 'Professional Desk' (ID: item_8823) currently has 15 units in stock. The unit price is $250.00. Would you like to create an invoice for this item?
```

## Capabilities

### Generate and track invoices
The system can create new sales invoices and list existing ones, showing their current payment status (paid, open, or overdue).

### Manage customer records
You can retrieve specific contact details, build new contacts, and list your entire client and supplier directory.

### Monitor stock levels
The agent queries the product catalog to report on available inventory items and their current pricing metadata.

### Review financial history
You can list all recorded payments, view sales estimates sent out, or get detailed information about any specific invoice number.

### Retrieve company data
The tool fetches core metadata and account configuration details directly from your Alegra profile for verification.

## Use Cases

### The Client Balance Check
A sales rep needs to know if a potential client has an immediate outstanding balance before sending a final proposal. They ask their agent, and the system uses `list_invoices` and `get_contact_details` to summarize all overdue accounts immediately.

### Inventory Verification Before Quoting
An operations manager has an estimate for a custom build. They ask their agent, who runs `list_inventory_items`, checks the stock levels via `get_item_details`, and confirms availability before drafting the final quote.

### Reconciling Payments
The bookkeeper needs to reconcile payments against open invoices. They instruct their agent to run `list_payments` and cross-reference those records with outstanding documents using `get_invoice_details`.

### New Client Setup
A new lead comes in, and the team needs a record. Instead of manually logging into multiple forms, they simply ask the agent to execute `create_contact`, getting it entered right away.

## Benefits

- Instead of logging into a separate CRM to check contact history, you can use the agent to get details on any contact directly. You just need the `get_contact_details` tool for that.
- You never have to manually build an invoice from scratch again. The system handles generating and tracking sales invoices with a single command using `create_invoice`.
- Track your company's financial health instantly. By calling `list_payments`, you get a clear picture of incoming funds without opening any bank statements.
- Inventory checks are simple. Use the agent to list products via `list_inventory_items` and check specific stock counts using `get_item_details` before quoting a client.
- Streamline reporting by listing all outstanding documents with `list_invoices`, making it easy for finance teams to spot overdue accounts immediately.

## How It Works

The bottom line is that all of your business data becomes accessible via simple commands from your chat interface.

1. First, you subscribe to this MCP on Vinkius.
2. Second, you provide the agent with your Alegra Email and API Token found in your account settings.
3. Third, you start by asking a question or giving an instruction through your AI client.

## Frequently Asked Questions

**How can I check if an invoice was paid using list_invoices?**
You view the status column when you use `list_invoices`. The agent filters this data and tells you exactly which invoices are marked as 'Paid,' helping you quickly confirm payment records.

**Can I create a new contact using create_contact?**
Yes. You ask the agent to create a contact, providing just the name and details. The tool handles logging it into your customer directory immediately.

**How do I check item availability with get_item_details?**
Simply request the item name from the agent. It uses `get_item_details` to fetch current stock levels and the unit price, letting you know if it's available for sale.

**What is the best way to see all my overdue bills?**
Use `list_invoices`. The agent retrieves the list of sales documents and filters them specifically by 'overdue' status, giving you a clean report of what needs attention.

**How does using the `get_company_info` tool help me verify my overall account setup?**
Running `get_company_info` confirms your credentials and pulls core company metadata. This is a quick check you should run after connecting to confirm the MCP has full access to all necessary financial data.

**When I call `create_invoice`, what information must I provide to ensure the invoice processes correctly?**
You need a valid contact ID, item details, and quantity for the MCP to draft an accurate invoice. The system will flag missing fields like tax rates or payment terms before it finalizes the document.

**Does `list_estimates` help me track potential sales that haven't become formal invoices yet?**
Yes, this tool pulls all outstanding quotes, letting you manage potential revenue streams. You can sort and filter these estimates by expiration date or client status.

**How do I use `list_payments` to check for payment discrepancies across my accounts?**
The tool returns a detailed record of every logged payment transaction, including associated invoice numbers. You can compare these records against your expected revenue flow directly in the chat.

**Can I check the stock level of an item via AI?**
Yes! Use the `get_item_details` tool and provide the Item ID. Your agent will retrieve the complete metadata, including current stock levels for that product.

**How do I create a new invoice for a client?**
Use the `create_invoice` action. You'll need to provide the Contact ID, date, due date, and a JSON string of items to register the new sale in Alegra.

**Is it possible to list all my recent payments?**
Absolutely. Use the `list_payments` query. The agent will retrieve a list of all recorded income payments received in your account.