qyl-mcp-server 11.1.4 → 17.0.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.
Files changed (110) hide show
  1. package/README.md +154 -159
  2. package/dist/analysis-client.d.ts +2 -2
  3. package/dist/analysis-client.js +1 -2
  4. package/dist/analysis-client.js.map +1 -1
  5. package/dist/analysis-summary.js +4 -2
  6. package/dist/analysis-summary.js.map +1 -1
  7. package/dist/analysis-tools.js +44 -72
  8. package/dist/analysis-tools.js.map +1 -1
  9. package/dist/ci.js +3 -3
  10. package/dist/ci.js.map +1 -1
  11. package/dist/collector-resources.d.ts +1 -1
  12. package/dist/collector-resources.js +5 -12
  13. package/dist/collector-resources.js.map +1 -1
  14. package/dist/collector.d.ts +6 -5
  15. package/dist/collector.js +16 -17
  16. package/dist/collector.js.map +1 -1
  17. package/dist/config.d.ts +4 -8
  18. package/dist/config.js +7 -11
  19. package/dist/config.js.map +1 -1
  20. package/dist/contract-handshake.d.ts +45 -58
  21. package/dist/contract-handshake.js +80 -106
  22. package/dist/contract-handshake.js.map +1 -1
  23. package/dist/contracts/generated/api.d.ts +2078 -0
  24. package/dist/contracts/generated/api.js +244 -0
  25. package/dist/contracts/generated/api.js.map +1 -0
  26. package/dist/contracts/generated/definitions.d.ts +310 -0
  27. package/dist/contracts/generated/definitions.js +2 -0
  28. package/dist/contracts/generated/definitions.js.map +1 -0
  29. package/dist/contracts/generated/headers.d.ts +12 -0
  30. package/dist/contracts/generated/headers.js +15 -0
  31. package/dist/contracts/generated/headers.js.map +1 -0
  32. package/dist/contracts/generated/tool-schemas.json +25515 -0
  33. package/dist/contracts/tool-schemas.d.ts +32 -0
  34. package/dist/contracts/tool-schemas.js +43 -0
  35. package/dist/contracts/tool-schemas.js.map +1 -0
  36. package/dist/contracts/unix-nanos.d.ts +4 -0
  37. package/dist/contracts/unix-nanos.js +14 -0
  38. package/dist/contracts/unix-nanos.js.map +1 -0
  39. package/dist/data.d.ts +1 -1
  40. package/dist/data.js +1 -2
  41. package/dist/data.js.map +1 -1
  42. package/dist/events.d.ts +1 -1
  43. package/dist/events.js +1 -1
  44. package/dist/events.js.map +1 -1
  45. package/dist/main.d.ts +0 -1
  46. package/dist/main.js +16 -30
  47. package/dist/main.js.map +1 -1
  48. package/dist/mcp-semconv.d.ts +9 -20
  49. package/dist/mcp-semconv.js +21 -62
  50. package/dist/mcp-semconv.js.map +1 -1
  51. package/dist/metrics-tools.js +7 -7
  52. package/dist/metrics-tools.js.map +1 -1
  53. package/dist/native-execution.d.ts +9 -10
  54. package/dist/native-execution.js +48 -63
  55. package/dist/native-execution.js.map +1 -1
  56. package/dist/oauth.d.ts +1 -1
  57. package/dist/oauth.js +2 -2
  58. package/dist/oauth.js.map +1 -1
  59. package/dist/request-scope.d.ts +5 -1
  60. package/dist/request-scope.js +8 -0
  61. package/dist/request-scope.js.map +1 -1
  62. package/dist/server.d.ts +1 -17
  63. package/dist/server.js +8 -142
  64. package/dist/server.js.map +1 -1
  65. package/dist/skills/qyl-investigate/SKILL.md +6 -9
  66. package/dist/skills.js +4 -5
  67. package/dist/skills.js.map +1 -1
  68. package/dist/stderr-log.d.ts +7 -2
  69. package/dist/stderr-log.js +7 -4
  70. package/dist/stderr-log.js.map +1 -1
  71. package/dist/summaries.js +1 -1
  72. package/dist/summaries.js.map +1 -1
  73. package/dist/telemetry.d.ts +2 -10
  74. package/dist/telemetry.js +20 -105
  75. package/dist/telemetry.js.map +1 -1
  76. package/dist/tool-scopes.d.ts +1 -1
  77. package/dist/tool-scopes.js +1 -1
  78. package/dist/tools.js +9 -9
  79. package/dist/tools.js.map +1 -1
  80. package/dist/wire.d.ts +3 -7
  81. package/dist/wire.js +3 -3
  82. package/dist/wire.js.map +1 -1
  83. package/dist/write-tools.d.ts +3 -3
  84. package/dist/write-tools.js +20 -28
  85. package/dist/write-tools.js.map +1 -1
  86. package/package.json +20 -57
  87. package/dist/contract-headers.d.ts +0 -28
  88. package/dist/contract-headers.js +0 -38
  89. package/dist/contract-headers.js.map +0 -1
  90. package/dist/contract-validation.d.ts +0 -190
  91. package/dist/contract-validation.js +0 -332
  92. package/dist/contract-validation.js.map +0 -1
  93. package/dist/execution-evidence.d.ts +0 -13
  94. package/dist/execution-evidence.js +0 -81
  95. package/dist/execution-evidence.js.map +0 -1
  96. package/dist/execution-result.d.ts +0 -5
  97. package/dist/execution-result.js +0 -17
  98. package/dist/execution-result.js.map +0 -1
  99. package/dist/mcp-app.html +0 -161
  100. package/dist/mcp-dashboard.html +0 -166
  101. package/dist/mcp-home.html +0 -195
  102. package/dist/observability-suppression.d.ts +0 -8
  103. package/dist/observability-suppression.js +0 -15
  104. package/dist/observability-suppression.js.map +0 -1
  105. package/dist/trace-query.d.ts +0 -5
  106. package/dist/trace-query.js +0 -8
  107. package/dist/trace-query.js.map +0 -1
  108. package/dist/ui-domain.d.ts +0 -4
  109. package/dist/ui-domain.js +0 -32
  110. package/dist/ui-domain.js.map +0 -1
