@agentteams/cli 0.1.22

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.
Files changed (200) hide show
  1. package/.agentteams/config.json +8 -0
  2. package/.agentteams/convention.md +100 -0
  3. package/.agentteams/platform/co-action-guide.md +144 -0
  4. package/.agentteams/platform/completion-report-guide.md +146 -0
  5. package/.agentteams/platform/convention-authoring-guide.md +112 -0
  6. package/.agentteams/platform/convention-ud-guide.md +59 -0
  7. package/.agentteams/platform/plan-guide.md +180 -0
  8. package/.agentteams/platform/plan-template.md +201 -0
  9. package/.agentteams/platform/post-mortem-guide.md +92 -0
  10. package/CODE_OF_CONDUCT.md +36 -0
  11. package/CONTRIBUTING.md +39 -0
  12. package/LICENSE +201 -0
  13. package/README.md +405 -0
  14. package/SECURITY.md +27 -0
  15. package/dist/api/coaction.d.ts +17 -0
  16. package/dist/api/coaction.d.ts.map +1 -0
  17. package/dist/api/coaction.js +102 -0
  18. package/dist/api/coaction.js.map +1 -0
  19. package/dist/api/comment.d.ts +13 -0
  20. package/dist/api/comment.d.ts.map +1 -0
  21. package/dist/api/comment.js +33 -0
  22. package/dist/api/comment.js.map +1 -0
  23. package/dist/api/feedback.d.ts +7 -0
  24. package/dist/api/feedback.d.ts.map +1 -0
  25. package/dist/api/feedback.js +6 -0
  26. package/dist/api/feedback.js.map +1 -0
  27. package/dist/api/linear.d.ts +5 -0
  28. package/dist/api/linear.d.ts.map +1 -0
  29. package/dist/api/linear.js +27 -0
  30. package/dist/api/linear.js.map +1 -0
  31. package/dist/api/member.d.ts +16 -0
  32. package/dist/api/member.d.ts.map +1 -0
  33. package/dist/api/member.js +6 -0
  34. package/dist/api/member.js.map +1 -0
  35. package/dist/api/plan.d.ts +51 -0
  36. package/dist/api/plan.d.ts.map +1 -0
  37. package/dist/api/plan.js +80 -0
  38. package/dist/api/plan.js.map +1 -0
  39. package/dist/api/postmortem.d.ts +6 -0
  40. package/dist/api/postmortem.d.ts.map +1 -0
  41. package/dist/api/postmortem.js +33 -0
  42. package/dist/api/postmortem.js.map +1 -0
  43. package/dist/api/report.d.ts +6 -0
  44. package/dist/api/report.d.ts.map +1 -0
  45. package/dist/api/report.js +33 -0
  46. package/dist/api/report.js.map +1 -0
  47. package/dist/api/search.d.ts +2 -0
  48. package/dist/api/search.d.ts.map +1 -0
  49. package/dist/api/search.js +20 -0
  50. package/dist/api/search.js.map +1 -0
  51. package/dist/api/status.d.ts +12 -0
  52. package/dist/api/status.d.ts.map +1 -0
  53. package/dist/api/status.js +33 -0
  54. package/dist/api/status.js.map +1 -0
  55. package/dist/commands/agentConfig.d.ts +4 -0
  56. package/dist/commands/agentConfig.d.ts.map +1 -0
  57. package/dist/commands/agentConfig.js +41 -0
  58. package/dist/commands/agentConfig.js.map +1 -0
  59. package/dist/commands/agentConfigCommand.d.ts +2 -0
  60. package/dist/commands/agentConfigCommand.d.ts.map +1 -0
  61. package/dist/commands/agentConfigCommand.js +20 -0
  62. package/dist/commands/agentConfigCommand.js.map +1 -0
  63. package/dist/commands/coaction.d.ts +2 -0
  64. package/dist/commands/coaction.d.ts.map +1 -0
  65. package/dist/commands/coaction.js +405 -0
  66. package/dist/commands/coaction.js.map +1 -0
  67. package/dist/commands/comment.d.ts +2 -0
  68. package/dist/commands/comment.d.ts.map +1 -0
  69. package/dist/commands/comment.js +63 -0
  70. package/dist/commands/comment.js.map +1 -0
  71. package/dist/commands/config.d.ts +2 -0
  72. package/dist/commands/config.d.ts.map +1 -0
  73. package/dist/commands/config.js +30 -0
  74. package/dist/commands/config.js.map +1 -0
  75. package/dist/commands/convention.d.ts +35 -0
  76. package/dist/commands/convention.d.ts.map +1 -0
  77. package/dist/commands/convention.js +680 -0
  78. package/dist/commands/convention.js.map +1 -0
  79. package/dist/commands/conventionRouter.d.ts +3 -0
  80. package/dist/commands/conventionRouter.d.ts.map +1 -0
  81. package/dist/commands/conventionRouter.js +46 -0
  82. package/dist/commands/conventionRouter.js.map +1 -0
  83. package/dist/commands/dependency.d.ts +4 -0
  84. package/dist/commands/dependency.d.ts.map +1 -0
  85. package/dist/commands/dependency.js +41 -0
  86. package/dist/commands/dependency.js.map +1 -0
  87. package/dist/commands/dependencyCommand.d.ts +2 -0
  88. package/dist/commands/dependencyCommand.d.ts.map +1 -0
  89. package/dist/commands/dependencyCommand.js +27 -0
  90. package/dist/commands/dependencyCommand.js.map +1 -0
  91. package/dist/commands/feedback.d.ts +2 -0
  92. package/dist/commands/feedback.d.ts.map +1 -0
  93. package/dist/commands/feedback.js +38 -0
  94. package/dist/commands/feedback.js.map +1 -0
  95. package/dist/commands/index.d.ts +2 -0
  96. package/dist/commands/index.d.ts.map +1 -0
  97. package/dist/commands/index.js +128 -0
  98. package/dist/commands/index.js.map +1 -0
  99. package/dist/commands/init.d.ts +22 -0
  100. package/dist/commands/init.d.ts.map +1 -0
  101. package/dist/commands/init.js +293 -0
  102. package/dist/commands/init.js.map +1 -0
  103. package/dist/commands/linear.d.ts +2 -0
  104. package/dist/commands/linear.d.ts.map +1 -0
  105. package/dist/commands/linear.js +41 -0
  106. package/dist/commands/linear.js.map +1 -0
  107. package/dist/commands/plan.d.ts +12 -0
  108. package/dist/commands/plan.d.ts.map +1 -0
  109. package/dist/commands/plan.js +626 -0
  110. package/dist/commands/plan.js.map +1 -0
  111. package/dist/commands/postmortem.d.ts +2 -0
  112. package/dist/commands/postmortem.d.ts.map +1 -0
  113. package/dist/commands/postmortem.js +157 -0
  114. package/dist/commands/postmortem.js.map +1 -0
  115. package/dist/commands/report.d.ts +2 -0
  116. package/dist/commands/report.d.ts.map +1 -0
  117. package/dist/commands/report.js +213 -0
  118. package/dist/commands/report.js.map +1 -0
  119. package/dist/commands/search.d.ts +2 -0
  120. package/dist/commands/search.d.ts.map +1 -0
  121. package/dist/commands/search.js +29 -0
  122. package/dist/commands/search.js.map +1 -0
  123. package/dist/commands/status.d.ts +2 -0
  124. package/dist/commands/status.d.ts.map +1 -0
  125. package/dist/commands/status.js +60 -0
  126. package/dist/commands/status.js.map +1 -0
  127. package/dist/index.d.ts +3 -0
  128. package/dist/index.d.ts.map +1 -0
  129. package/dist/index.js +750 -0
  130. package/dist/index.js.map +1 -0
  131. package/dist/types/index.d.ts +237 -0
  132. package/dist/types/index.d.ts.map +1 -0
  133. package/dist/types/index.js +6 -0
  134. package/dist/types/index.js.map +1 -0
  135. package/dist/utils/atomicWrite.d.ts +2 -0
  136. package/dist/utils/atomicWrite.d.ts.map +1 -0
  137. package/dist/utils/atomicWrite.js +7 -0
  138. package/dist/utils/atomicWrite.js.map +1 -0
  139. package/dist/utils/authServer.d.ts +18 -0
  140. package/dist/utils/authServer.d.ts.map +1 -0
  141. package/dist/utils/authServer.js +215 -0
  142. package/dist/utils/authServer.js.map +1 -0
  143. package/dist/utils/config.d.ts +31 -0
  144. package/dist/utils/config.d.ts.map +1 -0
  145. package/dist/utils/config.js +113 -0
  146. package/dist/utils/config.js.map +1 -0
  147. package/dist/utils/env.d.ts +7 -0
  148. package/dist/utils/env.d.ts.map +1 -0
  149. package/dist/utils/env.js +19 -0
  150. package/dist/utils/env.js.map +1 -0
  151. package/dist/utils/errors.d.ts +6 -0
  152. package/dist/utils/errors.d.ts.map +1 -0
  153. package/dist/utils/errors.js +112 -0
  154. package/dist/utils/errors.js.map +1 -0
  155. package/dist/utils/formatter.d.ts +2 -0
  156. package/dist/utils/formatter.d.ts.map +1 -0
  157. package/dist/utils/formatter.js +55 -0
  158. package/dist/utils/formatter.js.map +1 -0
  159. package/dist/utils/git.d.ts +21 -0
  160. package/dist/utils/git.d.ts.map +1 -0
  161. package/dist/utils/git.js +44 -0
  162. package/dist/utils/git.js.map +1 -0
  163. package/dist/utils/httpClient.d.ts +3 -0
  164. package/dist/utils/httpClient.d.ts.map +1 -0
  165. package/dist/utils/httpClient.js +45 -0
  166. package/dist/utils/httpClient.js.map +1 -0
  167. package/dist/utils/httpHeaders.d.ts +3 -0
  168. package/dist/utils/httpHeaders.d.ts.map +1 -0
  169. package/dist/utils/httpHeaders.js +11 -0
  170. package/dist/utils/httpHeaders.js.map +1 -0
  171. package/dist/utils/initOutput.d.ts +3 -0
  172. package/dist/utils/initOutput.d.ts.map +1 -0
  173. package/dist/utils/initOutput.js +45 -0
  174. package/dist/utils/initOutput.js.map +1 -0
  175. package/dist/utils/legacyCompat.d.ts +3 -0
  176. package/dist/utils/legacyCompat.d.ts.map +1 -0
  177. package/dist/utils/legacyCompat.js +20 -0
  178. package/dist/utils/legacyCompat.js.map +1 -0
  179. package/dist/utils/outputPolicy.d.ts +12 -0
  180. package/dist/utils/outputPolicy.d.ts.map +1 -0
  181. package/dist/utils/outputPolicy.js +171 -0
  182. package/dist/utils/outputPolicy.js.map +1 -0
  183. package/dist/utils/parsers.d.ts +14 -0
  184. package/dist/utils/parsers.d.ts.map +1 -0
  185. package/dist/utils/parsers.js +78 -0
  186. package/dist/utils/parsers.js.map +1 -0
  187. package/dist/utils/planFormat.d.ts +17 -0
  188. package/dist/utils/planFormat.d.ts.map +1 -0
  189. package/dist/utils/planFormat.js +81 -0
  190. package/dist/utils/planFormat.js.map +1 -0
  191. package/dist/utils/spinner.d.ts +6 -0
  192. package/dist/utils/spinner.d.ts.map +1 -0
  193. package/dist/utils/spinner.js +34 -0
  194. package/dist/utils/spinner.js.map +1 -0
  195. package/dist/utils/updateCheck.d.ts +19 -0
  196. package/dist/utils/updateCheck.d.ts.map +1 -0
  197. package/dist/utils/updateCheck.js +103 -0
  198. package/dist/utils/updateCheck.js.map +1 -0
  199. package/package.json +55 -0
  200. package/rlarua-agentteams-cli-0.1.8.tgz +0 -0
