@anchrd/colab-sdk 0.1.30 → 0.1.31

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.
@@ -114,6 +114,13 @@ export declare const ActionGadget: z.ZodObject<{
114
114
  hint: z.ZodBoolean;
115
115
  }, z.core.$strip>;
116
116
  export type ActionGadget = z.infer<typeof ActionGadget>;
117
+ export declare const ActionSource: z.ZodObject<{
118
+ problem: z.ZodLiteral<"access">;
119
+ status: z.ZodNullable<z.ZodNumber>;
120
+ message: z.ZodString;
121
+ hint: z.ZodBoolean;
122
+ }, z.core.$strip>;
123
+ export type ActionSource = z.infer<typeof ActionSource>;
117
124
  export declare const ActionItem: z.ZodObject<{
118
125
  node: z.ZodObject<{
119
126
  nodeId: z.ZodTemplateLiteral<`node_${string}`>;
@@ -127,6 +134,7 @@ export declare const ActionItem: z.ZodObject<{
127
134
  gadget: "gadget";
128
135
  goal: "goal";
129
136
  skill: "skill";
137
+ source: "source";
130
138
  }>;
131
139
  name: z.ZodString;
132
140
  path: z.ZodObject<{
@@ -235,6 +243,12 @@ export declare const ActionItem: z.ZodObject<{
235
243
  }>;
236
244
  hint: z.ZodBoolean;
237
245
  }, z.core.$strip>>;
246
+ source: z.ZodOptional<z.ZodNullable<z.ZodObject<{
247
+ problem: z.ZodLiteral<"access">;
248
+ status: z.ZodNullable<z.ZodNumber>;
249
+ message: z.ZodString;
250
+ hint: z.ZodBoolean;
251
+ }, z.core.$strip>>>;
238
252
  }, z.core.$strip>;
239
253
  export type ActionItem = z.infer<typeof ActionItem>;
240
254
  export declare const ActionAbortReason: z.ZodEnum<{
@@ -604,6 +618,7 @@ export declare const ActionRow: z.ZodUnion<readonly [z.ZodObject<{
604
618
  gadget: "gadget";
605
619
  goal: "goal";
606
620
  skill: "skill";
621
+ source: "source";
607
622
  }>;
608
623
  name: z.ZodString;
609
624
  path: z.ZodObject<{
@@ -712,6 +727,12 @@ export declare const ActionRow: z.ZodUnion<readonly [z.ZodObject<{
712
727
  }>;
713
728
  hint: z.ZodBoolean;
714
729
  }, z.core.$strip>>;
730
+ source: z.ZodOptional<z.ZodNullable<z.ZodObject<{
731
+ problem: z.ZodLiteral<"access">;
732
+ status: z.ZodNullable<z.ZodNumber>;
733
+ message: z.ZodString;
734
+ hint: z.ZodBoolean;
735
+ }, z.core.$strip>>>;
715
736
  }, z.core.$strip>, z.ZodObject<{
716
737
  notice: z.ZodObject<{
717
738
  package: z.ZodEnum<{
@@ -867,6 +888,7 @@ export declare const ActionList: z.ZodObject<{
867
888
  gadget: "gadget";
868
889
  goal: "goal";
869
890
  skill: "skill";
891
+ source: "source";
870
892
  }>;
871
893
  name: z.ZodString;
872
894
  path: z.ZodObject<{
@@ -975,6 +997,12 @@ export declare const ActionList: z.ZodObject<{
975
997
  }>;
976
998
  hint: z.ZodBoolean;
977
999
  }, z.core.$strip>>;
1000
+ source: z.ZodOptional<z.ZodNullable<z.ZodObject<{
1001
+ problem: z.ZodLiteral<"access">;
1002
+ status: z.ZodNullable<z.ZodNumber>;
1003
+ message: z.ZodString;
1004
+ hint: z.ZodBoolean;
1005
+ }, z.core.$strip>>>;
978
1006
  }, z.core.$strip>, z.ZodObject<{
979
1007
  notice: z.ZodObject<{
980
1008
  package: z.ZodEnum<{
@@ -82,6 +82,15 @@ export const ActionGadget = z.object({
82
82
  // Nobody is responsible: the row reaches the publisher only to name one.
83
83
  hint: z.boolean(),
84
84
  });
85
+ // A source whose provider refused its key (#900, E151, Nodes › Quelle › Läufe): its queries pause,
86
+ // and its responsible (its publisher while nobody is) sets the key anew under Einstellungen › Zugang.
87
+ export const ActionSource = z.object({
88
+ problem: z.literal("access"),
89
+ // The provider's status, 401 or 403.
90
+ status: z.number().int().nullable(),
91
+ message: z.string(),
92
+ hint: z.boolean(),
93
+ });
85
94
  // One row: the node, where it waits, since when, and what makes it wait. Exactly one of task and
86
95
  // gadget, or none of them on a row that is a chat alone; chat beside either.
87
96
  export const ActionItem = z.object({
@@ -106,6 +115,8 @@ export const ActionItem = z.object({
106
115
  task: ActionTask.nullable(),
107
116
  chat: ActionChat.nullable(),
108
117
  gadget: ActionGadget.nullable(),
118
+ // Left out on every row that is no source's.
119
+ source: ActionSource.nullable().optional(),
109
120
  });
110
121
  // What another package puts into a person's Actions (#334, E81, E82): "access invalid" for every
111
122
  // admin, "Operator paused" for its responsible person. Gathered when asked like every row, never
@@ -473,6 +473,7 @@ export declare const BoardTaskItem: z.ZodObject<{
473
473
  gadget: "gadget";
474
474
  goal: "goal";
475
475
  skill: "skill";
476
+ source: "source";
476
477
  }>;
477
478
  path: z.ZodObject<{
478
479
  section: z.ZodEnum<{
@@ -575,6 +576,7 @@ export declare const BoardTaskList: z.ZodObject<{
575
576
  gadget: "gadget";
576
577
  goal: "goal";
577
578
  skill: "skill";
579
+ source: "source";
578
580
  }>;
579
581
  path: z.ZodObject<{
580
582
  section: z.ZodEnum<{
@@ -903,6 +905,7 @@ export declare const TaskDetail: z.ZodObject<{
903
905
  gadget: "gadget";
904
906
  goal: "goal";
905
907
  skill: "skill";
908
+ source: "source";
906
909
  }>;
907
910
  name: z.ZodString;
908
911
  path: z.ZodObject<{
@@ -149,6 +149,7 @@ export declare const GoalCheck: z.ZodObject<{
149
149
  gadget: "gadget";
150
150
  goal: "goal";
151
151
  skill: "skill";
152
+ source: "source";
152
153
  }>>;
153
154
  needs: z.ZodNullable<z.ZodEnum<{
154
155
  write: "write";
@@ -219,6 +220,7 @@ export declare const GoalReady: z.ZodObject<{
219
220
  gadget: "gadget";
220
221
  goal: "goal";
221
222
  skill: "skill";
223
+ source: "source";
222
224
  }>>;
223
225
  needs: z.ZodNullable<z.ZodEnum<{
224
226
  write: "write";
@@ -739,6 +741,7 @@ export declare const GoalDetail: z.ZodObject<{
739
741
  gadget: "gadget";
740
742
  goal: "goal";
741
743
  skill: "skill";
744
+ source: "source";
742
745
  }>>;
743
746
  needs: z.ZodNullable<z.ZodEnum<{
744
747
  write: "write";
@@ -37,6 +37,9 @@ export declare const resources: {
37
37
  readonly step: "steps";
38
38
  readonly crawl: "crawls";
39
39
  readonly mcp: "mcps";
40
+ readonly source: "sources";
41
+ readonly query: "queries";
42
+ readonly item: "items";
40
43
  };
41
44
  export declare const actions: readonly ["list", "get", "create", "update", "archive", "restore", "purge"];
42
45
  export declare const verbs: readonly ["invite", "resend", "disable", "enable", "rotate", "share", "move", "start", "complete", "test", "revoke", "remove", "unlock", "publish", "schedule", "unpublish", "cancel"];
@@ -72,6 +72,12 @@ export const resources = {
72
72
  // A person's own MCP server for their personal Operators (#802, E144, Einstellungen › MCPs):
73
73
  // `operator_mcp_*`, its protocol `operator_mcp_call_list`. Named by the ticket and the page.
74
74
  mcp: "mcps",
75
+ // A node that fetches data from outside on a schedule and keeps it (#900, E151, Nodes › Quelle):
76
+ // `intelligence_source_*`; what it fetches is a query (`intelligence_source_query_*`), what it
77
+ // keeps an item (`intelligence_source_item_list`). Named by the ticket.
78
+ source: "sources",
79
+ query: "queries",
80
+ item: "items",
75
81
  };
76
82
  // The closed list of actions with a route of their own shape.
77
83
  export const actions = ["list", "get", "create", "update", "archive", "restore", "purge"];
@@ -7,7 +7,7 @@ export declare const SecretFields: {
7
7
  secret: z.ZodOptional<z.ZodLiteral<true>>;
8
8
  locked: z.ZodOptional<z.ZodBoolean>;
9
9
  };
10
- export declare const nodeKinds: readonly ["folder", "document", "table", "board", "task", "file", "gadget", "goal", "skill"];
10
+ export declare const nodeKinds: readonly ["folder", "document", "table", "board", "task", "file", "gadget", "goal", "skill", "source"];
11
11
  export declare const NodeKind: z.ZodEnum<{
12
12
  file: "file";
13
13
  folder: "folder";
@@ -18,6 +18,7 @@ export declare const NodeKind: z.ZodEnum<{
18
18
  gadget: "gadget";
19
19
  goal: "goal";
20
20
  skill: "skill";
21
+ source: "source";
21
22
  }>;
22
23
  export type NodeKind = z.infer<typeof NodeKind>;
23
24
  export declare const responsibleKinds: readonly ["document", "table", "file"];
@@ -101,6 +102,7 @@ export declare const NodeListItem: z.ZodObject<{
101
102
  gadget: "gadget";
102
103
  goal: "goal";
103
104
  skill: "skill";
105
+ source: "source";
104
106
  }>;
105
107
  name: z.ZodString;
106
108
  hidden: z.ZodBoolean;
@@ -172,6 +174,7 @@ export declare const NodeList: z.ZodObject<{
172
174
  gadget: "gadget";
173
175
  goal: "goal";
174
176
  skill: "skill";
177
+ source: "source";
175
178
  }>;
176
179
  name: z.ZodString;
177
180
  hidden: z.ZodBoolean;
@@ -268,6 +271,7 @@ export declare const NodeHit: z.ZodObject<{
268
271
  gadget: "gadget";
269
272
  goal: "goal";
270
273
  skill: "skill";
274
+ source: "source";
271
275
  }>;
272
276
  name: z.ZodString;
273
277
  path: z.ZodObject<{
@@ -340,6 +344,7 @@ export declare const NodeSearch: z.ZodObject<{
340
344
  gadget: "gadget";
341
345
  goal: "goal";
342
346
  skill: "skill";
347
+ source: "source";
343
348
  }>;
344
349
  name: z.ZodString;
345
350
  path: z.ZodObject<{
@@ -471,6 +476,7 @@ export declare const NodeDetail: z.ZodObject<{
471
476
  gadget: "gadget";
472
477
  goal: "goal";
473
478
  skill: "skill";
479
+ source: "source";
474
480
  }>;
475
481
  name: z.ZodString;
476
482
  hidden: z.ZodBoolean;
@@ -39,6 +39,8 @@ export const nodeKinds = [
39
39
  "goal",
40
40
  // #817, E140: how something is done well, with its result, trigger and tests.
41
41
  "skill",
42
+ // #900, E151: fetches data from outside on a schedule and keeps it as items.
43
+ "source",
42
44
  ];
43
45
  export const NodeKind = z.enum(nodeKinds);
44
46
  // Only these kinds have a responsible person (E32): the one who answers for the content's validity.
package/dist/sdk.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- export { ActionAbort, ActionAbortReason, ActionChat, ActionGadget, ActionItem, ActionList, ActionListInput, ActionNotice, ActionNoticeButton, ActionNoticeCrumb, ActionNoticeItem, ActionNoticeKind, ActionNoticeReason, ActionNoticeTitle, ActionRow, ActionRunTask, ActionSection, ActionTask, actionFilters, isNodeRow, MachineInstructions, MachineInstructionsRead, } from "./actions/actions.js";
1
+ export { ActionAbort, ActionAbortReason, ActionChat, ActionGadget, ActionItem, ActionList, ActionListInput, ActionNotice, ActionNoticeButton, ActionNoticeCrumb, ActionNoticeItem, ActionNoticeKind, ActionNoticeReason, ActionNoticeTitle, ActionRow, ActionRunTask, ActionSection, ActionSource, ActionTask, actionFilters, isNodeRow, MachineInstructions, MachineInstructionsRead, } from "./actions/actions.js";
2
2
  export { adminModeHeader, adminModeOn } from "./admin-mode.js";
3
3
  export { App, AppId, AppList, AppListInput, AppRevoked, AppRevokeInput, OwnAppListQuery, OwnSessionListQuery, Session, SessionId, SessionList, SessionListInput, SessionRevokeInput, SessionsRevoked, } from "./apps/apps.js";
4
4
  export { NodeArchived, NodeArchiveInput, NodePurged, NodePurgeInput, NodeRestoreInput, } from "./archive/archive.js";
@@ -44,6 +44,7 @@ export { NodeSecret, NodeSecretCreateInput, NodeSecretDetail, NodeSecretGetInput
44
44
  export { type Authorized, type AuthorizeResult, createServiceClient, type InterfaceDeclaredResult, type InterfaceRemovedResult, type ServiceClient, type ServiceClientDeps, type ServiceClientFailure, } from "./service-client/service-client.js";
45
45
  export { ConsentResource, FunctionId, InterfaceId, RightWord, Service, ServiceArchiveInput, ServiceCreateInput, ServiceFunction, ServiceId, ServiceInterface, ServiceKeyIssued, ServiceList, ServiceListInput, ServiceName, ServicePurged, ServicePurgeInput, ServiceRestoreInput, ServiceRotateInput, ServiceUpdateInput, } from "./services/services.js";
46
46
  export { SkillCaseResult, SkillCreateInput, SkillDetail, SkillFields, SkillFile, SkillFilePath, SkillGetInput, SkillId, SkillOffer, SkillPoint, SkillRunCall, SkillRunDetail, SkillRunGetInput, SkillRunItem, SkillRunList, SkillRunListInput, SkillTestInput, SkillTestReport, SkillTokens, SkillTriggerHit, SkillUpdateInput, skillCaseStatuses, skillFilePattern, skillRunKinds, skillRunStatuses, } from "./skills/skills.js";
47
+ export { ItemId, QueryId, SourceAccess, SourceCreateInput, SourceDetail, SourceField, SourceFieldType, SourceGetInput, SourceItem, SourceItemList, SourceItemListInput, SourceManifest, SourcePaging, SourceParam, SourcePath, SourceProbe, SourcePublishInput, SourceQuery, SourceQueryArchiveInput, SourceQueryCreateInput, SourceQueryList, SourceQueryListInput, SourceQueryRestoreInput, SourceQueryUpdateInput, SourceRun, SourceRunCounts, SourceRunCreateInput, SourceRunFailure, SourceRunGetInput, SourceRunList, SourceRunListInput, SourceSchedule, SourceSecretsInput, SourceStep, SourceTestInput, SourceUpdateInput, SourceVersionRef, SourceWhere, sourceCleans, sourceCodePath, sourceEvery, sourceFieldTypes, sourceKeepDays, sourceLimits, sourceManifestPath, sourceSchema, } from "./sources/sources.js";
47
48
  export { SignInProviders, Sso, SsoId, SsoList, SsoListInput, SsoRemoveInput, SsoSource, SsoUpdateInput, ssoIds, } from "./sso/sso.js";
48
49
  export { TableColumn, TableColumnChange, TableColumnType, TableCreateInput, TableDetail, TableExcerpt, TableGetInput, TableId, TableSaved, TableUpdateInput, tableColumnTypes, tableFormats, } from "./tables/tables.js";
49
50
  export { type Actor, defineTool, type Permission, type Tool, type ToolAnnotations, type ToolContext, type ToolInput, type ToolSource, } from "./tool.js";
package/dist/sdk.js CHANGED
@@ -1,7 +1,7 @@
1
1
  // The contract between UI, backends and outside services, published as `@anchrd/colab-sdk`. The
2
2
  // package exports only this file, so everything public is named here once.
3
3
  // biome-ignore lint/performance/noBarrelFile: this file IS the entry point of the package.
4
- export { ActionAbort, ActionAbortReason, ActionChat, ActionGadget, ActionItem, ActionList, ActionListInput, ActionNotice, ActionNoticeButton, ActionNoticeCrumb, ActionNoticeItem, ActionNoticeKind, ActionNoticeReason, ActionNoticeTitle, ActionRow, ActionRunTask, ActionSection, ActionTask, actionFilters, isNodeRow, MachineInstructions, MachineInstructionsRead, } from "./actions/actions.js";
4
+ export { ActionAbort, ActionAbortReason, ActionChat, ActionGadget, ActionItem, ActionList, ActionListInput, ActionNotice, ActionNoticeButton, ActionNoticeCrumb, ActionNoticeItem, ActionNoticeKind, ActionNoticeReason, ActionNoticeTitle, ActionRow, ActionRunTask, ActionSection, ActionSource, ActionTask, actionFilters, isNodeRow, MachineInstructions, MachineInstructionsRead, } from "./actions/actions.js";
5
5
  export { adminModeHeader, adminModeOn } from "./admin-mode.js";
6
6
  export { App, AppId, AppList, AppListInput, AppRevoked, AppRevokeInput, OwnAppListQuery, OwnSessionListQuery, Session, SessionId, SessionList, SessionListInput, SessionRevokeInput, SessionsRevoked, } from "./apps/apps.js";
7
7
  export { NodeArchived, NodeArchiveInput, NodePurged, NodePurgeInput, NodeRestoreInput, } from "./archive/archive.js";
@@ -47,6 +47,7 @@ export { NodeSecret, NodeSecretCreateInput, NodeSecretDetail, NodeSecretGetInput
47
47
  export { createServiceClient, } from "./service-client/service-client.js";
48
48
  export { ConsentResource, FunctionId, InterfaceId, RightWord, Service, ServiceArchiveInput, ServiceCreateInput, ServiceFunction, ServiceId, ServiceInterface, ServiceKeyIssued, ServiceList, ServiceListInput, ServiceName, ServicePurged, ServicePurgeInput, ServiceRestoreInput, ServiceRotateInput, ServiceUpdateInput, } from "./services/services.js";
49
49
  export { SkillCaseResult, SkillCreateInput, SkillDetail, SkillFields, SkillFile, SkillFilePath, SkillGetInput, SkillId, SkillOffer, SkillPoint, SkillRunCall, SkillRunDetail, SkillRunGetInput, SkillRunItem, SkillRunList, SkillRunListInput, SkillTestInput, SkillTestReport, SkillTokens, SkillTriggerHit, SkillUpdateInput, skillCaseStatuses, skillFilePattern, skillRunKinds, skillRunStatuses, } from "./skills/skills.js";
50
+ export { ItemId, QueryId, SourceAccess, SourceCreateInput, SourceDetail, SourceField, SourceFieldType, SourceGetInput, SourceItem, SourceItemList, SourceItemListInput, SourceManifest, SourcePaging, SourceParam, SourcePath, SourceProbe, SourcePublishInput, SourceQuery, SourceQueryArchiveInput, SourceQueryCreateInput, SourceQueryList, SourceQueryListInput, SourceQueryRestoreInput, SourceQueryUpdateInput, SourceRun, SourceRunCounts, SourceRunCreateInput, SourceRunFailure, SourceRunGetInput, SourceRunList, SourceRunListInput, SourceSchedule, SourceSecretsInput, SourceStep, SourceTestInput, SourceUpdateInput, SourceVersionRef, SourceWhere, sourceCleans, sourceCodePath, sourceEvery, sourceFieldTypes, sourceKeepDays, sourceLimits, sourceManifestPath, sourceSchema, } from "./sources/sources.js";
50
51
  export { SignInProviders, Sso, SsoId, SsoList, SsoListInput, SsoRemoveInput, SsoSource, SsoUpdateInput, ssoIds, } from "./sso/sso.js";
51
52
  export { TableColumn, TableColumnChange, TableColumnType, TableCreateInput, TableDetail, TableExcerpt, TableGetInput, TableId, TableSaved, TableUpdateInput, tableColumnTypes, tableFormats, } from "./tables/tables.js";
52
53
  export { defineTool, } from "./tool.js";