package/README.md CHANGED
@@ -1,70 +1,38 @@
1
1
  # qyl-mcp-server
2
2
 
3
- MCP tools over a live [qyl](https://github.com/ANcpLua/qyl) collector — traces,
4
- logs, metrics, sessions and CI runs, plus the Trace Explorer and MCP Dashboard
5
- viewers for hosts that render MCP Apps.
3
+ MCP tools over a live [qyl](https://github.com/ANcpLua/qyl) Collector — traces, logs, metrics,
4
+ sessions and CI runs — for agents investigating a running system. The Collector computes every
5
+ analysis; this server validates, scopes and frames the calls.
6
6
 
7
7
  ```bash
8
8
  bunx qyl-mcp-server --stdio # stdio MCP server
9
- bunx qyl-mcp-server # Streamable HTTP on 127.0.0.1:3001
9
+ bunx qyl-mcp-server # Streamable HTTP on 127.0.0.1:3001
10
10
  ```
11
11
 
12
- Use a modern or 2025-era MCP client. Point it at a collector:
12
+ `npx` and `pnpm dlx` also work when Bun 1.4 or newer is installed; the executable runs on Bun, the
13
+ library exports `qyl-mcp-server` and `qyl-mcp-server/auth` support Node 24. Point it at a Collector:
13
14
 
14
15
  ```bash
15
16
  export QYL_COLLECTOR_URL=http://127.0.0.1:5100
16
- export QYL_API_KEY='your-collector-key' # omit for an unsecured local collector
17
+ export QYL_API_KEY='your-collector-key' # omit for an unsecured local Collector
17
18
  ```
18
19
 
19
- `QYL_API_KEY` is an *outgoing* collector credential — it does not authenticate
20
- incoming MCP clients, which is why the local server binds to loopback only.
20
+ `QYL_API_KEY` is an *outgoing* Collector credential; it does not authenticate incoming MCP
21
+ clients, which is why the local server binds to loopback only.
21
22
 
22
- There is also a hosted instance at `https://mcp.qyl.at/mcp` needing no install.
23
- It is an OAuth 2.1 resource server, so an unauthenticated request answers `401`
24
- with an RFC 9728 protected-resource document that a stock MCP client follows on
25
- its own.
23
+ The hosted instance is `https://mcp.qyl.at/mcp`. It is an OAuth 2.1 resource server: an
24
+ unauthenticated request answers `401` with an RFC 9728 protected-resource document naming issuer
25
+ `https://qyl-eu.eu.auth0.com/` and scopes `qyl:read qyl:write qyl:delete`, which a stock MCP
26
+ client follows on its own.
26
27
 
27
- Both use MCP TypeScript SDK v2: Streamable HTTP through `createMcpHandler`
28
- and stdio through `serveStdio`, with their documented compatibility defaults.
29
- One factory serves revision `2026-07-28` and supported 2025-era requests.
30
- The HTTP server serves a product page at `/`; `/mcp` is the only protocol
31
- endpoint.
32
-
33
- ## Hosted authentication
34
-
35
- The hosted Auth0 profile requires CIMD and DCR discovery, Authorization Code
36
- with PKCE S256, both `private_key_jwt` and `none` for ChatGPT CIMD compatibility,
37
- `none` for Claude CIMD, and issuer identification. Auth0 owns registration and token
38
- issuance; this server validates resource-bound RFC 9068 access tokens on every
39
- MCP request. It rejects malformed/query credentials, invalid tokens and
40
- insufficient scopes with distinct 400/401/403 responses. Every request needs
41
- `qyl:read`. The initial 401 requests `qyl:read qyl:write qyl:delete` so new
42
- connections can authorize the complete tool set. A write tool called without `qyl:write` or `qyl:delete` gets a
43
- `403` with `error="insufficient_scope"` naming the scopes to request, in both
44
- protocol eras, before the handler runs.
45
-
46
- Optional resource-server integrations are selected explicitly:
47
-
48
- ```sh
49
- MCP_AUTH_EXTENSIONS=enterprise-managed-authorization@1.0.0,oauth-client-credentials@1.0.0
50
- ```
51
-
52
- Enterprise-managed authorization is stable upstream; client credentials is a
53
- draft extension. Both preserve the core token verifier and require matching
54
- Auth0 capabilities and separately provisioned client grants. Integration versions
55
- are independent of the MCP wire version. Embedders can use the exported
56
- `qyl-mcp-server/auth` composition API for additional declarative modules and
57
- explicit scope hierarchies.
58
-
59
- See the [deployment and authentication guide](https://github.com/ANcpLua/qyl.mcp#authentication)
60
- for Auth0 configuration, extension responsibilities, and verification. Auth0
61
- requires Enterprise for `private_key_jwt`. Neither a provider capability flag nor
62
- an enabled module proves a client has been provisioned.
28
+ Both use MCP TypeScript SDK v2: Streamable HTTP through `createMcpHandler` and stdio through
29
+ `serveStdio`. One factory serves revision `2026-07-28` and negotiates down for 2025-era clients
30
+ that send `initialize`. The HTTP server answers `/mcp`, `/healthz`, the OAuth discovery documents
31
+ and `/.well-known/openai-apps-challenge`; every other path, `/` included, is `404`.
63
32
 
64
33
  ## Tools
65
34
 
66
- The server publishes 32 tools, including one app-only read tool. Reads use the collector's
67
- analysis queries and the generated qyl API contracts.
35
+ The committed [`tool-manifest.snapshot.json`](tool-manifest.snapshot.json) is the tool contract.
68
36
 
69
37
  | Purpose | Tools |
70
38
  | --- | --- |
@@ -73,90 +41,116 @@ analysis queries and the generated qyl API contracts.
73
41
  | Read executions | `list_sessions`, `list_traces`, `get_trace`, `search_logs`, `ci_log` |
74
42
  | Read metrics | `list_metrics`, `get_metric_series`, `query_metric` |
75
43
  | Saved questions | `list_saved_queries`, `run_saved_query` |
76
- | Interactive views | `display_traces`, `display_mcp_dashboard`, `fetch_telemetry` (app-only) |
77
- | Write project records | `create_annotation`, `update_annotation`, `create_saved_query`, `update_saved_query`, `delete`, `update_failure_status` |
78
-
79
- Read tools accept an absolute RFC 3339 time window or `lookback_minutes` and report the
80
- resolved `window` and `coverage`: examined, matched and returned counts, truncation,
81
- scan completeness and observation time. Unknown counts are null. Filtering happens before
82
- pagination; reuse an opaque `next_cursor` with the same filters to continue a page.
83
-
84
- Shared matchers support `eq`, `neq`, `in`, `prefix`, `contains`, `exists`, `gt`, `gte`,
85
- `lt` and `lte`, with span, resource or log scope. Span durations are milliseconds;
86
- metrics retain their recorded units. Histogram percentiles identify their approximation,
87
- and cumulative counter changes account for resets. Verification reports insufficient
88
- traffic as pending rather than calling an unobserved failure fixed.
89
-
90
- `get_trace` supports all spans, errors, errors with ancestors, or the critical path,
91
- selected attributes and correlated logs. `display_traces` preserves the selected span
92
- and can compare two executions. Notes and bookmarks are created only through explicit
93
- viewer actions. `display_mcp_dashboard` uses the same MCP aggregates as `get_mcp_stats`,
94
- shows the numerator and denominator behind rates, classifies failures, and opens matching
95
- calls from aggregate selections. `fetch_telemetry` serves five app-only views: traces,
96
- trace, logs, MCP statistics and comparison, with incremental refresh and field selection.
97
-
98
- The 26 read tools carry `readOnlyHint: true`. Six write tools change annotations, saved
99
- queries or failure status in the caller's project. An annotation can target a trace, span,
100
- session or failure and has optional labels and a classification. A bookmark is a note
101
- labelled `bookmark`. Updates and deletes require the current `etag`; stale writes are
102
- rejected. Create calls reuse the stored result for 24 hours. Without an explicit
103
- `idempotency_key`, the server derives one from the project, operation and request
104
- body, so identical retries are safe. Supply a different key to deliberately create
105
- another identical record. No tool edits or deletes recorded telemetry.
44
+ | Write project records | `create_annotation`, `update_annotation`, `create_saved_query`, `update_saved_query`, `delete_record`, `update_failure_status` |
45
+
46
+ Read tools accept an absolute RFC 3339 time window or `lookback_minutes` and report the resolved
47
+ `window` and `coverage`: examined, matched and returned counts, truncation, scan completeness and
48
+ observation time. Unknown counts are null. Filtering happens before pagination; reuse an opaque
49
+ `next_cursor` with the same filters to continue a page. Shared matchers support `eq`, `neq`, `in`,
50
+ `prefix`, `contains`, `exists`, `gt`, `gte`, `lt` and `lte`, with span, resource or log scope. Span
51
+ durations are milliseconds; metrics keep their recorded units. Histogram percentiles identify their
52
+ approximation, cumulative counter changes account for resets, and verification reports
53
+ insufficient traffic as pending rather than calling an unobserved failure fixed.
54
+
55
+ `get_trace` returns all spans, errors, errors with ancestors, or the critical path, with selected
56
+ attributes and correlated logs. `ci_log` reads telemetry from any CI following its emitter
57
+ convention; `service_prefix` defaults to `qyl-ci`. `get_mcp_stats` reports MCP request totals, the
58
+ numerator and denominator behind rates, failure classes, the window's 60 time buckets, per-tool
59
+ requests, errors and latency, and simultaneous server, transport and method breakdowns. The `qyl-investigate` skill says which
60
+ tool to start with; the server serves it through the MCP skills extension (`skills/list`,
61
+ `skills/get`, `skill://qyl/qyl-investigate/SKILL.md`), and the build copies it from `skills/` into
62
+ `dist/skills`.
63
+
64
+ Every read tool carries `readOnlyHint: true`. The write tools change only records in the caller's
65
+ Collector project: annotations (plain-text notes of at most 2000 characters on a trace, span,
66
+ session or failure, with optional labels; a bookmark is a note labelled `bookmark`), saved queries
67
+ (named filters for traces, logs or metrics) and the status of recorded failures (`open`,
68
+ `resolved`, `ignored`, assignee, ignore-until). `delete_record` removes one annotation or saved
69
+ query (`kind` is `annotation` or `saved_query`). Updates and deletes send the current `etag` as
70
+ `If-Match`: a stale etag is refused with `precondition_failed`, a duplicate saved-query name with
71
+ `conflict`. Create calls reuse the stored result for 24 hours; without an explicit
72
+ `idempotency_key` the server derives one from the project, operation and request body. No tool
73
+ edits or deletes recorded telemetry; retention alone removes it.
106
74
 
107
75
  `qyl:read` covers reads, `qyl:write` adds creation and updates, and `qyl:delete` permits
108
- `delete`. A missing scope returns the supported OAuth step-up challenge. Failed calls
109
- carry a stable code, retryability, the problem type and field-level validation details
110
- when available. Secrets are redacted before model text or structured content is returned.
111
-
112
- Every tool runs inside its request scope, forwarding cancellation to the collector.
113
- Requested progress reports completion; no logging notifications are sent to clients.
114
- Analysis reads require a live collector. Synthetic data is used only by test fixtures, and is never substituted when a collector fails.
115
-
116
- Every inbound `tools/call` on a local server — `--stdio`, or HTTP without
117
- `MCP_PUBLIC_URL` — records only its tool name, timing, status and error type,
118
- plus a server-generated execution ID, atomically in
119
- `~/.qyl/mcp-native-executions.json`. Arguments, request metadata, result bodies
120
- and error messages are not retained. Known version-1/2 files are reduced to
121
- this format on load; unreadable files still use the existing archive recovery
122
- path, and pre-existing archives are not purged. A public deployment (`MCP_PUBLIC_URL` set)
123
- records nothing to disk; that evidence file is a local developer artifact, not a
124
- multi-tenant audit log.
76
+ `delete_record`. A missing scope returns the OAuth step-up challenge `403`
77
+ `insufficient_scope` naming the scopes to request, in both protocol eras, before the handler runs.
78
+ Failed calls carry a stable code, retryability, the problem type and field-level validation
79
+ details when available. Secrets are redacted before model text, structured content or durable
80
+ evidence. Every tool runs inside its request scope, forwarding cancellation to the Collector;
81
+ requested progress reports completion. Analysis reads require a live Collector; synthetic data
82
+ exists only in test fixtures.
83
+
84
+ ## Hosted authentication
85
+
86
+ The hosted Auth0 profile is **CIMD or DCR + OAuth 2.1 Authorization Code with PKCE S256 + issuer
87
+ identification**. ChatGPT's client metadata advertises `none` and `private_key_jwt` and uses the
88
+ latter; Claude's CIMD is a public client using `none`. Auth0 owns registration and token issuance;
89
+ the server validates resource-bound RFC 9068 access tokens (signature, issuer, resource audience,
90
+ expiry and scopes) on every MCP request and rejects malformed or query credentials, invalid tokens
91
+ and insufficient scopes with distinct `400`/`401`/`403` responses. Only the qyl production Auth0
92
+ issuer is accepted. `/.well-known/oauth-protected-resource/mcp` and
93
+ `/.well-known/oauth-protected-resource` describe the same `/mcp` resource.
94
+
95
+ Operating a hosted deployment:
96
+
97
+ 1. Register the resource audience `<public-url>/mcp`, RS256 access tokens and the permissions
98
+ `qyl:read`, `qyl:write` and `qyl:delete`.
99
+ 2. Provision each client through its current CIMD document or DCR, keeping its actual callback and
100
+ authentication method. When DCR is enabled, set `dynamic_client_registration_security_mode` to
101
+ `strict`; the DCR endpoint is open to registration, so keep third-party API default permissions
102
+ empty.
103
+ 3. `qyl:read` exposes traces, logs, metrics, sessions and CI evidence; grant it only to intended
104
+ clients and users. `qyl:write` and `qyl:delete` reach only annotations, saved queries and failure
105
+ status in the caller's project, and the Collector key the server uses needs the Collector's
106
+ `write` and `delete` roles.
107
+ 4. Configure `MCP_PUBLIC_URL`, `MCP_BIND_HOST`, allowed hosts and origins, and the Collector URL and
108
+ key. Non-loopback serving requires a public URL and hosted authorization.
109
+
110
+ `eng/auth0` in the repository records and reconciles the tenant's API scopes, named client grants
111
+ and mapped-user permissions.
112
+
113
+ Optional authorization extensions are selected explicitly:
114
+
115
+ ```sh
116
+ MCP_AUTH_EXTENSIONS=enterprise-managed-authorization@1.0.0,oauth-client-credentials@1.0.0
117
+ ```
118
+
119
+ `enterprise-managed-authorization@1.0.0` is stable and needs the JWT bearer and ID-JAG grant
120
+ profile; `oauth-client-credentials@1.0.0` is a draft and needs client credentials with
121
+ `private_key_jwt` (Auth0 Enterprise). Unknown versions and conflicting provider requirements are
122
+ rejected; neither replaces the core verifier. Embedders compose further modules through
123
+ `qyl-mcp-server/auth`.
124
+
125
+ The alternative `MCP_AUTH_PROVIDER=cloudflare-access` mode (with `MCP_ACCESS_TEAM_DOMAIN`,
126
+ `MCP_ACCESS_AUD` and `MCP_PUBLIC_URL`) validates `Cf-Access-Jwt-Assertion`: issuer, application
127
+ audience, expiry and subject, with RS256 signatures. Its assertion carries no qyl scopes, so it
128
+ grants the read tools only, and Auth0-backed Events cannot be enabled in it.
125
129
 
126
130
  ## Configuration
127
131
 
128
132
  | Variable | Meaning |
129
133
  | --- | --- |
130
- | `QYL_COLLECTOR_URL` | Collector read API base; default `http://127.0.0.1:5100`. Also the OTLP base when set. |
131
- | `QYL_API_KEY` | Collector credential for reads and OTLP; the write tools need the Collector's `write` and `delete` roles on it. Outgoing only. |
132
- | `QYL_PROJECT` | Server-owned collector project scope. Unset, the server sends no project-scope header, so the Collector's default project applies. Never accepted as tool input. This is the only place that states the default; other documents link here. |
133
- | `MCP_COLLECTOR_PROJECTS` | Optional secret JSON mapping validated Auth0 subjects to project-bound Collector keys; see account isolation below. |
134
- | `QYL_OTLP_ENDPOINT` | Optional OTLP base for self-telemetry. |
135
- | `QYL_MCP_TELEMETRY=0` | Disable MCP spans, metrics, and operation logs. |
136
- | `QYL_MCP_CAPTURE_CONTENT=1` | Workbench content capture; native incoming tool-call telemetry never supplies request or response bodies. |
137
- | `QYL_MCP_NATIVE_STATE_PATH` | Override the native execution-evidence path. |
138
- | `MCP_EVENTS_STORE` | Optional internal Events subscription file; leave unset for the shared ChatGPT/Claude deployment. |
139
- | `MCP_EVENTS_AUTH0_CLIENT_ID` / `MCP_EVENTS_AUTH0_CLIENT_SECRET` | Dedicated Management API application with `read:users`, `read:clients`, `read:client_grants`, `read:grants`; resolves CIMD identities and keeps access checks current without storing subscriber tokens. |
140
- | `MCP_EVENTS_POLL_MS` | Collector polling interval, at least 5000 ms; default 30000 ms. |
141
- | `PORT` | HTTP listener port; default `3001`. |
142
-
143
- Secrets are redacted before results reach the model, structured content, or
144
- durable evidence.
145
-
146
- `npx` and `pnpm dlx` also work when Bun 1.4 or newer is installed.
147
- Both the HTTP and stdio executables use Bun 1.4 or newer.
148
-
149
- ### Account isolation for hosted Auth0
150
-
151
- The existing tenant's API scopes, named client grants and mapped-user permissions
152
- are managed by [the Auth0 configuration and drift checker](https://github.com/ANcpLua/qyl.mcp/tree/main/tools/auth0).
153
- Run its check before applying changes; it preserves unrelated tenant configuration
154
- and never creates identities or rotates credentials.
155
-
156
- To give a reviewer access to sample data, provision a separate Collector
157
- project/key through the Collector's `QYL_OTLP_PROJECT_KEYS` configuration and
158
- assign that key to the reviewer's validated Auth0 subject. Configure the MCP
159
- service's secret `MCP_COLLECTOR_PROJECTS` with this shape (placeholder values):
134
+ | `QYL_COLLECTOR_URL` | Collector base URL; default `http://127.0.0.1:5100`. Also the OTLP base when set. |
135
+ | `QYL_API_KEY` | Collector credential for reads and OTLP; the write tools need its `write` and `delete` roles. Outgoing only. |
136
+ | `QYL_PROJECT` | Server-owned Collector project scope. Unset, the server sends no project header and the Collector's default project applies. Never accepted as tool input. |
137
+ | `MCP_COLLECTOR_PROJECTS` | Optional secret JSON mapping verified Auth0 subjects to project-bound Collector keys (below). |
138
+ | `MCP_PUBLIC_URL` | Public base URL of a hosted deployment; sets the resource audience and the canonical `/mcp` URL and disables the local execution record. |
139
+ | `MCP_BIND_HOST`, `PORT` | Listener address and port; default `127.0.0.1:3001`. |
140
+ | `MCP_ALLOWED_HOSTS`, `MCP_ALLOWED_ORIGIN_HOSTS` | Comma-separated request and browser-origin hostnames added to the public URL's hostname. |
141
+ | `MCP_AUTH_PROVIDER`, `MCP_AUTH_EXTENSIONS` | Authorization mode and optional extensions (above). |
142
+ | `MCP_EVENTS_STORE` | Persistent Events subscription file; unset disables Events. |
143
+ | `MCP_EVENTS_AUTH0_CLIENT_ID`, `MCP_EVENTS_AUTH0_CLIENT_SECRET` | Management API application with `read:users`, `read:clients`, `read:client_grants`, `read:grants`; resolves CIMD identities and keeps Events access checks current without storing subscriber tokens. |
144
+ | `MCP_EVENTS_POLL_MS` | Collector polling interval for Events, at least 5000 ms; default 30000 ms. |
145
+ | `OPENAI_APPS_CHALLENGE` | Text served at `/.well-known/openai-apps-challenge`; `404` while blank. |
146
+ | `QYL_OTLP_ENDPOINT` | Optional OTLP base for self-telemetry; signal-specific `OTEL_*` endpoints take precedence. |
147
+ | `QYL_MCP_TELEMETRY=0` | Disable MCP spans, metrics and operation logs. |
148
+ | `QYL_MCP_NATIVE_STATE_PATH` | Location of the local execution record; default `~/.qyl/mcp-native-executions.json`. |
149
+
150
+ With `MCP_COLLECTOR_PROJECTS` set, only the verified SDK `AuthInfo.extra.subject` selects the
151
+ project; tool inputs and request metadata cannot override it. An enabled map rejects unmapped
152
+ callers and never falls back to `QYL_API_KEY`; missing, malformed, duplicate or conflicting entries
153
+ fail validation. It needs the hosted Auth0 configuration. Shape (placeholder values):
160
154
 
161
155
  ```json
162
156
  [
@@ -165,38 +159,39 @@ service's secret `MCP_COLLECTOR_PROJECTS` with this shape (placeholder values):
165
159
  ]
166
160
  ```
167
161
 
168
- Include every account that should retain access, including the owner. An
169
- enabled map rejects unmapped callers and never falls back to `QYL_API_KEY`.
170
- Missing, malformed, duplicate or conflicting entries fail validation. The
171
- feature requires the hosted Auth0 configuration; local stdio and Cloudflare
172
- Access deployments cannot enable this map. When the variable is absent, the
173
- existing deployment-wide credential behavior is retained.
174
-
175
- Only the verified SDK `AuthInfo.extra.subject` selects the project. Tool inputs
176
- and request metadata cannot override it. Telemetry tools, viewer refreshes and
177
- tool-call OTLP exports use that account's project credential. Export pipelines
178
- are bounded by the configured projects; an unassigned caller gets no fallback
179
- export destination. Project
180
- keys are redacted from text and structured results, including keys nested in
181
- this JSON configuration. Keep the map in host secrets and out of the plugin ZIP.
182
-
183
- `bun run smoke:projects` from the repository root checks every tool, the
184
- writes included, viewer query paths and both protocol eras against a
185
- real local Collector with two temporary projects. It reuses the completed Release
186
- build; set `QYL_COLLECTOR_DLL` for another build. The script uses local test identities
187
- and an in-process signed webhook receiver.
188
-
189
- ### Seeded analysis verification
190
-
191
- `bun run --cwd server test:answer-key` starts a fresh temporary collector database,
192
- seeds real OTLP, and runs the 32 analysis checks through MCP and generated validators.
193
- It reuses the collector's completed build; set `QYL_COLLECTOR_DLL` when its location
194
- or configuration differs. `mise run check` includes this verification and the quiet
195
- SSE check. No pre-existing temporary file or manually seeded database is required.
196
-
197
- `QYL_BIN=/path/to/installed/qyl node live-tools-smoke.mjs` additionally checks
198
- all 32 tools against an isolated collector started by the published CLI.
162
+ Tool-call OTLP exports use the mapped project's credential; an unassigned caller gets no fallback
163
+ export destination. Project keys are redacted from text and structured results.
164
+
165
+ ## MCP Events
166
+
167
+ On authenticated Auth0 deployments with `MCP_EVENTS_STORE`, clients can subscribe to `trace.error`,
168
+ optionally filtered by `service_name`. The server verifies callbacks, signs deliveries, checks
169
+ ongoing authorization, expires subscriptions and cancels delivery on unsubscribe or confirmed
170
+ revocation. Subscription state is bounded and holds no OAuth tokens or copied telemetry.
171
+
172
+ ## Execution records and telemetry
173
+
174
+ A local server (`--stdio`, or HTTP without `MCP_PUBLIC_URL`) records each inbound `tools/call` —
175
+ tool name, timing, status, error type and a server-generated ID, never arguments, metadata, result
176
+ bodies or error messages — atomically in the execution record, keeping the latest 1,000. A hosted
177
+ deployment records nothing to disk. A completed or failed record that cannot be written never
178
+ changes the call's outcome: the tool's result or error is returned, a structured `warn` line goes
179
+ to stderr and the operation span carries `error.type=evidence_persistence_failed`; a record that
180
+ cannot be written before the tool runs refuses the call. OTLP exports carry operation timing,
181
+ status and trace correlation, without argument or result bodies.
182
+
183
+ ## Checks
184
+
185
+ From `services/qyl.mcp` after `bun install --frozen-lockfile && bun run build`:
186
+ `bun run test:built` (unit tests), `bun run smoke` (stdio transport), `bun run smoke:quiet`
187
+ (an 18-second quiet response over HTTP), `bun run test:answer-key` (seeded OTLP through a fresh
188
+ Collector, then every analysis check through MCP) and `bun run smoke:projects` (two real
189
+ Collector projects, every tool, both protocol eras). The last two use the Collector's Release
190
+ build in `artifacts/bin/qyl.collector/release/`; `QYL_COLLECTOR_DLL` selects another build.
191
+ `QYL_BIN=/path/to/qyl bun run smoke:live` calls every tool against a Collector started by an
192
+ installed qyl tool. `mise run hosted-eval` checks the hosted server with a real login
193
+ ([eval/](eval/)).
199
194
 
200
195
  ## Release notes
201
196
 
202
- In the repository's [CHANGELOG.md](https://github.com/ANcpLua/qyl.mcp/blob/main/CHANGELOG.md).
197
+ [CHANGELOG.md](https://github.com/ANcpLua/qyl/blob/main/CHANGELOG.md)
@@ -1,5 +1,5 @@
1
1
  /** Shared HTTP transport; every callable analysis operation is registered by name. */
2
2
  import type { CallToolResult } from "@modelcontextprotocol/server";
3
- import type * as z from "zod/v4";
3
+ import type { ContractSchemaName } from "./contracts/tool-schemas.js";
4
4
  import type { ToolScope } from "./request-scope.js";
5
- export declare function queryAnalysis<Input extends object, Output extends object>(operation: string, input: Input, schema: z.ZodType<Output>, scope: ToolScope): Promise<CallToolResult>;
5
+ export declare function queryAnalysis<Input extends object>(operation: string, input: Input, schema: ContractSchemaName, scope: ToolScope): Promise<CallToolResult>;
@@ -26,8 +26,7 @@ export async function queryAnalysis(operation, input, schema, scope) {
26
26
  const page = output;
27
27
  const originalPoints = operation === "get_metric_series" && typeof args.series_id === "string";
28
28
  const points = page.points;
29
- const traceView = operation === "get_trace" || operation === "fetch_telemetry" && args.view === "trace";
30
- const sizeKey = originalPoints ? "points_limit" : traceView ? "max_spans" : operation === "query_metric" ? "series_limit" : operation === "get_agent_run" ? "max_steps" : "limit";
29
+ const sizeKey = originalPoints ? "points_limit" : operation === "get_trace" ? "max_spans" : operation === "query_metric" ? "series_limit" : operation === "get_agent_run" ? "max_steps" : "limit";
31
30
  const trace = page.trace;
32
31
  const observed = page.observed;
33
32
  const sizes = [trace?.spans?.length, observed?.error_spans?.length, observed?.logs?.length,
@@ -1 +1 @@
1
- {"version":3,"file":"analysis-client.js","sourceRoot":"","sources":["../src/analysis-client.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,cAAc,EAAE,aAAa,EAAE,kBAAkB,EAAE,MAAM,gBAAgB,CAAC;AACnF,OAAO,EAAE,uBAAuB,EAAE,qBAAqB,EAAE,aAAa,EAAE,MAAM,sBAAsB,CAAC;AACrG,OAAO,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AAExD,OAAO,EAAE,mBAAmB,EAAE,MAAM,0BAA0B,CAAC;AAE/D,MAAM,CAAC,KAAK,UAAU,aAAa,CACjC,SAAiB,EACjB,KAAY,EACZ,MAAyB,EACzB,KAAgB;IAEhB,MAAM,IAAI,GAAG,oBAAoB,SAAS,EAAE,CAAC;IAC7C,MAAM,QAAQ,GAAG,IAAI,CAAC,GAAG,EAAE,GAAG,MAAM,CAAC;IACrC,IAAI,KAAK,GAAW,KAAK,CAAC;IAC1B,IAAI,gBAAgB,GAAG,QAAQ,CAAC;IAChC,SAAS,CAAC;QACR,MAAM,SAAS,GAAG,QAAQ,GAAG,IAAI,CAAC,GAAG,EAA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CAAC,IAAI,CAAC,SAAS,CAAC,CAAC,SAAS,CAAC;YAC5I,MAAM,IAAI,cAAc,CACtB,gGAAgG,KAAK,+CAA+C,EACpJ,KAAK,EAAE,SAAS,EAAE,oBAAoB,CACvC,CAAC;QACJ,CAAC;QACD,MAAM,KAAK,CAAC,IAAI,CAAC,WAAW,SAAS,4BAA4B,CAAC,CAAC;QACnE,OAAO,qBAAqB,CAAC,SAAS,EAAE,MAAM,CAAC,CAAC;IAClD,CAAC;AACH,CAAC"}
@@ -19,7 +19,7 @@ export function analysisSummary(operation, output) {
19
19
  if (data[key] !== undefined)
20
20
  lines.push(`${key}: ${short(data[key])}`);
21
21
  }
22
- const totals = record(data.totals ?? record(data.stats).totals);
22
+ const totals = record(data.totals);
23
23
  if (totals.requests !== undefined)
24
24
  lines.push(`${short(totals.errors)} errors / ${short(totals.requests)} requests; p95 ${short(totals.p95_ms)} ms.`);
25
25
  const trace = record(data.trace);
@@ -28,7 +28,9 @@ export function analysisSummary(operation, output) {
28
28
  const cause = record(record(data.observed).root_cause_span);
29
29
  if (cause.name)
30
30
  lines.push(`Recorded failure: ${short(cause.service)} / ${short(cause.name)} — ${short(record(cause.exception).message ?? cause.status)}`);
31
- const collections = ["failures", "regressions", "groups", "steps", "traces", "sessions", "logs", "items", "attributes", "releases", "nodes", "runs", "phases", "saved_queries"];
31
+ if (typeof data.span_count_analyzed === "number")
32
+ lines.push(`${data.span_count_analyzed} MCP spans analyzed${data.truncated === true ? " from an incomplete scan" : ""}.`);
33
+ const collections = ["failures", "regressions", "groups", "tools", "steps", "traces", "sessions", "logs", "items", "attributes", "releases", "nodes", "runs", "phases", "saved_queries"];
32
34
  let evidence = 0;
33
35
  for (const field of collections) {
34
36
  const rows = data[field];
@@ -1 +1 @@
1
- {"version":3,"file":"analysis-summary.js","sourceRoot":"","sources":["../src/analysis-summary.ts"],"names":[],"mappings":"AAAA,qFAAqF;AACrF,MAAM,UAAU,eAAe,CAAC,SAAiB,EAAE,MAAc;IA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