{"name":"@modelcontextprotocol/core","version":"2.0.0-alpha.0","keywords":["modelcontextprotocol","mcp","schemas","zod"],"author":{"url":"https://anthropic.com","name":"Anthropic, PBC"},"license":"MIT","_id":"@modelcontextprotocol/core@2.0.0-alpha.0","maintainers":[{"name":"jspahrsummers","email":"justin@jspahrsummers.com"},{"name":"pcarleton","email":"paul@modelcontextprotocol.io"},{"name":"fweinberger","email":"fweinberger@anthropic.com"},{"name":"thedsp","email":"david@modelcontextprotocol.io"},{"name":"ashwin-ant","email":"ashwin@anthropic.com"},{"name":"ochafik-ant","email":"ochafik@anthropic.com"}],"homepage":"https://modelcontextprotocol.io","bugs":{"url":"https://github.com/modelcontextprotocol/typescript-sdk/issues"},"dist":{"shasum":"1375798b1c45e4bd06a1ed2b45615aa600c2a949","tarball":"http://registry-npm.ywwl.com/@modelcontextprotocol/core/download/@modelcontextprotocol/core-2.0.0-alpha.0.tgz","fileCount":6,"integrity":"sha512-c0A6dzzSYdAu6O7wljgymA3oFd5tqVPU3knEFesYoj5tw+C+Q5DQFWgTwp5lLi7z6dHWbGnHM8xjUFqPvF3KcA==","signatures":[{"sig":"MEQCIHKfsRZTaGkKGfZLi5BQxvUWLGhwbF5SvXY44NdqPU/LAiAhWkHEfiDcJM6hlcMpe8TUKDEwO+FZpQ6Xr1tkIKi6xg==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":560934,"size":62899,"noattachment":false,"key":"/@modelcontextprotocol/core/-/@modelcontextprotocol/core-2.0.0-alpha.0.tgz"},"type":"module","types":"./dist/index.d.ts","engines":{"node":">=20"},"exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js"}},"gitHead":"0fb8406d83a3578a12a605e1b43c352d565071b1","scripts":{"lint":"eslint src/ && prettier --ignore-path ../../.prettierignore --check .","test":"vitest run","build":"tsdown","check":"pnpm run typecheck && pnpm run lint","prepack":"pnpm run build","lint:fix":"eslint src/ --fix && prettier --ignore-path ../../.prettierignore --write .","typecheck":"tsgo -p tsconfig.json --noEmit","test:watch":"vitest","build:watch":"tsdown --watch"},"_npmUser":{"name":"fweinberger","email":"fweinberger@anthropic.com"},"repository":{"url":"git+https://github.com/modelcontextprotocol/typescript-sdk.git","type":"git"},"_npmVersion":"10.9.7","description":"Model Context Protocol for TypeScript — public Zod schemas (spec + OAuth/OpenID)","directories":{},"_nodeVersion":"22.22.2","dependencies":{"zod":"catalog:runtimeShared"},"_hasShrinkwrap":false,"devDependencies":{"eslint":"catalog:devTools","tsdown":"catalog:devTools","vitest":"catalog:devTools","prettier":"catalog:devTools","@eslint/js":"catalog:devTools","typescript":"catalog:devTools","eslint-plugin-n":"catalog:devTools","typescript-eslint":"catalog:devTools","eslint-config-prettier":"catalog:devTools","@typescript/native-preview":"catalog:devTools","@modelcontextprotocol/tsconfig":"workspace:^","@modelcontextprotocol/core-internal":"workspace:^","@modelcontextprotocol/eslint-config":"workspace:^","@modelcontextprotocol/vitest-config":"workspace:^"},"_npmOperationalInternal":{"tmp":"tmp/core_2.0.0-alpha.0_1782416061016_0.23198884064117165","host":"s3://npm-registry-packages-npm-production"},"readme":"# @modelcontextprotocol/core\n\nCanonical public home for the [Model Context Protocol](https://modelcontextprotocol.io) specification and OAuth/OpenID **Zod schemas**.\n\nThese are the exact schema constants the SDK validates protocol and OAuth/OpenID payloads against internally. The `@modelcontextprotocol/server` and `@modelcontextprotocol/client` packages keep a Zod-free public surface, so this package exists as the supported place to import the\nraw schemas when you need to validate or parse MCP messages yourself.\n\n## Install\n\n```sh\nnpm install @modelcontextprotocol/core\n```\n\n## Usage\n\n```ts\nimport { CallToolResultSchema } from '@modelcontextprotocol/core';\n\n// Throws on invalid input; returns the typed result on success.\nconst result = CallToolResultSchema.parse(payload);\n\n// Or non-throwing:\nconst parsed = CallToolResultSchema.safeParse(payload);\nif (parsed.success) {\n    // parsed.data is a fully typed CallToolResult\n}\n```\n\n## Scope\n\nThis package exports **only** Zod schema constants (`*Schema`), in two groups:\n\n- the MCP **spec** schemas — `CallToolResultSchema`, `ListToolsResultSchema`, …; and\n- the **OAuth/OpenID** auth schemas — `OAuthTokensSchema`, `OAuthMetadataSchema`, `IdJagTokenExchangeResponseSchema`, … (the schemas v1 exposed from `@modelcontextprotocol/sdk/shared/auth.js`).\n\nThe corresponding TypeScript types, error classes, enums, and type guards are part of the public API of [`@modelcontextprotocol/server`](https://www.npmjs.com/package/@modelcontextprotocol/server) and\n[`@modelcontextprotocol/client`](https://www.npmjs.com/package/@modelcontextprotocol/client).\n\n> **Migrating from v1?** In v1 these schemas were imported from `@modelcontextprotocol/sdk/types.js` (spec schemas) and `@modelcontextprotocol/sdk/shared/auth.js` (OAuth/OpenID schemas). Point those `*Schema` imports at `@modelcontextprotocol/core` and your existing `.parse()` /\n> `.safeParse()` calls keep working unchanged.\n","publish_time":1782416061200,"_cnpm_publish_time":1782416061200,"dist-tags":{"latest":"2.4.0"}}