@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
|
@@ -0,0 +1,406 @@
|
|
|
1
|
+
# agsh: a shell for deployed agents
|
|
2
|
+
|
|
3
|
+
## What this is
|
|
4
|
+
|
|
5
|
+
`agsh` (agent shell) is a standalone CLI that connects to one agent-sdk
|
|
6
|
+
deployment and turns the agent's live tool surface into commands. Every tool
|
|
7
|
+
the deployment can execute (authored server tools and tools provided by the
|
|
8
|
+
agent's MCP connections) becomes a subcommand with a synopsis derived from its
|
|
9
|
+
input schema, a man-page style `--help`, and a place in an interactive shell.
|
|
10
|
+
|
|
11
|
+
It is a separate binary and a separate package from `agent-sdk`. The
|
|
12
|
+
`agent-sdk` CLI stays what it is today: the developer workflow tool for
|
|
13
|
+
authoring, validating, deploying, and debugging agent projects. `agsh` is the
|
|
14
|
+
operator's tool for working *inside* one deployed agent. The split also keeps
|
|
15
|
+
heavy presentation dependencies (markdown rendering, syntax highlighting, the
|
|
16
|
+
shell interpreter) out of `@cursor/july`, which ships to every agent project.
|
|
17
|
+
|
|
18
|
+
## The experience
|
|
19
|
+
|
|
20
|
+
```
|
|
21
|
+
$ agsh help # list of commands, man-page style
|
|
22
|
+
$ agsh read --help # man-page style: NAME, SYNOPSIS, DESCRIPTION, OPTIONS
|
|
23
|
+
$ agsh read /repo/README.md
|
|
24
|
+
$ agsh datadog_list_monitors --query "service:api"
|
|
25
|
+
$ agsh # bare: interactive shell on a TTY, script from stdin otherwise
|
|
26
|
+
❯ ls /repo | grep -i readme
|
|
27
|
+
❯ read /repo/config.json | jq .version
|
|
28
|
+
```
|
|
29
|
+
|
|
30
|
+
Every invocation binds to the deployment's latest session by default, with
|
|
31
|
+
`--session` and `--continuation-token` overrides, and prints the session
|
|
32
|
+
identifier as a final stderr line.
|
|
33
|
+
|
|
34
|
+
## Configuration
|
|
35
|
+
|
|
36
|
+
`agsh` is a client only; it never boots an agent. Every invocation needs a
|
|
37
|
+
target deployment, given by flags or by environment variables. Flags always
|
|
38
|
+
win over the environment.
|
|
39
|
+
|
|
40
|
+
Global command line options, accepted on every command and on the bare shell
|
|
41
|
+
launch:
|
|
42
|
+
|
|
43
|
+
| Option | Environment default | Meaning |
|
|
44
|
+
| --- | --- | --- |
|
|
45
|
+
| `--target <url \| name>` | `AGENT_SHELL_TARGET` | The deployment to talk to: a URL is a local deployment (`http://127.0.0.1:39400/executor`), a name a production one (`change-monitor-executor`). |
|
|
46
|
+
| `--team <team>` | `AGENT_SHELL_TEAM` | Team override for production resolution, when the login spans several. |
|
|
47
|
+
| `--bearer-token <token>` | `AGENT_SHELL_BEARER_TOKEN` | Explicit bearer auth for a deployment that is not behind the Cursor login. |
|
|
48
|
+
| `--session <id>` | | Bind to a specific session instead of the latest. |
|
|
49
|
+
| `--continuation-token <token>` | | Bind by continuation token instead of session id. |
|
|
50
|
+
| `--output <text\|json>` | | Result rendering: human-friendly views (default) or raw JSON. |
|
|
51
|
+
| `-h`, `--help` | | Per-command help. |
|
|
52
|
+
|
|
53
|
+
One parameter carries the whole target selection, and the value's shape
|
|
54
|
+
encodes the mode: a URL (`http://` or `https://`) targets a local
|
|
55
|
+
deployment, anything else names a production one. Two options with a
|
|
56
|
+
precedence rule would invite exactly the confusion a target selector must
|
|
57
|
+
not have; with one parameter the only rule is that the flag beats the
|
|
58
|
+
environment. A URL is self-contained down to the agent because one local
|
|
59
|
+
agent-sdk serve process hosts every agent of the project (change-monitor's
|
|
60
|
+
dev stack mounts `/executor` and `/planner` from a single port); a
|
|
61
|
+
production deployment is a single agent, so its name is the complete
|
|
62
|
+
address (`--team` narrows resolution when the login spans several).
|
|
63
|
+
Authentication defaults to the stored Cursor login (the same engine-access
|
|
64
|
+
credential agent-sdk uses); `--bearer-token` is the escape hatch for direct
|
|
65
|
+
deployments. Session flags are per invocation and have no environment
|
|
66
|
+
default: a session is state, not configuration. Color output follows the
|
|
67
|
+
`NO_COLOR` convention and TTY detection; there is no agsh-specific color
|
|
68
|
+
setting. No configuration file: one environment variable pins a working
|
|
69
|
+
target for a terminal session
|
|
70
|
+
(`AGENT_SHELL_TARGET=change-monitor-executor`, or a URL for a local stack),
|
|
71
|
+
which is the whole persistent-configuration need.
|
|
72
|
+
|
|
73
|
+
With no target from flags or environment, every command fails with a message
|
|
74
|
+
naming both ways to provide one.
|
|
75
|
+
|
|
76
|
+
## Architecture
|
|
77
|
+
|
|
78
|
+
### A new package
|
|
79
|
+
|
|
80
|
+
A new workspace package (working name `packages/agsh`, bin `agsh`) that
|
|
81
|
+
depends on `@cursor/july` for target resolution, stored Cursor login, and the
|
|
82
|
+
HTTP client plumbing. It owns the presentation stack: `marked` for terminal
|
|
83
|
+
markdown (moved out of `@cursor/july`), with syntax highlighting (`shiki`)
|
|
84
|
+
arriving in the phase that renders code; the shell interpreter is
|
|
85
|
+
purpose-built (see Rationale).
|
|
86
|
+
No new abstraction seam between the two packages; `agsh` imports what it
|
|
87
|
+
needs until a second consumer justifies extracting a thin client.
|
|
88
|
+
|
|
89
|
+
### The tool catalog
|
|
90
|
+
|
|
91
|
+
At startup `agsh` fetches one live catalog of everything invocable on the
|
|
92
|
+
deployment. This is the piece the current `/v1/info` cannot provide: `/v1/info`
|
|
93
|
+
projects the authored manifest, and connection tools only exist at runtime,
|
|
94
|
+
resolved per session under the connection's auth. A new endpoint provides the
|
|
95
|
+
live view (see Backend changes).
|
|
96
|
+
|
|
97
|
+
Catalog entries carry exactly one identifier each: the tool name exactly as
|
|
98
|
+
the agent sees it. Authored server tools keep their authored name (`read`).
|
|
99
|
+
Connection tools appear under their model-facing advertised name (the
|
|
100
|
+
sanitized passthrough name from `advertise-tools.ts`, e.g.
|
|
101
|
+
`datadog_list_monitors`). The CLI never invents a different naming format:
|
|
102
|
+
a tool name copied from a session transcript is a valid `agsh` command, and
|
|
103
|
+
vice versa. Where a tool came from — the upstream connector name when the
|
|
104
|
+
tool declares one, the connection name otherwise — is a field on the
|
|
105
|
+
catalog entry, not part of the identifier.
|
|
106
|
+
|
|
107
|
+
### Two command tiers
|
|
108
|
+
|
|
109
|
+
Each catalog entry becomes a command, through one of two shapes:
|
|
110
|
+
|
|
111
|
+
**Curated commands for builtin tools.** The well-known tool names (`ls`,
|
|
112
|
+
`read`, `grep`, `glob`, `diff`, ...) get hand-designed, POSIX-flavored
|
|
113
|
+
command shapes, hardcoded in `agsh` next to their titles. These tools are
|
|
114
|
+
what an operator types all day; their shapes should feel like the unix
|
|
115
|
+
commands they mirror, not like generated bindings. A curated shape decides
|
|
116
|
+
which schema fields are positional operands and which are flags, and every
|
|
117
|
+
input has exactly one spelling: an operand is only an operand, never also a
|
|
118
|
+
flag.
|
|
119
|
+
|
|
120
|
+
```
|
|
121
|
+
$ agsh read /repo/package.json --limit 2
|
|
122
|
+
{
|
|
123
|
+
"name": "change-monitor",
|
|
124
|
+
→ ses_a99d1b69c329eb75a2ec8603
|
|
125
|
+
|
|
126
|
+
$ agsh grep -i -A 2 toolEffect /repo/src
|
|
127
|
+
src/tool-policy.ts:12:export type ToolEffect = "read" | "write";
|
|
128
|
+
...
|
|
129
|
+
→ ses_a99d1b69c329eb75a2ec8603
|
|
130
|
+
|
|
131
|
+
$ agsh ls /repo --ignore-globs '*.test.ts' --ignore-globs 'node_modules/**'
|
|
132
|
+
```
|
|
133
|
+
|
|
134
|
+
`read` takes its path as an operand mapped to the schema's `path` field, with
|
|
135
|
+
`--offset` and `--limit` as integer flags. `grep` follows POSIX grep:
|
|
136
|
+
`grep [options] <pattern> [path]`, with the rg-style options (`-i`, `-A`,
|
|
137
|
+
`-B`, `-C`, `--output-mode`, `--head-limit`) mapping onto the schema fields
|
|
138
|
+
of the same names (kebab-cased). `ls` shows array input: an array field's flag repeats once
|
|
139
|
+
per element. A curated shape binds to the deployment's live schema at
|
|
140
|
+
startup; when a deployment's tool lacks the expected field, the command
|
|
141
|
+
degrades to the generic shape below rather than guessing.
|
|
142
|
+
|
|
143
|
+
A curated shape may also reformat the tool's text result toward the unix
|
|
144
|
+
command's own output conventions: the VFS ls tool returns the model-facing
|
|
145
|
+
tree (` - name/` rows under a header), and `agsh ls` prints it as standard
|
|
146
|
+
ls does, one name per line with the trailing slash kept on directories. The
|
|
147
|
+
tool's result string itself stays what the model sees; when a result does
|
|
148
|
+
not match the expected shape it prints verbatim.
|
|
149
|
+
|
|
150
|
+
**Generated commands for MCP tools.** Connection tools are dynamically
|
|
151
|
+
discovered, so no special treatment is possible; they get a uniform
|
|
152
|
+
schema-derived mapping:
|
|
153
|
+
|
|
154
|
+
- Every schema property is accepted as one flag, spelled as the
|
|
155
|
+
kebab-cased property name (`org_slug` → `--org-slug`) — the unix
|
|
156
|
+
convention; kebab collisions gain a numeric suffix. Properties already
|
|
157
|
+
shaped like flags (grep's `-i`) stay literal. No positionals, no other
|
|
158
|
+
aliases.
|
|
159
|
+
- Object-typed properties flatten recursively into one flag per leaf,
|
|
160
|
+
dash-joined (`--telemetry-context` for `telemetry.context`), so every
|
|
161
|
+
option reads as a plain value; a free-form object with no declared
|
|
162
|
+
properties stays one JSON-valued flag. A leaf is required only when its
|
|
163
|
+
whole ancestor chain is.
|
|
164
|
+
- Values are coerced by schema type: booleans are valueless flags, numbers
|
|
165
|
+
and integers are parsed, arrays accept the flag repeated once per element,
|
|
166
|
+
enums are validated before the call.
|
|
167
|
+
|
|
168
|
+
```
|
|
169
|
+
$ agsh datadog_list_monitors --query "service:api" --limit 10
|
|
170
|
+
```
|
|
171
|
+
|
|
172
|
+
In both tiers `-h`/`--help` and the global target and session flags are
|
|
173
|
+
reserved and injected, a flag that names no schema property fails before any
|
|
174
|
+
request (listing the tool's actual properties), and the bound session prints
|
|
175
|
+
as a final stderr line.
|
|
176
|
+
|
|
177
|
+
### Result rendering
|
|
178
|
+
|
|
179
|
+
Raw JSON on a terminal is not an experience for people, so `--output=text`
|
|
180
|
+
(the default) renders structured results through a small set of views,
|
|
181
|
+
selected automatically by the shape of the value each call actually returned;
|
|
182
|
+
tool metadata plays no part, since most tools advertise no output schema, and
|
|
183
|
+
many return structured data as JSON text. A string result that parses as a
|
|
184
|
+
JSON object or array counts as structured. An array of objects renders as a
|
|
185
|
+
table (columns are the union of keys, missing cells stay blank, the table
|
|
186
|
+
clamps to the terminal width); a single object renders as a property view
|
|
187
|
+
(aligned keys, scalar lists as bullets, nested structures indented); an
|
|
188
|
+
object that is nothing but an error wrapper renders as an `Error:` line;
|
|
189
|
+
plain text prints verbatim. `--output=json` renders the structured value as
|
|
190
|
+
raw JSON. The rendering never depends on the TTY: piped and interactive
|
|
191
|
+
output carry the same content, only color follows TTY detection.
|
|
192
|
+
|
|
193
|
+
### Help rendering
|
|
194
|
+
|
|
195
|
+
`--help` on a tool renders a man-page layout: NAME (the tool name, with the
|
|
196
|
+
tool's `title` beside it when the catalog carries one; titles are curated
|
|
197
|
+
data, never derived from the description), SYNOPSIS (operands from the
|
|
198
|
+
curated shape; options never enumerate — they summarize as `[options...]`,
|
|
199
|
+
man-page style, so the line stays bounded), DESCRIPTION (the tool
|
|
200
|
+
description rendered as terminal markdown), OPERANDS (positional arguments,
|
|
201
|
+
curated commands only), and OPTIONS. Descriptions of operands and options
|
|
202
|
+
come from the schema's property descriptions. Effect and approval metadata
|
|
203
|
+
render as notes when declared. Everything except the curated shape derives
|
|
204
|
+
from `GET /v1/tools/:name`; nothing else is hand-written per tool.
|
|
205
|
+
|
|
206
|
+
```
|
|
207
|
+
$ agsh read --help
|
|
208
|
+
NAME
|
|
209
|
+
read - Read a file
|
|
210
|
+
|
|
211
|
+
SYNOPSIS
|
|
212
|
+
read [options...] <path>
|
|
213
|
+
|
|
214
|
+
DESCRIPTION
|
|
215
|
+
Reads a file from the local filesystem. This tool can also read image
|
|
216
|
+
files when called with the appropriate path. Formats supported:
|
|
217
|
+
jpeg/jpg, png, gif, webp.
|
|
218
|
+
|
|
219
|
+
OPERANDS
|
|
220
|
+
<path>
|
|
221
|
+
The absolute path of the file to read.
|
|
222
|
+
|
|
223
|
+
OPTIONS
|
|
224
|
+
--offset <integer>
|
|
225
|
+
The line number to start reading from. Positive values are 1-indexed
|
|
226
|
+
from the start of the file. Negative values count backwards from the
|
|
227
|
+
end. Only provide if the file is too large to read at once.
|
|
228
|
+
|
|
229
|
+
--limit <integer>
|
|
230
|
+
The number of lines to read. Only provide if the file is too large
|
|
231
|
+
to read at once.
|
|
232
|
+
|
|
233
|
+
NOTES
|
|
234
|
+
Effect: read (performs no writes).
|
|
235
|
+
```
|
|
236
|
+
|
|
237
|
+
`agsh help` lists the available command names grouped by source, authored
|
|
238
|
+
tools first, then one group per upstream connector (its name is the group
|
|
239
|
+
header — one aggregating connection can host tools from several connectors,
|
|
240
|
+
and the connector name is what an operator recognizes). Each row is the
|
|
241
|
+
name, with the title beside it when the tool declares one; everything else
|
|
242
|
+
lives behind the command's `--help`:
|
|
243
|
+
|
|
244
|
+
The agent's description renders as a DESCRIPTION section when the deployment
|
|
245
|
+
declares one (`/v1/info` carries both name and description).
|
|
246
|
+
|
|
247
|
+
```
|
|
248
|
+
$ agsh help
|
|
249
|
+
NAME
|
|
250
|
+
change-monitor-executor
|
|
251
|
+
|
|
252
|
+
DESCRIPTION
|
|
253
|
+
Executes monitoring plans against changed code.
|
|
254
|
+
|
|
255
|
+
COMMANDS
|
|
256
|
+
diff Show workspace changes
|
|
257
|
+
glob Find files by pattern
|
|
258
|
+
grep Search file contents
|
|
259
|
+
ls List a directory
|
|
260
|
+
read Read a file
|
|
261
|
+
report_change_issue
|
|
262
|
+
report_change_succeeded
|
|
263
|
+
|
|
264
|
+
DATADOG
|
|
265
|
+
datadog_list_monitors List monitors
|
|
266
|
+
...
|
|
267
|
+
|
|
268
|
+
Run any command with --help for its synopsis and options.
|
|
269
|
+
```
|
|
270
|
+
|
|
271
|
+
### Shell mode
|
|
272
|
+
|
|
273
|
+
Invoked bare, `agsh` starts a shell. On a TTY this is a REPL; on a pipe it
|
|
274
|
+
reads a script from stdin, so `echo 'ls /' | agsh` and here-docs work.
|
|
275
|
+
|
|
276
|
+
The interpreter is purpose-built and minimal: tokenizing (quotes, escapes),
|
|
277
|
+
pipelines, and `;` / `&&` / `||`. The command namespace is exactly the
|
|
278
|
+
deployment's tool catalog plus a small curated set of local pipe filters
|
|
279
|
+
(`head`, `tail`, `wc`, stdin-filtering `grep`), so a tool name can never be
|
|
280
|
+
shadowed. There is no local filesystem, no variables, no control flow: agsh
|
|
281
|
+
has nothing local to operate on, and every command is a single traced
|
|
282
|
+
`POST /v1/tools/:name` call.
|
|
283
|
+
|
|
284
|
+
The shell binds one session identity at launch (latest by default) and keeps
|
|
285
|
+
it for the whole run, so a sequence of tool calls observes one consistent
|
|
286
|
+
session context.
|
|
287
|
+
|
|
288
|
+
## Backend changes on the agent-sdk runtime
|
|
289
|
+
|
|
290
|
+
Two read endpoints, mirroring the invocation path:
|
|
291
|
+
|
|
292
|
+
**`GET /v1/tools`: the live tool listing.** Returns the session's tool
|
|
293
|
+
namespace exactly as a turn would assemble it: authored server tools plus the
|
|
294
|
+
advertised passthrough tools synthesized from connections, under their
|
|
295
|
+
model-facing names. Entries are light (name, source, and `title` when one is
|
|
296
|
+
known); everything else lives behind the detail endpoint. Titles have two
|
|
297
|
+
sources and no new authoring surface: connection tools inherit the upstream
|
|
298
|
+
server's MCP title, which the host already propagates length-capped off
|
|
299
|
+
listings; tools that do not come from MCP get theirs from a hardcoded
|
|
300
|
+
name-to-title table in the runtime's endpoint implementation, covering the
|
|
301
|
+
well-known tool names. A tool in neither place has no title. Accepts the same
|
|
302
|
+
optional session binding as invocation (`session` or `continuationToken`)
|
|
303
|
+
because advertised inventories can be tenant-scoped and resolved per session.
|
|
304
|
+
Implementation reuses the existing plumbing: the discovered manifest for
|
|
305
|
+
authored tools and the advertise-tools synthesis (`McpHost.listTools`, or the
|
|
306
|
+
`oneOff` path when per-session auth substitution applies) for connection
|
|
307
|
+
tools. This is not a duplicate of `/v1/info`: the info document stays the
|
|
308
|
+
static authored manifest; the listing is the runtime view that only the
|
|
309
|
+
running deployment can answer.
|
|
310
|
+
|
|
311
|
+
**`GET /v1/tools/:name`: one tool's full description.** Description, input
|
|
312
|
+
schema, output schema when declared, effect when declared, approval
|
|
313
|
+
requirement, and source connection. Same path as invocation
|
|
314
|
+
(`POST /v1/tools/:name`), different method: GET describes what POST executes,
|
|
315
|
+
for the same identifier.
|
|
316
|
+
|
|
317
|
+
Invocation needs no new naming scheme. Advertised connection tools are
|
|
318
|
+
synthesized as ordinary server tools in the session's namespace, so
|
|
319
|
+
`POST /v1/tools/:name` addresses them by their model-facing name like any
|
|
320
|
+
authored tool, with the same session binding, policy checks, and per-call
|
|
321
|
+
tracing. (The direct-call path did need the synthesis step added: it now
|
|
322
|
+
resolves the advertised listing for the call's session identity when the
|
|
323
|
+
authored lookup misses.)
|
|
324
|
+
|
|
325
|
+
Phase 1 ships the minimal runtime surface agsh calls: the `effect`
|
|
326
|
+
projection in `/v1/info` (rendered in per-tool help), the scratch-workspace
|
|
327
|
+
fallback on direct calls, and `continuationToken` binding on
|
|
328
|
+
`POST /v1/tools/:toolName`. The detail endpoint in phase 2 also closes the
|
|
329
|
+
output-schema gap; `/v1/info` stays as it is.
|
|
330
|
+
|
|
331
|
+
## Local development loop
|
|
332
|
+
|
|
333
|
+
`factory/change-monitor` is the test bed. Its `pnpm start` already serves the
|
|
334
|
+
planner and executor locally through the agent-sdk dev runtime
|
|
335
|
+
(`agent-sdk serve --dir . --dev`). The loop:
|
|
336
|
+
|
|
337
|
+
1. `cd factory/change-monitor && pnpm start` (local stack, both agents).
|
|
338
|
+
2. `agsh --target http://127.0.0.1:<port>/<agent>` against it, via a dev shim
|
|
339
|
+
analogous to `agent-sdk-dev` so the CLI runs from the worktree.
|
|
340
|
+
3. Iterate end to end: VFS verbs (`ls`, `read`, `grep`, `glob`, `diff`) for the
|
|
341
|
+
authored-tool path, and the planner's tenant connectors for the
|
|
342
|
+
connection-tool path once `GET /v1/tools` exists.
|
|
343
|
+
|
|
344
|
+
## Removing the inspector surface from agent-sdk
|
|
345
|
+
|
|
346
|
+
The inspector CLI is still on development branches, so nothing migrates: the
|
|
347
|
+
CLI-side code is removed from `agent-sdk` and `agsh` is built in its place.
|
|
348
|
+
|
|
349
|
+
- The verb commands (`ls`, `read`, `grep`, `glob`, `diff`) become the
|
|
350
|
+
curated tier: their hand-designed shapes, schema-binding logic (including
|
|
351
|
+
the candidate-field fallback), and session binding carry over. The
|
|
352
|
+
schema-to-argv flag mapping seeds the generated tier for MCP tools.
|
|
353
|
+
- The `tools` and `skills` commands disappear entirely. `agsh help` and
|
|
354
|
+
per-tool `--help` are the discovery surface.
|
|
355
|
+
- `marked` and `shiki` leave `@cursor/july`; agsh's help rendering takes
|
|
356
|
+
`marked`, and `shiki` returns when agsh ships syntax highlighting.
|
|
357
|
+
`agent-sdk` keeps its developer workflow commands unchanged.
|
|
358
|
+
|
|
359
|
+
## Plan
|
|
360
|
+
|
|
361
|
+
1. **Package and core invocation.** Create the package, port target
|
|
362
|
+
resolution, the schema-to-argv mapping, and help rendering from the
|
|
363
|
+
inspector code. Authored tools only, against the existing endpoints.
|
|
364
|
+
Verified end to end on the local change-monitor stack.
|
|
365
|
+
2. **Live catalog.** Add `GET /v1/tools` and `GET /v1/tools/:name` to
|
|
366
|
+
the agent-sdk runtime, with the hardcoded title table for non-MCP tools, and verify
|
|
367
|
+
direct invocation resolves advertised connection tools by their
|
|
368
|
+
model-facing names. Connection tools appear as commands. Verified against
|
|
369
|
+
the planner's connectors.
|
|
370
|
+
3. **Shell mode.** The purpose-built mini-shell: REPL on TTY, script on
|
|
371
|
+
stdin, tools as the command namespace, one session per shell run.
|
|
372
|
+
4. **Cleanup.** Remove the inspector CLI surface and presentation
|
|
373
|
+
dependencies from `@cursor/july`.
|
|
374
|
+
|
|
375
|
+
## Rationale and rejected alternatives
|
|
376
|
+
|
|
377
|
+
**Why not extend `agent-sdk`.** The audiences differ: `agent-sdk` is for the
|
|
378
|
+
person building and deploying an agent; this tool is for the person operating
|
|
379
|
+
inside one. Bundling also forces every agent project to carry markdown
|
|
380
|
+
rendering, syntax highlighting, and a bash interpreter it never uses.
|
|
381
|
+
|
|
382
|
+
**Name.** `agsh` reads as "agent shell", is four characters, collides with
|
|
383
|
+
nothing common, and works as a shell prompt name. Considered: `august`
|
|
384
|
+
(pairs with `july` but says nothing about purpose), `toolsh` (awkward to
|
|
385
|
+
pronounce), `cursor-shell` (too broad; this is scoped to one agent).
|
|
386
|
+
|
|
387
|
+
**Why a REST catalog instead of the MCP endpoint.** The deployment already
|
|
388
|
+
speaks MCP at `/v1/mcp/tools`, including a per-connection bridge, but the
|
|
389
|
+
bridge is bound to an active turn and speaks JSON-RPC. The CLI wants a plain
|
|
390
|
+
authenticated GET with session binding that returns the assembled tool
|
|
391
|
+
namespace under the names the model sees. Wrapping that in MCP framing buys
|
|
392
|
+
nothing for a first-party client.
|
|
393
|
+
|
|
394
|
+
**Why a purpose-built interpreter instead of just-bash.** just-bash was the
|
|
395
|
+
original plan (a full bash emulation with a custom-command extension point),
|
|
396
|
+
and a prototype disproved it: custom commands replace its coreutils but can
|
|
397
|
+
never shadow its shell builtins, and `read`, `test`, `type`, and `help` are
|
|
398
|
+
builtins — so the flagship `read` tool is unreachable, and the precedence is
|
|
399
|
+
not ours to control (vercel-labs owns the package). No other embeddable JS
|
|
400
|
+
shell interpreter has a workable custom-command story (mvdan-sh's JS build
|
|
401
|
+
does not expose one; bash-parser is a parser only). agsh also needs almost
|
|
402
|
+
none of bash: no local filesystem, no variables, no control flow — just
|
|
403
|
+
tokenizing, pipelines, and a command namespace it fully owns. A TypeScript
|
|
404
|
+
REPL with tools as async functions (the shape of change-monitor's `script`
|
|
405
|
+
tool) was considered and kept as a possible later addition; it trades away
|
|
406
|
+
the unix muscle memory the curated commands exist for.
|
|
@@ -104,8 +104,8 @@ Peer MCP connections are ordinary MCP connections, so deterministic host code
|
|
|
104
104
|
can use them too. A channel handler or server tool can call
|
|
105
105
|
`host.mcp.callTool("weather", "ask", { message: "…" })` without any
|
|
106
106
|
model turn deciding to. See
|
|
107
|
-
[MCP connections](../reference/connections.md#every-mcp-connection-is-available-in-three-places)
|
|
108
|
-
for the three places every MCP connection is available.
|
|
107
|
+
[MCP connections](../reference/connections.md#every-model-visible-mcp-connection-is-available-in-three-places)
|
|
108
|
+
for the three places every model-visible MCP connection is available.
|
|
109
109
|
|
|
110
110
|
## What's next
|
|
111
111
|
|
|
@@ -66,6 +66,7 @@ mapping shifts:
|
|
|
66
66
|
| Agent tools (`execution: "agent"`) | scripts in the session workspace | catalog + script bodies on the first prompt |
|
|
67
67
|
| `skills/*` | `.cursor/skills/` in the workspace | native discovery after the first turn, from the hosted store or the signed-in account |
|
|
68
68
|
| `mcp-connections/*.ts` | SDK `mcpServers` | SDK `mcpServers` (peers need `--public-url`) |
|
|
69
|
+
| `host-connections/*.ts` | `ctx.host.mcp` only | `ctx.host.mcp` only |
|
|
69
70
|
| `sandbox/workspace/**` | seeded into the session workspace | ignored |
|
|
70
71
|
| Tool approvals (`needsApproval`) | supported | not supported; keep approval-gated tools on local turns |
|
|
71
72
|
|
|
@@ -78,7 +78,7 @@ or run lifecycle scripts from an existing `package.json`.
|
|
|
78
78
|
| Prompt model | Pins the model on `defineAgent` in `agent/agent.ts`. `git_config` and `agent_options` remain comments. |
|
|
79
79
|
| Cron trigger | Creates `agent/schedules/<slug>.ts` with `defineSchedule` in UTC. |
|
|
80
80
|
| GitHub trigger | Creates `agent/channels/github.ts`. It converts pull-request action, push branch, issue action, and user allowlist filters. |
|
|
81
|
-
| Slack trigger | Creates `agent/channels/slack.ts
|
|
81
|
+
| Slack trigger | Creates `agent/channels/slack.ts` as Socket Mode with `envPrefix` from the automation name (same names `slack create` writes). Watches add `engagement.channelPosts`. Run `agent-sdk slack create` for the bot. |
|
|
82
82
|
| Linear, PagerDuty, Sentry, Teams, or generic webhook | Creates a boilerplate `agent/channels/<slug>.ts`. |
|
|
83
83
|
| HTTP or SSE MCP server | Creates a name-based Cursor-account connection under `agent/mcp-connections/`. The project contains no server URL or credentials. |
|
|
84
84
|
| Stdio MCP server | Writes `agent/mcp-connections/<slug>.todo.md`. |
|
package/docs/guides/github.md
CHANGED
|
@@ -264,10 +264,10 @@ A comment-only first wake has no head SHA, so the check waits for a
|
|
|
264
264
|
PR or CI event. The banner still posts. A later turn on the same SHA
|
|
265
265
|
creates a new check run; GitHub cannot reopen a completed run.
|
|
266
266
|
|
|
267
|
-
Override `events` when the mapping is custom.
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
267
|
+
Override `events` when the mapping is custom. A handler can post commit
|
|
268
|
+
status from `turn.started` / `action.result` / `turn.failed` and stay
|
|
269
|
+
never-red; that pattern still wins when you replace a default handler
|
|
270
|
+
key. Handlers you author replace the matching defaults (same as
|
|
271
271
|
`progress.reactions` composition today).
|
|
272
272
|
|
|
273
273
|
## Related
|
package/docs/guides/mcp-oauth.md
CHANGED
|
@@ -22,10 +22,8 @@ The companion skill is
|
|
|
22
22
|
to that connection's resource URL
|
|
23
23
|
- Upsert deployment secrets with `--store` so hosted engines seed the
|
|
24
24
|
same tokens from env
|
|
25
|
-
-
|
|
26
|
-
tools still call
|
|
27
|
-
connectors the playground or local chat should call. Use
|
|
28
|
-
`advertiseTools: true` for those.
|
|
25
|
+
- Use `advertiseTools: true` when local turns should call the server by
|
|
26
|
+
name. Host tools can still call it through `ctx.host.mcp`.
|
|
29
27
|
|
|
30
28
|
Prefer a Cursor account MCP connection when the connector already lives
|
|
31
29
|
in the signed-in account dashboard:
|
|
@@ -40,7 +38,8 @@ and the host must hold tokens.
|
|
|
40
38
|
|
|
41
39
|
## How do I declare a host-OAuth connection?
|
|
42
40
|
|
|
43
|
-
Add one file under `agent/mcp-connections
|
|
41
|
+
Add one file under `agent/mcp-connections/` (model + host) or
|
|
42
|
+
`agent/host-connections/` (host + `mcp oauth` only). The filename is the
|
|
44
43
|
connection name you pass to the CLI and to `host.mcp`.
|
|
45
44
|
|
|
46
45
|
```ts
|
|
@@ -50,17 +49,14 @@ import { defineConnection } from "@cursor/july/connections";
|
|
|
50
49
|
export default defineConnection({
|
|
51
50
|
url: "https://mcp.example.com/inventory",
|
|
52
51
|
oauth: true,
|
|
53
|
-
|
|
54
|
-
description:
|
|
55
|
-
"Inventory MCP (privileged). Call only from host tools, not the model.",
|
|
52
|
+
description: "Inventory MCP.",
|
|
56
53
|
});
|
|
57
54
|
```
|
|
58
55
|
|
|
59
56
|
Rules of the road:
|
|
60
57
|
|
|
61
58
|
- `oauth: true` is required for `agent-sdk mcp oauth`
|
|
62
|
-
-
|
|
63
|
-
channel handlers still see it
|
|
59
|
+
- A file under `mcp-connections/` is visible to the model and to `ctx.host.mcp`. A file under `host-connections/` stays on the host.
|
|
64
60
|
- Declare expected secret names on the agent when you plan to `--store`:
|
|
65
61
|
|
|
66
62
|
```ts
|
|
@@ -93,8 +89,7 @@ agent-sdk mcp oauth inventory
|
|
|
93
89
|
|
|
94
90
|
What happens:
|
|
95
91
|
|
|
96
|
-
1. The Agent SDK loads
|
|
97
|
-
`oauth: true`
|
|
92
|
+
1. The Agent SDK loads the connection file and checks `oauth: true`
|
|
98
93
|
2. It opens the authorization URL in your browser
|
|
99
94
|
3. The callback lands on `http://localhost:8787/callback`
|
|
100
95
|
4. Tokens land in `mcp-auth.json` under the CLI config directory
|
|
@@ -133,8 +128,6 @@ on the pod.
|
|
|
133
128
|
|
|
134
129
|
## How do host tools call the server?
|
|
135
130
|
|
|
136
|
-
Keep privileged calls on the host:
|
|
137
|
-
|
|
138
131
|
```ts
|
|
139
132
|
const result = await ctx.host.mcp.callTool(
|
|
140
133
|
"inventory",
|
|
@@ -143,9 +136,8 @@ const result = await ctx.host.mcp.callTool(
|
|
|
143
136
|
);
|
|
144
137
|
```
|
|
145
138
|
|
|
146
|
-
The model
|
|
147
|
-
|
|
148
|
-
tool instead.
|
|
139
|
+
The model can call the same server. Use a host tool when the write needs
|
|
140
|
+
an allowlist or other deterministic gate.
|
|
149
141
|
|
|
150
142
|
## What if authorization fails?
|
|
151
143
|
|
|
@@ -158,7 +150,7 @@ tool instead.
|
|
|
158
150
|
|
|
159
151
|
## What's next
|
|
160
152
|
|
|
161
|
-
- [MCP connections](../reference/connections.md): transports,
|
|
153
|
+
- [MCP connections](../reference/connections.md): transports, account MCP
|
|
162
154
|
- [CLI](../reference/cli.md#mcp-oauth): full flag list for `mcp oauth`
|
|
163
155
|
- [Deployment](../deployment.md): secrets, egress, and hosted engines
|
|
164
156
|
- [Fix common agent problems](../troubleshooting.md): more symptom → fix tables
|
package/docs/guides/slack.md
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
---
|
|
2
2
|
title: "Slack"
|
|
3
|
-
description: "Put the agent in Slack:
|
|
3
|
+
description: "Put the agent in Slack: a dedicated Socket Mode app via the dashboard wizard, or a manual manifest import."
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
# Slack agents
|
|
7
7
|
|
|
8
|
-
The Slack channel puts your agent in Slack
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
8
|
+
The Slack channel puts your agent in Slack as its own Socket Mode bot.
|
|
9
|
+
`agent-sdk slack create` opens the dashboard wizard and writes tokens
|
|
10
|
+
to `.env.local`. To own the Slack app yourself, run
|
|
11
|
+
`agent-sdk slack init --manual` and paste the manifests at
|
|
12
12
|
[api.slack.com](https://api.slack.com/apps). Socket Mode has no
|
|
13
13
|
public Request URL. Replies stream in threads, with tool "thinking" steps,
|
|
14
14
|
suggested prompts, and opt-in approval buttons.
|
|
@@ -47,41 +47,12 @@ Missing tokens leave the channel idle (`channel idle … missing
|
|
|
47
47
|
credentials`) rather than failing `serve`. That's useful when you mount
|
|
48
48
|
many agents and only some have Slack apps.
|
|
49
49
|
|
|
50
|
-
## Use the Cursor Slack connection
|
|
51
|
-
|
|
52
|
-
If the Cursor Slack app is already installed in your workspace and linked
|
|
53
|
-
to your Cursor account, skip the dedicated Slack app:
|
|
54
|
-
|
|
55
|
-
```ts
|
|
56
|
-
import { slackChannel } from "@cursor/july/channels/slack";
|
|
57
|
-
|
|
58
|
-
export default slackChannel({
|
|
59
|
-
cursorAccount: true,
|
|
60
|
-
agentName: "Weatherbot", // single token — no spaces; defaults from mount slug (PascalCase)
|
|
61
|
-
agentIcon: { emoji: ":robot_face:" },
|
|
62
|
-
});
|
|
63
|
-
```
|
|
64
|
-
|
|
65
|
-
Sign the host in (`agent-sdk login` or `CURSOR_API_KEY`), then mention the
|
|
66
|
-
agent in Slack as `@Cursor Weatherbot …`. Thread replies and DMs keep going to
|
|
67
|
-
the same agent. Messages appear as the Cursor app under that agent's name
|
|
68
|
-
and icon. Slack shows its working status, then posts one final reply.
|
|
69
|
-
|
|
70
|
-
Use a dedicated Socket Mode Slack app when you need your own bot user,
|
|
71
|
-
channel watching (`engagement.channelPosts`), or approval buttons. On
|
|
72
|
-
`cursorAccount`, agents must be explicitly addressed (@mention, DM, or
|
|
73
|
-
claimed-thread reply). Channel watching and `toolApprovals` /
|
|
74
|
-
`interactivity` are Socket Mode only; the Cursor connection does not relay
|
|
75
|
-
Block Kit clicks. Agent names must be unique on the host; an unmatched
|
|
76
|
-
`@Cursor <name>` stays on Cursor's normal Slack agent.
|
|
77
|
-
|
|
78
50
|
## Control who can message the agent
|
|
79
51
|
|
|
80
52
|
External senders are blocked by default. Slack Connect users, guests, and
|
|
81
53
|
people whose home workspace is not the install team never reach the
|
|
82
|
-
handler.
|
|
83
|
-
|
|
84
|
-
your org:
|
|
54
|
+
handler. Set `blockExternals: false` only when the agent should serve
|
|
55
|
+
people outside your org:
|
|
85
56
|
|
|
86
57
|
```ts
|
|
87
58
|
export default slackChannel({
|
|
@@ -244,8 +215,7 @@ export default slackChannel({
|
|
|
244
215
|
```
|
|
245
216
|
|
|
246
217
|
Channel watching needs the `message.channels` / `message.groups` events
|
|
247
|
-
on the Slack app
|
|
248
|
-
`cursorAccount: true`). Pass `--channel-posts` on `slack create` or
|
|
218
|
+
on the Slack app. Pass `--channel-posts` on `slack create` or
|
|
249
219
|
`slack init --manual`. The bot must also be a member of each watched
|
|
250
220
|
channel.
|
|
251
221
|
|
|
@@ -255,9 +225,7 @@ Set `includeBotPosts: true` when the posts worth watching come from bots:
|
|
|
255
225
|
alert feeds, webhook integrations, or other agents posting notes. The
|
|
256
226
|
watching app's own posts stay dropped either way, matched by the `bot_id`
|
|
257
227
|
and bot user id from `auth.test`, so an agent can never dispatch on its
|
|
258
|
-
own replies.
|
|
259
|
-
[alert investigator example](../example-agents/oncall.md) watches a
|
|
260
|
-
bot-fed alerts channel this way.
|
|
228
|
+
own replies. Use this for a bot-fed alerts channel.
|
|
261
229
|
|
|
262
230
|
## Prepare work on the host
|
|
263
231
|
|
|
@@ -286,11 +254,6 @@ Approval cards need interactivity on the Slack app. Recreate with
|
|
|
286
254
|
`buildToolApprovalEvents({ credentials })` into `events` and set
|
|
287
255
|
`interactivity: true` on the channel so Socket Mode routes the clicks.
|
|
288
256
|
|
|
289
|
-
Approval buttons need Socket Mode. `slackChannel({ cursorAccount: true })`
|
|
290
|
-
rejects `toolApprovals` and `interactivity` at construction, since the
|
|
291
|
-
Cursor Slack connection does not relay Block Kit clicks. Use a dedicated
|
|
292
|
-
Slack app to run approvals for a cursor-account agent.
|
|
293
|
-
|
|
294
257
|
Cards show redacted, truncated arguments (Block Kit size limits);
|
|
295
258
|
execution still uses the full validated input, so review sensitive tools
|
|
296
259
|
in the playground when the arguments may exceed the card. Approvals
|
|
@@ -322,7 +285,7 @@ Two habits matter most.
|
|
|
322
285
|
The `slack` subcommands cover setup end to end.
|
|
323
286
|
|
|
324
287
|
```bash
|
|
325
|
-
agent-sdk slack setup #
|
|
288
|
+
agent-sdk slack setup # printed setup guide
|
|
326
289
|
agent-sdk slack create --dir . # dashboard wizard (dev app)
|
|
327
290
|
agent-sdk slack create --dir . --prod # prod app
|
|
328
291
|
agent-sdk slack destroy --dir . # delete the provisioned app
|
package/docs/quickstart.md
CHANGED
|
@@ -356,9 +356,8 @@ See [GitHub](./guides/github.md) for local event delivery and
|
|
|
356
356
|
|
|
357
357
|
## Where to go next
|
|
358
358
|
|
|
359
|
-
- [
|
|
360
|
-
|
|
361
|
-
policy
|
|
359
|
+
- [PR autofixer template](./templates/pr-autofixer.md): drive a PR on a
|
|
360
|
+
Cursor cloud VM
|
|
362
361
|
- [Evals](./evals.md): freeze these two PRs as regression checks so
|
|
363
362
|
prompt changes can't flip a verdict
|
|
364
363
|
- [Tools](./reference/tools.md): more on typed tools, approvals, and
|