@cursor/july 0.1.113 → 0.1.114
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/dist/docs/404.html +2 -2
- package/dist/docs/assets/{app.CAeK13eM.js → app.BqkJwOZ-.js} +4 -4
- package/dist/docs/assets/chunks/@localSearchIndexroot.BnSgidYE.js +1 -0
- package/dist/docs/assets/chunks/{VPLocalSearchBox.C9LbPHod.js → VPLocalSearchBox.BJAi2KiV.js} +1 -1
- package/dist/docs/assets/chunks/{arc.CmMq2zmS.js → arc.BZpXTgvV.js} +1 -1
- package/dist/docs/assets/chunks/{architectureDiagram-Q4EWVU46.CCXB8Uj5.js → architectureDiagram-Q4EWVU46.WYI-7F-Y.js} +1 -1
- package/dist/docs/assets/chunks/{baseUniq.CyQo6eLe.js → baseUniq.CZaUPpg0.js} +1 -1
- package/dist/docs/assets/chunks/{blockDiagram-DXYQGD6D.JYq6w91N.js → blockDiagram-DXYQGD6D.D6UES2pD.js} +1 -1
- package/dist/docs/assets/chunks/{c4Diagram-AHTNJAMY.BRV8GPJJ.js → c4Diagram-AHTNJAMY.cwebIe4i.js} +1 -1
- package/dist/docs/assets/chunks/channel.DdM5EfNW.js +1 -0
- package/dist/docs/assets/chunks/{chunk-4BX2VUAB.Bv4ooYQR.js → chunk-4BX2VUAB.fVyFnjxg.js} +1 -1
- package/dist/docs/assets/chunks/{chunk-4TB4RGXK.t4JtKPcj.js → chunk-4TB4RGXK.BanufG1c.js} +1 -1
- package/dist/docs/assets/chunks/{chunk-55IACEB6.34lCHj9Y.js → chunk-55IACEB6.VaSMz5-2.js} +1 -1
- package/dist/docs/assets/chunks/{chunk-EDXVE4YY.BSwrPNrt.js → chunk-EDXVE4YY.CN2diZOM.js} +1 -1
- package/dist/docs/assets/chunks/{chunk-FMBD7UC4.Beeun-R-.js → chunk-FMBD7UC4.g4ivypu3.js} +1 -1
- package/dist/docs/assets/chunks/{chunk-OYMX7WX6.BUUFUcJc.js → chunk-OYMX7WX6.GZXKn9JJ.js} +1 -1
- package/dist/docs/assets/chunks/{chunk-QZHKN3VN.B2XjHzN_.js → chunk-QZHKN3VN.itXxJZCd.js} +1 -1
- package/dist/docs/assets/chunks/{chunk-YZCP3GAM.CLYG8znk.js → chunk-YZCP3GAM.-rw2GfvX.js} +1 -1
- package/dist/docs/assets/chunks/classDiagram-6PBFFD2Q.CjfGHeg2.js +1 -0
- package/dist/docs/assets/chunks/classDiagram-v2-HSJHXN6E.CjfGHeg2.js +1 -0
- package/dist/docs/assets/chunks/clone.wSOICb_f.js +1 -0
- package/dist/docs/assets/chunks/{cose-bilkent-S5V4N54A.DVEa6fZp.js → cose-bilkent-S5V4N54A.CmaI5br0.js} +1 -1
- package/dist/docs/assets/chunks/{dagre-KV5264BT.C9PZQK-S.js → dagre-KV5264BT.4wY9S4Kt.js} +1 -1
- package/dist/docs/assets/chunks/{diagram-5BDNPKRD.DoN0uv3Y.js → diagram-5BDNPKRD.Pc3c0u9W.js} +1 -1
- package/dist/docs/assets/chunks/{diagram-G4DWMVQ6.Czv3duqx.js → diagram-G4DWMVQ6.CYrWz-nj.js} +1 -1
- package/dist/docs/assets/chunks/{diagram-MMDJMWI5.BinJ5kWb.js → diagram-MMDJMWI5.Bgj5hukb.js} +1 -1
- package/dist/docs/assets/chunks/{diagram-TYMM5635.DW326M4K.js → diagram-TYMM5635.DGMEXalS.js} +1 -1
- package/dist/docs/assets/chunks/{erDiagram-SMLLAGMA.U2pR_OA7.js → erDiagram-SMLLAGMA.GepTV9Im.js} +1 -1
- package/dist/docs/assets/chunks/{flowDiagram-DWJPFMVM.ByWJXeYK.js → flowDiagram-DWJPFMVM.DVKywg3j.js} +1 -1
- package/dist/docs/assets/chunks/{ganttDiagram-T4ZO3ILL.OquF0Rtg.js → ganttDiagram-T4ZO3ILL.C7qt9Mlo.js} +1 -1
- package/dist/docs/assets/chunks/{gitGraphDiagram-UUTBAWPF.Bpn01P7X.js → gitGraphDiagram-UUTBAWPF.U30_r82P.js} +1 -1
- package/dist/docs/assets/chunks/{graph.CNRB6ETL.js → graph.CyyMyAWv.js} +1 -1
- package/dist/docs/assets/chunks/{infoDiagram-42DDH7IO.CqhknMWi.js → infoDiagram-42DDH7IO.Dn9ACW3y.js} +1 -1
- package/dist/docs/assets/chunks/{ishikawaDiagram-UXIWVN3A.C6xpR2af.js → ishikawaDiagram-UXIWVN3A.DlIdIGOA.js} +1 -1
- package/dist/docs/assets/chunks/{journeyDiagram-VCZTEJTY.Cg5f7oB3.js → journeyDiagram-VCZTEJTY.DZj4vy4E.js} +1 -1
- package/dist/docs/assets/chunks/{kanban-definition-6JOO6SKY.Cx9YTwlU.js → kanban-definition-6JOO6SKY.Dl63eMUV.js} +1 -1
- package/dist/docs/assets/chunks/{layout.ljS-wFtK.js → layout.BLHZLWPH.js} +1 -1
- package/dist/docs/assets/chunks/{linear.jSxNrsFC.js → linear.aXKGKaNw.js} +1 -1
- package/dist/docs/assets/chunks/{min.Cum8AlQw.js → min.zWnFcpcc.js} +1 -1
- package/dist/docs/assets/chunks/{mindmap-definition-QFDTVHPH.BLiysLpe.js → mindmap-definition-QFDTVHPH.Qs4MQBea.js} +1 -1
- package/dist/docs/assets/chunks/{pieDiagram-DEJITSTG.BoIDyuKF.js → pieDiagram-DEJITSTG.BmPHgsk7.js} +1 -1
- package/dist/docs/assets/chunks/{quadrantDiagram-34T5L4WZ.DLkpDytR.js → quadrantDiagram-34T5L4WZ.D5MQ3gwA.js} +1 -1
- package/dist/docs/assets/chunks/{requirementDiagram-MS252O5E.DqTVqSu2.js → requirementDiagram-MS252O5E.CkdUFrO7.js} +1 -1
- package/dist/docs/assets/chunks/{sankeyDiagram-XADWPNL6.CG_6FF7j.js → sankeyDiagram-XADWPNL6.KZrljrAV.js} +1 -1
- package/dist/docs/assets/chunks/{sequenceDiagram-FGHM5R23.BIp9602K.js → sequenceDiagram-FGHM5R23.XMoEW-Lx.js} +1 -1
- package/dist/docs/assets/chunks/{stateDiagram-FHFEXIEX.COSXsD9I.js → stateDiagram-FHFEXIEX.BmTzePLj.js} +1 -1
- package/dist/docs/assets/chunks/stateDiagram-v2-QKLJ7IA2.Cu5X28zZ.js +1 -0
- package/dist/docs/assets/chunks/{theme.CXJ7PNwy.js → theme.BfQzpxsg.js} +2 -2
- package/dist/docs/assets/chunks/{timeline-definition-GMOUNBTQ.CXdVqkLq.js → timeline-definition-GMOUNBTQ.Dug0oamp.js} +1 -1
- package/dist/docs/assets/chunks/{vennDiagram-DHZGUBPP.CZxGuc4r.js → vennDiagram-DHZGUBPP.BOTHrEFu.js} +1 -1
- package/dist/docs/assets/chunks/{wardley-RL74JXVD.3oVgfqQk.js → wardley-RL74JXVD.DXy2i1LS.js} +1 -1
- package/dist/docs/assets/chunks/{wardleyDiagram-NUSXRM2D.6_irCgGJ.js → wardleyDiagram-NUSXRM2D.CoXKdfi6.js} +1 -1
- package/dist/docs/assets/chunks/{xychartDiagram-5P7HB3ND.TRPe92m3.js → xychartDiagram-5P7HB3ND.DXoSCjAW.js} +1 -1
- package/dist/docs/assets/{deployment.md.D2jQZuFx.js → deployment.md.D2YX7u_I.js} +1 -1
- package/dist/docs/assets/{guides_agent-to-agent.md.CD4T5FIl.js → guides_agent-to-agent.md.C6kPY8nu.js} +2 -2
- package/dist/docs/assets/{guides_cloud-agents.md.Cp1O3u-X.js → guides_cloud-agents.md.BPJqTZjT.js} +1 -1
- package/dist/docs/assets/{guides_grokbot-agents.md.CMhZNdEU.js → guides_grokbot-agents.md.CzV715v8.js} +1 -1
- package/dist/docs/assets/guides_hooks.md.BT9GLwEp.js +50 -0
- package/dist/docs/assets/guides_hooks.md.BT9GLwEp.lean.js +1 -0
- package/dist/docs/assets/{guides_jev.md.F5fAkkfN.js → guides_jev.md.DeSCqMaO.js} +6 -44
- package/dist/docs/assets/guides_jev.md.DeSCqMaO.lean.js +1 -0
- package/dist/docs/assets/reference_agent-config.md.BRxAlnRy.js +36 -0
- package/dist/docs/assets/{reference_agent-config.md.DGPyw7ms.lean.js → reference_agent-config.md.BRxAlnRy.lean.js} +1 -1
- package/dist/docs/assets/reference_artifacts.md.KRX0sAdt.js +18 -0
- package/dist/docs/assets/reference_artifacts.md.KRX0sAdt.lean.js +1 -0
- package/dist/docs/assets/reference_channels.md.DZr14vm7.js +23 -0
- package/dist/docs/assets/reference_channels.md.DZr14vm7.lean.js +1 -0
- package/dist/docs/assets/{reference_connections.md.Je9dMsdd.js → reference_connections.md.DJGUCxrr.js} +18 -30
- package/dist/docs/assets/{reference_connections.md.Je9dMsdd.lean.js → reference_connections.md.DJGUCxrr.lean.js} +1 -1
- package/dist/docs/assets/{reference_evals.md.DNJzM_yf.js → reference_evals.md.C6umwNC6.js} +6 -7
- package/dist/docs/assets/reference_evals.md.C6umwNC6.lean.js +1 -0
- package/dist/docs/assets/{reference_extensions.md.Cv5aLCz_.js → reference_extensions.md.DbNYu-DP.js} +3 -3
- package/dist/docs/assets/{reference_extensions.md.Cv5aLCz_.lean.js → reference_extensions.md.DbNYu-DP.lean.js} +1 -1
- package/dist/docs/assets/reference_hooks.md.BfOkhTU0.js +45 -0
- package/dist/docs/assets/{reference_hooks.md.B7uzNENk.lean.js → reference_hooks.md.BfOkhTU0.lean.js} +1 -1
- package/dist/docs/assets/reference_http-api.md.DdwtBeCj.js +11 -0
- package/dist/docs/assets/{reference_http-api.md.CduHavZ2.lean.js → reference_http-api.md.DdwtBeCj.lean.js} +1 -1
- package/dist/docs/assets/reference_instructions.md.B2mcIzT6.js +14 -0
- package/dist/docs/assets/reference_instructions.md.B2mcIzT6.lean.js +1 -0
- package/dist/docs/assets/reference_playground.md.CyrQD_n3.js +1 -0
- package/dist/docs/assets/reference_playground.md.CyrQD_n3.lean.js +1 -0
- package/dist/docs/assets/reference_project-layout.md.BEMzxAkq.js +19 -0
- package/dist/docs/assets/{reference_project-layout.md.BGhgpy9V.lean.js → reference_project-layout.md.BEMzxAkq.lean.js} +1 -1
- package/dist/docs/assets/reference_prompt.md.BFrqjHFL.js +9 -0
- package/dist/docs/assets/reference_prompt.md.BFrqjHFL.lean.js +1 -0
- package/dist/docs/assets/reference_schedules.md.BB9N3tRR.js +47 -0
- package/dist/docs/assets/reference_schedules.md.BB9N3tRR.lean.js +1 -0
- package/dist/docs/assets/reference_sessions.md.BBp-GIt-.js +1 -0
- package/dist/docs/assets/{reference_sessions.md.1_6Vyv7x.lean.js → reference_sessions.md.BBp-GIt-.lean.js} +1 -1
- package/dist/docs/assets/reference_skills.md.BVmi3UJ_.js +15 -0
- package/dist/docs/assets/{reference_skills.md.DjQkRefx.lean.js → reference_skills.md.BVmi3UJ_.lean.js} +1 -1
- package/dist/docs/assets/reference_subagents.md.DRoRy2Uj.js +10 -0
- package/dist/docs/assets/{reference_subagents.md.Dl16gcBj.lean.js → reference_subagents.md.DRoRy2Uj.lean.js} +1 -1
- package/dist/docs/assets/{reference_tools.md.B1dH1lpa.js → reference_tools.md.CgocLDX1.js} +9 -6
- package/dist/docs/assets/{reference_tools.md.B1dH1lpa.lean.js → reference_tools.md.CgocLDX1.lean.js} +1 -1
- package/dist/docs/assets/troubleshooting.md.HY95rCCz.js +1 -0
- package/dist/docs/building-with-agents.html +35 -35
- package/dist/docs/deployment.html +37 -37
- package/dist/docs/deployment.md +1 -1
- package/dist/docs/evals.html +35 -35
- package/dist/docs/guides/agent-to-agent.html +38 -38
- package/dist/docs/guides/agent-to-agent.md +11 -12
- package/dist/docs/guides/bitbucket.html +35 -35
- package/dist/docs/guides/cloud-agents.html +36 -36
- package/dist/docs/guides/cloud-agents.md +1 -1
- package/dist/docs/guides/convert-automation.html +35 -35
- package/dist/docs/guides/github.html +35 -35
- package/dist/docs/guides/gitlab.html +35 -35
- package/dist/docs/guides/grokbot-agents.html +37 -37
- package/dist/docs/guides/grokbot-agents.md +1 -1
- package/dist/docs/guides/hooks.html +109 -0
- package/dist/docs/guides/hooks.md +111 -0
- package/dist/docs/guides/improve.html +35 -35
- package/dist/docs/guides/jev.html +42 -80
- package/dist/docs/guides/jev.md +22 -79
- package/dist/docs/guides/mcp-oauth.html +36 -36
- package/dist/docs/guides/opentelemetry.html +35 -35
- 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 +35 -35
- package/dist/docs/llms-full.txt +993 -1303
- package/dist/docs/llms.txt +8 -7
- package/dist/docs/quickstart.html +35 -35
- package/dist/docs/reference/agent-config.html +42 -46
- package/dist/docs/reference/agent-config.md +48 -81
- package/dist/docs/reference/artifacts.html +39 -40
- package/dist/docs/reference/artifacts.md +71 -70
- package/dist/docs/reference/channels.html +41 -61
- package/dist/docs/reference/channels.md +134 -201
- package/dist/docs/reference/cli.html +35 -35
- package/dist/docs/reference/connections.html +54 -66
- package/dist/docs/reference/connections.md +92 -128
- package/dist/docs/reference/evals.html +42 -43
- package/dist/docs/reference/evals.md +42 -50
- package/dist/docs/reference/extensions.html +38 -38
- package/dist/docs/reference/extensions.md +9 -13
- package/dist/docs/reference/hooks.html +39 -67
- package/dist/docs/reference/hooks.md +72 -146
- package/dist/docs/reference/http-api.html +39 -39
- package/dist/docs/reference/http-api.md +137 -161
- package/dist/docs/reference/instructions.html +39 -39
- package/dist/docs/reference/instructions.md +21 -36
- package/dist/docs/reference/playground.html +36 -36
- package/dist/docs/reference/playground.md +26 -43
- package/dist/docs/reference/project-layout.html +38 -38
- package/dist/docs/reference/project-layout.md +12 -17
- package/dist/docs/reference/prompt.html +42 -42
- package/dist/docs/reference/prompt.md +18 -13
- package/dist/docs/reference/schedules.html +56 -91
- package/dist/docs/reference/schedules.md +52 -99
- package/dist/docs/reference/sessions.html +36 -36
- package/dist/docs/reference/sessions.md +36 -40
- package/dist/docs/reference/skills.html +38 -38
- package/dist/docs/reference/skills.md +15 -26
- package/dist/docs/reference/subagents.html +38 -38
- package/dist/docs/reference/subagents.md +20 -30
- package/dist/docs/reference/tools.html +44 -41
- package/dist/docs/reference/tools.md +45 -64
- package/dist/docs/templates/agentic-owners.html +35 -35
- package/dist/docs/templates/pr-autofixer.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/playground/assets/{index-DSMAewbx.css → index-C61EWMBK.css} +1 -1
- package/dist/playground/index.html +2 -2
- package/docs/deployment.md +1 -1
- package/docs/guides/agent-to-agent.md +11 -12
- package/docs/guides/cloud-agents.md +1 -1
- package/docs/guides/grokbot-agents.md +1 -1
- package/docs/guides/hooks.md +116 -0
- package/docs/guides/jev.md +23 -80
- package/docs/reference/agent-config.md +48 -81
- package/docs/reference/artifacts.md +72 -71
- package/docs/reference/channels.md +135 -202
- package/docs/reference/connections.md +93 -129
- package/docs/reference/evals.md +43 -51
- package/docs/reference/extensions.md +9 -13
- package/docs/reference/hooks.md +72 -146
- package/docs/reference/http-api.md +137 -161
- package/docs/reference/instructions.md +22 -37
- package/docs/reference/playground.md +26 -43
- package/docs/reference/project-layout.md +12 -17
- package/docs/reference/prompt.md +20 -15
- package/docs/reference/schedules.md +52 -99
- package/docs/reference/sessions.md +36 -40
- package/docs/reference/skills.md +15 -26
- package/docs/reference/subagents.md +20 -30
- package/docs/reference/tools.md +45 -64
- package/docs/troubleshooting.md +1 -1
- package/package.json +1 -1
- package/dist/docs/assets/chunks/@localSearchIndexroot.Ck9E52Ls.js +0 -1
- package/dist/docs/assets/chunks/channel.BHiYmnZ4.js +0 -1
- package/dist/docs/assets/chunks/classDiagram-6PBFFD2Q.Degh8l90.js +0 -1
- package/dist/docs/assets/chunks/classDiagram-v2-HSJHXN6E.Degh8l90.js +0 -1
- package/dist/docs/assets/chunks/clone.BIywbczV.js +0 -1
- package/dist/docs/assets/chunks/stateDiagram-v2-QKLJ7IA2.qrxrbFsX.js +0 -1
- package/dist/docs/assets/guides_jev.md.F5fAkkfN.lean.js +0 -1
- package/dist/docs/assets/reference_agent-config.md.DGPyw7ms.js +0 -40
- package/dist/docs/assets/reference_artifacts.md.Bu_4HmsD.js +0 -19
- package/dist/docs/assets/reference_artifacts.md.Bu_4HmsD.lean.js +0 -1
- package/dist/docs/assets/reference_channels.md.nFWbzAic.js +0 -43
- package/dist/docs/assets/reference_channels.md.nFWbzAic.lean.js +0 -1
- package/dist/docs/assets/reference_evals.md.DNJzM_yf.lean.js +0 -1
- package/dist/docs/assets/reference_hooks.md.B7uzNENk.js +0 -73
- package/dist/docs/assets/reference_http-api.md.CduHavZ2.js +0 -11
- package/dist/docs/assets/reference_instructions.md.CU1My5My.js +0 -14
- package/dist/docs/assets/reference_instructions.md.CU1My5My.lean.js +0 -1
- package/dist/docs/assets/reference_playground.md.Ch2d0Iqi.js +0 -1
- package/dist/docs/assets/reference_playground.md.Ch2d0Iqi.lean.js +0 -1
- package/dist/docs/assets/reference_project-layout.md.BGhgpy9V.js +0 -19
- package/dist/docs/assets/reference_prompt.md.Ccp0R53H.js +0 -1
- package/dist/docs/assets/reference_prompt.md.Ccp0R53H.lean.js +0 -1
- package/dist/docs/assets/reference_schedules.md.B2Nm6FaD.js +0 -82
- package/dist/docs/assets/reference_schedules.md.B2Nm6FaD.lean.js +0 -1
- package/dist/docs/assets/reference_sessions.md.1_6Vyv7x.js +0 -1
- package/dist/docs/assets/reference_skills.md.DjQkRefx.js +0 -15
- package/dist/docs/assets/reference_subagents.md.Dl16gcBj.js +0 -10
- package/dist/docs/assets/troubleshooting.md.mnfFG2Em.js +0 -1
- /package/dist/docs/assets/{deployment.md.D2jQZuFx.lean.js → deployment.md.D2YX7u_I.lean.js} +0 -0
- /package/dist/docs/assets/{guides_agent-to-agent.md.CD4T5FIl.lean.js → guides_agent-to-agent.md.C6kPY8nu.lean.js} +0 -0
- /package/dist/docs/assets/{guides_cloud-agents.md.Cp1O3u-X.lean.js → guides_cloud-agents.md.BPJqTZjT.lean.js} +0 -0
- /package/dist/docs/assets/{guides_grokbot-agents.md.CMhZNdEU.lean.js → guides_grokbot-agents.md.CzV715v8.lean.js} +0 -0
- /package/dist/docs/assets/{troubleshooting.md.mnfFG2Em.lean.js → troubleshooting.md.HY95rCCz.lean.js} +0 -0
- /package/dist/playground/assets/{index-De_lpFxE.js → index-CrMWlgUU.js} +0 -0
|
@@ -1,17 +1,16 @@
|
|
|
1
1
|
---
|
|
2
2
|
title: "Artifacts"
|
|
3
|
-
description: "
|
|
3
|
+
description: "Declare, tag, list, stream, and download durable agent outputs."
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
# Artifacts
|
|
7
7
|
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
artifacts
|
|
11
|
-
|
|
12
|
-
streams.
|
|
8
|
+
Artifacts are durable outputs such as reviewed pull requests, reports,
|
|
9
|
+
or decision records. An artifact kind defines the data it accepts, and
|
|
10
|
+
the artifacts API tags or updates records by key. Records persist across
|
|
11
|
+
sessions and can be listed, streamed, or downloaded.
|
|
13
12
|
|
|
14
|
-
##
|
|
13
|
+
## Artifact kinds
|
|
15
14
|
|
|
16
15
|
Author `agent/artifacts.ts` with `defineArtifacts` from
|
|
17
16
|
`@cursor/july/artifacts`:
|
|
@@ -32,26 +31,21 @@ export default defineArtifacts({
|
|
|
32
31
|
});
|
|
33
32
|
```
|
|
34
33
|
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
## Tag from host code
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
an `ArtifactsApi` with `tag` and `list
|
|
50
|
-
handlers and `onStart`, schedule `run` handlers, and reminder `run`
|
|
51
|
-
handlers. Tool and hook facades are session-bound, so `tag` auto-fills
|
|
52
|
-
the `sessionId` (and `turnId` when known). Channel, schedule, and
|
|
53
|
-
reminder facades are unbound; pass `sessionId` in the tag input to
|
|
54
|
-
attribute one.
|
|
34
|
+
| Option | Contract |
|
|
35
|
+
| --- | --- |
|
|
36
|
+
| `kinds` | Map of accepted kind names to a non-empty `description` and optional Zod `schema` |
|
|
37
|
+
| `agentTool` | Expose `tag_artifact` to the model; requires at least one declared kind |
|
|
38
|
+
| `max` | Positive retention cap; defaults to `1000` and evicts the oldest-updated record |
|
|
39
|
+
|
|
40
|
+
With declared kinds, `tag` rejects any other kind. With no registry, it
|
|
41
|
+
accepts free-form kind names and defaults an omitted kind to
|
|
42
|
+
`"artifact"`. A kind's schema validates `data`, and the parsed value is
|
|
43
|
+
stored, including schema defaults and coercions.
|
|
44
|
+
|
|
45
|
+
## Tag artifacts from host code
|
|
46
|
+
|
|
47
|
+
Tools, hooks, channel handlers, channel `onStart`, schedules, and
|
|
48
|
+
reminders receive an `ArtifactsApi` with `tag` and `list`.
|
|
55
49
|
|
|
56
50
|
```ts
|
|
57
51
|
await ctx.artifacts.tag({
|
|
@@ -62,56 +56,63 @@ await ctx.artifacts.tag({
|
|
|
62
56
|
});
|
|
63
57
|
```
|
|
64
58
|
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
`
|
|
69
|
-
`
|
|
70
|
-
`
|
|
71
|
-
|
|
72
|
-
|
|
59
|
+
| Tag field | Contract |
|
|
60
|
+
| --- | --- |
|
|
61
|
+
| `data` | Required JSON data, validated when the kind has a schema |
|
|
62
|
+
| `kind` | Declared or free-form kind |
|
|
63
|
+
| `key` | Agent-wide upsert key; the same key updates one record across kinds |
|
|
64
|
+
| `title` | Optional display title |
|
|
65
|
+
| `contents` | String or bytes served by the content route |
|
|
66
|
+
| `contentType` | MIME type for `contents` |
|
|
67
|
+
| `sessionId`, `turnId` | Attribute the artifact to a session or turn |
|
|
68
|
+
| `source` | `"host"` or `"model"`; defaults to `"host"` |
|
|
69
|
+
|
|
70
|
+
Tool, hook, result, and channel-event contexts are session-bound, so
|
|
71
|
+
they fill `sessionId` and the current `turnId`. Channel routes,
|
|
72
|
+
`onStart`, schedules, and reminders receive an unbound facade; pass
|
|
73
|
+
`sessionId` to attribute an artifact.
|
|
74
|
+
|
|
75
|
+
Re-tagging a key without `contents` keeps its file or blob when the
|
|
76
|
+
`sessionId` stays the same. Rebinding the key to another session without
|
|
77
|
+
new contents removes the previous payload. `tag` returns the stored
|
|
78
|
+
`ArtifactRecord`.
|
|
79
|
+
|
|
80
|
+
| Record field | Contract |
|
|
81
|
+
| --- | --- |
|
|
82
|
+
| `id` | Stable ID derived from `key`, or a generated ID when no key is set |
|
|
83
|
+
| `kind`, `data` | Validated kind and JSON payload |
|
|
84
|
+
| `key`, `title` | Optional upsert key and display title |
|
|
85
|
+
| `content` | Optional `{ size, contentType? }` metadata |
|
|
86
|
+
| `sessionId`, `turnId` | Optional session attribution |
|
|
87
|
+
| `source` | `"host"` or `"model"` |
|
|
88
|
+
| `createdAt`, `updatedAt` | ISO-8601 timestamps |
|
|
89
|
+
|
|
90
|
+
## Expose `tag_artifact` to the model
|
|
73
91
|
|
|
74
92
|
With `agentTool: true`, the `tag_artifact` server tool materializes from
|
|
75
|
-
the kinds registry. Its
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
validated exactly like a host-side tag. An authored tool named
|
|
79
|
-
`tag_artifact` shadows the built-in, with a warning.
|
|
80
|
-
|
|
81
|
-
## Observe and list
|
|
93
|
+
the kinds registry. Its input accepts the declared kinds and validates
|
|
94
|
+
their data with the same schemas as host-side tagging. The kind
|
|
95
|
+
descriptions tell the model which output each one represents.
|
|
82
96
|
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
`source` (`"host"` for host code, `"model"` for `tag_artifact`). Hooks,
|
|
86
|
-
channel `events`, and evals see it like any other
|
|
87
|
-
[stream event](./sessions.md#which-events-can-i-stream).
|
|
97
|
+
An authored tool named `tag_artifact` takes precedence over the generated
|
|
98
|
+
tool.
|
|
88
99
|
|
|
89
|
-
|
|
100
|
+
## List artifacts
|
|
90
101
|
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
```
|
|
102
|
+
`list({ kind?, sessionId? })` returns matching records newest-updated
|
|
103
|
+
first. HTTP callers can list records and download content through the
|
|
104
|
+
[artifact routes](./http-api.md#list-and-download-artifacts).
|
|
95
105
|
|
|
96
|
-
|
|
97
|
-
`kind` and `sessionId`. Session ownership applies, same as
|
|
98
|
-
`/v1/sessions`. The playground renders tagged artifacts too.
|
|
99
|
-
|
|
100
|
-
## Gate evals on tagging
|
|
101
|
-
|
|
102
|
-
`t.taggedArtifact(kind?, predicate?)` gates an eval on at least one
|
|
103
|
-
artifact tagged during the test turn, optionally of one kind and
|
|
104
|
-
matching a predicate over the record:
|
|
105
|
-
|
|
106
|
-
```ts
|
|
107
|
-
t.taggedArtifact("reviewed-pr", (record) => record.source === "model");
|
|
108
|
-
```
|
|
106
|
+
## Stream artifact tags
|
|
109
107
|
|
|
110
|
-
|
|
108
|
+
Tagging an artifact with a `sessionId` emits `artifact.tagged` on that
|
|
109
|
+
session. Its event data contains `id`, `kind`, `key`, `title`, `data`,
|
|
110
|
+
and `source`. See [Stream events](./sessions.md#stream-events) for the
|
|
111
|
+
event envelope.
|
|
111
112
|
|
|
112
|
-
|
|
113
|
+
## Related
|
|
113
114
|
|
|
114
|
-
- [Sessions
|
|
115
|
-
|
|
116
|
-
- [
|
|
117
|
-
- [
|
|
115
|
+
- [Sessions](./sessions.md)
|
|
116
|
+
- [Tools](./tools.md)
|
|
117
|
+
- [Evals](./evals.md)
|
|
118
|
+
- [HTTP API](./http-api.md)
|
|
@@ -1,28 +1,25 @@
|
|
|
1
1
|
---
|
|
2
2
|
title: "Channels"
|
|
3
|
-
description: "
|
|
3
|
+
description: "Define custom channel routes, schemas, state, events, and authentication."
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
# Channels
|
|
7
7
|
|
|
8
|
-
A channel
|
|
9
|
-
|
|
10
|
-
under `/v1/channels/<id>`. The
|
|
11
|
-
|
|
12
|
-
hosted and self-managed products. This page is the authoring reference;
|
|
13
|
-
for the walkthrough, see the [Webhooks guide](../guides/webhooks.md).
|
|
8
|
+
A channel connects an external surface to agent sessions. A file at
|
|
9
|
+
`agent/channels/<id>.ts` defines channel `<id>` and mounts its routes
|
|
10
|
+
under `/v1/channels/<id>`. The built-in HTTP session channel is always
|
|
11
|
+
available alongside any custom or prebuilt channels.
|
|
14
12
|
|
|
15
13
|
## Built-in HTTP channel
|
|
16
14
|
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
15
|
+
The built-in channel serves the session, approval, tool, discovery, and
|
|
16
|
+
health routes. In a multi-agent host, each agent's routes sit under its
|
|
17
|
+
slug. See the [HTTP API](./http-api.md) for request and response
|
|
18
|
+
contracts.
|
|
21
19
|
|
|
22
20
|
## Define a custom channel
|
|
23
21
|
|
|
24
|
-
|
|
25
|
-
route prefix:
|
|
22
|
+
Use `defineChannel` with one or more typed routes:
|
|
26
23
|
|
|
27
24
|
```ts
|
|
28
25
|
import { defineChannel, POST } from "@cursor/july/channels";
|
|
@@ -35,234 +32,170 @@ export default defineChannel({
|
|
|
35
32
|
bodySchema: z.object({
|
|
36
33
|
message: z.string(),
|
|
37
34
|
prUrl: z.string().url(),
|
|
38
|
-
thread: z.string().optional(),
|
|
39
35
|
}),
|
|
40
|
-
handler: async (
|
|
41
|
-
const prepared = await callTool("inspect_pr", {
|
|
42
|
-
prUrl: body.prUrl,
|
|
43
|
-
});
|
|
44
|
-
if (prepared.isError) {
|
|
45
|
-
return Response.json(
|
|
46
|
-
{ error: prepared.errorMessage ?? "Could not inspect pull request" },
|
|
47
|
-
{ status: 502 }
|
|
48
|
-
);
|
|
49
|
-
}
|
|
50
|
-
|
|
36
|
+
handler: async (_request, { send, body }) => {
|
|
51
37
|
const session = await send(
|
|
52
|
-
`${body.message}\n\
|
|
38
|
+
`${body.message}\n\nPull request: ${body.prUrl}`,
|
|
53
39
|
{
|
|
54
|
-
continuationToken:
|
|
55
|
-
workspaceFiles: {
|
|
56
|
-
"pr.json": JSON.stringify(prepared.result, null, 2) ?? "null",
|
|
57
|
-
},
|
|
40
|
+
continuationToken: `pr:${body.prUrl}`,
|
|
58
41
|
}
|
|
59
42
|
);
|
|
60
43
|
return Response.json({ sessionId: session.id });
|
|
61
44
|
},
|
|
62
45
|
}),
|
|
63
46
|
],
|
|
64
|
-
events: {
|
|
65
|
-
"message.completed"(event, channel, ctx) {
|
|
66
|
-
// deliver the reply to the surface that owns this channel
|
|
67
|
-
},
|
|
68
|
-
},
|
|
69
|
-
// auth: [...], state: {...}, onStart(...), onStop(...)
|
|
70
47
|
});
|
|
71
48
|
```
|
|
72
49
|
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
writes the tool result to `pr.json`. Instructions can ask the model to
|
|
77
|
-
inspect a PR, but host code guarantees it.
|
|
50
|
+
The route above is
|
|
51
|
+
`POST /v1/channels/<id>/review`. Calls for the same pull request reuse
|
|
52
|
+
one conversation because they pass the same continuation token.
|
|
78
53
|
|
|
79
54
|
## Route verbs and schemas
|
|
80
55
|
|
|
81
|
-
|
|
82
|
-
schemas
|
|
56
|
+
Route paths must begin with `/`. The method helper determines which Zod
|
|
57
|
+
schemas the route accepts:
|
|
83
58
|
|
|
84
|
-
|
|
|
85
|
-
|
|
|
86
|
-
| `GET`
|
|
87
|
-
| `POST
|
|
88
|
-
| `DELETE`
|
|
59
|
+
| Helper | Schema contract |
|
|
60
|
+
| --- | --- |
|
|
61
|
+
| `GET` | `querySchema` is required |
|
|
62
|
+
| `POST`, `PUT`, `PATCH` | `bodySchema` is required; `querySchema` is optional |
|
|
63
|
+
| `DELETE` | Both schemas are optional |
|
|
89
64
|
|
|
90
|
-
Plain JSON Schema objects
|
|
91
|
-
`z.unknown()` for
|
|
92
|
-
the handler
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
buttons and composer **slash commands**.
|
|
65
|
+
Plain JSON Schema objects don't type-check. Use `z.object({})` or
|
|
66
|
+
`z.unknown()` for an open surface. The host validates the body and query
|
|
67
|
+
before calling the handler, returning `400` on failure; an empty body is
|
|
68
|
+
read as `{}`. Declared schemas also appear in `GET /v1/info` for
|
|
69
|
+
playground requests and slash commands.
|
|
96
70
|
|
|
97
71
|
## Handler arguments
|
|
98
72
|
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
| Member
|
|
102
|
-
|
|
|
103
|
-
| `send(message, options?)`
|
|
104
|
-
| `getSession(sessionId)`
|
|
105
|
-
| `receive(
|
|
106
|
-
| `callTool(name, input, options?)`
|
|
107
|
-
| `body`, `query`, `params`
|
|
108
|
-
| `auth`
|
|
109
|
-
| `requestIp`
|
|
110
|
-
| `host`
|
|
111
|
-
| `waitUntil(promise)`
|
|
112
|
-
| `sessionUrls(request, sessionId)`
|
|
113
|
-
| `artifacts`
|
|
114
|
-
|
|
115
|
-
`send` options
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
73
|
+
Each handler receives the Fetch `Request` and a typed arguments object.
|
|
74
|
+
|
|
75
|
+
| Member | Contract |
|
|
76
|
+
| --- | --- |
|
|
77
|
+
| `send(message, options?)` | Start or resume a session on this channel |
|
|
78
|
+
| `getSession(sessionId)` | Return this channel's session, or `null` |
|
|
79
|
+
| `receive(channel, input)` | Hand work to another channel |
|
|
80
|
+
| `callTool(name, input, options?)` | [Call a server tool](./tools.md#call-a-tool-without-a-model-turn) without a model turn |
|
|
81
|
+
| `body`, `query`, `params` | Validated inputs and `:param` path segments |
|
|
82
|
+
| `auth` | The `AuthContext` returned by the route's auth chain |
|
|
83
|
+
| `requestIp` | The TCP peer address, or `null` |
|
|
84
|
+
| `host` | Shared MCP, provider, storage, telemetry, and reminder services |
|
|
85
|
+
| `waitUntil(promise)` | Track work after the response returns |
|
|
86
|
+
| `sessionUrls(request, sessionId)` | Build absolute playground and trace URLs for this mount |
|
|
87
|
+
| `artifacts` | List or tag [artifacts](./artifacts.md); pass `sessionId` when attributing one |
|
|
88
|
+
|
|
89
|
+
### `send` options
|
|
90
|
+
|
|
91
|
+
| Option | Contract |
|
|
92
|
+
| --- | --- |
|
|
93
|
+
| `continuationToken` | Resume the session with this channel-local key, or create one when the key is new |
|
|
94
|
+
| `admission` | `"preempt"` interrupts a busy turn; `"coalesce"` queues behind it. The default is `"preempt"` |
|
|
95
|
+
| `workspaceFiles` | Add relative files for the next turn |
|
|
96
|
+
| `workspaceDir` | Use an absolute local working directory |
|
|
97
|
+
| `cloud` | Override cloud session options when creating a session |
|
|
98
|
+
| `auth` | Set the session principal; defaults to the request principal |
|
|
99
|
+
| `state` | Set starting channel state for a new session |
|
|
100
|
+
| `title` | Set the display title for a new session |
|
|
101
|
+
| `purpose` | Use `"eval"` to mark a new session as regression traffic |
|
|
102
|
+
| `dryRun` | Run read tools and stub write tools for a new session |
|
|
103
|
+
| `asOf` | Freeze a new session at an ISO-8601 instant with a timezone |
|
|
104
|
+
|
|
105
|
+
`send` returns a `ChannelSession`. Its `id` identifies the session,
|
|
106
|
+
`continuationToken` contains its current channel key, and `isNew` says
|
|
107
|
+
whether this call created it. A coalesced call also returns
|
|
108
|
+
`coalesced: true`.
|
|
123
109
|
|
|
124
110
|
## Events
|
|
125
111
|
|
|
126
112
|
The `events` map subscribes the channel to stream events for the
|
|
127
113
|
sessions it owns. Keys are event types from the
|
|
128
|
-
[event vocabulary](./sessions.md#
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
replies back to its surface.
|
|
134
|
-
|
|
135
|
-
## State and lifecycle
|
|
136
|
-
|
|
137
|
-
`state` declares the starting per-session adapter state (JSON), persisted
|
|
138
|
-
on the session record. Routes and event handlers read and mutate it
|
|
139
|
-
through `channel.state`. `onStart(args)` runs when the channel mounts.
|
|
140
|
-
`onStop()` runs when the server stops.
|
|
141
|
-
|
|
142
|
-
`onStart` receives the route helpers (`send`, `getSession`, `receive`,
|
|
143
|
-
`callTool`, `host`, `waitUntil`, `artifacts`, `logger`) plus helpers
|
|
144
|
-
for long-lived transports:
|
|
145
|
-
|
|
146
|
-
- `emitAssistantMessage(sessionId, text)` appends an assistant message
|
|
147
|
-
without a model turn, for host tasks that already produced the final
|
|
148
|
-
text.
|
|
149
|
-
- `hasContinuationSession(token)` and `isContinuationBusy(token)`
|
|
150
|
-
report whether a continuation token has a live session and whether a
|
|
151
|
-
turn is in flight on it.
|
|
152
|
-
- `interruptContinuation(token)` stops the in-flight turn and clears
|
|
153
|
-
coalesced follow-ups queued behind it.
|
|
154
|
-
- `resolveApproval(sessionId, callId, decision, auth, options?)`
|
|
155
|
-
approves or denies a parked tool call, how Slack Block Kit buttons
|
|
156
|
-
unblock a turn without the HTTP approvals route.
|
|
114
|
+
[event vocabulary](./sessions.md#stream-events), or `"*"`. Each handler
|
|
115
|
+
receives `(event, channel, ctx)`, including the session's
|
|
116
|
+
`channel.state`, session info, and shared host services. Use these
|
|
117
|
+
handlers to deliver progress and replies to the surface that owns the
|
|
118
|
+
channel.
|
|
157
119
|
|
|
158
|
-
##
|
|
120
|
+
## Session state
|
|
121
|
+
|
|
122
|
+
`state` on the channel definition supplies starting JSON for each new
|
|
123
|
+
session. A route can instead pass `state` to `send`; event handlers read
|
|
124
|
+
and update the active value through `channel.state`.
|
|
159
125
|
|
|
160
|
-
|
|
161
|
-
`[localDevStrict()]` when unset. A policy is a function
|
|
162
|
-
`(request, info) => AuthContext | null` (async allowed); the first
|
|
163
|
-
non-null wins, and a request no policy admits gets `401`.
|
|
126
|
+
## Start and stop a channel
|
|
164
127
|
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
| `localDev()` | Like `localDevStrict()` but without the `Host` check. An explicit, weaker opt-in. |
|
|
169
|
-
| `loopbackOnly()` | A loopback TCP peer, ignoring forwarding headers; for dev relays that legitimately carry them, like `gh webhook forward`. |
|
|
170
|
-
| `bearerAuth(token)` | `Authorization: Bearer <token>`, compared in constant time. Also accepts a verifier function mapping a presented token to an `AuthContext`. |
|
|
171
|
-
| `allowAll()` | Everyone, as an `anonymous` principal. Only for surfaces protected upstream (an HMAC-verified webhook) or intentionally public. |
|
|
172
|
-
| `publicEndpoint()` | Everyone on this custom channel. Managed hosting also serves the channel without an alias token. Use it only when the handler verifies the provider signature. |
|
|
128
|
+
`onStart(args)` runs when the channel mounts, and `onStop()` runs when
|
|
129
|
+
the host stops. `onStart` receives the route helpers plus these
|
|
130
|
+
transport controls:
|
|
173
131
|
|
|
174
|
-
|
|
175
|
-
|
|
132
|
+
| Helper | Contract |
|
|
133
|
+
| --- | --- |
|
|
134
|
+
| `emitAssistantMessage(sessionId, text)` | Append final assistant text without starting a model turn |
|
|
135
|
+
| `hasContinuationSession(token)` | Check whether a token maps to a session |
|
|
136
|
+
| `isContinuationBusy(token)` | Check whether a turn is active for a token |
|
|
137
|
+
| `interruptContinuation(token)` | Stop the active turn and clear queued coalesced follow-ups |
|
|
138
|
+
| `resolveApproval(...)` | Approve or deny a parked tool call |
|
|
139
|
+
|
|
140
|
+
## Auth policies
|
|
141
|
+
|
|
142
|
+
Every route runs the channel's `auth` array. The default is
|
|
143
|
+
`[localDevStrict()]`. Policies may be asynchronous; the first one to
|
|
144
|
+
return an `AuthContext` admits the request, and an all-null result
|
|
145
|
+
returns `401`.
|
|
146
|
+
|
|
147
|
+
| Policy | Admits |
|
|
148
|
+
| --- | --- |
|
|
149
|
+
| `localDevStrict()` | Direct loopback requests with a loopback hostname and no proxy-forwarding headers |
|
|
150
|
+
| `localDev()` | Direct loopback requests with no proxy-forwarding headers, without checking the hostname |
|
|
151
|
+
| `loopbackOnly()` | Any loopback TCP peer, including local relays that carry forwarding headers |
|
|
152
|
+
| `bearerAuth(tokenOrVerify)` | A matching bearer token, or a token accepted by the verifier |
|
|
153
|
+
| `sharedSecretAuth({ header, secret })` | A header matching the named environment or deployment secret |
|
|
154
|
+
| `hmacSignatureAuth({ header, secret, prefix? })` | A hex HMAC-SHA256 signature over the raw body using the named secret |
|
|
155
|
+
| `allowAll()` | Every caller as an anonymous principal |
|
|
156
|
+
| `publicEndpoint()` | Every caller on this custom channel; managed hosting also exposes the route without an alias token |
|
|
157
|
+
|
|
158
|
+
Use `allowAll()` only for an intentionally public surface or one
|
|
159
|
+
protected upstream. With `publicEndpoint()`, the handler must verify the
|
|
160
|
+
provider's signature. The policy applies only to custom channel routes;
|
|
161
|
+
it doesn't open the built-in session or tool API.
|
|
176
162
|
|
|
177
163
|
The resolved `AuthContext` (`{ authenticator, principalId,
|
|
178
164
|
principalType, attributes? }`) becomes the request principal. Sessions
|
|
179
|
-
|
|
180
|
-
|
|
165
|
+
belong to the principal that created them, and other principals receive
|
|
166
|
+
`403` on owned routes.
|
|
181
167
|
|
|
182
168
|
Server flags interact with authored auth: `--bearer-token` swaps the
|
|
183
169
|
default `localDevStrict()` for `bearerAuth(...)` on channels that don't
|
|
184
170
|
author their own chain, and `--allow-anonymous` swaps it for
|
|
185
|
-
`allowAll()`.
|
|
186
|
-
declares `[localDevStrict()]` stays loopback-only even on an
|
|
187
|
-
`--allow-anonymous` host.
|
|
188
|
-
|
|
189
|
-
## First class channels
|
|
190
|
-
|
|
191
|
-
**Slack** (`@cursor/july/channels/slack`): Socket Mode
|
|
192
|
-
transport, streaming replies, engagement rules, approval cards, and a
|
|
193
|
-
default block on Slack Connect / guest / other-workspace senders. Author
|
|
194
|
-
`agent/channels/slack.ts` with `slackChannel()`. Guide:
|
|
195
|
-
[Slack](../guides/slack.md).
|
|
196
|
-
|
|
197
|
-
**GitHub** (`@cursor/july/channels/github`): webhook dispatch
|
|
198
|
-
with signature verification, per-event hooks returning `{ auth }` (a
|
|
199
|
-
model turn), `{ task }` (host work), or `null`, and CLI tooling for
|
|
200
|
-
replay and live forwarding. Author `agent/channels/github.ts` with
|
|
201
|
-
`githubChannel()`. Opt-in `progress.commitStatus` and `progress.banner`
|
|
202
|
-
converge a merge-box check and sticky PR comment from default stream
|
|
203
|
-
events. Supports GitHub.com and GitHub Enterprise Server. Guide:
|
|
204
|
-
[GitHub](../guides/github.md).
|
|
205
|
-
|
|
206
|
-
**GitLab** (`@cursor/july/channels/gitlab`): verified project hooks for
|
|
207
|
-
merge requests, notes, pipelines, pushes, and custom event types. Supports
|
|
208
|
-
GitLab.com and self-managed GitLab. Author `agent/channels/gitlab.ts` with
|
|
209
|
-
`gitlabChannel()`. Guide: [GitLab](../guides/gitlab.md).
|
|
210
|
-
|
|
211
|
-
**Bitbucket** (`@cursor/july/channels/bitbucket`): verified repository hooks
|
|
212
|
-
for pull requests, comments, pushes, and custom event types. Supports
|
|
213
|
-
Bitbucket Cloud and Bitbucket Data Center through one normalized hook API.
|
|
214
|
-
Author `agent/channels/bitbucket.ts` with `bitbucketChannel()`. Guide:
|
|
215
|
-
[Bitbucket](../guides/bitbucket.md).
|
|
216
|
-
|
|
217
|
-
**Deployments** (`@cursor/july/channels/deployments`): pull deploy
|
|
218
|
-
events. Declare `events` and handle each one in `onEvent`. Each event
|
|
219
|
-
carries `deploySourceUri` and `deployVersion`. Author
|
|
220
|
-
`agent/channels/deployments.ts` with `deploymentsChannel()`.
|
|
221
|
-
|
|
222
|
-
On Cursor-managed hosting, omit `deploySourceUris`. The deployment's
|
|
223
|
-
watched repositories bind the event scope automatically. Name sources
|
|
224
|
-
to narrow the scope or to drive the self-hosted pull relay. Subscribe
|
|
225
|
-
per deploy source with `deploySourceUris` and narrow with `environments`
|
|
226
|
-
or `events`. Each entry must match `Deployment.deploy_source_uri` as
|
|
227
|
-
your deployment writer records it. Matching is case-insensitive but
|
|
228
|
-
otherwise literal. It uses the host credential. A restart resumes
|
|
229
|
-
rather than dropping events. An empty `deploySourceUris` list mounts the
|
|
230
|
-
channel but starts no pull, so an env-configured agent stays inert until
|
|
231
|
-
its deploy sources are set.
|
|
232
|
-
|
|
233
|
-
**Change Monitors** (`@cursor/july/channels/change-monitors`): Change
|
|
234
|
-
Monitor Checkpoint events. The channel publishes Factory
|
|
235
|
-
`checkpoint.created` for every Checkpoint create. The agent filters the
|
|
236
|
-
result (for example to the `issues` arm). The payload contains the
|
|
237
|
-
full Checkpoint resource. This channel is scoped to Change Monitors,
|
|
238
|
-
not generic Factory Checkpoints. There is no repository filter or
|
|
239
|
-
resource filter. Author `agent/channels/change-monitors.ts` with
|
|
240
|
-
`changeMonitorsChannel()`. It uses the host credential.
|
|
241
|
-
|
|
242
|
-
**Issues** (`@cursor/july/channels/issues`): Factory issue events.
|
|
243
|
-
The channel publishes `issue.created` for every Issue create. The
|
|
244
|
-
agent filters if it needs a subset. The payload contains the full
|
|
245
|
-
Issue resource. There is no repository filter or resource filter.
|
|
246
|
-
Author `agent/channels/issues.ts` with `issuesChannel()`. It uses the
|
|
247
|
-
host credential.
|
|
171
|
+
`allowAll()`. An authored `auth` array always takes precedence.
|
|
248
172
|
|
|
249
|
-
|
|
250
|
-
`defineChannel` webhook form.
|
|
173
|
+
## Prebuilt channels
|
|
251
174
|
|
|
252
|
-
|
|
175
|
+
| Import | Factory | Surface |
|
|
176
|
+
| --- | --- | --- |
|
|
177
|
+
| `@cursor/july/channels/slack` | `slackChannel()` | Slack messages, threads, streaming replies, and approvals. See [Slack](../guides/slack.md) |
|
|
178
|
+
| `@cursor/july/channels/github` | `githubChannel()` | GitHub and GitHub Enterprise webhooks. See [GitHub](../guides/github.md) |
|
|
179
|
+
| `@cursor/july/channels/gitlab` | `gitlabChannel()` | GitLab.com and self-managed GitLab hooks. See [GitLab](../guides/gitlab.md) |
|
|
180
|
+
| `@cursor/july/channels/bitbucket` | `bitbucketChannel()` | Bitbucket Cloud and Data Center hooks. See [Bitbucket](../guides/bitbucket.md) |
|
|
181
|
+
| `@cursor/july/channels/deployments` | `deploymentsChannel()` | Deployment events filtered by source, environment, or event name |
|
|
182
|
+
| `@cursor/july/channels/change-monitors` | `changeMonitorsChannel()` | Change Monitor `checkpoint.created` events |
|
|
183
|
+
| `@cursor/july/channels/issues` | `issuesChannel()` | Factory `issue.created` events |
|
|
184
|
+
|
|
185
|
+
For other platforms like Discord or Teams, use the authored
|
|
186
|
+
`defineChannel` route form.
|
|
253
187
|
|
|
254
|
-
|
|
255
|
-
mints opaque rotating tokens, Slack uses `channelId:threadTs`, and PR
|
|
256
|
-
automations use keys like `pr:owner/repo#N`. Same token, same durable
|
|
257
|
-
session; one active continuation per session; the HTTP channel returns
|
|
258
|
-
`409` for stale tokens. For the full session model, see
|
|
259
|
-
[Sessions](./sessions.md).
|
|
188
|
+
## Continuation tokens
|
|
260
189
|
|
|
261
|
-
|
|
190
|
+
Each channel defines its continuation-token format. The same token
|
|
191
|
+
resumes the same conversation; the built-in HTTP channel rotates its
|
|
192
|
+
opaque token after every accepted follow-up and returns `409` for a
|
|
193
|
+
stale token. See [Session identifiers](./sessions.md#session-identifiers)
|
|
194
|
+
for the full contract.
|
|
262
195
|
|
|
263
|
-
|
|
196
|
+
## Related
|
|
264
197
|
|
|
265
|
-
- [Webhooks
|
|
266
|
-
- [HTTP API](./http-api.md)
|
|
267
|
-
- [Sessions
|
|
268
|
-
|
|
198
|
+
- [Webhooks](../guides/webhooks.md)
|
|
199
|
+
- [HTTP API](./http-api.md)
|
|
200
|
+
- [Sessions](./sessions.md)
|
|
201
|
+
- [Hooks](./hooks.md)
|