@cursor/bdk 0.2.18 → 0.2.21
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 +16 -6
- package/dist/channels/github/defaults.d.ts +1 -1
- package/dist/channels/github/defaults.d.ts.map +1 -1
- package/dist/channels/github/defaults.js +1 -1
- package/dist/channels/github/progress.d.ts +1 -1
- package/dist/channels/github/progress.d.ts.map +1 -1
- package/dist/channels/slack/slack-channel.d.ts +3 -2
- package/dist/channels/slack/slack-channel.d.ts.map +1 -1
- package/dist/channels/slack/slack-channel.js +9 -2
- package/dist/docs/404.html +2 -2
- package/dist/docs/assets/{app.CJ-XZTK5.js → app.C0diulDR.js} +4 -4
- package/dist/docs/assets/chunks/@localSearchIndexroot._fglLrPa.js +1 -0
- package/dist/docs/assets/chunks/{VPLocalSearchBox.CpbYgURZ.js → VPLocalSearchBox.mlUwkfRQ.js} +1 -1
- package/dist/docs/assets/chunks/{arc.B081PemO.js → arc.DM5RRfvb.js} +1 -1
- package/dist/docs/assets/chunks/{architectureDiagram-Q4EWVU46.DPaT_hi-.js → architectureDiagram-Q4EWVU46.CNHCBbQl.js} +1 -1
- package/dist/docs/assets/chunks/{baseUniq.Buu61NLg.js → baseUniq.25Udb_uV.js} +1 -1
- package/dist/docs/assets/chunks/{blockDiagram-DXYQGD6D.C6t63owh.js → blockDiagram-DXYQGD6D.Bg-f3-qN.js} +1 -1
- package/dist/docs/assets/chunks/{c4Diagram-AHTNJAMY.BtKabdXR.js → c4Diagram-AHTNJAMY.BywSQvK9.js} +1 -1
- package/dist/docs/assets/chunks/channel.C4s-x2x3.js +1 -0
- package/dist/docs/assets/chunks/{chunk-4BX2VUAB.DQpNaR8N.js → chunk-4BX2VUAB.C3IdWWlO.js} +1 -1
- package/dist/docs/assets/chunks/{chunk-4TB4RGXK.DrhL-6Rv.js → chunk-4TB4RGXK.D_t-pAXu.js} +1 -1
- package/dist/docs/assets/chunks/{chunk-55IACEB6.DRLIBfNR.js → chunk-55IACEB6.DvlNSQE5.js} +1 -1
- package/dist/docs/assets/chunks/{chunk-EDXVE4YY.kuUuFkIg.js → chunk-EDXVE4YY.6LpTrDTf.js} +1 -1
- package/dist/docs/assets/chunks/{chunk-FMBD7UC4.BlrVxprw.js → chunk-FMBD7UC4.BZxXsutI.js} +1 -1
- package/dist/docs/assets/chunks/{chunk-OYMX7WX6.CZCfYeQA.js → chunk-OYMX7WX6.CrtynS_e.js} +1 -1
- package/dist/docs/assets/chunks/{chunk-QZHKN3VN.C7rwVEMV.js → chunk-QZHKN3VN.CUOQY0pM.js} +1 -1
- package/dist/docs/assets/chunks/{chunk-YZCP3GAM.CGseJtT_.js → chunk-YZCP3GAM.Dv3biZVN.js} +1 -1
- package/dist/docs/assets/chunks/classDiagram-6PBFFD2Q.h-fLya-M.js +1 -0
- package/dist/docs/assets/chunks/classDiagram-v2-HSJHXN6E.h-fLya-M.js +1 -0
- package/dist/docs/assets/chunks/clone.BM9yCOiZ.js +1 -0
- package/dist/docs/assets/chunks/{cose-bilkent-S5V4N54A.BWlczAK4.js → cose-bilkent-S5V4N54A.DDzCqntx.js} +1 -1
- package/dist/docs/assets/chunks/{dagre-KV5264BT.Cw0tT0bB.js → dagre-KV5264BT.DoiV-U_C.js} +1 -1
- package/dist/docs/assets/chunks/{diagram-5BDNPKRD.Cm96ah9V.js → diagram-5BDNPKRD.LHX1aUDr.js} +1 -1
- package/dist/docs/assets/chunks/{diagram-G4DWMVQ6.Cl0AoWYM.js → diagram-G4DWMVQ6.lTnkbDQp.js} +1 -1
- package/dist/docs/assets/chunks/{diagram-MMDJMWI5.Bp7mlzKs.js → diagram-MMDJMWI5.CclJPnEx.js} +1 -1
- package/dist/docs/assets/chunks/{diagram-TYMM5635.ClVeqpcW.js → diagram-TYMM5635.CLmB0KKs.js} +1 -1
- package/dist/docs/assets/chunks/{erDiagram-SMLLAGMA.Bi8dojF9.js → erDiagram-SMLLAGMA.qKkkB7iQ.js} +1 -1
- package/dist/docs/assets/chunks/{flowDiagram-DWJPFMVM.Bb4urpfG.js → flowDiagram-DWJPFMVM.HIkXNLJ3.js} +1 -1
- package/dist/docs/assets/chunks/{ganttDiagram-T4ZO3ILL.whR4wFze.js → ganttDiagram-T4ZO3ILL.YN9lDgHe.js} +1 -1
- package/dist/docs/assets/chunks/{gitGraphDiagram-UUTBAWPF.6oVMi6-3.js → gitGraphDiagram-UUTBAWPF.CL6gf7f9.js} +1 -1
- package/dist/docs/assets/chunks/{graph.D8AJDOFK.js → graph.DMkP70rB.js} +1 -1
- package/dist/docs/assets/chunks/{infoDiagram-42DDH7IO.nTpsf5Vk.js → infoDiagram-42DDH7IO.CT98u6Zd.js} +1 -1
- package/dist/docs/assets/chunks/{ishikawaDiagram-UXIWVN3A.DhYDOwyB.js → ishikawaDiagram-UXIWVN3A.CF88w8YD.js} +1 -1
- package/dist/docs/assets/chunks/{journeyDiagram-VCZTEJTY.Bg7Rudw3.js → journeyDiagram-VCZTEJTY.BoWKk6Rz.js} +1 -1
- package/dist/docs/assets/chunks/{kanban-definition-6JOO6SKY.D80D_ZAR.js → kanban-definition-6JOO6SKY.CrmPv2sG.js} +1 -1
- package/dist/docs/assets/chunks/{layout.e9hmuC-K.js → layout.CEiPTQln.js} +1 -1
- package/dist/docs/assets/chunks/{linear.D6hEyqVB.js → linear.gkXuWu8G.js} +1 -1
- package/dist/docs/assets/chunks/{min.BPAdvB9D.js → min.C4EHK60v.js} +1 -1
- package/dist/docs/assets/chunks/{mindmap-definition-QFDTVHPH.tm2Sov2Q.js → mindmap-definition-QFDTVHPH.C-JqTP4s.js} +1 -1
- package/dist/docs/assets/chunks/{pieDiagram-DEJITSTG.BKHZ497m.js → pieDiagram-DEJITSTG.t2HgQOCt.js} +1 -1
- package/dist/docs/assets/chunks/{quadrantDiagram-34T5L4WZ.CPj7gSp6.js → quadrantDiagram-34T5L4WZ.D1k-BEKc.js} +1 -1
- package/dist/docs/assets/chunks/{requirementDiagram-MS252O5E._U68yVUd.js → requirementDiagram-MS252O5E.CUu9VVrt.js} +1 -1
- package/dist/docs/assets/chunks/{sankeyDiagram-XADWPNL6._6jrIQPb.js → sankeyDiagram-XADWPNL6.HroiBrt1.js} +1 -1
- package/dist/docs/assets/chunks/{sequenceDiagram-FGHM5R23.D9UlmB6F.js → sequenceDiagram-FGHM5R23.CeJapdwH.js} +1 -1
- package/dist/docs/assets/chunks/{stateDiagram-FHFEXIEX.BQSaiJCe.js → stateDiagram-FHFEXIEX.CLj6JnXZ.js} +1 -1
- package/dist/docs/assets/chunks/stateDiagram-v2-QKLJ7IA2.CLFLHNN0.js +1 -0
- package/dist/docs/assets/chunks/{theme.25ZC61Iy.js → theme.B9ZHHvCq.js} +2 -2
- package/dist/docs/assets/chunks/{timeline-definition-GMOUNBTQ.d-17NZ3L.js → timeline-definition-GMOUNBTQ.BzKGPAdN.js} +1 -1
- package/dist/docs/assets/chunks/{vennDiagram-DHZGUBPP.DE9AGEjG.js → vennDiagram-DHZGUBPP.DtBNkpF9.js} +1 -1
- package/dist/docs/assets/chunks/wardley-RL74JXVD.D_iarxve.js +162 -0
- package/dist/docs/assets/chunks/{wardleyDiagram-NUSXRM2D.D9SDNipV.js → wardleyDiagram-NUSXRM2D.rOXEXIA9.js} +1 -1
- package/dist/docs/assets/chunks/{xychartDiagram-5P7HB3ND.DM1sIMf8.js → xychartDiagram-5P7HB3ND.BrM71_SA.js} +1 -1
- package/dist/docs/assets/{deployment.md.ajc3VM0m.js → deployment.md.CtSJ6sF9.js} +3 -3
- package/dist/docs/assets/{deployment.md.ajc3VM0m.lean.js → deployment.md.CtSJ6sF9.lean.js} +1 -1
- package/dist/docs/assets/{guides_agent-to-agent.md.Cps5NiCV.js → guides_agent-to-agent.md.CwL5cwuE.js} +6 -5
- package/dist/docs/assets/{guides_agent-to-agent.md.Cps5NiCV.lean.js → guides_agent-to-agent.md.CwL5cwuE.lean.js} +1 -1
- package/dist/docs/assets/guides_export-grokbot.md.qo5bxi4h.js +55 -0
- package/dist/docs/assets/guides_export-grokbot.md.qo5bxi4h.lean.js +1 -0
- package/dist/docs/assets/{guides_hooks.md.B_bKG1oA.js → guides_hooks.md.Bfj0pK91.js} +1 -1
- package/dist/docs/assets/{guides_hooks.md.B_bKG1oA.lean.js → guides_hooks.md.Bfj0pK91.lean.js} +1 -1
- package/dist/docs/assets/{guides_opentelemetry.md.jcPNrQbH.js → guides_opentelemetry.md.ByW1Fs7b.js} +5 -5
- package/dist/docs/assets/{guides_opentelemetry.md.jcPNrQbH.lean.js → guides_opentelemetry.md.ByW1Fs7b.lean.js} +1 -1
- package/dist/docs/assets/{index.md.CHAFTf6m.js → index.md.CAnsLl8D.js} +2 -2
- package/dist/docs/assets/{index.md.CHAFTf6m.lean.js → index.md.CAnsLl8D.lean.js} +1 -1
- package/dist/docs/assets/{reference_cli.md.Bt3sAfat.js → reference_cli.md.Bkrsce22.js} +7 -4
- package/dist/docs/assets/{reference_cli.md.Bt3sAfat.lean.js → reference_cli.md.Bkrsce22.lean.js} +1 -1
- package/dist/docs/assets/{reference_connections.md.CxbLpaaP.js → reference_connections.md.BJE2Zllp.js} +4 -4
- package/dist/docs/assets/{reference_connections.md.CxbLpaaP.lean.js → reference_connections.md.BJE2Zllp.lean.js} +1 -1
- package/dist/docs/assets/{reference_hooks.md.DbJC8mcZ.js → reference_hooks.md.B1jq3oGl.js} +3 -3
- package/dist/docs/assets/{reference_hooks.md.DbJC8mcZ.lean.js → reference_hooks.md.B1jq3oGl.lean.js} +1 -1
- package/dist/docs/assets/reference_memory.md.BwyJXYZe.js +4 -0
- package/dist/docs/assets/reference_memory.md.BwyJXYZe.lean.js +1 -0
- package/dist/docs/assets/{reference_project-layout.md.SNzIvnmC.js → reference_project-layout.md.mFcS8yDD.js} +3 -3
- package/dist/docs/assets/{reference_project-layout.md.SNzIvnmC.lean.js → reference_project-layout.md.mFcS8yDD.lean.js} +1 -1
- package/dist/docs/assets/{reference_sessions.md.C_uzIWuy.js → reference_sessions.md.C8FXuGwk.js} +1 -1
- package/dist/docs/assets/{reference_skills.md.Ckddg6KX.js → reference_skills.md.C2GWh7g8.js} +3 -3
- package/dist/docs/assets/{reference_subagents.md.gmPt5J-M.js → reference_subagents.md.ChNGh6HK.js} +1 -1
- package/dist/docs/assets/{reference_subagents.md.gmPt5J-M.lean.js → reference_subagents.md.ChNGh6HK.lean.js} +1 -1
- package/dist/docs/assets/{troubleshooting.md.PCafNCb5.js → troubleshooting.md.DFnoTDlQ.js} +1 -1
- package/dist/docs/building-with-agents.html +35 -35
- package/dist/docs/deployment.html +38 -38
- package/dist/docs/deployment.md +27 -3
- package/dist/docs/evals.html +35 -35
- package/dist/docs/guides/agent-to-agent.html +41 -40
- package/dist/docs/guides/agent-to-agent.md +34 -21
- package/dist/docs/guides/bitbucket.html +35 -35
- package/dist/docs/guides/cloud-agents.html +35 -35
- package/dist/docs/guides/convert-automation.html +35 -35
- package/dist/docs/guides/export-grokbot.html +114 -0
- package/dist/docs/guides/export-grokbot.md +239 -0
- package/dist/docs/guides/github.html +35 -35
- package/dist/docs/guides/gitlab.html +35 -35
- package/dist/docs/guides/grokbot-agents.html +35 -35
- package/dist/docs/guides/hooks.html +37 -37
- package/dist/docs/guides/hooks.md +3 -1
- package/dist/docs/guides/improve.html +35 -35
- package/dist/docs/guides/jev.html +35 -35
- package/dist/docs/guides/mcp-oauth.html +35 -35
- package/dist/docs/guides/migrate.html +36 -36
- package/dist/docs/guides/opentelemetry.html +39 -39
- package/dist/docs/guides/opentelemetry.md +37 -5
- package/dist/docs/guides/slack.html +35 -35
- package/dist/docs/guides/webhooks.html +35 -35
- package/dist/docs/hashmap.json +1 -1
- package/dist/docs/hillclimbing.html +35 -35
- package/dist/docs/index.html +37 -37
- package/dist/docs/index.md +3 -0
- package/dist/docs/llms-full.txt +536 -44
- package/dist/docs/llms.txt +2 -0
- package/dist/docs/quickstart.html +35 -35
- package/dist/docs/reference/agent-config.html +35 -35
- package/dist/docs/reference/artifacts.html +35 -35
- package/dist/docs/reference/channels.html +35 -35
- package/dist/docs/reference/cli.html +41 -38
- package/dist/docs/reference/cli.md +39 -1
- package/dist/docs/reference/connections.html +38 -38
- package/dist/docs/reference/connections.md +16 -6
- package/dist/docs/reference/evals.html +36 -36
- package/dist/docs/reference/extensions.html +35 -35
- package/dist/docs/reference/hooks.html +38 -38
- package/dist/docs/reference/hooks.md +6 -2
- package/dist/docs/reference/http-api.html +35 -35
- package/dist/docs/reference/instructions.html +35 -35
- package/dist/docs/reference/memory.html +63 -0
- package/dist/docs/reference/memory.md +114 -0
- package/dist/docs/reference/playground.html +35 -35
- package/dist/docs/reference/project-layout.html +37 -37
- package/dist/docs/reference/project-layout.md +4 -1
- package/dist/docs/reference/prompt.html +35 -35
- package/dist/docs/reference/schedules.html +35 -35
- package/dist/docs/reference/sessions.html +36 -36
- package/dist/docs/reference/sessions.md +1 -3
- package/dist/docs/reference/skills.html +38 -38
- package/dist/docs/reference/subagents.html +36 -36
- package/dist/docs/reference/subagents.md +2 -0
- package/dist/docs/reference/tools.html +35 -35
- package/dist/docs/templates/agentic-owners.html +35 -35
- package/dist/docs/templates/grokbot-agents.html +35 -35
- package/dist/docs/templates/security-reviewer.html +35 -35
- package/dist/docs/templates/thermo-quality-review.html +35 -35
- package/dist/docs/templates/thermo-review.html +35 -35
- package/dist/docs/templates/triage.html +35 -35
- package/dist/docs/troubleshooting.html +36 -36
- package/dist/docs/troubleshooting.md +1 -1
- package/dist/evals/assertions.d.ts +3 -3
- package/dist/evals/assertions.d.ts.map +1 -1
- package/dist/evals/assertions.js +2 -2
- package/dist/evals/judge.d.ts +5 -4
- package/dist/evals/judge.d.ts.map +1 -1
- package/dist/evals.d.ts +1 -1
- package/dist/evals.js +1 -1
- package/dist/extensions/cursor-cloud-agents/extension.d.ts +5 -2
- package/dist/extensions/cursor-cloud-agents/extension.d.ts.map +1 -1
- package/dist/extensions/cursor-cloud-agents/extension.js +21 -1
- package/dist/extensions/cursor-cloud-agents/lib/backend.d.ts +22 -1
- package/dist/extensions/cursor-cloud-agents/lib/backend.d.ts.map +1 -1
- package/dist/extensions/cursor-cloud-agents/lib/backend.js +1 -0
- package/dist/extensions/cursor-cloud-agents/lib/launch-agent.d.ts +10 -3
- package/dist/extensions/cursor-cloud-agents/lib/launch-agent.d.ts.map +1 -1
- package/dist/extensions/cursor-cloud-agents/lib/launch-agent.js +10 -1
- package/dist/filesystem.js +1 -1
- package/dist/internal/cli-ax.d.ts +7 -7
- package/dist/internal/cli-ax.d.ts.map +1 -1
- package/dist/internal/cli-ax.js +36 -15
- package/dist/internal/cloud-turn-usage.d.ts +34 -0
- package/dist/internal/cloud-turn-usage.d.ts.map +1 -0
- package/dist/internal/cloud-turn-usage.js +94 -0
- package/dist/internal/cursor/account-mcp.d.ts +1 -1
- package/dist/internal/cursor/account-mcp.d.ts.map +1 -1
- package/dist/internal/cursor/account-mcp.js +1 -1
- package/dist/internal/cursor/github-credentials.d.ts +1 -1
- package/dist/internal/cursor/github-credentials.d.ts.map +1 -1
- package/dist/internal/deploy-client.js +20 -1
- package/dist/internal/discovery/agent.d.ts +1 -1
- package/dist/internal/discovery/agent.d.ts.map +1 -1
- package/dist/internal/estimate-cost.d.ts +55 -0
- package/dist/internal/estimate-cost.d.ts.map +1 -0
- package/dist/internal/{turn-cost.js → estimate-cost.js} +15 -23
- package/dist/internal/eval-judge-model.d.ts +1 -1
- package/dist/internal/eval-judge-model.d.ts.map +1 -1
- package/dist/internal/eval-runner.d.ts +2 -2
- package/dist/internal/eval-runner.d.ts.map +1 -1
- package/dist/internal/eval-runner.js +1 -1
- package/dist/internal/evals-client.d.ts +1 -1
- package/dist/internal/evals-client.d.ts.map +1 -1
- package/dist/internal/evals-client.js +1 -1
- package/dist/internal/event-log.d.ts +2 -2
- package/dist/internal/event-log.d.ts.map +1 -1
- package/dist/internal/event-log.js +6 -3
- package/dist/internal/event-mapper.d.ts.map +1 -1
- package/dist/internal/event-mapper.js +5 -1
- package/dist/internal/filesystem/nearest.d.ts +1 -1
- package/dist/internal/filesystem/nearest.d.ts.map +1 -1
- package/dist/internal/filesystem/walk.d.ts +1 -1
- package/dist/internal/filesystem/walk.d.ts.map +1 -1
- package/dist/internal/filesystem/walk.js +1 -1
- package/dist/internal/host-otel.d.ts.map +1 -1
- package/dist/internal/http-channel.js +1 -1
- package/dist/internal/init-scaffold.d.ts.map +1 -1
- package/dist/internal/init-scaffold.js +3 -4
- package/dist/internal/memory-dir.d.ts +8 -0
- package/dist/internal/memory-dir.d.ts.map +1 -0
- package/dist/internal/memory-dir.js +7 -0
- package/dist/internal/otel/collector.d.ts +3 -3
- package/dist/internal/otel/collector.d.ts.map +1 -1
- package/dist/internal/otel/collector.js +68 -43
- package/dist/internal/otel/computer-use-attrs.d.ts +18 -0
- package/dist/internal/otel/computer-use-attrs.d.ts.map +1 -0
- package/dist/internal/otel/computer-use-attrs.js +30 -0
- package/dist/internal/otel/config.d.ts +1 -1
- package/dist/internal/otel/config.d.ts.map +1 -1
- package/dist/internal/otel/config.js +1 -1
- package/dist/internal/otel/runtime.d.ts +2 -6
- package/dist/internal/otel/runtime.d.ts.map +1 -1
- package/dist/internal/otel/runtime.js +54 -43
- package/dist/internal/otel/tool-error-class.d.ts +4 -0
- package/dist/internal/otel/tool-error-class.d.ts.map +1 -0
- package/dist/internal/otel/tool-error-class.js +36 -0
- package/dist/internal/sdk-runner.d.ts.map +1 -1
- package/dist/internal/sdk-runner.js +5 -13
- package/dist/internal/session-cost.d.ts +21 -22
- package/dist/internal/session-cost.d.ts.map +1 -1
- package/dist/internal/session-cost.js +38 -46
- package/dist/internal/session-engine.d.ts +22 -40
- package/dist/internal/session-engine.d.ts.map +1 -1
- package/dist/internal/session-engine.js +62 -109
- package/dist/internal/sessions-client.d.ts +13 -1
- package/dist/internal/sessions-client.d.ts.map +1 -1
- package/dist/internal/sessions-client.js +24 -0
- package/dist/internal/tool-result.d.ts +2 -2
- package/dist/internal/tool-result.d.ts.map +1 -1
- package/dist/internal/tool-result.js +16 -11
- package/dist/internal/trajectory.d.ts +5 -6
- package/dist/internal/trajectory.d.ts.map +1 -1
- package/dist/internal/trajectory.js +1 -13
- package/dist/internal/workspace-sync.js +1 -1
- package/dist/internal/workspace.js +1 -1
- package/dist/memory.d.ts +5 -4
- package/dist/memory.d.ts.map +1 -1
- package/dist/memory.js +2 -3
- package/dist/playground/assets/cursor-icons-16-gwXtdAvu.woff2 +0 -0
- package/dist/playground/assets/index-BfePgvWh.css +1 -0
- package/dist/playground/assets/index-DAlf9lxD.js +71 -0
- package/dist/playground/index.html +2 -2
- package/dist/types.d.ts +25 -29
- package/dist/types.d.ts.map +1 -1
- package/docs/README.md +3 -0
- package/docs/deployment.md +27 -3
- package/docs/guides/agent-to-agent.md +34 -21
- package/docs/guides/export-grokbot.md +244 -0
- package/docs/guides/hooks.md +3 -1
- package/docs/guides/opentelemetry.md +37 -5
- package/docs/reference/cli.md +39 -1
- package/docs/reference/connections.md +16 -6
- package/docs/reference/hooks.md +6 -2
- package/docs/reference/memory.md +119 -0
- package/docs/reference/project-layout.md +4 -1
- package/docs/reference/sessions.md +1 -3
- package/docs/reference/subagents.md +2 -0
- package/docs/troubleshooting.md +1 -1
- package/package.json +6 -5
- package/skills/evals/SKILL.md +1 -1
- package/skills/framework-map/SKILL.md +3 -1
- package/skills/otel/SKILL.md +4 -3
- package/templates/agentic-owners/bot/lib/owners/matching.ts +57 -2
- package/templates/pr-autofixer/bot/tools/drive_pr.ts +1 -2
- package/dist/docs/assets/chunks/@localSearchIndexroot.ylB4B_Ud.js +0 -1
- package/dist/docs/assets/chunks/channel.BgjgeSqp.js +0 -1
- package/dist/docs/assets/chunks/classDiagram-6PBFFD2Q.CIVv63wE.js +0 -1
- package/dist/docs/assets/chunks/classDiagram-v2-HSJHXN6E.CIVv63wE.js +0 -1
- package/dist/docs/assets/chunks/clone.HcW7h-70.js +0 -1
- package/dist/docs/assets/chunks/stateDiagram-v2-QKLJ7IA2.B5d7jT7E.js +0 -1
- package/dist/docs/assets/chunks/wardley-RL74JXVD.BcY0KddE.js +0 -162
- package/dist/internal/cloud-turn-cost.d.ts +0 -42
- package/dist/internal/cloud-turn-cost.d.ts.map +0 -1
- package/dist/internal/cloud-turn-cost.js +0 -120
- package/dist/internal/turn-cost.d.ts +0 -41
- package/dist/internal/turn-cost.d.ts.map +0 -1
- package/dist/playground/assets/cursor-icons-16-DBmD_cqy.woff2 +0 -0
- package/dist/playground/assets/index-BDPd0Sec.css +0 -1
- package/dist/playground/assets/index-BrXDwbrN.js +0 -71
- /package/dist/docs/assets/{reference_sessions.md.C_uzIWuy.lean.js → reference_sessions.md.C8FXuGwk.lean.js} +0 -0
- /package/dist/docs/assets/{reference_skills.md.Ckddg6KX.lean.js → reference_skills.md.C2GWh7g8.lean.js} +0 -0
- /package/dist/docs/assets/{troubleshooting.md.PCafNCb5.lean.js → troubleshooting.md.DFnoTDlQ.lean.js} +0 -0
package/dist/docs/llms-full.txt
CHANGED
|
@@ -194,17 +194,41 @@ The source repository must be available through the team's repository
|
|
|
194
194
|
integration, and a nested `--path` must contain an installable BDK
|
|
195
195
|
project.
|
|
196
196
|
|
|
197
|
+
### Connect deployed peers
|
|
198
|
+
|
|
199
|
+
A team-owned deployment can call another agent deployed by the same team with
|
|
200
|
+
`defineConnection({ agent: "weather-agent" })`. Deploy the specialist and the
|
|
201
|
+
caller; Cursor-managed hosting resolves the slug and authenticates the call,
|
|
202
|
+
so you don't configure a peer URL, header, or secret.
|
|
203
|
+
|
|
204
|
+
Redeploy the caller after adding or changing a peer connection. An agent last
|
|
205
|
+
deployed before hosted peer connections became available also needs one
|
|
206
|
+
redeploy. See [Peer agents](/docs/guides/agent-to-agent.md) for delegation,
|
|
207
|
+
session affinity, and local development.
|
|
208
|
+
|
|
197
209
|
### Privacy Mode
|
|
198
210
|
|
|
199
211
|
A hosted deployment stores a snapshot of its source repository, along
|
|
200
212
|
with the sessions, KV, files, and logs the agent creates for your team.
|
|
201
|
-
Whether
|
|
202
|
-
you, which is your team's setting when the team
|
|
213
|
+
Whether managed hosting is available depends on the privacy setting
|
|
214
|
+
that applies to you, which is your team's setting when the team
|
|
215
|
+
enforces one:
|
|
203
216
|
|
|
204
217
|
| Privacy setting | Managed hosting |
|
|
205
218
|
| --- | --- |
|
|
206
219
|
| Privacy Mode | Available. Cursor stores deployment data the same way it does without Privacy Mode, and the agent's model requests get the same Privacy Mode handling as your other Cursor requests. |
|
|
207
|
-
| Privacy Mode (Legacy) | Not available. `deploy
|
|
220
|
+
| Privacy Mode (Legacy) | Not available. `deploy`, a hosted session, and an eval run all refuse. |
|
|
221
|
+
|
|
222
|
+
`deploy` refuses because a deployment stores a snapshot of your
|
|
223
|
+
repository. A hosted session refuses, and Cursor does not store the
|
|
224
|
+
message. An eval run refuses because it stores prompts and replies.
|
|
225
|
+
Switch to Privacy Mode, or ask a team admin when your team enforces
|
|
226
|
+
this setting.
|
|
227
|
+
|
|
228
|
+
The stored data includes the [memory](/docs/reference/memory.md) journal,
|
|
229
|
+
which `bdk init` turns on. The journal holds user messages and the
|
|
230
|
+
agent's replies. With Privacy Mode, Cursor stores it only to run your
|
|
231
|
+
agent and doesn't train on it.
|
|
208
232
|
|
|
209
233
|
## Add egress and secrets
|
|
210
234
|
|
|
@@ -676,10 +700,12 @@ Source: /docs/guides/agent-to-agent.md
|
|
|
676
700
|
|
|
677
701
|
# Peer agents
|
|
678
702
|
|
|
679
|
-
A peer connection lets one agent ask
|
|
680
|
-
|
|
681
|
-
|
|
682
|
-
|
|
703
|
+
A peer connection lets one agent ask an independent specialist for help.
|
|
704
|
+
On Cursor-managed hosting, team-owned agents reach peers by deployment
|
|
705
|
+
slug. Deploy both agents and BDK handles routing and authentication; you
|
|
706
|
+
don't configure a URL, header, or secret. The specialist keeps its own
|
|
707
|
+
instructions, tools, and session while the caller decides when to delegate
|
|
708
|
+
and returns the answer to the user.
|
|
683
709
|
|
|
684
710
|
## Delegate a question to a specialist
|
|
685
711
|
|
|
@@ -704,14 +730,15 @@ When a request needs current weather, ask the `weather` peer. Return its
|
|
|
704
730
|
answer.
|
|
705
731
|
```
|
|
706
732
|
|
|
707
|
-
|
|
708
|
-
|
|
709
|
-
|
|
710
|
-
|
|
733
|
+
Deploy the specialist and caller from pushed Git refs:
|
|
734
|
+
|
|
735
|
+
```bash
|
|
736
|
+
bdk deploy --dir ./agents/weather-agent --slug weather-agent
|
|
737
|
+
bdk deploy --dir ./agents/concierge --slug concierge
|
|
711
738
|
```
|
|
712
739
|
|
|
713
|
-
The connection filename
|
|
714
|
-
`agent`
|
|
740
|
+
The connection filename, `weather.ts`, becomes the MCP server name the
|
|
741
|
+
concierge calls. Set `agent` to the specialist's lowercase deployment slug.
|
|
715
742
|
|
|
716
743
|
## Continue the specialist's session
|
|
717
744
|
|
|
@@ -779,6 +806,19 @@ return {
|
|
|
779
806
|
`call_tool` appears only when the peer declares at least one
|
|
780
807
|
deterministic server tool.
|
|
781
808
|
|
|
809
|
+
## Try it locally
|
|
810
|
+
|
|
811
|
+
Run both projects under one process to try the same connection locally:
|
|
812
|
+
|
|
813
|
+
```bash
|
|
814
|
+
bdk dev ./agents
|
|
815
|
+
bdk chat --url http://127.0.0.1:3000/concierge \
|
|
816
|
+
--message "What's the weather in Paris right now?"
|
|
817
|
+
```
|
|
818
|
+
|
|
819
|
+
In a local multi-agent serve, `agent` is the specialist's mount slug,
|
|
820
|
+
normally its directory name.
|
|
821
|
+
|
|
782
822
|
## Peer or subagent?
|
|
783
823
|
|
|
784
824
|
Use a [subagent](/docs/reference/subagents.md) to split one agent's job
|
|
@@ -789,12 +829,12 @@ complete agent you would also run, inspect, or expose on its own.
|
|
|
789
829
|
| --- | --- | --- |
|
|
790
830
|
| Context | Child role inside one agent | Independent agent and session |
|
|
791
831
|
| Tools and connections | Inherits the parent project | Owns its project surface |
|
|
792
|
-
| Reachability | Parent only |
|
|
832
|
+
| Reachability | Parent only | Local co-hosted agents, or declared deployments on the same team |
|
|
793
833
|
|
|
794
834
|
## Affinity
|
|
795
835
|
|
|
796
|
-
|
|
797
|
-
can continue
|
|
836
|
+
Peer sessions appear in the specialist's playground. Only the calling
|
|
837
|
+
deployment can continue a hosted peer session.
|
|
798
838
|
|
|
799
839
|
## Practices
|
|
800
840
|
|
|
@@ -806,14 +846,11 @@ can continue or check them.
|
|
|
806
846
|
|
|
807
847
|
## Other hosts
|
|
808
848
|
|
|
809
|
-
|
|
810
|
-
|
|
811
|
-
|
|
812
|
-
|
|
813
|
-
|
|
814
|
-
protect it with `--bearer-token`, and pass its external base URL through
|
|
815
|
-
`--public-url`. The flag advertises the URL; it does not expose the
|
|
816
|
-
process. The [Deployment guide](/docs/deployment.md) owns the hosting setup.
|
|
849
|
+
For self-hosting, run peers under one `bdk` process. If turns run on remote
|
|
850
|
+
workers, protect the process with `--bearer-token` and set its external URL
|
|
851
|
+
with `--public-url`. Hosts that run one agent per process can supply
|
|
852
|
+
`--peers-url`; Cursor-managed hosting configures it automatically. See
|
|
853
|
+
[Deployment](/docs/deployment.md) for the secure hosting setup.
|
|
817
854
|
|
|
818
855
|
## Related
|
|
819
856
|
|
|
@@ -1394,6 +1431,250 @@ entirely in managed configuration.
|
|
|
1394
1431
|
|
|
1395
1432
|
---
|
|
1396
1433
|
|
|
1434
|
+
Source: /docs/guides/export-grokbot.md
|
|
1435
|
+
|
|
1436
|
+
# Export a Grok Bot to a BDK project
|
|
1437
|
+
|
|
1438
|
+
`bdk init --from-grokbot` turns a Grok Bot recipe into a project you can
|
|
1439
|
+
review, run locally, and keep in source control. It carries over the bot's
|
|
1440
|
+
profile, selected skills and routines, memory, and connectors where BDK has a
|
|
1441
|
+
matching project surface.
|
|
1442
|
+
|
|
1443
|
+
## Preview the export
|
|
1444
|
+
|
|
1445
|
+
Start with `--dry-run`. The command resolves the same defaults as a real
|
|
1446
|
+
export and shows every planned file, warning, secret name, and follow-up
|
|
1447
|
+
without creating the target directory or installing packages.
|
|
1448
|
+
|
|
1449
|
+
```bash
|
|
1450
|
+
bdk init ./launch-desk \
|
|
1451
|
+
--from-grokbot ./launch-desk.recipe.json \
|
|
1452
|
+
--dry-run
|
|
1453
|
+
```
|
|
1454
|
+
|
|
1455
|
+
Selected lines from the example recipe's non-interactive preview look like
|
|
1456
|
+
this:
|
|
1457
|
+
|
|
1458
|
+
```text
|
|
1459
|
+
Dry run: "Launch Desk" → ./launch-desk (nothing written)
|
|
1460
|
+
|
|
1461
|
+
bot/agent.ts profile
|
|
1462
|
+
bot/channels/slack.ts routines/launch-questions, routines/blocker-watch, routines/ship-it
|
|
1463
|
+
bot/instructions.md profile, gettingStarted, routines/launch-questions, routines/blocker-watch, routines/ship-it, memory
|
|
1464
|
+
bot/mcp-connections/linear.ts plugins/linear
|
|
1465
|
+
bot/schedules/morning-launch-brief.md routines/morning-launch-brief
|
|
1466
|
+
bot/skills/release-checklist/SKILL.md skills/release-checklist
|
|
1467
|
+
SECRETS.md answers
|
|
1468
|
+
...
|
|
1469
|
+
|
|
1470
|
+
Defaulted without asking:
|
|
1471
|
+
- name
|
|
1472
|
+
- description
|
|
1473
|
+
- model
|
|
1474
|
+
...
|
|
1475
|
+
|
|
1476
|
+
Not carried over:
|
|
1477
|
+
- profile.avatar: BDK agents have no avatar; kept in grokbot-export.json for the Slack app icon.
|
|
1478
|
+
|
|
1479
|
+
Secrets to set (names only; see SECRETS.md):
|
|
1480
|
+
- LAUNCH_DESK_SLACK_APP_TOKEN
|
|
1481
|
+
- LAUNCH_DESK_SLACK_BOT_TOKEN
|
|
1482
|
+
```
|
|
1483
|
+
|
|
1484
|
+
Each file row names the recipe parts that produced it. The remaining sections
|
|
1485
|
+
list defaults, answers the recipe ignored, excluded items, unmapped behavior,
|
|
1486
|
+
routine placeholders, fresh connector sign-ins, warnings, and setup steps.
|
|
1487
|
+
|
|
1488
|
+
Add `--json` when a script needs the preview:
|
|
1489
|
+
|
|
1490
|
+
```bash
|
|
1491
|
+
bdk init ./launch-desk \
|
|
1492
|
+
--from-grokbot ./launch-desk.recipe.json \
|
|
1493
|
+
--dry-run \
|
|
1494
|
+
--json
|
|
1495
|
+
```
|
|
1496
|
+
|
|
1497
|
+
The core JSON shape is:
|
|
1498
|
+
|
|
1499
|
+
```json
|
|
1500
|
+
{
|
|
1501
|
+
"ok": true,
|
|
1502
|
+
"dryRun": true,
|
|
1503
|
+
"directory": "/work/launch-desk",
|
|
1504
|
+
"preview": {
|
|
1505
|
+
"files": [],
|
|
1506
|
+
"defaulted": [],
|
|
1507
|
+
"ignored": [],
|
|
1508
|
+
"excluded": [],
|
|
1509
|
+
"unmapped": [],
|
|
1510
|
+
"fillIns": [],
|
|
1511
|
+
"secrets": { "names": [], "reauth": [] },
|
|
1512
|
+
"warnings": [],
|
|
1513
|
+
"setupSteps": []
|
|
1514
|
+
}
|
|
1515
|
+
}
|
|
1516
|
+
```
|
|
1517
|
+
|
|
1518
|
+
See [`bdk init`](/docs/reference/cli.md#init) for the complete preview fields and
|
|
1519
|
+
flag behavior.
|
|
1520
|
+
|
|
1521
|
+
## Choose an answers file or the terminal interview
|
|
1522
|
+
|
|
1523
|
+
Run the command in a terminal when you want to review each choice once. Press
|
|
1524
|
+
Enter to accept a default.
|
|
1525
|
+
|
|
1526
|
+
```bash
|
|
1527
|
+
bdk init ./launch-desk \
|
|
1528
|
+
--from-grokbot ./launch-desk.recipe.json
|
|
1529
|
+
```
|
|
1530
|
+
|
|
1531
|
+
Use `--answers` for a repeatable export or a non-interactive environment. This
|
|
1532
|
+
minimal file validates against the published schema and accepts every recipe
|
|
1533
|
+
default:
|
|
1534
|
+
|
|
1535
|
+
```json
|
|
1536
|
+
{
|
|
1537
|
+
"$schema": "./node_modules/@cursor/bdk/schemas/grokbot-answers.schema.json",
|
|
1538
|
+
"version": 1
|
|
1539
|
+
}
|
|
1540
|
+
```
|
|
1541
|
+
|
|
1542
|
+
Save it as `grokbot-answers.json`, then run:
|
|
1543
|
+
|
|
1544
|
+
```bash
|
|
1545
|
+
bdk init ./launch-desk \
|
|
1546
|
+
--from-grokbot ./launch-desk.recipe.json \
|
|
1547
|
+
--answers ./grokbot-answers.json
|
|
1548
|
+
```
|
|
1549
|
+
|
|
1550
|
+
The `$schema` property is an optional editor hint. Add only the choices you
|
|
1551
|
+
want to override; any answer present in the file is not asked again. A
|
|
1552
|
+
positional directory such as `./launch-desk` overrides `location` in the
|
|
1553
|
+
answers file.
|
|
1554
|
+
|
|
1555
|
+
When stdin or stdout is not a TTY, the command never prompts. `--json` also
|
|
1556
|
+
uses this non-interactive path. Missing fields take their defaults and appear
|
|
1557
|
+
under **Defaulted without asking** or `preview.defaulted`. If a required
|
|
1558
|
+
conditional answer has no default, such as the time for a scheduled decision,
|
|
1559
|
+
the command stops and names the field to add to the answers file.
|
|
1560
|
+
|
|
1561
|
+
## Write and check the project
|
|
1562
|
+
|
|
1563
|
+
Remove `--dry-run` after the preview matches your intent. The command writes
|
|
1564
|
+
the project, installs its npm dependencies, and prints the next commands.
|
|
1565
|
+
Export into a fresh directory; a project previously created with
|
|
1566
|
+
`bdk init --template` is rejected.
|
|
1567
|
+
|
|
1568
|
+
```bash
|
|
1569
|
+
bdk init ./launch-desk \
|
|
1570
|
+
--from-grokbot ./launch-desk.recipe.json \
|
|
1571
|
+
--answers ./grokbot-answers.json
|
|
1572
|
+
|
|
1573
|
+
cd ./launch-desk
|
|
1574
|
+
bdk validate
|
|
1575
|
+
bdk dev
|
|
1576
|
+
```
|
|
1577
|
+
|
|
1578
|
+
Open the playground from `bdk dev` and try the routines you plan to keep
|
|
1579
|
+
before connecting live channels.
|
|
1580
|
+
|
|
1581
|
+
## Review what maps where
|
|
1582
|
+
|
|
1583
|
+
| Grok Bot recipe part | BDK project result |
|
|
1584
|
+
| --- | --- |
|
|
1585
|
+
| Profile or persona | The name and description become `bot/agent.ts` and the opening of `bot/instructions.md`. |
|
|
1586
|
+
| Skills | Each selected skill becomes `bot/skills/<slug>/SKILL.md`. An enabled, valid skill schedule also becomes `bot/schedules/<slug>.md` when the schedule channel is on. |
|
|
1587
|
+
| Getting-started skill | `bot/instructions.md` tells the agent to use this skill for a new conversation. |
|
|
1588
|
+
| Cron routines | A selected routine with a valid, enabled cron trigger becomes `bot/schedules/<slug>.md` when the schedule channel is on. |
|
|
1589
|
+
| Slack routines | When the Slack channel is on, the routine text becomes a section in `bot/instructions.md`; mentions, channel watches, keywords, and reactions are wired in `bot/channels/slack.ts`. Missing trigger values remain as warnings or TODOs. |
|
|
1590
|
+
| GitHub or webhook routines | When the corresponding channel is on, the preview adds a setup step to wire the trigger. A routine with no other wired trigger also becomes an on-request skill. |
|
|
1591
|
+
| Other routines | A routine without a wired trigger becomes an on-request skill. The preview explains which trigger still needs work. |
|
|
1592
|
+
| Memory | The default is `bot/skills/knowledge/SKILL.md`. Choose `memory: "kv"` for `bot/lib/memory-seed.json`, or `memory: "drop"` to leave it out. |
|
|
1593
|
+
| Plugins and connectors | Each selected plugin becomes `bot/mcp-connections/<slug>.ts` using Cursor-account auth, OAuth, or a named bearer-token secret. |
|
|
1594
|
+
| Routine placeholders | Values under `fillIns.<routine-slug>` replace placeholders such as `{slack_channel}`. Unfilled placeholders remain visible and produce warnings. |
|
|
1595
|
+
| Export decisions | Resolved answers and recipe metadata are recorded in `grokbot-export.json`. |
|
|
1596
|
+
|
|
1597
|
+
The generated project also includes the standard package, TypeScript, eval,
|
|
1598
|
+
memory-hook, and ignore files needed to run it.
|
|
1599
|
+
|
|
1600
|
+
## Resolve what does not map
|
|
1601
|
+
|
|
1602
|
+
The preview separates choices you made from behavior the converter could not
|
|
1603
|
+
carry over:
|
|
1604
|
+
|
|
1605
|
+
| Preview result | What it means | What to do |
|
|
1606
|
+
| --- | --- | --- |
|
|
1607
|
+
| **Left out** | An answer excluded a skill, routine, plugin, or memory. | Change the matching `include` or `exclude` answer, or change `memory` from `"drop"`, then rerun; otherwise leave the item behind. |
|
|
1608
|
+
| `BDK agents have no avatar` | The profile avatar is not an agent setting. Its metadata remains in `grokbot-export.json`. | Set an icon separately if the destination needs one. |
|
|
1609
|
+
| `Unknown recipe field; ignored.` | The recipe contains a field this BDK version does not map. | Inspect the field and add its behavior to the generated project when needed. |
|
|
1610
|
+
| `Paused schedule ...` | A paused cron trigger does not produce a schedule file. | Leave it paused, or add a schedule under `bot/schedules/`. |
|
|
1611
|
+
| `trigger dropped: the ... channel is off.` | The answers disabled the channel used by a trigger. | Enable the channel in the answers or add the trigger manually after export. |
|
|
1612
|
+
| `trigger has no BDK channel.` | The trigger type has no direct BDK channel mapping. | Add a supported channel or custom wake; use the generated on-request skill when one is present. |
|
|
1613
|
+
| `is not a five-field cron expression.` | The source cron cannot become a BDK schedule. | Correct the expression and add the schedule before enabling it. |
|
|
1614
|
+
| `placeholders ... are unfilled` | A routine still contains values such as `{slack_channel}`. | Set `fillIns.<routine-slug>` in the answers or edit the generated text. |
|
|
1615
|
+
| `BDK has no built-in KV seed` | `memory: "kv"` writes data but does not load it into hosted KV. | Add your own `ctx.host.kv` seeding code, or use `memory: "skill"`. |
|
|
1616
|
+
|
|
1617
|
+
Treat setup steps and warnings as the checklist for restoring the source
|
|
1618
|
+
behavior. A generated project is ready for review, not automatically ready for
|
|
1619
|
+
live traffic.
|
|
1620
|
+
|
|
1621
|
+
## Set secrets and reconnect OAuth
|
|
1622
|
+
|
|
1623
|
+
The export carries secret names only, never values. `SECRETS.md` lists each
|
|
1624
|
+
name, where it is read, and every connector that needs a fresh sign-in.
|
|
1625
|
+
|
|
1626
|
+
Set local values in the environment where you run `bdk dev`. For a hosted
|
|
1627
|
+
deployment, let `bdk` prompt for each value:
|
|
1628
|
+
|
|
1629
|
+
```bash
|
|
1630
|
+
bdk secrets set launch-desk LINEAR_API_KEY
|
|
1631
|
+
```
|
|
1632
|
+
|
|
1633
|
+
OAuth tokens do not move with the recipe. Sign in to each OAuth connector
|
|
1634
|
+
again:
|
|
1635
|
+
|
|
1636
|
+
```bash
|
|
1637
|
+
bdk mcp oauth notion
|
|
1638
|
+
```
|
|
1639
|
+
|
|
1640
|
+
Add `--store` when the sign-in is for a hosted deployment.
|
|
1641
|
+
|
|
1642
|
+
## Check cron schedules in UTC
|
|
1643
|
+
|
|
1644
|
+
BDK evaluates cron schedules in UTC. A recipe routine that asks for a
|
|
1645
|
+
timezone produces a warning like:
|
|
1646
|
+
|
|
1647
|
+
```text
|
|
1648
|
+
routines/morning-launch-brief: BDK runs `0 8 * * 1-5` in UTC, not America/Los_Angeles; adjust the cron in bot/schedules/morning-launch-brief.md if the time matters.
|
|
1649
|
+
```
|
|
1650
|
+
|
|
1651
|
+
The timezone answer documents the source intent; it does not rewrite the cron.
|
|
1652
|
+
Check each generated file under `bot/schedules/` and translate local
|
|
1653
|
+
wall-clock times to UTC. For locations that observe daylight saving time,
|
|
1654
|
+
also decide how you will handle the offset change.
|
|
1655
|
+
|
|
1656
|
+
## Use the handoff files
|
|
1657
|
+
|
|
1658
|
+
| File | Purpose |
|
|
1659
|
+
| --- | --- |
|
|
1660
|
+
| `AGENTS.md` | Gives a coding agent the project commands and points it to the export handoff. |
|
|
1661
|
+
| `SECRETS.md` | Lists secret names and connector sign-ins, without values. |
|
|
1662
|
+
| `SLACK.md` | When Slack is selected, holds the Slack app setup notes. |
|
|
1663
|
+
| `.cursor/skills/finish-grokbot-export/SKILL.md` | Guides a coding agent through the remaining setup, warnings, validation, and local test. |
|
|
1664
|
+
| `.cursor/environment.json` | Tells a Cursor cloud agent to install the project with `npm install`. |
|
|
1665
|
+
|
|
1666
|
+
Server-side secret transfer, automatic moves of existing Slack apps, and
|
|
1667
|
+
self-deploy are not shipped, so this guide does not cover those flows.
|
|
1668
|
+
|
|
1669
|
+
## Related
|
|
1670
|
+
|
|
1671
|
+
- [`bdk init`](/docs/reference/cli.md#init): flags, JSON output, and failures
|
|
1672
|
+
- [Project layout](/docs/reference/project-layout.md): generated project files
|
|
1673
|
+
- [Schedules and reminders](/docs/reference/schedules.md): cron behavior
|
|
1674
|
+
- [MCP connections](/docs/reference/connections.md): connector auth choices
|
|
1675
|
+
|
|
1676
|
+
---
|
|
1677
|
+
|
|
1397
1678
|
Source: /docs/guides/github.md
|
|
1398
1679
|
|
|
1399
1680
|
# GitHub agents
|
|
@@ -2313,9 +2594,11 @@ replay recorded events into hooks.
|
|
|
2313
2594
|
| --- | --- |
|
|
2314
2595
|
| Add context before the model | `instructions.md`, skills, or `workspaceFiles` |
|
|
2315
2596
|
| Deliver to Slack or a PR | Channel [`events`](/docs/reference/channels.md#events) or packs |
|
|
2316
|
-
| Gate final assistant text | `defineResult` |
|
|
2317
2597
|
| Gate behavior | [Evals](/docs/evals.md) |
|
|
2318
2598
|
|
|
2599
|
+
To act on a turn's decision, have the model record it with an authored
|
|
2600
|
+
[tool](/docs/reference/tools.md), then act on it from a `turn.completed` hook.
|
|
2601
|
+
|
|
2319
2602
|
[Cursor Agent hooks](https://cursor.com/docs/agent/hooks) in
|
|
2320
2603
|
`.cursor/hooks.json` are a different product. They can observe, block, or
|
|
2321
2604
|
modify the local agent loop.
|
|
@@ -3086,7 +3369,9 @@ await serve(".", {
|
|
|
3086
3369
|
|
|
3087
3370
|
Use environment variables when you start the agent with
|
|
3088
3371
|
`bdk serve`. Use `serve({ otel })` when your TypeScript
|
|
3089
|
-
application starts the server itself.
|
|
3372
|
+
application starts the server itself. When that application
|
|
3373
|
+
already uses OpenTelemetry, BDK sends its traces, metrics, and
|
|
3374
|
+
logs to the collector configured here.
|
|
3090
3375
|
|
|
3091
3376
|
## Follow one conversation
|
|
3092
3377
|
|
|
@@ -3109,6 +3394,35 @@ turn: agent_sdk.turn
|
|
|
3109
3394
|
A conversation can produce several turn traces, so use the session ID
|
|
3110
3395
|
as the join key instead of expecting one long-lived session span.
|
|
3111
3396
|
|
|
3397
|
+
### Subagents
|
|
3398
|
+
|
|
3399
|
+
A subagent's tool calls are `agent_sdk.tool` spans under its
|
|
3400
|
+
`agent_sdk.subagent` span. Its `reasoning.completed` and
|
|
3401
|
+
`message.completed` events sit on that span too, so the subagent span
|
|
3402
|
+
shows where its time went. Time between two tool spans is the model
|
|
3403
|
+
choosing the next step. A subagent that fails or is cancelled ends its
|
|
3404
|
+
span with ERROR status when it stops.
|
|
3405
|
+
|
|
3406
|
+
### Computer use
|
|
3407
|
+
|
|
3408
|
+
Each computer use action is an `agent_sdk.tool` span with
|
|
3409
|
+
`cursor.tool.name` set to `computerUse`, under the computer use
|
|
3410
|
+
subagent's span. A failed action has ERROR status. These attributes
|
|
3411
|
+
describe the action without typed text, coordinates, or screenshots:
|
|
3412
|
+
|
|
3413
|
+
| Attribute | Value |
|
|
3414
|
+
| --- | --- |
|
|
3415
|
+
| `agent_sdk.computer.actions` | The action type, such as `click`, `type`, or `screenshot` |
|
|
3416
|
+
| `agent_sdk.computer.executor_duration_ms` | Time the desktop took to run the action and capture the screen |
|
|
3417
|
+
| `agent_sdk.computer.settle_ms` | Part of that time spent waiting for the screen to settle |
|
|
3418
|
+
|
|
3419
|
+
The two durations appear only on actions that succeed.
|
|
3420
|
+
|
|
3421
|
+
To export the full actions, turn on tool content as shown in
|
|
3422
|
+
[Control what leaves the process](#control-what-leaves-the-process).
|
|
3423
|
+
Tool content includes the text the agent typed, which can contain
|
|
3424
|
+
passwords.
|
|
3425
|
+
|
|
3112
3426
|
## Add domain telemetry
|
|
3113
3427
|
|
|
3114
3428
|
Use `ctx.host.otel` when your dashboard should answer questions the
|
|
@@ -3159,10 +3473,11 @@ The first metrics to look for are `cursor.token.usage`,
|
|
|
3159
3473
|
|
|
3160
3474
|
## Control what leaves the process
|
|
3161
3475
|
|
|
3162
|
-
|
|
3163
|
-
|
|
3164
|
-
|
|
3165
|
-
|
|
3476
|
+
Traces include structure, tool names, usage metrics, and span
|
|
3477
|
+
status. A failed tool's status includes a short failure reason.
|
|
3478
|
+
A tool or subagent that is still open when the turn ends gets
|
|
3479
|
+
ERROR status with the reason `no result`. User prompts, tool
|
|
3480
|
+
arguments, and full tool results stay off the wire until you opt in.
|
|
3166
3481
|
|
|
3167
3482
|
Turn on logs first, then opt into prompt or tool content separately:
|
|
3168
3483
|
|
|
@@ -3964,6 +4279,9 @@ Describe your bot or agent in Cursor, or edit the files yourself.
|
|
|
3964
4279
|
- [Convert a Cursor Automation](/docs/guides/convert-automation.md): export
|
|
3965
4280
|
an Automation from the dashboard into a project you own.
|
|
3966
4281
|
|
|
4282
|
+
- [Export a Grok Bot](/docs/guides/export-grokbot.md): turn a recipe into a BDK
|
|
4283
|
+
project and review what needs manual setup.
|
|
4284
|
+
|
|
3967
4285
|
- [Build agents with agents](/docs/building-with-agents.md): hand the build
|
|
3968
4286
|
to a coding agent with the package's bundled skills.
|
|
3969
4287
|
|
|
@@ -4966,6 +5284,7 @@ bdk serve [--dir <path>] [--port <n>] [--host <host>]
|
|
|
4966
5284
|
[--allow-anonymous-cursor-account-mcp]
|
|
4967
5285
|
[--allow-anonymous-grokbot]
|
|
4968
5286
|
[--public-url <url>]
|
|
5287
|
+
[--peers-url <url>]
|
|
4969
5288
|
[--no-schedules] [--no-playground] [--no-docs]
|
|
4970
5289
|
[--cursor-events --repo <owner/name>]...
|
|
4971
5290
|
```
|
|
@@ -4975,7 +5294,7 @@ bdk serve [--dir <path>] [--port <n>] [--host <host>]
|
|
|
4975
5294
|
| `--port <n>` | Listen on this port. The default is `3000`; `0` selects an available port. When an omitted default is occupied, the CLI selects the next port. An occupied explicit port fails with a next-port hint. |
|
|
4976
5295
|
| `--host <host>` | Bind this host. The default is loopback-only `127.0.0.1`. |
|
|
4977
5296
|
| `--mode multi` | Mount projects at `/<slug>/v1/*` and `/<slug>/playground`, with an index at `/`. This is the default. |
|
|
4978
|
-
| `--mode single` | Mount one project at `/v1/*` and `/playground`. |
|
|
5297
|
+
| `--mode single` | Mount one project at `/v1/*` and `/playground`. Declared peers are omitted with a warning unless `--peers-url` is set. |
|
|
4979
5298
|
| `--dev` | Disable automatic schedule and reminder firing, admit unsigned loopback GitHub deliveries, and enable local playground access. |
|
|
4980
5299
|
| `--state-root <path>` | Store local sessions, streams, workspaces, and channel state here. Keep durable state outside a repository whose rules shouldn't reach agent workspaces. |
|
|
4981
5300
|
| `--bearer-token <secret>` | Require this token on routes without authored authentication. Mutually exclusive with `--allow-anonymous`. |
|
|
@@ -4984,6 +5303,7 @@ bdk serve [--dir <path>] [--port <n>] [--host <host>]
|
|
|
4984
5303
|
| `--allow-anonymous-cursor-account-mcp` | Let anonymous callers use Cursor account MCP connections. Requires an authenticating proxy. |
|
|
4985
5304
|
| `--allow-anonymous-grokbot` | Let anonymous callers drive hosted Grok Bot runtime agents. Requires an authenticating proxy. |
|
|
4986
5305
|
| `--public-url <url>` | Set the externally reachable base URL that turns running off the serve host use for peer MCP and host bridges. It does not expose the server; configure the listener or proxy separately. Local-runtime peers use loopback. |
|
|
5306
|
+
| `--peers-url <url>` | Resolve declared peers for a single-agent serve through a hosting-provided peer service. Cursor-managed hosting sets this option automatically; a multi-agent serve rejects it. |
|
|
4987
5307
|
| `--no-schedules` | Disable schedule firing outside dev mode. |
|
|
4988
5308
|
| `--no-playground` | Skip the playground. |
|
|
4989
5309
|
| `--no-docs` | Skip the documentation site at `/docs`. |
|
|
@@ -5277,6 +5597,8 @@ requires an ID. The `status` and `cancel` subcommands require `--url`.
|
|
|
5277
5597
|
|
|
5278
5598
|
```text
|
|
5279
5599
|
bdk init [directory] [--template <name>] [--var id=value]... [--json]
|
|
5600
|
+
bdk init [directory] --from-grokbot <recipe.json>
|
|
5601
|
+
[--answers <file>] [--dry-run] [--json]
|
|
5280
5602
|
```
|
|
5281
5603
|
|
|
5282
5604
|
Without a directory, `init` prints the setup guide and changes no files. With
|
|
@@ -5293,6 +5615,40 @@ On a TTY, templates with questions run their interview before writing files.
|
|
|
5293
5615
|
`init` also offers to refresh the bundled coding-agent skills and starts login
|
|
5294
5616
|
when the host has no Cursor credential.
|
|
5295
5617
|
|
|
5618
|
+
#### Export a Grok Bot recipe
|
|
5619
|
+
|
|
5620
|
+
`--from-grokbot` reads a Grok Bot recipe and maps its profile, selected skills
|
|
5621
|
+
and routines, memory, channels, and connectors into a BDK project. The target
|
|
5622
|
+
directory defaults to the resolved `location` answer; a positional directory
|
|
5623
|
+
overrides it. A target previously created with `bdk init --template` is
|
|
5624
|
+
rejected; export into a fresh directory instead.
|
|
5625
|
+
|
|
5626
|
+
| Option | Contract |
|
|
5627
|
+
| --- | --- |
|
|
5628
|
+
| `--from-grokbot <recipe.json>` | Read the recipe to export. |
|
|
5629
|
+
| `--answers <file>` | Read export decisions from a JSON object. Fields present in the file are not asked again. The published schema is `schemas/grokbot-answers.schema.json`. |
|
|
5630
|
+
| `--dry-run` | Print the planned files, defaults, exclusions, unmapped behavior, placeholders, secret names, warnings, and setup steps without writing files or installing dependencies. |
|
|
5631
|
+
| `--json` | Never prompt and print machine-readable output. Combine it with `--dry-run` for a machine-readable preview. |
|
|
5632
|
+
|
|
5633
|
+
On a TTY, the command asks for missing decisions and offers recipe-derived
|
|
5634
|
+
defaults. Off a TTY, it never prompts, takes defaults where possible, and
|
|
5635
|
+
lists the fields it defaulted.
|
|
5636
|
+
|
|
5637
|
+
`--dry-run --json` prints `{ ok, dryRun, directory, preview }`. The preview
|
|
5638
|
+
contains `version`, `name`, resolved `answers`, `defaulted`, `ignored`, `files`
|
|
5639
|
+
as `{ path, from }`, `excluded`, `unmapped` as `{ from, reason }`, `fillIns`,
|
|
5640
|
+
`secrets` as `{ names, reauth }`, `warnings`, and `setupSteps`. A write with
|
|
5641
|
+
`--json` also reports `files`, `installed`, and `installError`. A dependency
|
|
5642
|
+
install failure leaves `ok: true`, sets `installed: false`, reports
|
|
5643
|
+
`installError`, and exits `0`. Other errors print `{ ok: false, error }` and
|
|
5644
|
+
exit nonzero.
|
|
5645
|
+
|
|
5646
|
+
`--answers` and `--dry-run` require `--from-grokbot`. This export mode does
|
|
5647
|
+
not accept `--template` or `--var`.
|
|
5648
|
+
|
|
5649
|
+
See [Export a Grok Bot](/docs/guides/export-grokbot.md) for the preview-first
|
|
5650
|
+
workflow, mapping table, and post-export checklist.
|
|
5651
|
+
|
|
5296
5652
|
### Convert an Automation {#convert-automation}
|
|
5297
5653
|
|
|
5298
5654
|
```text
|
|
@@ -5866,8 +6222,8 @@ An MCP connection gives the agent tools from an MCP server. Define one
|
|
|
5866
6222
|
file per server under `bot/mcp-connections/`; the filename becomes the
|
|
5867
6223
|
server name. Default-export `defineConnection` from
|
|
5868
6224
|
`@cursor/bdk/connections`. The transport is remote HTTP, local stdio,
|
|
5869
|
-
the signed-in Cursor account's connectors, or a peer agent
|
|
5870
|
-
|
|
6225
|
+
the signed-in Cursor account's connectors, or a peer agent addressed by
|
|
6226
|
+
slug.
|
|
5871
6227
|
|
|
5872
6228
|
Put a server in `bot/host-connections/` when only host tools should
|
|
5873
6229
|
call it. Host connections use the same `defineConnection` shape and
|
|
@@ -6111,9 +6467,14 @@ Use a `{ command }` connection for stdio servers.
|
|
|
6111
6467
|
|
|
6112
6468
|
## Peer MCP connection {#peer-mcp-connection}
|
|
6113
6469
|
|
|
6114
|
-
`{ agent: "<slug>" }` addresses another agent
|
|
6115
|
-
|
|
6116
|
-
|
|
6470
|
+
`{ agent: "<slug>" }` addresses another agent without configuring a URL,
|
|
6471
|
+
headers, or secrets. On a local multi-agent serve, the target is another
|
|
6472
|
+
mount slug. On Cursor-managed hosting, it is the lowercase deployment slug
|
|
6473
|
+
of another agent on the same team.
|
|
6474
|
+
|
|
6475
|
+
On a local multi-agent serve, the model gets the peer's `ask` and `check`
|
|
6476
|
+
tools, plus `call_tool` when the peer has server tools, and can delegate work
|
|
6477
|
+
to it:
|
|
6117
6478
|
|
|
6118
6479
|
```ts
|
|
6119
6480
|
export default defineConnection({
|
|
@@ -6122,7 +6483,12 @@ export default defineConnection({
|
|
|
6122
6483
|
});
|
|
6123
6484
|
```
|
|
6124
6485
|
|
|
6125
|
-
|
|
6486
|
+
Declare the connection only on the caller. The specialist needs no matching
|
|
6487
|
+
configuration.
|
|
6488
|
+
|
|
6489
|
+
In a local multi-agent serve, unknown slugs and self-references fail at
|
|
6490
|
+
startup. A single-agent serve omits peers with a warning unless its hosting
|
|
6491
|
+
platform sets `--peers-url`. Walkthrough:
|
|
6126
6492
|
[Peer agents](/docs/guides/agent-to-agent.md#delegate-a-question-to-a-specialist).
|
|
6127
6493
|
|
|
6128
6494
|
## Call MCP from host code
|
|
@@ -6724,7 +7090,8 @@ reports all three. An extension mounts its hooks as `<ns>__<name>`, and
|
|
|
6724
7090
|
|
|
6725
7091
|
`bdk init` scaffolds `bot/hooks/memory.ts`, which exports
|
|
6726
7092
|
`memoryHook()` from `@cursor/bdk/memory` and journals every turn for
|
|
6727
|
-
later sessions to read. Delete the file to opt out.
|
|
7093
|
+
later sessions to read. Delete the file to opt out. See
|
|
7094
|
+
[Memory](/docs/reference/memory.md).
|
|
6728
7095
|
|
|
6729
7096
|
## Events and payloads
|
|
6730
7097
|
|
|
@@ -6830,9 +7197,12 @@ All three consume the same stream, for different jobs:
|
|
|
6830
7197
|
| Add context before the model runs | The channel's `send` message and `workspaceFiles`, `instructions.md`, skills, or `sandbox/workspace/` seed files |
|
|
6831
7198
|
| Reply on Slack, comment on a PR, or post any other delivery | The channel's `events` map, or the Slack and GitHub packs |
|
|
6832
7199
|
| Show PR progress (merge-box check, sticky banner) | `githubChannel({ progress: { commitStatus, banner } })`; see [GitHub agents](/docs/guides/github.md) |
|
|
6833
|
-
| Act on the final assistant text, reject it for a same-turn repair, or fail a bad turn | `defineResult` |
|
|
6834
7200
|
| Gate a change on behavior | [Evals](/docs/evals.md) |
|
|
6835
7201
|
|
|
7202
|
+
To act on a turn's decision, such as a label or a ticket, have the model
|
|
7203
|
+
record it with an authored [tool](/docs/reference/tools.md). A `turn.completed` hook then
|
|
7204
|
+
reads the recorded decision and acts on it through `ctx.host`.
|
|
7205
|
+
|
|
6836
7206
|
## Test a hook
|
|
6837
7207
|
|
|
6838
7208
|
A hook definition is a plain object, so a unit test calls
|
|
@@ -7151,6 +7521,125 @@ Put multi-step workflows the model only sometimes needs in
|
|
|
7151
7521
|
|
|
7152
7522
|
---
|
|
7153
7523
|
|
|
7524
|
+
Source: /docs/reference/memory.md
|
|
7525
|
+
|
|
7526
|
+
# Memory
|
|
7527
|
+
|
|
7528
|
+
Memory lets an agent recall work from earlier sessions. A memory hook
|
|
7529
|
+
appends one record per turn to a shared journal, and the model reads
|
|
7530
|
+
that journal with its normal file tools when its instructions send it
|
|
7531
|
+
there. Every session and every user of the agent shares one journal.
|
|
7532
|
+
|
|
7533
|
+
## Memory is on by default
|
|
7534
|
+
|
|
7535
|
+
`bdk init` scaffolds `bot/hooks/memory.ts`:
|
|
7536
|
+
|
|
7537
|
+
```ts
|
|
7538
|
+
// bot/hooks/memory.ts
|
|
7539
|
+
import { memoryHook } from "@cursor/bdk/memory";
|
|
7540
|
+
|
|
7541
|
+
export default memoryHook();
|
|
7542
|
+
```
|
|
7543
|
+
|
|
7544
|
+
It also adds a `## Memory` section to `bot/instructions.md`. The model
|
|
7545
|
+
has no recall tool, so that section is what sends it to the journal:
|
|
7546
|
+
it says when to read `memory/`, and it tells the model to treat records
|
|
7547
|
+
as untrusted history. To add memory to an existing project, create the
|
|
7548
|
+
hook file and copy the `## Memory` section from a fresh `bdk init`
|
|
7549
|
+
project into your instructions. To turn memory off, delete the hook
|
|
7550
|
+
file and the `## Memory` section.
|
|
7551
|
+
|
|
7552
|
+
## Journal records
|
|
7553
|
+
|
|
7554
|
+
The hook appends one JSON line to `memory/journal.jsonl` after each
|
|
7555
|
+
turn completes or fails:
|
|
7556
|
+
|
|
7557
|
+
```json
|
|
7558
|
+
{"at":"2026-10-01T16:42:09.118Z","sessionId":"5f0c2a9e-7d1b-4c43-9a6e-2b8f1e0d7c35","channelId":"slack","status":"completed","title":"Checkout flaky test","userMessage":"Why does acme/checkout fail on main?","result":"The cart test races the price service mock...","usage":{"inputTokens":18234,"outputTokens":912,"cacheReadTokens":15002,"cacheWriteTokens":0}}
|
|
7559
|
+
```
|
|
7560
|
+
|
|
7561
|
+
| Field | Contract |
|
|
7562
|
+
| --- | --- |
|
|
7563
|
+
| `at` | ISO-8601 time the turn finished |
|
|
7564
|
+
| `sessionId` | Session that ran the turn |
|
|
7565
|
+
| `channelId` | Channel that started the session, such as `http` for the session API |
|
|
7566
|
+
| `status` | `"completed"` or `"failed"` |
|
|
7567
|
+
| `title` | Session title, when the channel set one |
|
|
7568
|
+
| `userMessage` | The message that started the turn, truncated to `maxTextLength` |
|
|
7569
|
+
| `result` | Final assistant text, or the failure message, truncated to `maxTextLength` |
|
|
7570
|
+
| `usage` | Token usage for completed turns; see [Events and payloads](/docs/reference/hooks.md#events-and-payloads) |
|
|
7571
|
+
|
|
7572
|
+
As the journal grows, older records move to `journal-*.jsonl` files
|
|
7573
|
+
beside it. Point the model at the whole `memory/` directory when it
|
|
7574
|
+
needs history beyond the latest segment.
|
|
7575
|
+
|
|
7576
|
+
## Read memory
|
|
7577
|
+
|
|
7578
|
+
Local turns find the journal at `memory/` in the session workspace. On
|
|
7579
|
+
a Cursor-hosted deployment, the first prompt of each session names the
|
|
7580
|
+
journal's path on that machine. A session on a server you run yourself
|
|
7581
|
+
can't reach the journal.
|
|
7582
|
+
|
|
7583
|
+
`memory` is a reserved workspace path. BDK rejects per-send
|
|
7584
|
+
`workspaceFiles` and `sandbox/workspace/` seed files under `memory/`,
|
|
7585
|
+
so callers can't write records through the workspace.
|
|
7586
|
+
|
|
7587
|
+
Local servers keep the journal in the project state directory. `bdk
|
|
7588
|
+
run` and `bdk eval` start an ephemeral server with a fresh state
|
|
7589
|
+
directory unless you pass `--state-root`, so each run starts with
|
|
7590
|
+
empty memory. Use `bdk serve` or `bdk dev`, or pass the same
|
|
7591
|
+
`--state-root`, to keep memory across runs. Hosted deployments keep
|
|
7592
|
+
the journal across redeploys.
|
|
7593
|
+
|
|
7594
|
+
## Who sees memory
|
|
7595
|
+
|
|
7596
|
+
Records from every session and every user land in the same journal, so
|
|
7597
|
+
one person's messages and the agent's replies to them can surface in
|
|
7598
|
+
another person's session. Turn memory off for an agent whose users
|
|
7599
|
+
shouldn't see each other's requests. Turning it off stops new records,
|
|
7600
|
+
but the journal keeps the records it already has. On a local server,
|
|
7601
|
+
delete the `memory/` directory in the project state directory to clear
|
|
7602
|
+
them. On Cursor-managed hosting, the journal is deployment data, so
|
|
7603
|
+
[Privacy Mode](/docs/deployment.md#privacy-mode) applies to it.
|
|
7604
|
+
|
|
7605
|
+
Anyone who can message the agent can put text in the journal. The
|
|
7606
|
+
scaffolded instructions tell the model never to follow instructions
|
|
7607
|
+
found inside records; keep that rule if you write your own section.
|
|
7608
|
+
|
|
7609
|
+
## Memory and host state
|
|
7610
|
+
|
|
7611
|
+
Memory is advisory. A record can be dropped, and records written by
|
|
7612
|
+
concurrent sessions can show up only in a later session. Keep state
|
|
7613
|
+
your code depends on, such as dedupe records and cursors, in
|
|
7614
|
+
`ctx.host.kv` or `ctx.host.files`; see
|
|
7615
|
+
[Handler context](/docs/reference/hooks.md#handler-context).
|
|
7616
|
+
|
|
7617
|
+
## Options
|
|
7618
|
+
|
|
7619
|
+
`memoryHook(options?)` accepts:
|
|
7620
|
+
|
|
7621
|
+
| Option | Contract |
|
|
7622
|
+
| --- | --- |
|
|
7623
|
+
| `maxTextLength` | Truncation cap for `userMessage` and `result`. Default `2000` characters. |
|
|
7624
|
+
| `backend` | A `MemoryBackend` that replaces the default journal |
|
|
7625
|
+
|
|
7626
|
+
A `MemoryBackend` has `appendTurn(record, { stateRoot, agentName })`,
|
|
7627
|
+
which receives each record, and an optional
|
|
7628
|
+
`prepareSession({ stateRoot, agentName })`, which runs when a session
|
|
7629
|
+
starts. Records go only where `appendTurn` sends them, but the
|
|
7630
|
+
`memory/` directory and the hosted first-prompt path still point at the
|
|
7631
|
+
default journal. Give the model a tool or file to read your records,
|
|
7632
|
+
and write instructions that send it there instead of `memory/`.
|
|
7633
|
+
|
|
7634
|
+
## Related
|
|
7635
|
+
|
|
7636
|
+
- [Hooks](/docs/reference/hooks.md)
|
|
7637
|
+
- [Instructions](/docs/reference/instructions.md)
|
|
7638
|
+
- [Sessions](/docs/reference/sessions.md)
|
|
7639
|
+
- [Deployment](/docs/deployment.md)
|
|
7640
|
+
|
|
7641
|
+
---
|
|
7642
|
+
|
|
7154
7643
|
Source: /docs/reference/playground.md
|
|
7155
7644
|
|
|
7156
7645
|
# Playground
|
|
@@ -7271,12 +7760,15 @@ Each path maps to a capability and a reference page.
|
|
|
7271
7760
|
| `channels/*.ts` | HTTP surfaces beyond the built-in session API; `slack.ts` and `github.ts` use the platform packs | [Channels](/docs/reference/channels.md) |
|
|
7272
7761
|
| `hooks/*.ts` | Observe-only event subscribers, never fatal | [Hooks](/docs/reference/hooks.md) |
|
|
7273
7762
|
| `artifacts.ts` | `defineArtifacts` kinds, the `tag_artifact` opt-in, and retention | [Artifacts](/docs/reference/artifacts.md) |
|
|
7274
|
-
| `result.ts` | `defineResult` host `commit` on the final assistant text (`throw` or `ctx.reject`) | None |
|
|
7275
7763
|
| `schedules/*` | Cron-driven runs (UTC, 5-field; never auto-fire under `--dev`) | [Schedules](/docs/reference/schedules.md) |
|
|
7276
7764
|
| `reminders/*.ts` | Named reminder handlers that stay armed across restarts | [Schedules](/docs/reference/schedules.md#reminders) |
|
|
7277
7765
|
| `sandbox/workspace/**` | Seed files copied into each local session workspace | [Sessions](/docs/reference/sessions.md#local-session-workspace) |
|
|
7278
7766
|
| `lib/` | Import-only shared code, never discovered | None |
|
|
7279
7767
|
|
|
7768
|
+
Discovery rejects a `bot/result.ts` file. To act on a turn's decision, have
|
|
7769
|
+
the model record it with an authored [tool](/docs/reference/tools.md), then act on it from a
|
|
7770
|
+
`turn.completed` [hook](/docs/reference/hooks.md).
|
|
7771
|
+
|
|
7280
7772
|
Evals use project-root paths:
|
|
7281
7773
|
|
|
7282
7774
|
| Project-root path | What it is | Reference |
|
|
@@ -7651,9 +8143,7 @@ within one session. The `at` field is an ISO-8601 timestamp.
|
|
|
7651
8143
|
Pair `actions.requested` with `actions.completed` for each model-step
|
|
7652
8144
|
batch. `action.result` is the live per-call envelope. Read
|
|
7653
8145
|
`turn.completed.data.usage` for input, output, and
|
|
7654
|
-
cache token counts.
|
|
7655
|
-
`commit` throws, the turn has no assistant text, or `ctx.reject(message)`
|
|
7656
|
-
doesn't lead to an accepted revision.
|
|
8146
|
+
cache token counts.
|
|
7657
8147
|
|
|
7658
8148
|
## Stream or replay events
|
|
7659
8149
|
|
|
@@ -7806,6 +8296,8 @@ mid-turn. Each one lives under `bot/subagents/<id>/` with a required
|
|
|
7806
8296
|
`agent.ts`. Add `instructions.md` or inline `instructions` in `agent.ts`
|
|
7807
8297
|
for a custom prompt. The parent model delegates through the `task` tool,
|
|
7808
8298
|
and the stream records `subagent.called` and `subagent.completed`.
|
|
8299
|
+
`subagent.completed` has `isError: true` when the subagent failed or was
|
|
8300
|
+
cancelled.
|
|
7809
8301
|
|
|
7810
8302
|
```text
|
|
7811
8303
|
bot/subagents/researcher/
|
|
@@ -8750,7 +9242,7 @@ Match the visible symptom below.
|
|
|
8750
9242
|
| `run --prod --session <sessionId>` reports the session belongs to another channel | `--session` continues only sessions that `run --prod` or `session --prod` started. Reach Slack, SCM, and custom-route sessions through their own channel. |
|
|
8751
9243
|
| A custom route returns `202` with no body | Expected on managed hosting. The handler runs after the response, so deliver results from the channel. See [Route responses](/docs/reference/channels.md#route-responses). |
|
|
8752
9244
|
| External HTTP rejects the alias token | Update the caller with the current token. If the token is lost or exposed, run `bdk rotate-token <slug>` and replace it everywhere. |
|
|
8753
|
-
| `deploy
|
|
9245
|
+
| `deploy`, a hosted session, or an eval run says it is not available with Privacy Mode (Legacy) | Switch to Privacy Mode, or ask a team admin if your team enforces this setting. A refused session does not store the message. See [Privacy Mode](/docs/deployment.md#privacy-mode). |
|
|
8754
9246
|
| `deploy` says persistent deployments are limited to 1 per team | Another deployment of the team already sets `persistent: true`. Remove the setting from one agent, or delete that deployment. |
|
|
8755
9247
|
| A schedule does not fire on the hosted deployment | Make sure the deployment is running and its release has the schedule. Deploy again with `@cursor/bdk` 0.2.14 or newer. |
|
|
8756
9248
|
| A request to a custom route gets `429` | The deployment received more requests than its limit. Wait for the time in `Retry-After`, then send the request again. |
|