@recursiv/sdk 0.7.13 → 0.7.15

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 (275) hide show
  1. package/README.md +23 -4
  2. package/dist/client.d.ts +0 -1
  3. package/dist/client.js +0 -1
  4. package/dist/errors.d.ts +0 -1
  5. package/dist/errors.js +0 -1
  6. package/dist/index.d.ts +1 -2
  7. package/dist/index.js +0 -1
  8. package/dist/lib/sse.d.ts +0 -1
  9. package/dist/lib/sse.js +0 -1
  10. package/dist/lib/webhooks.d.ts +0 -1
  11. package/dist/lib/webhooks.js +0 -1
  12. package/dist/next/index.d.ts +0 -1
  13. package/dist/next/index.js +0 -1
  14. package/dist/next/scopes.d.ts +0 -1
  15. package/dist/next/scopes.js +0 -1
  16. package/dist/next/server-auth.d.ts +0 -1
  17. package/dist/next/server-auth.js +0 -1
  18. package/dist/react/index.d.ts +0 -1
  19. package/dist/react/index.js +0 -1
  20. package/dist/react/useChat.d.ts +0 -1
  21. package/dist/react/useChat.js +0 -1
  22. package/dist/realtime.d.ts +1 -2
  23. package/dist/realtime.js +23 -11
  24. package/dist/resources/accounts.d.ts +0 -1
  25. package/dist/resources/accounts.js +0 -1
  26. package/dist/resources/admin.d.ts +4 -1
  27. package/dist/resources/admin.js +4 -1
  28. package/dist/resources/agents.d.ts +11 -2
  29. package/dist/resources/agents.js +12 -1
  30. package/dist/resources/app-subscriptions.d.ts +0 -1
  31. package/dist/resources/app-subscriptions.js +0 -1
  32. package/dist/resources/auth.d.ts +25 -1
  33. package/dist/resources/auth.js +75 -4
  34. package/dist/resources/billing.d.ts +0 -1
  35. package/dist/resources/billing.js +0 -1
  36. package/dist/resources/brain.d.ts +0 -1
  37. package/dist/resources/brain.js +0 -1
  38. package/dist/resources/brief.d.ts +0 -1
  39. package/dist/resources/brief.js +0 -1
  40. package/dist/resources/chat.d.ts +0 -1
  41. package/dist/resources/chat.js +0 -1
  42. package/dist/resources/commands.d.ts +0 -1
  43. package/dist/resources/commands.js +0 -1
  44. package/dist/resources/communities.d.ts +66 -4
  45. package/dist/resources/communities.js +62 -2
  46. package/dist/resources/curator.d.ts +0 -1
  47. package/dist/resources/curator.js +0 -1
  48. package/dist/resources/databases.d.ts +0 -1
  49. package/dist/resources/databases.js +0 -1
  50. package/dist/resources/deployments.d.ts +0 -1
  51. package/dist/resources/deployments.js +0 -1
  52. package/dist/resources/dispatcher.d.ts +18 -2
  53. package/dist/resources/dispatcher.js +6 -2
  54. package/dist/resources/email.d.ts +0 -1
  55. package/dist/resources/email.js +0 -1
  56. package/dist/resources/env-vars.d.ts +0 -1
  57. package/dist/resources/env-vars.js +0 -1
  58. package/dist/resources/evidence.d.ts +26 -4
  59. package/dist/resources/evidence.js +8 -1
  60. package/dist/resources/free-tier.d.ts +0 -1
  61. package/dist/resources/free-tier.js +0 -1
  62. package/dist/resources/github.d.ts +0 -1
  63. package/dist/resources/github.js +0 -1
  64. package/dist/resources/goals.d.ts +0 -1
  65. package/dist/resources/goals.js +0 -1
  66. package/dist/resources/human-asks.d.ts +0 -1
  67. package/dist/resources/human-asks.js +0 -1
  68. package/dist/resources/human-input.d.ts +0 -1
  69. package/dist/resources/human-input.js +0 -1
  70. package/dist/resources/inbox.d.ts +0 -1
  71. package/dist/resources/inbox.js +0 -1
  72. package/dist/resources/integrations.d.ts +0 -1
  73. package/dist/resources/integrations.js +0 -1
  74. package/dist/resources/invite-codes-admin.d.ts +0 -1
  75. package/dist/resources/invite-codes-admin.js +0 -1
  76. package/dist/resources/invite-codes.d.ts +0 -1
  77. package/dist/resources/invite-codes.js +0 -1
  78. package/dist/resources/jobs.d.ts +0 -1
  79. package/dist/resources/jobs.js +0 -1
  80. package/dist/resources/link-preview.d.ts +0 -1
  81. package/dist/resources/link-preview.js +0 -1
  82. package/dist/resources/media.d.ts +0 -1
  83. package/dist/resources/media.js +0 -1
  84. package/dist/resources/memory.d.ts +0 -1
  85. package/dist/resources/memory.js +0 -1
  86. package/dist/resources/moderation.d.ts +0 -1
  87. package/dist/resources/moderation.js +0 -1
  88. package/dist/resources/network.d.ts +0 -1
  89. package/dist/resources/network.js +0 -1
  90. package/dist/resources/notifications.d.ts +14 -2
  91. package/dist/resources/notifications.js +5 -3
  92. package/dist/resources/organization-security.d.ts +0 -1
  93. package/dist/resources/organization-security.js +0 -1
  94. package/dist/resources/organization-settings.d.ts +18 -1
  95. package/dist/resources/organization-settings.js +4 -1
  96. package/dist/resources/organizations.d.ts +0 -1
  97. package/dist/resources/organizations.js +0 -1
  98. package/dist/resources/posts.d.ts +0 -1
  99. package/dist/resources/posts.js +0 -1
  100. package/dist/resources/profiles.d.ts +8 -1
  101. package/dist/resources/profiles.js +8 -1
  102. package/dist/resources/project-brain.d.ts +18 -1
  103. package/dist/resources/project-brain.js +11 -1
  104. package/dist/resources/project-settings.d.ts +0 -1
  105. package/dist/resources/project-settings.js +0 -1
  106. package/dist/resources/projects.d.ts +0 -1
  107. package/dist/resources/projects.js +0 -1
  108. package/dist/resources/protocols.d.ts +54 -1
  109. package/dist/resources/protocols.js +29 -1
  110. package/dist/resources/reports.d.ts +0 -1
  111. package/dist/resources/reports.js +0 -1
  112. package/dist/resources/sandbox.d.ts +0 -1
  113. package/dist/resources/sandbox.js +0 -1
  114. package/dist/resources/settings.d.ts +0 -1
  115. package/dist/resources/settings.js +0 -1
  116. package/dist/resources/simulator.d.ts +0 -1
  117. package/dist/resources/simulator.js +0 -1
  118. package/dist/resources/storage.d.ts +0 -1
  119. package/dist/resources/storage.js +0 -1
  120. package/dist/resources/swarms.d.ts +0 -1
  121. package/dist/resources/swarms.js +0 -1
  122. package/dist/resources/tags.d.ts +0 -1
  123. package/dist/resources/tags.js +0 -1
  124. package/dist/resources/templates.d.ts +0 -1
  125. package/dist/resources/templates.js +0 -1
  126. package/dist/resources/uploads.d.ts +0 -1
  127. package/dist/resources/uploads.js +0 -1
  128. package/dist/resources/users.d.ts +0 -1
  129. package/dist/resources/users.js +0 -1
  130. package/dist/resources/video.d.ts +0 -1
  131. package/dist/resources/video.js +0 -1
  132. package/dist/resources/wallet.d.ts +16 -1
  133. package/dist/resources/wallet.js +12 -1
  134. package/dist/resources/webhooks.d.ts +0 -1
  135. package/dist/resources/webhooks.js +0 -1
  136. package/dist/types.d.ts +34 -1
  137. package/dist/types.js +0 -1
  138. package/llm.md +29 -2
  139. package/package.json +13 -7
  140. package/dist/client.d.ts.map +0 -1
  141. package/dist/client.js.map +0 -1
  142. package/dist/errors.d.ts.map +0 -1
  143. package/dist/errors.js.map +0 -1
  144. package/dist/index.d.ts.map +0 -1
  145. package/dist/index.js.map +0 -1
  146. package/dist/lib/sse.d.ts.map +0 -1
  147. package/dist/lib/sse.js.map +0 -1
  148. package/dist/lib/webhooks.d.ts.map +0 -1
  149. package/dist/lib/webhooks.js.map +0 -1
  150. package/dist/next/index.d.ts.map +0 -1
  151. package/dist/next/index.js.map +0 -1
  152. package/dist/next/scopes.d.ts.map +0 -1
  153. package/dist/next/scopes.js.map +0 -1
  154. package/dist/next/server-auth.d.ts.map +0 -1
  155. package/dist/next/server-auth.js.map +0 -1
  156. package/dist/react/index.d.ts.map +0 -1
  157. package/dist/react/index.js.map +0 -1
  158. package/dist/react/useChat.d.ts.map +0 -1
  159. package/dist/react/useChat.js.map +0 -1
  160. package/dist/realtime.d.ts.map +0 -1
  161. package/dist/realtime.js.map +0 -1
  162. package/dist/resources/accounts.d.ts.map +0 -1
  163. package/dist/resources/accounts.js.map +0 -1
  164. package/dist/resources/admin.d.ts.map +0 -1
  165. package/dist/resources/admin.js.map +0 -1
  166. package/dist/resources/agents.d.ts.map +0 -1
  167. package/dist/resources/agents.js.map +0 -1
  168. package/dist/resources/app-subscriptions.d.ts.map +0 -1
  169. package/dist/resources/app-subscriptions.js.map +0 -1
  170. package/dist/resources/auth.d.ts.map +0 -1
  171. package/dist/resources/auth.js.map +0 -1
  172. package/dist/resources/billing.d.ts.map +0 -1
  173. package/dist/resources/billing.js.map +0 -1
  174. package/dist/resources/brain.d.ts.map +0 -1
  175. package/dist/resources/brain.js.map +0 -1
  176. package/dist/resources/brief.d.ts.map +0 -1
  177. package/dist/resources/brief.js.map +0 -1
  178. package/dist/resources/chat.d.ts.map +0 -1
  179. package/dist/resources/chat.js.map +0 -1
  180. package/dist/resources/commands.d.ts.map +0 -1
  181. package/dist/resources/commands.js.map +0 -1
  182. package/dist/resources/communities.d.ts.map +0 -1
  183. package/dist/resources/communities.js.map +0 -1
  184. package/dist/resources/curator.d.ts.map +0 -1
  185. package/dist/resources/curator.js.map +0 -1
  186. package/dist/resources/databases.d.ts.map +0 -1
  187. package/dist/resources/databases.js.map +0 -1
  188. package/dist/resources/deployments.d.ts.map +0 -1
  189. package/dist/resources/deployments.js.map +0 -1
  190. package/dist/resources/dispatcher.d.ts.map +0 -1
  191. package/dist/resources/dispatcher.js.map +0 -1
  192. package/dist/resources/email.d.ts.map +0 -1
  193. package/dist/resources/email.js.map +0 -1
  194. package/dist/resources/env-vars.d.ts.map +0 -1
  195. package/dist/resources/env-vars.js.map +0 -1
  196. package/dist/resources/evidence.d.ts.map +0 -1
  197. package/dist/resources/evidence.js.map +0 -1
  198. package/dist/resources/free-tier.d.ts.map +0 -1
  199. package/dist/resources/free-tier.js.map +0 -1
  200. package/dist/resources/github.d.ts.map +0 -1
  201. package/dist/resources/github.js.map +0 -1
  202. package/dist/resources/goals.d.ts.map +0 -1
  203. package/dist/resources/goals.js.map +0 -1
  204. package/dist/resources/human-asks.d.ts.map +0 -1
  205. package/dist/resources/human-asks.js.map +0 -1
  206. package/dist/resources/human-input.d.ts.map +0 -1
  207. package/dist/resources/human-input.js.map +0 -1
  208. package/dist/resources/inbox.d.ts.map +0 -1
  209. package/dist/resources/inbox.js.map +0 -1
  210. package/dist/resources/integrations.d.ts.map +0 -1
  211. package/dist/resources/integrations.js.map +0 -1
  212. package/dist/resources/invite-codes-admin.d.ts.map +0 -1
  213. package/dist/resources/invite-codes-admin.js.map +0 -1
  214. package/dist/resources/invite-codes.d.ts.map +0 -1
  215. package/dist/resources/invite-codes.js.map +0 -1
  216. package/dist/resources/jobs.d.ts.map +0 -1
  217. package/dist/resources/jobs.js.map +0 -1
  218. package/dist/resources/link-preview.d.ts.map +0 -1
  219. package/dist/resources/link-preview.js.map +0 -1
  220. package/dist/resources/media.d.ts.map +0 -1
  221. package/dist/resources/media.js.map +0 -1
  222. package/dist/resources/memory.d.ts.map +0 -1
  223. package/dist/resources/memory.js.map +0 -1
  224. package/dist/resources/moderation.d.ts.map +0 -1
  225. package/dist/resources/moderation.js.map +0 -1
  226. package/dist/resources/network.d.ts.map +0 -1
  227. package/dist/resources/network.js.map +0 -1
  228. package/dist/resources/notifications.d.ts.map +0 -1
  229. package/dist/resources/notifications.js.map +0 -1
  230. package/dist/resources/organization-security.d.ts.map +0 -1
  231. package/dist/resources/organization-security.js.map +0 -1
  232. package/dist/resources/organization-settings.d.ts.map +0 -1
  233. package/dist/resources/organization-settings.js.map +0 -1
  234. package/dist/resources/organizations.d.ts.map +0 -1
  235. package/dist/resources/organizations.js.map +0 -1
  236. package/dist/resources/posts.d.ts.map +0 -1
  237. package/dist/resources/posts.js.map +0 -1
  238. package/dist/resources/profiles.d.ts.map +0 -1
  239. package/dist/resources/profiles.js.map +0 -1
  240. package/dist/resources/project-brain.d.ts.map +0 -1
  241. package/dist/resources/project-brain.js.map +0 -1
  242. package/dist/resources/project-settings.d.ts.map +0 -1
  243. package/dist/resources/project-settings.js.map +0 -1
  244. package/dist/resources/projects.d.ts.map +0 -1
  245. package/dist/resources/projects.js.map +0 -1
  246. package/dist/resources/protocols.d.ts.map +0 -1
  247. package/dist/resources/protocols.js.map +0 -1
  248. package/dist/resources/reports.d.ts.map +0 -1
  249. package/dist/resources/reports.js.map +0 -1
  250. package/dist/resources/sandbox.d.ts.map +0 -1
  251. package/dist/resources/sandbox.js.map +0 -1
  252. package/dist/resources/settings.d.ts.map +0 -1
  253. package/dist/resources/settings.js.map +0 -1
  254. package/dist/resources/simulator.d.ts.map +0 -1
  255. package/dist/resources/simulator.js.map +0 -1
  256. package/dist/resources/storage.d.ts.map +0 -1
  257. package/dist/resources/storage.js.map +0 -1
  258. package/dist/resources/swarms.d.ts.map +0 -1
  259. package/dist/resources/swarms.js.map +0 -1
  260. package/dist/resources/tags.d.ts.map +0 -1
  261. package/dist/resources/tags.js.map +0 -1
  262. package/dist/resources/templates.d.ts.map +0 -1
  263. package/dist/resources/templates.js.map +0 -1
  264. package/dist/resources/uploads.d.ts.map +0 -1
  265. package/dist/resources/uploads.js.map +0 -1
  266. package/dist/resources/users.d.ts.map +0 -1
  267. package/dist/resources/users.js.map +0 -1
  268. package/dist/resources/video.d.ts.map +0 -1
  269. package/dist/resources/video.js.map +0 -1
  270. package/dist/resources/wallet.d.ts.map +0 -1
  271. package/dist/resources/wallet.js.map +0 -1
  272. package/dist/resources/webhooks.d.ts.map +0 -1
  273. package/dist/resources/webhooks.js.map +0 -1
  274. package/dist/types.d.ts.map +0 -1
  275. package/dist/types.js.map +0 -1
