@cursor/july 0.1.93 → 0.1.95
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/AGENTS.md +8 -20
- package/README.md +4 -26
- package/dist/channels/github/github-channel.d.ts.map +1 -1
- package/dist/channels/github/github-channel.js +14 -2
- package/dist/channels/github/types.d.ts +18 -3
- package/dist/channels/github/types.d.ts.map +1 -1
- package/dist/channels/origin/origin-channel.d.ts.map +1 -1
- package/dist/channels/origin/origin-channel.js +11 -3
- package/dist/channels/origin/origin-webhook.d.ts +11 -1
- package/dist/channels/origin/origin-webhook.d.ts.map +1 -1
- package/dist/channels/origin/origin-webhook.js +23 -3
- package/dist/channels/origin/types.d.ts +8 -0
- package/dist/channels/origin/types.d.ts.map +1 -1
- package/dist/channels/slack/attachments.js +2 -2
- package/dist/channels/slack/dispatch.d.ts +0 -7
- package/dist/channels/slack/dispatch.d.ts.map +1 -1
- package/dist/channels/slack/dispatch.js +4 -7
- package/dist/channels/slack/eval-directive.d.ts +5 -12
- package/dist/channels/slack/eval-directive.d.ts.map +1 -1
- package/dist/channels/slack/eval-directive.js +8 -19
- package/dist/channels/slack/index.d.ts +0 -6
- package/dist/channels/slack/index.d.ts.map +1 -1
- package/dist/channels/slack/index.js +0 -6
- package/dist/channels/slack/pr-ref.d.ts +7 -1
- package/dist/channels/slack/pr-ref.d.ts.map +1 -1
- package/dist/channels/slack/pr-ref.js +42 -23
- package/dist/channels/slack/setup.d.ts +4 -4
- package/dist/channels/slack/setup.d.ts.map +1 -1
- package/dist/channels/slack/setup.js +8 -15
- package/dist/channels/slack/slack-channel.d.ts +6 -13
- package/dist/channels/slack/slack-channel.d.ts.map +1 -1
- package/dist/channels/slack/slack-channel.js +15 -101
- package/dist/channels/slack/types.d.ts +12 -79
- package/dist/channels/slack/types.d.ts.map +1 -1
- package/dist/channels/slack/types.js +1 -15
- package/dist/client.d.ts +14 -0
- package/dist/client.d.ts.map +1 -0
- package/dist/client.js +12 -0
- package/dist/connections.d.ts +18 -9
- package/dist/connections.d.ts.map +1 -1
- package/dist/connections.js +17 -8
- package/dist/docs/404.html +2 -2
- package/dist/docs/ab.html +4 -4
- package/dist/docs/assets/{app.CjWU-x0z.js → app.BBj0klBO.js} +1 -1
- package/dist/docs/assets/chunks/@localSearchIndexroot.oqPawjiD.js +1 -0
- package/dist/docs/assets/chunks/{VPLocalSearchBox.Cxy8ySFQ.js → VPLocalSearchBox.CUEXpL78.js} +1 -1
- package/dist/docs/assets/chunks/{theme.Dvq1Bktu.js → theme.DabmQnia.js} +2 -2
- package/dist/docs/assets/concepts.md.lwAgBIMI.js +1 -0
- package/dist/docs/assets/{deployment.md.DoLFAzfm.js → deployment.md.D9msOFOW.js} +3 -8
- package/dist/docs/assets/{deployment.md.DoLFAzfm.lean.js → deployment.md.D9msOFOW.lean.js} +1 -1
- package/dist/docs/assets/{guides_agent-to-agent.md.B3JIaAqz.js → guides_agent-to-agent.md.BDb0t1QV.js} +1 -1
- package/dist/docs/assets/guides_cloud-runtime.md.CkYbjnAX.js +9 -0
- package/dist/docs/assets/guides_cloud-runtime.md.CkYbjnAX.lean.js +1 -0
- package/dist/docs/assets/{guides_convert-automation.md.Bboisykk.js → guides_convert-automation.md.B4sjlodG.js} +1 -1
- package/dist/docs/assets/{guides_github.md.DqJhuaN1.js → guides_github.md.Cnh2mL4a.js} +1 -1
- package/dist/docs/assets/{guides_mcp-oauth.md.CJvrXtkN.js → guides_mcp-oauth.md.DPYmBCbV.js} +7 -9
- package/dist/docs/assets/{guides_mcp-oauth.md.CJvrXtkN.lean.js → guides_mcp-oauth.md.DPYmBCbV.lean.js} +1 -1
- package/dist/docs/assets/{guides_slack.md.mqeNKs84.js → guides_slack.md.C32HsdKk.js} +5 -11
- package/dist/docs/assets/guides_slack.md.C32HsdKk.lean.js +1 -0
- package/dist/docs/assets/index.md.BoHaMdeZ.js +5 -0
- package/dist/docs/assets/{index.md.B-lVR4wT.lean.js → index.md.BoHaMdeZ.lean.js} +1 -1
- package/dist/docs/assets/{quickstart.md.BrmfrrIr.js → quickstart.md.Nj_LjW_a.js} +1 -1
- package/dist/docs/assets/{reference_cli.md.D9KESDsD.js → reference_cli.md.BsMOxDvh.js} +4 -3
- package/dist/docs/assets/{reference_cli.md.D9KESDsD.lean.js → reference_cli.md.BsMOxDvh.lean.js} +1 -1
- package/dist/docs/assets/{reference_connections.md.DB6SsN6U.js → reference_connections.md.BH8Oc0D0.js} +5 -5
- package/dist/docs/assets/{reference_connections.md.DB6SsN6U.lean.js → reference_connections.md.BH8Oc0D0.lean.js} +1 -1
- package/dist/docs/assets/{reference_hooks.md.BxN87gCw.js → reference_hooks.md.a8BJxMR5.js} +1 -1
- package/dist/docs/assets/reference_http-api.md.D89k1mdm.js +11 -0
- package/dist/docs/assets/reference_http-api.md.D89k1mdm.lean.js +1 -0
- package/dist/docs/assets/reference_project-layout.md.Bv4KOtlB.js +19 -0
- package/dist/docs/assets/{reference_subagents.md.Xoav0AII.js → reference_subagents.md.CfsIloPm.js} +1 -1
- package/dist/docs/assets/{reference_tools.md.DuKvkYWG.js → reference_tools.md.BHeXn2id.js} +3 -3
- package/dist/docs/assets/{reference_tools.md.DuKvkYWG.lean.js → reference_tools.md.BHeXn2id.lean.js} +1 -1
- package/dist/docs/assets/{templates_agentic-owners.md.DqtPdm6f.js → templates_agentic-owners.md.BZSH4N9z.js} +1 -1
- package/dist/docs/assets/{templates_demo.md.DhFcWN6j.js → templates_demo.md.BeQX9V3H.js} +1 -1
- package/dist/docs/assets/{templates_pr-autofixer.md.R4K_qytS.js → templates_pr-autofixer.md.x5zl6-GT.js} +2 -2
- package/dist/docs/assets/{templates_pr-autofixer.md.R4K_qytS.lean.js → templates_pr-autofixer.md.x5zl6-GT.lean.js} +1 -1
- package/dist/docs/assets/templates_security-help.md.C3Ny_Qr2.js +4 -0
- package/dist/docs/assets/templates_security-help.md.C3Ny_Qr2.lean.js +1 -0
- package/dist/docs/assets/{templates_security-reviewer.md.ByFyRta2.js → templates_security-reviewer.md.lshxbCLK.js} +2 -2
- package/dist/docs/assets/{templates_security-reviewer.md.ByFyRta2.lean.js → templates_security-reviewer.md.lshxbCLK.lean.js} +1 -1
- package/dist/docs/assets/{templates_triage.md.CVlpctKS.js → templates_triage.md.Co4UNzkZ.js} +3 -3
- package/dist/docs/assets/{templates_triage.md.CVlpctKS.lean.js → templates_triage.md.Co4UNzkZ.lean.js} +1 -1
- package/dist/docs/assets/troubleshooting.md.Ctv3T8C2.js +1 -0
- package/dist/docs/building-with-agents.html +4 -4
- package/dist/docs/concepts.html +5 -5
- package/dist/docs/concepts.md +1 -0
- package/dist/docs/deployment.html +7 -12
- package/dist/docs/deployment.md +1 -20
- package/dist/docs/design/agsh.md +406 -0
- package/dist/docs/evals.html +4 -4
- package/dist/docs/guides/agent-to-agent.html +6 -6
- package/dist/docs/guides/agent-to-agent.md +2 -2
- package/dist/docs/guides/cloud-runtime.html +6 -6
- package/dist/docs/guides/cloud-runtime.md +1 -0
- package/dist/docs/guides/convert-automation.html +6 -6
- package/dist/docs/guides/convert-automation.md +1 -1
- package/dist/docs/guides/github.html +6 -6
- package/dist/docs/guides/github.md +4 -4
- package/dist/docs/guides/human-in-the-loop.html +4 -4
- package/dist/docs/guides/mcp-oauth.html +11 -13
- package/dist/docs/guides/mcp-oauth.md +10 -18
- package/dist/docs/guides/opentelemetry.html +5 -5
- package/dist/docs/guides/slack.html +9 -15
- package/dist/docs/guides/slack.md +9 -46
- package/dist/docs/guides/webhooks.html +4 -4
- package/dist/docs/hashmap.json +1 -1
- package/dist/docs/hillclimbing.html +4 -4
- package/dist/docs/index.html +6 -6
- package/dist/docs/index.md +3 -29
- package/dist/docs/llms-full.txt +756 -2810
- package/dist/docs/llms.txt +3 -16
- package/dist/docs/quickstart.html +6 -6
- package/dist/docs/quickstart.md +2 -3
- package/dist/docs/reference/agent-config.html +4 -4
- package/dist/docs/reference/artifacts.html +4 -4
- package/dist/docs/reference/channels.html +4 -4
- package/dist/docs/reference/cli.html +8 -7
- package/dist/docs/reference/cli.md +5 -2
- package/dist/docs/reference/connections.html +9 -9
- package/dist/docs/reference/connections.md +15 -11
- package/dist/docs/reference/hooks.html +6 -6
- package/dist/docs/reference/hooks.md +2 -3
- package/dist/docs/reference/http-api.html +6 -6
- package/dist/docs/reference/http-api.md +8 -0
- package/dist/docs/reference/instructions.html +4 -4
- package/dist/docs/reference/playground.html +4 -4
- package/dist/docs/reference/project-layout.html +8 -6
- package/dist/docs/reference/project-layout.md +5 -1
- package/dist/docs/reference/prompt.html +4 -4
- package/dist/docs/reference/schedules.html +4 -4
- package/dist/docs/reference/sessions.html +4 -4
- package/dist/docs/reference/skills.html +4 -4
- package/dist/docs/reference/subagents.html +6 -6
- package/dist/docs/reference/subagents.md +2 -2
- package/dist/docs/reference/tools.html +7 -7
- package/dist/docs/reference/tools.md +19 -3
- package/dist/docs/scaffolding-agents.html +4 -4
- package/dist/docs/storage.html +4 -4
- package/dist/docs/templates/agentic-owners.html +7 -7
- package/dist/docs/templates/agentic-owners.md +1 -1
- package/dist/docs/templates/demo.html +6 -6
- package/dist/docs/templates/demo.md +3 -2
- package/dist/docs/templates/pr-autofixer.html +6 -6
- package/dist/docs/templates/pr-autofixer.md +8 -13
- package/dist/docs/templates/security-help.html +30 -0
- package/dist/docs/templates/security-help.md +65 -0
- package/dist/docs/templates/security-reviewer.html +6 -6
- package/dist/docs/templates/security-reviewer.md +1 -3
- package/dist/docs/templates/triage.html +7 -7
- package/dist/docs/templates/triage.md +2 -6
- package/dist/docs/troubleshooting.html +5 -5
- package/dist/docs/troubleshooting.md +2 -2
- package/dist/files-backends/cursor-hosted.d.ts +6 -2
- package/dist/files-backends/cursor-hosted.d.ts.map +1 -1
- package/dist/files-backends/cursor-hosted.js +2 -2
- package/dist/files.d.ts +2 -0
- package/dist/files.d.ts.map +1 -1
- package/dist/files.js +5 -0
- package/dist/index.d.ts +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -1
- package/dist/internal/advertise-tools.d.ts +11 -0
- package/dist/internal/advertise-tools.d.ts.map +1 -1
- package/dist/internal/advertise-tools.js +47 -9
- package/dist/internal/cli-deploy.d.ts.map +1 -1
- package/dist/internal/cli-deploy.js +135 -6
- package/dist/internal/cli-mcp-oauth.d.ts.map +1 -1
- package/dist/internal/cli-mcp-oauth.js +7 -4
- package/dist/internal/conversation-mirror.d.ts +82 -0
- package/dist/internal/conversation-mirror.d.ts.map +1 -0
- package/dist/internal/conversation-mirror.js +251 -0
- package/dist/internal/convert-automation/convert-workflow.d.ts.map +1 -1
- package/dist/internal/convert-automation/convert-workflow.js +26 -15
- package/dist/internal/convert-automation/slug.d.ts +0 -2
- package/dist/internal/convert-automation/slug.d.ts.map +1 -1
- package/dist/internal/convert-automation/slug.js +0 -8
- package/dist/internal/cursor/account-mcp.d.ts.map +1 -1
- package/dist/internal/cursor/account-mcp.js +5 -1
- package/dist/internal/deferred-channel-session.d.ts +20 -0
- package/dist/internal/deferred-channel-session.d.ts.map +1 -0
- package/dist/internal/deferred-channel-session.js +62 -0
- package/dist/internal/deploy-client.d.ts +13 -1
- package/dist/internal/deploy-client.d.ts.map +1 -1
- package/dist/internal/deploy-client.js +11 -1
- package/dist/internal/deploy-manifest.d.ts.map +1 -1
- package/dist/internal/deploy-manifest.js +11 -5
- package/dist/internal/discovery.d.ts.map +1 -1
- package/dist/internal/discovery.js +110 -15
- package/dist/internal/framework-storage-selection.d.ts +32 -16
- package/dist/internal/framework-storage-selection.d.ts.map +1 -1
- package/dist/internal/framework-storage-selection.js +51 -17
- package/dist/internal/hosted-admission-context.d.ts +20 -0
- package/dist/internal/hosted-admission-context.d.ts.map +1 -0
- package/dist/internal/hosted-admission-context.js +31 -0
- package/dist/internal/hosted-delivery-protocol.d.ts +5 -0
- package/dist/internal/hosted-delivery-protocol.d.ts.map +1 -1
- package/dist/internal/hosted-delivery-protocol.js +33 -1
- package/dist/internal/hosted-delivery.d.ts +4 -2
- package/dist/internal/hosted-delivery.d.ts.map +1 -1
- package/dist/internal/hosted-delivery.js +97 -44
- package/dist/internal/hosted-managed-automation.d.ts +30 -0
- package/dist/internal/hosted-managed-automation.d.ts.map +1 -0
- package/dist/internal/hosted-managed-automation.js +58 -0
- package/dist/internal/mcp-endpoint.js +3 -3
- package/dist/internal/mcp-host.d.ts +8 -7
- package/dist/internal/mcp-host.d.ts.map +1 -1
- package/dist/internal/mcp-host.js +8 -7
- package/dist/internal/peer-connections.d.ts.map +1 -1
- package/dist/internal/peer-connections.js +5 -1
- package/dist/internal/playground/static.d.ts +0 -3
- package/dist/internal/playground/static.d.ts.map +1 -1
- package/dist/internal/resolved-connections.d.ts.map +1 -1
- package/dist/internal/resolved-connections.js +5 -7
- package/dist/internal/review-comments.d.ts.map +1 -1
- package/dist/internal/review-comments.js +10 -98
- package/dist/internal/scm/pr-url.d.ts +14 -0
- package/dist/internal/scm/pr-url.d.ts.map +1 -0
- package/dist/internal/scm/pr-url.js +65 -0
- package/dist/internal/sdk-runner.d.ts +14 -0
- package/dist/internal/sdk-runner.d.ts.map +1 -1
- package/dist/internal/sdk-runner.js +41 -2
- package/dist/internal/server.d.ts.map +1 -1
- package/dist/internal/server.js +123 -174
- package/dist/internal/session-engine.d.ts +45 -10
- package/dist/internal/session-engine.d.ts.map +1 -1
- package/dist/internal/session-engine.js +217 -65
- package/dist/internal/tool-catalog.d.ts +31 -0
- package/dist/internal/tool-catalog.d.ts.map +1 -0
- package/dist/internal/tool-catalog.js +67 -0
- package/dist/playground/assets/index-CF7hUDnQ.css +1 -0
- package/dist/playground/assets/{index-D9MFzhNE.js → index-CZA1uEWA.js} +48 -48
- package/dist/playground/index.html +2 -2
- package/dist/storage-backends/cursor-hosted.d.ts +7 -2
- package/dist/storage-backends/cursor-hosted.d.ts.map +1 -1
- package/dist/storage-backends/cursor-hosted.js +2 -2
- package/dist/types.d.ts +72 -23
- package/dist/types.d.ts.map +1 -1
- package/dist/types.js +19 -0
- package/docs/README.md +3 -29
- package/docs/concepts.md +1 -0
- package/docs/deployment.md +1 -20
- package/docs/design/agsh.md +406 -0
- package/docs/guides/agent-to-agent.md +2 -2
- package/docs/guides/cloud-runtime.md +1 -0
- package/docs/guides/convert-automation.md +1 -1
- package/docs/guides/github.md +4 -4
- package/docs/guides/mcp-oauth.md +10 -18
- package/docs/guides/slack.md +10 -47
- package/docs/quickstart.md +2 -3
- package/docs/reference/cli.md +5 -2
- package/docs/reference/connections.md +15 -11
- package/docs/reference/hooks.md +2 -3
- package/docs/reference/http-api.md +8 -0
- package/docs/reference/project-layout.md +5 -1
- package/docs/reference/subagents.md +2 -2
- package/docs/reference/tools.md +19 -3
- package/docs/templates/agentic-owners.md +1 -1
- package/docs/templates/demo.md +3 -2
- package/docs/templates/pr-autofixer.md +8 -13
- package/docs/templates/security-help.md +70 -0
- package/docs/templates/security-reviewer.md +1 -3
- package/docs/templates/triage.md +2 -6
- package/docs/troubleshooting.md +2 -2
- package/package.json +9 -2
- package/skills/create-agent/SKILL.md +6 -13
- package/skills/debug/SKILL.md +2 -4
- package/skills/evals/SKILL.md +1 -1
- package/skills/framework-map/SKILL.md +3 -2
- package/skills/mcp-auth/SKILL.md +10 -13
- package/skills/setup-slack/SKILL.md +21 -137
- package/src/channels/github/github-channel.ts +23 -8
- package/src/channels/github/types.ts +19 -2
- package/src/channels/origin/origin-channel.ts +13 -1
- package/src/channels/origin/origin-webhook.ts +27 -3
- package/src/channels/origin/types.ts +8 -0
- package/src/channels/slack/attachments.ts +2 -2
- package/src/channels/slack/dispatch.ts +2 -16
- package/src/channels/slack/eval-directive.ts +8 -27
- package/src/channels/slack/index.ts +0 -6
- package/src/channels/slack/pr-ref.ts +56 -25
- package/src/channels/slack/setup.ts +8 -15
- package/src/channels/slack/slack-channel.ts +14 -125
- package/src/channels/slack/types.ts +12 -96
- package/src/client.ts +23 -0
- package/src/connections.ts +20 -7
- package/src/files-backends/cursor-hosted.ts +9 -3
- package/src/files.ts +11 -0
- package/src/index.ts +2 -0
- package/src/internal/advertise-tools.ts +45 -7
- package/src/internal/cli-deploy.ts +171 -7
- package/src/internal/cli-mcp-oauth.ts +6 -4
- package/src/internal/conversation-mirror.ts +330 -0
- package/src/internal/convert-automation/convert-workflow.ts +29 -17
- package/src/internal/convert-automation/slug.ts +0 -9
- package/src/internal/cursor/account-mcp.ts +4 -1
- package/src/internal/deferred-channel-session.ts +61 -0
- package/src/internal/deploy-client.ts +24 -1
- package/src/internal/deploy-manifest.ts +10 -5
- package/src/internal/discovery.ts +129 -15
- package/src/internal/fixtures/units-server.ts +52 -0
- package/src/internal/framework-storage-selection.ts +61 -19
- package/src/internal/hosted-admission-context.ts +37 -0
- package/src/internal/hosted-delivery-protocol.ts +44 -1
- package/src/internal/hosted-delivery.ts +155 -68
- package/src/internal/hosted-managed-automation.ts +72 -0
- package/src/internal/mcp-endpoint.ts +3 -3
- package/src/internal/mcp-host.ts +8 -7
- package/src/internal/peer-connections.ts +4 -1
- package/src/internal/playground/static.ts +1 -3
- package/src/internal/resolved-connections.ts +8 -10
- package/src/internal/review-comments.ts +10 -113
- package/src/internal/scm/pr-url.ts +95 -0
- package/src/internal/sdk-runner.ts +57 -2
- package/src/internal/server.ts +161 -251
- package/src/internal/session-engine.ts +266 -69
- package/src/internal/tool-catalog.ts +106 -0
- package/src/storage-backends/cursor-hosted.ts +10 -3
- package/src/types.ts +90 -23
- package/templates/agentic-owners/README.md +1 -1
- package/templates/agentic-owners/agent/agent.ts +0 -10
- package/templates/agentic-owners/agent/channels/github.ts +5 -14
- package/templates/agentic-owners/agent/lib/config.ts +0 -8
- package/templates/agentic-owners/agent/lib/review.ts +2 -15
- package/templates/agentic-owners/agent/tools/record_review.ts +2 -4
- package/templates/demo/agent/agent.ts +0 -10
- package/templates/pr-autofixer/README.md +0 -2
- package/templates/pr-autofixer/agent/agent.ts +0 -11
- package/templates/pr-autofixer/agent/channels/slack.ts +1 -2
- package/templates/pr-autofixer/agent/lib/pr-state.ts +5 -17
- package/templates/pr-autofixer/agent/lib/repos.ts +0 -1
- package/templates/security-help/README.md +2 -2
- package/templates/security-help/agent/agent.ts +1 -2
- package/templates/security-help/agent/channels/slack.ts +0 -3
- package/templates/security-help/agent/instructions.md +9 -10
- package/templates/security-help/agent/skills/access-request.md +1 -1
- package/templates/security-help/agent/skills/faq.md +31 -0
- package/templates/security-help/agent/skills/security-playbooks.md +1 -1
- package/templates/security-help/package.json +1 -2
- package/templates/security-reviewer/agent/agent.ts +0 -10
- package/templates/triage/README.md +2 -1
- package/templates/triage/agent/agent.ts +0 -10
- package/templates/triage/agent/channels/queue.ts +1 -1
- package/templates/triage/agent/channels/webhook.ts +1 -3
- package/templates/triage/overlays/jira/agent/mcp-connections/tracker.ts +0 -1
- package/templates/triage/overlays/linear/agent/mcp-connections/tracker.ts +0 -1
- package/dist/channels/slack/cursor-account.d.ts +0 -87
- package/dist/channels/slack/cursor-account.d.ts.map +0 -1
- package/dist/channels/slack/cursor-account.js +0 -100
- package/dist/docs/assets/chunks/@localSearchIndexroot.ChpIC3Zy.js +0 -1
- package/dist/docs/assets/concepts.md.F6AiPorA.js +0 -1
- package/dist/docs/assets/example-agents_approval-buddy.md.DmezILPg.js +0 -10
- package/dist/docs/assets/example-agents_approval-buddy.md.DmezILPg.lean.js +0 -1
- package/dist/docs/assets/example-agents_benny.md.B0kwY7D_.js +0 -5
- package/dist/docs/assets/example-agents_benny.md.B0kwY7D_.lean.js +0 -1
- package/dist/docs/assets/example-agents_bugbot.md.BRGMi9O2.js +0 -11
- package/dist/docs/assets/example-agents_bugbot.md.BRGMi9O2.lean.js +0 -1
- package/dist/docs/assets/example-agents_codebase-wiki.md.BBNw9Ekr.js +0 -8
- package/dist/docs/assets/example-agents_codebase-wiki.md.BBNw9Ekr.lean.js +0 -1
- package/dist/docs/assets/example-agents_codeowners-review.md.Bfta-lBU.js +0 -8
- package/dist/docs/assets/example-agents_codeowners-review.md.Bfta-lBU.lean.js +0 -1
- package/dist/docs/assets/example-agents_concierge.md.BzB2b20R.js +0 -22
- package/dist/docs/assets/example-agents_concierge.md.BzB2b20R.lean.js +0 -1
- package/dist/docs/assets/example-agents_index.md.ChBp0AX6.js +0 -2
- package/dist/docs/assets/example-agents_index.md.ChBp0AX6.lean.js +0 -1
- package/dist/docs/assets/example-agents_knowledge-base.md.CrA85ig-.js +0 -11
- package/dist/docs/assets/example-agents_knowledge-base.md.CrA85ig-.lean.js +0 -1
- package/dist/docs/assets/example-agents_oncall.md.DK4XkYTd.js +0 -10
- package/dist/docs/assets/example-agents_oncall.md.DK4XkYTd.lean.js +0 -1
- package/dist/docs/assets/example-agents_security-reviewer.md.74pPpWYj.js +0 -19
- package/dist/docs/assets/example-agents_security-reviewer.md.74pPpWYj.lean.js +0 -1
- package/dist/docs/assets/example-agents_slack-agent.md.D7Kdj5BV.js +0 -5
- package/dist/docs/assets/example-agents_slack-agent.md.D7Kdj5BV.lean.js +0 -1
- package/dist/docs/assets/example-agents_weather-agent.md.CaGpmw3Y.js +0 -25
- package/dist/docs/assets/example-agents_weather-agent.md.CaGpmw3Y.lean.js +0 -1
- package/dist/docs/assets/guides_cloud-runtime.md.BnvjPiia.js +0 -9
- package/dist/docs/assets/guides_cloud-runtime.md.BnvjPiia.lean.js +0 -1
- package/dist/docs/assets/guides_slack.md.mqeNKs84.lean.js +0 -1
- package/dist/docs/assets/index.md.B-lVR4wT.js +0 -5
- package/dist/docs/assets/reference_http-api.md.C68BERYr.js +0 -11
- package/dist/docs/assets/reference_http-api.md.C68BERYr.lean.js +0 -1
- package/dist/docs/assets/reference_project-layout.md.WN9nwJht.js +0 -17
- package/dist/docs/assets/troubleshooting.md.vCWwvqcJ.js +0 -1
- package/dist/docs/example-agents/approval-buddy.html +0 -36
- package/dist/docs/example-agents/approval-buddy.md +0 -266
- package/dist/docs/example-agents/benny.html +0 -31
- package/dist/docs/example-agents/benny.md +0 -173
- package/dist/docs/example-agents/bugbot.html +0 -37
- package/dist/docs/example-agents/bugbot.md +0 -229
- package/dist/docs/example-agents/codebase-wiki.html +0 -34
- package/dist/docs/example-agents/codebase-wiki.md +0 -167
- package/dist/docs/example-agents/codeowners-review.html +0 -34
- package/dist/docs/example-agents/codeowners-review.md +0 -192
- package/dist/docs/example-agents/concierge.html +0 -48
- package/dist/docs/example-agents/concierge.md +0 -200
- package/dist/docs/example-agents/index.html +0 -28
- package/dist/docs/example-agents/index.md +0 -99
- package/dist/docs/example-agents/knowledge-base.html +0 -37
- package/dist/docs/example-agents/knowledge-base.md +0 -168
- package/dist/docs/example-agents/oncall.html +0 -36
- package/dist/docs/example-agents/oncall.md +0 -212
- package/dist/docs/example-agents/security-reviewer.html +0 -45
- package/dist/docs/example-agents/security-reviewer.md +0 -265
- package/dist/docs/example-agents/slack-agent.html +0 -31
- package/dist/docs/example-agents/slack-agent.md +0 -142
- package/dist/docs/example-agents/weather-agent.html +0 -51
- package/dist/docs/example-agents/weather-agent.md +0 -297
- package/dist/internal/cursor-slack-relay.d.ts +0 -96
- package/dist/internal/cursor-slack-relay.d.ts.map +0 -1
- package/dist/internal/cursor-slack-relay.js +0 -176
- package/dist/playground/assets/index-D9N7-q97.css +0 -1
- package/docs/example-agents/approval-buddy.md +0 -271
- package/docs/example-agents/benny.md +0 -178
- package/docs/example-agents/bugbot.md +0 -234
- package/docs/example-agents/codebase-wiki.md +0 -172
- package/docs/example-agents/codeowners-review.md +0 -197
- package/docs/example-agents/concierge.md +0 -205
- package/docs/example-agents/index.md +0 -104
- package/docs/example-agents/knowledge-base.md +0 -173
- package/docs/example-agents/oncall.md +0 -217
- package/docs/example-agents/security-reviewer.md +0 -270
- package/docs/example-agents/slack-agent.md +0 -147
- package/docs/example-agents/weather-agent.md +0 -302
- package/src/channels/slack/cursor-account.ts +0 -202
- package/src/internal/cursor-slack-relay.ts +0 -249
- package/templates/security-help/agent/knowledge/faq/approvals.md +0 -5
- package/templates/security-help/agent/knowledge/faq/channels.md +0 -6
- package/templates/security-help/agent/knowledge/faq/phishing.md +0 -10
- package/templates/security-help/agent/skills/security-first-pass.md +0 -15
- /package/dist/docs/assets/{concepts.md.F6AiPorA.lean.js → concepts.md.lwAgBIMI.lean.js} +0 -0
- /package/dist/docs/assets/{guides_agent-to-agent.md.B3JIaAqz.lean.js → guides_agent-to-agent.md.BDb0t1QV.lean.js} +0 -0
- /package/dist/docs/assets/{guides_convert-automation.md.Bboisykk.lean.js → guides_convert-automation.md.B4sjlodG.lean.js} +0 -0
- /package/dist/docs/assets/{guides_github.md.DqJhuaN1.lean.js → guides_github.md.Cnh2mL4a.lean.js} +0 -0
- /package/dist/docs/assets/{quickstart.md.BrmfrrIr.lean.js → quickstart.md.Nj_LjW_a.lean.js} +0 -0
- /package/dist/docs/assets/{reference_hooks.md.BxN87gCw.lean.js → reference_hooks.md.a8BJxMR5.lean.js} +0 -0
- /package/dist/docs/assets/{reference_project-layout.md.WN9nwJht.lean.js → reference_project-layout.md.Bv4KOtlB.lean.js} +0 -0
- /package/dist/docs/assets/{reference_subagents.md.Xoav0AII.lean.js → reference_subagents.md.CfsIloPm.lean.js} +0 -0
- /package/dist/docs/assets/{templates_agentic-owners.md.DqtPdm6f.lean.js → templates_agentic-owners.md.BZSH4N9z.lean.js} +0 -0
- /package/dist/docs/assets/{templates_demo.md.DhFcWN6j.lean.js → templates_demo.md.BeQX9V3H.lean.js} +0 -0
- /package/dist/docs/assets/{troubleshooting.md.vCWwvqcJ.lean.js → troubleshooting.md.Ctv3T8C2.lean.js} +0 -0
package/docs/reference/cli.md
CHANGED
|
@@ -415,6 +415,7 @@ non-zero when the reconstructed trajectory failed.
|
|
|
415
415
|
agent-sdk init ./my-agent # scaffold package.json, tsconfig.json, agent/ + a demo tool
|
|
416
416
|
agent-sdk init ./my-demo --template demo # record a PR walkthrough
|
|
417
417
|
agent-sdk init ./my-reviewer --template security-reviewer # review PRs for security bugs
|
|
418
|
+
agent-sdk init ./security-help --template security-help # answer security questions in Slack
|
|
418
419
|
agent-sdk init ./my-triage --template triage-linear # comment on Linear issues
|
|
419
420
|
agent-sdk init ./my-triage --template triage-jira # comment on Jira issues
|
|
420
421
|
agent-sdk init ./my-owners --template agentic-owners # review PRs via owners policies
|
|
@@ -430,7 +431,8 @@ agent-sdk init # no directory: print the setup guide
|
|
|
430
431
|
`@cursor/july` resolves for `dev` and `run`.
|
|
431
432
|
|
|
432
433
|
Templates may ship `init.json`. On a TTY, `init` asks those questions
|
|
433
|
-
before writing files. `pr-autofixer`
|
|
434
|
+
before writing files. `pr-autofixer` and `security-help` ask for GitHub
|
|
435
|
+
repos. Repeat
|
|
434
436
|
`--var id=value` to answer without a prompt.
|
|
435
437
|
`--json` and non-TTY hosts skip the interview unless `--var` is set.
|
|
436
438
|
|
|
@@ -751,7 +753,8 @@ command prints a note when you pass it anyway.
|
|
|
751
753
|
agent-sdk mcp oauth <connection> [--dir .] [--store] [--slug <slug>] [--team <id>]
|
|
752
754
|
```
|
|
753
755
|
|
|
754
|
-
`<connection>` is the `agent/mcp-connections
|
|
756
|
+
`<connection>` is the basename under `agent/mcp-connections/` or
|
|
757
|
+
`agent/host-connections/`.
|
|
755
758
|
`--slug` defaults to the `--dir` basename. `--team` defaults to the
|
|
756
759
|
signed-in account's team. You need `agent-sdk login` (or `--api-key`)
|
|
757
760
|
before `--store`.
|
|
@@ -12,6 +12,11 @@ from `@cursor/july/connections`, and the transport comes in
|
|
|
12
12
|
four shapes: remote HTTP, local stdio, the signed-in Cursor account's
|
|
13
13
|
connectors, and peer agents on the same host.
|
|
14
14
|
|
|
15
|
+
Put a server in `agent/host-connections/` when host tools should call it
|
|
16
|
+
and the model should not. Same `defineConnection` shape. `agent-sdk mcp
|
|
17
|
+
oauth` still works. The playground and the turn's MCP servers never see
|
|
18
|
+
those files.
|
|
19
|
+
|
|
15
20
|
## Remote MCP server
|
|
16
21
|
|
|
17
22
|
Point an MCP connection at a remote server with a URL.
|
|
@@ -48,12 +53,10 @@ agent-sdk mcp oauth inventory --store # also upsert deployment secrets
|
|
|
48
53
|
Full walkthrough: [Host MCP OAuth](../guides/mcp-oauth.md). Companion
|
|
49
54
|
skill: [`skills/mcp-auth/SKILL.md`](../../skills/mcp-auth/SKILL.md).
|
|
50
55
|
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
connected connector. If the model should call those tools by name on
|
|
56
|
-
local turns, set `advertiseTools: true`.
|
|
56
|
+
Account MCP (`cursorAccount: true`) is the right choice for connectors
|
|
57
|
+
already linked in the Cursor dashboard. Omit `servers` (or pass `"*"`)
|
|
58
|
+
to forward every connected connector. If the model should call those
|
|
59
|
+
tools by name on local turns, set `advertiseTools: true`.
|
|
57
60
|
|
|
58
61
|
## Per-session auth (`auth`)
|
|
59
62
|
|
|
@@ -113,7 +116,7 @@ export default defineConnection({
|
|
|
113
116
|
|
|
114
117
|
A listing failure, invalid tool name, or name collision fails the turn.
|
|
115
118
|
Advertised tools follow the same runtime support as server tools. They cannot
|
|
116
|
-
be
|
|
119
|
+
be called through the direct tool API.
|
|
117
120
|
|
|
118
121
|
In a dry-run session, MCP tools marked read-only run normally. Tools marked
|
|
119
122
|
as writes are stubbed. Tools without effect annotations are unavailable.
|
|
@@ -221,13 +224,14 @@ Unknown slugs and self-references fail `serve` at startup. Resolution
|
|
|
221
224
|
(loopback versus `--public-url`), loop caveats, and the delegation model
|
|
222
225
|
are in the [Agent-to-agent guide](../guides/agent-to-agent.md).
|
|
223
226
|
|
|
224
|
-
## Every MCP connection is available in three places
|
|
227
|
+
## Every model-visible MCP connection is available in three places
|
|
225
228
|
|
|
226
|
-
|
|
229
|
+
A file under `agent/mcp-connections/` serves three consumers. Host
|
|
230
|
+
connections skip the first one.
|
|
227
231
|
|
|
228
232
|
1. **Cursor agent:** Attached connections ride SDK `mcpServers` behind
|
|
229
233
|
harness MCP meta-tools. Set `advertiseTools: true` so local turns see
|
|
230
|
-
named tools.
|
|
234
|
+
named tools.
|
|
231
235
|
2. **Server tools:** Deterministic host code composes MCP calls
|
|
232
236
|
through `ctx.host.mcp`:
|
|
233
237
|
|
|
@@ -262,7 +266,7 @@ lazily on first use.
|
|
|
262
266
|
|
|
263
267
|
Continue with these pages:
|
|
264
268
|
|
|
265
|
-
- [Host MCP OAuth](../guides/mcp-oauth.md): `mcp oauth`, `--store
|
|
269
|
+
- [Host MCP OAuth](../guides/mcp-oauth.md): `mcp oauth`, `--store`
|
|
266
270
|
- [Agent-to-agent](../guides/agent-to-agent.md): peers in depth
|
|
267
271
|
- [Tools](./tools.md): authored tools that wrap MCP connections
|
|
268
272
|
- [Webhooks](../guides/webhooks.md): calling MCP connections from handlers
|
package/docs/reference/hooks.md
CHANGED
|
@@ -71,9 +71,8 @@ For GitHub merge-box checks and sticky PR banners, use
|
|
|
71
71
|
`githubChannel({ progress: { commitStatus, banner } })` from
|
|
72
72
|
`@cursor/july/channels/github`. That is the supported Autofix-style
|
|
73
73
|
path. See [GitHub: Show PR progress](../guides/github.md#show-pr-progress).
|
|
74
|
-
Override channel `events` only when the lifecycle is custom
|
|
75
|
-
|
|
76
|
-
never-red status from tool output). Do not use `defineHook` for those
|
|
74
|
+
Override channel `events` only when the lifecycle is custom, such as
|
|
75
|
+
never-red status from tool output. Do not use `defineHook` for those
|
|
77
76
|
writes.
|
|
78
77
|
|
|
79
78
|
## Patterns
|
|
@@ -138,6 +138,12 @@ while a turn runs). Agent-execution tools are rejected with `400`, and
|
|
|
138
138
|
unknown tools with `404` and the list of available names. For the
|
|
139
139
|
semantics, see [Tools](./tools.md#call-a-tool-without-a-model-turn).
|
|
140
140
|
|
|
141
|
+
An optional `"continuationToken"` (`<channelId>:<key>`, as
|
|
142
|
+
`/v1/sessions` lists it; mutually exclusive with `sessionId`) addresses
|
|
143
|
+
the session by continuation token instead; malformed tokens are
|
|
144
|
+
rejected with `400 invalid_continuation_token`. For the semantics, see
|
|
145
|
+
[Tools](./tools.md#call-a-tool-without-a-model-turn).
|
|
146
|
+
|
|
141
147
|
## Discovery
|
|
142
148
|
|
|
143
149
|
These read-only routes describe the running agent.
|
|
@@ -145,6 +151,8 @@ These read-only routes describe the running agent.
|
|
|
145
151
|
| Route | What it does |
|
|
146
152
|
| ---------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
147
153
|
| `GET /v1/info` | The discovered surface: model, tools, skills, MCP connections, subagents, channels and routes (with schemas), schedules, hooks, A/B experiments, diagnostics |
|
|
154
|
+
| `GET /v1/tools` | The live tool catalog: authored server tools plus advertised MCP passthroughs under model-facing names, as light `{ name, title?, source? }` entries. `session` / `continuationToken` query parameters bind the listing to a session identity (advertised inventories can be tenant-scoped); a connection whose listing fails is skipped and reported in `connectionErrors` |
|
|
155
|
+
| `GET /v1/tools/:name` | One catalog tool's full description: description, execution, `needsApproval`, `effect`, input and output schemas, source connection. Same session binding as the listing; unknown names get `404` with the available names |
|
|
148
156
|
| `GET /v1/health` | Per-agent liveness, no auth |
|
|
149
157
|
| `GET /v1/logs?after=N` | Recent server log lines, with a polling cursor |
|
|
150
158
|
| `GET /v1/abs` | [Live A/B metrics](../ab.md): per-session assignments and aggregate arm totals |
|
|
@@ -17,7 +17,8 @@ experiments can override their file-derived name.
|
|
|
17
17
|
| Path | Resolves to |
|
|
18
18
|
| --- | --- |
|
|
19
19
|
| `agent/tools/approve_pr.ts` | tool `approve_pr` |
|
|
20
|
-
| `agent/mcp-connections/linear.ts` | MCP connection `linear` |
|
|
20
|
+
| `agent/mcp-connections/linear.ts` | MCP connection `linear` (model + host) |
|
|
21
|
+
| `agent/host-connections/anytool.ts` | Host MCP connection `anytool` (host + `mcp oauth` only) |
|
|
21
22
|
| `agent/skills/pr-review.md` | skill `pr-review` |
|
|
22
23
|
| `agent/subagents/reviewer/` | subagent `reviewer` |
|
|
23
24
|
| `agent/channels/drive.ts` | channel `drive`, routes under `/v1/channels/drive` |
|
|
@@ -45,6 +46,8 @@ my-agent/
|
|
|
45
46
|
│ │ └── pr-review.md # on-demand procedures (SKILL.md convention)
|
|
46
47
|
│ ├── mcp-connections/
|
|
47
48
|
│ │ └── linear.ts # tools from external MCP servers
|
|
49
|
+
│ ├── host-connections/
|
|
50
|
+
│ │ └── anytool.ts # privileged MCP, host tools only
|
|
48
51
|
│ └── channels/
|
|
49
52
|
│ └── github.ts # messages and external events
|
|
50
53
|
└── evals/
|
|
@@ -66,6 +69,7 @@ Each path maps to a capability and a reference page.
|
|
|
66
69
|
| `agent/tools/<name>.ts` | One typed tool; filename = tool name. `execution: "server"` (in-process, default) or `"agent"` (a script that runs where the agent runs) | [Tools](./tools.md) |
|
|
67
70
|
| `agent/skills/*` | SKILL.md-convention procedures, loaded on demand | [Skills](./skills.md) |
|
|
68
71
|
| `agent/mcp-connections/<name>.ts` | MCP servers, available to the model, to server tools (`ctx.host.mcp`), and to channel/schedule handlers (`args.host.mcp`) | [MCP connections](./connections.md) |
|
|
72
|
+
| `agent/host-connections/<name>.ts` | Privileged MCP servers for `ctx.host.mcp` and `mcp oauth`. The model never sees them. | [MCP connections](./connections.md) |
|
|
69
73
|
| `agent/subagents/<id>/` | Child agent directory; `description` required | [Subagents](./subagents.md) |
|
|
70
74
|
| `agent/channels/*.ts` | HTTP surfaces beyond the built-in session API; `slack.ts` and `github.ts` use the platform packs | [Channels](./channels.md) |
|
|
71
75
|
| `agent/hooks/*.ts` | Observe-only event subscribers, never fatal | [Hooks](./hooks.md) |
|
|
@@ -41,8 +41,8 @@ different one.
|
|
|
41
41
|
Subagents inherit the parent's execution surface. Every per-subagent
|
|
42
42
|
capability directory is reported as a warning and ignored: `tools/`,
|
|
43
43
|
`skills/`, `mcp-connections/` (and the legacy `connections/` alias),
|
|
44
|
-
`channels/`, `schedules/`, `hooks/`, `sandbox/`,
|
|
45
|
-
`subagents/`.
|
|
44
|
+
`host-connections/`, `channels/`, `schedules/`, `hooks/`, `sandbox/`,
|
|
45
|
+
and nested `subagents/`.
|
|
46
46
|
|
|
47
47
|
Delegation needs both halves: the description makes it possible, and the
|
|
48
48
|
parent's [instructions](./instructions.md) make it happen. "When a
|
package/docs/reference/tools.md
CHANGED
|
@@ -187,8 +187,9 @@ passthrough server tools from the connection's live `listTools` on every
|
|
|
187
187
|
local turn. See
|
|
188
188
|
[MCP Connections](connections.md#advertise-tools).
|
|
189
189
|
Advertised tools ride the same execution path as authored server tools,
|
|
190
|
-
|
|
191
|
-
|
|
190
|
+
and [direct tool calls](#call-a-tool-without-a-model-turn) address them
|
|
191
|
+
by the same model-facing names: the call's session identity resolves the
|
|
192
|
+
advertised listing when the authored lookup misses.
|
|
192
193
|
|
|
193
194
|
## Gate a tool on human approval
|
|
194
195
|
|
|
@@ -262,7 +263,22 @@ when the call returns. Pass a `sessionId` (a body field over
|
|
|
262
263
|
HTTP, `--session` on the CLI, `options.sessionId` programmatically) to
|
|
263
264
|
run inside an existing session instead: the tool sees that session's
|
|
264
265
|
workspace, and the call is recorded on the session's event stream.
|
|
265
|
-
Session-bound calls return `409 session_busy` while a turn runs.
|
|
266
|
+
Session-bound calls return `409 session_busy` while a turn runs. When the
|
|
267
|
+
session's harness cwd cannot be materialized, a read-effect call runs
|
|
268
|
+
in a scratch workspace instead and the outcome carries
|
|
269
|
+
`scratchWorkspace: true`; a write-effect call fails with
|
|
270
|
+
`workspace_unavailable`.
|
|
271
|
+
|
|
272
|
+
A session can also be addressed by its continuation token: an optional
|
|
273
|
+
`continuationToken` (`<channelId>:<key>`, as `/v1/sessions` lists it;
|
|
274
|
+
mutually exclusive with `sessionId`). A token that maps to a live
|
|
275
|
+
session behaves exactly like passing that session's id — same ownership
|
|
276
|
+
check, same `409 session_busy`, same event recording. A token with no
|
|
277
|
+
session behind it runs the call scratch-bound with the token's channel
|
|
278
|
+
id and continuation key as the call's session identity, so a deployment
|
|
279
|
+
whose tools resolve state from the continuation key can serve it with
|
|
280
|
+
no live session. Malformed tokens are rejected with
|
|
281
|
+
`400 invalid_continuation_token`.
|
|
266
282
|
|
|
267
283
|
The error semantics match the model path. Unknown tools are rejected
|
|
268
284
|
with the available names, agent-execution tools cannot be called on the
|
|
@@ -49,7 +49,7 @@ low risk approve, medium and above hold with a comment. Route reviews by
|
|
|
49
49
|
committing policies:
|
|
50
50
|
|
|
51
51
|
```yaml
|
|
52
|
-
# .agentic-owners/policy.yml
|
|
52
|
+
# .agentic-owners/policy.yml. Anywhere in the repo; closest wins.
|
|
53
53
|
# paths are repo-root-relative globs, wherever the policy file lives.
|
|
54
54
|
version: 1
|
|
55
55
|
policies:
|
package/docs/templates/demo.md
CHANGED
|
@@ -44,13 +44,14 @@ curl -X POST http://127.0.0.1:3000/demo-agent/v1/channels/queue/pr \
|
|
|
44
44
|
```
|
|
45
45
|
|
|
46
46
|
The host fetches title, body, and files, writes `pr.md` and `files.md`,
|
|
47
|
-
and starts the turn. Retries
|
|
47
|
+
and starts the turn. Retries for the same PR coalesce.
|
|
48
48
|
|
|
49
49
|
GitHub label `demo` or comment `/demo` when you terminate webhooks
|
|
50
50
|
yourself: self-host and set `GITHUB_WEBHOOK_SECRET`. Hosted Cursor
|
|
51
51
|
aliases require `X-Agent-Alias-Token`, which GitHub cannot send.
|
|
52
52
|
|
|
53
|
-
`record_demo` comments on that
|
|
53
|
+
`record_demo` comments on that pull request. Eval sessions skip the
|
|
54
|
+
comment.
|
|
54
55
|
|
|
55
56
|
## First walkthrough
|
|
56
57
|
|
|
@@ -83,17 +83,11 @@ with `git push origin HEAD:<headRef>`. Workflow actions run through
|
|
|
83
83
|
|
|
84
84
|
## GitHub wakes
|
|
85
85
|
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
not. The channel buffers about 3 seconds per PR. Payload details are
|
|
92
|
-
dropped on purpose. The follow-up says something changed.
|
|
93
|
-
|
|
94
|
-
Pending wakes and the PR-to-cloud-agent map persist in `host.kv` so
|
|
95
|
-
they survive restart. `cursorHostedStorage` keeps both across replace.
|
|
96
|
-
Without that plug-in, `host.kv` is local-only.
|
|
86
|
+
Cursor relays pull request, comment, review, check, and failing status
|
|
87
|
+
events for the repos you listed. A wake only starts or resumes a cloud
|
|
88
|
+
conversation after that PR has been driven. `pull_request.opened` is
|
|
89
|
+
ignored. A PR comment or review on an opted-in PR wakes the agent. A
|
|
90
|
+
comment on a plain GitHub issue does not.
|
|
97
91
|
|
|
98
92
|
Closing a PR cancels its merge-conflict reminder and drops buffered
|
|
99
93
|
wakes.
|
|
@@ -103,8 +97,9 @@ fixture replay.
|
|
|
103
97
|
|
|
104
98
|
## Slack
|
|
105
99
|
|
|
106
|
-
`agent/channels/slack.ts`
|
|
107
|
-
|
|
100
|
+
`agent/channels/slack.ts` is a dedicated Socket Mode bot
|
|
101
|
+
(`PR_AUTOFIXER_SLACK_*`). Mint it with `agent-sdk slack create`, then
|
|
102
|
+
mention the bot or DM it with a PR URL. Same `drive_pr` path as the
|
|
108
103
|
playground. See [Slack](../guides/slack.md).
|
|
109
104
|
|
|
110
105
|
## Evals
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: "Answer security questions in Slack"
|
|
3
|
+
description: "Scaffold the agent, connect Slack, and answer from your skills. Paste a GitHub pull request for a first look."
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Answer security questions in Slack
|
|
7
|
+
|
|
8
|
+
This agent answers security questions in Slack from files you edit.
|
|
9
|
+
Paste a GitHub pull request URL for a first look. Access grants,
|
|
10
|
+
incident close-out, and GitHub writes stay with a person.
|
|
11
|
+
|
|
12
|
+
## Scaffold
|
|
13
|
+
|
|
14
|
+
```bash
|
|
15
|
+
npx @cursor/july init ./security-help --template security-help
|
|
16
|
+
```
|
|
17
|
+
|
|
18
|
+
`init` asks which GitHub repos it may read. Every repo must share one
|
|
19
|
+
owner. Pass `--var repos=acme/api,acme/web` to skip the prompt.
|
|
20
|
+
|
|
21
|
+
The list lands in `agent/lib/repos.ts`. Slack uses it when someone
|
|
22
|
+
pastes a PR URL.
|
|
23
|
+
|
|
24
|
+
## Connect Slack and GitHub
|
|
25
|
+
|
|
26
|
+
```bash
|
|
27
|
+
cd security-help
|
|
28
|
+
agent-sdk login
|
|
29
|
+
agent-sdk slack create --name "Security Help" --channel-posts
|
|
30
|
+
agent-sdk dev
|
|
31
|
+
```
|
|
32
|
+
|
|
33
|
+
`--channel-posts` is required to watch channels. Mentions and DMs work
|
|
34
|
+
without it. Connect GitHub in Cursor for the watched repos. Slack
|
|
35
|
+
starts the session. See [Slack](../guides/slack.md) and
|
|
36
|
+
[GitHub](../guides/github.md).
|
|
37
|
+
|
|
38
|
+
## First answer
|
|
39
|
+
|
|
40
|
+
Mention the bot or DM it. Edit `agent/skills/faq.md` before you rely
|
|
41
|
+
on the answers; the shipped file is a placeholder.
|
|
42
|
+
|
|
43
|
+
Paste a watched PR URL for a first look. A repo outside the list is
|
|
44
|
+
refused.
|
|
45
|
+
|
|
46
|
+
## What to edit
|
|
47
|
+
|
|
48
|
+
- `agent/lib/repos.ts`: repos it may read
|
|
49
|
+
- `agent/channels/slack.ts`: channel ids to watch (`watch`)
|
|
50
|
+
- `agent/skills/faq.md`: answers for your company
|
|
51
|
+
- `agent/skills/`: how to look at a PR, a leak, or an access ask
|
|
52
|
+
- `agent/instructions.md`: routing
|
|
53
|
+
|
|
54
|
+
## Evals
|
|
55
|
+
|
|
56
|
+
```bash
|
|
57
|
+
agent-sdk eval
|
|
58
|
+
```
|
|
59
|
+
|
|
60
|
+
Three smoke cases: phishing, SaaS access, and a seeded PR look. Eval
|
|
61
|
+
sessions skip Slack and GitHub writes.
|
|
62
|
+
|
|
63
|
+
## Deploy
|
|
64
|
+
|
|
65
|
+
```bash
|
|
66
|
+
agent-sdk deploy
|
|
67
|
+
```
|
|
68
|
+
|
|
69
|
+
Run it from the agent's git checkout. Set Slack tokens on the
|
|
70
|
+
deployment after `slack create`. See [Deployment](../deployment.md).
|
|
@@ -9,9 +9,7 @@ This agent reads a pull request diff and posts one review comment. It
|
|
|
9
9
|
reports exploitable bugs: injection, authz bypass, secret leaks, SSRF,
|
|
10
10
|
RCE. Style nits stay out.
|
|
11
11
|
|
|
12
|
-
|
|
13
|
-
runs a staged pipeline with parallel workers. This template is one
|
|
14
|
-
model turn.
|
|
12
|
+
This template is one model turn: read the diff, then post one comment.
|
|
15
13
|
|
|
16
14
|
## Scaffold
|
|
17
15
|
|
package/docs/templates/triage.md
CHANGED
|
@@ -51,8 +51,7 @@ agent-sdk dev
|
|
|
51
51
|
|
|
52
52
|
Open the playground. Run `/queue/issue` and paste an existing issue.
|
|
53
53
|
|
|
54
|
-
|
|
55
|
-
also POST:
|
|
54
|
+
You can also POST:
|
|
56
55
|
|
|
57
56
|
```bash
|
|
58
57
|
curl -X POST http://127.0.0.1:3000/triage-agent/v1/channels/queue/issue \
|
|
@@ -64,14 +63,11 @@ curl -X POST http://127.0.0.1:3000/triage-agent/v1/channels/queue/issue \
|
|
|
64
63
|
}'
|
|
65
64
|
```
|
|
66
65
|
|
|
67
|
-
`POST /v1/channels/queue/issue` accepts
|
|
68
|
-
`{ identifier, title?, description? }` from the playground.
|
|
69
|
-
|
|
70
66
|
For create webhooks, set `LINEAR_WEBHOOK_SECRET` or
|
|
71
67
|
`JIRA_WEBHOOK_SECRET`. Point the provider at the deployed alias under
|
|
72
68
|
`/v1/channels/webhook`. Signed events start or resume triage for that issue.
|
|
73
69
|
|
|
74
|
-
`record_triage` comments on the issue
|
|
70
|
+
`record_triage` comments on the issue that started the session, not
|
|
75
71
|
whatever identifier the model copies out of the ticket body.
|
|
76
72
|
|
|
77
73
|
## Rubric
|
package/docs/troubleshooting.md
CHANGED
|
@@ -32,7 +32,7 @@ not on `PATH`, use `npx @cursor/july`.
|
|
|
32
32
|
| Built-in file reads and greps fail; the turn retries for a long time | Run under Node 22.13+ (or `tsx`), never Bun. Look for `NGHTTP2_FRAME_SIZE_ERROR` in logs. |
|
|
33
33
|
| The turn fails immediately with an API-key error | Sign in with `agent-sdk login`, or set `CURSOR_API_KEY`. Discovery, `info`, `call`, and serve bring-up work without a key; model turns need one. |
|
|
34
34
|
| Replies quote rules or `AGENTS.md` from outside your agent project | The session workspace inherited parent-folder config. Nested git checkouts default `local.cwd` to a per-project cache directory under `~/.cache`. Point `defineAgent({ local: { cwd } })` at a checkout only when the agent should inherit that tree, or set `--state-root` to a clean directory (for example under `/tmp`). |
|
|
35
|
-
| Yellow box shows Datadog/Linear tools, but the model lists `GetDynamicTools` / IDE `cursor` tools and never calls them | Attached MCP sits behind harness meta-tools, or
|
|
35
|
+
| Yellow box shows Datadog/Linear tools, but the model lists `GetDynamicTools` / IDE `cursor` tools and never calls them | Attached MCP sits behind harness meta-tools, or the harness cwd is still inside another checkout. Set `advertiseTools: true` for named tools on local turns. Check `GET /v1/info` `local.cwd` and `connections[].advertiseTools`. |
|
|
36
36
|
| Server tools, skills, or workspace seed files never appear | Server tools and sandbox seeds apply on the local runtime (cloud server tools need `--public-url` / `--cloud-tools-url`). Skills reach cloud through the Agent Store when hosting or a personal `CURSOR_API_KEY` is available; otherwise only skills already in the cloud repo. `validate` warns when this combination is present. |
|
|
37
37
|
| `validate` and `run` succeed, but typecheck fails in CI | The CLI runs TypeScript with type-stripping only. Keep tool `execute` return types as object literals or `type` aliases, not `interface` types. |
|
|
38
38
|
| Login works, but turns are rejected when using custom API hosts | Point login and model traffic at the same host (`CURSOR_API_BASE_URL` and `CURSOR_BACKEND_URL`). A key from one host is rejected by the other. |
|
|
@@ -71,7 +71,7 @@ not on `PATH`, use `npx @cursor/july`.
|
|
|
71
71
|
| --- | --- |
|
|
72
72
|
| `must be defineConnection({ url, oauth: true })` | The connection file needs `oauth: true`, or you passed the wrong connection name to `agent-sdk mcp oauth`. |
|
|
73
73
|
| Local auth works; hosted calls unauthorized | Run `agent-sdk mcp oauth <name> --store`, confirm names with `agent-sdk secrets list <slug>`, then redeploy. |
|
|
74
|
-
| Model asks for `mcp_auth` or IDE MCP for a
|
|
74
|
+
| Model asks for `mcp_auth` or IDE MCP for a connector it already has | Attached MCP is behind meta-tools. Set `advertiseTools: true` for named tools on local turns, or call it from a host tool via `ctx.host.mcp`. |
|
|
75
75
|
|
|
76
76
|
See [Host MCP OAuth](./guides/mcp-oauth.md) and
|
|
77
77
|
[`skills/mcp-auth/SKILL.md`](../skills/mcp-auth/SKILL.md).
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cursor/july",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.95",
|
|
4
4
|
"description": "(early alpha) Filesystem-first framework for defining Cursor agents as markdown and TypeScript and serving them over channels with the Cursor SDK.",
|
|
5
5
|
"license": "SEE LICENSE IN LICENSE.md",
|
|
6
6
|
"repository": {
|
|
@@ -120,6 +120,13 @@
|
|
|
120
120
|
"import": "./dist/hooks.js",
|
|
121
121
|
"default": "./dist/hooks.js"
|
|
122
122
|
},
|
|
123
|
+
"./client": {
|
|
124
|
+
"anysphere-source": "./src/client.ts",
|
|
125
|
+
"bun": "./dist/client.js",
|
|
126
|
+
"types": "./dist/client.d.ts",
|
|
127
|
+
"import": "./dist/client.js",
|
|
128
|
+
"default": "./dist/client.js"
|
|
129
|
+
},
|
|
123
130
|
"./memory": {
|
|
124
131
|
"anysphere-source": "./src/memory.ts",
|
|
125
132
|
"types": "./dist/memory.d.ts",
|
|
@@ -255,13 +262,13 @@
|
|
|
255
262
|
"@slack/socket-mode": "^2.0.7",
|
|
256
263
|
"@slack/web-api": "^7.18.0",
|
|
257
264
|
"croner": "^8.0.1",
|
|
265
|
+
"esbuild": "^0.25.0",
|
|
258
266
|
"javascript-time-ago": "^2.6.4",
|
|
259
267
|
"js-yaml": "4.1.0",
|
|
260
268
|
"ms": "^2.1.3",
|
|
261
269
|
"proper-lockfile": "^4.1.2",
|
|
262
270
|
"slackify-markdown": "^5.0.0",
|
|
263
271
|
"tsx": "^4.0.0",
|
|
264
|
-
"esbuild": "^0.25.0",
|
|
265
272
|
"zod": "^3.25.0",
|
|
266
273
|
"zod-to-json-schema": "^3.24.5"
|
|
267
274
|
},
|
|
@@ -64,8 +64,8 @@ questions, concrete options, the recommended option listed first and labeled
|
|
|
64
64
|
| --- | --- | --- |
|
|
65
65
|
| **Runtime** | `local` (default) · `cloud` | Local runs on this machine. Cloud runs on a Cursor cloud agent and needs `cloud.repos`. Server tools and skills work on both. Tool approvals and sandbox seeds are local only. Recommend local unless the purpose needs a cloud checkout. |
|
|
66
66
|
| **Model** | `grok-4.5` with `effort=high`, `fast=true` (default) · Other model id | Effort and fast are params, not id suffixes: `{ id: "grok-4.5", params: [{ id: "effort", value: "high" }, { id: "fast", value: "true" }] }` — the SDK rejects suffix-style ids. |
|
|
67
|
-
| **Channels** (multi) | playground + HTTP API only (always mounted) · Slack · GitHub webhooks · custom webhook · schedule (cron) | Slack
|
|
68
|
-
| **MCP connections** (multi) | none · remote server (URL + header auth) · local stdio server · Cursor account connectors · Other | One file per server under `agent/mcp-connections/`; filename = server name. Do not name an account connection `cursor.ts` (collides with the IDE `cursor` namespace); use `account.ts`. Tokens via env vars, never hardcoded. Connections serve the model and host code (`ctx.host.mcp`). If the model should call them by name on local turns, set `advertiseTools: true`.
|
|
67
|
+
| **Channels** (multi) | playground + HTTP API only (always mounted) · Slack · GitHub webhooks · custom webhook · schedule (cron) | Slack is a dedicated Socket Mode app (`agent-sdk slack create` — own bot user + one app/token pair per agent). When Slack is picked, follow `setup-slack/SKILL.md`. GitHub verifies `X-Hub-Signature-256` when a secret is set. Discord/Teams packs do not exist yet — offer custom webhook instead. |
|
|
68
|
+
| **MCP connections** (multi) | none · remote server (URL + header auth) · local stdio server · Cursor account connectors · Other | One file per server under `agent/mcp-connections/`; filename = server name. Do not name an account connection `cursor.ts` (collides with the IDE `cursor` namespace); use `account.ts`. Tokens via env vars, never hardcoded. Connections serve the model and host code (`ctx.host.mcp`). If the model should call them by name on local turns, set `advertiseTools: true`. Privileged servers the model must not see go in `agent/host-connections/` instead. |
|
|
69
69
|
| **Capabilities** (multi) | server tools · agent tools (scripts) · skills · subagents · hooks · sandbox seed files · tool approvals (HITL) · evals (recommend) | Always recommend at least one smoke eval. |
|
|
70
70
|
|
|
71
71
|
Close the round with a one-screen plan — chosen options plus the file tree you
|
|
@@ -80,7 +80,7 @@ inventing:
|
|
|
80
80
|
|
|
81
81
|
| Purpose looks like | Proven shape |
|
|
82
82
|
| --- | --- |
|
|
83
|
-
| Slack chat assistant |
|
|
83
|
+
| Slack chat assistant | `slackChannel()` with suggested prompts; run `agent-sdk slack create` for the bot and tokens |
|
|
84
84
|
| PR review with host-prepared evidence | channel `callTool` prep into a trimmed workspace `pr/` tree |
|
|
85
85
|
| GitHub-webhook automation | `githubChannel()` hooks, per-PR debounce, replay fixtures |
|
|
86
86
|
| Domain assistant over live APIs / MCP | server + agent tools, a stdio MCP connection, a skill, a schedule |
|
|
@@ -105,7 +105,6 @@ Defaults that make first cuts good:
|
|
|
105
105
|
multi-line strings).
|
|
106
106
|
- **Env prefix** for Slack tokens = upper-snake slug (`my-agent` →
|
|
107
107
|
`MY_AGENT_SLACK_*`); `agent-sdk slack create` derives it for you.
|
|
108
|
-
Dedicated-app path only — the Cursor-hosted connection has no tokens.
|
|
109
108
|
- **Host prep beats model wandering — for evidence, not judgment.** When the
|
|
110
109
|
purpose has a deterministic setup step (fetch a PR, seed files), do it in
|
|
111
110
|
the channel handler via `callTool` / `workspaceFiles` rather than
|
|
@@ -160,11 +159,7 @@ plan:
|
|
|
160
159
|
with the real tools.
|
|
161
160
|
4. Add the chosen `channels/`, `mcp-connections/`, `skills/`, `subagents/<id>/`
|
|
162
161
|
(needs `description`), `schedules/`, `hooks/`, `sandbox/workspace/`. For
|
|
163
|
-
Slack,
|
|
164
|
-
short hand-written `agent/channels/slack.ts`
|
|
165
|
-
(`slackChannel({ cursorAccount: true, agentName: "<Name>" })` — no
|
|
166
|
-
tokens, no manifests); for a dedicated Socket Mode app do not hand-write
|
|
167
|
-
the channel — `agent-sdk slack create --dir ./<slug> --name "<Name>"`
|
|
162
|
+
Slack, do not hand-write the channel — `agent-sdk slack create --dir ./<slug> --name "<Name>"`
|
|
168
163
|
opens the dashboard wizard (env prefix from the directory name);
|
|
169
164
|
for a Slack app they own at api.slack.com, `agent-sdk slack init --manual --dir ./<slug> --name "<Name>"`;
|
|
170
165
|
customize `agent/channels/slack.ts` afterwards (e.g. `suggestedPrompts`).
|
|
@@ -225,10 +220,8 @@ Each surface beyond the playground has a human gate — drive the user through
|
|
|
225
220
|
it, verify with doctor commands, and smoke-test before declaring victory.
|
|
226
221
|
|
|
227
222
|
- **Slack** — follow `packages/agent-serve/skills/setup-slack/SKILL.md` end
|
|
228
|
-
to end
|
|
229
|
-
|
|
230
|
-
smoke. Dedicated app: init → human creates apps → doctor → `@mention`
|
|
231
|
-
smoke.
|
|
223
|
+
to end: `slack create` → doctor → `@mention` smoke. Manual path only
|
|
224
|
+
when they own the Slack app at api.slack.com.
|
|
232
225
|
- **GitHub** — follow `packages/agent-serve/skills/github/SKILL.md`
|
|
233
226
|
(fixtures / replay / forward / `--cursor-events`).
|
|
234
227
|
- **Custom webhook** — `POST /<slug>/v1/channels/<id>/<route>`. Default
|
package/skills/debug/SKILL.md
CHANGED
|
@@ -51,7 +51,7 @@ curl -sN 'localhost:3000/<slug>/v1/session/<id>/stream?startIndex=0' | head -50
|
|
|
51
51
|
| `gh webhook forward` / `agent-sdk github forward` deliveries all 401 — but hook creation succeeded | `GITHUB_TOKEN`/`GH_TOKEN` in the env. The relay authenticates with the gh CLI login and rejects env tokens. `GITHUB_TOKEN= GH_TOKEN= agent-sdk github forward ...` |
|
|
52
52
|
| `Hook already exists` starting a forwarder | GitHub allows one forwarder per repo. Use one `github forward --dir <parent>` (it fans out to every matching channel) instead of N processes; kill stale forwarders. |
|
|
53
53
|
| Agent's answers reference monorepo rules / AGENTS.md it shouldn't know | Session workspace sits inside another git checkout, so the harness loaded ancestor config. Nested projects default `local.cwd` to `~/.cache/agent-serve/<dir>`. Point cwd at a checkout only when the agent should inherit that tree. |
|
|
54
|
-
| Yellow box lists Datadog/Linear tools; model recites `GetDynamicTools` / IDE `cursor` tools and never calls MCP | Attached MCP is behind meta-tools, or
|
|
54
|
+
| Yellow box lists Datadog/Linear tools; model recites `GetDynamicTools` / IDE `cursor` tools and never calls MCP | Attached MCP is behind meta-tools, or cwd still leaked IDE MCP. Set `advertiseTools: true` for named tools on local turns. Confirm `GET /v1/info` `local.cwd` and `connections[].advertiseTools`. |
|
|
55
55
|
| Port 3000/5273 in use; stray processes after crashes | `lsof -iTCP:3000 -sTCP:LISTEN`, kill the pids; also check companion processes (e.g. vite). |
|
|
56
56
|
| Pending tool approval vanished after server restart | By design: parked SDK calls don't survive host restart; they resolve as interrupted. Re-run the turn. |
|
|
57
57
|
| Schedule / reminder never fires under `--dev` | Dev never auto-fires. `POST /<slug>/v1/dev/schedules/<id>` or `POST /<slug>/v1/dev/reminders/<id>` (list at `GET /v1/dev/reminders`). |
|
|
@@ -61,9 +61,7 @@ curl -sN 'localhost:3000/<slug>/v1/session/<id>/stream?startIndex=0' | head -50
|
|
|
61
61
|
| `403` on stream/follow-up | Caller principal ≠ session owner. In dev, create and inspect with the same auth; beyond loopback pass `--bearer-token` and send it. |
|
|
62
62
|
| Works on localhost, 401/blocked through a tunnel or LAN | Default `localDevStrict()` auth only admits direct loopback, **rejects proxy-forwarding headers** (`X-Forwarded-For`, ...), and requires a loopback `Host`. Use `--bearer-token <secret>` (or authored `bearerAuth`) — `--allow-anonymous` only for trusted-network demos (and never with Cursor account MCP connections). |
|
|
63
63
|
| Channel route won't compile: body/query schema type error | `GET` requires a Zod `querySchema`, `POST`/`PUT`/`PATCH` a Zod `bodySchema` — plain JSON Schema objects don't type-check. Use `z.object({})` / `z.unknown()` for open surfaces. Empty POST bodies are coerced to `{}` before validation. |
|
|
64
|
-
| Slack channel prints `channel idle ... missing credentials` | Expected: tokens absent
|
|
65
|
-
| `serve` fails: `Slack channels using the Cursor account connection ... not signed in to Cursor` | Cursor-hosted Slack (`cursorAccount: true`) needs a signed-in host: `agent-sdk login` or `CURSOR_API_KEY`. No Slack tokens exist on this path — `slack doctor` doesn't apply. |
|
|
66
|
-
| `@Cursor <name>` in Slack gets Cursor's normal agent, not yours | Agent name mismatch or host not relaying. Names are single-token and matched case-insensitively; confirm the serve log `cursor-slack: relaying Slack for <AgentName>` and that the workspace's Cursor Slack integration is linked to the signed-in account. |
|
|
64
|
+
| Slack channel prints `channel idle ... missing credentials` | Expected: tokens absent. Multi-agent needs `<PREFIX>_SLACK_BOT_TOKEN` + `<PREFIX>_SLACK_APP_TOKEN` per agent. `agent-sdk slack doctor --prefix <PREFIX>`. |
|
|
67
65
|
| Turn fails immediately with an API-key error | Model turns need `CURSOR_API_KEY`; everything structural (validate/info/call/serve bring-up) doesn't. |
|
|
68
66
|
| Server tools / skills / sandbox silently absent | Runtime is `cloud` — those are local-only. `validate` prints exactly this warning; read it. |
|
|
69
67
|
| `validate` clean, `run` works, CI typecheck fails | tsx never typechecked it. See invariant 3 in `framework-map/SKILL.md` (JSON-shaped tool returns; `type` not `interface`). |
|
package/skills/evals/SKILL.md
CHANGED
|
@@ -181,7 +181,7 @@ export default defineEvalConfig({
|
|
|
181
181
|
Drop `agent/playground/evals.tsx` exporting `agentName` (must match
|
|
182
182
|
`defineAgent({ name })`) and
|
|
183
183
|
`default: { RunSummary?, CaseMetrics?, CaseExtras? }`. The playground
|
|
184
|
-
loads these via Vite glob (`
|
|
184
|
+
loads these via Vite glob (`factory/*`). Without a
|
|
185
185
|
module, cases still show default `t.metric` badges.
|
|
186
186
|
|
|
187
187
|
## What good cases assert
|
|
@@ -45,7 +45,7 @@ pnpm exec tsx src/bin/agent-serve.ts <cmd> ...
|
|
|
45
45
|
`~/.cache/agent-serve/<dir>` so ancestor `AGENTS.md` / `.cursor` / IDE
|
|
46
46
|
MCP do not leak into playground turns. Set cwd at a checkout only when
|
|
47
47
|
the agent must inherit that tree. Attached MCP is invisible by name
|
|
48
|
-
until `advertiseTools: true`.
|
|
48
|
+
until `advertiseTools: true`.
|
|
49
49
|
5. **A model turn needs `CURSOR_API_KEY`.** Everything structural
|
|
50
50
|
(`validate`, `info`, `call`, `serve` bring-up) works without one.
|
|
51
51
|
|
|
@@ -60,7 +60,8 @@ path live under README "Folder structure".
|
|
|
60
60
|
| `agent/instructions.md` | Always-on system prompt (required; `.ts`/dir forms exist) |
|
|
61
61
|
| `agent/tools/<name>.ts` | One typed tool; filename = tool name. `execution: "server"` (in-process, default) or `"agent"` (script that runs where the agent runs) |
|
|
62
62
|
| `agent/skills/*` | SKILL.md-convention procedures, loaded on demand |
|
|
63
|
-
| `agent/mcp-connections/<name>.ts` | MCP servers. Do not name an account connection `cursor.ts`. `advertiseTools: true` for named tools on local turns
|
|
63
|
+
| `agent/mcp-connections/<name>.ts` | MCP servers. Do not name an account connection `cursor.ts`. `advertiseTools: true` for named tools on local turns. `{ tools }` authors TypeScript the Agent SDK packages as stdio MCP. |
|
|
64
|
+
| `agent/host-connections/<name>.ts` | Privileged MCP for `ctx.host.mcp` and `mcp oauth`. The model never sees them. |
|
|
64
65
|
| `agent/subagents/<id>/` | Child agent dir (`description` required; per-subagent tools/skills/MCP connections ignored for now) |
|
|
65
66
|
| `agent/channels/*.ts` | HTTP surfaces beyond the built-in session API; `slack.ts` / `github.ts` use the platform packs |
|
|
66
67
|
| `agent/hooks/*.ts` | Observe-only event subscribers (never fatal) |
|
package/skills/mcp-auth/SKILL.md
CHANGED
|
@@ -3,7 +3,7 @@ name: agentsdk-mcp-auth
|
|
|
3
3
|
description: >-
|
|
4
4
|
Authorize host MCP OAuth for defineConnection({ url, oauth: true }):
|
|
5
5
|
agent-sdk mcp oauth, local mcp-auth.json, --store deployment secrets,
|
|
6
|
-
|
|
6
|
+
advertiseTools, and egress. Read when wiring or debugging MCP auth.
|
|
7
7
|
---
|
|
8
8
|
|
|
9
9
|
# Host MCP OAuth (mcp auth)
|
|
@@ -29,15 +29,13 @@ Docs: `docs/guides/mcp-oauth.md`, `docs/reference/connections.md`,
|
|
|
29
29
|
| Remote URL that speaks OAuth; host must hold tokens | `defineConnection({ url, oauth: true })` + this skill |
|
|
30
30
|
| Static bearer / API key | `headers` / env on a plain `{ url }` connection |
|
|
31
31
|
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
call on local turns (Linear, Datadog, account MCP), omit `hostOnly` and
|
|
36
|
-
set `advertiseTools: true`.
|
|
32
|
+
For connectors the model should call by name on local turns (Linear,
|
|
33
|
+
Datadog, account MCP), set `advertiseTools: true`. Host tools can still
|
|
34
|
+
call the same connection through `ctx.host.mcp`.
|
|
37
35
|
|
|
38
36
|
## Goal checklist
|
|
39
37
|
|
|
40
|
-
- [ ] `agent/mcp-connections/<name>.ts` with `url` + `oauth: true` (`
|
|
38
|
+
- [ ] `agent/mcp-connections/<name>.ts` with `url` + `oauth: true` (`advertiseTools` if the model should call it by name). Use `agent/host-connections/<name>.ts` when host tools should call it and the model should not.
|
|
41
39
|
- [ ] `hosting.secretNames` lists `MCP_OAUTH_<NAME>_{ACCESS_TOKEN,REFRESH_TOKEN,CLIENT_ID}` when you will `--store`
|
|
42
40
|
- [ ] Hosted engines that reach non-bootstrap hosts declare `hosting.egressDomains`
|
|
43
41
|
- [ ] Local: `agent-sdk mcp oauth <name>` succeeds
|
|
@@ -52,8 +50,7 @@ import { defineConnection } from "@cursor/july/connections";
|
|
|
52
50
|
export default defineConnection({
|
|
53
51
|
url: "https://mcp.example.com/inventory",
|
|
54
52
|
oauth: true,
|
|
55
|
-
|
|
56
|
-
description: "Privileged inventory MCP; call via ctx.host.mcp only.",
|
|
53
|
+
description: "Inventory MCP.",
|
|
57
54
|
});
|
|
58
55
|
```
|
|
59
56
|
|
|
@@ -81,8 +78,8 @@ await ctx.host.mcp.callTool("inventory", "list_warehouses", {
|
|
|
81
78
|
});
|
|
82
79
|
```
|
|
83
80
|
|
|
84
|
-
|
|
85
|
-
|
|
81
|
+
Set `advertiseTools: true` when the model should call the server by name
|
|
82
|
+
instead of through MCP meta-tools.
|
|
86
83
|
|
|
87
84
|
## Phase 1 — Local authorize (agent + human)
|
|
88
85
|
|
|
@@ -129,10 +126,10 @@ redeploy completed, then exercise the same host tool once.
|
|
|
129
126
|
| Symptom | Fix |
|
|
130
127
|
| --- | --- |
|
|
131
128
|
| `must be defineConnection({ url, oauth: true })` | Wrong connection name, or missing `oauth: true` |
|
|
132
|
-
| `Unknown MCP connection` | Filename under `agent/mcp-connections/` must match CLI arg |
|
|
129
|
+
| `Unknown MCP connection` | Filename under `agent/mcp-connections/` or `agent/host-connections/` must match CLI arg |
|
|
133
130
|
| Callback hang | Free port 8787; finish browser flow on this machine |
|
|
134
131
|
| Hosted 401 / unauthorized | `secrets list`; re-run `--store`; redeploy |
|
|
135
|
-
| Model invents `mcp_auth` / IDE MCP |
|
|
132
|
+
| Model invents `mcp_auth` / IDE MCP | Attached MCP is behind meta-tools. Set `advertiseTools: true` for named tools on local turns. |
|
|
136
133
|
| Tokens ignored after URL edit | Expected; run `mcp oauth` again for the new resource URL |
|
|
137
134
|
|
|
138
135
|
## Don't
|