@mgamadeus/ddd-agents 0.5.17 → 0.6.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.
Files changed (99) hide show
  1. package/README.md +164 -6
  2. package/boundary.json +13 -0
  3. package/dist/chat.js +148 -773
  4. package/dist/chat.js.map +1 -1
  5. package/dist/chunks/{canvas-title-slot-context-DK4sfhkl.js → ConversationMarkdown-BsCjyhj4.js} +14 -43
  6. package/dist/chunks/ConversationMarkdown-BsCjyhj4.js.map +1 -0
  7. package/dist/chunks/{ConversationMessageInputComposerWidgets-B3Zf69rD.js → ConversationMessageInputComposerWidgets-CE8LpyXY.js} +10 -37
  8. package/dist/chunks/ConversationMessageInputComposerWidgets-CE8LpyXY.js.map +1 -0
  9. package/dist/chunks/VoiceBarsIcon-BIcURsBF.js +643 -0
  10. package/dist/chunks/VoiceBarsIcon-BIcURsBF.js.map +1 -0
  11. package/dist/chunks/{WebSearchResultsConversationWidget-887v8Wen.js → WebSearchResultsConversationWidget-DXhfSikV.js} +2 -2
  12. package/dist/chunks/{WebSearchResultsConversationWidget-887v8Wen.js.map → WebSearchResultsConversationWidget-DXhfSikV.js.map} +1 -1
  13. package/dist/chunks/{browser-request-interception-BdKjYz31.js → browser-request-interception-BnzFbH0m.js} +2 -2
  14. package/dist/chunks/{browser-request-interception-BdKjYz31.js.map → browser-request-interception-BnzFbH0m.js.map} +1 -1
  15. package/dist/chunks/{canvas-reducers-CwFA3rQ6.js → canvas-reducers-D-YxAR4B.js} +2 -2
  16. package/dist/chunks/{canvas-reducers-CwFA3rQ6.js.map → canvas-reducers-D-YxAR4B.js.map} +1 -1
  17. package/dist/chunks/canvas-title-slot-context-D6UXrkdJ.js +36 -0
  18. package/dist/chunks/canvas-title-slot-context-D6UXrkdJ.js.map +1 -0
  19. package/dist/chunks/{canvasBodies-C7qqThc9.js → canvasBodies-CQEBkIVw.js} +4 -4
  20. package/dist/chunks/{canvasBodies-C7qqThc9.js.map → canvasBodies-CQEBkIVw.js.map} +1 -1
  21. package/dist/chunks/{canvasStorage-i2wKVSBf.js → canvasStorage-BbEI3h-8.js} +2 -2
  22. package/dist/chunks/{canvasStorage-i2wKVSBf.js.map → canvasStorage-BbEI3h-8.js.map} +1 -1
  23. package/dist/chunks/format-agent-voice-call-duration-C-3hRc9p.js +10 -0
  24. package/dist/chunks/format-agent-voice-call-duration-C-3hRc9p.js.map +1 -0
  25. package/dist/chunks/{link-navigation-CNX8Am2L.js → link-navigation-BUcy5qWW.js} +2 -2
  26. package/dist/chunks/{link-navigation-CNX8Am2L.js.map → link-navigation-BUcy5qWW.js.map} +1 -1
  27. package/dist/chunks/{realtime-arrival-BTLE3jjt.js → realtime-arrival-BfsAPwqQ.js} +8 -3
  28. package/dist/chunks/realtime-arrival-BfsAPwqQ.js.map +1 -0
  29. package/dist/chunks/use-agents-chat-store-CuIkCz9v.js +34 -0
  30. package/dist/chunks/use-agents-chat-store-CuIkCz9v.js.map +1 -0
  31. package/dist/chunks/{widget-name-resolver-BVEuAsW5.js → widget-name-resolver-B9k-s_cF.js} +3 -3
  32. package/dist/chunks/{widget-name-resolver-BVEuAsW5.js.map → widget-name-resolver-B9k-s_cF.js.map} +1 -1
  33. package/dist/chunks/withPollingChangeSubscription-CnQnubfK.js.map +1 -1
  34. package/dist/client-testing.js +4 -4
  35. package/dist/client.js +14 -3
  36. package/dist/client.js.map +1 -1
  37. package/dist/files/i18n-keys.json +1128 -100
  38. package/dist/image-render.js +7 -7
  39. package/dist/index.js +6 -6
  40. package/dist/kit.js +2 -2
  41. package/dist/preview.js +7 -7
  42. package/dist/provider.js +1 -1
  43. package/dist/renderer.js +25 -24
  44. package/dist/renderer.js.map +1 -1
  45. package/dist/styles.css +531 -93
  46. package/dist/types/client/AgentsConversationClient.d.ts +4 -1
  47. package/dist/types/client/http/createAgentsHttpConversationClient.d.ts +2 -1
  48. package/dist/types/entries/voice-admin.d.ts +7 -0
  49. package/dist/types/entries/voice.d.ts +24 -0
  50. package/dist/types/ui/account-realtime.d.ts +50 -11
  51. package/dist/types/voice/AgentVoiceCallBand/AgentVoiceCallBand.d.ts +49 -0
  52. package/dist/types/voice/AgentVoiceCallBand/agent-voice-call-outcome-title-text-key.d.ts +8 -0
  53. package/dist/types/voice/AgentVoiceCallCaptions/AgentVoiceCallCaptions.d.ts +15 -0
  54. package/dist/types/voice/AgentVoiceCallCaptions/saved-messages-of-agent-voice-chat.d.ts +12 -0
  55. package/dist/types/voice/AgentVoiceCallProvider/AgentVoiceCallProvider.d.ts +21 -0
  56. package/dist/types/voice/AgentVoiceCallProvider/agent-voice-call-context.d.ts +17 -0
  57. package/dist/types/voice/AgentVoiceChatStartButton/AgentVoiceChatStartButton.d.ts +15 -0
  58. package/dist/types/voice/AgentVoiceIcons/AgentVoiceIcons.d.ts +10 -0
  59. package/dist/types/voice/AgentVoiceIncomingCall/AgentVoiceIncomingCall.d.ts +28 -0
  60. package/dist/types/voice/AgentVoiceInputGlow/AgentVoiceInputGlow.d.ts +11 -0
  61. package/dist/types/voice/AgentVoiceInputGlow/agent-voice-input-glow-voice.d.ts +8 -0
  62. package/dist/types/voice/admin/AgentVoiceCallConversationLink/AgentVoiceCallConversationLink.d.ts +10 -0
  63. package/dist/types/voice/admin/AgentVoiceCallDetailScreen/AgentVoiceCallDetailScreen.d.ts +27 -0
  64. package/dist/types/voice/admin/AgentVoiceCallStateBadges/AgentVoiceCallStateBadges.d.ts +12 -0
  65. package/dist/types/voice/admin/AgentVoiceCallsScreen/AgentVoiceCallsScreen.d.ts +33 -0
  66. package/dist/types/voice/admin/agent-voice-admin-api.d.ts +59 -0
  67. package/dist/types/voice/admin/agent-voice-admin-format.d.ts +38 -0
  68. package/dist/types/voice/admin/agent-voice-admin-types.d.ts +110 -0
  69. package/dist/types/voice/agent-voice-api.d.ts +114 -0
  70. package/dist/types/voice/call/agent-voice-call-elapsed-seconds.d.ts +6 -0
  71. package/dist/types/voice/call/agent-voice-call-end-reasons.d.ts +3 -0
  72. package/dist/types/voice/call/agent-voice-call-store.d.ts +111 -0
  73. package/dist/types/voice/call/agent-voice-call-turn.d.ts +4 -0
  74. package/dist/types/voice/call/build-unsaved-agent-voice-call-lines.d.ts +14 -0
  75. package/dist/types/voice/call/format-agent-voice-call-duration.d.ts +2 -0
  76. package/dist/types/voice/call/use-agent-voice-call-elapsed-seconds.d.ts +3 -0
  77. package/dist/types/voice/call/use-agent-voice-call-server-end.d.ts +15 -0
  78. package/dist/types/voice/call/use-agent-voice-call.d.ts +12 -0
  79. package/dist/types/voice/call/use-follow-agent-voice-call-conversation.d.ts +9 -0
  80. package/dist/types/voice/ring/agent-voice-caller-label.d.ts +21 -0
  81. package/dist/types/voice/ring/agent-voice-incoming-ring-list.d.ts +10 -0
  82. package/dist/types/voice/ring/agent-voice-incoming-ring-store.d.ts +47 -0
  83. package/dist/types/voice/ring/agent-voice-ring-source.d.ts +75 -0
  84. package/dist/types/voice/ring/agent-voice-ring.d.ts +35 -0
  85. package/dist/types/voice/ring/answer-incoming-agent-voice-call.d.ts +13 -0
  86. package/dist/types/voice/ring/use-agent-voice-incoming-rings.d.ts +14 -0
  87. package/dist/types/voice/ring/use-agent-voice-ring-tone.d.ts +6 -0
  88. package/dist/ui.js +82 -19
  89. package/dist/ui.js.map +1 -1
  90. package/dist/voice-admin.js +738 -0
  91. package/dist/voice-admin.js.map +1 -0
  92. package/dist/voice.js +1586 -0
  93. package/dist/voice.js.map +1 -0
  94. package/dist/widgets.js +4 -4
  95. package/package.json +27 -1
  96. package/public-api.json +156 -0
  97. package/dist/chunks/ConversationMessageInputComposerWidgets-B3Zf69rD.js.map +0 -1
  98. package/dist/chunks/canvas-title-slot-context-DK4sfhkl.js.map +0 -1
  99. package/dist/chunks/realtime-arrival-BTLE3jjt.js.map +0 -1