@@ -1,10 +1,10 @@
1
1
  import type { HttpClient } from '../client.js';
2
- import type { PaginatedResponse, SingleResponse, Community, CommunityDetail, CommunityMember, CreateCommunityInput, CreatedCommunity, JoinResult, LeaveResult, PaginationParams } from '../types.js';
2
+ import type { Community, CommunityBannedMember, CommunityDetail, CommunityMember, CreateCommunityInput, CreatedCommunity, JoinResult, LeaveResult, ListCommunitiesParams, PaginatedResponse, PaginationParams, SingleResponse } from '../types.js';
3
3
  export declare class CommunitiesResource {
4
4
  private client;
5
5
  constructor(client: HttpClient);
6
- /** List public communities */
7
- list(params?: PaginationParams): Promise<PaginatedResponse<Community>>;
6
+ /** List public communities, or only the authenticated caller's memberships. */
7
+ list(params?: ListCommunitiesParams): Promise<PaginatedResponse<Community>>;
8
8
  /** Get a community by ID */
9
9
  get(id: string): Promise<SingleResponse<CommunityDetail>>;
10
10
  /** List members of a community */
@@ -15,5 +15,67 @@ export declare class CommunitiesResource {
15
15
  join(id: string): Promise<SingleResponse<JoinResult>>;
16
16
  /** Leave a community */
17
17
  leave(id: string): Promise<SingleResponse<LeaveResult>>;
18
+ /** Update name, description, image, banner or privacy. Owner or admin. */
19
+ update(id: string, input: Partial<Pick<CreateCommunityInput, 'name' | 'description' | 'privacy'>> & {
20
+ image?: string | null;
21
+ banner?: string | null;
22
+ }): Promise<SingleResponse<CommunityDetail>>;
23
+ /** Delete a community. Owner only. */
24
+ delete(id: string): Promise<SingleResponse<{
25
+ deleted: boolean;
26
+ }>>;
27
+ /** People waiting to join a private group. Moderator or higher. */
28
+ requests(id: string, params?: PaginationParams): Promise<PaginatedResponse<CommunityMember>>;
29
+ /** Active bans an admin can review and lift. Admin or higher. */
30
+ bans(id: string, params?: PaginationParams): Promise<PaginatedResponse<CommunityBannedMember>>;
31
+ /** Let a pending member in. Admin or higher. */
32
+ approveMember(id: string, userId: string): Promise<SingleResponse<{
33
+ status: string;
34
+ }>>;
35
+ /** Turn a pending member away. Admin or higher. */
36
+ declineMember(id: string, userId: string): Promise<SingleResponse<{
37
+ declined: boolean;
38
+ }>>;
39
+ /** Remove a member. Moderator or higher, and only members below your role. */
40
+ removeMember(id: string, userId: string): Promise<SingleResponse<{
41
+ removed: boolean;
42
+ }>>;
43
+ /** Ban a member, with an optional reason. Moderator or higher. */
44
+ banMember(id: string, userId: string, reason?: string): Promise<SingleResponse<{
45
+ banned: boolean;
46
+ }>>;
47
+ /** Lift a ban. Admin or higher. */
48
+ unbanMember(id: string, userId: string): Promise<SingleResponse<{
49
+ banned: boolean;
50
+ }>>;
51
+ /** Change a member's role. Admin or higher; only the owner makes admins. */
52
+ setMemberRole(id: string, userId: string, role: 'admin' | 'moderator' | 'member'): Promise<SingleResponse<{
53
+ role: string;
54
+ }>>;
55
+ /** Pin a post to the top of the group. Moderator or higher. */
56
+ pinPost(id: string, postId: string): Promise<SingleResponse<{
57
+ pinned: boolean;
58
+ }>>;
59
+ /** Unpin a post. Moderator or higher. */
60
+ unpinPost(id: string, postId: string): Promise<SingleResponse<{
61
+ pinned: boolean;
62
+ }>>;
63
+ /** Remove a post from the group. Moderator or higher. */
64
+ removePost(id: string, postId: string): Promise<SingleResponse<{
65
+ removed: boolean;
66
+ }>>;
67
+ /**
68
+ * Mint an invite code that joins the redeemer to this group. Any member of
69
+ * a public group; moderator or higher for a private one. Admins can mint a
70
+ * code that joins people as moderators.
71
+ */
72
+ createInvite(id: string, input?: {
73
+ role?: 'member' | 'moderator';
74
+ expires_days?: number;
75
+ }): Promise<SingleResponse<{
76
+ code: string;
77
+ community_id: string;
78
+ role: string;
79
+ expires_at: string | null;
80
+ }>>;
18
81
  }
19
- //# sourceMappingURL=communities.d.ts.map
@@ -3,7 +3,7 @@ export class CommunitiesResource {
3
3
  constructor(client) {
4
4
  this.client = client;
5
5
  }
6
- /** List public communities */
6
+ /** List public communities, or only the authenticated caller's memberships. */
7
7
  list(params) {
8
8
  return this.client.get('/communities', params);
9
9
  }
@@ -27,5 +27,65 @@ export class CommunitiesResource {
27
27
  leave(id) {
28
28
  return this.client.post(`/communities/${id}/leave`);
29
29
  }
30
+ /** Update name, description, image, banner or privacy. Owner or admin. */
31
+ update(id, input) {
32
+ return this.client.put(`/communities/${id}`, input);
33
+ }
34
+ /** Delete a community. Owner only. */
35
+ delete(id) {
36
+ return this.client.delete(`/communities/${id}`);
37
+ }
38
+ // ── Running the group: the tools an owner, admin or moderator has ────────
39
+ /** People waiting to join a private group. Moderator or higher. */
40
+ requests(id, params) {
41
+ return this.client.get(`/communities/${id}/requests`, params);
42
+ }
43
+ /** Active bans an admin can review and lift. Admin or higher. */
44
+ bans(id, params) {
45
+ return this.client.get(`/communities/${id}/bans`, params);
46
+ }
47
+ /** Let a pending member in. Admin or higher. */
48
+ approveMember(id, userId) {
49
+ return this.client.post(`/communities/${id}/members/${userId}/approve`);
50
+ }
51
+ /** Turn a pending member away. Admin or higher. */
52
+ declineMember(id, userId) {
53
+ return this.client.post(`/communities/${id}/members/${userId}/decline`);
54
+ }
55
+ /** Remove a member. Moderator or higher, and only members below your role. */
56
+ removeMember(id, userId) {
57
+ return this.client.delete(`/communities/${id}/members/${userId}`);
58
+ }
59
+ /** Ban a member, with an optional reason. Moderator or higher. */
60
+ banMember(id, userId, reason) {
61
+ return this.client.post(`/communities/${id}/members/${userId}/ban`, reason ? { reason } : {});
62
+ }
63
+ /** Lift a ban. Admin or higher. */
64
+ unbanMember(id, userId) {
65
+ return this.client.post(`/communities/${id}/members/${userId}/unban`);
66
+ }
67
+ /** Change a member's role. Admin or higher; only the owner makes admins. */
68
+ setMemberRole(id, userId, role) {
69
+ return this.client.patch(`/communities/${id}/members/${userId}`, { role });
70
+ }
71
+ /** Pin a post to the top of the group. Moderator or higher. */
72
+ pinPost(id, postId) {
73
+ return this.client.post(`/communities/${id}/posts/${postId}/pin`);
74
+ }
75
+ /** Unpin a post. Moderator or higher. */
76
+ unpinPost(id, postId) {
77
+ return this.client.delete(`/communities/${id}/posts/${postId}/pin`);
78
+ }
79
+ /** Remove a post from the group. Moderator or higher. */
80
+ removePost(id, postId) {
81
+ return this.client.delete(`/communities/${id}/posts/${postId}`);
82
+ }
83
+ /**
84
+ * Mint an invite code that joins the redeemer to this group. Any member of
85
+ * a public group; moderator or higher for a private one. Admins can mint a
86
+ * code that joins people as moderators.
87
+ */
88
+ createInvite(id, input) {
89
+ return this.client.post(`/communities/${id}/invites`, input ?? {});
90
+ }
30
91
  }
31
- //# sourceMappingURL=communities.js.map
@@ -147,4 +147,3 @@ export declare class CuratorResource {
147
147
  offset?: number;
148
148
  }): Promise<PaginatedResponse<Post>>;
149
149
  }
