@acruxcoreai/mcp-server 0.0.0-stage → 0.1.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/CHANGELOG.md ADDED
@@ -0,0 +1,46 @@
1
+ # Changelog
2
+
3
+ All notable changes to `@acruxcoreai/mcp-server` are documented here.
4
+
5
+ The format follows [Keep a Changelog](https://keepachangelog.com/en/1.1.0/), and this
6
+ package follows [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
7
+
8
+ ## 0.1.0 — 2026-10-18
9
+
10
+
11
+ First release.
12
+
13
+ ### Added
14
+
15
+ - **Model Context Protocol server for AcruxCore**, shipped two ways: a stdio binary
16
+ (`npx @acruxcoreai/mcp-server`) and a hosted Streamable HTTP endpoint at
17
+ `POST /api/v1/mcp` on any AcruxCore instance. Both register the same tools, so a tool
18
+ added once appears on both.
19
+ - **28 tools across five toolsets.** `prompts` — `list_prompts`, `get_prompt`,
20
+ `render_prompt`, `diff_prompt_versions`, `create_prompt`, `commit_prompt_version`,
21
+ `promote_prompt_alias`. `gateway` — `run_prompt`, `chat_completion`, `list_models`,
22
+ `get_gateway_usage`. `tools` — `list_catalog_tools`, `get_catalog_tool`,
23
+ `sync_catalog_tool`, `execute_catalog_tool`. `traces` — `search_traces`, `get_trace`,
24
+ `get_trace_analytics`, `list_sessions`, `get_session`, `submit_trace_feedback`.
25
+ `evaluations` — `list_datasets`, `get_dataset`, `create_dataset`,
26
+ `add_dataset_example`, `run_experiment`, `list_experiment_runs`, `get_experiment_run`.
27
+ - **Registry prompts as MCP prompts.** Every prompt in the team's registry is exposed
28
+ through MCP's prompts primitive at the `production` alias, with the version's template
29
+ variables as typed arguments. `ACRUXCORE_MCP_PROMPT_ALIAS` selects a different alias.
30
+ - **`acruxcore://` resources.** `acruxcore://prompts/{name}/{alias}` reads back the raw,
31
+ unrendered template of the version an alias points at;
32
+ `acruxcore://traces/{traceId}` reads one trace with its full span tree.
33
+ - **Names work wherever ids do.** Any tool taking a prompt or a catalog tool accepts the
34
+ name or the UUID, and an unknown name comes back as a `NOT_FOUND` listing the closest
35
+ matches rather than a silent near-miss.
36
+ - **`--read-only` removes mutating tools from the listing** rather than refusing them
37
+ when called, so a model cannot choose a tool it never sees.
38
+ - **`--toolsets`** narrows the surface to any subset of the five.
39
+ - Configuration by environment variable or CLI flag, the flag winning:
40
+ `ACRUXCORE_API_KEY`, `ACRUXCORE_BASE_URL`, `ACRUXCORE_MCP_TOOLSETS`,
41
+ `ACRUXCORE_MCP_READ_ONLY`, `ACRUXCORE_MCP_PROMPT_ALIAS`,
42
+ `ACRUXCORE_MCP_MAX_TEXT_BYTES`, `ACRUXCORE_MCP_TIMEOUT_MS`.
43
+ - **`initialize` instructions follow the registered tools.** A `--read-only` server
44
+ tells the model the connection is read-only and never names a tool it lacks.
45
+ - **`diff_prompt_versions` says when two versions have identical messages**, and points
46
+ to `get_prompt` for comparing the bound models and settings.
package/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 AcruxCore
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 CHANGED
@@ -1,3 +1,118 @@
1
- # Temporary Holding Version
1
+ # @acruxcoreai/mcp-server
2
2
 
3
- This version is a temporary placeholder for this package. An operational version to replace this has been submitted for review and is awaiting a staged release.
3
+ The [Model Context Protocol](https://modelcontextprotocol.io) server for
4
+ [AcruxCore](https://acruxcore.com). It turns the platform — the prompt registry, the
5
+ versioned tool catalog, the AI gateway, tracing and evaluation — into tools any MCP
6
+ client can call, so an assistant can operate AcruxCore instead of being told which HTTP
7
+ endpoints to hit.
8
+
9
+ It also exposes your team's **registry prompts as MCP prompts**, so the prompts your
10
+ production traffic renders show up in the client as ready-to-use templates, with the
11
+ template variables as typed arguments.
12
+
13
+ ## Two ways to connect
14
+
15
+ **Hosted — nothing to install.** Point an MCP client that supports remote servers at
16
+ your AcruxCore instance:
17
+
18
+ ```
19
+ https://api.acruxcore.com/api/v1/mcp
20
+ ```
21
+
22
+ with an `Authorization: Bearer acx_sk_…` header. Create the key in the dashboard under
23
+ **Settings → API keys**.
24
+
25
+ **Local — stdio.** For clients that only speak stdio, or when you want to narrow the
26
+ tool surface:
27
+
28
+ ```jsonc
29
+ {
30
+ "mcpServers": {
31
+ "acruxcore": {
32
+ "command": "npx",
33
+ "args": ["-y", "@acruxcoreai/mcp-server"],
34
+ "env": {
35
+ "ACRUXCORE_API_KEY": "acx_sk_…",
36
+ "ACRUXCORE_BASE_URL": "https://api.acruxcore.com/api/v1"
37
+ }
38
+ }
39
+ }
40
+ }
41
+ ```
42
+
43
+ In Claude Code, one command does the same thing:
44
+
45
+ ```bash
46
+ claude mcp add acruxcore -e ACRUXCORE_API_KEY=acx_sk_… -- npx -y @acruxcoreai/mcp-server
47
+ ```
48
+
49
+ For a full walkthrough with a real Claude Code session, see
50
+ [Connect Claude to AcruxCore with MCP](https://docs.acruxcore.com/docs/guides/connect-an-mcp-client).
51
+ The endpoint reference is at
52
+ [docs.acruxcore.com/api-reference/mcp](https://docs.acruxcore.com/api-reference/mcp).
53
+
54
+ ## Configuration
55
+
56
+ Every option is an environment variable or a CLI flag; the flag wins.
57
+
58
+ | Env | Flag | Default | Meaning |
59
+ |---|---|---|---|
60
+ | `ACRUXCORE_API_KEY` | `--api-key` | *required* | Your `acx_sk_…` key. |
61
+ | `ACRUXCORE_BASE_URL` | `--base-url` | `https://api.acruxcore.com/api/v1` | Self-hosting? Point it at your instance. `/api/v1` is appended if you leave it off. |
62
+ | `ACRUXCORE_MCP_TOOLSETS` | `--toolsets` | all | Comma-separated: `prompts`, `gateway`, `tools`, `traces`, `evaluations`. |
63
+ | `ACRUXCORE_MCP_READ_ONLY` | `--read-only` | `false` | Drop every mutating tool from the listing. |
64
+ | `ACRUXCORE_MCP_PROMPT_ALIAS` | `--prompt-alias` | `production` | Which alias the prompts primitive exposes. |
65
+ | `ACRUXCORE_MCP_MAX_TEXT_BYTES` | `--max-text-bytes` | `40000` | Cap on the size of any single tool result. |
66
+ | `ACRUXCORE_MCP_TIMEOUT_MS` | `--timeout-ms` | `60000` | Per-request HTTP timeout. |
67
+
68
+ ### Read-only mode
69
+
70
+ `--read-only` removes the mutating tools from `tools/list` entirely rather than refusing
71
+ them when called. A tool that is absent cannot be chosen by mistake and cannot be talked
72
+ into running — which is the point of handing an agent a key it should not write with.
73
+
74
+ ## Tools
75
+
76
+ **Prompts** — `list_prompts`, `get_prompt`, `render_prompt`, `diff_prompt_versions`,
77
+ `create_prompt`, `commit_prompt_version`, `promote_prompt_alias`
78
+
79
+ **Gateway** — `run_prompt`, `chat_completion`, `list_models`, `get_gateway_usage`
80
+
81
+ **Tool catalog** — `list_catalog_tools`, `get_catalog_tool`, `sync_catalog_tool`,
82
+ `execute_catalog_tool`
83
+
84
+ **Traces** — `search_traces`, `get_trace`, `get_trace_analytics`, `list_sessions`,
85
+ `get_session`, `submit_trace_feedback`
86
+
87
+ **Evaluations** — `list_datasets`, `get_dataset`, `create_dataset`,
88
+ `add_dataset_example`, `run_experiment`, `list_experiment_runs`, `get_experiment_run`
89
+
90
+ Anywhere a tool takes a prompt or a catalog tool, a **name works as well as a UUID**.
91
+
92
+ ## Prompts and resources
93
+
94
+ Registry prompts appear through MCP's prompts primitive at the configured alias, with
95
+ their template variables as arguments. MCP has no system role, so a template's system
96
+ message is carried through as the leading `user` message with its text unchanged.
97
+
98
+ Two resource templates are registered:
99
+
100
+ - `acruxcore://prompts/{name}/{alias}` — the raw, unrendered template of the version an
101
+ alias points at.
102
+ - `acruxcore://traces/{traceId}` — one trace with its full span tree.
103
+
104
+ ## The model behind the tools
105
+
106
+ Three ideas explain nearly every tool here:
107
+
108
+ - A **prompt** is a named container. It holds no messages itself.
109
+ - A **version** is an immutable commit of that prompt's messages, numbered sequentially.
110
+ - An **alias** — `production`, `staging`, anything else — is a moving pointer at one
111
+ version.
112
+
113
+ Committing a version never moves an alias. `promote_prompt_alias` is what ships a
114
+ change, and promoting an earlier version number is how you roll back.
115
+
116
+ ## License
117
+
118
+ MIT
package/dist/bin.d.mts ADDED
@@ -0,0 +1 @@
1
+ #!/usr/bin/env node
package/dist/bin.d.ts ADDED
@@ -0,0 +1 @@
1
+ #!/usr/bin/env node