@casys/mcp-erpnext 3.0.2 → 3.1.0-beta.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/README.md +42 -31
- package/mcp-erpnext.mjs +1799 -493
- package/package.json +1 -1
- package/ui-dist/chart-viewer/index.html +57 -99
- package/ui-dist/doclist-viewer/index.html +43 -82
- package/ui-dist/funnel-viewer/index.html +41 -80
- package/ui-dist/invoice-viewer/index.html +41 -80
- package/ui-dist/kanban-viewer/index.html +41 -80
- package/ui-dist/kpi-viewer/index.html +41 -80
- package/ui-dist/stock-viewer/index.html +41 -80
package/README.md
CHANGED
|
@@ -72,6 +72,11 @@ See the [CHANGELOG](CHANGELOG.md) for the full release history, or the
|
|
|
72
72
|
[latest release](https://github.com/Casys-AI/mcp-erpnext/releases/latest) for
|
|
73
73
|
the current version's highlights.
|
|
74
74
|
|
|
75
|
+
> **3.1 beta preview:** install with `npx -y @casys/mcp-erpnext@next`. The beta
|
|
76
|
+
> remains compatible with the 3.0 tool surface and progressively enables in-view
|
|
77
|
+
> navigation and active context according to the capabilities advertised by the
|
|
78
|
+
> MCP host.
|
|
79
|
+
|
|
75
80
|
## Documentation
|
|
76
81
|
|
|
77
82
|
Organised by what you are doing, following [Diátaxis](https://diataxis.fr):
|
|
@@ -179,43 +184,48 @@ until it exists. See
|
|
|
179
184
|
Seven interactive [MCP Apps](https://github.com/modelcontextprotocol/ext-apps)
|
|
180
185
|
viewers, registered as `ui://mcp-erpnext/{name}`:
|
|
181
186
|
|
|
182
|
-
| Viewer | Description | Interactive Features
|
|
183
|
-
| ---------------- | ---------------------------------------------------------------- |
|
|
184
|
-
| `doclist-viewer` | Generic document table with sort, filter, pagination, CSV export |
|
|
185
|
-
| `invoice-viewer` | Sales/Purchase
|
|
186
|
-
| `stock-viewer` | Stock balance table with color-coded qty badges |
|
|
187
|
-
| `chart-viewer` | Universal chart renderer (12 types via Recharts) |
|
|
188
|
-
| `kanban-viewer` | Read-write kanban for Task, Opportunity, Issue | Drag-and-drop
|
|
189
|
-
| `kpi-viewer` | Big number card with delta, sparkline, trend |
|
|
190
|
-
| `funnel-viewer` | Trapezoid sales funnel with conversion rates |
|
|
191
|
-
|
|
192
|
-
###
|
|
193
|
-
|
|
194
|
-
Viewers
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
- `
|
|
204
|
-
|
|
187
|
+
| Viewer | Description | Interactive Features |
|
|
188
|
+
| ---------------- | ---------------------------------------------------------------- | --------------------------------------------------------------------------------------------- |
|
|
189
|
+
| `doclist-viewer` | Generic document table with sort, filter, pagination, CSV export | Inline details, typed nested navigation, Submit/Cancel, and compact status filters. |
|
|
190
|
+
| `invoice-viewer` | Sales/Purchase documents with parties, items, totals | Item, stock, party, and payment navigation plus guarded Submit/Cancel actions. |
|
|
191
|
+
| `stock-viewer` | Stock balance table with color-coded qty badges | Item details, recent movements, stock charts, and stock-entry navigation. |
|
|
192
|
+
| `chart-viewer` | Universal chart renderer (12 types via Recharts) | Exact point/series navigation and active-context selection across simple and composed charts. |
|
|
193
|
+
| `kanban-viewer` | Read-write kanban for Task, Opportunity, Issue | Drag-and-drop, inline editing, serialized saves, and typed related-document navigation. |
|
|
194
|
+
| `kpi-viewer` | Big number card with delta, sparkline, trend | Number and trend navigation with bounded active-context selection. |
|
|
195
|
+
| `funnel-viewer` | Trapezoid sales funnel with conversion rates | Period-aware stage navigation and bounded active-context selection. |
|
|
196
|
+
|
|
197
|
+
### Navigation and active context
|
|
198
|
+
|
|
199
|
+
Viewers progressively select the best interaction supported by the host:
|
|
200
|
+
|
|
201
|
+
- `serverTools` opens typed list, record, and chart targets inside the current
|
|
202
|
+
viewer through `app.callServerTool()`. Back and breadcrumb navigation restore
|
|
203
|
+
the state of each level.
|
|
204
|
+
- `updateModelContext` lets chart, KPI, and funnel selections join a bounded
|
|
205
|
+
active-context snapshot. The compact context chip keeps up to eight items and
|
|
206
|
+
lets users remove one item or clear them all. The snapshot contains selected
|
|
207
|
+
values, never hidden instructions for the model.
|
|
208
|
+
- `message.text` keeps `app.sendMessage()` as a conversational fallback when
|
|
209
|
+
direct navigation or context replacement is unavailable.
|
|
210
|
+
- Without these capabilities, local inspection remains available and unsupported
|
|
211
|
+
remote actions are omitted.
|
|
212
|
+
|
|
213
|
+
The server supplies typed navigation metadata and the exact `_availableTools`
|
|
214
|
+
allowed for each viewer, so category-filtered deployments do not expose tools
|
|
215
|
+
that are not loaded.
|
|
205
216
|
|
|
206
217
|
### Refresh model
|
|
207
218
|
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
- All other viewers support focus refresh + manual refresh button
|
|
219
|
+
Read-only viewers revalidate on focus and through their refresh control.
|
|
220
|
+
Mutations use an explicit read-only request to fetch committed state; a mutating
|
|
221
|
+
tool is never replayed automatically. Overlapping or stale responses are ignored
|
|
222
|
+
when a newer host payload or mutation has already won.
|
|
213
223
|
|
|
214
224
|
### Building UI viewers
|
|
215
225
|
|
|
216
226
|
```bash
|
|
217
227
|
cd src/ui
|
|
218
|
-
npm
|
|
228
|
+
npm ci
|
|
219
229
|
node build-all.mjs
|
|
220
230
|
```
|
|
221
231
|
|
|
@@ -237,8 +247,9 @@ click, inline detail, and cross-viewer navigation.
|
|
|
237
247
|
- **Manufacturing** — BOMs, Work Orders, and Job Cards.
|
|
238
248
|
- **CRM** — Leads, Opportunities, Contacts, and Campaigns.
|
|
239
249
|
- **Assets** — Assets, Movements, Maintenance records, and Categories.
|
|
240
|
-
- **Operations** — Generic CRUD, native assignment, and
|
|
241
|
-
DocType (`erpnext_doc_*`, `
|
|
250
|
+
- **Operations** — Generic CRUD, native assignment, and attachment listing or
|
|
251
|
+
upload for any DocType (`erpnext_doc_*`, `erpnext_file_list`,
|
|
252
|
+
`erpnext_file_upload`).
|
|
242
253
|
- **Kanban** — Read-write boards for Task, Opportunity, and Issue with
|
|
243
254
|
drag-and-drop.
|
|
244
255
|
- **Analytics** — Charts (bar, area, treemap, radar, scatter, P&L…), KPIs with
|