Point an agent at Lurk. It reads your project, writes rules as drafts and previews them. Going live always waits for a person.
Lurk’s optional MCP server exposes the API as typed tools at https://api.getlurk.com/mcp. It is stateless and speaks JSON over Streamable HTTP (POST only).
Connect
This page connects an agent with a key. To connect your own assistant as yourself, with no key, see Connect your assistant.Make an agent key in Developers → Agents (one per agent, to revoke one alone). Put it in an environment variable.
Set the URL and an Authorization: Bearer <key> header in your client’s MCP settings.
A project key (lurk_sk_…) works too, but an agent key puts the agent’s name on its receipts and proposals, and can be revoked without touching your server.
Never put a key in a repository or a shared prompt. Use an environment variable, and ask your agent to read it by name.
What it can do
See MCP tools for every tool an agent key sees. An agent can use lurk.apply to ask a person to approve creating an audience, adding people to a list or taking back an added template.
What it cannot do, on purpose
Going live (rules.publish, rules.resume), deciding proposals and held changes, giving units by hand, spending, using and sending units, undoing, creating or changing units, arranging dashboards (read one view at a time with lurk.views.get), credentials, the team, project settings, and copying between projects. A person does these in the dashboard.When an agent needs one, the call answers approval_required with a link. That is not an error: the agent gives the person the link and stops. See Going live.
Errors and limits
A tool that fails answers the same error body as the REST API, with a next_step: see Errors. The same limits apply.A rate-limited tool call has isError: true and error.code: "rate_limited" in its text content, even when the HTTP response is 200. Its result includes _meta["getlurk.com/retry-after-seconds"], the seconds to wait before retrying with the same idempotency key. Read it, not an HTTP Retry-After header. No other tool error has it.
Docs for agents
These docs are agent-readable: /llms.txt, /llms-full.txt, a Copy as Markdown menu on every page, and a docs MCP server at https://docs.getlurk.com/mcp. For a brief for your agent’s instructions, see Agent instructions.
{"docsConfig":{"theme":"mint","$schema":"https://mintlify.com/docs.json","name":"Lurk","description":"Events in, rules decide, units change, receipts out. For apps and for agents.","colors":{"primary":"#E4572E","light":"#FF8A63","dark":"#B23A16"},"favicon":"https://mintcdn.com/lurk/nFoY2f_SKS2sofMT/favicon.svg?fit=max\u0026auto=format\u0026n=nFoY2f_SKS2sofMT\u0026q=85\u0026s=34f6a2e159c17a9241f6736fa3e1cd46","api":{"playground":{"display":"interactive"},"examples":{"languages":["curl","javascript","python"]}},"navbar":{"links":[{"href":"https://app.getlurk.com","label":"Dashboard"}],"primary":{"type":"button","label":"Join the waitlist","href":"https://getlurk.com/waitlist"}},"footer":{"socials":{"github":"https://github.com/getlurk"}},"contextual":{"options":["copy","view","claude","chatgpt","mcp","cursor"],"display":"header"},"styling":{"latex":false},"navigation":{"pages":[]}},"deployment":{"deploymentMetadataValue":{"subdomain":"lurk","hasAudioNarration":false,"actualSubdomain":"lurk","customDomains":["docs.getlurk.com"],"gitSource":{"type":"github","owner":"getlurk","repo":"lurk","deployBranch":"main","contentDirectory":"apps/docs","isPrivate":true,"mountPath":"","label":"","_id":"6b1102f59ffae5051c41e9a6"},"entitlements":{"AI_CHAT":{"status":"DISABLED"},"WEB_MCP":{"status":"DISABLED"},"NARRATION":{"status":"DISABLED"}},"buildId":"6b130e72cb18fd5c6c14b608","clientVersion":"0.0.4450","searchFilterCounts":[{"language":"default","tag":"API reference","count":81},{"language":"default","tag":"Docs","count":60},{"language":"default","tag":"Agents","count":11},{"language":"default","tag":"Primitives","count":10},{"language":"default","tag":"People","count":10},{"language":"default","tag":"Guides","count":9},{"language":"default","tag":"Rules","count":9},{"language":"default","tag":"Units","count":9},{"language":"default","tag":"End-user sign-in","count":8},{"language":"default","tag":"Trusted issuers","count":8}]},"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":"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":"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":"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":"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":"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":"turbopuffer-dual-write","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":"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":"treatment","enabled":true,"payload":{"type":"string","value":"treatment"},"feature_enabled":true},"impressionData":false},{"name":"llms-txt-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"auth-vite-origin","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false}],"starterQuestions":[],"googleFontsInlined":false},"customCss":[]}
{"page":{"pagePath":"mcp-server","slug":"/mcp-server","pageMetadata":{"title":"MCP server","description":"Point an agent at Lurk. It reads your project, writes rules as drafts and previews them. Going live always waits for a person.","keywords":["mcp","model context protocol","tools","agent","claude code","cursor","lurk.apply","draft"],"href":"/mcp-server"},"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: \"Point an agent at Lurk. It reads your project, writes rules as drafts and previews them. Going live always waits for a person.\"\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`,..._provideComponents(),...props.components},{CodeBlock,Heading,Tab,Tabs,Warning}=_components;if(!CodeBlock)_missingMdxReference(`CodeBlock`,true);if(!Heading)_missingMdxReference(`Heading`,true);if(!Tab)_missingMdxReference(`Tab`,true);if(!Tabs)_missingMdxReference(`Tabs`,true);if(!Warning)_missingMdxReference(`Warning`,true);return _jsxs(_Fragment,{children:[_jsxs(_components.p,{children:[`Lurk’s `,_jsx(_components.strong,{children:`optional`}),` MCP server exposes the `,_jsx(_components.a,{href:`/quickstart`,children:`API`}),` as typed tools at `,_jsx(_components.code,{children:`https://api.getlurk.com/mcp`}),`. It is stateless and speaks JSON over Streamable HTTP (`,_jsx(_components.code,{children:`POST`}),` only).`]}),`\n`,_jsx(Heading,{level:`2`,id:`connect`,children:`Connect`}),`\n`,_jsxs(_components.p,{children:[`This page connects an agent with a key. To connect your own assistant as yourself, with no key, see `,_jsx(_components.a,{href:`/connect-your-assistant`,children:`Connect your assistant`}),`.`]}),`\n`,_jsxs(_components.p,{children:[`Make an `,_jsx(_components.strong,{children:`agent key`}),` in `,_jsx(_components.strong,{children:`Developers → Agents`}),` (one per agent, to revoke one alone). Put it in an environment variable.`]}),`\n`,_jsxs(Tabs,{children:[_jsxs(Tab,{title:`Claude Code`,id:`claude-code`,children:[_jsx(CodeBlock,{filename:``,numberOfLines:`2`,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:`2`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#DCDCAA`},children:`claude`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` mcp`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` add`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` --transport`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` http`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` lurk`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` https://api.getlurk.com/mcp`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D7BA7D`},children:` \\\\`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` --header`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:\" 'Authorization: Bearer ${LURK_AGENT_KEY}'\"})]}),`\n`]})})}),_jsxs(_components.p,{children:[`Keep the single quotes: Claude Code reads `,_jsx(_components.code,{children:`LURK_AGENT_KEY`}),` at each connection, so the key never lands in its config file.`]}),_jsx(CodeBlock,{filename:``,numberOfLines:`2`,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:`2`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`# Check it: lurk should say Connected`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#DCDCAA`},children:`claude`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` mcp`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` list`})]}),`\n`]})})})]}),_jsx(Tab,{title:`Cursor`,id:`cursor`,children:_jsx(CodeBlock,{filename:`.cursor/mcp.json`,numberOfLines:`8`,language:`json`,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:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`8`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"mcpServers\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"lurk\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"url\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"https://api.getlurk.com/mcp\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"headers\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: { `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"Authorization\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:'\"Bearer ${env:LURK_AGENT_KEY}\"'}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})})}),_jsx(Tab,{title:`VS Code`,id:`vs-code`,children:_jsx(CodeBlock,{filename:`.vscode/mcp.json`,numberOfLines:`10`,language:`json`,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:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`10`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"servers\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"lurk\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"type\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"http\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"url\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"https://api.getlurk.com/mcp\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"headers\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: { `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"Authorization\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:'\"Bearer ${input:lurk-agent-key}\"'}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"inputs\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: [{ `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"id\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"lurk-agent-key\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"type\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"promptString\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"description\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Lurk agent key\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"password\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:`true`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }]`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})})}),_jsxs(Tab,{title:`Any other client`,id:`any-other-client`,children:[_jsx(CodeBlock,{filename:``,numberOfLines:`8`,language:`json`,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:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`8`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"mcpServers\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"lurk\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"url\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"https://api.getlurk.com/mcp\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"headers\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: { `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"Authorization\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Bearer lurk_ak_…\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),_jsxs(_components.p,{children:[`Set the URL and an `,_jsx(_components.code,{children:`Authorization: Bearer \u003ckey>`}),` header in your client’s MCP settings.`]})]})]}),`\n`,_jsxs(_components.p,{children:[`A project key (`,_jsx(_components.code,{children:`lurk_sk_…`}),`) works too, but an agent key puts the agent’s name on its receipts and proposals, and can be revoked without touching your server.`]}),`\n`,_jsx(Warning,{children:`Never put a key in a repository or a shared prompt. Use an environment variable, and ask your agent to read it by name.`}),`\n`,_jsx(Heading,{level:`2`,id:`what-it-can-do`,children:`What it can do`}),`\n`,_jsxs(_components.p,{children:[`See `,_jsx(_components.a,{href:`/mcp-tools`,children:`MCP tools`}),` for every tool an agent key sees. An agent can use `,_jsx(_components.code,{children:`lurk.apply`}),` to ask a person to approve creating an audience, adding people to a list or taking back an added template.`]}),`\n`,_jsx(Heading,{level:`2`,id:`what-it-cannot-do-on-purpose`,children:`What it cannot do, on purpose`}),`\n`,_jsxs(_components.p,{children:[`Going live (`,_jsx(_components.code,{children:`rules.publish`}),`, `,_jsx(_components.code,{children:`rules.resume`}),`), deciding proposals and held changes, giving units by hand, spending, using and sending units, undoing, creating or changing units, arranging dashboards (read one view at a time with `,_jsx(_components.code,{children:`lurk.views.get`}),`), credentials, the team, project settings, and copying between projects. A person does these in the dashboard.`]}),`\n`,_jsxs(_components.p,{children:[`When an agent needs one, the call answers `,_jsx(_components.code,{children:`approval_required`}),` with a link. That is not an error: the agent gives the person the link and stops. See `,_jsx(_components.a,{href:`/guides/going-live`,children:`Going live`}),`.`]}),`\n`,_jsx(Heading,{level:`2`,id:`errors-and-limits`,children:`Errors and limits`}),`\n`,_jsxs(_components.p,{children:[`A tool that fails answers the same error body as the REST API, with a `,_jsx(_components.code,{children:`next_step`}),`: see `,_jsx(_components.a,{href:`/errors`,children:`Errors`}),`. The same `,_jsx(_components.a,{href:`/guides/idempotency-and-retries#limits`,children:`limits`}),` apply.`]}),`\n`,_jsxs(_components.p,{children:[`A rate-limited tool call has `,_jsx(_components.code,{children:`isError: true`}),` and `,_jsx(_components.code,{children:`error.code: \"rate_limited\"`}),` in its text content, even when the HTTP response is 200. Its result includes `,_jsx(_components.code,{children:`_meta[\"getlurk.com/retry-after-seconds\"]`}),`, the seconds to wait before retrying with the same idempotency key. Read it, not an HTTP `,_jsx(_components.code,{children:`Retry-After`}),` header. No other tool error has it.`]}),`\n`,_jsx(Heading,{level:`2`,id:`docs-for-agents`,children:`Docs for agents`}),`\n`,_jsxs(_components.p,{children:[`These docs are agent-readable: `,_jsx(_components.a,{href:`https://docs.getlurk.com/llms.txt`,children:_jsx(_components.code,{children:`/llms.txt`})}),`, `,_jsx(_components.a,{href:`https://docs.getlurk.com/llms-full.txt`,children:_jsx(_components.code,{children:`/llms-full.txt`})}),`, a `,_jsx(_components.strong,{children:`Copy as Markdown`}),` menu on every page, and a docs MCP server at `,_jsx(_components.code,{children:`https://docs.getlurk.com/mcp`}),`. For a brief for your agent’s instructions, see `,_jsx(_components.a,{href:`/agent-instructions`,children:`Agent instructions`}),`.`]})]})}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":{"config":{},"pageMetadata":{"title":"MCP server","description":"Point an agent at Lurk. It reads your project, writes rules as drafts and previews them. Going live always waits for a person.","keywords":["mcp","model context protocol","tools","agent","claude code","cursor","lurk.apply","draft"],"href":"/mcp-server"}}},"mdxSourceWithNoJs":null},"mdxExtracts":{"tableOfContents":[{"title":"Connect","slug":"connect","depth":2,"children":[]},{"title":"What it can do","slug":"what-it-can-do","depth":2,"children":[]},{"title":"What it cannot do, on purpose","slug":"what-it-cannot-do-on-purpose","depth":2,"children":[]},{"title":"Errors and limits","slug":"errors-and-limits","depth":2,"children":[]},{"title":"Docs for agents","slug":"docs-for-agents","depth":2,"children":[]}],"codeExamples":{}},"jsLinks":[],"subdomain":"lurk","siteName":"Lurk","title":"MCP server - Lurk","contextualStarterQuestions":[],"navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{}},"lastModified":"2026-11-20T19:05:08.660Z","originalFileLocation":"mcp-server.mdx"},"headHtml":"\u003cscript data-mint-head>(function(){var d=document.documentElement,p=null;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=\"system\"}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=\"Point an agent at Lurk. It reads your project, writes rules as drafts and previews them. Going live always waits for a person.\">\u003cmeta data-mint-head name=\"application-name\" content=\"Lurk\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/lurk/l-5wOCcrYMBCQB9Y/_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/lurk/l-5wOCcrYMBCQB9Y/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/lurk/l-5wOCcrYMBCQB9Y/_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/lurk/l-5wOCcrYMBCQB9Y/_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/lurk/l-5wOCcrYMBCQB9Y/_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/lurk/l-5wOCcrYMBCQB9Y/_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/lurk/l-5wOCcrYMBCQB9Y/_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/lurk/l-5wOCcrYMBCQB9Y/_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/lurk/l-5wOCcrYMBCQB9Y/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"MCP server - Lurk\">\u003cmeta data-mint-head property=\"og:description\" content=\"Point an agent at Lurk. It reads your project, writes rules as drafts and previews them. Going live always waits for a person.\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"Lurk\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://docs.getlurk.com/mcp-server\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://lurk.mintlify.site/_mintlify/api/og/v2?division=Agents\u0026amp;title=MCP+server\u0026amp;description=Point+an+agent+at+Lurk.+It+reads+your+project%2C+writes+rules+as+drafts+and+previews+them.+Going+live+always+waits+for+a+person.\u0026amp;theme=7795adf5e2483b4811d7796b\u0026amp;signature=a89da9c86e47b1dc4b8bf1826ffdcdb686870782aeb401b4dfa8ba12bb21867c\">\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 server - Lurk\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"Point an agent at Lurk. It reads your project, writes rules as drafts and previews them. Going live always waits for a person.\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://lurk.mintlify.site/_mintlify/api/og/v2?division=Agents\u0026amp;title=MCP+server\u0026amp;description=Point+an+agent+at+Lurk.+It+reads+your+project%2C+writes+rules+as+drafts+and+previews+them.+Going+live+always+waits+for+a+person.\u0026amp;theme=7795adf5e2483b4811d7796b\u0026amp;signature=a89da9c86e47b1dc4b8bf1826ffdcdb686870782aeb401b4dfa8ba12bb21867c\">\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/lurk/l-5wOCcrYMBCQB9Y/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"Lurk\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#E4572E\">\u003clink data-mint-head rel=\"canonical\" href=\"https://docs.getlurk.com/mcp-server\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/mcp-server.md\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://docs.getlurk.com/#organization\",\"name\":\"Lurk\",\"url\":\"https://docs.getlurk.com\"},{\"@type\":\"WebSite\",\"@id\":\"https://docs.getlurk.com#website\",\"name\":\"Lurk\",\"url\":\"https://docs.getlurk.com\",\"publisher\":{\"@id\":\"https://docs.getlurk.com/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://docs.getlurk.com/mcp-server#webpage\",\"url\":\"https://docs.getlurk.com/mcp-server\",\"name\":\"MCP server\",\"description\":\"Point an agent at Lurk. It reads your project, writes rules as drafts and previews them. Going live always waits for a person.\",\"dateModified\":\"2026-11-20T19:05:08.660Z\",\"isPartOf\":{\"@id\":\"https://docs.getlurk.com#website\"},\"breadcrumb\":{\"@id\":\"https://docs.getlurk.com/mcp-server#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://docs.getlurk.com/mcp-server#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Agents\",\"item\":\"https://docs.getlurk.com/connect-your-assistant\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"MCP server\",\"item\":\"https://docs.getlurk.com/mcp-server\"}]},{\"@type\":[\"Article\",\"TechArticle\"],\"@id\":\"https://docs.getlurk.com/mcp-server#article\",\"headline\":\"MCP server\",\"name\":\"MCP server\",\"description\":\"Point an agent at Lurk. It reads your project, writes rules as drafts and previews them. Going live always waits for a person.\",\"url\":\"https://docs.getlurk.com/mcp-server\",\"mainEntityOfPage\":{\"@id\":\"https://docs.getlurk.com/mcp-server#webpage\"},\"dateModified\":\"2026-11-20T19:05:08.660Z\",\"keywords\":\"mcp, model context protocol, tools, agent, claude code, cursor, lurk.apply, draft\",\"publisher\":{\"@id\":\"https://docs.getlurk.com/#organization\"},\"isPartOf\":{\"@id\":\"https://docs.getlurk.com#website\"}}]}\u003c/script>\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"Lurk\",\"publisher\":{\"@type\":\"Organization\",\"name\":\"Lurk\"},\"provider\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","agentPointerHref":"/mcp-server.md","siteName":"Lurk","nav":{"global":null,"tabs":[{"tab":"Docs","groups":[{"group":"Get started","pages":[{"title":"Lurk","href":""},{"title":"Quickstart","href":"/quickstart"},{"title":"Concepts","href":"/concepts"},{"title":"Build with an agent","href":"/build-with-an-agent"},{"title":"Projects and keys","href":"/projects-and-keys"}]},{"group":"SDKs","pages":[{"title":"SDKs","href":"/sdks/overview"},{"title":"TypeScript and JavaScript","href":"/sdks/typescript"},{"title":"Python","href":"/sdks/python"},{"title":"Test your integration","href":"/sdks/testing"}]},{"group":"Primitives","pages":[{"title":"Events","href":"/events"},{"title":"Rules","href":"/rules"},{"title":"Balance and schedule triggers","href":"/rule-triggers"},{"title":"Units","href":"/units"},{"title":"Levels, passes and appearance","href":"/unit-patterns"},{"title":"Resets, supply and expiry","href":"/unit-limits"},{"title":"Audiences","href":"/audiences"},{"title":"Activity","href":"/activity"},{"title":"Views","href":"/views"},{"title":"Annotations","href":"/annotations"}]},{"group":"Using the dashboard","pages":[{"title":"Build a rule","href":"/dashboard/build-a-rule"},{"title":"Read Activity","href":"/dashboard/read-activity"},{"title":"Manage people","href":"/dashboard/manage-people"},{"title":"Go live","href":"/dashboard/go-live"}]},{"group":"Guides","pages":[{"title":"People","href":"/guides/people"},{"title":"Reading people","href":"/guides/reading-people"},{"title":"Merging people","href":"/guides/merging-people"},{"title":"Going live","href":"/guides/going-live"},{"title":"Idempotency, retries and limits","href":"/guides/idempotency-and-retries"},{"title":"Pagination","href":"/guides/pagination"},{"title":"Versioning and deprecation","href":"/guides/versioning"},{"title":"Privacy and AI","href":"/guides/privacy-and-ai"},{"title":"Send feedback","href":"/guides/send-feedback"}]},{"group":"Web analytics","pages":[{"title":"Install web analytics","href":"/web/install"},{"title":"Web analytics relay recipes","href":"/web/relay-recipes"},{"title":"How web analytics counts","href":"/web/definitions"},{"title":"Web analytics and privacy","href":"/web/privacy"},{"title":"Why a report has no numbers","href":"/web/no-numbers"}]},{"group":"End-user sign-in","pages":[{"title":"Sign-in for your app's users","href":"/end-user-auth/overview"},{"title":"Add a trusted issuer","href":"/end-user-auth/add-a-trusted-issuer"},{"title":"Sign-in with Clerk","href":"/end-user-auth/clerk"},{"title":"Sign-in with Supabase","href":"/end-user-auth/supabase"},{"title":"Sign-in with another provider","href":"/end-user-auth/other-providers"},{"title":"Linking people","href":"/end-user-auth/linking-people"},{"title":"Client API","href":"/end-user-auth/client-api"},{"title":"Sign-in troubleshooting","href":"/end-user-auth/troubleshooting"}]},{"group":"Agents","pages":[{"title":"Connect your assistant","href":"/connect-your-assistant"},{"title":"Setup prompt","description":"The prompt that has your own assistant connect itself to Lurk's MCP server. Point it at this page's Markdown, or paste it.","href":"/agent-setup/prompt"},{"title":"MCP server","href":"/mcp-server"},{"title":"MCP tools","description":"Every tool an agent key sees, by what it does: read, change something, and not available yet.","href":"/mcp-tools"},{"title":"Agent instructions","href":"/agent-instructions"},{"group":"Agent skill","pages":[{"title":"Agent skill","href":"/agent-skill"},{"title":"Agent skill: events","sidebarTitle":"Skill: events","href":"/agent-skill/events"},{"title":"Agent skill: rules","sidebarTitle":"Skill: rules","href":"/agent-skill/rules"},{"title":"Agent skill: MCP","sidebarTitle":"Skill: MCP","href":"/agent-skill/mcp"},{"title":"Agent skill: errors","sidebarTitle":"Skill: errors","href":"/agent-skill/errors"},{"title":"Agent skill: a person's own assistant","sidebarTitle":"Skill: your own assistant","href":"/agent-skill/member-assistant"}]}]},{"group":"Reference","pages":[{"title":"Webhooks","href":"/webhooks"},{"title":"Rate limits","href":"/rate-limits"},{"title":"Errors","href":"/errors"},{"title":"Changelog","href":"/changelog"}]}]},{"tab":"API reference","pages":[{"title":"API reference","href":"/api-reference/events/send-an-event"}]}]},"basePath":"","title":"MCP server - Lurk","deploymentId":"dpl_BEYRRXz1HkchnQ2yWX4JUQCbQT5Q","buildId":"dpl_BEYRRXz1HkchnQ2yWX4JUQCbQT5Q","dynamics":[],"chunks":[]}