@jinshuju/mcp 0.4.0 → 0.5.0

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  # @jinshuju/mcp
2
2
 
3
3
  The MCP server for Jinshuju ([jinshuju.net](https://jinshuju.net)): lets Claude, Cursor, Claude Code and other MCP-capable AI tools read and write forms, tables and entries.
4
- The tools are generated from the [open API v1 openapi.yaml](https://jinshuju.net/api/v1/openapi.yaml) and stay in step with the API; the tool set matches the tools documented for the [Jinshuju MCP Server](https://open.jinshuju.net/mcp) one to one.
4
+ The tools are generated from the [open API v1 openapi.yaml](https://jinshuju.net/api/v1/openapi.yaml) and stay in step with the API.
5
5
 
6
6
  Two ways to use it:
7
7
 
@@ -49,7 +49,7 @@ To check it works, ask the assistant to "list my Jinshuju forms".
49
49
 
50
50
  ## Tools
51
51
 
52
- The 60 tools documented for the [Jinshuju MCP Server](https://open.jinshuju.net/mcp), with the same names, plus delete_form. Each tool maps to one operation in openapi.yaml; a few combine two operations:
52
+ Each tool maps to one operation in openapi.yaml; a few combine two operations:
53
53
 
54
54
  | Category | Tools |
55
55
  | ------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
@@ -62,11 +62,16 @@ The 60 tools documented for the [Jinshuju MCP Server](https://open.jinshuju.net/
62
62
  | Tables | list_tables, get_table, create_table, edit_table, move_table |
63
63
  | Public queries | list_opensearch_queries, get_opensearch_query, create_opensearch_query, edit_opensearch_query, get_opensearch_field_suggestions |
64
64
  | Folders / account | list_folders, create_folder, get_current_user, get_current_billing_account, list_account_users |
65
- | Uploads | upload_entry_attachment, upload_form_image, upload_import_file |
65
+ | Uploads | prepare_entry_attachment_upload, prepare_form_image_upload, prepare_import_file_upload, upload_entry_attachment, upload_form_image, upload_import_file |
66
66
  | Schemas | get_schema (reads an openapi schema by name, e.g. FieldInput, TextFieldInput) |
67
67
 
68
68
  The full tool → operation mapping is in `mcp.overlay.yaml` and `src/generated/meta.json`.
69
69
 
70
+ **Uploads.** A file on disk goes through `prepare_*_upload`, which returns a one-time `upload_url` (valid 30 minutes);
71
+ the client posts the file to it itself (`curl -F file=@<path> <upload_url>`), so its bytes never pass through the model, then uses the returned `attachment_id`.
72
+ That needs a client with a shell that can reach jinshuju.net, such as Claude Code, Cursor or Codex.
73
+ `upload_*` carry the file as Base64 inside the tool call, which only suits small content the model has in hand.
74
+
70
75
  **Size.** The full tools/list is about 39k tokens (o200k estimate; about 36k without outputSchema).
71
76
  It stays that size by not inlining large schemas: field definitions (52 types), form settings, themes and the like become a one-line pointer; unions that branch on type, such as table columns, keep only their common properties.
72
77
  The model reads them on demand with `get_schema("FieldInput")` / `get_schema("TextFieldInput")`.
@@ -2,11 +2,11 @@
2
2
  "generatedFrom": {
3
3
  "title": "Jinshuju API v1",
4
4
  "version": "1.0",
5
- "sha256": "ecaf2b639eaf7555"
5
+ "sha256": "aecc3bef9088dcc7"
6
6
  },
7
7
  "baseUrl": "https://jinshuju.net/api/v1",
8
- "toolCount": 61,
9
- "operationCount": 129,
8
+ "toolCount": 64,
9
+ "operationCount": 176,
10
10
  "tools": {
11
11
  "list_forms": "listForms",
12
12
  "get_form": "getForm",
@@ -60,6 +60,9 @@
60
60
  "get_current_user": "getCurrentUser",
61
61
  "get_current_billing_account": "getBillingAccount",
62
62
  "list_account_users": "listBillingAccountUsers",
63
+ "prepare_entry_attachment_upload": "prepareEntryAttachmentUpload",
64
+ "prepare_form_image_upload": "prepareFormImageUpload",
65
+ "prepare_import_file_upload": "prepareImportFileUpload",
63
66
  "upload_entry_attachment": "uploadEntryAttachment",
64
67
  "upload_form_image": "uploadFormImage",
65
68
  "upload_import_file": "uploadImportFile",
@@ -71,24 +74,26 @@
71
74
  "count_entries": "countEntries+countEntriesAcrossForms"
72
75
  },
73
76
  "pointerSchemas": [
74
- "BillingAccount",
75
- "EntryData",
76
- "EvaluationSetting",
77
- "EvaluationSettingInput",
78
- "FieldDefinition",
79
77
  "FieldInput",
80
78
  "FieldUpdateInput",
81
- "FormSetting",
82
- "FormSettingInput",
79
+ "FieldDefinition",
83
80
  "FormSettingWriteInput",
81
+ "FormSettingInput",
82
+ "FormSetting",
83
+ "ThemeInput",
84
84
  "FormTheme",
85
- "FormView",
85
+ "EvaluationSettingInput",
86
+ "EvaluationSetting",
86
87
  "FormViewInput",
87
- "GoodsItemInput",
88
- "OpensearchQuery",
88
+ "FormView",
89
89
  "OpensearchQueryInput",
90
- "ThemeInput",
91
- "TradeMerchant"
90
+ "OpensearchQuery",
91
+ "GoodsItemInput",
92
+ "EntryData",
93
+ "TradeMerchant",
94
+ "BillingAccount",
95
+ "ExamFieldInput",
96
+ "EvaluationFieldInput"
92
97
  ],
93
98
  "omitSchemas": [
94
99
  "FormCreateConstraints"
@@ -97,7 +102,7 @@
97
102
  "Forms": "Forms: list, structure, create and edit, plus field display rules, cooperators, copy, move and other related operations.",
98
103
  "Form Settings": "Form settings: submission settings, access policy, Webhook, theme, closing rules, exam / evaluation scene settings.",
99
104
  "Plugins": "Plugin center plugins (check-in for now). A plugin campaign is bound to one form, and only its creator can see and change it. The account must have enabled the plugin in the plugin center, or the request returns 402.",
100
- "Entries": "Form entries: list, query, create, update, delete and batch operations.",
105
+ "Entries": "Form entries: list, query, create, update, delete and batch operations, and sending SMS / email to entries.",
101
106
  "Tables": "Tables (kind=table): structure and entries; field types are limited to the column types tables support.",
102
107
  "Views": "Form / table views (view filters, sort, column configuration) and reading entries through a view.",
103
108
  "Comments": "Entry comments.",
@@ -107,9 +112,10 @@
107
112
  "Predefined Choices Sets": "Predefined choice sets.",
108
113
  "Templates": "Using templates.",
109
114
  "Contacts": "Contacts.",
110
- "Account": "Current user and account: members, e-invoices, payment history, SMS signature review status.",
115
+ "Account": "Current user and account: members, e-invoices, payment history, SMS signatures and templates, SMTP accounts.",
111
116
  "Trade": "小金商户: merchant and onboarding progress, payment orders, transaction statistics, refunds and payouts.",
112
- "Uploads": "Uploading attachments, form images and import files.",
113
- "Utilities": "Utility endpoints."
117
+ "Uploads": "Uploading attachments, form images, license images and import files.",
118
+ "Utilities": "Utility endpoints.",
119
+ "Routines": "Routines (`自动任务`): instructions Jiri carries out as you, on a schedule or when data changes, and their runs. The rules and messages are those of the routines page; times are in Beijing time (+08:00). OAuth tokens need the `routines` scope. As routines run unattended and spend AI points, self-registered clients cannot get it; only a registered application with `routines` among its scopes (such as the Jinshuju CLI) can ask for it."
114
120
  }
115
121
  }