@ziggs-ai/contracts 0.7.6 → 0.8.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/generated/chat-send.d.ts +11 -0
- package/dist/inbox.d.ts +47 -0
- package/dist/vocabulary.d.ts +6 -1
- package/package.json +1 -1
|
@@ -6,10 +6,21 @@ export type DailyUsageView = {
|
|
|
6
6
|
messagesToday: number;
|
|
7
7
|
dailyLimit: number;
|
|
8
8
|
};
|
|
9
|
+
export type MessageDestination = {
|
|
10
|
+
id: string;
|
|
11
|
+
type: string;
|
|
12
|
+
};
|
|
13
|
+
export type MessageDelivery = {
|
|
14
|
+
accepted: boolean;
|
|
15
|
+
to: MessageDestination;
|
|
16
|
+
broadcast: boolean;
|
|
17
|
+
wakesAgent: boolean;
|
|
18
|
+
};
|
|
9
19
|
export type SendChatMessageResult = {
|
|
10
20
|
success: boolean;
|
|
11
21
|
message: string;
|
|
12
22
|
messageId: string;
|
|
13
23
|
chatId: string;
|
|
24
|
+
delivery: MessageDelivery;
|
|
14
25
|
usage?: DailyUsageView;
|
|
15
26
|
};
|
package/dist/inbox.d.ts
CHANGED
|
@@ -47,6 +47,53 @@ export interface DecisionRef {
|
|
|
47
47
|
/** Signed-in review page. Following it does not approve or mark anything seen. */
|
|
48
48
|
reviewUrl?: string;
|
|
49
49
|
decideVia: DecideVia;
|
|
50
|
+
/**
|
|
51
|
+
* Present when what is being asked for is ACCESS to one thing.
|
|
52
|
+
*
|
|
53
|
+
* A grant request already arrives as an ordinary pending proposal, so the
|
|
54
|
+
* button was there; the card was not. `title` is the request's own prose,
|
|
55
|
+
* which leaves the person to work out what they are being asked to open, for
|
|
56
|
+
* whom, and for how long. These are the fields that answer that, taken from
|
|
57
|
+
* the request the agent actually filed — nothing here is inferred.
|
|
58
|
+
*/
|
|
59
|
+
access?: AccessAsk;
|
|
60
|
+
}
|
|
61
|
+
/**
|
|
62
|
+
* What an access ask is asking for, as the person answering needs to read it.
|
|
63
|
+
*
|
|
64
|
+
* One resource. `scope` is the whole of what a yes opens: there is no arm here
|
|
65
|
+
* that widens to a container or to a second row, and the card says so rather
|
|
66
|
+
* than leaving the reader to assume it.
|
|
67
|
+
*/
|
|
68
|
+
export interface AccessAsk {
|
|
69
|
+
/** The one thing. `name` is absent when nothing readable resolves. */
|
|
70
|
+
scope: {
|
|
71
|
+
kind: string;
|
|
72
|
+
id: string;
|
|
73
|
+
name?: string | null;
|
|
74
|
+
};
|
|
75
|
+
/**
|
|
76
|
+
* The agent that would read it. A label, never an agent id.
|
|
77
|
+
*
|
|
78
|
+
* Who it reads FOR is the row's own `requestedByDisplayName` /
|
|
79
|
+
* `requestedByOrgName`: the asking side is the side the agent acts for, and
|
|
80
|
+
* repeating it here would be a second answer to one question.
|
|
81
|
+
*/
|
|
82
|
+
holderDisplayName: string | null;
|
|
83
|
+
/** Why, in the requester's own words. */
|
|
84
|
+
reason: string | null;
|
|
85
|
+
/**
|
|
86
|
+
* How long a yes lasts, in hours, counted FROM the yes rather than from the
|
|
87
|
+
* ask. Null when the request names no lifetime.
|
|
88
|
+
*/
|
|
89
|
+
durationHours: number | null;
|
|
90
|
+
/**
|
|
91
|
+
* The grant's real expiry, once there is one. Absent while the ask is still
|
|
92
|
+
* pending — a card must not show an expiry for access that does not exist.
|
|
93
|
+
*/
|
|
94
|
+
grantedUntil?: string | null;
|
|
95
|
+
/** `from-now` reads what arrives next; `from-start` reads the history too. */
|
|
96
|
+
temporal?: 'from-now' | 'from-start' | null;
|
|
50
97
|
}
|
|
51
98
|
/**
|
|
52
99
|
* One row in the reader's merged view. A reference, never content — following
|
package/dist/vocabulary.d.ts
CHANGED
|
@@ -33,7 +33,12 @@ export type ChatAddressKind = (typeof CHAT_ADDRESS_KINDS)[number];
|
|
|
33
33
|
export declare const RESOURCE_KINDS: readonly ["message", "artifact", "task-state", "agreement", "request"];
|
|
34
34
|
export type ResourceKind = (typeof RESOURCE_KINDS)[number];
|
|
35
35
|
/** What kind of thing is waiting on a person. */
|
|
36
|
-
|
|
36
|
+
/**
|
|
37
|
+
* What a card in the decision list is. Not an approval kind: `chat_admission`
|
|
38
|
+
* names the card for an approval the chat rail has had since ZIG-426, which
|
|
39
|
+
* was answerable all along and simply never reached this list.
|
|
40
|
+
*/
|
|
41
|
+
export type DecisionKind = 'proposal' | 'connection_request' | 'spend_approval' | 'chat_admission';
|
|
37
42
|
/** Which mailbox a delivery copy lives in. */
|
|
38
43
|
export type InboxPartyKind = 'human' | 'org';
|
|
39
44
|
/** How a principal is party to an agreement. */
|
package/package.json
CHANGED