@buun_group/plotwork-mcp 0.0.0 → 0.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/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 Buun Group
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md ADDED
@@ -0,0 +1,149 @@
1
+ # Plotwork MCP server
2
+
3
+ The Plotwork diagram tools as a local MCP (Model Context Protocol) server. An AI agent uses it to read the diagram language, validate source, check an outline, and render twenty kinds of diagram, from flow, sequence, and database to Gantt, state, mind map, and treemap as SVG. It runs on your machine over standard input and output.
4
+
5
+ ## TL;DR
6
+
7
+ | Question | Answer |
8
+ |---|---|
9
+ | Does it need an API key? | No. There is no key, no sign-in, and no account. |
10
+ | Does it use the network? | Not by default. Every tool is a pure computation over its arguments, and with nothing set it reads no files, writes none, and makes no network request. Only if you set `PLOTWORK_USAGE` does it count your tool calls, and only if you set it to `share` does it send anything. See [Usage counts](#usage-counts-off-unless-you-turn-them-on). |
11
+ | How do I start it? | `npx -y @buun_group/plotwork-mcp`. Your MCP client runs this command for you. |
12
+ | Which Node version? | Node 22 or newer. |
13
+ | What are the tools? | Workflows that draw a diagram, convert Mermaid, choose icons, and sync a Markdown document in one call, and single steps for fine control. All are read-only. Your client lists them, and the tool reference in the documentation has every name and schema. |
14
+ | Is there a hosted version? | Yes, at `https://mcp.plotwork.dev`. It needs an API key or a browser sign-in. See [the hosted server](#the-hosted-server). |
15
+ | Which licence? | MIT. Code and data from other people keep their own licences, listed in `THIRD-PARTY-NOTICES.md`. See [License](#license). |
16
+
17
+ ## Install
18
+
19
+ Nothing is installed globally. Your client starts the server with `npx`, and `npx` downloads this package on first use.
20
+
21
+ ### Claude Code
22
+
23
+ ```sh
24
+ claude mcp add plotwork -- npx -y @buun_group/plotwork-mcp
25
+ ```
26
+
27
+ Then run `/mcp` in Claude Code and check that `plotwork` is connected and lists the Plotwork tools.
28
+
29
+ ### Cursor
30
+
31
+ Add this to `~/.cursor/mcp.json`:
32
+
33
+ ```json
34
+ {
35
+ "mcpServers": {
36
+ "plotwork": {
37
+ "command": "npx",
38
+ "args": ["-y", "@buun_group/plotwork-mcp"]
39
+ }
40
+ }
41
+ }
42
+ ```
43
+
44
+ ### VS Code
45
+
46
+ Add this to `.vscode/mcp.json`:
47
+
48
+ ```json
49
+ {
50
+ "servers": {
51
+ "plotwork": {
52
+ "type": "stdio",
53
+ "command": "npx",
54
+ "args": ["-y", "@buun_group/plotwork-mcp"]
55
+ }
56
+ }
57
+ }
58
+ ```
59
+
60
+ ### Claude Desktop
61
+
62
+ Add this to `claude_desktop_config.json`, then restart Claude Desktop:
63
+
64
+ ```json
65
+ {
66
+ "mcpServers": {
67
+ "plotwork": {
68
+ "command": "npx",
69
+ "args": ["-y", "@buun_group/plotwork-mcp"]
70
+ }
71
+ }
72
+ }
73
+ ```
74
+
75
+ ### Other clients
76
+
77
+ Any client that starts an MCP server as a local process takes the same two parts: the command `npx` and the arguments `-y @buun_group/plotwork-mcp`.
78
+
79
+ ## Check it by hand
80
+
81
+ ```sh
82
+ npx -y @buun_group/plotwork-mcp --version
83
+ npx -y @buun_group/plotwork-mcp --help
84
+ ```
85
+
86
+ Run with no arguments, `plotwork-mcp` waits for an MCP client on standard input. Standard output carries only protocol messages. One log line per tool call goes to standard error, with the tool, the outcome, the duration, and the size of the arguments. The contents of the arguments are never logged.
87
+
88
+ ## Usage counts (off unless you turn them on)
89
+
90
+ By default the package counts nothing and keeps no file. You can ask it to count how often each tool is used on your own machine, and, separately, to send pseudonymous daily totals to Plotwork so the project can see which tools matter. Both are off until you set `PLOTWORK_USAGE` in the `env` block of your client or in your shell. There is no config file, so nothing is switched on out of sight.
91
+
92
+ | Setting | What it does |
93
+ |---|---|
94
+ | `PLOTWORK_USAGE` unset, empty, or any other value | Off. Nothing is counted, saved, or sent. |
95
+ | `PLOTWORK_USAGE=local` | Counts calls on this device, in one file, `usage.json`. Nothing is sent. |
96
+ | `PLOTWORK_USAGE=share` | Counts the same way, and once a day sends the totals of each finished day. |
97
+ | `DO_NOT_TRACK=1` (or `true`) | Caps the setting at `local`, so nothing is ever sent, whatever else is set. |
98
+ | `PLOTWORK_HOME` | The folder for `usage.json`. The default is `.plotwork` in your home folder. |
99
+
100
+ Only counts are kept. A count is a tool name, the diagram kind the source declared (`flow`, `sequence`, `schema`, or `none`), how the call ended (`ok`, `rejected`, or `error`), and a number, for each UTC day. Diagram source, arguments, names, file paths, error messages, your host name and user name, and the time of day are never counted or sent.
101
+
102
+ What `share` sends is a small JSON body with those counts, a pseudonym for the month (a keyed hash that changes every month, so Plotwork can count active installs in a month but cannot follow one from month to month), the package version, your operating system family, and the Node major version. It carries no cookie, no account, and no key. It never sends today, never follows a redirect, gives up after three seconds, and fails silently.
103
+
104
+ You can look at all of it before you decide:
105
+
106
+ ```sh
107
+ npx -y @buun_group/plotwork-mcp usage # the setting, the counts of the last 30 days, and the next send
108
+ npx -y @buun_group/plotwork-mcp usage preview # the exact request a send would post, or "nothing to send"
109
+ npx -y @buun_group/plotwork-mcp usage reset # delete the file, with its secret and every count
110
+ ```
111
+
112
+ These commands never touch the network.
113
+
114
+ ## The hosted server
115
+
116
+ The hosted server runs the same tools at `https://mcp.plotwork.dev`. Use it when a client cannot start a local process, or when you want one shared endpoint. It is not part of this package, and it asks for a credential.
117
+
118
+ | Way in | Address | Credential |
119
+ |---|---|---|
120
+ | API key | `https://mcp.plotwork.dev/mcp` | Create a key at [app.plotwork.dev](https://app.plotwork.dev) and send it in the `X-API-Key` header. |
121
+ | Browser sign-in (OAuth) | `https://mcp.plotwork.dev/mcp-oauth` | None to copy. Your client opens a browser and you sign in. |
122
+
123
+ The documentation has the exact settings for each client.
124
+
125
+ ## License
126
+
127
+ @buun_group/plotwork-mcp is licensed under the MIT licence. The text is in the file `LICENSE`.
128
+
129
+ The single file `plotwork-mcp.mjs` also contains code and data that other people wrote: the MCP SDK, the zod validation library, the ELK layout engine, icon artwork, and font measurements. Each keeps its own licence. `THIRD-PARTY-NOTICES.md` lists every one with its version, copyright, and the full licence text. The MIT licence of this package does not replace those licences.
130
+
131
+ The package includes the official architecture icons of AWS, Microsoft Azure, Google Cloud, unmodified. They belong to their owners and are **not** covered by the MIT licence. Their terms and the trademark notice are in `THIRD-PARTY-NOTICES.md`.
132
+
133
+ ## About this repository
134
+
135
+ This repository holds the built package that is published to npm, updated by an automated release. A change here is replaced by the next release, so open an issue instead of a pull request. Releases are immutable: a published version is never changed, and a fix is a new version.
136
+
137
+ Each release carries `checksums.txt` with the SHA-256 of every file in the package, including `LICENSE` and `THIRD-PARTY-NOTICES.md`. To check a download:
138
+
139
+ ```sh
140
+ sha256sum --check checksums.txt
141
+ ```
142
+
143
+ ## See also
144
+
145
+ | Link | Why |
146
+ |---|---|
147
+ | [Documentation](https://docs.plotwork.dev) | The diagram language, the tool reference, and client settings |
148
+ | [Issues](https://github.com/plotwork-official/plotwork-mcp/issues) | Report a problem or ask a question |
149
+ | [Security policy](https://github.com/plotwork-official/plotwork-mcp/security/policy) | Report a vulnerability privately |