150
- //# sourceMappingURL=curator.d.ts.map
@@ -45,4 +45,3 @@ export class CuratorResource {
45
45
  return this.client.get('/curator/foryou', params);
46
46
  }
47
47
  }
48
- //# sourceMappingURL=curator.js.map
@@ -61,4 +61,3 @@ export declare class DatabasesResource {
61
61
  /** Execute a SQL query against a project's database */
62
62
  query(input: QueryDatabaseInput): Promise<SingleResponse<QueryResult>>;
63
63
  }
64
- //# sourceMappingURL=databases.d.ts.map
@@ -37,4 +37,3 @@ export class DatabasesResource {
37
37
  });
38
38
  }
39
39
  }
40
- //# sourceMappingURL=databases.js.map
@@ -58,4 +58,3 @@ export declare class DeploymentsResource {
58
58
  /** Delete production deployment for a project */
59
59
  delete(params: DeleteDeploymentParams): Promise<SingleResponse<unknown>>;
60
60
  }
61
- //# sourceMappingURL=deployments.d.ts.map
@@ -32,4 +32,3 @@ export class DeploymentsResource {
32
32
  return this.client.delete(`/deployments?project_id=${params.project_id}`);
33
33
  }
34
34
  }
35
- //# sourceMappingURL=deployments.js.map
@@ -15,6 +15,9 @@ export interface DispatcherTask {
15
15
  description: string | null;
16
16
  organization_id: string | null;
17
17
  goal_id: string | null;
18
+ /** What proves this task is done; null = undeclared. */
19
+ proof_type?: string | null;
20
+ proof_note?: string | null;
18
21
  created_at: string;
19
22
  updated_at: string;
20
23
  }
