@anchrd/intel-contract 0.24.0 → 0.25.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/contract/board.d.ts +25 -0
- package/dist/contract/board.js +36 -0
- package/package.json +1 -1
package/dist/contract/board.d.ts
CHANGED
|
@@ -107,3 +107,28 @@ export declare const BoardTaskUpdateInput: z.ZodObject<{
|
|
|
107
107
|
idempotencyKey: z.ZodString;
|
|
108
108
|
}, z.core.$strict>;
|
|
109
109
|
export type BoardTaskUpdateInput = z.infer<typeof BoardTaskUpdateInput>;
|
|
110
|
+
export declare const BoardAssignee: z.ZodObject<{
|
|
111
|
+
id: z.ZodString;
|
|
112
|
+
name: z.ZodString;
|
|
113
|
+
email: z.ZodEmail;
|
|
114
|
+
isMachine: z.ZodBoolean;
|
|
115
|
+
}, z.core.$strict>;
|
|
116
|
+
export type BoardAssignee = z.infer<typeof BoardAssignee>;
|
|
117
|
+
export declare const BoardAssigneeSearchInput: z.ZodObject<{
|
|
118
|
+
boardId: z.ZodString;
|
|
119
|
+
query: z.ZodString;
|
|
120
|
+
}, z.core.$strict>;
|
|
121
|
+
export type BoardAssigneeSearchInput = z.infer<typeof BoardAssigneeSearchInput>;
|
|
122
|
+
export declare const BoardAssigneeResolveInput: z.ZodObject<{
|
|
123
|
+
ids: z.ZodArray<z.ZodString>;
|
|
124
|
+
}, z.core.$strict>;
|
|
125
|
+
export type BoardAssigneeResolveInput = z.infer<typeof BoardAssigneeResolveInput>;
|
|
126
|
+
export declare const BoardAssigneeList: z.ZodObject<{
|
|
127
|
+
items: z.ZodArray<z.ZodObject<{
|
|
128
|
+
id: z.ZodString;
|
|
129
|
+
name: z.ZodString;
|
|
130
|
+
email: z.ZodEmail;
|
|
131
|
+
isMachine: z.ZodBoolean;
|
|
132
|
+
}, z.core.$strict>>;
|
|
133
|
+
}, z.core.$strict>;
|
|
134
|
+
export type BoardAssigneeList = z.infer<typeof BoardAssigneeList>;
|
package/dist/contract/board.js
CHANGED
|
@@ -188,3 +188,39 @@ export const BoardTaskUpdateInput = z.strictObject({
|
|
|
188
188
|
.describe("A node this card waits for. `null` clears the dependency."),
|
|
189
189
|
idempotencyKey: IdempotencyKey,
|
|
190
190
|
});
|
|
191
|
+
// ── Who a card can be given to ────────────────────────────────────────────────────────────────
|
|
192
|
+
// D70 (`~/Dev/anchrd/core/DECISIONS.md`): the people offered here are the ones who can actually open
|
|
193
|
+
// THIS board, never everyone who holds an account. The narrower answer is the point, and it is what
|
|
194
|
+
// makes the door safe to offer to anyone who can see the board.
|
|
195
|
+
//
|
|
196
|
+
// ⚠️ `email` travels because two colleagues share a first name more often than a picker can afford,
|
|
197
|
+
// and a list of indistinguishable "Anton" rows is not a picker. It is no wider than what gate hands
|
|
198
|
+
// any signed-in person at `POST /directory/search`; the narrowing this door adds is WHO appears,
|
|
199
|
+
// not WHAT is said about them.
|
|
200
|
+
//
|
|
201
|
+
// `isMachine` travels for the same reason gate carries it: whoever picks an assignee wants to know
|
|
202
|
+
// whether they are handing the card to a colleague or to an agent.
|
|
203
|
+
export const BoardAssignee = z.strictObject({
|
|
204
|
+
id: IntelId,
|
|
205
|
+
name: z.string(),
|
|
206
|
+
email: z.email(),
|
|
207
|
+
isMachine: z.boolean(),
|
|
208
|
+
});
|
|
209
|
+
export const BoardAssigneeSearchInput = z.strictObject({
|
|
210
|
+
boardId: IntelId.describe("The board whose people to offer. Only those who can open this board appear, so the same query against two boards can give two different answers."),
|
|
211
|
+
query: z
|
|
212
|
+
.string()
|
|
213
|
+
.describe("What was typed. Under two characters the answer is empty rather than everybody: a single letter is a listing under a different name."),
|
|
214
|
+
});
|
|
215
|
+
// ⚠️ A DIFFERENT question from the one above, and deliberately not board-scoped. This one names
|
|
216
|
+
// people who are ALREADY recorded on a card, so that a circle can carry initials instead of a raw
|
|
217
|
+
// id (`#258`). Someone whose access was withdrawn, or whose account was switched off, still has to
|
|
218
|
+
// be nameable: a card that reads as unassigned is a worse answer than the truth.
|
|
219
|
+
export const BoardAssigneeResolveInput = z.strictObject({
|
|
220
|
+
ids: z
|
|
221
|
+
.array(IntelId)
|
|
222
|
+
.min(1)
|
|
223
|
+
.max(100)
|
|
224
|
+
.describe("The ids to name. Ids that cannot be named are absent from the answer rather than reported, and more than a hundred is refused rather than silently shortened."),
|
|
225
|
+
});
|
|
226
|
+
export const BoardAssigneeList = z.strictObject({ items: z.array(BoardAssignee) });
|