package/LICENSE ADDED
@@ -0,0 +1,201 @@
1
+ Apache License
2
+ Version 2.0, January 2004
3
+ http://www.apache.org/licenses/
4
+
5
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
6
+
7
+ 1. Definitions.
8
+
9
+ "License" shall mean the terms and conditions for use, reproduction,
10
+ and distribution as defined by Sections 1 through 9 of this document.
11
+
12
+ "Licensor" shall mean the copyright owner or entity authorized by
13
+ the copyright owner that is granting the License.
14
+
15
+ "Legal Entity" shall mean the union of the acting entity and all
16
+ other entities that control, are controlled by, or are under common
17
+ control with that entity. For the purposes of this definition,
18
+ "control" means (i) the power, direct or indirect, to cause the
19
+ direction or management of such entity, whether by contract or
20
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
21
+ outstanding shares, or (iii) beneficial ownership of such entity.
22
+
23
+ "You" (or "Your") shall mean an individual or Legal Entity
24
+ exercising permissions granted by this License.
25
+
26
+ "Source" form shall mean the preferred form for making modifications,
27
+ including but not limited to software source code, documentation
28
+ source, and configuration files.
29
+
30
+ "Object" form shall mean any form resulting from mechanical
31
+ transformation or translation of a Source form, including but
32
+ not limited to compiled object code, generated documentation,
33
+ and conversions to other media types.
34
+
35
+ "Work" shall mean the work of authorship, whether in Source or
36
+ Object form, made available under the License, as indicated by a
37
+ copyright notice that is included in or attached to the work
38
+ (an example is provided in the Appendix below).
39
+
40
+ "Derivative Works" shall mean any work, whether in Source or Object
41
+ form, that is based on (or derived from) the Work and for which the
42
+ editorial revisions, annotations, elaborations, or other modifications
43
+ represent, as a whole, an original work of authorship. For the purposes
44
+ of this License, Derivative Works shall not include works that remain
45
+ separable from, or merely link (or bind by name) to the interfaces of,
46
+ the Work and Derivative Works thereof.
47
+
48
+ "Contribution" shall mean any work of authorship, including
49
+ the original version of the Work and any modifications or additions
50
+ to that Work or Derivative Works thereof, that is intentionally
51
+ submitted to Licensor for inclusion in the Work by the copyright owner
52
+ or by an individual or Legal Entity authorized to submit on behalf of
53
+ the copyright owner. For the purposes of this definition, "submitted"
54
+ means any form of electronic, verbal, or written communication sent
55
+ to the Licensor or its representatives, including but not limited to
56
+ communication on electronic mailing lists, source code control systems,
57
+ and issue tracking systems that are managed by, or on behalf of, the
58
+ Licensor for the purpose of discussing and improving the Work, but
59
+ excluding communication that is conspicuously marked or otherwise
60
+ designated in writing by the copyright owner as "Not a Contribution."
61
+
62
+ "Contributor" shall mean Licensor and any individual or Legal Entity
63
+ on behalf of whom a Contribution has been received by Licensor and
64
+ subsequently incorporated within the Work.
65
+
66
+ 2. Grant of Copyright License. Subject to the terms and conditions of
67
+ this License, each Contributor hereby grants to You a perpetual,
68
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
69
+ copyright license to reproduce, prepare Derivative Works of,
70
+ publicly display, publicly perform, sublicense, and distribute the
71
+ Work and such Derivative Works in Source or Object form.
72
+
73
+ 3. Grant of Patent License. Subject to the terms and conditions of
74
+ this License, each Contributor hereby grants to You a perpetual,
75
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
76
+ (except as stated in this section) patent license to make, have made,
77
+ use, offer to sell, sell, import, and otherwise transfer the Work,
78
+ where such license applies only to those patent claims licensable
79
+ by such Contributor that are necessarily infringed by their
80
+ Contribution(s) alone or by combination of their Contribution(s)
81
+ with the Work to which such Contribution(s) was submitted. If You
82
+ institute patent litigation against any entity (including a
83
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
84
+ or a Contribution incorporated within the Work constitutes direct
85
+ or contributory patent infringement, then any patent licenses
86
+ granted to You under this License for that Work shall terminate
87
+ as of the date such litigation is filed.
88
+
89
+ 4. Redistribution. You may reproduce and distribute copies of the
90
+ Work or Derivative Works thereof in any medium, with or without
91
+ modifications, and in Source or Object form, provided that You
92
+ meet the following conditions:
93
+
94
+ (a) You must give any other recipients of the Work or
95
+ Derivative Works a copy of this License; and
96
+
97
+ (b) You must cause any modified files to carry prominent notices
98
+ stating that You changed the files; and
99
+
100
+ (c) You must retain, in the Source form of any Derivative Works
101
+ that You distribute, all copyright, patent, trademark, and
102
+ attribution notices from the Source form of the Work,
103
+ excluding those notices that do not pertain to any part of
104
+ the Derivative Works; and
105
+
106
+ (d) If the Work includes a "NOTICE" text file as part of its
107
+ distribution, then any Derivative Works that You distribute must
108
+ include a readable copy of the attribution notices contained
109
+ within such NOTICE file, excluding those notices that do not
110
+ pertain to any part of the Derivative Works, in at least one
111
+ of the following places: within a NOTICE text file distributed
112
+ as part of the Derivative Works; within the Source form or
113
+ documentation, if provided along with the Derivative Works; or,
114
+ within a display generated by the Derivative Works, if and
115
+ wherever such third-party notices normally appear. The contents
116
+ of the NOTICE file are for informational purposes only and
117
+ do not modify the License. You may add Your own attribution
118
+ notices within Derivative Works that You distribute, alongside
119
+ or as an addendum to the NOTICE text from the Work, provided
120
+ that such additional attribution notices cannot be construed
121
+ as modifying the License.
122
+
123
+ You may add Your own copyright statement to Your modifications and
124
+ may provide additional or different license terms and conditions
125
+ for use, reproduction, or distribution of Your modifications, or
126
+ for any such Derivative Works as a whole, provided Your use,
127
+ reproduction, and distribution of the Work otherwise complies with
128
+ the conditions stated in this License.
129
+
130
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
131
+ any Contribution intentionally submitted for inclusion in the Work
132
+ by You to the Licensor shall be under the terms and conditions of
133
+ this License, without any additional terms or conditions.
134
+ Notwithstanding the above, nothing herein shall supersede or modify
135
+ the terms of any separate license agreement you may have executed
136
+ with Licensor regarding such Contributions.
137
+
138
+ 6. Trademarks. This License does not grant permission to use the trade
139
+ names, trademarks, service marks, or product names of the Licensor,
140
+ except as required for reasonable and customary use in describing the
141
+ origin of the Work and reproducing the content of the NOTICE file.
142
+
143
+ 7. Disclaimer of Warranty. Unless required by applicable law or
144
+ agreed to in writing, Licensor provides the Work (and each
145
+ Contributor provides its Contributions) on an "AS IS" BASIS,
146
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
147
+ implied, including, without limitation, any warranties or conditions
148
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
149
+ PARTICULAR PURPOSE. You are solely responsible for determining the
150
+ appropriateness of using or redistributing the Work and assume any
151
+ risks associated with Your exercise of permissions under this License.
152
+
153
+ 8. Limitation of Liability. In no event and under no legal theory,
154
+ whether in tort (including negligence), contract, or otherwise,
155
+ unless required by applicable law (such as deliberate and grossly
156
+ negligent acts) or agreed to in writing, shall any Contributor be
157
+ liable to You for damages, including any direct, indirect, special,
158
+ incidental, or consequential damages of any character arising as a
159
+ result of this License or out of the use or inability to use the
160
+ Work (including but not limited to damages for loss of goodwill,
161
+ work stoppage, computer failure or malfunction, or any and all
162
+ other commercial damages or losses), even if such Contributor
163
+ has been advised of the possibility of such damages.
164
+
165
+ 9. Accepting Warranty or Additional Liability. While redistributing
166
+ the Work or Derivative Works thereof, You may choose to offer,
167
+ and charge a fee for, acceptance of support, warranty, indemnity,
168
+ or other liability obligations and/or rights consistent with this
169
+ License. However, in accepting such obligations, You may act only
170
+ on Your own behalf and on Your sole responsibility, not on behalf
171
+ of any other Contributor, and only if You agree to indemnify,
172
+ defend, and hold each Contributor harmless for any liability
173
+ incurred by, or claims asserted against, such Contributor by reason
174
+ of your accepting any such warranty or additional liability.
175
+
176
+ END OF TERMS AND CONDITIONS
177
+
178
+ APPENDIX: How to apply the Apache License to your work.
179
+
180
+ To apply the Apache License to your work, attach the following
181
+ boilerplate notice, with the fields enclosed by brackets "[]"
182
+ replaced with your own identifying information. (Don't include
183
+ the brackets!) The text should be enclosed in the appropriate
184
+ comment syntax for the file format. We also recommend that a
185
+ file or class name and description of purpose be included on the
186
+ same "printed page" as the copyright notice for easier
187
+ identification within third-party archives.
188
+
189
+ Copyright [yyyy] [name of copyright owner]
190
+
191
+ Licensed under the Apache License, Version 2.0 (the "License");
192
+ you may not use this file except in compliance with the License.
193
+ You may obtain a copy of the License at
194
+
195
+ http://www.apache.org/licenses/LICENSE-2.0
196
+
197
+ Unless required by applicable law or agreed to in writing, software
198
+ distributed under the License is distributed on an "AS IS" BASIS,
199
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
200
+ See the License for the specific language governing permissions and
201
+ limitations under the License.
package/README.md ADDED
@@ -0,0 +1,405 @@
1
+ # @agentteams/cli
2
+
3
+ [![GitHub](https://img.shields.io/badge/GitHub-rlarua%2FAgentTeams--cli-blue?logo=github)](https://github.com/rlarua/AgentTeams-cli)
4
+ [![Issues](https://img.shields.io/github/issues/rlarua/AgentTeams-cli)](https://github.com/rlarua/AgentTeams-cli/issues)
5
+
6
+ A CLI for working with the AgentTeams API from your terminal.
7
+ It supports convention sync and plan/comment/report management.
8
+
9
+ ## Installation
10
+
11
+ ```bash
12
+ npm install -g @agentteams/cli
13
+ ```
14
+
15
+ ## Quick Start
16
+
17
+ ### 1. Initialize
18
+
19
+ ```bash
20
+ agentteams init
21
+ ```
22
+
23
+ The `init` command:
24
+
25
+ - Opens a browser for OAuth authentication
26
+ - Creates `.agentteams/config.json`
27
+ - Optionally selects a default project repository (saved as `repositoryId` in config)
28
+ - Saves the convention template to `.agentteams/convention.md`
29
+ - Syncs convention files into `.agentteams/<category>/*.md`
30
+
31
+ In SSH/remote environments, open the URL printed in the terminal manually.
32
+
33
+ ### Service URLs (Defaults and Overrides)
34
+
35
+ The CLI talks to two services:
36
+
37
+ - Web app (OAuth flow): defaults to `https://agentteams.run`
38
+
39
+ ### 2. Protect Sensitive Data
40
+
41
+ `.agentteams` may contain API keys, so do not commit it to git.
42
+
43
+ ```gitignore
44
+ # AgentTeams CLI config (contains API keys)
45
+ .agentteams
46
+ ```
47
+
48
+ ### 3. Use Conventions
49
+
50
+ ```bash
51
+ agentteams convention list
52
+ agentteams convention show
53
+ agentteams convention download
54
+ agentteams convention create --file .agentteams/rules/new-rule.md
55
+ agentteams convention update --file .agentteams/rules/context.md
56
+ agentteams convention update --file .agentteams/rules/context.md --apply
57
+ agentteams convention delete --file .agentteams/rules/context.md
58
+ agentteams convention delete --file .agentteams/rules/context.md --apply
59
+ ```
60
+
61
+ ## Core Commands
62
+
63
+ ### `init`
64
+
65
+ Initialize the CLI via OAuth and download conventions.
66
+
67
+ ```bash
68
+ agentteams init
69
+ ```
70
+
71
+ ### `convention`
72
+
73
+ Manage project conventions.
74
+
75
+ ```bash
76
+ agentteams convention list
77
+ agentteams convention show
78
+ agentteams convention download
79
+ agentteams convention create --file .agentteams/rules/new-rule.md
80
+ agentteams convention update --file .agentteams/rules/context.md
81
+ agentteams convention update --file .agentteams/rules/context.md --apply
82
+ agentteams convention delete --file .agentteams/rules/context.md
83
+ agentteams convention delete --file .agentteams/rules/context.md --apply
84
+ ```
85
+
86
+ `convention download` saves files by category in `.agentteams/<category>/`.
87
+ If file names collide within the same category, suffixes like `-2`, `-3` are added.
88
+
89
+ #### `convention create`
90
+
91
+ Create a new convention.
92
+
93
+ - The input file must be under `.agentteams/<category>/*.md`, and `<category>` is inferred from the path.
94
+ - Frontmatter is optional. Supported fields: `trigger`, `description`, `title` (optional). Use `# AGENT_RULES` in the document body instead of the deprecated `agentInstruction` frontmatter field.
95
+ - After creation, the CLI immediately updates `.agentteams/conventions.manifest.json`, so you can `update/delete` the same file right away.
96
+ - Run `agentteams convention download` if you want to refresh `convention.md` and the server-normalized (downloadable) markdown.
97
+
98
+ Examples:
99
+
100
+ ```bash
101
+ agentteams convention create --file .agentteams/rules/new-rule.md
102
+ ```
103
+
104
+ #### `convention update` / `convention delete`
105
+
106
+ - By default, `update` and `delete` run in **dry-run** mode. They print a diff/plan and do not modify the server.
107
+ - Use `--apply` to actually update/delete the server resource.
108
+ - Only files produced by `agentteams convention download` are allowed. The CLI uses `.agentteams/conventions.manifest.json` to map local files to server conventions.
109
+
110
+ Examples:
111
+
112
+ ```bash
113
+ # Preview changes (dry-run)
114
+ agentteams convention update --file .agentteams/rules/context.md
115
+
116
+ # Apply update to server
117
+ agentteams convention update --file .agentteams/rules/context.md --apply
118
+
119
+ # Preview deletion (dry-run)
120
+ agentteams convention delete --file .agentteams/rules/context.md
121
+
122
+ # Apply deletion to server
123
+ agentteams convention delete --file .agentteams/rules/context.md --apply
124
+ ```
125
+
126
+ Common errors:
127
+
128
+ - `403 Forbidden`: the server rejected the operation due to missing write permissions.
129
+ - `409 Conflict`: optimistic-lock conflict (someone else updated the convention). Download again and retry.
130
+
131
+ ### `sync`
132
+
133
+ Resync convention files.
134
+
135
+ ```bash
136
+ agentteams sync
137
+ ```
138
+
139
+ ### `plan`
140
+
141
+ Manage plans.
142
+
143
+ Note: Plans are always created as `DRAFT`. Even if you pass `--status` to `plan create`, the server will ignore it. Use `plan update` to change status after creation.
144
+
145
+ ```bash
146
+ agentteams plan list
147
+ agentteams plan get --id <plan-id>
148
+ agentteams plan get --id <plan-id> --include-deps --format text
149
+ agentteams plan show --id <plan-id> # alias of get
150
+ agentteams plan status --id <plan-id>
151
+ agentteams plan set-status --id <plan-id> --status <status>
152
+
153
+ agentteams plan create \
154
+ --title "Implement feature" \
155
+ --content "Detailed content" \
156
+ --type FEATURE \
157
+ --priority HIGH
158
+
159
+ # optional checklist template for create
160
+ agentteams plan create \
161
+ --title "Refactor module" \
162
+ --template "refactor-minimal"
163
+
164
+ # repository linkage
165
+ # - `plan create` uses `.agentteams/config.json` -> `repositoryId` when present.
166
+
167
+ agentteams plan quick --title "Quick task" --content "Implemented X and verified with tests" --type CHORE
168
+ agentteams plan update --id <plan-id> --status PENDING
169
+ agentteams plan update --id <plan-id> --status IN_PROGRESS
170
+ agentteams plan assign --id <plan-id> --agent "agent-name"
171
+ agentteams plan download --id <plan-id>
172
+ agentteams plan cleanup --id <plan-id>
173
+ agentteams plan delete --id <plan-id>
174
+ ```
175
+
176
+ Status values: `DRAFT`, `PENDING`, `ASSIGNED`, `IN_PROGRESS`, `BLOCKED`, `DONE`, `CANCELLED`
177
+
178
+ Types: `FEATURE`, `BUG_FIX`, `ISSUE`, `REFACTOR`, `CHORE`
179
+
180
+ Priorities: `LOW`, `MEDIUM`, `HIGH`
181
+
182
+ Plan template values (create): `refactor-minimal`, `quick-minimal`
183
+
184
+ `plan quick` behavior:
185
+
186
+ - Creates a plan with `--content` as the plan body (`--content` or `--file` is required)
187
+ - Uses `LOW` as the default priority (override with `--priority`)
188
+ - Starts and finishes the plan in one flow
189
+ - Does not attach a completion report; use the full plan workflow for detailed reporting
190
+
191
+ `--include-deps` (get/show): also fetches dependency data and appends a `Dependencies` section in text output; in json output it adds `data.dependencies` with `blocking` and `dependents` arrays.
192
+
193
+ ### `comment`
194
+
195
+ Manage plan comments.
196
+
197
+ ```bash
198
+ agentteams comment list --plan-id <plan-id>
199
+
200
+ agentteams comment create \
201
+ --plan-id <plan-id> \
202
+ --type GENERAL \
203
+ --content "Work completed"
204
+
205
+ agentteams comment update --id <comment-id> --content "Updated content"
206
+ agentteams comment delete --id <comment-id>
207
+ ```
208
+
209
+ Types: `RISK`, `MODIFICATION`, `GENERAL`
210
+
211
+ ### `dependency`
212
+
213
+ Manage plan dependencies.
214
+
215
+ ```bash
216
+ agentteams dependency list --plan-id <plan-id>
217
+ agentteams dependency create --plan-id <plan-id> --blocking-plan-id <blocking-plan-id>
218
+ agentteams dependency delete --plan-id <plan-id> --dep-id <dependency-id>
219
+ ```
220
+
221
+ ### `agent-config`
222
+
223
+ View or delete agent configurations.
224
+
225
+ ```bash
226
+ agentteams agent-config list
227
+ agentteams agent-config get --id <config-id>
228
+ agentteams agent-config delete --id <config-id>
229
+ ```
230
+
231
+ ### `report`
232
+
233
+ Manage completion reports.
234
+
235
+ Tip: Include reproducible verification evidence (commands + outcomes), but keep outcomes short: `pass/fail + 1–3 lines of summary`. Do not paste long raw logs into the report body.
236
+
237
+ ```bash
238
+ agentteams report list
239
+
240
+ agentteams report create \
241
+ --title "AgentTeams completion report" \
242
+ --file ./report.md \
243
+ --status COMPLETED
244
+
245
+ # repository linkage
246
+ # - `report create` uses `.agentteams/config.json` -> `repositoryId` when present.
247
+
248
+ # with metrics (auto + manual)
249
+ agentteams report create \
250
+ --title "CLI metrics report" \
251
+ --file ./report.md \
252
+ --files-modified 5 \
253
+ --lines-added 120 \
254
+ --lines-deleted 30 \
255
+ --quality-score 95
256
+
257
+ # disable git auto collection
258
+ agentteams report create \
259
+ --title "Manual metrics report" \
260
+ --file ./report.md \
261
+ --no-git
262
+ ```
263
+
264
+ Status values: `COMPLETED`, `FAILED`, `PARTIAL`
265
+
266
+ Metrics behavior:
267
+
268
+ - Auto-collected on `report create` (unless `--no-git`): `commitHash`, `branchName`, `filesModified`, `linesAdded`, `linesDeleted`
269
+ - Manual only: `durationSeconds`, `commitStart`, `commitEnd`, `pullRequestId`
270
+ - Manual options always override auto-collected values
271
+
272
+ ### `postmortem`
273
+
274
+ Manage post mortems.
275
+
276
+ Tip: If you have platform guides downloaded under `.agentteams/platform/guides/`, prefer the template in `post-mortem-guide.md`.
277
+
278
+ ```bash
279
+ agentteams postmortem list
280
+
281
+ agentteams postmortem create \
282
+ --title "Deployment incident analysis" \
283
+ --content "## Root cause\n- Missing configuration" \
284
+ --action-items "Automate rollback,Pre-release checklist" \
285
+ --status RESOLVED
286
+
287
+ # repository linkage
288
+ # - `postmortem create` uses `.agentteams/config.json` -> `repositoryId` when present.
289
+ ```
290
+
291
+ Status values: `OPEN`, `IN_PROGRESS`, `RESOLVED`
292
+
293
+ ### `search`
294
+
295
+ Search across all entity types in a project.
296
+
297
+ ```bash
298
+ # Basic search
299
+ agentteams search --query "login feature"
300
+
301
+ # Filter by entity types
302
+ agentteams search --query "auth" --types PLAN,CO_ACTION
303
+
304
+ # Limit results and token budget (useful for agents)
305
+ agentteams search --query "deployment" --limit 5 --max-tokens 4000
306
+
307
+ # JSON output for automation
308
+ agentteams search --query "refactor" --format json
309
+ ```
310
+
311
+ Searchable entity types: `PLAN`, `CO_ACTION`, `COMPLETION_REPORT`, `POST_MORTEM`, `CONVENTION`
312
+
313
+ ### `config`
314
+
315
+ ```bash
316
+ agentteams config whoami
317
+ agentteams config whoami --format text
318
+ ```
319
+
320
+ `config whoami` prints current environment variable values for `AGENTTEAMS_API_KEY` and `AGENTTEAMS_API_URL`.
321
+
322
+ ## Configuration
323
+
324
+ Configuration is merged in this priority order (highest first):
325
+
326
+ 1. CLI options
327
+ 2. Environment variables (`AGENTTEAMS_*`)
328
+ 3. Project config (`.agentteams/config.json`)
329
+ 4. Global config (`~/.agentteams/config.json`)
330
+
331
+ ### Config File Example
332
+
333
+ ```json
334
+ {
335
+ "teamId": "team_xxx",
336
+ "projectId": "proj_xxx",
337
+ "repositoryId": "repo_xxx",
338
+ "agentName": "my-agent",
339
+ "apiKey": "key_xxx",
340
+ "apiUrl": "https://api.agentteams.run"
341
+ }
342
+ ```
343
+
344
+ ### Environment Variable Example
345
+
346
+ ```bash
347
+ export AGENTTEAMS_API_KEY="key_your_api_key_here"
348
+ export AGENTTEAMS_API_URL="https://api.agentteams.run"
349
+ export AGENTTEAMS_TEAM_ID="team_xxx"
350
+ export AGENTTEAMS_PROJECT_ID="proj_xxx"
351
+ export AGENTTEAMS_AGENT_NAME="my-agent"
352
+ ```
353
+
354
+ ## Output Format
355
+
356
+ Most resource commands support `--format json|text`.
357
+
358
+ Output behavior by default:
359
+
360
+ - `plan create|update|start|finish|quick`: prints short summary lines on stdout by default.
361
+ - `plan list|get` and other read-oriented commands: keep full output by default.
362
+ - `--verbose`: always prints full output to stdout.
363
+ - `--output-file <path>`: always writes full output to file and keeps stdout short.
364
+
365
+ Compatibility note:
366
+
367
+ - If you need full JSON on stdout for automation, pass `--format json` explicitly.
368
+
369
+ ```bash
370
+ agentteams plan list --format json
371
+ agentteams plan list --format text
372
+ agentteams plan update --id <plan-id> --status IN_PROGRESS --format json
373
+ ```
374
+
375
+ Note: `convention` does not support `--format`.
376
+
377
+ ## Error Guide
378
+
379
+ The API may include an optional machine-readable `errorCode` in error responses:
380
+
381
+ ```json
382
+ {
383
+ "statusCode": 403,
384
+ "error": "Forbidden",
385
+ "message": "Cross-project access denied",
386
+ "errorCode": "CROSS_PROJECT_ACCESS_DENIED"
387
+ }
388
+ ```
389
+
390
+ The CLI prioritizes `errorCode` when present and falls back to message/status-based handling for older API responses.
391
+
392
+ | Error | Meaning | Resolution |
393
+ |---|---|---|
394
+ | `401 Unauthorized` | Invalid API key | Check `apiKey` or `AGENTTEAMS_API_KEY` |
395
+ | `403 Forbidden` | No access to project | Verify `projectId` |
396
+ | `404 Not Found` | Resource does not exist | Verify ID or create the resource |
397
+ | Network error | Cannot reach server | Check `apiUrl` and server status |
398
+ | Missing config | Config file/env vars not found | Run `agentteams init` |
399
+
400
+ ## License
401
+
402
+ Apache-2.0
403
+
404
+ This license applies to the CLI code distributed in this package.
405
+ Use of the AgentTeams service/API may require credentials and is governed by separate service terms/policies.
package/SECURITY.md ADDED
@@ -0,0 +1,27 @@
1
+ # Security Policy
2
+
3
+ ## Supported Versions
4
+
5
+ Security fixes are applied to the latest released version of `@agentteams/cli`.
6
+
7
+ ## Reporting a Vulnerability
8
+
9
+ Please do not open public issues for security vulnerabilities.
10
+
11
+ Use one of the following channels:
12
+
13
+ 1. GitHub Security Advisory (preferred): open a private report in this repository.
14
+ 2. If advisory is unavailable, contact the maintainers through a private GitHub channel.
15
+
16
+ Include the following details in your report:
17
+
18
+ - Affected version
19
+ - Reproduction steps
20
+ - Impact assessment
21
+ - Suggested fix (optional)
22
+
23
+ ## Response Process
24
+
25
+ - We will acknowledge receipt as soon as possible.
26
+ - We will validate and triage the issue.
27
+ - We will coordinate a fix and release timeline.
@@ -0,0 +1,17 @@
1
+ export declare function listCoActions(apiUrl: string, projectId: string, headers: any, params?: Record<string, string | number>): Promise<any>;
2
+ export declare function getCoAction(apiUrl: string, projectId: string, headers: any, id: string): Promise<any>;
3
+ export declare function createCoAction(apiUrl: string, projectId: string, headers: any, body: Record<string, unknown>): Promise<any>;
4
+ export declare function updateCoAction(apiUrl: string, projectId: string, headers: any, id: string, body: Record<string, unknown>): Promise<any>;
5
+ export declare function deleteCoAction(apiUrl: string, projectId: string, headers: any, id: string): Promise<any>;
6
+ export declare function listCoActionTakeaways(apiUrl: string, projectId: string, headers: any, coActionId: string, params?: Record<string, string | number>): Promise<any>;
7
+ export declare function createCoActionTakeaway(apiUrl: string, projectId: string, headers: any, coActionId: string, body: Record<string, unknown>): Promise<any>;
8
+ export declare function updateCoActionTakeaway(apiUrl: string, projectId: string, headers: any, coActionId: string, takeawayId: string, body: Record<string, unknown>): Promise<any>;
9
+ export declare function deleteCoActionTakeaway(apiUrl: string, projectId: string, headers: any, coActionId: string, takeawayId: string): Promise<any>;
10
+ export declare function listCoActionHistories(apiUrl: string, projectId: string, headers: any, coActionId: string, params?: Record<string, string | number>): Promise<any>;
11
+ export declare function linkPlanToCoAction(apiUrl: string, projectId: string, headers: any, coActionId: string, planId: string): Promise<any>;
12
+ export declare function unlinkPlanFromCoAction(apiUrl: string, projectId: string, headers: any, coActionId: string, planId: string): Promise<any>;
13
+ export declare function linkCompletionReportToCoAction(apiUrl: string, projectId: string, headers: any, coActionId: string, completionReportId: string): Promise<any>;
14
+ export declare function unlinkCompletionReportFromCoAction(apiUrl: string, projectId: string, headers: any, coActionId: string, completionReportId: string): Promise<any>;
15
+ export declare function linkPostMortemToCoAction(apiUrl: string, projectId: string, headers: any, coActionId: string, postMortemId: string): Promise<any>;
16
+ export declare function unlinkPostMortemFromCoAction(apiUrl: string, projectId: string, headers: any, coActionId: string, postMortemId: string): Promise<any>;
17
+ //# sourceMappingURL=coaction.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"coaction.d.ts","sourceRoot":"","sources":["../../src/api/coaction.ts"],"names":[],"mappings":"AAGA,wBAAsB,aAAa,CACjC,MAAM,EAAE,MAAM,EACd,SAAS,EAAE,MAAM,EACjB,OAAO,EAAE,GAAG,EACZ,MAAM,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,CAAC,GACvC,OAAO,CAAC,GAAG,CAAC,CAQd;AAED,wBAAsB,WAAW,CAC/B,MAAM,EAAE,MAAM,EACd,SAAS,EAAE,MAAM,EACjB,OAAO,EAAE,GAAG,EACZ,EAAE,EAAE,MAAM,GACT,OAAO,CAAC,GAAG,CAAC,CAId;AAED,wBAAsB,cAAc,CAClC,MAAM,EAAE,MAAM,EACd,SAAS,EAAE,MAAM,EACjB,OAAO,EAAE,GAAG,EACZ,IAAI,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAC5B,OAAO,CAAC,GAAG,CAAC,CAId;AAED,wBAAsB,cAAc,CA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