@@ -80,6 +83,10 @@ export interface CreateTaskInput {
80
83
  severity?: number;
81
84
  ui_impact?: number;
82
85
  score_override?: number;
86
+ /** What proves this task is done: machine_checked | expert_graded | scenario_tested | field_tested | exempt. */
87
+ proof_type?: string;
88
+ /** The check in words, or the reason for an exemption. */
89
+ proof_note?: string;
83
90
  created_by?: string;
84
91
  created_via?: string;
85
92
  }
@@ -104,6 +111,8 @@ export interface UpdateTaskInput {
104
111
  severity?: number;
105
112
  ui_impact?: number;
106
113
  score_override?: number;
114
+ proof_type?: string | null;
115
+ proof_note?: string | null;
107
116
  }
108
117
  export interface ListTasksParams extends PaginationParams {
109
118
  status?: string;
@@ -266,13 +275,21 @@ export declare class DispatcherResource {
266
275
  }): Promise<SingleResponse<{
267
276
  ok: true;
268
277
  }>>;
269
- /** Mark a task as done */
278
+ /**
279
+ * Mark a task as done. A task with a thresholded check that has no passing
280
+ * run refuses with 409 and the failing check names — run
281
+ * `evidence.runTaskChecks(taskId)` first. `override_reason` closes anyway
282
+ * and writes the reason to the activity log, permanently.
283
+ */
270
284
  complete(taskId: string, input?: {
271
285
  agent?: string;
272
286
  notes?: string;
273
287
  organization_id?: string;
288
+ override_reason?: string;
274
289
  }): Promise<SingleResponse<{
275
290
  ok: true;
291
+ /** Under the org's "Check and flag" policy: the checks that were failing when the task closed. */
292
+ check_warnings?: string[];
276
293
  }>>;