@@ -13,14 +13,38 @@ export interface AccountRealtimeRead {
13
13
  export declare const ACCOUNT_REALTIME_POLL_INTERVAL_MS = 5000;
14
14
  /** The pause before the one re-read of `readAfterPing` when the first read brought nothing new. */
15
15
  export declare const ACCOUNT_REALTIME_PING_REREAD_DELAY_MS = 400;
16
- export interface AccountRealtimePollOptions {
17
- /** The account read of the binding (`AgentsConversationClient.getAccountRealtimeMessages`). */
18
- readAccountRealtime: () => Promise<AccountRealtimeRead>;
16
+ /** What a subscriber of the poll is told; each hook is optional. */
17
+ export interface AccountRealtimePollSubscriber {
19
18
  /**
20
- * The arrival hook: every message once per type, key and payload (a replacement with a new payload arrives again; a
21
- * message cleared and sent again after a read saw it gone arrives again). From the poll and from the transport.
19
+ * A message that arrived: every message once per type, key and payload (a replacement with a new payload arrives
20
+ * again; a message cleared and sent again after a read saw it gone arrives again). From the poll and from the
21
+ * transport.
22
22
  */
23
- onMessage: (message: AgentRealtimeMessageDelivery) => void;
23
+ onMessage?: (message: AgentRealtimeMessageDelivery) => void;
24
+ /**
25
+ * A message that is open no more: a read answered without any message of its type and key (it was answered or
26
+ * withdrawn on the server, or its time is over). Called once, after the arrivals of the same read. A subscriber is
27
+ * told the clear only of a message it was handed, as an arrival or in the hand-over of `subscribe`, and with that
28
+ * message as it was handed to it last. A replacement under the same type and key is an arrival, never a clear. Only
29
+ * a read tells it, and only of a message that was known when the read started: while a transport is bound, the next
30
+ * `readNow()` or `readAfterPing()`.
31
+ */
32
+ onMessageCleared?: (message: AgentRealtimeMessageDelivery) => void;
33
+ }
34
+ export interface AccountRealtimePollOptions extends AccountRealtimePollSubscriber {
35
+ /**
36
+ * The account read of the binding (`AgentsConversationClient.getAccountRealtimeMessages`), called with the
37
+ * `clientId` option (undefined without one). The read always states a client id (the HTTP binding: query parameter
38
+ * `clientId`), by which the server knows a client that only polls; which id is the binding's word: the one handed
39
+ * in, else the id of its `uiClient`, else one it creates once and keeps while it lives. A binding of the host's own
40
+ * states one the same way.
41
+ */
42
+ readAccountRealtime: (clientId?: string) => Promise<AccountRealtimeRead>;
43
+ /**
44
+ * The client id the account read states, for a host that manages its own ids (8 to 64 letters, digits and `-`): it
45
+ * wins over the binding's `uiClient` and over the id the binding creates. Default: none — the binding decides.
46
+ */
47
+ clientId?: string;
24
48
  /** The credential of every read (null without a transport) — the host binds its transport with it. */
25
49
  onListenerCredential?: (credential: AgentRealtimeListenerCredential | null) => void;
26
50
  /**
@@ -32,11 +56,14 @@ export interface AccountRealtimePollOptions {
32
56
  intervalMs?: number;
33
57
  /** The pause before the one re-read after a ping. Default `ACCOUNT_REALTIME_PING_REREAD_DELAY_MS`. */
34
58
  rereadDelayMs?: number;
35
- /** A failed read (the next interval reads again). Default: ignored. */
59
+ /** A failed read (the next interval reads again; nothing arrives and nothing is cleared). Default: ignored. */
36
60
  onReadFailed?: (error: unknown) => void;
37
61
  }
38
62
  export interface AccountRealtimePoll {
39
- /** Reads at once (also while a transport is bound); resolves with the number of messages that arrived new. */
63
+ /**
64
+ * Reads at once (also while a transport is bound); resolves with the number of messages that arrived new. An answer
65
+ * that comes back after the answer of a read started later is left out (0).
66
+ */
40
67
  readNow: () => Promise<number>;
41
68
  /**
42
69
  * The arrival adapter for a host transport that carries the message: hands it to `onMessage` unless it already
@@ -49,12 +76,24 @@ export interface AccountRealtimePoll {
49
76
  * message arrived.
50
77
  */
51
78
  readAfterPing: () => Promise<boolean>;
52
- /** Stops the poll (a read in flight still hands its messages). */
79
+ /**
80
+ * Adds a subscriber after the poll was created; the hooks the poll was created with keep working beside it. The
81
+ * subscriber gets, before `subscribe` returns, the messages open now (those the last read saw and the transport
82
+ * delivered since, inside their `secondsLeft`), then every arrival and the clear of every message it was handed: a
83
+ * message past its `secondsLeft` when the subscriber came is not handed to it, and neither is its clear. Returns
84
+ * the function that removes it; the poll keeps running.
85
+ */
86
+ subscribe: (subscriber: AccountRealtimePollSubscriber) => () => void;
87
+ /**
88
+ * Stops the poll (a read in flight still hands its messages). Nothing is reported as cleared and no subscriber is
89
+ * removed: what `readNow()` or `acceptArrivedMessage()` bring afterwards still reaches them.
90
+ */
53
91
  stop: () => void;
54
92
  }
55
93
  /**
56
94
  * The account-level realtime poll of a client that shows no conversation: reads the account at once, then every
57
- * interval while no transport is bound, and hands each new message to `onMessage` once (the same message from the poll
58
- * and the transport arrives once). The client of a conversation keeps its run-state read; this is the read without one.
95
+ * interval while no transport is bound, hands each new message to `onMessage` once (the same message from the poll and
96
+ * the transport arrives once) and each message a read finds gone to `onMessageCleared` once. Further subscribers come
97
+ * and go through `subscribe`. The client of a conversation keeps its run-state read; this is the read without one.
59
98
  */
60
99
  export declare const createAccountRealtimePoll: (options: AccountRealtimePollOptions) => AccountRealtimePoll;
@@ -0,0 +1,49 @@
1
+ import type { ReactNode } from "react";
2
+ import { type AgentVoiceCallSnapshot } from "../call/agent-voice-call-store";
3
+ import { type AgentVoiceCallerLabel } from "../ring/agent-voice-caller-label";
4
+ import type { AgentVoiceRing } from "../ring/agent-voice-ring";
5
+ import { type AgentVoiceAnswerRefusal } from "../ring/answer-incoming-agent-voice-call";
6
+ export interface AgentVoiceCallIncomingRing {
7
+ ring?: AgentVoiceRing;
8
+ /** The caller line of `ring`; without one the band words the ring's own label key. */
9
+ callerLabel?: AgentVoiceCallerLabel;
10
+ isAnswering: boolean;
11
+ /** Why the last Accept did not get the call. */
12
+ refusal?: AgentVoiceAnswerRefusal;
13
+ onAccept: () => void;
14
+ /** Decline: lets the ring go. */
15
+ onDecline: () => void;
16
+ }
17
+ export interface AgentVoiceCallBandViewProps {
18
+ call: AgentVoiceCallSnapshot;
19
+ elapsedSeconds: number;
20
+ /** Talk with the agent again after an ended or failed voice chat. */
21
+ onStartVoiceChat: () => void;
22
+ /** The agent ringing this client: while no voice chat runs, the band asks to talk. */
23
+ incoming?: AgentVoiceCallIncomingRing;
24
+ /** The application's avatar of the agent, before the name (while a call runs or the agent rings). */
25
+ agentSpot?: ReactNode;
26
+ }
27
+ /**
28
+ * The voice chat in the band over the chat input: before it, the agent asking to talk (Decline, Accept); during it,
29
+ * who is on the line, for how long and whose turn it is, with Mute and End; after it, the outcome with the way to talk
30
+ * again. Driven only by its props: the band feeds it the live call, a test or a showcase feeds it fixtures.
31
+ */
32
+ export declare const AgentVoiceCallBandView: (props: AgentVoiceCallBandViewProps) => import("react/jsx-runtime").JSX.Element | null;
33
+ export interface AgentVoiceCallBandProps {
34
+ /** The application's avatar of the agent for the call (it gets the call to show whose turn it is). */
35
+ renderAgentSpot?: (call: AgentVoiceCallSnapshot) => ReactNode;
36
+ /** The chat's agent space, where the application has one: a voice chat running in another one shows nothing here. */
37
+ agentSpaceId?: number;
38
+ /**
39
+ * False while the chat that holds the band is out of sight (behind another surface): the band then hosts no ring,
40
+ * and the incoming call shows its own card. Default true.
41
+ */
42
+ isPresented?: boolean;
43
+ }
44
+ /**
45
+ * The band of the agent ringing this client and of the running (or just finished) voice chat; renders nothing while
46
+ * there is none. While presented it is where the ring is answered, so the page-level incoming call stays away. "Talk
47
+ * again" starts a voice chat in the ended call's agent space and conversation.
48
+ */
49
+ export declare const AgentVoiceCallBand: (props: AgentVoiceCallBandProps) => import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,8 @@
1
+ import type { AgentVoiceCallSnapshot } from "../call/agent-voice-call-store";
2
+ /** An ended voice chat that was connected: who or what ended it (the call's end reason, when the server ended it). */
3
+ export declare const endedAgentVoiceCallTitleTextKey: (call: Pick<AgentVoiceCallSnapshot, "endReason">) => string;
4
+ /**
5
+ * The band's title after a voice chat (`phase` `ended` or `failed`): a failed one says so; an ended one that was
6
+ * connected says who or what ended it; one hung up before it connected (nothing was said) was cancelled.
7
+ */
8
+ export declare const agentVoiceCallOutcomeTitleTextKey: (call: Pick<AgentVoiceCallSnapshot, "phase" | "connectedAtMs" | "endReason">) => string;
@@ -0,0 +1,15 @@
1
+ import { type ConversationMessageUserTheme } from "../../chat/ConversationMessage/ConversationMessageUser/ConversationMessageUser";
2
+ export interface AgentVoiceCallCaptionsProps {
3
+ /** The chat's agent space, where the application has one: a voice chat running in another one shows nothing here. */
4
+ agentSpaceId?: number;
5
+ /** The theme of the owner's line, as the chat renders the owner's messages. Default: the message component's own. */
6
+ ownerMessageTheme?: ConversationMessageUserTheme;
7
+ }
8
+ /**
9
+ * The end of the chat while a voice chat runs: what is being said that the chat does not hold yet, streamed from the
10
+ * browser as the agent's prose and the owner's bubble (the chat's own message components), each sentence giving way
11
+ * to the real message once the backend saved it. Sits inside the chat, after its message list (it reads the chat's
12
+ * messages from the chat store in the context); outside one, every line of the call shows. Renders nothing while no
13
+ * voice chat is connecting or live.
14
+ */
15
+ export declare const AgentVoiceCallCaptions: (props: AgentVoiceCallCaptionsProps) => import("react/jsx-runtime").JSX.Element | null;
@@ -0,0 +1,12 @@
1
+ import type { ChatMessage } from "../../chat/chat-message";
2
+ import type { SavedAgentVoiceCallMessage } from "../call/build-unsaved-agent-voice-call-lines";
3
+ /** What the rules below read of a chat message. */
4
+ type ChatMessageOfVoiceChat = Pick<ChatMessage, "role" | "message" | "indexInConversation">;
5
+ /** The highest index in the conversation among `messages`; -1 for none, or when no message carries an index yet. */
6
+ export declare const highestIndexInConversationOf: (messages: readonly ChatMessageOfVoiceChat[]) => number;
7
+ /**
8
+ * What the chat holds of the voice chat: the agent's and the owner's text messages saved after the voice chat started
9
+ * (an index above `highestIndexBeforeVoiceChat`), in the conversation's order, each as the speaker and the text.
10
+ */
11
+ export declare const savedMessagesOfTheVoiceChat: (messages: readonly ChatMessageOfVoiceChat[], highestIndexBeforeVoiceChat: number) => SavedAgentVoiceCallMessage[];
12
+ export {};
@@ -0,0 +1,21 @@
1
+ import { type ReactNode } from "react";
2
+ import type { AgentVoiceApi } from "../agent-voice-api";
3
+ import { type AgentVoiceConversationOfCallChangedHandler } from "../call/use-follow-agent-voice-call-conversation";
4
+ import type { AgentVoiceRingSource } from "../ring/agent-voice-ring-source";
5
+ export interface AgentVoiceCallProviderProps {
6
+ /** The adapter the call store and the ring send their requests through. */
7
+ api: AgentVoiceApi;
8
+ /** The stream of the agent's rings. Without one nothing rings in this client. */
9
+ ringSource?: AgentVoiceRingSource;
10
+ /** Called once per call when the conversation the call writes into is known: the application shows it. */
11
+ onConversationOfCallChanged?: AgentVoiceConversationOfCallChangedHandler;
12
+ children?: ReactNode;
13
+ }
14
+ /**
15
+ * Mounted once, above every voice component: binds the adapter to the call store, carries the ring source, ends the
16
+ * call here when the server ended it (the change signal of the call's conversation, from the conversation client in
17
+ * the context above the provider) and reports the call's conversation. The call itself lives in the module's store,
18
+ * not in the provider: it goes on when the provider re-renders or a chat below it closes. The voice components take
19
+ * their texts from the environment around (`AgentsEnvironment.texts`), as every other component of the package.
20
+ */
21
+ export declare const AgentVoiceCallProvider: (props: AgentVoiceCallProviderProps) => import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,17 @@
1
+ import type { AgentVoiceRingSource } from "../ring/agent-voice-ring-source";
2
+ /** What `AgentVoiceCallProvider` carries to the voice components below it. */
3
+ export interface AgentVoiceCallContextValue {
4
+ ringSource: AgentVoiceRingSource | undefined;
5
+ }
6
+ /** Without a provider: no ring source (nothing rings). */
7
+ export declare const AgentVoiceCallContext: import("react").Context<AgentVoiceCallContextValue>;
8
+ /** The ring source of the provider above (undefined: the application has no ring transport). */
9
+ export declare const useAgentVoiceRingSource: () => AgentVoiceRingSource | undefined;
10
+ /** The text function of the voice components: a text key and what its `%placeholders%` are filled with. */
11
+ export type AgentVoiceTranslateText = (key: string, replacements?: Record<string, string | number>) => string;
12
+ /**
13
+ * The text function of the voice components: the texts of the environment around (`AgentsEnvironment.texts`, a
14
+ * subtree's own over the app-wide ones) with `%agentName%` filled with the name the owner knows the agent by
15
+ * (`AgentsEnvironment.agentDisplayName`).
16
+ */
17
+ export declare const useAgentVoiceTranslateText: () => AgentVoiceTranslateText;
@@ -0,0 +1,15 @@
1
+ export interface AgentVoiceChatStartButtonProps {
2
+ /** The chat's agent space, where the application has one. */
3
+ agentSpaceId?: number;
4
+ /** The chat's conversation the voice chat continues; without one the backend creates a conversation for it. */
5
+ conversationId?: number;
6
+ /** The owner may not start a voice chat here (the application's own gate). */
7
+ disabled?: boolean;
8
+ testId?: string;
9
+ }
10
+ /**
11
+ * In a chat input's send spot while nothing is typed and no voice chat runs: starts a voice chat with the agent. An
12
+ * input outside the chat uses it too; the application shows the call's conversation when the provider reports it
13
+ * (`onConversationOfCallChanged`). Disabled while a voice chat is connecting or live.
14
+ */
15
+ export declare const AgentVoiceChatStartButton: (props: AgentVoiceChatStartButtonProps) => import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,10 @@
1
+ export interface AgentVoiceLineIconProps {
2
+ /** Edge length in px; the icon takes the current text colour. */
3
+ size?: number;
4
+ }
5
+ /** The microphone: the band's Mute and the incoming call's Accept. */
6
+ export declare const AgentVoiceMicrophoneIcon: (props: AgentVoiceLineIconProps) => import("react/jsx-runtime").JSX.Element;
7
+ /** The receiver laid down: the band's End. */
8
+ export declare const AgentVoiceHangUpIcon: (props: AgentVoiceLineIconProps) => import("react/jsx-runtime").JSX.Element;
9
+ /** The cross: Decline and the band's Close. */
10
+ export declare const AgentVoiceCloseIcon: (props: AgentVoiceLineIconProps) => import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,28 @@
1
+ import { type ReactNode } from "react";
2
+ import { type AgentVoiceCallerLabel } from "../ring/agent-voice-caller-label";
3
+ import { type AgentVoiceRing } from "../ring/agent-voice-ring";
4
+ export interface AgentVoiceIncomingCallProps {
5
+ /**
6
+ * The application's own caller line for a ring (from what it put into the ring's `callerContext`): who is asking to
7
+ * talk and, as `detail`, which of the owner's agent spaces it is. Undefined, or no resolver: the ring's label key
8
+ * through the text function.
9
+ */
10
+ resolveCallerLabel?: (ring: AgentVoiceRing) => AgentVoiceCallerLabel | undefined;
11
+ /** The application's avatar of the agent on the card. Default: the voice chat's mark. */
12
+ renderAgentSpot?: () => ReactNode;
13
+ }
14
+ /**
15
+ * The agent ringing the owner in the browser window: the one listener per client. While a ring is live it publishes it
16
+ * (the band over an open chat's input offers Decline / Accept there) and plays the ring tone once the page had a user
17
+ * interaction; with no chat band in sight (none open, or a surface covers them) it shows its own card with the same
18
+ * choices, on top of the page. Accept answers the ring and, when this client won, starts the same WebRTC call as the
19
+ * chat's voice button; Decline ends the ring for every open client. The ring goes when its deadline passed, when the
20
+ * ring source reports it cleared, or when this client answered or declined it.
21
+ *
22
+ * A ring reaches every open client of the account, whatever the client shows: the caller line can name the calling
23
+ * agent space (`resolveCallerLabel`), and Accept starts the call on the ring's own conversation.
24
+ *
25
+ * Mounted once, below `AgentVoiceCallProvider` and outside the chat, so it rings whether or not a chat is open. It
26
+ * listens while the provider carries a ring source.
27
+ */
28
+ export declare const AgentVoiceIncomingCall: (props: AgentVoiceIncomingCallProps) => import("react/jsx-runtime").JSX.Element | null;
@@ -0,0 +1,11 @@
1
+ export interface AgentVoiceInputGlowProps {
2
+ /** The chat's agent space, where the application has one: a voice chat running in another one glows nowhere here. */
3
+ agentSpaceId?: number;
4
+ }
5
+ /**
6
+ * The chat input's glow during a voice chat; renders nothing while no voice chat is connecting or live. Rendered as
7
+ * the input's underlay: its box covers the input's whole box, under the field, and the field's own surface covers the
8
+ * canvases' middle, so only what is past its edge shows. The field needs a positioned parent with its own stacking
9
+ * context.
10
+ */
11
+ export declare const AgentVoiceInputGlow: (props: AgentVoiceInputGlowProps) => import("react/jsx-runtime").JSX.Element | null;
@@ -0,0 +1,8 @@
1
+ import type { AgentVoiceCallTurn } from "../call/agent-voice-call-turn";
2
+ /** Who is making sound right now, as the input glow draws it. */
3
+ export type AgentVoiceInputGlowVoice = "agent" | "owner" | "thinking" | "quiet";
4
+ /**
5
+ * The glow's voice of a call's turn: the agent or the owner while one of them speaks, the slow breath while the agent
6
+ * thinks or the call connects, quiet for every other turn (listening, muted, a silent microphone).
7
+ */
8
+ export declare const glowVoiceOfAgentVoiceCallTurn: (turn: AgentVoiceCallTurn) => AgentVoiceInputGlowVoice;
@@ -0,0 +1,10 @@
1
+ import { type PageLinkComponent } from "@mgamadeus/ddd-admin-ui/primitives";
2
+ export interface AgentVoiceCallConversationLinkProps {
3
+ conversationId: number;
4
+ /** The host's link of the conversation; `null` = the id as text. */
5
+ href: string | null;
6
+ /** The host's router link; default the one of `AdminUiProvider.linkComponent`, else a plain `<a>` (full page load). */
7
+ linkComponent?: PageLinkComponent;
8
+ }
9
+ /** `#<conversationId>` as the host's router link (no full page load inside the admin app), or as text without a link. */
10
+ export declare const AgentVoiceCallConversationLink: ({ conversationId, href, linkComponent }: AgentVoiceCallConversationLinkProps) => import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,27 @@
1
+ import type { ReactNode } from "react";
2
+ import { type PageLinkComponent } from "@mgamadeus/ddd-admin-ui/primitives";
3
+ import type { AgentVoiceAdminApi } from "../agent-voice-admin-api";
4
+ export interface AgentVoiceCallDetailScreenProps {
5
+ /** `createAgentVoiceAdminApi(…)` of the host. */
6
+ api: AgentVoiceAdminApi;
7
+ callId: number;
8
+ /** A link back (the list), drawn left of the title. */
9
+ backLink?: ReactNode;
10
+ headerActions?: ReactNode;
11
+ /**
12
+ * The link of a conversation in the host's agent screens; `null` = no link. With it the screen offers to open the
13
+ * call's conversation, whose messages are what was said in the call.
14
+ */
15
+ buildConversationHref?: (conversationId: number) => string | null;
16
+ /** The host's router link for the conversation links; default `AdminUiProvider.linkComponent`, else a plain `<a>`. */
17
+ linkComponent?: PageLinkComponent;
18
+ }
19
+ /**
20
+ * One voice call: where it stands (the server's reading at answer time) and why it ended, who started it, its account,
21
+ * its conversation, its times (created, answered, ended, the ring deadline), its duration, the booked seconds and
22
+ * their costs, the provider it ran on and its task. The call's conversation opens through the host's link
23
+ * (`buildConversationHref`): nothing of what was said is in this screen. While voice is switched off the screen says
24
+ * so; a call the signed-in account may not read reads as not found. The task is written by the agent or the owner and
25
+ * shown as text only.
26
+ */
27
+ export declare const AgentVoiceCallDetailScreen: ({ api, callId, backLink, headerActions, buildConversationHref, linkComponent, }: AgentVoiceCallDetailScreenProps) => import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,12 @@
1
+ import type { AgentVoiceAdminCallState } from "../agent-voice-admin-types";
2
+ export interface AgentVoiceCallStateBadgesProps {
3
+ /** The server's reading of where the call stands (`callState` of the answer); without one the empty marker shows. */
4
+ callState: AgentVoiceAdminCallState | null | undefined;
5
+ /** Why the call ended (`endReason` of the call), once it has a reason. */
6
+ endReason: string | null | undefined;
7
+ }
8
+ /**
9
+ * Where a call stands (ringing, running, ended), as the server read it, and, once it has one, why it ended. An end
10
+ * reason outside the known ones (a diagnostic value of a teardown path) shows as the text it came as.
11
+ */
12
+ export declare const AgentVoiceCallStateBadges: ({ callState, endReason }: AgentVoiceCallStateBadgesProps) => import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,33 @@
1
+ import { type ReactNode } from "react";
2
+ import type { PageLinkComponent } from "@mgamadeus/ddd-admin-ui/primitives";
3
+ import type { AgentVoiceAdminApi } from "../agent-voice-admin-api";
4
+ export interface AgentVoiceCallsScreenProps {
5
+ /** `createAgentVoiceAdminApi(…)` of the host. */
6
+ api: AgentVoiceAdminApi;
7
+ /** Default "Voice calls". */
8
+ title?: ReactNode;
9
+ description?: ReactNode;
10
+ headerActions?: ReactNode;
11
+ /** Opens a call's details (the host's route, e.g. `router.push(…)`). */
12
+ onOpenCall?: (callId: number) => void;
13
+ /** Only the calls of this account (e.g. from the URL); the account filter is then left out. */
14
+ accountId?: number;
15
+ /** Only the calls that ran on this conversation. */
16
+ conversationId?: number;
17
+ /** The link of a conversation in the host's agent screens; `null` = no link. */
18
+ buildConversationHref?: (conversationId: number) => string | null;
19
+ /** The host's router link for the conversation link; default `AdminUiProvider.linkComponent`, else a plain `<a>`. */
20
+ linkComponent?: PageLinkComponent;
21
+ /** Calls per page (default 50, at most 200). */
22
+ pageSize?: number;
23
+ }
24
+ /** The most calls one page shows. */
25
+ export declare const AGENT_VOICE_CALLS_MAX_PAGE_SIZE = 200;
26
+ /**
27
+ * The voice calls the signed-in account may read, newest first: when a call began, its account, who started it, where
28
+ * it stands (the server's reading at answer time) and why it ended, its duration, the booked seconds, their costs, its
29
+ * task and its conversation; filters for the account, the day it was created, the booked seconds and the end reason.
30
+ * Needs the admin call routes mounted (`AdminAgentVoiceCallsTrait`). While voice is switched off the
31
+ * screen says so instead of listing. A call's task is written by the agent or the owner and shown as text only.
32
+ */
33
+ export declare const AgentVoiceCallsScreen: ({ api, title, description, headerActions, onOpenCall, accountId, conversationId, buildConversationHref, linkComponent, pageSize, }: AgentVoiceCallsScreenProps) => import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,59 @@
1
+ import { type ApiQueryHook, type InjectableBaseApi, type InjectedRequest, type StaticQueryFailure } from "@mgamadeus/ddd-admin-ui/logic/pure";
2
+ import type { AgentVoiceAdminCallIdArg, AgentVoiceAdminCallResponse, AgentVoiceAdminCallsArg, AgentVoiceAdminCallsResponse } from "./agent-voice-admin-types";
3
+ /** The cache tag type of the call operations (ids `LIST`, `DETAIL`). */
4
+ export declare const AGENT_VOICE_CALLS_TAG = "AdminUiAgentVoiceCalls";
5
+ /** The hooks `createAgentVoiceAdminApi` returns; the call screens take them as their `api`. */
6
+ export interface AgentVoiceAdminApi {
7
+ /** `GET /calls?filters&top&skip`: the calls the signed-in account may read, newest first. */
8
+ useAgentVoiceCallsQuery: ApiQueryHook<AgentVoiceAdminCallsArg, AgentVoiceAdminCallsResponse>;
9
+ /** `GET /calls/{callId}`: one call (404 `call_not_found`: unknown or not readable). */
10
+ useAgentVoiceCallQuery: ApiQueryHook<AgentVoiceAdminCallIdArg, AgentVoiceAdminCallResponse>;
11
+ }
12
+ export interface CreateAgentVoiceAdminApiOptions {
13
+ /** The host's RTK Query api (`createApi` with the React hooks module). */
14
+ baseApi: InjectableBaseApi;
15
+ /** Where the host mounts `AdminAgentVoiceCallsTrait`, without a trailing slash (`/api/admin/ai/voiceCalls`). */
16
+ apiPrefix: string;
17
+ }
18
+ /**
19
+ * The filter expression of the list's arguments, in the query options grammar of the route (`accountId eq '12' and
20
+ * bookedSeconds ge '60'`); undefined when nothing narrows. The date range filters the moment a call was created, so a
21
+ * call nobody answered is found too. Which accounts' calls are read at all is decided on the server.
22
+ */
23
+ export declare const buildAgentVoiceAdminCallsFilters: (arg: AgentVoiceAdminCallsArg) => string | undefined;
24
+ /** The request of every operation, on `apiPrefix`. Pure: no RTK runtime. */
25
+ export declare const buildAgentVoiceAdminRequests: (apiPrefix: string) => {
26
+ calls: (arg?: AgentVoiceAdminCallsArg) => InjectedRequest;
27
+ call: ({ callId }: AgentVoiceAdminCallIdArg) => InjectedRequest;
28
+ };
29
+ /** The operations as injected. */
30
+ export declare const agentVoiceAdminEndpointDefinitions: (apiPrefix: string) => {
31
+ readonly adminUiAgentVoiceCalls: {
32
+ readonly kind: "query";
33
+ readonly request: (arg?: AgentVoiceAdminCallsArg) => InjectedRequest;
34
+ readonly providesTags: readonly [{
35
+ readonly type: "AdminUiAgentVoiceCalls";
36
+ readonly id: "LIST";
37
+ }];
38
+ };
39
+ readonly adminUiAgentVoiceCall: {
40
+ readonly kind: "query";
41
+ readonly request: ({ callId }: AgentVoiceAdminCallIdArg) => InjectedRequest;
42
+ readonly providesTags: readonly [{
43
+ readonly type: "AdminUiAgentVoiceCalls";
44
+ readonly id: "DETAIL";
45
+ }];
46
+ };
47
+ };
48
+ /**
49
+ * Injects the call operations into the host's RTK Query api and returns their hooks. Call it once at module scope:
50
+ * `export const agentVoiceAdminApi = createAgentVoiceAdminApi({ baseApi: adminApi, apiPrefix: "/api/admin/ai/voiceCalls" });`
51
+ */
52
+ export declare const createAgentVoiceAdminApi: ({ baseApi, apiPrefix }: CreateAgentVoiceAdminApiOptions) => AgentVoiceAdminApi;
53
+ /** Fixed answers of a `createStaticAgentVoiceAdminApi`; a query without one stays loading. */
54
+ export interface StaticAgentVoiceAdminData {
55
+ calls?: (arg: AgentVoiceAdminCallsArg) => AgentVoiceAdminCallsResponse | StaticQueryFailure | undefined;
56
+ call?: (arg: AgentVoiceAdminCallIdArg) => AgentVoiceAdminCallResponse | StaticQueryFailure | undefined;
57
+ }
58
+ /** An `AgentVoiceAdminApi` answering fixed payloads, without a store or a request (showcases, tests, reviews). */
59
+ export declare const createStaticAgentVoiceAdminApi: (data: StaticAgentVoiceAdminData) => AgentVoiceAdminApi;
@@ -0,0 +1,38 @@
1
+ import type { AgentVoiceAdminCall, AgentVoiceAdminCallDerivedValues, AgentVoiceAdminCallDirection, AgentVoiceAdminCallEndReason, AgentVoiceAdminCallState, AgentVoiceAdminMoneyAmount } from "./agent-voice-admin-types";
2
+ /** Where a call stands, as the server read it (`callState` of the answers). */
3
+ export declare const AGENT_VOICE_CALL_STATE: Readonly<Record<AgentVoiceAdminCallState, import("@mgamadeus/ddd-admin-ui/logic").StatusDefinition>>;
4
+ /** `AgentVoiceCall.endReason`: the reasons the call writes itself. A diagnostic value shows as it came. */
5
+ export declare const AGENT_VOICE_CALL_END_REASON: Readonly<Record<AgentVoiceAdminCallEndReason, import("@mgamadeus/ddd-admin-ui/logic").StatusDefinition>>;
6
+ /** The end reasons a list can be filtered by, in the order the filter offers them. */
7
+ export declare const AGENT_VOICE_CALL_END_REASONS: readonly ["COMPLETED", "ENDED_BY_AGENT", "LIMIT_REACHED", "FAILED", "NOT_ANSWERED", "DECLINED", "EXPIRED", "CANCELED"];
8
+ /** `AgentVoiceCall.direction`: who started the call. */
9
+ export declare const AGENT_VOICE_CALL_DIRECTION: Readonly<Record<AgentVoiceAdminCallDirection, import("@mgamadeus/ddd-admin-ui/logic").StatusDefinition>>;
10
+ /**
11
+ * When a call began: the moment it was created (the owner opened the voice chat, or the ring started) where the
12
+ * answer carries it, else the moment it was answered; null for a call nobody answered whose creation is not sent.
13
+ */
14
+ export declare const agentVoiceAdminCallStartTimeOf: (call: Pick<AgentVoiceAdminCall, "startedAt" | "changeHistory">) => string | null;
15
+ /** How long a call lasted, from the moment it was answered to its end; null while it runs or when nobody answered. */
16
+ export declare const agentVoiceAdminCallDurationInSecondsOf: (call: Pick<AgentVoiceAdminCall, "startedAt" | "endedAt">) => number | null;
17
+ /**
18
+ * What the server derived for the list's calls (the state, the costs), by call id. A call the answer names no entry
19
+ * for has none here: its row then shows no state and no costs.
20
+ */
21
+ export declare const agentVoiceAdminCallDerivedValuesByCallIdOf: (agentVoiceCallDerivedValues: readonly AgentVoiceAdminCallDerivedValues[] | null | undefined) => ReadonlyMap<number, AgentVoiceAdminCallDerivedValues>;
22
+ /** A call's costs, rounded, in the UI language. Call it at render time, so a language switch formats anew. */
23
+ export declare const formatAgentVoiceAdminCallCosts: (bookedCosts: AgentVoiceAdminMoneyAmount) => string;
24
+ /**
25
+ * The viewer's calendar day `YYYY-MM-DD` as a moment in UTC: its first second, or with `isEndOfDay` its last.
26
+ * Undefined for an empty value or a day the calendar lacks.
27
+ */
28
+ export declare const toAgentVoiceAdminDayBound: (day: string, isEndOfDay: boolean) => string | undefined;
29
+ /** A whole, non-negative number typed into a filter (an account id, seconds); undefined for anything else. */
30
+ export declare const readAgentVoiceAdminWholeNumber: (text: string) => number | undefined;
31
+ /** The error codes of the call routes a screen shows as a state of its own. */
32
+ export declare const AGENT_VOICE_ADMIN_ERROR_FEATURE_NOT_AVAILABLE = "feature_not_available";
33
+ export declare const AGENT_VOICE_ADMIN_ERROR_CALL_NOT_FOUND = "call_not_found";
34
+ /**
35
+ * Whether a failed request was refused with `errorCode`. The routes answer the code as the error message; a base
36
+ * query that translates error bodies keeps the original beside it (`errorEnglish`).
37
+ */
38
+ export declare const isAgentVoiceAdminError: (error: unknown, errorCode: string) => boolean;
@@ -0,0 +1,110 @@
1
+ /** `AgentVoiceCall.direction`: `INBOUND` the owner called the agent, `OUTBOUND` the agent rang the owner. */
2
+ export type AgentVoiceAdminCallDirection = "INBOUND" | "OUTBOUND";
3
+ /** The end reasons the call writes itself; the teardown paths write diagnostic values of their own beside them. */
4
+ export type AgentVoiceAdminCallEndReason = "COMPLETED" | "LIMIT_REACHED" | "FAILED" | "NOT_ANSWERED" | "DECLINED" | "EXPIRED" | "CANCELED" | "ENDED_BY_AGENT";
5
+ /**
6
+ * Where a call stands: it rings, it was answered and runs, or it is over. The server's reading at the time it answers:
7
+ * a call a dead session worker left open, or a ring past its deadline, reads `ENDED` although it has no `endedAt`. A
8
+ * screen shows it as it came and derives no state from the call's times.
9
+ */
10
+ export type AgentVoiceAdminCallState = "RINGING" | "IN_PROGRESS" | "ENDED";
11
+ export interface AgentVoiceAdminChangeHistory {
12
+ createdTime?: string | null;
13
+ modifiedTime?: string | null;
14
+ }
15
+ /** One voice call as both routes answer it. */
16
+ export interface AgentVoiceAdminCall {
17
+ id: number;
18
+ /** The account the call belongs to. */
19
+ accountId?: number | null;
20
+ direction: AgentVoiceAdminCallDirection | string;
21
+ /** When the call was answered; missing = never answered (yet). */
22
+ startedAt?: string | null;
23
+ /** When it hung up; missing = still ringing or running. */
24
+ endedAt?: string | null;
25
+ /** When the ringing stops; missing for a call the owner opened. */
26
+ ringDeadlineAt?: string | null;
27
+ /** Why it ended: an `AgentVoiceAdminCallEndReason`, or a diagnostic value of a teardown path. */
28
+ endReason?: AgentVoiceAdminCallEndReason | string | null;
29
+ /** The seconds booked as usage so far. */
30
+ bookedSeconds: number;
31
+ /** The conversation the call ran on. */
32
+ aiConversationId?: number | null;
33
+ /** What the agent works on in the call. Written by the agent or the owner: shown as text only. */
34
+ callTask?: string | null;
35
+ /** The name of the provider adapter the call runs on. */
36
+ voiceProvider?: string | null;
37
+ /** The provider's id of the session. */
38
+ providerCallId?: string | null;
39
+ /** The conversation in which the agent itself started the call. */
40
+ startedByAgentInConversationId?: number | null;
41
+ /** Present when the application's serializer settings keep it. */
42
+ changeHistory?: AgentVoiceAdminChangeHistory | null;
43
+ }
44
+ export interface AgentVoiceAdminElements<T> {
45
+ elements?: T[];
46
+ }
47
+ export interface AgentVoiceAdminCurrency {
48
+ /** `USD` for a catalog price. */
49
+ isoCode: string;
50
+ displaySymbolBeforeAmount?: boolean | null;
51
+ }
52
+ /** A money value. `amount` is unrounded (`0.10799999999999998` is a real value): round it when showing it. */
53
+ export interface AgentVoiceAdminMoneyAmount {
54
+ amount: number;
55
+ currency: AgentVoiceAdminCurrency;
56
+ }
57
+ /** What the server derives for one call of the list. */
58
+ export interface AgentVoiceAdminCallDerivedValues {
59
+ /** The `id` of the call. */
60
+ callId: number;
61
+ /** Where the call stands, read on the server with one clock reading for all rows of the answer. */
62
+ callState: AgentVoiceAdminCallState;
63
+ /** The costs of the call's booked seconds; missing = no price is known for its model, or nothing was booked. */
64
+ bookedCosts?: AgentVoiceAdminMoneyAmount | null;
65
+ }
66
+ /** `GET /calls`: the calls the signed-in account may read, newest first. The answer carries no total count. */
67
+ export interface AgentVoiceAdminCallsResponse {
68
+ agentVoiceCalls: AgentVoiceAdminElements<AgentVoiceAdminCall>;
69
+ /** One entry per call of `agentVoiceCalls.elements`, in the same order; joined by `callId`. */
70
+ agentVoiceCallDerivedValues: AgentVoiceAdminCallDerivedValues[];
71
+ }
72
+ /** `GET /calls/{callId}`: one call with what a screen would otherwise compute or look up. */
73
+ export interface AgentVoiceAdminCallResponse {
74
+ agentVoiceCall: AgentVoiceAdminCall;
75
+ /** Where the call stands, read on the server at answer time. */
76
+ callState: AgentVoiceAdminCallState;
77
+ /** `endedAt - startedAt`; missing while the call runs or when nobody answered. */
78
+ durationInSeconds?: number | null;
79
+ bookedSeconds: number;
80
+ /** The costs of the booked seconds; missing = no price is known for the call's model, or nothing was booked. */
81
+ bookedCosts?: AgentVoiceAdminMoneyAmount | null;
82
+ endReason?: AgentVoiceAdminCallEndReason | string | null;
83
+ /** The conversation whose messages are the transcript of the call. */
84
+ conversationId?: number | null;
85
+ }
86
+ /** The filters and the page of the call list; a filter left out does not narrow. */
87
+ export interface AgentVoiceAdminCallsArg {
88
+ /** Only the calls of this account (inside what the signed-in account may read). */
89
+ accountId?: number;
90
+ /** Only the calls that ran on this conversation. */
91
+ conversationId?: number;
92
+ /**
93
+ * Only the calls created at or after this moment: a date-time `Y-m-d H:i:s` in the zone of the backend's date-times
94
+ * (the screens send UTC, as the admin UI's date cells read it), or a day `Y-m-d`.
95
+ */
96
+ createdFrom?: string;
97
+ /** Only the calls created at or before this moment; the same form as `createdFrom`. */
98
+ createdTo?: string;
99
+ /** Only the calls with at least this many booked seconds. */
100
+ bookedSecondsFrom?: number;
101
+ /** Only the calls with at most this many booked seconds. */
102
+ bookedSecondsTo?: number;
103
+ /** Only the calls that ended for this reason. */
104
+ endReason?: AgentVoiceAdminCallEndReason | string;
105
+ limit?: number;
106
+ offset?: number;
107
+ }
108
+ export interface AgentVoiceAdminCallIdArg {
109
+ callId: number;
110
+ }