@etazio/agent-sdk 0.1.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.
@@ -0,0 +1,137 @@
1
+ import { z } from 'zod';
2
+ /**
3
+ * Avatar-Profil (Phase 4, Roadmap §6 Charakter-Editor / §8 AvatarProfile). Ein Profil je Nutzer,
4
+ * gilt in allen Workspaces. Alle Varianten sitzen auf dem gemeinsamen Rig `avatar_base` (v2) und
5
+ * sind als eigene Meshes `part_<gruppe>_<variante>` in derselben GLB enthalten – der Client blendet
6
+ * sie ein/aus, Farben gehen über die freigegebenen Material-Slots. Kuratiert, damit nichts clippt
7
+ * (Roadmap §12): freie Mesh-Uploads und Morphs kommen erst nach dem stabilen Avatar-System.
8
+ */
9
+ export declare const AVATAR_RIG_VERSION = 2;
10
+ export declare const AVATAR_BODIES: readonly ['slim', 'standard', 'broad'];
11
+ export declare const AVATAR_HEIGHTS: readonly ['short', 'medium', 'tall'];
12
+ export declare const AVATAR_HAIRS: readonly ['none', 'short', 'long', 'bun'];
13
+ export declare const AVATAR_TOPS: readonly ['tshirt', 'longsleeve', 'hoodie'];
14
+ export declare const AVATAR_ACCESSORIES: readonly ['glasses', 'headphones', 'cap'];
15
+ export declare const AVATAR_COLOR_SLOTS: readonly ['skin', 'hair', 'shirt', 'pants', 'shoes', 'accent'];
16
+ export type AvatarBody = (typeof AVATAR_BODIES)[number];
17
+ export type AvatarHeight = (typeof AVATAR_HEIGHTS)[number];
18
+ export type AvatarHair = (typeof AVATAR_HAIRS)[number];
19
+ export type AvatarTop = (typeof AVATAR_TOPS)[number];
20
+ export type AvatarAccessory = (typeof AVATAR_ACCESSORIES)[number];
21
+ export type AvatarColorSlot = (typeof AVATAR_COLOR_SLOTS)[number];
22
+ export declare const avatarProfileSchema: z.ZodPipe<z.ZodObject<{
23
+ rigVersion: z.ZodDefault<z.ZodLiteral<2>>;
24
+ body: z.ZodDefault<z.ZodEnum<{
25
+ broad: "broad";
26
+ slim: "slim";
27
+ standard: "standard";
28
+ }>>;
29
+ height: z.ZodDefault<z.ZodEnum<{
30
+ medium: "medium";
31
+ short: "short";
32
+ tall: "tall";
33
+ }>>;
34
+ hair: z.ZodDefault<z.ZodEnum<{
35
+ bun: "bun";
36
+ long: "long";
37
+ none: "none";
38
+ short: "short";
39
+ }>>;
40
+ top: z.ZodDefault<z.ZodEnum<{
41
+ hoodie: "hoodie";
42
+ longsleeve: "longsleeve";
43
+ tshirt: "tshirt";
44
+ }>>;
45
+ accessories: z.ZodDefault<z.ZodArray<z.ZodEnum<{
46
+ cap: "cap";
47
+ glasses: "glasses";
48
+ headphones: "headphones";
49
+ }>>>;
50
+ colors: z.ZodPrefault<z.ZodObject<{
51
+ skin: z.ZodDefault<z.ZodString>;
52
+ hair: z.ZodDefault<z.ZodString>;
53
+ shirt: z.ZodDefault<z.ZodString>;
54
+ pants: z.ZodDefault<z.ZodString>;
55
+ shoes: z.ZodDefault<z.ZodString>;
56
+ accent: z.ZodDefault<z.ZodString>;
57
+ }, z.core.$strip>>;
58
+ }, z.core.$strip>, z.ZodTransform<{
59
+ rigVersion: 2;
60
+ body: "broad" | "slim" | "standard";
61
+ height: "medium" | "short" | "tall";
62
+ hair: "bun" | "long" | "none" | "short";
63
+ top: "hoodie" | "longsleeve" | "tshirt";
64
+ colors: {
65
+ skin: string;
66
+ hair: string;
67
+ shirt: string;
68
+ pants: string;
69
+ shoes: string;
70
+ accent: string;
71
+ };
72
+ accessories: ("cap" | "glasses" | "headphones")[];
73
+ }, {
74
+ rigVersion: 2;
75
+ body: "broad" | "slim" | "standard";
76
+ height: "medium" | "short" | "tall";
77
+ hair: "bun" | "long" | "none" | "short";
78
+ top: "hoodie" | "longsleeve" | "tshirt";
79
+ accessories: ("cap" | "glasses" | "headphones")[];
80
+ colors: {
81
+ skin: string;
82
+ hair: string;
83
+ shirt: string;
84
+ pants: string;
85
+ shoes: string;
86
+ accent: string;
87
+ };
88
+ }>>;
89
+ export type AvatarProfile = z.output<typeof avatarProfileSchema>;
90
+ export type AvatarProfileInput = z.input<typeof avatarProfileSchema>;
91
+ export declare function defaultAvatarProfile(): AvatarProfile;
92
+ /** Kuratierte Hauttöne (Roadmap §6); weitere Farben sind erlaubt, die UI bietet diese an. */
93
+ export declare const SKIN_TONES: readonly ['#f5dcc4', '#deae8c', '#c98f6a', '#a86d4b', '#7d4a2e', '#4f2e1c'];
94
+ export declare const HAIR_COLORS: readonly ['#1a1412', '#402b1f', '#7a4a2a', '#b8793a', '#d9b37a', '#8c8c8c', '#c94f3d', '#5a3f8c'];
95
+ export declare const CLOTH_COLORS: readonly ['#386b9e', '#2f7a5a', '#b04a3c', '#d97340', '#6a5acd', '#333642', '#8a8f99', '#e8e2d5', '#1f1f21', '#f0c46a'];
96
+ /** Sichtbare Varianten-Teile der GLB für ein Profil (Namen aus assets/blender/scripts/build_avatar.py). */
97
+ export declare function avatarPartsFor(profile: AvatarProfile): string[];
98
+ /** Skalierung des Avatars (Körperbau × Größe); Kopf und Anker bleiben proportional. */
99
+ export declare function avatarScaleFor(profile: AvatarProfile): [number, number, number];
100
+ /** Material-Slot der GLB je Farbslot des Profils. */
101
+ export declare const AVATAR_SLOT_MATERIALS: Record<AvatarColorSlot, string>;
102
+ export declare const AVATAR_LABELS: {
103
+ readonly body: {
104
+ readonly slim: 'Schlank';
105
+ readonly standard: 'Normal';
106
+ readonly broad: 'Kräftig';
107
+ };
108
+ readonly height: {
109
+ readonly short: 'Klein';
110
+ readonly medium: 'Mittel';
111
+ readonly tall: 'Groß';
112
+ };
113
+ readonly hair: {
114
+ readonly none: 'Ohne';
115
+ readonly short: 'Kurz';
116
+ readonly long: 'Lang';
117
+ readonly bun: 'Dutt';
118
+ };
119
+ readonly top: {
120
+ readonly tshirt: 'T-Shirt';
121
+ readonly longsleeve: 'Langarm';
122
+ readonly hoodie: 'Hoodie';
123
+ };
124
+ readonly accessories: {
125
+ readonly glasses: 'Brille';
126
+ readonly headphones: 'Kopfhörer';
127
+ readonly cap: 'Kappe';
128
+ };
129
+ readonly colors: {
130
+ readonly skin: 'Haut';
131
+ readonly hair: 'Haare';
132
+ readonly shirt: 'Oberteil';
133
+ readonly pants: 'Hose';
134
+ readonly shoes: 'Schuhe';
135
+ readonly accent: 'Accessoires';
136
+ };
137
+ };
@@ -0,0 +1,124 @@
1
+ import { z } from 'zod';
2
+ /**
3
+ * Whiteboard (Phase 7b): Operationen auf einem gemeinsamen Board. Koordinaten sind auf 0–1 normiert
4
+ * (u = links→rechts, v = oben→unten), damit 3D-Textur und Overlay dasselbe Bild zeichnen. Striche und Notizen
5
+ * sind kommutativ; nur `clear` prüft die Basisversion. Der Server vergibt `version` je Operation.
6
+ */
7
+ export declare const BOARD_LIMITS: {
8
+ /** Punkte je Strich (inkl. Verlängerungen) */
9
+ readonly maxPoints: 500;
10
+ /** Punkte je Operation (Segment beim Live-Zeichnen) */
11
+ readonly maxSegment: 120;
12
+ readonly maxText: 200;
13
+ /** Operationen im Log je Board; darüber verlangt der Server einen Snapshot */
14
+ readonly maxOps: 5000;
15
+ /** Nach so vielen Operationen seit dem Snapshot lädt der Client ein neues Snapshot-PNG hoch */
16
+ readonly snapshotEvery: 200;
17
+ /** Snapshot-PNG als Base64, Bytes */
18
+ readonly maxSnapshotBytes: 1500000;
19
+ /** Operationen je Teilnehmer und Sekunde */
20
+ readonly opsPerSecond: 30;
21
+ /** Zeigerpositionen je Sekunde */
22
+ readonly cursorHz: 10;
23
+ };
24
+ export declare const BOARD_COLORS: readonly ['#1c1c1e', '#2f4dff', '#12a594', '#e0871f', '#d63b3b', '#8b5cf6', '#6b7280', '#ffffff'];
25
+ export declare const BOARD_WIDTHS: readonly [2, 4, 8];
26
+ export declare const boardOpSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
27
+ type: z.ZodLiteral<"stroke">;
28
+ id: z.ZodString;
29
+ color: z.ZodString;
30
+ width: z.ZodNumber;
31
+ points: z.ZodArray<z.ZodTuple<[z.ZodNumber, z.ZodNumber], null>>;
32
+ }, z.core.$strip>, z.ZodObject<{
33
+ type: z.ZodLiteral<"extend">;
34
+ id: z.ZodString;
35
+ points: z.ZodArray<z.ZodTuple<[z.ZodNumber, z.ZodNumber], null>>;
36
+ }, z.core.$strip>, z.ZodObject<{
37
+ type: z.ZodLiteral<"note">;
38
+ id: z.ZodString;
39
+ x: z.ZodNumber;
40
+ y: z.ZodNumber;
41
+ text: z.ZodString;
42
+ color: z.ZodString;
43
+ }, z.core.$strip>, z.ZodObject<{
44
+ type: z.ZodLiteral<"move">;
45
+ id: z.ZodString;
46
+ x: z.ZodNumber;
47
+ y: z.ZodNumber;
48
+ }, z.core.$strip>, z.ZodObject<{
49
+ type: z.ZodLiteral<"erase">;
50
+ id: z.ZodString;
51
+ }, z.core.$strip>, z.ZodObject<{
52
+ type: z.ZodLiteral<"clear">;
53
+ }, z.core.$strip>], "type">;
54
+ export type BoardOp = z.infer<typeof boardOpSchema>;
55
+ export declare const boardOpEnvelopeSchema: z.ZodObject<{
56
+ placementId: z.ZodString;
57
+ opId: z.ZodString;
58
+ baseVersion: z.ZodNumber;
59
+ op: z.ZodDiscriminatedUnion<[z.ZodObject<{
60
+ type: z.ZodLiteral<"stroke">;
61
+ id: z.ZodString;
62
+ color: z.ZodString;
63
+ width: z.ZodNumber;
64
+ points: z.ZodArray<z.ZodTuple<[z.ZodNumber, z.ZodNumber], null>>;
65
+ }, z.core.$strip>, z.ZodObject<{
66
+ type: z.ZodLiteral<"extend">;
67
+ id: z.ZodString;
68
+ points: z.ZodArray<z.ZodTuple<[z.ZodNumber, z.ZodNumber], null>>;
69
+ }, z.core.$strip>, z.ZodObject<{
70
+ type: z.ZodLiteral<"note">;
71
+ id: z.ZodString;
72
+ x: z.ZodNumber;
73
+ y: z.ZodNumber;
74
+ text: z.ZodString;
75
+ color: z.ZodString;
76
+ }, z.core.$strip>, z.ZodObject<{
77
+ type: z.ZodLiteral<"move">;
78
+ id: z.ZodString;
79
+ x: z.ZodNumber;
80
+ y: z.ZodNumber;
81
+ }, z.core.$strip>, z.ZodObject<{
82
+ type: z.ZodLiteral<"erase">;
83
+ id: z.ZodString;
84
+ }, z.core.$strip>, z.ZodObject<{
85
+ type: z.ZodLiteral<"clear">;
86
+ }, z.core.$strip>], "type">;
87
+ }, z.core.$strip>;
88
+ export type BoardOpEnvelope = z.infer<typeof boardOpEnvelopeSchema>;
89
+ export declare const boardSyncRequestSchema: z.ZodObject<{
90
+ placementId: z.ZodString;
91
+ }, z.core.$strip>;
92
+ export declare const boardCursorSchema: z.ZodObject<{
93
+ placementId: z.ZodString;
94
+ x: z.ZodNullable<z.ZodNumber>;
95
+ y: z.ZodNullable<z.ZodNumber>;
96
+ }, z.core.$strip>;
97
+ export declare const boardSnapshotSchema: z.ZodObject<{
98
+ version: z.ZodNumber;
99
+ png: z.ZodString;
100
+ }, z.core.$strip>;
101
+ /** Sichtbares Element auf dem Board (aus dem Op-Log gefaltet) */
102
+ export type BoardItem = {
103
+ kind: 'stroke';
104
+ id: string;
105
+ color: string;
106
+ width: number;
107
+ points: Array<[number, number]>;
108
+ } | {
109
+ kind: 'note';
110
+ id: string;
111
+ x: number;
112
+ y: number;
113
+ text: string;
114
+ color: string;
115
+ };
116
+ export interface BoardModel {
117
+ /** Elemente in Zeichenreihenfolge */
118
+ items: BoardItem[];
119
+ /** Version der letzten angewandten Operation */
120
+ version: number;
121
+ }
122
+ export declare function emptyBoard(): BoardModel;
123
+ /** Wendet eine Operation auf das Modell an (in place). Unbekannte IDs werden still ignoriert (kommutativ). */
124
+ export declare function applyBoardOp(model: BoardModel, op: BoardOp, version?: number): void;
@@ -0,0 +1,64 @@
1
+ /**
2
+ * Kalender-Tab der Office-Shell (SPA-132). MVP: Google Calendar, nur lesen, nur der eigene
3
+ * Hauptkalender des verbundenen Kontos. Verbindung gilt je Nutzer (nicht je Workspace).
4
+ */
5
+ export declare const CALENDAR_PROVIDERS: readonly ['google'];
6
+ export type CalendarProvider = (typeof CALENDAR_PROVIDERS)[number];
7
+ /** Einziger Scope des MVP – Schreibzugriff kommt bewusst getrennt (Folgeticket). */
8
+ export declare const GOOGLE_CALENDAR_SCOPE = "https://www.googleapis.com/auth/calendar.readonly";
9
+ /**
10
+ * - `active`: Termine abrufbar
11
+ * - `expired`: Google hat das Refresh-Token nicht mehr angenommen (widerrufen, abgelaufen, Passwort geändert)
12
+ * - `scope_missing`: bei der Zustimmung wurde der Kalender-Haken abgewählt
13
+ */
14
+ export type CalendarConnectionStatus = 'active' | 'expired' | 'scope_missing';
15
+ export interface CalendarConnectionDto {
16
+ provider: CalendarProvider;
17
+ /** Google-Konto, dessen Kalender gelesen wird */
18
+ email: string | null;
19
+ status: CalendarConnectionStatus;
20
+ connectedAt: string;
21
+ lastError: string | null;
22
+ }
23
+ export interface CalendarStatusDto {
24
+ /** Server hat eine Google-App konfiguriert */
25
+ available: boolean;
26
+ connection: CalendarConnectionDto | null;
27
+ /** Anmeldung dieser Sitzung lief über Google → Konto für den Connect-Flow vorschlagen */
28
+ suggestedEmail: string | null;
29
+ }
30
+ export interface CalendarEventDto {
31
+ id: string;
32
+ title: string;
33
+ /** ISO-Zeitpunkt; bei ganztägigen Terminen `YYYY-MM-DD` */
34
+ start: string;
35
+ end: string;
36
+ allDay: boolean;
37
+ location: string | null;
38
+ /** Videokonferenz-Link (Meet o. ä.), falls vorhanden */
39
+ meetingUrl: string | null;
40
+ /** Link zum Termin in Google Calendar */
41
+ htmlLink: string | null;
42
+ /** eigene Antwort: accepted | declined | tentative | needsAction | null (eigener Termin ohne Gäste) */
43
+ response: 'accepted' | 'declined' | 'tentative' | 'needsAction' | null;
44
+ tentative: boolean;
45
+ attendees: number;
46
+ }
47
+ export interface CalendarEventsDto {
48
+ from: string;
49
+ to: string;
50
+ timeZone: string | null;
51
+ events: CalendarEventDto[];
52
+ }
53
+ /** Fehlercodes im `?calendar_error=` nach dem OAuth-Rückweg */
54
+ export declare const CALENDAR_ERRORS: {
55
+ readonly unavailable: 'Google ist auf diesem Server nicht eingerichtet.';
56
+ readonly cancelled: 'Verbindung abgebrochen.';
57
+ readonly state: 'Der Anmeldevorgang ist abgelaufen – bitte erneut verbinden.';
58
+ readonly provider: 'Google hat die Verbindung abgelehnt. Bitte erneut versuchen.';
59
+ readonly scope_missing: 'Ohne den Haken „Kalender ansehen“ kann Etazio keine Termine zeigen.';
60
+ readonly no_refresh: 'Google hat keinen dauerhaften Zugriff erteilt. Bitte erneut verbinden.';
61
+ };
62
+ export type CalendarErrorCode = keyof typeof CALENDAR_ERRORS;
63
+ /** Maximaler Abfragezeitraum in Tagen */
64
+ export declare const CALENDAR_MAX_RANGE_DAYS = 42;
@@ -0,0 +1,161 @@
1
+ import { z } from 'zod';
2
+ /**
3
+ * Strukturierte Nachrichteninhalte und Emoji-Regeln für den Chat (SPA-117).
4
+ *
5
+ * Eine Nachricht bleibt in erster Linie Text – `text` ist Pflicht und trägt Suche, Vorschau und
6
+ * Benachrichtigung. `blocks` kommt additiv dazu: eine Karte, die man anklickt, statt einer Frage,
7
+ * die man abtippt. Bestandsnachrichten ohne `blocks` bleiben gültig, eine Migration braucht es nicht.
8
+ */
9
+ export declare const CHAT_GLYPH_LIMITS: {
10
+ /** Eine Reaktion ist genau ein sichtbares Zeichen – Skin-Tone und ZWJ-Sequenz eingeschlossen */
11
+ readonly maxClusters: 1;
12
+ /** Harte Klammer über die Rohlänge: eine Familien-Sequenz mit Skin-Tones ist lang, aber nicht beliebig */
13
+ readonly maxChars: 80;
14
+ };
15
+ /**
16
+ * Sichtbare Zeichen einer Zeichenkette. `👩\u{1F3FD}\u{200D}🚒` ist ein Zeichen und sieben Code-Einheiten – genau
17
+ * dieser Unterschied hat die alte Prüfung (`length <= 8`) Reaktionen ablehnen lassen, die es gibt.
18
+ */
19
+ export declare function graphemeCount(s: string): number;
20
+ /**
21
+ * Nur Emoji dürfen Reaktion sein. Ohne diese Prüfung wäre die Reaktionsleiste ein zweiter, kürzerer
22
+ * Nachrichtenkanal – mit allem, was man dort hineinschreiben kann.
23
+ */
24
+ export declare function isEmojiGlyph(s: string): boolean;
25
+ export declare const glyphSchema: z.ZodString;
26
+ export declare const CHAT_BLOCK_LIMITS: {
27
+ /** Blöcke je Nachricht */
28
+ readonly maxBlocks: 3;
29
+ readonly maxTitle: 120;
30
+ readonly maxDescription: 600;
31
+ readonly maxFields: 10;
32
+ readonly maxFieldLabel: 60;
33
+ readonly maxFieldValue: 240;
34
+ readonly maxActions: 4;
35
+ readonly maxActionLabel: 40;
36
+ /** Weiter als das darf ein Ablaufzeitpunkt nicht in der Zukunft liegen */
37
+ readonly maxTtlMs: number;
38
+ };
39
+ export declare const CHAT_ACTION_STYLES: readonly ['primary', 'secondary', 'danger'];
40
+ export type ChatActionStyle = (typeof CHAT_ACTION_STYLES)[number];
41
+ export interface ChatBlockField {
42
+ label: string;
43
+ value: string;
44
+ }
45
+ export interface ChatBlockAction {
46
+ id: string;
47
+ label: string;
48
+ style: ChatActionStyle;
49
+ }
50
+ /** Wer die Karte entschieden hat und wann – steht in der Karte, nicht nur im Audit-Log. */
51
+ export interface ChatBlockDecision {
52
+ actionId: string;
53
+ actionLabel: string;
54
+ userId: string;
55
+ userName: string;
56
+ at: string;
57
+ }
58
+ /**
59
+ * Bestätigungs-Karte: eine Frage mit festen Antworten. Genau einmal entscheidbar; danach sehen alle
60
+ * denselben Endzustand.
61
+ */
62
+ export interface ChatConfirmBlock {
63
+ type: 'confirm';
64
+ id: string;
65
+ title: string;
66
+ description: string | null;
67
+ fields: ChatBlockField[];
68
+ actions: ChatBlockAction[];
69
+ expiresAt: string | null;
70
+ decision: ChatBlockDecision | null;
71
+ }
72
+ /**
73
+ * Union mit genau einem Mitglied – bewusst. `fields`, `image` und `select` kommen später als
74
+ * eigene `type`-Zweige dazu, ohne dass der bestehende Zweig sich ändert.
75
+ */
76
+ export type ChatBlock = ChatConfirmBlock;
77
+ export declare const blockIdSchema: z.ZodString;
78
+ export declare const actionIdSchema: z.ZodString;
79
+ /** Eingabe des Absenders: ohne `decision` – die entsteht erst durch einen Klick auf dem Server. */
80
+ export declare const confirmBlockInputSchema: z.ZodObject<{
81
+ type: z.ZodLiteral<"confirm">;
82
+ id: z.ZodString;
83
+ title: z.ZodString;
84
+ description: z.ZodOptional<z.ZodNullable<z.ZodString>>;
85
+ fields: z.ZodDefault<z.ZodArray<z.ZodObject<{
86
+ label: z.ZodString;
87
+ value: z.ZodString;
88
+ }, z.core.$strip>>>;
89
+ actions: z.ZodArray<z.ZodObject<{
90
+ id: z.ZodString;
91
+ label: z.ZodString;
92
+ style: z.ZodDefault<z.ZodEnum<{
93
+ danger: "danger";
94
+ primary: "primary";
95
+ secondary: "secondary";
96
+ }>>;
97
+ }, z.core.$strip>>;
98
+ expiresAt: z.ZodOptional<z.ZodNullable<z.ZodString>>;
99
+ }, z.core.$strip>;
100
+ /** Eingabe einer Bestätigungs-Karte ohne `type` – so, wie ein Agent sie zusammenstellt. */
101
+ export interface ChatConfirmBlockInput {
102
+ id: string;
103
+ title: string;
104
+ description?: string | null;
105
+ fields?: ChatBlockField[];
106
+ actions: Array<{
107
+ id: string;
108
+ label: string;
109
+ style?: ChatActionStyle;
110
+ }>;
111
+ expiresAt?: string | null;
112
+ }
113
+ export declare const chatBlockInputSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
114
+ type: z.ZodLiteral<"confirm">;
115
+ id: z.ZodString;
116
+ title: z.ZodString;
117
+ description: z.ZodOptional<z.ZodNullable<z.ZodString>>;
118
+ fields: z.ZodDefault<z.ZodArray<z.ZodObject<{
119
+ label: z.ZodString;
120
+ value: z.ZodString;
121
+ }, z.core.$strip>>>;
122
+ actions: z.ZodArray<z.ZodObject<{
123
+ id: z.ZodString;
124
+ label: z.ZodString;
125
+ style: z.ZodDefault<z.ZodEnum<{
126
+ danger: "danger";
127
+ primary: "primary";
128
+ secondary: "secondary";
129
+ }>>;
130
+ }, z.core.$strip>>;
131
+ expiresAt: z.ZodOptional<z.ZodNullable<z.ZodString>>;
132
+ }, z.core.$strip>], "type">;
133
+ export type ChatBlockInput = z.output<typeof chatBlockInputSchema>;
134
+ export declare const chatBlocksInputSchema: z.ZodArray<z.ZodDiscriminatedUnion<[z.ZodObject<{
135
+ type: z.ZodLiteral<"confirm">;
136
+ id: z.ZodString;
137
+ title: z.ZodString;
138
+ description: z.ZodOptional<z.ZodNullable<z.ZodString>>;
139
+ fields: z.ZodDefault<z.ZodArray<z.ZodObject<{
140
+ label: z.ZodString;
141
+ value: z.ZodString;
142
+ }, z.core.$strip>>>;
143
+ actions: z.ZodArray<z.ZodObject<{
144
+ id: z.ZodString;
145
+ label: z.ZodString;
146
+ style: z.ZodDefault<z.ZodEnum<{
147
+ danger: "danger";
148
+ primary: "primary";
149
+ secondary: "secondary";
150
+ }>>;
151
+ }, z.core.$strip>>;
152
+ expiresAt: z.ZodOptional<z.ZodNullable<z.ZodString>>;
153
+ }, z.core.$strip>], "type">>;
154
+ /** Klick auf eine Aktion: `POST /chat/messages/:messageId/actions`. */
155
+ export declare const chatActionSchema: z.ZodObject<{
156
+ blockId: z.ZodString;
157
+ actionId: z.ZodString;
158
+ }, z.core.$strip>;
159
+ export type ChatActionInput = z.output<typeof chatActionSchema>;
160
+ /** Ist die Karte abgelaufen? Abgelaufene Karten sind grau und nicht mehr klickbar. */
161
+ export declare function blockExpired(block: Pick<ChatConfirmBlock, 'expiresAt'>, now?: number): boolean;