277
294
  /** Release a claim on a task */
278
295
  release(taskId: string, input?: {
@@ -367,4 +384,3 @@ export declare class DispatcherResource {
367
384
  retentionDays: number;
368
385
  }>>;
369
386
  }
370
- //# sourceMappingURL=dispatcher.d.ts.map
@@ -28,7 +28,12 @@ export class DispatcherResource {
28
28
  const { organization_id, ...body } = input;
29
29
  return this.client.post(`/dispatcher/heartbeat/${encodeURIComponent(taskId)}${orgQuery(organization_id)}`, body);
30
30
  }
31
- /** Mark a task as done */
31
+ /**
32
+ * Mark a task as done. A task with a thresholded check that has no passing
33
+ * run refuses with 409 and the failing check names — run
34
+ * `evidence.runTaskChecks(taskId)` first. `override_reason` closes anyway
35
+ * and writes the reason to the activity log, permanently.
36
+ */
32
37
  complete(taskId, input) {
33
38
  return this.client.post(`/dispatcher/done/${encodeURIComponent(taskId)}`, input ?? {});
34
39
  }
@@ -168,4 +173,3 @@ export class DispatcherResource {
168
173
  return this.client.post(`/dispatcher/webhooks/cleanup${query}`, {});
169
174
  }
170
175
  }
