@langwatch/mcp-server 0.10.1 → 2.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.
- package/.python-version +1 -0
- package/.release-please-shim +1 -1
- package/CHANGELOG.md +75 -0
- package/CONTRIBUTING.md +1 -1
- package/README.md +64 -18
- package/dist/{archive-project-KAZFHR4A.js → archive-project-4EQGLBJJ.js} +5 -4
- package/dist/{archive-scenario-6M2IB7Y2.js → archive-scenario-W6BXYDZ3.js} +5 -4
- package/dist/{archive-suite-NXZ3YDS3.js → archive-suite-4T6BSRS7.js} +5 -4
- package/dist/{assign-prompt-tag-WPUJO55U.js → assign-prompt-tag-VLXUWEKU.js} +4 -3
- package/dist/chunk-37SMPMQS.js +12 -0
- package/dist/{chunk-HRFQAFPR.js → chunk-4QC7SA2L.js} +221 -134
- package/dist/{chunk-XRQNXN2Z.js → chunk-5CCZFUXS.js} +2 -2
- package/dist/{chunk-ITN2QGHF.js → chunk-77BNWQ3U.js} +2 -2
- package/dist/{chunk-B6UV3JVI.js → chunk-7RHG56OH.js} +2 -2
- package/dist/{chunk-CAY57CKF.js → chunk-A2LEVYQ5.js} +78 -5
- package/dist/{chunk-U2QIW2SW.js → chunk-AQJO2EI5.js} +2 -2
- package/dist/{chunk-GWEW5XON.js → chunk-CDYQOY5U.js} +2 -2
- package/dist/{chunk-LTEJDL4V.js → chunk-J42FWRJ2.js} +2 -2
- package/dist/chunk-SAS5OB7F.js +58 -0
- package/dist/{chunk-AGGE6NPR.js → chunk-SFB4MU6H.js} +2 -2
- package/dist/{chunk-COCNCXVJ.js → chunk-TJCXFNDT.js} +2 -2
- package/dist/chunk-TOXJQDIZ.js +432 -0
- package/dist/chunk-UJPXFA26.js +267 -0
- package/dist/{chunk-KOO5733S.js → chunk-WT4PO4A3.js} +8 -2
- package/dist/{chunk-RDUXCCFR.js → chunk-YX3A3CFM.js} +2 -2
- package/dist/{chunk-UKRCZJJC.js → chunk-YZLYHLLI.js} +2 -2
- package/dist/{chunk-ESGZVPPC.js → chunk-ZWIL4EFL.js} +2 -2
- package/dist/config.js +2 -1
- package/dist/{create-agent-BI7UTJ6A.js → create-agent-7XHO6UIS.js} +5 -4
- package/dist/{create-annotation-SNM2J6S4.js → create-annotation-YQXRQC6A.js} +5 -4
- package/dist/{create-api-key-23MXYC2L.js → create-api-key-YUS36KBU.js} +5 -4
- package/dist/{create-dashboard-CPOOOIKK.js → create-dashboard-4Z5JO5LB.js} +5 -4
- package/dist/{create-dataset-BVXPVVY2.js → create-dataset-E6NMSVX7.js} +5 -4
- package/dist/{create-dataset-records-S7VFIIMR.js → create-dataset-records-SKHPRD2K.js} +5 -4
- package/dist/{create-evaluator-WJAAQOUE.js → create-evaluator-JXF5PF33.js} +5 -4
- package/dist/create-mcp-server.js +4 -3
- package/dist/{create-project-BF7LMZH5.js → create-project-CS2CB57Y.js} +5 -4
- package/dist/{create-prompt-LZ3QHSU4.js → create-prompt-F5RMX3L3.js} +4 -3
- package/dist/{create-prompt-tag-IF4J24QM.js → create-prompt-tag-GMRWTEFR.js} +4 -3
- package/dist/{create-scenario-BK4E5DEU.js → create-scenario-JDR2VB2H.js} +5 -4
- package/dist/{create-suite-HEQPNLND.js → create-suite-LZS6QIAF.js} +5 -4
- package/dist/{delete-agent-Y4T2G5PT.js → delete-agent-O3EEH4S5.js} +5 -4
- package/dist/{delete-annotation-KYDMQTZG.js → delete-annotation-XP6FQM7A.js} +5 -4
- package/dist/{delete-dashboard-3RW647WJ.js → delete-dashboard-RFUNYCNP.js} +5 -4
- package/dist/{delete-dataset-SZAHFHHS.js → delete-dataset-3MJFRDLP.js} +5 -4
- package/dist/{delete-dataset-records-ISHKGEBH.js → delete-dataset-records-WPMU5GL5.js} +5 -4
- package/dist/{delete-evaluator-VKIG5I3S.js → delete-evaluator-33SP2JFX.js} +5 -4
- package/dist/{delete-prompt-tag-VYYL4GTF.js → delete-prompt-tag-KNMZVSPB.js} +4 -3
- package/dist/{delete-workflow-SHNPYSWQ.js → delete-workflow-3NUXO46U.js} +5 -4
- package/dist/discover-evaluator-schema-XTAD4X7D.js +2191 -0
- package/dist/{discover-scenario-schema-MEEEVND7.js → discover-scenario-schema-FE64QK2D.js} +3 -1
- package/dist/{discover-schema-3T52ORPB.js → discover-schema-L6QDPON3.js} +3 -1
- package/dist/{get-agent-IZSP7AR5.js → get-agent-Y7MWZ65F.js} +5 -4
- package/dist/{get-analytics-EDFAYYIQ.js → get-analytics-TETCSOK6.js} +4 -3
- package/dist/{get-dashboard-WSAO6IQ4.js → get-dashboard-KHBEGZGL.js} +5 -4
- package/dist/{get-dataset-BEVNXQNF.js → get-dataset-RCMU5VAH.js} +5 -4
- package/dist/{get-evaluator-HCVXNPZR.js → get-evaluator-ADMKVWYZ.js} +5 -4
- package/dist/{get-project-H4V3GYRQ.js → get-project-RAK7URQJ.js} +5 -4
- package/dist/{get-prompt-EWRJVVGB.js → get-prompt-OY5B7TRI.js} +4 -3
- package/dist/{get-scenario-24YUJS5W.js → get-scenario-ZTAJJL5T.js} +5 -4
- package/dist/{get-simulation-run-UX2W6F6I.js → get-simulation-run-T2ZQWYH2.js} +5 -4
- package/dist/{get-suite-B65ZKZJA.js → get-suite-J7JVWO6O.js} +5 -4
- package/dist/{get-trace-ZR7MIITH.js → get-trace-K7U234Q4.js} +8 -10
- package/dist/{get-workflow-YROHUQJW.js → get-workflow-L5L2PSK3.js} +5 -4
- package/dist/http-security-EU3CHTY7.js +26 -0
- package/dist/http-server-YXHFPPGA.js +24706 -0
- package/dist/index.js +23280 -3135
- package/dist/{langwatch-api-annotations-OPEXNTPF.js → langwatch-api-annotations-FDAS6NQ7.js} +5 -4
- package/dist/{langwatch-api-dashboards-NPQM6QJI.js → langwatch-api-dashboards-JTVCS7ZJ.js} +5 -4
- package/dist/{langwatch-api-monitors-3L25OOOS.js → langwatch-api-monitors-3J7UIQME.js} +4 -3
- package/dist/{langwatch-api-secrets-ZFURUA62.js → langwatch-api-secrets-BUBSNCNO.js} +4 -3
- package/dist/{langwatch-api-triggers-XGXXT7DD.js → langwatch-api-triggers-EDFUCJN6.js} +4 -3
- package/dist/langwatch-api-workflows-NBJX5KOG.js +16 -0
- package/dist/{list-agents-6ZNOV7FK.js → list-agents-KFHKGPXV.js} +5 -4
- package/dist/{list-annotations-6P3IWILH.js → list-annotations-ZTVP4EEL.js} +5 -4
- package/dist/{list-api-keys-JJI62KD2.js → list-api-keys-CWD4UQT5.js} +5 -4
- package/dist/{list-dashboards-G2WJOXWB.js → list-dashboards-PWG6P6KR.js} +5 -4
- package/dist/{list-dataset-records-GWWVOCII.js → list-dataset-records-IOE7LQXS.js} +5 -4
- package/dist/{list-datasets-HBTH33X4.js → list-datasets-ZT4JYUDT.js} +5 -4
- package/dist/{list-evaluators-K5OGB6TX.js → list-evaluators-SJHC7VBH.js} +5 -4
- package/dist/{list-model-providers-JMOGZLSO.js → list-model-providers-PPD2WPD2.js} +5 -4
- package/dist/{list-projects-OXJC2NW5.js → list-projects-K7QAIX2I.js} +5 -4
- package/dist/{list-prompt-tags-J2HPHVAZ.js → list-prompt-tags-FOO6TNHB.js} +4 -3
- package/dist/{list-prompts-C7GR72XL.js → list-prompts-SC2HAUFG.js} +4 -3
- package/dist/{list-scenarios-JEPGIIDO.js → list-scenarios-F2WYNRIE.js} +5 -4
- package/dist/{list-simulation-runs-DRSAGPEC.js → list-simulation-runs-KF5THG5H.js} +5 -4
- package/dist/{list-suites-POTZ3ZT6.js → list-suites-CRY4VWW6.js} +5 -4
- package/dist/{list-workflows-QQZQIOHB.js → list-workflows-QSJWURCK.js} +5 -4
- package/dist/{rename-prompt-tag-4AAV2BS4.js → rename-prompt-tag-EKWU5QF3.js} +4 -3
- package/dist/report-issue-XYVAPAYJ.js +412 -0
- package/dist/{revoke-api-key-TONB4ADQ.js → revoke-api-key-FTRTZMOF.js} +5 -4
- package/dist/{run-agent-7QE3YEH7.js → run-agent-6SM4XNA7.js} +5 -4
- package/dist/{run-suite-Q66OSPO4.js → run-suite-NKZCJ2IN.js} +5 -4
- package/dist/{run-workflow-RWX2D752.js → run-workflow-QPXC627O.js} +5 -4
- package/dist/{search-traces-M5E5VB4X.js → search-traces-A6HFKPLJ.js} +10 -3
- package/dist/{set-model-provider-XENT5D2P.js → set-model-provider-3WKT63ZN.js} +5 -4
- package/dist/{update-agent-GML25EE3.js → update-agent-SMAEHLXH.js} +5 -4
- package/dist/{update-dataset-R4MM6NNY.js → update-dataset-BDUK7TUO.js} +5 -4
- package/dist/{update-dataset-record-FN4BL5P4.js → update-dataset-record-4ZSDRBSW.js} +5 -4
- package/dist/{update-evaluator-LH2RDDB5.js → update-evaluator-LS6TIBY7.js} +5 -4
- package/dist/{update-project-H53IHRBB.js → update-project-LKVYXENH.js} +5 -4
- package/dist/{update-prompt-M33OTTAJ.js → update-prompt-ODCRQRN6.js} +4 -3
- package/dist/{update-scenario-FKTQRAFQ.js → update-scenario-NEXCAQI7.js} +5 -4
- package/dist/{update-suite-JJTNOTXN.js → update-suite-SNO3GS7T.js} +5 -4
- package/package.json +20 -18
- package/pyproject.toml +10 -2
- package/src/__tests__/all-tools.integration.test.ts +56 -120
- package/src/__tests__/config.unit.test.ts +33 -0
- package/src/__tests__/docker.integration.test.ts +91 -7
- package/src/__tests__/documentation-fetch-security.integration.test.ts +182 -0
- package/src/__tests__/feature-map-tool-drift.unit.test.ts +93 -0
- package/src/__tests__/http-security-origin.unit.test.ts +97 -0
- package/src/__tests__/http-security-sessions.unit.test.ts +209 -0
- package/src/__tests__/http-security-verifier.unit.test.ts +248 -0
- package/src/__tests__/http-server-allocation.integration.test.ts +279 -0
- package/src/__tests__/http-server-origin.integration.test.ts +169 -0
- package/src/__tests__/http-server-session-auth.integration.test.ts +341 -0
- package/src/__tests__/http-transport.integration.test.ts +85 -87
- package/src/__tests__/langwatch-api.unit.test.ts +206 -0
- package/src/__tests__/public-http-request-security.integration.test.ts +118 -0
- package/src/__tests__/report-issue.integration.test.ts +147 -0
- package/src/__tests__/support/http-server-harness.ts +138 -0
- package/src/__tests__/tools.unit.test.ts +24 -0
- package/src/config.ts +17 -2
- package/src/create-mcp-server.ts +43 -29
- package/src/documentation-fetch.ts +111 -0
- package/src/http-security.ts +492 -0
- package/src/http-server.ts +536 -152
- package/src/index.ts +49 -2
- package/src/langwatch-api-agents.ts +2 -2
- package/src/langwatch-api.ts +138 -8
- package/src/public-http-request.ts +242 -0
- package/src/tools/discover-evaluator-schema.ts +2 -2
- package/src/tools/get-trace.ts +2 -12
- package/src/tools/report-issue.ts +150 -0
- package/src/tools/search-traces.ts +4 -0
- package/src/utils/format-evaluations.ts +20 -0
- package/tsconfig.json +8 -1
- package/uv.lock +261 -207
- package/dist/chunk-IUP5IHBD.js +0 -71
- package/dist/discover-evaluator-schema-H23XCLNE.js +0 -1402
- package/dist/http-server-GXVEDA7G.js +0 -226
- package/dist/langwatch-api-workflows-CXCTTCXT.js +0 -15
- package/pnpm-workspace.yaml +0 -17
package/.python-version
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
3.11
|
package/.release-please-shim
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
release-please shadow marker (
|
|
1
|
+
release-please shadow marker (v3), next: 1.0.0
|
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,80 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## [2.0.0](https://github.com/langwatch/langwatch/compare/mcp-server@v1.0.0...mcp-server@v2.0.0) (2026-08-07)
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
### ⚠ BREAKING CHANGES
|
|
7
|
+
|
|
8
|
+
* **mcp-server:** three behaviors change for callers of the HTTP server. A client that authenticated once at initialize and then sent only the session id must now send Authorization: Bearer <key> on every request. GET /sse?apiKey=<key> no longer authenticates; use the Authorization header. A deployment relying on the implicit 0.0.0.0 bind must pass --host 0.0.0.0, which the published container image already does.
|
|
9
|
+
|
|
10
|
+
### Features
|
|
11
|
+
|
|
12
|
+
* **api-docs:** publish the REST API the SDKs actually call, and gate route coverage ([#6605](https://github.com/langwatch/langwatch/issues/6605)) ([25884bf](https://github.com/langwatch/langwatch/commit/25884bf3992eb99c00c3c7bafb09b979b02f0013))
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
### Bug Fixes
|
|
16
|
+
|
|
17
|
+
* **mcp-server:** authorize every request to the standalone HTTP server ([#6641](https://github.com/langwatch/langwatch/issues/6641)) ([af324de](https://github.com/langwatch/langwatch/commit/af324deeb3700f2745783a46e6fd5e8625ef868e))
|
|
18
|
+
|
|
19
|
+
|
|
20
|
+
### Code Refactoring
|
|
21
|
+
|
|
22
|
+
* **build:** single pnpm workspace + restructure into sdks/ platform/ services/ mcp/ infra/ (ADR-076) ([#6405](https://github.com/langwatch/langwatch/issues/6405)) ([2bbeb7d](https://github.com/langwatch/langwatch/commit/2bbeb7dd2e0747e81478f22c3165adb9163c9f99))
|
|
23
|
+
|
|
24
|
+
## [1.0.0](https://github.com/langwatch/langwatch/compare/mcp-server@v0.10.1...mcp-server@v1.0.0) (2026-07-24)
|
|
25
|
+
|
|
26
|
+
|
|
27
|
+
### Features
|
|
28
|
+
|
|
29
|
+
* agent issue reports, npx langwatch report at every access point ([#6101](https://github.com/langwatch/langwatch/issues/6101)) ([e881f8e](https://github.com/langwatch/langwatch/commit/e881f8e5ed5e24094e9c55e3f8d390c9ff2f43e4))
|
|
30
|
+
* **errors:** handled-error remediation channel (tips/docsUrl/fault) + shared package ([#5917](https://github.com/langwatch/langwatch/issues/5917)) ([bf9bf5a](https://github.com/langwatch/langwatch/commit/bf9bf5ab61c1c70160be712532a92d81816f77be))
|
|
31
|
+
* **langy:** event-sourced frontend, model-emitted cards, and a home built on one field ([#6027](https://github.com/langwatch/langwatch/issues/6027)) ([5d72c7e](https://github.com/langwatch/langwatch/commit/5d72c7efc7b27fbc683ed77df7a943d01fb6b7a9))
|
|
32
|
+
* **mcp-server:** graduate to 1.0.0 ([fa2341f](https://github.com/langwatch/langwatch/commit/fa2341f3e4e2caafea684886e3f68de99c5e9bd4))
|
|
33
|
+
|
|
34
|
+
|
|
35
|
+
### Bug Fixes
|
|
36
|
+
|
|
37
|
+
* **deps:** bump @anthropic-ai/claude-code to 2.1.202 with consistent lockfiles ([#5808](https://github.com/langwatch/langwatch/issues/5808)) ([a32cb2d](https://github.com/langwatch/langwatch/commit/a32cb2d7935dab244e05dd6ef360296d90a548d5))
|
|
38
|
+
* **mcp-server:** bump vitest to 4.1.8 for SNYK-JS-VITEST-17375131 ([#5379](https://github.com/langwatch/langwatch/issues/5379)) ([f495f35](https://github.com/langwatch/langwatch/commit/f495f35e385db610bdfbd235992dbcf18df8b1eb))
|
|
39
|
+
* **mcp-server:** keep zod and @modelcontextprotocol/sdk as real dependencies ([#5976](https://github.com/langwatch/langwatch/issues/5976)) ([2a368ef](https://github.com/langwatch/langwatch/commit/2a368eff7f7b1129b992bf3a74259e63cf299140))
|
|
40
|
+
* **mcp-server:** move unused runtime deps to devDependencies (npx cold-start 27s -> 2s) ([#5965](https://github.com/langwatch/langwatch/issues/5965)) ([7c5b49a](https://github.com/langwatch/langwatch/commit/7c5b49a18cc24a1c9f0a462d521c5907e4e98216))
|
|
41
|
+
* **mcp-server:** surface evaluation results in search_traces ([#5983](https://github.com/langwatch/langwatch/issues/5983)) ([dacb1e9](https://github.com/langwatch/langwatch/commit/dacb1e9fbadfb0d156bf44d31cd263720180eded))
|
|
42
|
+
* **security:** harden MCP outbound requests and browser policy ([#6091](https://github.com/langwatch/langwatch/issues/6091)) ([694aeaf](https://github.com/langwatch/langwatch/commit/694aeaf21e8aab41055d027c6106c64d8e67e624))
|
|
43
|
+
* **security:** raise hono and undici floors across npm workspaces ([#5071](https://github.com/langwatch/langwatch/issues/5071)) ([5b5d57a](https://github.com/langwatch/langwatch/commit/5b5d57ac59baa38e90f9db82f3c213a26262bce4))
|
|
44
|
+
* **security:** raise litellm to >=1.84.0 in mcp-server and python-sdk ([cb44747](https://github.com/langwatch/langwatch/commit/cb447477d21feb9448445505bbe088f4b54776dc))
|
|
45
|
+
* **security:** raise litellm to >=1.84.0 in mcp-server and python-sdk (CRITICAL) ([#5230](https://github.com/langwatch/langwatch/issues/5230)) ([cb44747](https://github.com/langwatch/langwatch/commit/cb447477d21feb9448445505bbe088f4b54776dc))
|
|
46
|
+
* **security:** raise mcp-server python-dotenv and python-liquid transitive floors ([#5610](https://github.com/langwatch/langwatch/issues/5610)) ([52db5a4](https://github.com/langwatch/langwatch/commit/52db5a4c69e7a6b7bef9d80cf58d696d44ce4238))
|
|
47
|
+
|
|
48
|
+
|
|
49
|
+
### Miscellaneous
|
|
50
|
+
|
|
51
|
+
* **deps-dev:** bump @anthropic-ai/claude-code ([acb7ce4](https://github.com/langwatch/langwatch/commit/acb7ce41ac1ec574ed8b1a78aeddd4867246ee5c))
|
|
52
|
+
* **deps-dev:** bump @anthropic-ai/claude-code from 2.1.158 to 2.1.163 in /mcp-server in the npm_and_yarn group across 1 directory ([#4995](https://github.com/langwatch/langwatch/issues/4995)) ([acb7ce4](https://github.com/langwatch/langwatch/commit/acb7ce41ac1ec574ed8b1a78aeddd4867246ee5c))
|
|
53
|
+
* **deps-dev:** bump @anthropic-ai/claude-code from 2.1.163 to 2.1.195 in /mcp-server ([#5376](https://github.com/langwatch/langwatch/issues/5376)) ([5ff4826](https://github.com/langwatch/langwatch/commit/5ff4826214587a6aed784a69578062ab12fd9df1))
|
|
54
|
+
* **deps-dev:** bump @anthropic-ai/claude-code in /mcp-server ([5ff4826](https://github.com/langwatch/langwatch/commit/5ff4826214587a6aed784a69578062ab12fd9df1))
|
|
55
|
+
* **deps-dev:** bump @langwatch/scenario from 0.4.11 to 0.4.15 in /mcp-server ([#5338](https://github.com/langwatch/langwatch/issues/5338)) ([de74e61](https://github.com/langwatch/langwatch/commit/de74e6183244683b650105eea70dda5fe4bda4a4))
|
|
56
|
+
* **deps-dev:** bump @langwatch/scenario in /mcp-server ([de74e61](https://github.com/langwatch/langwatch/commit/de74e6183244683b650105eea70dda5fe4bda4a4))
|
|
57
|
+
* **deps-dev:** bump @types/eslint__js from 8.42.3 to 9.14.0 in /langwatch ([#4605](https://github.com/langwatch/langwatch/issues/4605)) ([b937610](https://github.com/langwatch/langwatch/commit/b937610ea11752f5a07aa111da07e9dd7bbaa9f8))
|
|
58
|
+
* **deps-dev:** bump @typescript/native-preview from 7.0.0-dev.20250911.1 to 7.0.0-dev.20260628.1 in /mcp-server ([#5373](https://github.com/langwatch/langwatch/issues/5373)) ([1ac876f](https://github.com/langwatch/langwatch/commit/1ac876fe55f2c73452c82b9a4219e52980dda9d2))
|
|
59
|
+
* **deps-dev:** bump @typescript/native-preview to 7.0.0-dev.20260628.1 in /mcp-server ([1ac876f](https://github.com/langwatch/langwatch/commit/1ac876fe55f2c73452c82b9a4219e52980dda9d2))
|
|
60
|
+
* **deps-dev:** bump eslint from 10.4.1 to 10.6.0 in /mcp-server ([#5372](https://github.com/langwatch/langwatch/issues/5372)) ([78244c1](https://github.com/langwatch/langwatch/commit/78244c197c8000cb7358f19f7cdcf7e07e93231e))
|
|
61
|
+
* **deps-dev:** bump the typescript-native-preview group across 3 directories with 1 update ([#5721](https://github.com/langwatch/langwatch/issues/5721)) ([6e44614](https://github.com/langwatch/langwatch/commit/6e44614f5b193cf959203bb32e357cc7407e4b16))
|
|
62
|
+
* **deps-dev:** bump the typescript-native-preview group across 3 directories with 1 update ([#5755](https://github.com/langwatch/langwatch/issues/5755)) ([1508d35](https://github.com/langwatch/langwatch/commit/1508d359e5bc5a8f382dbec25d53c5448b910d90))
|
|
63
|
+
* **deps-dev:** bump tsx from 4.22.3 to 4.22.4 in /mcp-server ([#4779](https://github.com/langwatch/langwatch/issues/4779)) ([1e8e538](https://github.com/langwatch/langwatch/commit/1e8e538e57e0096957439a4146a5eea480df3e93))
|
|
64
|
+
* **deps-dev:** bump typescript-eslint from 8.60.0 to 8.62.0 in /mcp-server ([#4880](https://github.com/langwatch/langwatch/issues/4880)) ([5773c2d](https://github.com/langwatch/langwatch/commit/5773c2db77634313075eb58e94190e0d7c146577))
|
|
65
|
+
* **deps-dev:** bump typescript-eslint from 8.62.0 to 8.62.1 in /mcp-server ([#5478](https://github.com/langwatch/langwatch/issues/5478)) ([9250768](https://github.com/langwatch/langwatch/commit/92507686d7d519691b8d53a625c4a67374ded313))
|
|
66
|
+
* **deps-dev:** bump typescript-eslint in /mcp-server ([9250768](https://github.com/langwatch/langwatch/commit/92507686d7d519691b8d53a625c4a67374ded313))
|
|
67
|
+
* **deps-dev:** bump typescript-eslint in /mcp-server ([5773c2d](https://github.com/langwatch/langwatch/commit/5773c2db77634313075eb58e94190e0d7c146577))
|
|
68
|
+
* **deps-dev:** remove redundant @types/eslint__js in /mcp-server ([b937610](https://github.com/langwatch/langwatch/commit/b937610ea11752f5a07aa111da07e9dd7bbaa9f8))
|
|
69
|
+
* **deps:** batch small dependency updates in /langwatch + /mcp-server ([#5447](https://github.com/langwatch/langwatch/issues/5447)) ([daed7b1](https://github.com/langwatch/langwatch/commit/daed7b1325fc06b70c0739849d27280a8a4f6c9c))
|
|
70
|
+
* **deps:** bump @modelcontextprotocol/sdk from 1.26.0 to 1.29.0 in /langwatch ([#4607](https://github.com/langwatch/langwatch/issues/4607)) ([08f2ce6](https://github.com/langwatch/langwatch/commit/08f2ce6b50877edf35ec524e1524afdbb5de53b0))
|
|
71
|
+
* **deps:** bump @opentelemetry/context-async-hooks from 2.7.1 to 2.8.0 in /mcp-server ([#5033](https://github.com/langwatch/langwatch/issues/5033)) ([1506b70](https://github.com/langwatch/langwatch/commit/1506b701e999bc779190bff988942927537cffd1))
|
|
72
|
+
* **deps:** bump @opentelemetry/context-async-hooks in /mcp-server ([1506b70](https://github.com/langwatch/langwatch/commit/1506b701e999bc779190bff988942927537cffd1))
|
|
73
|
+
* **deps:** bump @opentelemetry/sdk-node from 0.217.0 to 0.219.0 in /mcp-server ([#5048](https://github.com/langwatch/langwatch/issues/5048)) ([9f1ef55](https://github.com/langwatch/langwatch/commit/9f1ef5572a9cca3114e583b4a319fb3ec416e080))
|
|
74
|
+
* **deps:** bump @opentelemetry/sdk-node in /mcp-server ([9f1ef55](https://github.com/langwatch/langwatch/commit/9f1ef5572a9cca3114e583b4a319fb3ec416e080))
|
|
75
|
+
* **deps:** bump vitest from 4.1.0 to 4.1.9 in /mcp-server ([#4784](https://github.com/langwatch/langwatch/issues/4784)) ([efe348f](https://github.com/langwatch/langwatch/commit/efe348f4b4e4836f7b27d5ab32673a5bc77323a2))
|
|
76
|
+
* **deps:** bump yargs from 17.7.2 to 18.0.0 in /mcp-server ([#4307](https://github.com/langwatch/langwatch/issues/4307)) ([dddc31d](https://github.com/langwatch/langwatch/commit/dddc31d6901a4d7fc91ea25fe442810dacdbda67))
|
|
77
|
+
|
|
3
78
|
## [0.10.1](https://github.com/langwatch/langwatch/compare/mcp-server@v0.10.0...mcp-server@v0.10.1) (2026-05-31)
|
|
4
79
|
|
|
5
80
|
|
package/CONTRIBUTING.md
CHANGED
|
@@ -15,7 +15,7 @@ Thank you for your interest in contributing to the LangWatch MCP Server! This gu
|
|
|
15
15
|
1. **Clone the repository and navigate to the MCP server directory:**
|
|
16
16
|
```bash
|
|
17
17
|
git clone https://github.com/langwatch/langwatch.git
|
|
18
|
-
cd langwatch/mcp
|
|
18
|
+
cd langwatch/mcp/typescript
|
|
19
19
|
```
|
|
20
20
|
|
|
21
21
|
2. **Install dependencies and build the MCP server:**
|
package/README.md
CHANGED
|
@@ -4,29 +4,21 @@ MCP server that gives AI coding agents access to LangWatch observability data, p
|
|
|
4
4
|
|
|
5
5
|
## Quick Setup
|
|
6
6
|
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
```json
|
|
10
|
-
{
|
|
11
|
-
"mcpServers": {
|
|
12
|
-
"langwatch": {
|
|
13
|
-
"command": "npx",
|
|
14
|
-
"args": ["-y", "@langwatch/mcp-server"],
|
|
15
|
-
"env": {
|
|
16
|
-
"LANGWATCH_API_KEY": "your-api-key-here"
|
|
17
|
-
}
|
|
18
|
-
}
|
|
19
|
-
}
|
|
20
|
-
}
|
|
21
|
-
```
|
|
22
|
-
|
|
23
|
-
For Claude Code, you can also run:
|
|
7
|
+
For Claude Code, run:
|
|
24
8
|
|
|
25
9
|
```bash
|
|
26
10
|
claude mcp add langwatch -- npx -y @langwatch/mcp-server --apiKey your-api-key-here
|
|
27
11
|
```
|
|
28
12
|
|
|
29
|
-
|
|
13
|
+
For Claude Code (manual) or other MCP clients (Cursor, Copilot, etc.), add an entry named `langwatch` under the `mcpServers` object of your client's MCP settings file with these fields:
|
|
14
|
+
|
|
15
|
+
- `command`: `npx`
|
|
16
|
+
- `args`: `-y`, then the package name `@langwatch/mcp-server` on a separate token
|
|
17
|
+
- `env.LANGWATCH_API_KEY`: your LangWatch API key
|
|
18
|
+
|
|
19
|
+
In stdio mode the API key is required for observability and prompt tools, and documentation tools work without it. In HTTP mode every MCP request needs a valid key, including documentation-tool requests, because the server authenticates the request before it reaches any tool.
|
|
20
|
+
|
|
21
|
+
> The config is described in prose rather than as a JSON snippet because some CLI agents (notably Gemini CLI 0.36.0 and earlier) parse `@`-prefixed runs as file paths and can crash with `ENAMETOOLONG` when a multi-line JSON snippet wraps the scoped package name in double quotes. See [#3104](https://github.com/langwatch/langwatch/issues/3104). The bash form above is safe — the package name is followed by a whitespace terminator.
|
|
30
22
|
|
|
31
23
|
## Configuration
|
|
32
24
|
|
|
@@ -34,6 +26,60 @@ The API key is required for observability and prompt tools. Documentation tools
|
|
|
34
26
|
|---------|---------|-------------|
|
|
35
27
|
| `LANGWATCH_API_KEY` | `--apiKey` | API key for authentication |
|
|
36
28
|
| `LANGWATCH_ENDPOINT` | `--endpoint` | API endpoint (default: `https://app.langwatch.ai`) |
|
|
29
|
+
| | `--http` | Serve over HTTP and SSE instead of stdio |
|
|
30
|
+
| | `--port` | HTTP port (default: `3000`) |
|
|
31
|
+
| `LANGWATCH_MCP_HTTP_HOST` | `--host` | HTTP listen address (default: `127.0.0.1`) |
|
|
32
|
+
| `LANGWATCH_MCP_ALLOWED_ORIGINS` | `--allowedOrigin` | Browser origins allowed to call the HTTP server |
|
|
33
|
+
| `LANGWATCH_MCP_TRUST_PROXY` | | Use `X-Forwarded-For` as the rate limit key (default: off) |
|
|
34
|
+
|
|
35
|
+
### HTTP mode
|
|
36
|
+
|
|
37
|
+
In HTTP mode each client brings its own API key in an `Authorization: Bearer <key>`
|
|
38
|
+
header, on every MCP request rather than only at session start. That covers
|
|
39
|
+
`/mcp`, `/sse`, and `/messages`. The key is checked against the LangWatch API
|
|
40
|
+
before a session is created and re-checked on each request, so a session id by
|
|
41
|
+
itself grants no access and revoking a key stops its sessions being served
|
|
42
|
+
within a minute. The API key is never read from a query parameter.
|
|
43
|
+
|
|
44
|
+
Because authentication happens before routing, this applies to the documentation
|
|
45
|
+
tools too: unlike stdio mode, they are not reachable without a valid key.
|
|
46
|
+
|
|
47
|
+
Three routes do not take the bearer. `/health` reports liveness only.
|
|
48
|
+
`/.well-known/oauth-authorization-server` is the discovery document clients read
|
|
49
|
+
before they hold a token. `/oauth/token` exchanges an API key, sent as
|
|
50
|
+
`client_secret` in the form body, for a short-lived access token; it verifies
|
|
51
|
+
that key against the LangWatch API before issuing anything, and the token it
|
|
52
|
+
returns is what later MCP requests carry.
|
|
53
|
+
|
|
54
|
+
The server listens on `127.0.0.1` by default, per the MCP transport guidance for
|
|
55
|
+
local servers. Pass `--host 0.0.0.0` to accept connections from other machines,
|
|
56
|
+
and only behind a network boundary you trust.
|
|
57
|
+
|
|
58
|
+
Requests carrying a browser `Origin` header are checked against an allowlist.
|
|
59
|
+
Loopback origins are always allowed; anything else has to be listed:
|
|
60
|
+
|
|
61
|
+
```bash
|
|
62
|
+
npx @langwatch/mcp-server --http --port 3000 \
|
|
63
|
+
--allowedOrigin https://your-app.example.com
|
|
64
|
+
```
|
|
65
|
+
|
|
66
|
+
#### Running behind a proxy
|
|
67
|
+
|
|
68
|
+
Forwarded proxy headers resolve the external scheme that the OAuth metadata
|
|
69
|
+
document advertises, so they are read by default.
|
|
70
|
+
|
|
71
|
+
They do not decide the rate limit. Failed authentication is limited per client
|
|
72
|
+
address, and that address comes from the socket rather than from
|
|
73
|
+
`X-Forwarded-For`, so a client reaching the port directly cannot rotate a header
|
|
74
|
+
to reset its own counter. Behind a real proxy every request shares the proxy's
|
|
75
|
+
socket address, which means the whole proxy is limited as one client. Set
|
|
76
|
+
`LANGWATCH_MCP_TRUST_PROXY=true` there to limit per real client instead, and
|
|
77
|
+
only when the proxy overwrites `X-Forwarded-For` on the way in.
|
|
78
|
+
|
|
79
|
+
This is defense in depth, not the security boundary. API keys are verified
|
|
80
|
+
against the LangWatch API before a session is created and re-checked on every
|
|
81
|
+
request; the rate limit exists to make guessing expensive, not to decide who
|
|
82
|
+
gets in. A spoofable rate limit does not let anyone authenticate.
|
|
37
83
|
|
|
38
84
|
## Tools
|
|
39
85
|
|
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
import {
|
|
2
2
|
archiveProject
|
|
3
|
-
} from "./chunk-
|
|
4
|
-
import "./chunk-
|
|
5
|
-
import "./chunk-
|
|
3
|
+
} from "./chunk-7RHG56OH.js";
|
|
4
|
+
import "./chunk-A2LEVYQ5.js";
|
|
5
|
+
import "./chunk-WT4PO4A3.js";
|
|
6
|
+
import "./chunk-SAS5OB7F.js";
|
|
6
7
|
|
|
7
8
|
// src/tools/archive-project.ts
|
|
8
9
|
async function handleArchiveProject(params) {
|
|
@@ -16,4 +17,4 @@ async function handleArchiveProject(params) {
|
|
|
16
17
|
export {
|
|
17
18
|
handleArchiveProject
|
|
18
19
|
};
|
|
19
|
-
//# sourceMappingURL=archive-project-
|
|
20
|
+
//# sourceMappingURL=archive-project-4EQGLBJJ.js.map
|
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
import {
|
|
2
2
|
archiveScenario
|
|
3
|
-
} from "./chunk-
|
|
4
|
-
import "./chunk-
|
|
5
|
-
import "./chunk-
|
|
3
|
+
} from "./chunk-J42FWRJ2.js";
|
|
4
|
+
import "./chunk-A2LEVYQ5.js";
|
|
5
|
+
import "./chunk-WT4PO4A3.js";
|
|
6
|
+
import "./chunk-SAS5OB7F.js";
|
|
6
7
|
|
|
7
8
|
// src/tools/archive-scenario.ts
|
|
8
9
|
async function handleArchiveScenario(params) {
|
|
@@ -16,4 +17,4 @@ async function handleArchiveScenario(params) {
|
|
|
16
17
|
export {
|
|
17
18
|
handleArchiveScenario
|
|
18
19
|
};
|
|
19
|
-
//# sourceMappingURL=archive-scenario-
|
|
20
|
+
//# sourceMappingURL=archive-scenario-W6BXYDZ3.js.map
|
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
import {
|
|
2
2
|
archiveSuite
|
|
3
|
-
} from "./chunk-
|
|
4
|
-
import "./chunk-
|
|
5
|
-
import "./chunk-
|
|
3
|
+
} from "./chunk-YZLYHLLI.js";
|
|
4
|
+
import "./chunk-A2LEVYQ5.js";
|
|
5
|
+
import "./chunk-WT4PO4A3.js";
|
|
6
|
+
import "./chunk-SAS5OB7F.js";
|
|
6
7
|
|
|
7
8
|
// src/tools/archive-suite.ts
|
|
8
9
|
async function handleArchiveSuite(params) {
|
|
@@ -12,4 +13,4 @@ async function handleArchiveSuite(params) {
|
|
|
12
13
|
export {
|
|
13
14
|
handleArchiveSuite
|
|
14
15
|
};
|
|
15
|
-
//# sourceMappingURL=archive-suite-
|
|
16
|
+
//# sourceMappingURL=archive-suite-4T6BSRS7.js.map
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import {
|
|
2
2
|
assignPromptTag
|
|
3
|
-
} from "./chunk-
|
|
4
|
-
import "./chunk-
|
|
3
|
+
} from "./chunk-A2LEVYQ5.js";
|
|
4
|
+
import "./chunk-WT4PO4A3.js";
|
|
5
|
+
import "./chunk-SAS5OB7F.js";
|
|
5
6
|
|
|
6
7
|
// src/tools/assign-prompt-tag.ts
|
|
7
8
|
async function handleAssignPromptTag(params) {
|
|
@@ -16,4 +17,4 @@ async function handleAssignPromptTag(params) {
|
|
|
16
17
|
export {
|
|
17
18
|
handleAssignPromptTag
|
|
18
19
|
};
|
|
19
|
-
//# sourceMappingURL=assign-prompt-tag-
|
|
20
|
+
//# sourceMappingURL=assign-prompt-tag-VLXUWEKU.js.map
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
// src/utils/format-evaluations.ts
|
|
2
|
+
function formatEvaluationLines(evaluations) {
|
|
3
|
+
return evaluations.map((evaluation) => {
|
|
4
|
+
const status = evaluation.passed === true ? "PASSED" : evaluation.passed === false ? "FAILED" : "N/A";
|
|
5
|
+
return `- **${evaluation.name || evaluation.evaluator_id}**: ${status}${evaluation.score != null ? ` (score: ${evaluation.score})` : ""}${evaluation.label ? ` [${evaluation.label}]` : ""}`;
|
|
6
|
+
});
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
export {
|
|
10
|
+
formatEvaluationLines
|
|
11
|
+
};
|
|
12
|
+
//# sourceMappingURL=chunk-37SMPMQS.js.map
|