{"_id":"@adaptivemcp/thin-client","_rev":"3-784a4347d41e301ce365672f6d8c3b5a","name":"@adaptivemcp/thin-client","dist-tags":{"latest":"0.2.2"},"versions":{"0.2.0":{"name":"@adaptivemcp/thin-client","version":"0.2.0","license":"MIT","_id":"@adaptivemcp/thin-client@0.2.0","maintainers":[{"name":"kemalelmizan","email":"kemalelmizan@gmail.com"}],"dist":{"shasum":"6c0e95ab467383a196839590b1e581c54aa58da2","tarball":"https://registry.npmjs.org/@adaptivemcp/thin-client/-/thin-client-0.2.0.tgz","fileCount":10,"integrity":"sha512-XJOhPNmFy8gyNpwMa3nOSy1teNPJN/UFcBode8RV6UUHSMx9Nh7+JZF82A84LFwvvIiRqmWuD7rhtvHHYaFcmw==","signatures":[{"sig":"MEQCIDXzHkpVKFcLiJ5jm2rZKUXIaPh0AV6ClBqw1eWaDCRvAiAs8WAk62TQ3eGWsg2xZNrGO+eKKR+9XzxvR9vE0B5cfA==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":11940},"main":"./dist/index.js","type":"module","types":"./dist/index.d.ts","exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js"}},"gitHead":"c04f081b84978d143a021ad607fbb72ada829913","scripts":{"test":"vitest run --config ../../vitest.config.ts","build":"tsc -p tsconfig.json"},"_npmUser":{"name":"kemalelmizan","email":"kemalelmizan@gmail.com"},"_npmVersion":"12.0.1","description":"Minimal client-side execution loop for Adaptive MCP.","directories":{},"_nodeVersion":"26.5.0","dependencies":{"@adaptivemcp/spec":"workspace:*","@adaptivemcp/memory":"workspace:*","@adaptivemcp/approval":"workspace:*","@adaptivemcp/orchestration":"workspace:*"},"_hasShrinkwrap":false,"devDependencies":{"vitest":"^2.1.0","typescript":"^5.6.0"},"_npmOperationalInternal":{"tmp":"tmp/thin-client_0.2.0_1784449909120_0.2744664322391357","host":"s3://npm-registry-packages-npm-production"}},"0.2.1":{"name":"@adaptivemcp/thin-client","version":"0.2.1","license":"MIT","_id":"@adaptivemcp/thin-client@0.2.1","maintainers":[{"name":"kemalelmizan","email":"kemalelmizan@gmail.com"}],"dist":{"shasum":"7d28dd439409eea17bb87d6598c7bd09a504a83a","tarball":"https://registry.npmjs.org/@adaptivemcp/thin-client/-/thin-client-0.2.1.tgz","fileCount":10,"integrity":"sha512-yw4R6sGJhTMjlk+LAjhXOeVola4cG3fxt6v6FFzpySpe7v4AwU/Tr3bUqyrDZwk3J7c5ZDCcBJHbm64s9ncGoQ==","signatures":[{"sig":"MEUCIQCYsCHOXfZr+37NYJnuUkT69UEAKvlFZQlu/CltER8IhAIgRz1PWQp6hDxcZ6nUqWHq4uppzSIVGrY/Y7hdqsEX9MU=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":12487},"main":"./dist/index.js","type":"module","types":"./dist/index.d.ts","exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js"}},"gitHead":"67875dd46c157fcfce32192c63201c00105202d5","scripts":{"test":"vitest run --config ../../vitest.config.ts","build":"tsc -p tsconfig.json"},"_npmUser":{"name":"kemalelmizan","email":"kemalelmizan@gmail.com"},"_npmVersion":"12.0.1","description":"Minimal client-side execution loop for Adaptive MCP.","directories":{},"_nodeVersion":"26.5.0","dependencies":{"@adaptivemcp/spec":"workspace:*","@adaptivemcp/memory":"workspace:*","@adaptivemcp/approval":"workspace:*","@adaptivemcp/orchestration":"workspace:*"},"_hasShrinkwrap":false,"devDependencies":{"vitest":"^2.1.0","typescript":"^5.6.0"},"_npmOperationalInternal":{"tmp":"tmp/thin-client_0.2.1_1784454893339_0.3550517287388677","host":"s3://npm-registry-packages-npm-production"}},"0.2.2":{"name":"@adaptivemcp/thin-client","version":"0.2.2","description":"Minimal client-side execution loop for Adaptive MCP.","license":"MIT","type":"module","main":"./dist/index.js","types":"./dist/index.d.ts","exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js"}},"scripts":{"build":"tsc -p tsconfig.json","test":"vitest run --config ../../vitest.config.ts"},"dependencies":{"@adaptivemcp/spec":"workspace:*","@adaptivemcp/memory":"workspace:*","@adaptivemcp/approval":"workspace:*","@adaptivemcp/orchestration":"workspace:*"},"devDependencies":{"typescript":"^5.6.0","vitest":"^2.1.0"},"gitHead":"00b51e676ad298a079f5de73e5cbea411fae39f2","_id":"@adaptivemcp/thin-client@0.2.2","_nodeVersion":"26.5.0","_npmVersion":"12.0.1","dist":{"integrity":"sha512-NVi4+OaFjCg92Qu9AmMvaAtNXcovqNeJjlOPpRW9SJVsjog07uxoFOAt0EKodMXQoJq0aO/pBln7V5nEvpctlw==","shasum":"07ee02bde3af844071edd46b8a90422fc4a17b36","tarball":"https://registry.npmjs.org/@adaptivemcp/thin-client/-/thin-client-0.2.2.tgz","fileCount":10,"unpackedSize":12487,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEYCIQCbMFdEttxZF1ktAdxtgSQ+3bmzwhTt86F4p8jF9qjpIwIhAOcvvvycaq9fEsxMmrdUjOjPCWDg2kGG5b6bPuSiKD4a"}]},"_npmUser":{"name":"kemalelmizan","email":"kemalelmizan@gmail.com"},"directories":{},"maintainers":[{"name":"kemalelmizan","email":"kemalelmizan@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/thin-client_0.2.2_1784457366180_0.4783655769240609"},"_hasShrinkwrap":false}},"time":{"created":"2026-07-19T08:31:48.966Z","modified":"2026-07-19T10:36:06.447Z","0.2.0":"2026-07-19T08:31:49.282Z","0.2.1":"2026-07-19T09:54:53.451Z","0.2.2":"2026-07-19T10:36:06.293Z"},"license":"MIT","description":"Minimal client-side execution loop for Adaptive MCP.","maintainers":[{"name":"kemalelmizan","email":"kemalelmizan@gmail.com"}],"readme":"# @adaptivemcp/thin-client\n\nMinimal MCP client loop for Adaptive MCP.\n\n> **Status:** published to npm as `@adaptivemcp/thin-client`. It is the\n> runtime engine that wires the learning packages into execution.\n\n`thin-client` is the runtime engine that wires the learning packages into\nexecution. It is intentionally small: transport, capability negotiation,\nmiddleware hooks, and the execution lifecycle. Business logic lives in the\nmiddleware packages (`routing`, `orchestration`, `approval`).\n\n## Usage\n\n```ts\nimport { MemoryStore } from \"@adaptivemcp/memory\";\nimport { ApprovalGate } from \"@adaptivemcp/approval\";\nimport { ThinClient } from \"@adaptivemcp/thin-client\";\n\nconst memory = new MemoryStore();\nconst gate = new ApprovalGate({ memory });\nconst client = new ThinClient({\n  memory,\n  gate,\n  requestApproval: (tool) => confirm(`${tool}?`), // human prompt in real use\n});\n\nawait client.run(\n  \"deploy_service\",\n  async (input) => ({ ok: true }), // the actual tool call\n  input,\n  (ok, error) => memory.recordExecution(/* … */), // record the outcome\n);\n```\n\n## What it does\n\n- `run(toolName, handler, input, record)`: execute a tool, consulting the\n  approval `gate` and the orchestration retry policy, and recording the outcome\n  into the store.\n- Does **not** implement MCP transport. That remains an implementation detail\n  of the host.\n\n## License\n\nReleased under the [MIT License](../../LICENSE). Copyright (c) 2026 Kemal Elmizan.\n","readmeFilename":"README.md"}