siigo-mcp-server 2.1.0 → 3.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +93 -1
- package/README.md +263 -170
- package/bin/siigo-mcp +5 -15
- package/dist/index.js +1410 -1162
- package/dist/index.js.map +1 -1
- package/dist/siigo-client.d.ts +70 -61
- package/dist/siigo-client.d.ts.map +1 -1
- package/dist/siigo-client.js +155 -70
- package/dist/siigo-client.js.map +1 -1
- package/dist/types.d.ts +540 -102
- package/dist/types.d.ts.map +1 -1
- package/dist/types.js +2 -2
- package/dist/types.js.map +1 -1
- package/package.json +20 -19
package/CHANGELOG.md
CHANGED
|
@@ -5,6 +5,98 @@ All notable changes to this project will be documented in this file.
|
|
|
5
5
|
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
|
|
6
6
|
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
7
7
|
|
|
8
|
+
## [3.0.1] - 2026-03-11
|
|
9
|
+
|
|
10
|
+
### Fixed
|
|
11
|
+
- API failures now surface as proper MCP tool errors instead of success payloads, preserving Siigo error details for callers.
|
|
12
|
+
- Webhook updates now target the specific webhook resource by ID.
|
|
13
|
+
- Product and customer partial-match search now scans all result pages before filtering, avoiding missed matches beyond the first page.
|
|
14
|
+
|
|
15
|
+
### Changed
|
|
16
|
+
- Switched project package management to pnpm and added `pnpm-lock.yaml` plus `packageManager` metadata.
|
|
17
|
+
- Updated direct dependencies to the latest safe patch/minor releases used by this project.
|
|
18
|
+
- Added Jest smoke coverage for API error propagation, webhook updates, and paginated search behavior.
|
|
19
|
+
|
|
20
|
+
## [3.0.0] - 2026-02-13
|
|
21
|
+
|
|
22
|
+
### BREAKING CHANGES
|
|
23
|
+
- **MCP SDK upgraded from v0.6 to v1.26** - Uses the new `McpServer` high-level API with `registerTool()` and Zod input schemas. The low-level `Server` class with `ListToolsRequestSchema`/`CallToolRequestSchema` handlers has been replaced.
|
|
24
|
+
- **Package is now ESM** - Added `"type": "module"` to package.json, switched tsconfig to `module: "Node16"`.
|
|
25
|
+
- **`zod` is now a required dependency** (peer dependency of the new MCP SDK).
|
|
26
|
+
- **Report endpoints fixed** - Trial balance reports now use `POST` method and correct API paths (`/v1/test-balance-report`, `/v1/test-balance-report-by-thirdparty`) as per the Siigo API spec. Previously used `GET` with incorrect paths.
|
|
27
|
+
- **Bin entry point changed** - `siigo-mcp` bin now points directly to `dist/index.js` instead of a wrapper script.
|
|
28
|
+
|
|
29
|
+
### Added - New Endpoints (17 new tools, total 68 tools)
|
|
30
|
+
|
|
31
|
+
#### Quotations (Cotizaciones) - 5 tools
|
|
32
|
+
- `siigo_get_quotations` - List quotations with date filters
|
|
33
|
+
- `siigo_get_quotation` - Get a specific quotation by ID
|
|
34
|
+
- `siigo_create_quotation` - Create a new quotation (document type C)
|
|
35
|
+
- `siigo_update_quotation` - Update an existing quotation
|
|
36
|
+
- `siigo_delete_quotation` - Delete a quotation
|
|
37
|
+
|
|
38
|
+
#### Inventory Categories (Categorias de Inventario) - 2 tools
|
|
39
|
+
- `siigo_create_account_group` - Create a new inventory category
|
|
40
|
+
- `siigo_update_account_group` - Update an existing inventory category
|
|
41
|
+
|
|
42
|
+
#### Invoice Enhancements - 4 tools
|
|
43
|
+
- `siigo_create_invoice_batch` - Create invoices in batch asynchronously with webhook notification
|
|
44
|
+
- `siigo_annul_invoice` - Annul (void) a sales invoice
|
|
45
|
+
- `siigo_get_invoice_xml` - Get invoice electronic XML as base64
|
|
46
|
+
- `siigo_get_invoice_stamp_errors` - Get DIAN rejection errors for failed electronic invoices
|
|
47
|
+
|
|
48
|
+
#### Credit Note Enhancements - 1 tool
|
|
49
|
+
- `siigo_get_credit_note_pdf` - Get credit note PDF as base64
|
|
50
|
+
|
|
51
|
+
#### Catalog Enhancements - 1 tool
|
|
52
|
+
- `siigo_get_fixed_assets` - Get fixed assets catalog
|
|
53
|
+
|
|
54
|
+
#### Webhooks - 4 tools
|
|
55
|
+
- `siigo_get_webhooks` - List webhook subscriptions
|
|
56
|
+
- `siigo_create_webhook` - Subscribe to a webhook event
|
|
57
|
+
- `siigo_update_webhook` - Update a webhook subscription
|
|
58
|
+
- `siigo_delete_webhook` - Delete a webhook subscription
|
|
59
|
+
|
|
60
|
+
### Enhanced - Existing Endpoints
|
|
61
|
+
|
|
62
|
+
#### Combo Products
|
|
63
|
+
- `siigo_create_product` and `siigo_update_product` now support `type: "Combo"` with a `components` array containing `code` and `quantity` for each component product.
|
|
64
|
+
|
|
65
|
+
#### Healthcare Sector (Sector Salud)
|
|
66
|
+
- `siigo_create_invoice` and `siigo_create_credit_note` now support `healthcare_company` object with fields: `operation_type` (SS-CUFE, SS-SinAporte, SS-Recaudo), `period_start`, `period_end`, `payment_method`, `service_plan`, `policy_number`, `contract_number`, `copayment`, `coinsurance`, `cost_sharing`, `recovery_charge`.
|
|
67
|
+
|
|
68
|
+
#### Document Type Filter
|
|
69
|
+
- `siigo_get_document_types` now supports `RP` (payment receipt) and `C` (quotation) type codes in addition to FV, RC, NC, FC, CC.
|
|
70
|
+
|
|
71
|
+
#### Credit Notes
|
|
72
|
+
- `siigo_create_credit_note` now supports `invoice_data` for referencing external invoices not in Siigo, and `reason` field.
|
|
73
|
+
|
|
74
|
+
### Changed - Architecture & Code Quality
|
|
75
|
+
|
|
76
|
+
#### MCP SDK Upgrade (0.6 -> 1.26)
|
|
77
|
+
- Migrated from low-level `Server` with manual request handlers to high-level `McpServer` with `registerTool()` pattern
|
|
78
|
+
- All tool input schemas now use Zod for runtime validation
|
|
79
|
+
- Added tool annotations (`readOnlyHint`, `destructiveHint`) for all 59 tools
|
|
80
|
+
- Server version now correctly reports `3.0.0`
|
|
81
|
+
|
|
82
|
+
#### Full TypeScript Type Safety
|
|
83
|
+
- Added proper interfaces for all document types: `SiigoQuotation`, `SiigoVoucher`, `SiigoPaymentReceipt`, `SiigoCreditNote`, `SiigoPurchase`, `SiigoJournal`, `SiigoWebhook`, `SiigoBatchInvoiceRequest`, `SiigoAccountGroupIn`, `SiigoFixedAsset`, and more
|
|
84
|
+
- Replaced all `any` types in `siigo-client.ts` with proper typed interfaces
|
|
85
|
+
- Added comprehensive types for catalogs, reports, and shared structures
|
|
86
|
+
|
|
87
|
+
#### Bug Fixes
|
|
88
|
+
- Fixed server version reporting `1.0.0` instead of actual version
|
|
89
|
+
- Fixed trial balance report endpoints using wrong HTTP method (`GET` -> `POST`)
|
|
90
|
+
- Fixed trial balance report endpoint paths to match Siigo API spec
|
|
91
|
+
- Added 120s timeout to HTTP client as recommended by Siigo API docs
|
|
92
|
+
|
|
93
|
+
### Migration Guide
|
|
94
|
+
If upgrading from v2.x.x:
|
|
95
|
+
1. Run `npm install` to get the new SDK and zod dependencies
|
|
96
|
+
2. If importing types, note that many `any` types have been replaced with proper interfaces
|
|
97
|
+
3. The bin entry point has changed - if you reference it directly, update paths accordingly
|
|
98
|
+
4. Report tools may behave differently as they now use the correct HTTP method (POST)
|
|
99
|
+
|
|
8
100
|
## [2.1.0] - 2024-09-17
|
|
9
101
|
|
|
10
102
|
### Added
|
|
@@ -61,4 +153,4 @@ If upgrading from v1.x.x, you need to:
|
|
|
61
153
|
- Comprehensive TypeScript implementation
|
|
62
154
|
- Environment variable configuration
|
|
63
155
|
- Automatic token management and refresh
|
|
64
|
-
- Error handling and validation
|
|
156
|
+
- Error handling and validation
|
package/README.md
CHANGED
|
@@ -1,248 +1,340 @@
|
|
|
1
1
|
# Siigo MCP Server
|
|
2
2
|
|
|
3
|
-
A Model Context Protocol (MCP) server that provides integration with the Siigo API, enabling access to Colombian accounting software features including products, customers, invoices, purchases, credit notes, vouchers, payment receipts, and
|
|
3
|
+
A Model Context Protocol (MCP) server that provides full integration with the Siigo API, enabling access to Colombian accounting software features including products, customers, invoices, quotations, purchases, credit notes, vouchers, payment receipts, journals, webhooks, and more.
|
|
4
|
+
|
|
5
|
+
**v3.0.1** - Full Siigo API parity with 68 tools, MCP SDK v1.27, Zod schemas, improved MCP error propagation, and complete TypeScript type safety.
|
|
4
6
|
|
|
5
7
|
## Features
|
|
6
8
|
|
|
7
|
-
This MCP server provides access to all
|
|
9
|
+
This MCP server provides access to all Siigo API endpoints:
|
|
8
10
|
|
|
9
11
|
### Core Resources
|
|
10
|
-
- **Products**:
|
|
11
|
-
- **Customers**: Manage
|
|
12
|
-
- **Invoices**:
|
|
13
|
-
- **
|
|
14
|
-
- **
|
|
15
|
-
- **
|
|
16
|
-
- **
|
|
17
|
-
- **
|
|
12
|
+
- **Products**: Full CRUD for products, services, consumer goods, and **Combo** products with components
|
|
13
|
+
- **Customers**: Manage customers, suppliers, and third parties
|
|
14
|
+
- **Invoices**: Sales invoices with electronic invoicing, **healthcare sector**, **batch creation**, annulment, PDF, XML, and DIAN error queries
|
|
15
|
+
- **Quotations**: Full CRUD for quotations (cotizaciones) -- **NEW in v3**
|
|
16
|
+
- **Purchases**: Purchase invoices and expenses (including Documentos de Soporte via `document_support` flag)
|
|
17
|
+
- **Credit Notes**: Create and query credit notes with PDF support and healthcare sector fields
|
|
18
|
+
- **Vouchers**: Cash receipts (recibos de caja) - create and query
|
|
19
|
+
- **Payment Receipts**: Payment receipts / disbursements (recibos de pago / comprobantes de egreso) - full CRUD
|
|
20
|
+
- **Journals**: Accounting journal entries (comprobantes contables)
|
|
21
|
+
- **Webhooks**: Subscribe to and manage webhook events -- **NEW in v3**
|
|
22
|
+
|
|
23
|
+
### Inventory Management
|
|
24
|
+
- **Account Groups**: Create and edit inventory categories -- **NEW in v3**
|
|
18
25
|
|
|
19
26
|
### Catalogs
|
|
20
|
-
- Document types,
|
|
21
|
-
-
|
|
22
|
-
-
|
|
23
|
-
-
|
|
27
|
+
- Document types (FV, RC, NC, FC, CC, RP, C)
|
|
28
|
+
- Taxes, payment types, cost centers
|
|
29
|
+
- Users/sellers, warehouses, price lists
|
|
30
|
+
- Account groups, cities, ID types
|
|
31
|
+
- Fiscal responsibilities, **fixed assets**
|
|
24
32
|
|
|
25
33
|
### Reports
|
|
26
|
-
- Trial balance reports
|
|
27
|
-
- Trial balance by third party
|
|
34
|
+
- Trial balance reports (general and by third party)
|
|
28
35
|
- Accounts payable reports
|
|
29
36
|
|
|
30
37
|
## Installation
|
|
31
38
|
|
|
32
39
|
### Option 1: NPX (Recommended - No Installation Required)
|
|
33
40
|
```bash
|
|
34
|
-
# Run directly with npx - downloads and runs the latest version
|
|
35
41
|
npx siigo-mcp-server
|
|
36
42
|
```
|
|
37
43
|
|
|
38
44
|
### Option 2: Global Installation
|
|
39
45
|
```bash
|
|
40
|
-
# Install globally
|
|
41
46
|
npm install -g siigo-mcp-server
|
|
42
|
-
|
|
43
|
-
# Then run
|
|
44
47
|
siigo-mcp
|
|
45
48
|
```
|
|
46
49
|
|
|
47
|
-
### Option 3: Local Development/Building from Source
|
|
48
|
-
1. Clone this repository:
|
|
49
|
-
```bash
|
|
50
|
-
git clone https://github.com/jdlar/siigo-mcp-server.git
|
|
51
|
-
cd siigo-mcp-server
|
|
52
|
-
```
|
|
53
|
-
|
|
54
|
-
2. Install dependencies:
|
|
50
|
+
### Option 3: Local Development / Building from Source
|
|
55
51
|
```bash
|
|
52
|
+
git clone https://github.com/jdlar1/siigo-mcp.git
|
|
53
|
+
cd siigo-mcp
|
|
56
54
|
npm install
|
|
57
|
-
```
|
|
58
|
-
|
|
59
|
-
3. Build the TypeScript code:
|
|
60
|
-
```bash
|
|
61
55
|
npm run build
|
|
62
|
-
```
|
|
63
|
-
|
|
64
|
-
4. Set up environment variables by copying the example file:
|
|
65
|
-
```bash
|
|
66
56
|
cp .env.example .env
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
5. Edit `.env` with your Siigo credentials:
|
|
70
|
-
```bash
|
|
71
|
-
SIIGO_USERNAME=your_siigo_username
|
|
72
|
-
SIIGO_ACCESS_KEY=your_siigo_access_key
|
|
73
|
-
SIIGO_PARTNER_ID=your_app_name
|
|
74
|
-
SIIGO_BASE_URL=https://api.siigo.com
|
|
57
|
+
# Edit .env with your Siigo credentials
|
|
75
58
|
```
|
|
76
59
|
|
|
77
60
|
## Configuration
|
|
78
61
|
|
|
79
62
|
### Required Environment Variables
|
|
80
63
|
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
64
|
+
| Variable | Description |
|
|
65
|
+
|---|---|
|
|
66
|
+
| `SIIGO_USERNAME` | Your Siigo API username |
|
|
67
|
+
| `SIIGO_ACCESS_KEY` | Your Siigo API access key |
|
|
68
|
+
| `SIIGO_PARTNER_ID` | Partner ID for API identification (3-100 alphanumeric chars, no spaces) |
|
|
84
69
|
|
|
85
70
|
### Optional Environment Variables
|
|
86
71
|
|
|
87
|
-
|
|
72
|
+
| Variable | Default | Description |
|
|
73
|
+
|---|---|---|
|
|
74
|
+
| `SIIGO_BASE_URL` | `https://api.siigo.com` | API base URL |
|
|
88
75
|
|
|
89
76
|
### Getting Siigo API Credentials
|
|
90
77
|
|
|
91
78
|
1. Sign up for a Siigo account at [siigo.com](https://siigo.com)
|
|
92
79
|
2. Access the API section in your Siigo dashboard
|
|
93
80
|
3. Generate your API credentials (username and access key)
|
|
94
|
-
4. For testing,
|
|
95
|
-
|
|
96
|
-
## Usage
|
|
81
|
+
4. For testing, use the sandbox environment
|
|
97
82
|
|
|
98
|
-
|
|
83
|
+
## MCP Client Configuration
|
|
99
84
|
|
|
100
|
-
|
|
101
|
-
```bash
|
|
102
|
-
# Set environment variables and run
|
|
103
|
-
SIIGO_USERNAME=your_username SIIGO_ACCESS_KEY=your_key SIIGO_PARTNER_ID=your_app npx siigo-mcp-server
|
|
104
|
-
```
|
|
85
|
+
### Claude Desktop
|
|
105
86
|
|
|
106
|
-
|
|
107
|
-
```bash
|
|
108
|
-
# Set environment variables and run
|
|
109
|
-
SIIGO_USERNAME=your_username SIIGO_ACCESS_KEY=your_key SIIGO_PARTNER_ID=your_app siigo-mcp
|
|
110
|
-
```
|
|
87
|
+
Add to your Claude Desktop config (`claude_desktop_config.json`):
|
|
111
88
|
|
|
112
|
-
#### For Development (from source)
|
|
113
|
-
```bash
|
|
114
|
-
# Start the server
|
|
115
|
-
npm start
|
|
116
|
-
|
|
117
|
-
# Or for development with auto-reload
|
|
118
|
-
npm run dev
|
|
119
|
-
```
|
|
120
|
-
|
|
121
|
-
### Available Tools
|
|
122
|
-
|
|
123
|
-
The server provides 40+ tools for interacting with the Siigo API. Here are some examples:
|
|
124
|
-
|
|
125
|
-
#### Products
|
|
126
|
-
- `siigo_get_products` - List all products
|
|
127
|
-
- `siigo_get_product` - Get a specific product by ID
|
|
128
|
-
- `siigo_create_product` - Create a new product
|
|
129
|
-
- `siigo_update_product` - Update an existing product
|
|
130
|
-
- `siigo_delete_product` - Delete a product
|
|
131
|
-
- `siigo_search_products` - **NEW!** Search products by code, name, or reference
|
|
132
|
-
|
|
133
|
-
#### Customers
|
|
134
|
-
- `siigo_get_customers` - List all customers
|
|
135
|
-
- `siigo_get_customer` - Get a specific customer by ID
|
|
136
|
-
- `siigo_create_customer` - Create a new customer
|
|
137
|
-
- `siigo_update_customer` - Update an existing customer
|
|
138
|
-
- `siigo_search_customers` - **NEW!** Search customers by identification, name, or type
|
|
139
|
-
|
|
140
|
-
#### Invoices
|
|
141
|
-
- `siigo_get_invoices` - List all invoices
|
|
142
|
-
- `siigo_get_invoice` - Get a specific invoice by ID
|
|
143
|
-
- `siigo_create_invoice` - Create a new invoice
|
|
144
|
-
- `siigo_update_invoice` - Update an existing invoice
|
|
145
|
-
- `siigo_delete_invoice` - Delete an invoice
|
|
146
|
-
- `siigo_get_invoice_pdf` - Get invoice PDF
|
|
147
|
-
- `siigo_send_invoice_email` - Send invoice by email
|
|
148
|
-
|
|
149
|
-
#### Catalogs
|
|
150
|
-
- `siigo_get_document_types` - Get document types
|
|
151
|
-
- `siigo_get_taxes` - Get tax information
|
|
152
|
-
- `siigo_get_payment_types` - Get payment methods
|
|
153
|
-
- `siigo_get_cost_centers` - Get cost centers
|
|
154
|
-
- `siigo_get_users` - Get system users
|
|
155
|
-
|
|
156
|
-
#### Reports
|
|
157
|
-
- `siigo_get_trial_balance` - Generate trial balance report
|
|
158
|
-
- `siigo_get_accounts_payable` - Get accounts payable report
|
|
159
|
-
|
|
160
|
-
### Example Usage
|
|
161
|
-
|
|
162
|
-
#### Search for Customers
|
|
163
89
|
```json
|
|
164
90
|
{
|
|
165
|
-
"
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
91
|
+
"mcpServers": {
|
|
92
|
+
"siigo": {
|
|
93
|
+
"command": "npx",
|
|
94
|
+
"args": ["siigo-mcp-server"],
|
|
95
|
+
"env": {
|
|
96
|
+
"SIIGO_USERNAME": "your_username",
|
|
97
|
+
"SIIGO_ACCESS_KEY": "your_access_key",
|
|
98
|
+
"SIIGO_PARTNER_ID": "your_app_name"
|
|
99
|
+
}
|
|
100
|
+
}
|
|
170
101
|
}
|
|
171
102
|
}
|
|
172
103
|
```
|
|
173
104
|
|
|
174
|
-
|
|
105
|
+
## Available Tools (68 total)
|
|
106
|
+
|
|
107
|
+
### Products (6 tools)
|
|
108
|
+
| Tool | Description | Annotations |
|
|
109
|
+
|---|---|---|
|
|
110
|
+
| `siigo_get_products` | List products with pagination | read-only |
|
|
111
|
+
| `siigo_get_product` | Get a product by ID | read-only |
|
|
112
|
+
| `siigo_create_product` | Create product (supports **Combo** type with components) | |
|
|
113
|
+
| `siigo_update_product` | Update a product | |
|
|
114
|
+
| `siigo_delete_product` | Delete a product | destructive |
|
|
115
|
+
| `siigo_search_products` | Search by code, name, or reference (partial match) | read-only |
|
|
116
|
+
|
|
117
|
+
### Account Groups / Inventory Categories (3 tools)
|
|
118
|
+
| Tool | Description | Annotations |
|
|
119
|
+
|---|---|---|
|
|
120
|
+
| `siigo_get_account_groups` | List inventory categories | read-only |
|
|
121
|
+
| `siigo_create_account_group` | Create inventory category | |
|
|
122
|
+
| `siigo_update_account_group` | Update inventory category | |
|
|
123
|
+
|
|
124
|
+
### Customers (5 tools)
|
|
125
|
+
| Tool | Description | Annotations |
|
|
126
|
+
|---|---|---|
|
|
127
|
+
| `siigo_get_customers` | List customers | read-only |
|
|
128
|
+
| `siigo_get_customer` | Get a customer by ID | read-only |
|
|
129
|
+
| `siigo_create_customer` | Create a customer/third party | |
|
|
130
|
+
| `siigo_update_customer` | Update a customer | |
|
|
131
|
+
| `siigo_search_customers` | Search by identification, name, or type | read-only |
|
|
132
|
+
|
|
133
|
+
### Invoices (10 tools)
|
|
134
|
+
| Tool | Description | Annotations |
|
|
135
|
+
|---|---|---|
|
|
136
|
+
| `siigo_get_invoices` | List invoices with date filters | read-only |
|
|
137
|
+
| `siigo_get_invoice` | Get an invoice by ID | read-only |
|
|
138
|
+
| `siigo_create_invoice` | Create invoice (supports **healthcare** and **transport** sectors) | |
|
|
139
|
+
| `siigo_update_invoice` | Update an invoice | |
|
|
140
|
+
| `siigo_delete_invoice` | Delete an invoice | destructive |
|
|
141
|
+
| `siigo_annul_invoice` | Annul (void) an invoice | destructive |
|
|
142
|
+
| `siigo_get_invoice_pdf` | Get invoice PDF (base64) | read-only |
|
|
143
|
+
| `siigo_get_invoice_xml` | Get invoice electronic XML (base64) | read-only |
|
|
144
|
+
| `siigo_get_invoice_stamp_errors` | Get DIAN rejection errors | read-only |
|
|
145
|
+
| `siigo_send_invoice_email` | Send invoice by email (up to 5 addresses) | |
|
|
146
|
+
|
|
147
|
+
### Batch Invoices (1 tool)
|
|
148
|
+
| Tool | Description | Annotations |
|
|
149
|
+
|---|---|---|
|
|
150
|
+
| `siigo_create_invoice_batch` | Create invoices in batch (async with webhook notification) | |
|
|
151
|
+
|
|
152
|
+
### Quotations (5 tools)
|
|
153
|
+
| Tool | Description | Annotations |
|
|
154
|
+
|---|---|---|
|
|
155
|
+
| `siigo_get_quotations` | List quotations with date filters | read-only |
|
|
156
|
+
| `siigo_get_quotation` | Get a quotation by ID | read-only |
|
|
157
|
+
| `siigo_create_quotation` | Create a quotation (document type C) | |
|
|
158
|
+
| `siigo_update_quotation` | Update a quotation | |
|
|
159
|
+
| `siigo_delete_quotation` | Delete a quotation | destructive |
|
|
160
|
+
|
|
161
|
+
### Credit Notes (4 tools)
|
|
162
|
+
| Tool | Description | Annotations |
|
|
163
|
+
|---|---|---|
|
|
164
|
+
| `siigo_get_credit_notes` | List credit notes | read-only |
|
|
165
|
+
| `siigo_get_credit_note` | Get a credit note by ID | read-only |
|
|
166
|
+
| `siigo_create_credit_note` | Create credit note (supports **healthcare** sector, external invoice refs) | |
|
|
167
|
+
| `siigo_get_credit_note_pdf` | Get credit note PDF (base64) | read-only |
|
|
168
|
+
|
|
169
|
+
### Vouchers / Cash Receipts (3 tools)
|
|
170
|
+
| Tool | Description | Annotations |
|
|
171
|
+
|---|---|---|
|
|
172
|
+
| `siigo_get_vouchers` | List cash receipts (recibos de caja) | read-only |
|
|
173
|
+
| `siigo_get_voucher` | Get a cash receipt by ID | read-only |
|
|
174
|
+
| `siigo_create_voucher` | Create cash receipt (DebtPayment, AdvancePayment, Advanced) | |
|
|
175
|
+
|
|
176
|
+
### Purchases (5 tools)
|
|
177
|
+
| Tool | Description | Annotations |
|
|
178
|
+
|---|---|---|
|
|
179
|
+
| `siigo_get_purchases` | List purchase invoices | read-only |
|
|
180
|
+
| `siigo_get_purchase` | Get a purchase by ID | read-only |
|
|
181
|
+
| `siigo_create_purchase` | Create purchase (use FC type with `document_support` for Documento Soporte) | |
|
|
182
|
+
| `siigo_update_purchase` | Update a purchase | |
|
|
183
|
+
| `siigo_delete_purchase` | Delete a purchase | destructive |
|
|
184
|
+
|
|
185
|
+
### Payment Receipts / Disbursements (5 tools)
|
|
186
|
+
| Tool | Description | Annotations |
|
|
187
|
+
|---|---|---|
|
|
188
|
+
| `siigo_get_payment_receipts` | List payment receipts (recibos de pago / comprobantes de egreso) | read-only |
|
|
189
|
+
| `siigo_get_payment_receipt` | Get a payment receipt by ID | read-only |
|
|
190
|
+
| `siigo_create_payment_receipt` | Create payment receipt (DebtPayment, AdvancePayment, Advanced) | |
|
|
191
|
+
| `siigo_update_payment_receipt` | Update a payment receipt | |
|
|
192
|
+
| `siigo_delete_payment_receipt` | Delete a payment receipt | destructive |
|
|
193
|
+
|
|
194
|
+
### Journals / Accounting Entries (3 tools)
|
|
195
|
+
| Tool | Description | Annotations |
|
|
196
|
+
|---|---|---|
|
|
197
|
+
| `siigo_get_journals` | List accounting journals (comprobantes contables) | read-only |
|
|
198
|
+
| `siigo_get_journal` | Get a journal by ID | read-only |
|
|
199
|
+
| `siigo_create_journal` | Create journal entry (debits must equal credits) | |
|
|
200
|
+
|
|
201
|
+
### Webhooks (4 tools)
|
|
202
|
+
| Tool | Description | Annotations |
|
|
203
|
+
|---|---|---|
|
|
204
|
+
| `siigo_get_webhooks` | List webhook subscriptions | read-only |
|
|
205
|
+
| `siigo_create_webhook` | Subscribe to a webhook event | |
|
|
206
|
+
| `siigo_update_webhook` | Update a webhook subscription | |
|
|
207
|
+
| `siigo_delete_webhook` | Delete a webhook subscription | destructive |
|
|
208
|
+
|
|
209
|
+
### Catalogs (11 tools + account groups above)
|
|
210
|
+
| Tool | Description |
|
|
211
|
+
|---|---|
|
|
212
|
+
| `siigo_get_document_types` | Document types (FV, RC, NC, FC, CC, RP, C) |
|
|
213
|
+
| `siigo_get_taxes` | Taxes (IVA, Retefuente, ReteIVA, ReteICA, etc.) |
|
|
214
|
+
| `siigo_get_payment_types` | Payment methods |
|
|
215
|
+
| `siigo_get_cost_centers` | Cost centers |
|
|
216
|
+
| `siigo_get_users` | Users/sellers |
|
|
217
|
+
| `siigo_get_warehouses` | Warehouses |
|
|
218
|
+
| `siigo_get_price_lists` | Price lists (up to 12) |
|
|
219
|
+
| `siigo_get_cities` | Colombian cities |
|
|
220
|
+
| `siigo_get_id_types` | Identification types |
|
|
221
|
+
| `siigo_get_fiscal_responsibilities` | Fiscal responsibilities |
|
|
222
|
+
| `siigo_get_fixed_assets` | Fixed assets |
|
|
223
|
+
|
|
224
|
+
### Reports (3 tools)
|
|
225
|
+
| Tool | Description |
|
|
226
|
+
|---|---|
|
|
227
|
+
| `siigo_get_trial_balance` | Trial balance report (Excel) |
|
|
228
|
+
| `siigo_get_trial_balance_by_third` | Trial balance by third party (Excel) |
|
|
229
|
+
| `siigo_get_accounts_payable` | Accounts payable report |
|
|
230
|
+
|
|
231
|
+
## Document Types Reference
|
|
232
|
+
|
|
233
|
+
| Code | Spanish Name | English Name | MCP Support |
|
|
234
|
+
|---|---|---|---|
|
|
235
|
+
| `FV` | Factura de Venta | Sales Invoice | Full CRUD + PDF/XML/Email/Batch/Annul |
|
|
236
|
+
| `RC` | Recibo de Caja | Cash Receipt | Create + Query |
|
|
237
|
+
| `NC` | Nota Credito | Credit Note | Create + Query + PDF |
|
|
238
|
+
| `FC` | Factura de Compra | Purchase Invoice | Full CRUD |
|
|
239
|
+
| `CC` | Comprobante Contable | Accounting Journal | Create + Query |
|
|
240
|
+
| `RP` | Recibo de Pago/Egreso | Payment Receipt | Full CRUD |
|
|
241
|
+
| `C` | Cotizacion | Quotation | Full CRUD |
|
|
242
|
+
|
|
243
|
+
## Example Usage
|
|
244
|
+
|
|
245
|
+
### Create a Quotation
|
|
175
246
|
```json
|
|
176
247
|
{
|
|
177
|
-
"name": "
|
|
248
|
+
"name": "siigo_create_quotation",
|
|
178
249
|
"arguments": {
|
|
179
|
-
"
|
|
180
|
-
|
|
250
|
+
"quotation": {
|
|
251
|
+
"document": { "id": 12345 },
|
|
252
|
+
"date": "2026-02-13",
|
|
253
|
+
"customer": { "identification": "13832081", "branch_office": 0 },
|
|
254
|
+
"seller": 629,
|
|
255
|
+
"items": [{
|
|
256
|
+
"code": "PROD001",
|
|
257
|
+
"quantity": 5,
|
|
258
|
+
"price": 50000,
|
|
259
|
+
"taxes": [{ "id": 13156 }]
|
|
260
|
+
}]
|
|
261
|
+
}
|
|
181
262
|
}
|
|
182
263
|
}
|
|
183
264
|
```
|
|
184
265
|
|
|
185
|
-
|
|
266
|
+
### Create a Combo Product
|
|
186
267
|
```json
|
|
187
268
|
{
|
|
188
269
|
"name": "siigo_create_product",
|
|
189
270
|
"arguments": {
|
|
190
271
|
"product": {
|
|
191
|
-
"code": "
|
|
192
|
-
"name": "
|
|
272
|
+
"code": "COMBO-001",
|
|
273
|
+
"name": "Kit de oficina",
|
|
193
274
|
"account_group": 1253,
|
|
194
|
-
"type": "
|
|
195
|
-
"
|
|
196
|
-
|
|
275
|
+
"type": "Combo",
|
|
276
|
+
"components": [
|
|
277
|
+
{ "code": "PROD-001", "quantity": 2 },
|
|
278
|
+
{ "code": "PROD-002", "quantity": 1 }
|
|
279
|
+
]
|
|
197
280
|
}
|
|
198
281
|
}
|
|
199
282
|
}
|
|
200
283
|
```
|
|
201
284
|
|
|
202
|
-
|
|
285
|
+
### Create a Healthcare Invoice
|
|
203
286
|
```json
|
|
204
287
|
{
|
|
205
|
-
"name": "
|
|
288
|
+
"name": "siigo_create_invoice",
|
|
206
289
|
"arguments": {
|
|
207
|
-
"
|
|
208
|
-
"
|
|
209
|
-
"
|
|
210
|
-
"identification": "
|
|
211
|
-
"
|
|
212
|
-
"
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
},
|
|
220
|
-
"phones": [{"number": "1234567890"}],
|
|
221
|
-
"contacts": [{
|
|
222
|
-
"first_name": "John",
|
|
223
|
-
"last_name": "Doe",
|
|
224
|
-
"email": "john@example.com"
|
|
225
|
-
}]
|
|
290
|
+
"invoice": {
|
|
291
|
+
"document": { "id": 24446 },
|
|
292
|
+
"date": "2026-02-13",
|
|
293
|
+
"customer": { "identification": "13832081" },
|
|
294
|
+
"seller": 629,
|
|
295
|
+
"items": [{ "code": "SRV001", "quantity": 1, "price": 150000 }],
|
|
296
|
+
"payments": [{ "id": 5636, "value": 150000 }],
|
|
297
|
+
"healthcare_company": {
|
|
298
|
+
"operation_type": "SS-CUFE",
|
|
299
|
+
"period_start": "2026-01-01",
|
|
300
|
+
"period_end": "2026-01-31"
|
|
301
|
+
}
|
|
226
302
|
}
|
|
227
303
|
}
|
|
228
304
|
}
|
|
229
305
|
```
|
|
230
306
|
|
|
307
|
+
### Create Batch Invoices
|
|
308
|
+
```json
|
|
309
|
+
{
|
|
310
|
+
"name": "siigo_create_invoice_batch",
|
|
311
|
+
"arguments": {
|
|
312
|
+
"notification_url": "https://myapp.com/webhooks/siigo-batch",
|
|
313
|
+
"invoices": [
|
|
314
|
+
{
|
|
315
|
+
"idempotency_key": "INV202602001",
|
|
316
|
+
"document": { "id": 24446 },
|
|
317
|
+
"date": "2026-02-13",
|
|
318
|
+
"customer": { "identification": "13832081" },
|
|
319
|
+
"seller": 629,
|
|
320
|
+
"items": [{ "code": "PROD001", "quantity": 1, "price": 50000 }],
|
|
321
|
+
"payments": [{ "id": 5636, "value": 50000 }]
|
|
322
|
+
}
|
|
323
|
+
]
|
|
324
|
+
}
|
|
325
|
+
}
|
|
326
|
+
```
|
|
327
|
+
|
|
231
328
|
## API Rate Limits
|
|
232
329
|
|
|
233
|
-
|
|
234
|
-
-
|
|
235
|
-
- Sandbox: 10 requests per minute
|
|
330
|
+
- **Production**: 100 requests per minute per company
|
|
331
|
+
- **Sandbox**: 10 requests per minute
|
|
236
332
|
|
|
237
|
-
|
|
333
|
+
The server uses a 120-second HTTP timeout as recommended by Siigo for long-running operations.
|
|
238
334
|
|
|
239
|
-
|
|
335
|
+
## Error Handling
|
|
240
336
|
|
|
241
|
-
-
|
|
242
|
-
- Invalid parameters
|
|
243
|
-
- Rate limit exceeded
|
|
244
|
-
- Resource not found
|
|
245
|
-
- Validation errors
|
|
337
|
+
The server handles Siigo API errors and returns structured error responses with error codes, messages, and details. See the [Siigo API docs](https://siigoapi.docs.apiary.io/#introduction/codigos-de-error) for a full list of error codes.
|
|
246
338
|
|
|
247
339
|
## Development
|
|
248
340
|
|
|
@@ -251,12 +343,13 @@ The server handles various Siigo API errors and returns structured error respons
|
|
|
251
343
|
```
|
|
252
344
|
siigo-mcp/
|
|
253
345
|
├── src/
|
|
254
|
-
│ ├── index.ts #
|
|
255
|
-
│ ├── siigo-client.ts # Siigo API
|
|
256
|
-
│ └── types.ts # TypeScript
|
|
346
|
+
│ ├── index.ts # MCP server - tool registration with Zod schemas
|
|
347
|
+
│ ├── siigo-client.ts # HTTP client for all Siigo API endpoints
|
|
348
|
+
│ └── types.ts # Full TypeScript interfaces for all document types
|
|
349
|
+
├── dist/ # Compiled output (ESM)
|
|
257
350
|
├── package.json
|
|
258
351
|
├── tsconfig.json
|
|
259
|
-
├── .
|
|
352
|
+
├── CHANGELOG.md
|
|
260
353
|
└── README.md
|
|
261
354
|
```
|
|
262
355
|
|
|
@@ -266,10 +359,10 @@ siigo-mcp/
|
|
|
266
359
|
npm run build
|
|
267
360
|
```
|
|
268
361
|
|
|
269
|
-
###
|
|
362
|
+
### Running for Development
|
|
270
363
|
|
|
271
364
|
```bash
|
|
272
|
-
npm
|
|
365
|
+
npm run dev
|
|
273
366
|
```
|
|
274
367
|
|
|
275
368
|
## Contributing
|
|
@@ -277,7 +370,7 @@ npm test
|
|
|
277
370
|
1. Fork the repository
|
|
278
371
|
2. Create a feature branch
|
|
279
372
|
3. Make your changes
|
|
280
|
-
4.
|
|
373
|
+
4. Run `npm run build` to verify
|
|
281
374
|
5. Submit a pull request
|
|
282
375
|
|
|
283
376
|
## License
|
|
@@ -286,12 +379,12 @@ MIT License
|
|
|
286
379
|
|
|
287
380
|
## Support
|
|
288
381
|
|
|
289
|
-
|
|
290
|
-
-
|
|
291
|
-
- This MCP server: Create an issue in this repository
|
|
382
|
+
- **Siigo API**: Contact soporteapi@siigo.com
|
|
383
|
+
- **This MCP server**: [Create an issue](https://github.com/jdlar1/siigo-mcp/issues)
|
|
292
384
|
|
|
293
385
|
## Links
|
|
294
386
|
|
|
295
387
|
- [Siigo API Documentation](https://siigoapi.docs.apiary.io/)
|
|
296
388
|
- [Model Context Protocol](https://modelcontextprotocol.io/)
|
|
297
|
-
- [
|
|
389
|
+
- [MCP TypeScript SDK](https://www.npmjs.com/package/@modelcontextprotocol/sdk)
|
|
390
|
+
- [Siigo Official Website](https://siigo.com/)
|