171
- //# sourceMappingURL=dispatcher.js.map
@@ -155,4 +155,3 @@ export declare class EmailResource {
155
155
  imported: number;
156
156
  }>>;
157
157
  }
158
- //# sourceMappingURL=email.d.ts.map
@@ -52,4 +52,3 @@ export class EmailResource {
52
52
  return this.client.post('/email/consents', input);
53
53
  }
54
54
  }
55
- //# sourceMappingURL=email.js.map
@@ -52,4 +52,3 @@ export declare class EnvVarsResource {
52
52
  deleted: boolean;
53
53
  }>>;
54
54
  }
55
- //# sourceMappingURL=env-vars.d.ts.map
@@ -24,4 +24,3 @@ export class EnvVarsResource {
24
24
  return this.client.delete(`/env-vars?${query.toString()}`);
25
25
  }
26
26
  }
27
- //# sourceMappingURL=env-vars.js.map
@@ -1,11 +1,16 @@
1
1
  import type { HttpClient } from '../client.js';
2
2
  import type { SingleResponse } from '../types.js';
3
- /** An agent or swarm being measured. */
3
+ /**
4
+ * What is being measured. Agent and swarm ids are UUIDs; a task id is the
5
+ * dispatcher's text id (e.g. "proj-fix-the-thing-ab12cd34"). A task target's
6
+ * evals are its CHECKS: they grade the task's close evidence, and a thresholded
7
+ * check without a passing run blocks `dispatcher.complete()`.
8
+ */
4
9
  export interface EvidenceTarget {
5
- type: 'agent' | 'swarm';
10
+ type: 'agent' | 'swarm' | 'task';
6
11
  id: string;
7
12
  }
8
- export type EvalType = 'code' | 'judge' | 'match' | 'consensus';
13
+ export type EvalType = 'code' | 'judge' | 'match' | 'consensus' | 'check';
9
14
  /** A first-class eval (scorer): code · judge · match · consensus. */
10
15
  export interface CreateEvalInput {
11
16
  target: EvidenceTarget;
@@ -33,6 +38,8 @@ export interface SimulateInput {
33
38
  run_type?: 'test' | 'real';
34
39
  scoring_mode?: 'exact' | 'judge';
35
40
  label?: string;
41
+ /** Attach the run to a project so it appears there, not only on the agent. */
42
+ project_id?: string;
36
43
  }
37
44
  export interface EvalRunRow {
38
45
  id: string;
@@ -144,6 +151,22 @@ export declare class EvidenceResource {
144
151
  * one call. Optionally attach evals inline. Returns the run + graded results.
145
152
  */
146
153
  simulate(input: SimulateInput): Promise<SingleResponse<SimulateResult>>;
154
+ /**
155
+ * Run a task's checks against its close evidence (title, latest claim notes,
156
+ * PR urls, commits) and record pass/fail where the dispatcher's close gate
157
+ * reads it. Run this before `dispatcher.complete()` on a checked task.
158
+ */
159
+ runTaskChecks(taskId: string): Promise<SingleResponse<{
160
+ evalRunId: string;
161
+ passed: number;
162
+ failed: number;
163
+ results: Array<{
164
+ name: string;
165
+ passed: boolean | null;
166
+ score: number | null;
167
+ reason: string;
168
+ }>;
169
+ }>>;
147
170
  /** Recent runs for a target. */
148
171
  listRuns(target: EvidenceTarget, limit?: number): Promise<{
149
172
  data: EvalRunRow[];
@@ -170,4 +193,3 @@ export declare class EvidenceResource {
170
193
  */
171
194
  recordDetail(target: EvidenceTarget, recordId: string, kind?: 'model_call' | 'tool_call'): Promise<SingleResponse<EvidenceRecordDetail>>;
172
195
  }
173
- //# sourceMappingURL=evidence.d.ts.map
@@ -18,6 +18,14 @@ export class EvidenceResource {
18
18
  simulate(input) {
19
19
  return this.client.post('/evidence/simulate', input);
20
20
  }
21
+ /**
22
+ * Run a task's checks against its close evidence (title, latest claim notes,
23
+ * PR urls, commits) and record pass/fail where the dispatcher's close gate
24
+ * reads it. Run this before `dispatcher.complete()` on a checked task.
25
+ */
26
+ runTaskChecks(taskId) {
27
+ return this.client.post('/evidence/task-checks/run', { task_id: taskId });
28
+ }
21
29
  /** Recent runs for a target. */
22
30
  listRuns(target, limit = 20) {
23
31
  return this.client.get(`/evidence/runs?target_type=${target.type}&target_id=${encodeURIComponent(target.id)}&limit=${limit}`);
@@ -47,4 +55,3 @@ export class EvidenceResource {
47
55
  return this.client.get(`/evidence/records/${recordId}?target_type=${target.type}&target_id=${encodeURIComponent(target.id)}&kind=${kind}`);
48
56
  }
49
57
  }
50
- //# sourceMappingURL=evidence.js.map
@@ -56,4 +56,3 @@ export declare class FreeTierResource {
56
56
  tier: string;
57
57
  }>>;
58
58
  }
59
- //# sourceMappingURL=free-tier.d.ts.map
@@ -24,4 +24,3 @@ export class FreeTierResource {
24
24
  return this.client.post('/free-tier/set-tier', input);
25
25
  }
26
26
  }
27
- //# sourceMappingURL=free-tier.js.map
@@ -77,4 +77,3 @@ export declare class GitHubResource {
77
77
  */
78
78
  createFromTemplate(params: CreateFromTemplateParams): Promise<SingleResponse<CreatedRepo>>;
79
79
  }
80
- //# sourceMappingURL=github.d.ts.map
@@ -31,4 +31,3 @@ export class GitHubResource {
31
31
  return this.client.post('/github/from-template', params);
32
32
  }
33
33
  }
34
- //# sourceMappingURL=github.js.map
@@ -89,4 +89,3 @@ export declare class GoalsResource {
89
89
  organization_id?: string;
90
90
  }): Promise<SingleResponse<Goal>>;
91
91
  }
