@intentic/sandbox-contract 1.316.0 → 1.317.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/contracts/agent.contract.d.ts +561 -0
- package/dist/contracts/agent.contract.d.ts.map +1 -1
- package/dist/contracts/agents.contract.d.ts +402 -0
- package/dist/contracts/agents.contract.d.ts.map +1 -1
- package/dist/contracts/capabilities.contract.d.ts +16 -0
- package/dist/contracts/capabilities.contract.d.ts.map +1 -1
- package/dist/contracts/capabilities.contract.js +10 -1
- package/dist/contracts/capabilities.contract.js.map +1 -1
- package/dist/contracts/device.contract.d.ts +1 -0
- package/dist/contracts/device.contract.d.ts.map +1 -1
- package/dist/contracts/needs.contract.d.ts +532 -0
- package/dist/contracts/needs.contract.d.ts.map +1 -0
- package/dist/contracts/needs.contract.js +80 -0
- package/dist/contracts/needs.contract.js.map +1 -0
- package/dist/contracts/runner.contract.d.ts +294 -122
- package/dist/contracts/runner.contract.d.ts.map +1 -1
- package/dist/contracts/secrets.contract.d.ts +16 -0
- package/dist/contracts/secrets.contract.d.ts.map +1 -1
- package/dist/contracts/secrets.contract.js +12 -2
- package/dist/contracts/secrets.contract.js.map +1 -1
- package/dist/contracts/sessions.contract.d.ts +79 -0
- package/dist/contracts/sessions.contract.d.ts.map +1 -1
- package/dist/contracts/settings.contract.d.ts +2 -0
- package/dist/contracts/settings.contract.d.ts.map +1 -1
- package/dist/contracts/system.contract.d.ts +160 -0
- package/dist/contracts/system.contract.d.ts.map +1 -1
- package/dist/contracts/system.contract.js +11 -0
- package/dist/contracts/system.contract.js.map +1 -1
- package/dist/events/agent-events.d.ts +309 -0
- package/dist/events/agent-events.d.ts.map +1 -1
- package/dist/events/agent-events.js +2 -0
- package/dist/events/agent-events.js.map +1 -1
- package/dist/events/agent-words.d.ts.map +1 -1
- package/dist/events/agent-words.js +2 -1
- package/dist/events/agent-words.js.map +1 -1
- package/dist/events/need-wake.d.ts +17 -0
- package/dist/events/need-wake.d.ts.map +1 -0
- package/dist/events/need-wake.js +34 -0
- package/dist/events/need-wake.js.map +1 -0
- package/dist/events/system-events.d.ts +38 -0
- package/dist/events/system-events.d.ts.map +1 -1
- package/dist/events/transcript.d.ts +484 -0
- package/dist/events/transcript.d.ts.map +1 -1
- package/dist/events/transcript.js +9 -0
- package/dist/events/transcript.js.map +1 -1
- package/dist/index.d.ts +1826 -55
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +6 -0
- package/dist/index.js.map +1 -1
- package/dist/protocol/raw-routes.d.ts +0 -5
- package/dist/protocol/raw-routes.d.ts.map +1 -1
- package/dist/protocol/raw-routes.js +0 -1
- package/dist/protocol/raw-routes.js.map +1 -1
- package/dist/schemas/agents.d.ts +58 -0
- package/dist/schemas/agents.d.ts.map +1 -1
- package/dist/schemas/agents.js +9 -0
- package/dist/schemas/agents.js.map +1 -1
- package/dist/schemas/automations.d.ts +19 -0
- package/dist/schemas/automations.d.ts.map +1 -1
- package/dist/schemas/capabilities.d.ts +19 -0
- package/dist/schemas/capabilities.d.ts.map +1 -1
- package/dist/schemas/capabilities.js +16 -0
- package/dist/schemas/capabilities.js.map +1 -1
- package/dist/schemas/devices.d.ts +68 -0
- package/dist/schemas/devices.d.ts.map +1 -1
- package/dist/schemas/devices.js +7 -0
- package/dist/schemas/devices.js.map +1 -1
- package/dist/schemas/hosts.d.ts +2 -0
- package/dist/schemas/hosts.d.ts.map +1 -1
- package/dist/schemas/hosts.js +2 -1
- package/dist/schemas/hosts.js.map +1 -1
- package/dist/schemas/needs.d.ts +661 -0
- package/dist/schemas/needs.d.ts.map +1 -0
- package/dist/schemas/needs.js +196 -0
- package/dist/schemas/needs.js.map +1 -0
- package/dist/schemas/secrets.d.ts +18 -0
- package/dist/schemas/secrets.d.ts.map +1 -1
- package/dist/schemas/secrets.js +20 -0
- package/dist/schemas/secrets.js.map +1 -1
- package/dist/schemas/settings.d.ts +2 -0
- package/dist/schemas/settings.d.ts.map +1 -1
- package/dist/schemas/settings.js +4 -0
- package/dist/schemas/settings.js.map +1 -1
- package/dist/schemas/state-plan.d.ts +1 -0
- package/dist/schemas/state-plan.d.ts.map +1 -1
- package/dist/schemas/state-plan.js +3 -1
- package/dist/schemas/state-plan.js.map +1 -1
- package/dist/schemas/system.d.ts +20 -0
- package/dist/schemas/system.d.ts.map +1 -1
- package/dist/schemas/system.js +7 -0
- package/dist/schemas/system.js.map +1 -1
- package/dist/schemas/updates.d.ts +39 -0
- package/dist/schemas/updates.d.ts.map +1 -0
- package/dist/schemas/updates.js +31 -0
- package/dist/schemas/updates.js.map +1 -0
- package/dist/state/definition.d.ts +16 -0
- package/dist/state/definition.d.ts.map +1 -1
- package/dist/state/history-state.d.ts.map +1 -1
- package/dist/state/history-state.js +3 -0
- package/dist/state/history-state.js.map +1 -1
- package/dist/state/workspace-state.d.ts +4 -0
- package/dist/state/workspace-state.d.ts.map +1 -1
- package/dist/state/workspace-state.js +1 -0
- package/dist/state/workspace-state.js.map +1 -1
- package/dist/text/transcript-fold.d.ts.map +1 -1
- package/dist/text/transcript-fold.js +3 -0
- package/dist/text/transcript-fold.js.map +1 -1
- package/package.json +5 -5
- package/src/contracts/capabilities.contract.ts +14 -1
- package/src/contracts/needs.contract.ts +103 -0
- package/src/contracts/secrets.contract.ts +17 -3
- package/src/contracts/system.contract.ts +14 -0
- package/src/events/agent-events.ts +4 -0
- package/src/events/agent-words.ts +2 -1
- package/src/events/need-wake.test.ts +55 -0
- package/src/events/need-wake.ts +71 -0
- package/src/events/transcript.ts +16 -0
- package/src/index.ts +6 -0
- package/src/protocol/raw-routes.ts +1 -2
- package/src/schemas/agents.ts +14 -1
- package/src/schemas/capabilities.ts +28 -0
- package/src/schemas/devices.ts +17 -0
- package/src/schemas/hosts.ts +4 -1
- package/src/schemas/needs.ts +292 -0
- package/src/schemas/secrets.ts +23 -0
- package/src/schemas/settings.ts +8 -0
- package/src/schemas/state-plan.ts +8 -1
- package/src/schemas/system.ts +15 -0
- package/src/schemas/updates.ts +56 -0
- package/src/state/history-state.ts +5 -0
- package/src/state/workspace-state.ts +4 -0
- package/src/text/transcript-fold.ts +4 -0
|
@@ -0,0 +1,532 @@
|
|
|
1
|
+
export declare const needsContract: {
|
|
2
|
+
ask: import("@orpc/contract").ContractProcedureBuilderWithInputOutput<import("zod").ZodObject<{
|
|
3
|
+
ask: import("zod").ZodDiscriminatedUnion<[import("zod").ZodObject<{
|
|
4
|
+
kind: import("zod").ZodLiteral<"capability">;
|
|
5
|
+
entry: import("zod").ZodString;
|
|
6
|
+
target: import("zod").ZodOptional<import("zod").ZodString>;
|
|
7
|
+
set: import("zod").ZodOptional<import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodString>>;
|
|
8
|
+
reconnect: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
9
|
+
}, import("zod/v4/core").$strip>, import("zod").ZodObject<{
|
|
10
|
+
kind: import("zod").ZodLiteral<"secret">;
|
|
11
|
+
name: import("zod").ZodString;
|
|
12
|
+
where: import("zod").ZodOptional<import("zod").ZodString>;
|
|
13
|
+
link: import("zod").ZodOptional<import("zod").ZodString>;
|
|
14
|
+
hint: import("zod").ZodOptional<import("zod").ZodString>;
|
|
15
|
+
replace: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
16
|
+
}, import("zod/v4/core").$strip>, import("zod").ZodObject<{
|
|
17
|
+
kind: import("zod").ZodLiteral<"grant">;
|
|
18
|
+
subject: import("zod").ZodEnum<{
|
|
19
|
+
capability: "capability";
|
|
20
|
+
folder: "folder";
|
|
21
|
+
shelf: "shelf";
|
|
22
|
+
site: "site";
|
|
23
|
+
}>;
|
|
24
|
+
what: import("zod").ZodString;
|
|
25
|
+
}, import("zod/v4/core").$strip>, import("zod").ZodObject<{
|
|
26
|
+
kind: import("zod").ZodLiteral<"release">;
|
|
27
|
+
subject: import("zod").ZodString;
|
|
28
|
+
}, import("zod/v4/core").$strip>, import("zod").ZodObject<{
|
|
29
|
+
kind: import("zod").ZodLiteral<"environment">;
|
|
30
|
+
tool: import("zod").ZodString;
|
|
31
|
+
steps: import("zod").ZodString;
|
|
32
|
+
}, import("zod/v4/core").$strip>], "kind">;
|
|
33
|
+
why: import("zod").ZodOptional<import("zod").ZodString>;
|
|
34
|
+
wait: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
35
|
+
}, import("zod/v4/core").$strip>, import("zod").ZodObject<{
|
|
36
|
+
state: import("zod").ZodEnum<{
|
|
37
|
+
met: "met";
|
|
38
|
+
open: "open";
|
|
39
|
+
refused: "refused";
|
|
40
|
+
}>;
|
|
41
|
+
message: import("zod").ZodString;
|
|
42
|
+
need: import("zod").ZodOptional<import("zod").ZodObject<{
|
|
43
|
+
id: import("zod").ZodString;
|
|
44
|
+
conversationId: import("zod").ZodString;
|
|
45
|
+
subject: import("zod").ZodDiscriminatedUnion<[import("zod").ZodObject<{
|
|
46
|
+
kind: import("zod").ZodLiteral<"capability">;
|
|
47
|
+
entry: import("zod").ZodString;
|
|
48
|
+
name: import("zod").ZodString;
|
|
49
|
+
mode: import("zod").ZodEnum<{
|
|
50
|
+
change: "change";
|
|
51
|
+
connect: "connect";
|
|
52
|
+
reconnect: "reconnect";
|
|
53
|
+
}>;
|
|
54
|
+
instance: import("zod").ZodOptional<import("zod").ZodString>;
|
|
55
|
+
target: import("zod").ZodOptional<import("zod").ZodString>;
|
|
56
|
+
prefill: import("zod").ZodOptional<import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodString>>;
|
|
57
|
+
changes: import("zod").ZodOptional<import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodString>>;
|
|
58
|
+
reason: import("zod").ZodOptional<import("zod").ZodString>;
|
|
59
|
+
reported: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
60
|
+
}, import("zod/v4/core").$strip>, import("zod").ZodObject<{
|
|
61
|
+
kind: import("zod").ZodLiteral<"secret">;
|
|
62
|
+
name: import("zod").ZodString;
|
|
63
|
+
where: import("zod").ZodOptional<import("zod").ZodString>;
|
|
64
|
+
link: import("zod").ZodOptional<import("zod").ZodString>;
|
|
65
|
+
hint: import("zod").ZodOptional<import("zod").ZodString>;
|
|
66
|
+
replace: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
67
|
+
}, import("zod/v4/core").$strip>, import("zod").ZodObject<{
|
|
68
|
+
kind: import("zod").ZodLiteral<"grant">;
|
|
69
|
+
subject: import("zod").ZodEnum<{
|
|
70
|
+
capability: "capability";
|
|
71
|
+
folder: "folder";
|
|
72
|
+
shelf: "shelf";
|
|
73
|
+
site: "site";
|
|
74
|
+
}>;
|
|
75
|
+
what: import("zod").ZodString;
|
|
76
|
+
label: import("zod").ZodString;
|
|
77
|
+
persona: import("zod").ZodOptional<import("zod").ZodString>;
|
|
78
|
+
scope: import("zod").ZodOptional<import("zod").ZodEnum<{
|
|
79
|
+
conversation: "conversation";
|
|
80
|
+
persona: "persona";
|
|
81
|
+
}>>;
|
|
82
|
+
}, import("zod/v4/core").$strip>, import("zod").ZodObject<{
|
|
83
|
+
kind: import("zod").ZodLiteral<"release">;
|
|
84
|
+
subject: import("zod").ZodString;
|
|
85
|
+
approvers: import("zod").ZodArray<import("zod").ZodString>;
|
|
86
|
+
}, import("zod/v4/core").$strip>, import("zod").ZodObject<{
|
|
87
|
+
kind: import("zod").ZodLiteral<"environment">;
|
|
88
|
+
tool: import("zod").ZodString;
|
|
89
|
+
steps: import("zod").ZodString;
|
|
90
|
+
approvedHash: import("zod").ZodOptional<import("zod").ZodString>;
|
|
91
|
+
}, import("zod/v4/core").$strip>], "kind">;
|
|
92
|
+
title: import("zod").ZodString;
|
|
93
|
+
why: import("zod").ZodOptional<import("zod").ZodString>;
|
|
94
|
+
status: import("zod").ZodEnum<{
|
|
95
|
+
cancelled: "cancelled";
|
|
96
|
+
declined: "declined";
|
|
97
|
+
met: "met";
|
|
98
|
+
open: "open";
|
|
99
|
+
working: "working";
|
|
100
|
+
}>;
|
|
101
|
+
createdAt: import("zod").ZodNumber;
|
|
102
|
+
updatedAt: import("zod").ZodNumber;
|
|
103
|
+
answeredBy: import("zod").ZodOptional<import("zod").ZodString>;
|
|
104
|
+
outcome: import("zod").ZodOptional<import("zod").ZodString>;
|
|
105
|
+
told: import("zod").ZodOptional<import("zod").ZodEnum<{
|
|
106
|
+
call: "call";
|
|
107
|
+
queued: "queued";
|
|
108
|
+
turn: "turn";
|
|
109
|
+
}>>;
|
|
110
|
+
unattended: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
111
|
+
}, import("zod/v4/core").$strip>>;
|
|
112
|
+
code: import("zod").ZodOptional<import("zod").ZodString>;
|
|
113
|
+
}, import("zod/v4/core").$strip>, Record<never, never>, import("../protocol/route-meta.js").RouteMeta & Record<never, never>>;
|
|
114
|
+
mine: import("@orpc/contract").ContractProcedureBuilderWithOutput<import("@orpc/contract").Schema<unknown, unknown>, import("zod").ZodObject<{
|
|
115
|
+
needs: import("zod").ZodArray<import("zod").ZodObject<{
|
|
116
|
+
id: import("zod").ZodString;
|
|
117
|
+
conversationId: import("zod").ZodString;
|
|
118
|
+
subject: import("zod").ZodDiscriminatedUnion<[import("zod").ZodObject<{
|
|
119
|
+
kind: import("zod").ZodLiteral<"capability">;
|
|
120
|
+
entry: import("zod").ZodString;
|
|
121
|
+
name: import("zod").ZodString;
|
|
122
|
+
mode: import("zod").ZodEnum<{
|
|
123
|
+
change: "change";
|
|
124
|
+
connect: "connect";
|
|
125
|
+
reconnect: "reconnect";
|
|
126
|
+
}>;
|
|
127
|
+
instance: import("zod").ZodOptional<import("zod").ZodString>;
|
|
128
|
+
target: import("zod").ZodOptional<import("zod").ZodString>;
|
|
129
|
+
prefill: import("zod").ZodOptional<import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodString>>;
|
|
130
|
+
changes: import("zod").ZodOptional<import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodString>>;
|
|
131
|
+
reason: import("zod").ZodOptional<import("zod").ZodString>;
|
|
132
|
+
reported: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
133
|
+
}, import("zod/v4/core").$strip>, import("zod").ZodObject<{
|
|
134
|
+
kind: import("zod").ZodLiteral<"secret">;
|
|
135
|
+
name: import("zod").ZodString;
|
|
136
|
+
where: import("zod").ZodOptional<import("zod").ZodString>;
|
|
137
|
+
link: import("zod").ZodOptional<import("zod").ZodString>;
|
|
138
|
+
hint: import("zod").ZodOptional<import("zod").ZodString>;
|
|
139
|
+
replace: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
140
|
+
}, import("zod/v4/core").$strip>, import("zod").ZodObject<{
|
|
141
|
+
kind: import("zod").ZodLiteral<"grant">;
|
|
142
|
+
subject: import("zod").ZodEnum<{
|
|
143
|
+
capability: "capability";
|
|
144
|
+
folder: "folder";
|
|
145
|
+
shelf: "shelf";
|
|
146
|
+
site: "site";
|
|
147
|
+
}>;
|
|
148
|
+
what: import("zod").ZodString;
|
|
149
|
+
label: import("zod").ZodString;
|
|
150
|
+
persona: import("zod").ZodOptional<import("zod").ZodString>;
|
|
151
|
+
scope: import("zod").ZodOptional<import("zod").ZodEnum<{
|
|
152
|
+
conversation: "conversation";
|
|
153
|
+
persona: "persona";
|
|
154
|
+
}>>;
|
|
155
|
+
}, import("zod/v4/core").$strip>, import("zod").ZodObject<{
|
|
156
|
+
kind: import("zod").ZodLiteral<"release">;
|
|
157
|
+
subject: import("zod").ZodString;
|
|
158
|
+
approvers: import("zod").ZodArray<import("zod").ZodString>;
|
|
159
|
+
}, import("zod/v4/core").$strip>, import("zod").ZodObject<{
|
|
160
|
+
kind: import("zod").ZodLiteral<"environment">;
|
|
161
|
+
tool: import("zod").ZodString;
|
|
162
|
+
steps: import("zod").ZodString;
|
|
163
|
+
approvedHash: import("zod").ZodOptional<import("zod").ZodString>;
|
|
164
|
+
}, import("zod/v4/core").$strip>], "kind">;
|
|
165
|
+
title: import("zod").ZodString;
|
|
166
|
+
why: import("zod").ZodOptional<import("zod").ZodString>;
|
|
167
|
+
status: import("zod").ZodEnum<{
|
|
168
|
+
cancelled: "cancelled";
|
|
169
|
+
declined: "declined";
|
|
170
|
+
met: "met";
|
|
171
|
+
open: "open";
|
|
172
|
+
working: "working";
|
|
173
|
+
}>;
|
|
174
|
+
createdAt: import("zod").ZodNumber;
|
|
175
|
+
updatedAt: import("zod").ZodNumber;
|
|
176
|
+
answeredBy: import("zod").ZodOptional<import("zod").ZodString>;
|
|
177
|
+
outcome: import("zod").ZodOptional<import("zod").ZodString>;
|
|
178
|
+
told: import("zod").ZodOptional<import("zod").ZodEnum<{
|
|
179
|
+
call: "call";
|
|
180
|
+
queued: "queued";
|
|
181
|
+
turn: "turn";
|
|
182
|
+
}>>;
|
|
183
|
+
unattended: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
184
|
+
}, import("zod/v4/core").$strip>>;
|
|
185
|
+
}, import("zod/v4/core").$strip>, Record<never, never>, import("../protocol/route-meta.js").RouteMeta & Record<never, never>>;
|
|
186
|
+
withdraw: import("@orpc/contract").ContractProcedureBuilderWithInputOutput<import("zod").ZodObject<{
|
|
187
|
+
id: import("zod").ZodString;
|
|
188
|
+
}, import("zod/v4/core").$strip>, import("zod").ZodObject<{
|
|
189
|
+
id: import("zod").ZodString;
|
|
190
|
+
conversationId: import("zod").ZodString;
|
|
191
|
+
subject: import("zod").ZodDiscriminatedUnion<[import("zod").ZodObject<{
|
|
192
|
+
kind: import("zod").ZodLiteral<"capability">;
|
|
193
|
+
entry: import("zod").ZodString;
|
|
194
|
+
name: import("zod").ZodString;
|
|
195
|
+
mode: import("zod").ZodEnum<{
|
|
196
|
+
change: "change";
|
|
197
|
+
connect: "connect";
|
|
198
|
+
reconnect: "reconnect";
|
|
199
|
+
}>;
|
|
200
|
+
instance: import("zod").ZodOptional<import("zod").ZodString>;
|
|
201
|
+
target: import("zod").ZodOptional<import("zod").ZodString>;
|
|
202
|
+
prefill: import("zod").ZodOptional<import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodString>>;
|
|
203
|
+
changes: import("zod").ZodOptional<import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodString>>;
|
|
204
|
+
reason: import("zod").ZodOptional<import("zod").ZodString>;
|
|
205
|
+
reported: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
206
|
+
}, import("zod/v4/core").$strip>, import("zod").ZodObject<{
|
|
207
|
+
kind: import("zod").ZodLiteral<"secret">;
|
|
208
|
+
name: import("zod").ZodString;
|
|
209
|
+
where: import("zod").ZodOptional<import("zod").ZodString>;
|
|
210
|
+
link: import("zod").ZodOptional<import("zod").ZodString>;
|
|
211
|
+
hint: import("zod").ZodOptional<import("zod").ZodString>;
|
|
212
|
+
replace: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
213
|
+
}, import("zod/v4/core").$strip>, import("zod").ZodObject<{
|
|
214
|
+
kind: import("zod").ZodLiteral<"grant">;
|
|
215
|
+
subject: import("zod").ZodEnum<{
|
|
216
|
+
capability: "capability";
|
|
217
|
+
folder: "folder";
|
|
218
|
+
shelf: "shelf";
|
|
219
|
+
site: "site";
|
|
220
|
+
}>;
|
|
221
|
+
what: import("zod").ZodString;
|
|
222
|
+
label: import("zod").ZodString;
|
|
223
|
+
persona: import("zod").ZodOptional<import("zod").ZodString>;
|
|
224
|
+
scope: import("zod").ZodOptional<import("zod").ZodEnum<{
|
|
225
|
+
conversation: "conversation";
|
|
226
|
+
persona: "persona";
|
|
227
|
+
}>>;
|
|
228
|
+
}, import("zod/v4/core").$strip>, import("zod").ZodObject<{
|
|
229
|
+
kind: import("zod").ZodLiteral<"release">;
|
|
230
|
+
subject: import("zod").ZodString;
|
|
231
|
+
approvers: import("zod").ZodArray<import("zod").ZodString>;
|
|
232
|
+
}, import("zod/v4/core").$strip>, import("zod").ZodObject<{
|
|
233
|
+
kind: import("zod").ZodLiteral<"environment">;
|
|
234
|
+
tool: import("zod").ZodString;
|
|
235
|
+
steps: import("zod").ZodString;
|
|
236
|
+
approvedHash: import("zod").ZodOptional<import("zod").ZodString>;
|
|
237
|
+
}, import("zod/v4/core").$strip>], "kind">;
|
|
238
|
+
title: import("zod").ZodString;
|
|
239
|
+
why: import("zod").ZodOptional<import("zod").ZodString>;
|
|
240
|
+
status: import("zod").ZodEnum<{
|
|
241
|
+
cancelled: "cancelled";
|
|
242
|
+
declined: "declined";
|
|
243
|
+
met: "met";
|
|
244
|
+
open: "open";
|
|
245
|
+
working: "working";
|
|
246
|
+
}>;
|
|
247
|
+
createdAt: import("zod").ZodNumber;
|
|
248
|
+
updatedAt: import("zod").ZodNumber;
|
|
249
|
+
answeredBy: import("zod").ZodOptional<import("zod").ZodString>;
|
|
250
|
+
outcome: import("zod").ZodOptional<import("zod").ZodString>;
|
|
251
|
+
told: import("zod").ZodOptional<import("zod").ZodEnum<{
|
|
252
|
+
call: "call";
|
|
253
|
+
queued: "queued";
|
|
254
|
+
turn: "turn";
|
|
255
|
+
}>>;
|
|
256
|
+
unattended: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
257
|
+
}, import("zod/v4/core").$strip>, Record<never, never>, import("../protocol/route-meta.js").RouteMeta & Record<never, never>>;
|
|
258
|
+
list: import("@orpc/contract").ContractProcedureBuilderWithInputOutput<import("zod").ZodObject<{
|
|
259
|
+
conversationId: import("zod").ZodOptional<import("zod").ZodString>;
|
|
260
|
+
open: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
261
|
+
}, import("zod/v4/core").$strip>, import("zod").ZodObject<{
|
|
262
|
+
needs: import("zod").ZodArray<import("zod").ZodObject<{
|
|
263
|
+
id: import("zod").ZodString;
|
|
264
|
+
conversationId: import("zod").ZodString;
|
|
265
|
+
subject: import("zod").ZodDiscriminatedUnion<[import("zod").ZodObject<{
|
|
266
|
+
kind: import("zod").ZodLiteral<"capability">;
|
|
267
|
+
entry: import("zod").ZodString;
|
|
268
|
+
name: import("zod").ZodString;
|
|
269
|
+
mode: import("zod").ZodEnum<{
|
|
270
|
+
change: "change";
|
|
271
|
+
connect: "connect";
|
|
272
|
+
reconnect: "reconnect";
|
|
273
|
+
}>;
|
|
274
|
+
instance: import("zod").ZodOptional<import("zod").ZodString>;
|
|
275
|
+
target: import("zod").ZodOptional<import("zod").ZodString>;
|
|
276
|
+
prefill: import("zod").ZodOptional<import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodString>>;
|
|
277
|
+
changes: import("zod").ZodOptional<import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodString>>;
|
|
278
|
+
reason: import("zod").ZodOptional<import("zod").ZodString>;
|
|
279
|
+
reported: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
280
|
+
}, import("zod/v4/core").$strip>, import("zod").ZodObject<{
|
|
281
|
+
kind: import("zod").ZodLiteral<"secret">;
|
|
282
|
+
name: import("zod").ZodString;
|
|
283
|
+
where: import("zod").ZodOptional<import("zod").ZodString>;
|
|
284
|
+
link: import("zod").ZodOptional<import("zod").ZodString>;
|
|
285
|
+
hint: import("zod").ZodOptional<import("zod").ZodString>;
|
|
286
|
+
replace: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
287
|
+
}, import("zod/v4/core").$strip>, import("zod").ZodObject<{
|
|
288
|
+
kind: import("zod").ZodLiteral<"grant">;
|
|
289
|
+
subject: import("zod").ZodEnum<{
|
|
290
|
+
capability: "capability";
|
|
291
|
+
folder: "folder";
|
|
292
|
+
shelf: "shelf";
|
|
293
|
+
site: "site";
|
|
294
|
+
}>;
|
|
295
|
+
what: import("zod").ZodString;
|
|
296
|
+
label: import("zod").ZodString;
|
|
297
|
+
persona: import("zod").ZodOptional<import("zod").ZodString>;
|
|
298
|
+
scope: import("zod").ZodOptional<import("zod").ZodEnum<{
|
|
299
|
+
conversation: "conversation";
|
|
300
|
+
persona: "persona";
|
|
301
|
+
}>>;
|
|
302
|
+
}, import("zod/v4/core").$strip>, import("zod").ZodObject<{
|
|
303
|
+
kind: import("zod").ZodLiteral<"release">;
|
|
304
|
+
subject: import("zod").ZodString;
|
|
305
|
+
approvers: import("zod").ZodArray<import("zod").ZodString>;
|
|
306
|
+
}, import("zod/v4/core").$strip>, import("zod").ZodObject<{
|
|
307
|
+
kind: import("zod").ZodLiteral<"environment">;
|
|
308
|
+
tool: import("zod").ZodString;
|
|
309
|
+
steps: import("zod").ZodString;
|
|
310
|
+
approvedHash: import("zod").ZodOptional<import("zod").ZodString>;
|
|
311
|
+
}, import("zod/v4/core").$strip>], "kind">;
|
|
312
|
+
title: import("zod").ZodString;
|
|
313
|
+
why: import("zod").ZodOptional<import("zod").ZodString>;
|
|
314
|
+
status: import("zod").ZodEnum<{
|
|
315
|
+
cancelled: "cancelled";
|
|
316
|
+
declined: "declined";
|
|
317
|
+
met: "met";
|
|
318
|
+
open: "open";
|
|
319
|
+
working: "working";
|
|
320
|
+
}>;
|
|
321
|
+
createdAt: import("zod").ZodNumber;
|
|
322
|
+
updatedAt: import("zod").ZodNumber;
|
|
323
|
+
answeredBy: import("zod").ZodOptional<import("zod").ZodString>;
|
|
324
|
+
outcome: import("zod").ZodOptional<import("zod").ZodString>;
|
|
325
|
+
told: import("zod").ZodOptional<import("zod").ZodEnum<{
|
|
326
|
+
call: "call";
|
|
327
|
+
queued: "queued";
|
|
328
|
+
turn: "turn";
|
|
329
|
+
}>>;
|
|
330
|
+
unattended: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
331
|
+
}, import("zod/v4/core").$strip>>;
|
|
332
|
+
}, import("zod/v4/core").$strip>, Record<never, never>, import("../protocol/route-meta.js").RouteMeta & Record<never, never>>;
|
|
333
|
+
answer: import("@orpc/contract").ContractProcedureBuilderWithInputOutput<import("zod").ZodObject<{
|
|
334
|
+
id: import("zod").ZodString;
|
|
335
|
+
answer: import("zod").ZodDiscriminatedUnion<[import("zod").ZodObject<{
|
|
336
|
+
kind: import("zod").ZodLiteral<"decline">;
|
|
337
|
+
note: import("zod").ZodOptional<import("zod").ZodString>;
|
|
338
|
+
}, import("zod/v4/core").$strip>, import("zod").ZodObject<{
|
|
339
|
+
kind: import("zod").ZodLiteral<"accept">;
|
|
340
|
+
}, import("zod/v4/core").$strip>, import("zod").ZodObject<{
|
|
341
|
+
kind: import("zod").ZodLiteral<"apply">;
|
|
342
|
+
}, import("zod/v4/core").$strip>, import("zod").ZodObject<{
|
|
343
|
+
kind: import("zod").ZodLiteral<"grant">;
|
|
344
|
+
scope: import("zod").ZodEnum<{
|
|
345
|
+
conversation: "conversation";
|
|
346
|
+
persona: "persona";
|
|
347
|
+
}>;
|
|
348
|
+
}, import("zod/v4/core").$strip>, import("zod").ZodObject<{
|
|
349
|
+
kind: import("zod").ZodLiteral<"release">;
|
|
350
|
+
}, import("zod/v4/core").$strip>, import("zod").ZodObject<{
|
|
351
|
+
kind: import("zod").ZodLiteral<"approve">;
|
|
352
|
+
}, import("zod/v4/core").$strip>], "kind">;
|
|
353
|
+
}, import("zod/v4/core").$strip>, import("zod").ZodObject<{
|
|
354
|
+
id: import("zod").ZodString;
|
|
355
|
+
conversationId: import("zod").ZodString;
|
|
356
|
+
subject: import("zod").ZodDiscriminatedUnion<[import("zod").ZodObject<{
|
|
357
|
+
kind: import("zod").ZodLiteral<"capability">;
|
|
358
|
+
entry: import("zod").ZodString;
|
|
359
|
+
name: import("zod").ZodString;
|
|
360
|
+
mode: import("zod").ZodEnum<{
|
|
361
|
+
change: "change";
|
|
362
|
+
connect: "connect";
|
|
363
|
+
reconnect: "reconnect";
|
|
364
|
+
}>;
|
|
365
|
+
instance: import("zod").ZodOptional<import("zod").ZodString>;
|
|
366
|
+
target: import("zod").ZodOptional<import("zod").ZodString>;
|
|
367
|
+
prefill: import("zod").ZodOptional<import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodString>>;
|
|
368
|
+
changes: import("zod").ZodOptional<import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodString>>;
|
|
369
|
+
reason: import("zod").ZodOptional<import("zod").ZodString>;
|
|
370
|
+
reported: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
371
|
+
}, import("zod/v4/core").$strip>, import("zod").ZodObject<{
|
|
372
|
+
kind: import("zod").ZodLiteral<"secret">;
|
|
373
|
+
name: import("zod").ZodString;
|
|
374
|
+
where: import("zod").ZodOptional<import("zod").ZodString>;
|
|
375
|
+
link: import("zod").ZodOptional<import("zod").ZodString>;
|
|
376
|
+
hint: import("zod").ZodOptional<import("zod").ZodString>;
|
|
377
|
+
replace: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
378
|
+
}, import("zod/v4/core").$strip>, import("zod").ZodObject<{
|
|
379
|
+
kind: import("zod").ZodLiteral<"grant">;
|
|
380
|
+
subject: import("zod").ZodEnum<{
|
|
381
|
+
capability: "capability";
|
|
382
|
+
folder: "folder";
|
|
383
|
+
shelf: "shelf";
|
|
384
|
+
site: "site";
|
|
385
|
+
}>;
|
|
386
|
+
what: import("zod").ZodString;
|
|
387
|
+
label: import("zod").ZodString;
|
|
388
|
+
persona: import("zod").ZodOptional<import("zod").ZodString>;
|
|
389
|
+
scope: import("zod").ZodOptional<import("zod").ZodEnum<{
|
|
390
|
+
conversation: "conversation";
|
|
391
|
+
persona: "persona";
|
|
392
|
+
}>>;
|
|
393
|
+
}, import("zod/v4/core").$strip>, import("zod").ZodObject<{
|
|
394
|
+
kind: import("zod").ZodLiteral<"release">;
|
|
395
|
+
subject: import("zod").ZodString;
|
|
396
|
+
approvers: import("zod").ZodArray<import("zod").ZodString>;
|
|
397
|
+
}, import("zod/v4/core").$strip>, import("zod").ZodObject<{
|
|
398
|
+
kind: import("zod").ZodLiteral<"environment">;
|
|
399
|
+
tool: import("zod").ZodString;
|
|
400
|
+
steps: import("zod").ZodString;
|
|
401
|
+
approvedHash: import("zod").ZodOptional<import("zod").ZodString>;
|
|
402
|
+
}, import("zod/v4/core").$strip>], "kind">;
|
|
403
|
+
title: import("zod").ZodString;
|
|
404
|
+
why: import("zod").ZodOptional<import("zod").ZodString>;
|
|
405
|
+
status: import("zod").ZodEnum<{
|
|
406
|
+
cancelled: "cancelled";
|
|
407
|
+
declined: "declined";
|
|
408
|
+
met: "met";
|
|
409
|
+
open: "open";
|
|
410
|
+
working: "working";
|
|
411
|
+
}>;
|
|
412
|
+
createdAt: import("zod").ZodNumber;
|
|
413
|
+
updatedAt: import("zod").ZodNumber;
|
|
414
|
+
answeredBy: import("zod").ZodOptional<import("zod").ZodString>;
|
|
415
|
+
outcome: import("zod").ZodOptional<import("zod").ZodString>;
|
|
416
|
+
told: import("zod").ZodOptional<import("zod").ZodEnum<{
|
|
417
|
+
call: "call";
|
|
418
|
+
queued: "queued";
|
|
419
|
+
turn: "turn";
|
|
420
|
+
}>>;
|
|
421
|
+
unattended: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
422
|
+
}, import("zod/v4/core").$strip>, Record<never, never>, import("../protocol/route-meta.js").RouteMeta & Record<never, never>>;
|
|
423
|
+
provideSecret: import("@orpc/contract").ContractProcedureBuilderWithInputOutput<import("zod").ZodObject<{
|
|
424
|
+
id: import("zod").ZodString;
|
|
425
|
+
value: import("zod").ZodString;
|
|
426
|
+
}, import("zod/v4/core").$strip>, import("zod").ZodObject<{
|
|
427
|
+
id: import("zod").ZodString;
|
|
428
|
+
conversationId: import("zod").ZodString;
|
|
429
|
+
subject: import("zod").ZodDiscriminatedUnion<[import("zod").ZodObject<{
|
|
430
|
+
kind: import("zod").ZodLiteral<"capability">;
|
|
431
|
+
entry: import("zod").ZodString;
|
|
432
|
+
name: import("zod").ZodString;
|
|
433
|
+
mode: import("zod").ZodEnum<{
|
|
434
|
+
change: "change";
|
|
435
|
+
connect: "connect";
|
|
436
|
+
reconnect: "reconnect";
|
|
437
|
+
}>;
|
|
438
|
+
instance: import("zod").ZodOptional<import("zod").ZodString>;
|
|
439
|
+
target: import("zod").ZodOptional<import("zod").ZodString>;
|
|
440
|
+
prefill: import("zod").ZodOptional<import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodString>>;
|
|
441
|
+
changes: import("zod").ZodOptional<import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodString>>;
|
|
442
|
+
reason: import("zod").ZodOptional<import("zod").ZodString>;
|
|
443
|
+
reported: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
444
|
+
}, import("zod/v4/core").$strip>, import("zod").ZodObject<{
|
|
445
|
+
kind: import("zod").ZodLiteral<"secret">;
|
|
446
|
+
name: import("zod").ZodString;
|
|
447
|
+
where: import("zod").ZodOptional<import("zod").ZodString>;
|
|
448
|
+
link: import("zod").ZodOptional<import("zod").ZodString>;
|
|
449
|
+
hint: import("zod").ZodOptional<import("zod").ZodString>;
|
|
450
|
+
replace: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
451
|
+
}, import("zod/v4/core").$strip>, import("zod").ZodObject<{
|
|
452
|
+
kind: import("zod").ZodLiteral<"grant">;
|
|
453
|
+
subject: import("zod").ZodEnum<{
|
|
454
|
+
capability: "capability";
|
|
455
|
+
folder: "folder";
|
|
456
|
+
shelf: "shelf";
|
|
457
|
+
site: "site";
|
|
458
|
+
}>;
|
|
459
|
+
what: import("zod").ZodString;
|
|
460
|
+
label: import("zod").ZodString;
|
|
461
|
+
persona: import("zod").ZodOptional<import("zod").ZodString>;
|
|
462
|
+
scope: import("zod").ZodOptional<import("zod").ZodEnum<{
|
|
463
|
+
conversation: "conversation";
|
|
464
|
+
persona: "persona";
|
|
465
|
+
}>>;
|
|
466
|
+
}, import("zod/v4/core").$strip>, import("zod").ZodObject<{
|
|
467
|
+
kind: import("zod").ZodLiteral<"release">;
|
|
468
|
+
subject: import("zod").ZodString;
|
|
469
|
+
approvers: import("zod").ZodArray<import("zod").ZodString>;
|
|
470
|
+
}, import("zod/v4/core").$strip>, import("zod").ZodObject<{
|
|
471
|
+
kind: import("zod").ZodLiteral<"environment">;
|
|
472
|
+
tool: import("zod").ZodString;
|
|
473
|
+
steps: import("zod").ZodString;
|
|
474
|
+
approvedHash: import("zod").ZodOptional<import("zod").ZodString>;
|
|
475
|
+
}, import("zod/v4/core").$strip>], "kind">;
|
|
476
|
+
title: import("zod").ZodString;
|
|
477
|
+
why: import("zod").ZodOptional<import("zod").ZodString>;
|
|
478
|
+
status: import("zod").ZodEnum<{
|
|
479
|
+
cancelled: "cancelled";
|
|
480
|
+
declined: "declined";
|
|
481
|
+
met: "met";
|
|
482
|
+
open: "open";
|
|
483
|
+
working: "working";
|
|
484
|
+
}>;
|
|
485
|
+
createdAt: import("zod").ZodNumber;
|
|
486
|
+
updatedAt: import("zod").ZodNumber;
|
|
487
|
+
answeredBy: import("zod").ZodOptional<import("zod").ZodString>;
|
|
488
|
+
outcome: import("zod").ZodOptional<import("zod").ZodString>;
|
|
489
|
+
told: import("zod").ZodOptional<import("zod").ZodEnum<{
|
|
490
|
+
call: "call";
|
|
491
|
+
queued: "queued";
|
|
492
|
+
turn: "turn";
|
|
493
|
+
}>>;
|
|
494
|
+
unattended: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
495
|
+
}, import("zod/v4/core").$strip>, Record<never, never>, import("../protocol/route-meta.js").RouteMeta & Record<never, never>>;
|
|
496
|
+
grants: import("@orpc/contract").ContractProcedureBuilderWithOutput<import("@orpc/contract").Schema<unknown, unknown>, import("zod").ZodObject<{
|
|
497
|
+
conversations: import("zod").ZodArray<import("zod").ZodObject<{
|
|
498
|
+
conversationId: import("zod").ZodString;
|
|
499
|
+
capabilities: import("zod").ZodArray<import("zod").ZodString>;
|
|
500
|
+
folders: import("zod").ZodArray<import("zod").ZodString>;
|
|
501
|
+
shelves: import("zod").ZodArray<import("zod").ZodEnum<{
|
|
502
|
+
browser: "browser";
|
|
503
|
+
code: "code";
|
|
504
|
+
delegate: "delegate";
|
|
505
|
+
files: "files";
|
|
506
|
+
sandbox: "sandbox";
|
|
507
|
+
shell: "shell";
|
|
508
|
+
web: "web";
|
|
509
|
+
}>>;
|
|
510
|
+
by: import("zod").ZodOptional<import("zod").ZodString>;
|
|
511
|
+
updatedAt: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
512
|
+
releases: import("zod").ZodArray<import("zod").ZodObject<{
|
|
513
|
+
subject: import("zod").ZodString;
|
|
514
|
+
approvedBy: import("zod").ZodString;
|
|
515
|
+
at: import("zod").ZodNumber;
|
|
516
|
+
}, import("zod/v4/core").$strip>>;
|
|
517
|
+
}, import("zod/v4/core").$strip>>;
|
|
518
|
+
}, import("zod/v4/core").$strip>, Record<never, never>, import("../protocol/route-meta.js").RouteMeta & Record<never, never>>;
|
|
519
|
+
revokeGrant: import("@orpc/contract").ContractProcedureBuilderWithInputOutput<import("zod").ZodObject<{
|
|
520
|
+
conversationId: import("zod").ZodString;
|
|
521
|
+
kind: import("zod").ZodEnum<{
|
|
522
|
+
capability: "capability";
|
|
523
|
+
folder: "folder";
|
|
524
|
+
release: "release";
|
|
525
|
+
shelf: "shelf";
|
|
526
|
+
}>;
|
|
527
|
+
what: import("zod").ZodString;
|
|
528
|
+
}, import("zod/v4/core").$strip>, import("zod").ZodObject<{
|
|
529
|
+
ok: import("zod").ZodLiteral<true>;
|
|
530
|
+
}, import("zod/v4/core").$strip>, Record<never, never>, import("../protocol/route-meta.js").RouteMeta & Record<never, never>>;
|
|
531
|
+
};
|
|
532
|
+
//# sourceMappingURL=needs.contract.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"needs.contract.d.ts","sourceRoot":"","sources":["../../src/contracts/needs.contract.ts"],"names":[],"mappings":"AAsBA,eAAO,MAAM,aAAa;IACtB,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAYH,IAAI;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAQJ,QAAQ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IASR,IAAI;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IASJ,MAAM;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAUN,aAAa;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAYb,MAAM;;;;;;;;;;;;;;;;;;;;;;;IASN,WAAW;;;;;;;;;;;;CAUd,CAAC"}
|
|
@@ -0,0 +1,80 @@
|
|
|
1
|
+
import { procedure } from "../protocol/route-meta.js";
|
|
2
|
+
import { OkSchema } from "../schemas/shared.js";
|
|
3
|
+
import { GrantRevokeSchema, NeedAnswerInputSchema, NeedIdParamSchema, NeedRaisedSchema, NeedRaiseSchema, NeedSchema, NeedSecretInputSchema, NeedsListSchema, NeedsQuerySchema, StandingGrantsSchema, } from "../schemas/needs.js";
|
|
4
|
+
const agentDoor = procedure.meta({ agent: true, control: "never" });
|
|
5
|
+
const answerRoute = procedure.meta({ floor: "maintainer", control: "never" });
|
|
6
|
+
export const needsContract = {
|
|
7
|
+
ask: agentDoor
|
|
8
|
+
.route({
|
|
9
|
+
method: "POST",
|
|
10
|
+
path: "/needs/ask",
|
|
11
|
+
summary: "Ask a person for something the task needs",
|
|
12
|
+
description: "Raises a need in the conversation the calling shell belongs to and holds the call up to `wait` seconds for an answer. Answers `met` when it is usable now (or already was), `open` when it is still waiting, and `refused` when nothing was raised or a person declined. An open need's answer reaches the conversation by itself.",
|
|
13
|
+
})
|
|
14
|
+
.meta({ stream: true })
|
|
15
|
+
.input(NeedRaiseSchema)
|
|
16
|
+
.output(NeedRaisedSchema),
|
|
17
|
+
mine: agentDoor
|
|
18
|
+
.route({
|
|
19
|
+
method: "GET",
|
|
20
|
+
path: "/needs/mine",
|
|
21
|
+
summary: "This conversation's needs",
|
|
22
|
+
description: "Every need the calling shell's conversation raised, newest first, open or answered.",
|
|
23
|
+
})
|
|
24
|
+
.output(NeedsListSchema),
|
|
25
|
+
withdraw: agentDoor
|
|
26
|
+
.route({
|
|
27
|
+
method: "POST",
|
|
28
|
+
path: "/needs/{id}/withdraw",
|
|
29
|
+
summary: "Withdraw a need",
|
|
30
|
+
description: "Closes one of this conversation's open needs because the task no longer needs it. Its card says so.",
|
|
31
|
+
})
|
|
32
|
+
.input(NeedIdParamSchema)
|
|
33
|
+
.output(NeedSchema),
|
|
34
|
+
list: procedure
|
|
35
|
+
.route({
|
|
36
|
+
method: "GET",
|
|
37
|
+
path: "/needs",
|
|
38
|
+
summary: "What agents are waiting on people for",
|
|
39
|
+
description: "Needs across the sandbox, or one conversation's, newest first. Never a secret's value.",
|
|
40
|
+
})
|
|
41
|
+
.input(NeedsQuerySchema)
|
|
42
|
+
.output(NeedsListSchema),
|
|
43
|
+
answer: answerRoute
|
|
44
|
+
.route({
|
|
45
|
+
method: "POST",
|
|
46
|
+
path: "/needs/{id}/answer",
|
|
47
|
+
summary: "Answer a need",
|
|
48
|
+
description: "Declines it, or says yes the way its card offered: accept a connection being set up, apply a change, grant for this conversation or the persona, release a gated credential, approve an environment proposal. A release is refused from anyone the gate does not name.",
|
|
49
|
+
})
|
|
50
|
+
.input(NeedAnswerInputSchema)
|
|
51
|
+
.output(NeedSchema),
|
|
52
|
+
provideSecret: answerRoute
|
|
53
|
+
.route({
|
|
54
|
+
method: "POST",
|
|
55
|
+
path: "/needs/{id}/secret",
|
|
56
|
+
summary: "Give a secret a need asked for",
|
|
57
|
+
description: "Stores the value under the name the need asked for and meets it. The value goes to the sandbox's secret store and nowhere else: not the answer, not the transcript, not a log.",
|
|
58
|
+
})
|
|
59
|
+
.meta({ panel: false })
|
|
60
|
+
.input(NeedSecretInputSchema)
|
|
61
|
+
.output(NeedSchema),
|
|
62
|
+
grants: answerRoute
|
|
63
|
+
.route({
|
|
64
|
+
method: "GET",
|
|
65
|
+
path: "/needs/grants",
|
|
66
|
+
summary: "The yeses still standing",
|
|
67
|
+
description: "What people allowed conversations beyond their persona or area, and the gated credentials released to them, by conversation. Names only, never a value.",
|
|
68
|
+
})
|
|
69
|
+
.output(StandingGrantsSchema),
|
|
70
|
+
revokeGrant: answerRoute
|
|
71
|
+
.route({
|
|
72
|
+
method: "POST",
|
|
73
|
+
path: "/needs/grants/revoke",
|
|
74
|
+
summary: "Take a yes back",
|
|
75
|
+
description: "Takes back one grant or one release. The conversation's next turn runs without it; a turn already running keeps what it mounted.",
|
|
76
|
+
})
|
|
77
|
+
.input(GrantRevokeSchema)
|
|
78
|
+
.output(OkSchema),
|
|
79
|
+
};
|
|
80
|
+
//# sourceMappingURL=needs.contract.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"needs.contract.js","sourceRoot":"","sources":["../../src/contracts/needs.contract.ts"],"names":[],"mappings":"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"}
|