rotascale-mcp: expose your own tools with authorisation built in, so there is no unguarded path to them.
pip install rotascale-mcp
Two entry points ship:
Command
For
rotascale-mcp
A guarded MCP server: your tools, with the gate in front
rotascale-mcp-proxy
A proxy in front of somebody else’s MCP server. See the proxy
Why MCP needs this more than most integrations
An agent platform handing out OAuth scopes is granting a permission it cannot
recall, cannot bound and cannot attribute to a person. A grant has an expiry, a
ceiling and a named human. When the tools an agent reaches are ones you did not
write, that difference stops being philosophical.
The guarded server
export ROTASCALE_URL="https://rotagrant.internal.example"export ROTASCALE_API_KEY="rsk_..."export ROTASCALE_MCP_TRANSPORT="stdio" # or the HTTP transportrotascale-mcp
Every tool call is authorised before it reaches your handler. A refusal is
returned to the caller as an MCP error carrying the outcome and the reason, not
as a generic failure, so the agent on the other end can tell “not permitted”
from “out of allowance” and stop retrying the second one.
Mapping tools to grants
A server exposing ten tools is not one authority. A read tool and a tool that
moves money should not sit behind the same bound, and putting them there is the
mistake this package exists to prevent.Grants resolve per tool. A tool with no grant configured is refused rather than
allowed, which is the correct default and the opposite of what most gateway
software does.
Untrusted by default
Content returned by an MCP tool is untrusted unless you say otherwise. That is
the right default here more than anywhere: the premise of an open tool ecosystem
is that you did not write the thing on the other end.Where a tool result feeds an action that requires a clean context, gate 5
refuses it and the record names the tool and the step. See
Clean context.
{"docsConfig":{"theme":"mint","$schema":"https://mintlify.com/docs.json","name":"Rotascale","description":"RotaGrant documentation: state what an agent may do before it acts, refuse what exceeds it, and prove afterwards what was decided.","colors":{"primary":"#b509ac","light":"#ef8ce9","dark":"#b509ac"},"logo":{"light":"https://mintcdn.com/rotascale/ReWKDMCG0fRFm3DJ/assets/img/logo-lockup-light.png?fit=max\u0026auto=format\u0026n=ReWKDMCG0fRFm3DJ\u0026q=85\u0026s=8e5b17a4c59854ad5afb756b3c5e5e99","dark":"https://mintcdn.com/rotascale/ReWKDMCG0fRFm3DJ/assets/img/logo-lockup-light.png?fit=max\u0026auto=format\u0026n=ReWKDMCG0fRFm3DJ\u0026q=85\u0026s=8e5b17a4c59854ad5afb756b3c5e5e99","href":"https://rotascale.com"},"favicon":"https://mintcdn.com/rotascale/aTi_D90m7YBuHFsG/assets/img/favicon.svg?fit=max\u0026auto=format\u0026n=aTi_D90m7YBuHFsG\u0026q=85\u0026s=fe3c90d5fe514dc4f152e589f1e71ee4","api":{"playground":{"display":"simple"}},"appearance":{"default":"light","strict":true},"navbar":{"links":[{"href":"https://rotascale.com/contact/","label":"Contact"}],"primary":{"type":"button","label":"See it live","href":"https://rotascale.com/demo/"}},"footer":{"socials":{"website":"https://rotascale.com","github":"https://github.com/rotascale"},"links":[{"header":"Rotascale","items":[{"label":"Platform","href":"https://rotascale.com/platform"},{"label":"Security","href":"https://rotascale.com/security"},{"label":"Trust centre","href":"https://rotascale.com/trust"}]},{"header":"Build","items":[{"label":"Developers","href":"https://rotascale.com/developers"},{"label":"Specification","href":"https://rotascale.com/spec"},{"label":"Verify an artefact","href":"https://rotascale.com/verify"}]}]},"fonts":{"heading":{"family":"IBM Plex Sans","weight":470,"source":"https://docs.rotascale.com/assets/fonts/plex-sans-var.woff2","format":"woff2"},"body":{"family":"IBM Plex Sans","source":"https://docs.rotascale.com/assets/fonts/plex-sans-var.woff2","format":"woff2"}},"styling":{"eyebrows":"section","codeblocks":"system","latex":false},"integrations":{"ga4":{"measurementId":"G-6GCMKZ2SWH"}},"navigation":{"global":{"anchors":[{"anchor":"Live demo","icon":"play","href":"https://demo.rotascale.com"},{"anchor":"Specification","icon":"book","href":"https://rotascale.com/spec/"},{"anchor":"GitHub","icon":"github","href":"https://github.com/rotascale/rotascale-sdks"},{"anchor":"Blog","icon":"newspaper","href":"https://rotascale.com/blog/"}]},"pages":[]}},"deployment":{"deploymentMetadataValue":{"subdomain":"rotascale","hasAudioNarration":false,"actualSubdomain":"rotascale","customDomains":["docs.rotascale.com"],"gitSource":{"type":"github","owner":"rotascale","repo":"rotascale-docs","deployBranch":"main","contentDirectory":"","isPrivate":true,"mountPath":"","label":""},"entitlements":{"AI_CHAT":{"status":"DISABLED"}},"buildId":"6b01de58c7cbb24353cc5ca3","clientVersion":"0.0.4270","searchFilterCounts":[{"language":"default","tag":"API reference","count":142},{"language":"default","tag":"Every route","count":139},{"language":"default","tag":"Documentation","count":44},{"language":"default","tag":"Authority","count":34},{"language":"default","tag":"Core concepts","count":18},{"language":"default","tag":"Evidence","count":15},{"language":"default","tag":"Integrations","count":12},{"language":"default","tag":"Behaviour","count":12},{"language":"default","tag":"Registry","count":11},{"language":"default","tag":"Guides","count":9}]},"assistantConfig":{"enableAskAiButton":false,"enableStarterQuestions":false,"enableContextualStarterQuestions":false,"enableAskAiSearchBar":true},"basePath":"","hasChatPermissions":false,"hasWebMcpPermissions":false,"toggles":[{"name":"kill-isr","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-rbac-roles","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-mintlify-slack","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-integrations-settings","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"rbac-expansion","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-pr-grouping","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-prefix","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"analytics-v7","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"user-flows-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"no-publish-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-onboarding","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving-live","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"stripTemperatureMiddleware","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"support-platform-pylon-zendesk","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"instant-rollback","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications-server","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-fable","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fixed-ai-action-pricing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"site-roles","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automation-resolve-merge-conflict","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"scoped-publishing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"mintql","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"page-level-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-version-history-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-page-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"full-page-search","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workspace-projects","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"assistant-v5","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fork-pr-previews","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"revalidation-jwt","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-sso-scim","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"hobby-abuse-scan","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"dashboard-inbox","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-signup","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-dual-write","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-enabled","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"approve-review-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-metadata","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"sso-setup-deadline-banner","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-serve","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"live-agents","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"starter-pricing","enabled":true,"variant":{"name":"control","enabled":true,"payload":{"type":"string","value":"control"},"feature_enabled":true},"impressionData":false},{"name":"llms-txt-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"wildcard-email-auth","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false}],"googleFontsInlined":false},"customCss":[{"filePath":"style.css","content":"@font-face{font-family:\"IBM Plex Sans\";src:url(\"/assets/fonts/plex-sans-var.woff2\") format(\"woff2\");font-weight:100 700;font-style:normal;font-display:swap}@font-face{font-family:\"IBM Plex Sans\";src:url(\"/assets/fonts/plex-sans-400-italic.woff2\") format(\"woff2\");font-weight:400;font-style:italic;font-display:swap}@font-face{font-family:\"IBM Plex Mono\";src:url(\"/assets/fonts/plex-mono-400.woff2\") format(\"woff2\");font-weight:400;font-style:normal;font-display:swap}@font-face{font-family:\"IBM Plex Mono\";src:url(\"/assets/fonts/plex-mono-500.woff2\") format(\"woff2\");font-weight:500;font-style:normal;font-display:swap}:root{color-scheme:light;--rs-sans: \"IBM Plex Sans\", \"Helvetica Neue\", Helvetica, Arial, sans-serif;--rs-mono: \"IBM Plex Mono\", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;--rs-rule: #e0e0dc;--rs-rule-hard: #c9c9c2}[class*=\"rounded\"],.rounded,.rounded-md,.rounded-lg,.rounded-xl,.rounded-2xl,button,input,select,textarea,pre,code,img,table,blockquote,[class*=\"card\"],[class*=\"Card\"],[class*=\"callout\"],[class*=\"Callout\"]{border-radius:0!important}[class*=\"shadow\"],.shadow,.shadow-sm,.shadow-md,.shadow-lg,.shadow-xl{box-shadow:none!important}body,#content-area,.prose{font-family:var(--rs-sans)}#content-area h1,#content-area h2,#content-area h3,h1.mint-h1,h2,h1{font-family:var(--rs-sans);letter-spacing:-0.02em;font-weight:600}#content-area h1{font-size:2.45rem;line-height:1.1;font-weight:470;letter-spacing:-0.035em}#content-area h2:not(.not-prose){font-size:1.75rem;line-height:1.2;font-weight:470;letter-spacing:-0.028em;border-top:1px solid var(--rs-rule);padding-top:0.75em;margin-top:2.2em}#content-area h2.not-prose{font-size:1rem;font-weight:600;letter-spacing:-0.008em}#content-area h3{font-size:1.19rem;font-weight:600;letter-spacing:-0.01em}code,pre,kbd,.font-mono,[class*=\"mono\"]{font-family:var(--rs-mono)!important}pre code{font-size:13px;line-height:1.7}:not(pre)>code{background:transparent!important;border:0!important;padding:0!important;font-size:0.92em;color:inherit}:not(pre)>code::before,:not(pre)>code::after{content:\"\"!important}.eyebrow,[class*=\"eyebrow\"]{font-family:var(--rs-mono);font-size:11px;letter-spacing:0.09em;text-transform:uppercase}pre{border:0!important}#content-area table{border-collapse:collapse}#content-area th{font-family:var(--rs-mono);font-size:11px;font-weight:500;letter-spacing:0.05em;text-transform:uppercase;border-bottom:1px solid var(--rs-rule-hard)}#content-area td{border-bottom:1px solid var(--rs-rule)}.card{border:1px solid var(--rs-rule)!important}.card-group,[class*=\"card-group\"],[class*=\"cardGroup\"]{border:0!important}"}]}
{"page":{"pagePath":"sdk/mcp","slug":"/sdk/mcp","pageMetadata":{"title":"MCP SDK","description":"rotascale-mcp: expose your own tools with authorisation built in, so there is no unguarded path to them.","href":"/sdk/mcp"},"description":{"compiledSource":"\"use strict\";\nconst {jsx: _jsx} = arguments[0];\nconst {useMDXComponents: _provideComponents} = arguments[0];\nfunction _createMdxContent(props) {\n const _components = {\n p: \"p\",\n ..._provideComponents(),\n ...props.components\n };\n return _jsx(_components.p, {\n children: \"rotascale-mcp: expose your own tools with authorisation built in, so there is no unguarded path to them.\"\n });\n}\nfunction MDXContent(props = {}) {\n const {wrapper: MDXLayout} = {\n ..._provideComponents(),\n ...props.components\n };\n return MDXLayout ? _jsx(MDXLayout, {\n ...props,\n children: _jsx(_createMdxContent, {\n ...props\n })\n }) : _createMdxContent(props);\n}\nreturn {\n default: MDXContent\n};\n","frontmatter":{},"scope":{}},"pageType":"default","mdx":{"mdxSource":{"compiledSource":"\"use strict\";const{Fragment:_Fragment,jsx:_jsx,jsxs:_jsxs}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){const _components={a:`a`,code:`code`,p:`p`,pre:`pre`,span:`span`,strong:`strong`,tbody:`tbody`,td:`td`,th:`th`,thead:`thead`,tr:`tr`,..._provideComponents(),...props.components},{CodeBlock,Heading,Table}=_components;if(!CodeBlock)_missingMdxReference(`CodeBlock`,true);if(!Heading)_missingMdxReference(`Heading`,true);if(!Table)_missingMdxReference(`Table`,true);return _jsxs(_Fragment,{children:[_jsx(CodeBlock,{filename:``,numberOfLines:`1`,language:`shellscript`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`shellscript`,children:_jsxs(_components.code,{language:`shellscript`,numberOfLines:`1`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#DCDCAA`},children:`pip`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` install`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` rotascale-mcp`})]}),`\n`]})})}),`\n`,_jsx(_components.p,{children:`Two entry points ship:`}),`\n`,_jsxs(Table,{children:[_jsx(_components.thead,{children:_jsxs(_components.tr,{children:[_jsx(_components.th,{children:`Command`}),_jsx(_components.th,{children:`For`})]})}),_jsxs(_components.tbody,{children:[_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`rotascale-mcp`})}),_jsxs(_components.td,{children:[`A guarded MCP `,_jsx(_components.strong,{children:`server`}),`: your tools, with the gate in front`]})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`rotascale-mcp-proxy`})}),_jsxs(_components.td,{children:[`A `,_jsx(_components.strong,{children:`proxy`}),` in front of somebody else’s MCP server. See `,_jsx(_components.a,{href:`/sdk/mcp-proxy`,children:`the proxy`})]})]})]})]}),`\n`,_jsx(Heading,{level:`2`,id:`why-mcp-needs-this-more-than-most-integrations`,children:`Why MCP needs this more than most integrations`}),`\n`,_jsx(_components.p,{children:`An agent platform handing out OAuth scopes is granting a permission it cannot\nrecall, cannot bound and cannot attribute to a person. A grant has an expiry, a\nceiling and a named human. When the tools an agent reaches are ones you did not\nwrite, that difference stops being philosophical.`}),`\n`,_jsx(Heading,{level:`2`,id:`the-guarded-server`,children:`The guarded server`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`4`,language:`shellscript`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`shellscript`,children:_jsxs(_components.code,{language:`shellscript`,numberOfLines:`4`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`export`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` ROTASCALE_URL`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`=`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"https://rotagrant.internal.example\"`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`export`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` ROTASCALE_API_KEY`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`=`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"rsk_...\"`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`export`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` ROTASCALE_MCP_TRANSPORT`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`=`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"stdio\"`}),_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:` # or the HTTP transport`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#DCDCAA`},children:`rotascale-mcp`})}),`\n`]})})}),`\n`,_jsx(_components.p,{children:`Every tool call is authorised before it reaches your handler. A refusal is\nreturned to the caller as an MCP error carrying the outcome and the reason, not\nas a generic failure, so the agent on the other end can tell “not permitted”\nfrom “out of allowance” and stop retrying the second one.`}),`\n`,_jsx(Heading,{level:`2`,id:`mapping-tools-to-grants`,children:`Mapping tools to grants`}),`\n`,_jsx(_components.p,{children:`A server exposing ten tools is not one authority. A read tool and a tool that\nmoves money should not sit behind the same bound, and putting them there is the\nmistake this package exists to prevent.`}),`\n`,_jsx(_components.p,{children:`Grants resolve per tool. A tool with no grant configured is refused rather than\nallowed, which is the correct default and the opposite of what most gateway\nsoftware does.`}),`\n`,_jsx(Heading,{level:`2`,id:`untrusted-by-default`,children:`Untrusted by default`}),`\n`,_jsx(_components.p,{children:`Content returned by an MCP tool is untrusted unless you say otherwise. That is\nthe right default here more than anywhere: the premise of an open tool ecosystem\nis that you did not write the thing on the other end.`}),`\n`,_jsxs(_components.p,{children:[`Where a tool result feeds an action that requires a clean context, gate 5\nrefuses it and the record names the tool and the step. See\n`,_jsx(_components.a,{href:`/concepts/clean-context`,children:`Clean context`}),`.`]}),`\n`,_jsx(Heading,{level:`2`,id:`environment`,children:`Environment`}),`\n`,_jsxs(Table,{children:[_jsx(_components.thead,{children:_jsxs(_components.tr,{children:[_jsx(_components.th,{children:`Variable`}),_jsx(_components.th,{children:`Meaning`})]})}),_jsxs(_components.tbody,{children:[_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`ROTASCALE_URL`})}),_jsx(_components.td,{children:`Your deployment`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`ROTASCALE_API_KEY`})}),_jsxs(_components.td,{children:[`See `,_jsx(_components.a,{href:`/authentication`,children:`Authentication`})]})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`ROTASCALE_MCP_TRANSPORT`})}),_jsxs(_components.td,{children:[_jsx(_components.code,{children:`stdio`}),` by default`]})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`ROTASCALE_MCP_LOG`})}),_jsxs(_components.td,{children:[_jsx(_components.code,{children:`WARNING`}),` by default`]})]})]})]})]})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent};function _missingMdxReference(id,component){throw new Error(`Expected `+(component?`component`:`object`)+\" `\"+id+\"` to be defined: you likely forgot to import, pass, or provide it.\")}","frontmatter":{},"scope":{"codeStyling":"system","config":{},"pageMetadata":{"title":"MCP SDK","description":"rotascale-mcp: expose your own tools with authorisation built in, so there is no unguarded path to them.","href":"/sdk/mcp"}}},"mdxSourceWithNoJs":null},"mdxExtracts":{"tableOfContents":[{"title":"Why MCP needs this more than most integrations","slug":"why-mcp-needs-this-more-than-most-integrations","depth":2,"children":[]},{"title":"The guarded server","slug":"the-guarded-server","depth":2,"children":[]},{"title":"Mapping tools to grants","slug":"mapping-tools-to-grants","depth":2,"children":[]},{"title":"Untrusted by default","slug":"untrusted-by-default","depth":2,"children":[]},{"title":"Environment","slug":"environment","depth":2,"children":[]}],"codeExamples":{}},"jsLinks":["/_mintlify/custom/rotascale/3d630729d099c112/scripts/make-lockup.js"],"subdomain":"rotascale","siteName":"Rotascale","title":"MCP SDK - Rotascale","navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{}},"lastModified":"2026-11-21T18:08:34.770Z","originalFileLocation":"sdk/mcp.mdx"},"headHtml":"\u003cscript data-mint-head>(function(){var d=document.documentElement,p=\"light\";if(!p){try{p=localStorage.getItem(\"isDarkMode\")}catch(e){}if(p==='true')p='dark';else if(p==='false')p='light';if(p!=='light'\u0026\u0026p!=='dark'\u0026\u0026p!=='system')p=\"light\"}var r=p==='system'?(matchMedia(\"(prefers-color-scheme: dark)\").matches?'dark':'light'):p;d.classList.remove(r==='dark'?'light':'dark');d.classList.add(r);d.setAttribute(\"data-theme-preference\",p)})();\u003c/script>\u003cmeta data-mint-head name=\"description\" content=\"rotascale-mcp: expose your own tools with authorisation built in, so there is no unguarded path to them.\">\u003cmeta data-mint-head name=\"application-name\" content=\"Rotascale\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/rotascale/fnKwy0JVdAFTO57L/_generated/favicon/android-chrome-192x192.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"apple-touch-icon\" type=\"image/png\" sizes=\"180x180\" href=\"/mintlify-assets/_mintlify/favicons/rotascale/fnKwy0JVdAFTO57L/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/rotascale/fnKwy0JVdAFTO57L/_generated/favicon/favicon-16x16.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/rotascale/fnKwy0JVdAFTO57L/_generated/favicon/favicon-32x32.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/rotascale/fnKwy0JVdAFTO57L/_generated/favicon/favicon.ico\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/rotascale/fnKwy0JVdAFTO57L/_generated/favicon-dark/android-chrome-192x192.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/rotascale/fnKwy0JVdAFTO57L/_generated/favicon-dark/favicon-16x16.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/rotascale/fnKwy0JVdAFTO57L/_generated/favicon-dark/favicon-32x32.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/rotascale/fnKwy0JVdAFTO57L/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"MCP SDK - Rotascale\">\u003cmeta data-mint-head property=\"og:description\" content=\"rotascale-mcp: expose your own tools with authorisation built in, so there is no unguarded path to them.\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"Rotascale\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://docs.rotascale.com/sdk/mcp\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://rotascale.mintlify.site/_mintlify/api/og/v2?division=MCP\u0026amp;title=MCP+SDK\u0026amp;description=rotascale-mcp%3A+expose+your+own+tools+with+authorisation+built+in%2C+so+there+is+no+unguarded+path+to+them.\u0026amp;theme=41b62b677badfbb7253937e4\u0026amp;signature=e388d3139493aa6082f17a2ca8f36ca424478761b3905ed0115be7118524f4ad\">\u003cmeta data-mint-head property=\"og:image:width\" content=\"1200\">\u003cmeta data-mint-head property=\"og:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"twitter:card\" content=\"summary_large_image\">\u003cmeta data-mint-head name=\"twitter:title\" content=\"MCP SDK - Rotascale\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"rotascale-mcp: expose your own tools with authorisation built in, so there is no unguarded path to them.\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://rotascale.mintlify.site/_mintlify/api/og/v2?division=MCP\u0026amp;title=MCP+SDK\u0026amp;description=rotascale-mcp%3A+expose+your+own+tools+with+authorisation+built+in%2C+so+there+is+no+unguarded+path+to+them.\u0026amp;theme=41b62b677badfbb7253937e4\u0026amp;signature=e388d3139493aa6082f17a2ca8f36ca424478761b3905ed0115be7118524f4ad\">\u003cmeta data-mint-head name=\"twitter:image:width\" content=\"1200\">\u003cmeta data-mint-head name=\"twitter:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"msapplication-config\" content=\"/mintlify-assets/_mintlify/favicons/rotascale/fnKwy0JVdAFTO57L/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"Rotascale\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#b509ac\">\u003clink data-mint-head rel=\"canonical\" href=\"https://docs.rotascale.com/sdk/mcp\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/sdk/mcp.md\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://docs.rotascale.com/#organization\",\"name\":\"Rotascale\",\"url\":\"https://docs.rotascale.com\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https://mintcdn.com/rotascale/ReWKDMCG0fRFm3DJ/assets/img/logo-lockup-light.png?fit=max\u0026auto=format\u0026n=ReWKDMCG0fRFm3DJ\u0026q=85\u0026s=8e5b17a4c59854ad5afb756b3c5e5e99\"}},{\"@type\":\"WebSite\",\"@id\":\"https://docs.rotascale.com#website\",\"name\":\"Rotascale\",\"url\":\"https://docs.rotascale.com\",\"publisher\":{\"@id\":\"https://docs.rotascale.com/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://docs.rotascale.com/sdk/mcp#webpage\",\"url\":\"https://docs.rotascale.com/sdk/mcp\",\"name\":\"MCP SDK\",\"description\":\"rotascale-mcp: expose your own tools with authorisation built in, so there is no unguarded path to them.\",\"dateModified\":\"2026-11-21T18:08:34.770Z\",\"isPartOf\":{\"@id\":\"https://docs.rotascale.com#website\"},\"breadcrumb\":{\"@id\":\"https://docs.rotascale.com/sdk/mcp#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://docs.rotascale.com/sdk/mcp#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Rotascale\",\"item\":\"https://docs.rotascale.com\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"MCP SDK\",\"item\":\"https://docs.rotascale.com/sdk/mcp\"}]},{\"@type\":[\"Article\",\"TechArticle\"],\"@id\":\"https://docs.rotascale.com/sdk/mcp#article\",\"headline\":\"MCP SDK\",\"name\":\"MCP SDK\",\"description\":\"rotascale-mcp: expose your own tools with authorisation built in, so there is no unguarded path to them.\",\"url\":\"https://docs.rotascale.com/sdk/mcp\",\"mainEntityOfPage\":{\"@id\":\"https://docs.rotascale.com/sdk/mcp#webpage\"},\"dateModified\":\"2026-11-21T18:08:34.770Z\",\"publisher\":{\"@id\":\"https://docs.rotascale.com/#organization\"},\"isPartOf\":{\"@id\":\"https://docs.rotascale.com#website\"}}]}\u003c/script>\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"Rotascale\",\"publisher\":{\"@type\":\"Organization\",\"name\":\"Rotascale\"},\"provider\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","agentPointerHref":"/sdk/mcp.md","siteName":"Rotascale","nav":{"global":{"anchors":[{"anchor":"Live demo","icon":"play","href":"https://demo.rotascale.com"},{"anchor":"Specification","icon":"book","href":"https://rotascale.com/spec/"},{"anchor":"GitHub","icon":"github","href":"https://github.com/rotascale/rotascale-sdks"},{"anchor":"Blog","icon":"newspaper","href":"https://rotascale.com/blog/"}]},"tabs":[{"tab":"Documentation","pages":[{"title":"Documentation","href":"/introduction"}]},{"tab":"SDK","groups":[{"group":"Python","pages":[{"title":"Python SDK","href":"/sdk/python"},{"title":"Decisions","href":"/sdk/decisions"},{"title":"Framework middleware","href":"/sdk/middleware"}]},{"group":"TypeScript","pages":[{"title":"TypeScript SDK","description":"@rotascale/sdk: the same nine gates and six outcomes, from Node.","href":"/sdk/typescript"}]},{"group":"MCP","pages":[{"title":"MCP SDK","href":"/sdk/mcp"},{"title":"MCP proxy","description":"Govern an MCP server you did not write, without touching it. rotascale-mcp-proxy sits in front and authorises every tool call.","href":"/sdk/mcp-proxy"}]}]},{"tab":"API reference","pages":[{"title":"API reference","href":"/api/overview"}]}]},"basePath":"","title":"MCP SDK - Rotascale","deploymentId":"dpl_DyXGnKeCjZyA3sUdfMJ7FjkdBefg","buildId":"dpl_DyXGnKeCjZyA3sUdfMJ7FjkdBefg","dynamics":[],"chunks":[]}