92
- //# sourceMappingURL=goals.d.ts.map
@@ -36,4 +36,3 @@ export class GoalsResource {
36
36
  return this.client.delete(`/goals/${encodeURIComponent(goalId)}${query}`);
37
37
  }
38
38
  }
39
- //# sourceMappingURL=goals.js.map
@@ -53,4 +53,3 @@ export declare class HumanAsksResource {
53
53
  /** List asks in an organization, newest first. Open asks by default. */
54
54
  list(params?: ListHumanAsksParams): Promise<SingleResponse<HumanAsk[]>>;
55
55
  }
56
- //# sourceMappingURL=human-asks.d.ts.map
@@ -17,4 +17,3 @@ export class HumanAsksResource {
17
17
  return this.client.get('/human-asks', params);
18
18
  }
19
19
  }
20
- //# sourceMappingURL=human-asks.js.map
@@ -49,4 +49,3 @@ export declare class HumanInputResource {
49
49
  /** Has the human answered yet? */
50
50
  answers(conversationId: string): Promise<SingleResponse<HumanInputAnswers>>;
51
51
  }
52
- //# sourceMappingURL=human-input.d.ts.map
@@ -25,4 +25,3 @@ export class HumanInputResource {
25
25
  return this.client.get(`/human-input/${encodeURIComponent(conversationId)}`);
26
26
  }
27
27
  }
28
- //# sourceMappingURL=human-input.js.map
@@ -10,4 +10,3 @@ export declare class InboxResource {
10
10
  list(params?: ListInboxParams): Promise<SingleResponse<unknown>>;
11
11
  }
12
12
  export {};
13
- //# sourceMappingURL=inbox.d.ts.map
@@ -8,4 +8,3 @@ export class InboxResource {
8
8
  return this.client.get('/inbox', params);
9
9
  }
10
10
  }
11
- //# sourceMappingURL=inbox.js.map
@@ -202,4 +202,3 @@ export declare class IntegrationsResource {
202
202
  /** Reject a pending tool execution (integration or brain/platform tool) */
203
203
  rejectExecution(id: string): Promise<SuccessResponse>;
204
204
  }
205
- //# sourceMappingURL=integrations.d.ts.map
@@ -109,4 +109,3 @@ export class IntegrationsResource {
109
109
  return this.client.post(`/integrations/approvals/${id}/reject`);
110
110
  }
111
111
  }
112
- //# sourceMappingURL=integrations.js.map
@@ -66,4 +66,3 @@ export declare class InviteCodesAdminResource {
66
66
  offset?: number;
67
67
  }): Promise<PaginatedResponse<WaitlistEntry>>;
68
68
  }
69
- //# sourceMappingURL=invite-codes-admin.d.ts.map
@@ -28,4 +28,3 @@ export class InviteCodesAdminResource {
28
28
  return this.client.get('/invite-codes-admin/waitlist', params);
29
29
  }
30
30
  }
31
- //# sourceMappingURL=invite-codes-admin.js.map
@@ -163,4 +163,3 @@ export declare class InviteCodesResource {
163
163
  /** Admin: Get waitlist entries */
164
164
  getWaitlist(params?: WaitlistParams): Promise<PaginatedResponse<WaitlistEntry>>;
165
165
  }
166
- //# sourceMappingURL=invite-codes.d.ts.map
@@ -66,4 +66,3 @@ export class InviteCodesResource {
66
66
  return this.client.get('/invite-codes/admin/waitlist', params);
67
67
  }
68
68
  }
69
- //# sourceMappingURL=invite-codes.js.map
@@ -37,4 +37,3 @@ export declare class JobsResource {
37
37
  /** Delete a scheduled job */
38
38
  delete(id: string): Promise<DeleteResponse>;
39
39
  }
40
- //# sourceMappingURL=jobs.d.ts.map
@@ -20,4 +20,3 @@ export class JobsResource {
20
20
  return this.client.delete(`/jobs/${id}`);
21
21
  }
22
22
  }
23
- //# sourceMappingURL=jobs.js.map
@@ -23,4 +23,3 @@ export declare class LinkPreviewResource {
23
23
  */
24
24
  get(url: string): Promise<LinkPreviewResponse>;
25
25
  }
26
- //# sourceMappingURL=link-preview.d.ts.map
@@ -13,4 +13,3 @@ export class LinkPreviewResource {
13
13
  return this.client.get('/link-preview', { url });
14
14
  }
15
15
  }
16
- //# sourceMappingURL=link-preview.js.map
@@ -18,4 +18,3 @@ export declare class MediaResource {
18
18
  /** Generate an AI image and return a URL for use in posts */
19
19
  generateImage(input: GenerateImageInput): Promise<SingleResponse<GeneratedImage>>;
20
20
  }
21
- //# sourceMappingURL=media.d.ts.map
@@ -8,4 +8,3 @@ export class MediaResource {
8
8
  return this.client.post('/media/generate', input);
9
9
  }
10
10
  }
11
- //# sourceMappingURL=media.js.map
@@ -113,4 +113,3 @@ export declare class MemoryResource {
113
113
  }>>;
114
114
  }
115
115
  export {};
116
- //# sourceMappingURL=memory.d.ts.map
@@ -54,4 +54,3 @@ export class MemoryResource {
54
54
  return this.client.delete(`/memory/project/${projectId}`);
55
55
  }
56
56
  }
57
- //# sourceMappingURL=memory.js.map
@@ -97,4 +97,3 @@ export declare class ModerationResource {
97
97
  outcome: 'upheld' | 'overturned';
98
98
  }>>;
99
99
  }
100
- //# sourceMappingURL=moderation.d.ts.map
@@ -31,4 +31,3 @@ export class ModerationResource {
31
31
  return this.client.post(`/moderation/appeals/${encodeURIComponent(appealId)}/resolve`, input);
32
32
  }
33
33
  }
34
- //# sourceMappingURL=moderation.js.map
@@ -21,4 +21,3 @@ export declare class NetworkResource {
21
21
  getConfig(): Promise<SingleResponse<NetworkConfig>>;
22
22
  }
23
23
  export {};
24
- //# sourceMappingURL=network.d.ts.map
@@ -8,4 +8,3 @@ export class NetworkResource {
8
8
  return this.client.get('/network/config');
9
9
  }
10
10
  }
11
- //# sourceMappingURL=network.js.map
@@ -12,11 +12,24 @@ export interface Notification {
12
12
  created_at: string;
13
13
  read_at: string | null;
14
14
  }
15
+ export type NotificationCategory = 'all' | 'social' | 'system';
15
16
  export interface ListNotificationsParams extends PaginationParams {
16
17
  status?: 'unread' | 'read' | 'all';
17
18
  cursor?: string;
18
19
  /** Scope to a specific organization. Recommended for app clients to avoid cross-org notification leaks. */
19
20
  organization_id?: string;
21
+ /**
22
+ * Which kind of notification to return. Defaults to `all`.
23
+ *
24
+ * `social` is what a person did to you (follows, replies, reactions,
25
+ * reposts, mentions, chat, community invites/joins). `system` is everything
26
+ * operational (agent, task, deploy, billing, security).
27
+ *
28
+ * Ask for it here rather than filtering the page you get back: the server
29
+ * applies the limit AFTER the category, so a client that filters afterwards
30
+ * on an account which also runs agents can be left with almost no rows.
31
+ */
32
+ category?: NotificationCategory;
20
33
  }
21
34
  export interface NotificationListResponse {
22
35
  data: Notification[];
@@ -33,10 +46,9 @@ export declare class NotificationsResource {
33
46
  /** Mark a single notification as read */
34
47
  markAsRead(notificationId: string): Promise<SuccessResponse>;
35
48
  /** Mark all notifications as read */
36
- markAllAsRead(): Promise<SuccessResponse>;
49
+ markAllAsRead(category?: NotificationCategory): Promise<SuccessResponse>;
37
50
  /** Register a push notification token for the current user */
38
51
  registerToken(input: RegisterTokenInput): Promise<SuccessResponse>;
39
52
  /** Unregister a push notification token (e.g., on logout) */
40
53
  unregisterToken(token: string): Promise<SuccessResponse>;
41
54
  }
42
- //# sourceMappingURL=notifications.d.ts.map
@@ -12,8 +12,11 @@ export class NotificationsResource {
12
12
  return this.client.post(`/notifications/${notificationId}/read`);
13
13
  }
14
14
  /** Mark all notifications as read */
15
- markAllAsRead() {
16
- return this.client.post('/notifications/read-all');
15
+ markAllAsRead(category) {
16
+ const path = category && category !== 'all'
17
+ ? `/notifications/read-all?category=${encodeURIComponent(category)}`
18
+ : '/notifications/read-all';
19
+ return this.client.post(path);
17
20
  }
18
21
  /** Register a push notification token for the current user */
19
22
  registerToken(input) {
@@ -45,4 +48,3 @@ export class NotificationsResource {
45
48
  return response.json();
46
49
  }
47
50
  }
48
- //# sourceMappingURL=notifications.js.map
@@ -26,4 +26,3 @@ export declare class OrganizationSecurityResource {
26
26
  success: true;
27
27
  }>>;
28
28
  }
29
- //# sourceMappingURL=organization-security.d.ts.map
@@ -12,4 +12,3 @@ export class OrganizationSecurityResource {
12
12
  return this.client.put(`/organization-security/${organizationId}/security`, input);
13
13
  }
14
14
  }
15
- //# sourceMappingURL=organization-security.js.map