@athenaintel/react 0.43.0 → 0.48.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/README.md +215 -3
- package/dist/agent-runtime/src/answer-label.cjs +137 -0
- package/dist/agent-runtime/src/answer-label.cjs.map +1 -0
- package/dist/agent-runtime/src/answer-label.d.ts +104 -0
- package/dist/agent-runtime/src/answer-label.js +137 -0
- package/dist/agent-runtime/src/answer-label.js.map +1 -0
- package/dist/agent-runtime/src/answer-rows.cjs +180 -0
- package/dist/agent-runtime/src/answer-rows.cjs.map +1 -0
- package/dist/agent-runtime/src/answer-rows.d.ts +86 -0
- package/dist/agent-runtime/src/answer-rows.js +180 -0
- package/dist/agent-runtime/src/answer-rows.js.map +1 -0
- package/dist/agent-runtime/src/client-tool-bridge.cjs +15 -15
- package/dist/agent-runtime/src/client-tool-bridge.cjs.map +1 -1
- package/dist/agent-runtime/src/conversation-index.cjs +8 -8
- package/dist/agent-runtime/src/conversation-index.cjs.map +1 -1
- package/dist/agent-runtime/src/decision-checks.cjs +207 -0
- package/dist/agent-runtime/src/decision-checks.cjs.map +1 -0
- package/dist/agent-runtime/src/decision-checks.d.ts +142 -0
- package/dist/agent-runtime/src/decision-checks.js +207 -0
- package/dist/agent-runtime/src/decision-checks.js.map +1 -0
- package/dist/agent-runtime/src/desktop-handoff.d.ts +12 -0
- package/dist/agent-runtime/src/errors.cjs +18 -0
- package/dist/agent-runtime/src/errors.cjs.map +1 -1
- package/dist/agent-runtime/src/errors.d.ts +7 -0
- package/dist/agent-runtime/src/errors.js +18 -0
- package/dist/agent-runtime/src/errors.js.map +1 -1
- package/dist/agent-runtime/src/generated/runconfig-contract.cjs +12 -0
- package/dist/agent-runtime/src/generated/runconfig-contract.cjs.map +1 -1
- package/dist/agent-runtime/src/generated/runconfig-contract.d.ts +6 -6
- package/dist/agent-runtime/src/generated/runconfig-contract.js +12 -0
- package/dist/agent-runtime/src/generated/runconfig-contract.js.map +1 -1
- package/dist/agent-runtime/src/handoff-arrival.cjs +60 -0
- package/dist/agent-runtime/src/handoff-arrival.cjs.map +1 -0
- package/dist/agent-runtime/src/handoff-arrival.d.ts +46 -0
- package/dist/agent-runtime/src/handoff-arrival.js +60 -0
- package/dist/agent-runtime/src/handoff-arrival.js.map +1 -0
- package/dist/agent-runtime/src/index.d.ts +14 -8
- package/dist/agent-runtime/src/interrupts.cjs +43 -18
- package/dist/agent-runtime/src/interrupts.cjs.map +1 -1
- package/dist/agent-runtime/src/interrupts.d.ts +19 -2
- package/dist/agent-runtime/src/interrupts.js +28 -3
- package/dist/agent-runtime/src/interrupts.js.map +1 -1
- package/dist/agent-runtime/src/lane-history.cjs +8 -8
- package/dist/agent-runtime/src/lane-history.cjs.map +1 -1
- package/dist/agent-runtime/src/messages.cjs +43 -8
- package/dist/agent-runtime/src/messages.cjs.map +1 -1
- package/dist/agent-runtime/src/messages.d.ts +25 -3
- package/dist/agent-runtime/src/messages.js +43 -8
- package/dist/agent-runtime/src/messages.js.map +1 -1
- package/dist/agent-runtime/src/offline-status.cjs +36 -0
- package/dist/agent-runtime/src/offline-status.cjs.map +1 -0
- package/dist/agent-runtime/src/offline-status.d.ts +118 -3
- package/dist/agent-runtime/src/offline-status.js +36 -0
- package/dist/agent-runtime/src/offline-status.js.map +1 -0
- package/dist/agent-runtime/src/queue.cjs +0 -9
- package/dist/agent-runtime/src/queue.cjs.map +1 -1
- package/dist/agent-runtime/src/queue.js +0 -9
- package/dist/agent-runtime/src/queue.js.map +1 -1
- package/dist/agent-runtime/src/quota-safe-local-storage-session.cjs +9 -9
- package/dist/agent-runtime/src/quota-safe-local-storage-session.cjs.map +1 -1
- package/dist/agent-runtime/src/runtime-catalog.cjs +42 -0
- package/dist/agent-runtime/src/runtime-catalog.cjs.map +1 -0
- package/dist/agent-runtime/src/runtime-catalog.d.ts +35 -0
- package/dist/agent-runtime/src/runtime-catalog.js +42 -0
- package/dist/agent-runtime/src/runtime-catalog.js.map +1 -0
- package/dist/agent-runtime/src/runtime-messages.cjs.map +1 -1
- package/dist/agent-runtime/src/runtime-messages.d.ts +1 -1
- package/dist/agent-runtime/src/runtime-messages.js.map +1 -1
- package/dist/agent-runtime/src/runtime.d.ts +40 -0
- package/dist/agent-runtime/src/statewire-suspended.cjs +3 -3
- package/dist/agent-runtime/src/statewire-suspended.cjs.map +1 -1
- package/dist/agent-runtime/src/subagents.cjs +32 -2
- package/dist/agent-runtime/src/subagents.cjs.map +1 -1
- package/dist/agent-runtime/src/subagents.d.ts +9 -0
- package/dist/agent-runtime/src/subagents.js +30 -0
- package/dist/agent-runtime/src/subagents.js.map +1 -1
- package/dist/agent-runtime/src/thread-driver.cjs +67 -0
- package/dist/agent-runtime/src/thread-driver.cjs.map +1 -0
- package/dist/agent-runtime/src/thread-driver.d.ts +49 -0
- package/dist/agent-runtime/src/thread-driver.js +67 -0
- package/dist/agent-runtime/src/thread-driver.js.map +1 -0
- package/dist/agent-runtime/src/thread-handoff-flow-machine.d.ts +172 -0
- package/dist/agent-runtime/src/thread-handoff-protocol.d.ts +756 -0
- package/dist/agent-runtime/src/thread-handoff-qr.d.ts +11 -0
- package/dist/agent-runtime/src/thread-handoff.d.ts +3 -364
- package/dist/agent-runtime/src/thread-status.cjs +3 -3
- package/dist/agent-runtime/src/thread-status.cjs.map +1 -1
- package/dist/agent-runtime/src/tool-metadata.cjs +210 -25
- package/dist/agent-runtime/src/tool-metadata.cjs.map +1 -1
- package/dist/agent-runtime/src/tool-metadata.d.ts +12 -0
- package/dist/agent-runtime/src/tool-metadata.js +210 -25
- package/dist/agent-runtime/src/tool-metadata.js.map +1 -1
- package/dist/agent-runtime/src/tool-names.cjs +2 -0
- package/dist/agent-runtime/src/tool-names.cjs.map +1 -1
- package/dist/agent-runtime/src/tool-names.d.ts +2 -0
- package/dist/agent-runtime/src/tool-names.js +2 -0
- package/dist/agent-runtime/src/tool-names.js.map +1 -1
- package/dist/agent-runtime/src/types.d.ts +10 -2
- package/dist/agent-runtime/src/use-conversation-list.cjs +11 -11
- package/dist/agent-runtime/src/use-conversation-list.cjs.map +1 -1
- package/dist/agent-runtime/src/use-deep-agent-chat-outbox.cjs +24 -19
- package/dist/agent-runtime/src/use-deep-agent-chat-outbox.cjs.map +1 -1
- package/dist/agent-runtime/src/use-deep-agent-chat-outbox.d.ts +2 -1
- package/dist/agent-runtime/src/use-deep-agent-chat-outbox.js +6 -1
- package/dist/agent-runtime/src/use-deep-agent-chat-outbox.js.map +1 -1
- package/dist/agent-runtime/src/use-deep-agent-config.cjs +14 -14
- package/dist/agent-runtime/src/use-deep-agent-config.cjs.map +1 -1
- package/dist/agent-runtime/src/use-deep-agent-edit-submit.cjs +6 -6
- package/dist/agent-runtime/src/use-deep-agent-edit-submit.cjs.map +1 -1
- package/dist/agent-runtime/src/use-deep-agent-runtime.cjs +16 -16
- package/dist/agent-runtime/src/use-deep-agent-runtime.cjs.map +1 -1
- package/dist/agent-runtime/src/use-deep-agent-thread.cjs +45 -45
- package/dist/agent-runtime/src/use-deep-agent-thread.cjs.map +1 -1
- package/dist/agent-runtime/src/use-deep-agent-voice.cjs +547 -124
- package/dist/agent-runtime/src/use-deep-agent-voice.cjs.map +1 -1
- package/dist/agent-runtime/src/use-deep-agent-voice.d.ts +129 -10
- package/dist/agent-runtime/src/use-deep-agent-voice.js +487 -64
- package/dist/agent-runtime/src/use-deep-agent-voice.js.map +1 -1
- package/dist/agent-runtime/src/use-deep-agent-window-sync.cjs +26 -26
- package/dist/agent-runtime/src/use-deep-agent-window-sync.cjs.map +1 -1
- package/dist/agent-runtime/src/use-historical-edit-attachments.cjs +4 -4
- package/dist/agent-runtime/src/use-historical-edit-attachments.cjs.map +1 -1
- package/dist/agent-runtime/src/use-thread-handoff-flow.d.ts +28 -26
- package/dist/agent-runtime/src/voice-media.cjs +117 -0
- package/dist/agent-runtime/src/voice-media.cjs.map +1 -0
- package/dist/agent-runtime/src/voice-media.d.ts +49 -0
- package/dist/agent-runtime/src/voice-media.js +117 -0
- package/dist/agent-runtime/src/voice-media.js.map +1 -0
- package/dist/agent-runtime/src/voice-wire-types.d.ts +32 -0
- package/dist/assets/AssetPanel.cjs +11 -11
- package/dist/assets/AssetPanel.cjs.map +1 -1
- package/dist/assets/AthenaAssetEmbed.cjs +11 -9
- package/dist/assets/AthenaAssetEmbed.cjs.map +1 -1
- package/dist/assets/AthenaAssetEmbed.d.ts +7 -0
- package/dist/assets/AthenaAssetEmbed.js +4 -2
- package/dist/assets/AthenaAssetEmbed.js.map +1 -1
- package/dist/assets/AthenaLayout.cjs +16 -16
- package/dist/assets/AthenaLayout.cjs.map +1 -1
- package/dist/assets/use-asset-content.cjs +4 -4
- package/dist/assets/use-asset-content.cjs.map +1 -1
- package/dist/assets/use-asset-embed.cjs +14 -7
- package/dist/assets/use-asset-embed.cjs.map +1 -1
- package/dist/assets/use-asset-embed.d.ts +11 -1
- package/dist/assets/use-asset-embed.js +10 -3
- package/dist/assets/use-asset-embed.js.map +1 -1
- package/dist/auth/AthenaAuthContext.cjs +3 -3
- package/dist/auth/AthenaAuthContext.cjs.map +1 -1
- package/dist/auth/AthenaAuthProvider.cjs +8 -8
- package/dist/auth/AthenaAuthProvider.cjs.map +1 -1
- package/dist/auth/AthenaCredentialSourceContext.cjs +5 -5
- package/dist/auth/AthenaCredentialSourceContext.cjs.map +1 -1
- package/dist/auth/AthenaSSOProvider.cjs +14 -14
- package/dist/auth/AthenaSSOProvider.cjs.map +1 -1
- package/dist/auth/credential-source.cjs +26 -13
- package/dist/auth/credential-source.cjs.map +1 -1
- package/dist/auth/credential-source.d.ts +8 -0
- package/dist/auth/credential-source.js +26 -13
- package/dist/auth/credential-source.js.map +1 -1
- package/dist/catalog/agent-model-options.cjs +25 -17
- package/dist/catalog/agent-model-options.cjs.map +1 -1
- package/dist/catalog/agent-model-options.d.ts +38 -5
- package/dist/catalog/agent-model-options.js +25 -17
- package/dist/catalog/agent-model-options.js.map +1 -1
- package/dist/catalog/channel-refusal.cjs +36 -0
- package/dist/catalog/channel-refusal.cjs.map +1 -0
- package/dist/catalog/channel-refusal.d.ts +29 -0
- package/dist/catalog/channel-refusal.js +36 -0
- package/dist/catalog/channel-refusal.js.map +1 -0
- package/dist/catalog/chat-pickers.cjs +60 -24
- package/dist/catalog/chat-pickers.cjs.map +1 -1
- package/dist/catalog/chat-pickers.d.ts +12 -2
- package/dist/catalog/chat-pickers.js +56 -20
- package/dist/catalog/chat-pickers.js.map +1 -1
- package/dist/catalog/runtime-catalog.cjs +89 -23
- package/dist/catalog/runtime-catalog.cjs.map +1 -1
- package/dist/catalog/runtime-catalog.d.ts +8 -2
- package/dist/catalog/runtime-catalog.js +83 -17
- package/dist/catalog/runtime-catalog.js.map +1 -1
- package/dist/catalog/use-athena-chat-mode.cjs +12 -12
- package/dist/catalog/use-athena-chat-mode.cjs.map +1 -1
- package/dist/chat/AthenaChat.cjs +155 -67
- package/dist/chat/AthenaChat.cjs.map +1 -1
- package/dist/chat/AthenaChat.d.ts +42 -2
- package/dist/chat/AthenaChat.js +106 -18
- package/dist/chat/AthenaChat.js.map +1 -1
- package/dist/chat/AthenaChatErrorBoundary.cjs +3 -3
- package/dist/chat/AthenaChatErrorBoundary.cjs.map +1 -1
- package/dist/chat/DrivingOnChip.cjs +23 -0
- package/dist/chat/DrivingOnChip.cjs.map +1 -0
- package/dist/chat/DrivingOnChip.d.ts +17 -0
- package/dist/chat/DrivingOnChip.js +23 -0
- package/dist/chat/DrivingOnChip.js.map +1 -0
- package/dist/chat/StatewireApprovalCard.cjs +125 -31
- package/dist/chat/StatewireApprovalCard.cjs.map +1 -1
- package/dist/chat/StatewireApprovalCard.d.ts +73 -1
- package/dist/chat/StatewireApprovalCard.js +115 -21
- package/dist/chat/StatewireApprovalCard.js.map +1 -1
- package/dist/chat/StatewireClientToolBridge.cjs +2 -2
- package/dist/chat/StatewireClientToolBridge.cjs.map +1 -1
- package/dist/chat/StatewireQueuedMessages.cjs +25 -63
- package/dist/chat/StatewireQueuedMessages.cjs.map +1 -1
- package/dist/chat/StatewireQueuedMessages.d.ts +11 -13
- package/dist/chat/StatewireQueuedMessages.js +16 -54
- package/dist/chat/StatewireQueuedMessages.js.map +1 -1
- package/dist/chat/WaitingOnYouBanner.cjs +3 -3
- package/dist/chat/WaitingOnYouBanner.cjs.map +1 -1
- package/dist/chat/athena-chat-welcome.cjs +2 -2
- package/dist/chat/athena-chat-welcome.cjs.map +1 -1
- package/dist/chat/athena-citation-links.cjs +5 -5
- package/dist/chat/athena-citation-links.cjs.map +1 -1
- package/dist/chat/athena-composer-controls.cjs +26 -16
- package/dist/chat/athena-composer-controls.cjs.map +1 -1
- package/dist/chat/athena-composer-controls.d.ts +6 -0
- package/dist/chat/athena-composer-controls.js +26 -16
- package/dist/chat/athena-composer-controls.js.map +1 -1
- package/dist/chat/athena-turn-end-status.cjs +42 -0
- package/dist/chat/athena-turn-end-status.cjs.map +1 -0
- package/dist/chat/athena-turn-end-status.d.ts +24 -0
- package/dist/chat/athena-turn-end-status.js +42 -0
- package/dist/chat/athena-turn-end-status.js.map +1 -0
- package/dist/chat/browser-decision-check.cjs +131 -0
- package/dist/chat/browser-decision-check.cjs.map +1 -0
- package/dist/chat/browser-decision-check.d.ts +61 -0
- package/dist/chat/browser-decision-check.js +131 -0
- package/dist/chat/browser-decision-check.js.map +1 -0
- package/dist/chat/chat-outbox-rows.cjs +3 -3
- package/dist/chat/chat-outbox-rows.cjs.map +1 -1
- package/dist/chat/chat-voice-controls.cjs +93 -28
- package/dist/chat/chat-voice-controls.cjs.map +1 -1
- package/dist/chat/chat-voice-controls.d.ts +36 -2
- package/dist/chat/chat-voice-controls.js +89 -24
- package/dist/chat/chat-voice-controls.js.map +1 -1
- package/dist/chat/composer-keyboard-hint.cjs +5 -5
- package/dist/chat/composer-keyboard-hint.cjs.map +1 -1
- package/dist/chat/device-operation.cjs +29 -0
- package/dist/chat/device-operation.cjs.map +1 -0
- package/dist/chat/device-operation.d.ts +34 -0
- package/dist/chat/device-operation.js +29 -0
- package/dist/chat/device-operation.js.map +1 -0
- package/dist/chat/super-grouping/CollapsibleGroup.cjs +14 -14
- package/dist/chat/super-grouping/CollapsibleGroup.cjs.map +1 -1
- package/dist/chat/super-grouping/GroupedMessageParts.cjs +4 -4
- package/dist/chat/super-grouping/GroupedMessageParts.cjs.map +1 -1
- package/dist/chat/super-grouping/SuperGroupingCard.cjs +52 -36
- package/dist/chat/super-grouping/SuperGroupingCard.cjs.map +1 -1
- package/dist/chat/super-grouping/SuperGroupingCard.d.ts +19 -4
- package/dist/chat/super-grouping/SuperGroupingCard.js +29 -13
- package/dist/chat/super-grouping/SuperGroupingCard.js.map +1 -1
- package/dist/chat/super-grouping/SuperGroupingTranscript.cjs +32 -32
- package/dist/chat/super-grouping/SuperGroupingTranscript.cjs.map +1 -1
- package/dist/chat/super-grouping/SuperGroupingTranscript.js +3 -3
- package/dist/chat/super-grouping/SuperGroupingTranscript.js.map +1 -1
- package/dist/chat/super-grouping/ToolTimeline.cjs +73 -40
- package/dist/chat/super-grouping/ToolTimeline.cjs.map +1 -1
- package/dist/chat/super-grouping/ToolTimeline.d.ts +10 -2
- package/dist/chat/super-grouping/ToolTimeline.js +69 -36
- package/dist/chat/super-grouping/ToolTimeline.js.map +1 -1
- package/dist/chat/super-grouping/activity-timeline.cjs +47 -12
- package/dist/chat/super-grouping/activity-timeline.cjs.map +1 -1
- package/dist/chat/super-grouping/activity-timeline.d.ts +21 -0
- package/dist/chat/super-grouping/activity-timeline.js +47 -12
- package/dist/chat/super-grouping/activity-timeline.js.map +1 -1
- package/dist/chat/super-grouping/grouping-function.cjs +4 -0
- package/dist/chat/super-grouping/grouping-function.cjs.map +1 -1
- package/dist/chat/super-grouping/grouping-function.d.ts +7 -0
- package/dist/chat/super-grouping/grouping-function.js +5 -1
- package/dist/chat/super-grouping/grouping-function.js.map +1 -1
- package/dist/chat/super-grouping/index.cjs +6 -0
- package/dist/chat/super-grouping/index.cjs.map +1 -1
- package/dist/chat/super-grouping/index.d.ts +5 -2
- package/dist/chat/super-grouping/index.js +7 -1
- package/dist/chat/super-grouping/index.js.map +1 -1
- package/dist/chat/super-grouping/tool-part-placement.cjs +17 -0
- package/dist/chat/super-grouping/tool-part-placement.cjs.map +1 -0
- package/dist/chat/super-grouping/tool-part-placement.d.ts +22 -0
- package/dist/chat/super-grouping/tool-part-placement.js +17 -0
- package/dist/chat/super-grouping/tool-part-placement.js.map +1 -0
- package/dist/chat/thread-scroll-to-bottom.cjs +2 -2
- package/dist/chat/thread-scroll-to-bottom.cjs.map +1 -1
- package/dist/chat/thread-scroll-to-bottom.d.ts +10 -7
- package/dist/chat/thread-scroll-to-bottom.js +2 -2
- package/dist/chat/thread-scroll-to-bottom.js.map +1 -1
- package/dist/chat/tooltip-icon-button.cjs +2 -2
- package/dist/chat/tooltip-icon-button.cjs.map +1 -1
- package/dist/chat/use-athena-voice-live.cjs +11 -0
- package/dist/chat/use-athena-voice-live.cjs.map +1 -0
- package/dist/chat/use-athena-voice-live.d.ts +11 -0
- package/dist/chat/use-athena-voice-live.js +11 -0
- package/dist/chat/use-athena-voice-live.js.map +1 -0
- package/dist/chat/use-statewire-approval-request.cjs +56 -24
- package/dist/chat/use-statewire-approval-request.cjs.map +1 -1
- package/dist/chat/use-statewire-approval-request.d.ts +33 -4
- package/dist/chat/use-statewire-approval-request.js +41 -9
- package/dist/chat/use-statewire-approval-request.js.map +1 -1
- package/dist/chat-ui/auth/sign-in-card.cjs +2 -2
- package/dist/chat-ui/auth/sign-in-card.cjs.map +1 -1
- package/dist/chat-ui/composer/tiptap-composer.cjs +138 -107
- package/dist/chat-ui/composer/tiptap-composer.cjs.map +1 -1
- package/dist/chat-ui/composer/tiptap-composer.d.ts +20 -4
- package/dist/chat-ui/composer/tiptap-composer.js +85 -54
- package/dist/chat-ui/composer/tiptap-composer.js.map +1 -1
- package/dist/chat-ui/header/conversation-history-panel.cjs +49 -23
- package/dist/chat-ui/header/conversation-history-panel.cjs.map +1 -1
- package/dist/chat-ui/header/conversation-history-panel.d.ts +12 -1
- package/dist/chat-ui/header/conversation-history-panel.js +38 -12
- package/dist/chat-ui/header/conversation-history-panel.js.map +1 -1
- package/dist/chat-ui/index.cjs +18 -0
- package/dist/chat-ui/index.cjs.map +1 -1
- package/dist/chat-ui/index.d.ts +7 -1
- package/dist/chat-ui/index.js +18 -0
- package/dist/chat-ui/index.js.map +1 -1
- package/dist/chat-ui/mentions/mention-chip.cjs +4 -4
- package/dist/chat-ui/mentions/mention-chip.cjs.map +1 -1
- package/dist/chat-ui/mentions/suggestions/components/mention-suggestion-list.cjs +10 -9
- package/dist/chat-ui/mentions/suggestions/components/mention-suggestion-list.cjs.map +1 -1
- package/dist/chat-ui/mentions/suggestions/components/mention-suggestion-list.js +3 -2
- package/dist/chat-ui/mentions/suggestions/components/mention-suggestion-list.js.map +1 -1
- package/dist/chat-ui/mentions/suggestions/components/mention-suggestion-popup.cjs +2 -2
- package/dist/chat-ui/mentions/suggestions/components/mention-suggestion-popup.cjs.map +1 -1
- package/dist/chat-ui/mentions/suggestions/components/menu-list.cjs +29 -6
- package/dist/chat-ui/mentions/suggestions/components/menu-list.cjs.map +1 -1
- package/dist/chat-ui/mentions/suggestions/components/menu-list.d.ts +7 -1
- package/dist/chat-ui/mentions/suggestions/components/menu-list.js +25 -2
- package/dist/chat-ui/mentions/suggestions/components/menu-list.js.map +1 -1
- package/dist/chat-ui/mentions/suggestions/components/use-keyboard-navigation.cjs +2 -2
- package/dist/chat-ui/mentions/suggestions/components/use-keyboard-navigation.cjs.map +1 -1
- package/dist/chat-ui/mentions/suggestions/components/use-menu-navigation.cjs +2 -2
- package/dist/chat-ui/mentions/suggestions/components/use-menu-navigation.cjs.map +1 -1
- package/dist/chat-ui/mentions/suggestions/data/api-client.cjs +3 -3
- package/dist/chat-ui/mentions/suggestions/data/api-client.cjs.map +1 -1
- package/dist/chat-ui/mentions/suggestions/data/orchestrator.cjs +56 -2
- package/dist/chat-ui/mentions/suggestions/data/orchestrator.cjs.map +1 -1
- package/dist/chat-ui/mentions/suggestions/data/orchestrator.d.ts +12 -0
- package/dist/chat-ui/mentions/suggestions/data/orchestrator.js +56 -2
- package/dist/chat-ui/mentions/suggestions/data/orchestrator.js.map +1 -1
- package/dist/chat-ui/mentions/suggestions/data/sources/index.cjs +24 -3
- package/dist/chat-ui/mentions/suggestions/data/sources/index.cjs.map +1 -1
- package/dist/chat-ui/mentions/suggestions/data/sources/index.d.ts +7 -0
- package/dist/chat-ui/mentions/suggestions/data/sources/index.js +24 -3
- package/dist/chat-ui/mentions/suggestions/data/sources/index.js.map +1 -1
- package/dist/chat-ui/mentions/suggestions/data/use-mention-suggestions.cjs +35 -13
- package/dist/chat-ui/mentions/suggestions/data/use-mention-suggestions.cjs.map +1 -1
- package/dist/chat-ui/mentions/suggestions/data/use-mention-suggestions.d.ts +15 -1
- package/dist/chat-ui/mentions/suggestions/data/use-mention-suggestions.js +28 -6
- package/dist/chat-ui/mentions/suggestions/data/use-mention-suggestions.js.map +1 -1
- package/dist/chat-ui/mentions/suggestions/data/use-menu-items.cjs +9 -6
- package/dist/chat-ui/mentions/suggestions/data/use-menu-items.cjs.map +1 -1
- package/dist/chat-ui/mentions/suggestions/data/use-menu-items.d.ts +3 -0
- package/dist/chat-ui/mentions/suggestions/data/use-menu-items.js +5 -2
- package/dist/chat-ui/mentions/suggestions/data/use-menu-items.js.map +1 -1
- package/dist/chat-ui/mentions/use-account-workspace-id.cjs +45 -10
- package/dist/chat-ui/mentions/use-account-workspace-id.cjs.map +1 -1
- package/dist/chat-ui/mentions/use-account-workspace-id.d.ts +24 -1
- package/dist/chat-ui/mentions/use-account-workspace-id.js +46 -11
- package/dist/chat-ui/mentions/use-account-workspace-id.js.map +1 -1
- package/dist/chat-ui/mentions/use-member-avatar.cjs +4 -4
- package/dist/chat-ui/mentions/use-member-avatar.cjs.map +1 -1
- package/dist/chat-ui/mentions/use-mention-asset.cjs +3 -3
- package/dist/chat-ui/mentions/use-mention-asset.cjs.map +1 -1
- package/dist/chat-ui/messages/answer-label.cjs +42 -0
- package/dist/chat-ui/messages/answer-label.cjs.map +1 -0
- package/dist/chat-ui/messages/answer-label.d.ts +33 -0
- package/dist/chat-ui/messages/answer-label.js +42 -0
- package/dist/chat-ui/messages/answer-label.js.map +1 -0
- package/dist/chat-ui/messages/arrival-animation.cjs +13 -0
- package/dist/chat-ui/messages/arrival-animation.cjs.map +1 -0
- package/dist/chat-ui/messages/arrival-animation.d.ts +14 -0
- package/dist/chat-ui/messages/arrival-animation.js +13 -0
- package/dist/chat-ui/messages/arrival-animation.js.map +1 -0
- package/dist/chat-ui/messages/continue-pill.cjs +5 -5
- package/dist/chat-ui/messages/continue-pill.cjs.map +1 -1
- package/dist/chat-ui/messages/handoff-arrival-divider.cjs +44 -0
- package/dist/chat-ui/messages/handoff-arrival-divider.cjs.map +1 -0
- package/dist/chat-ui/messages/handoff-arrival-divider.d.ts +17 -0
- package/dist/chat-ui/messages/handoff-arrival-divider.js +44 -0
- package/dist/chat-ui/messages/handoff-arrival-divider.js.map +1 -0
- package/dist/chat-ui/messages/message-actions-config.cjs +3 -3
- package/dist/chat-ui/messages/message-actions-config.cjs.map +1 -1
- package/dist/chat-ui/messages/message-components.cjs +8 -4
- package/dist/chat-ui/messages/message-components.cjs.map +1 -1
- package/dist/chat-ui/messages/message-components.js +5 -1
- package/dist/chat-ui/messages/message-components.js.map +1 -1
- package/dist/chat-ui/messages/message-images.cjs +66 -0
- package/dist/chat-ui/messages/message-images.cjs.map +1 -0
- package/dist/chat-ui/messages/message-images.d.ts +16 -0
- package/dist/chat-ui/messages/message-images.js +66 -0
- package/dist/chat-ui/messages/message-images.js.map +1 -0
- package/dist/chat-ui/messages/user-edit-composer.cjs +2 -2
- package/dist/chat-ui/messages/user-edit-composer.cjs.map +1 -1
- package/dist/chat-ui/messages/wake-marker.cjs +3 -3
- package/dist/chat-ui/messages/wake-marker.cjs.map +1 -1
- package/dist/chat-ui/rich-text/chat-link.cjs +2 -2
- package/dist/chat-ui/rich-text/chat-link.cjs.map +1 -1
- package/dist/chat-ui/rich-text/chat-message-body.cjs +8 -8
- package/dist/chat-ui/rich-text/chat-message-body.cjs.map +1 -1
- package/dist/chat-ui/rich-text/chat-node-views.cjs +6 -6
- package/dist/chat-ui/rich-text/chat-node-views.cjs.map +1 -1
- package/dist/chat-ui/rich-text/dom-output-spec.cjs +2 -2
- package/dist/chat-ui/rich-text/dom-output-spec.cjs.map +1 -1
- package/dist/chat-ui/statewire.cjs +3 -0
- package/dist/chat-ui/statewire.cjs.map +1 -1
- package/dist/chat-ui/statewire.d.ts +2 -1
- package/dist/chat-ui/statewire.js +3 -0
- package/dist/chat-ui/statewire.js.map +1 -1
- package/dist/chat-ui/thread/chat-thread-shell.cjs +43 -14
- package/dist/chat-ui/thread/chat-thread-shell.cjs.map +1 -1
- package/dist/chat-ui/thread/chat-thread-shell.d.ts +16 -2
- package/dist/chat-ui/thread/chat-thread-shell.js +35 -6
- package/dist/chat-ui/thread/chat-thread-shell.js.map +1 -1
- package/dist/chat-ui/thread/composer-send-or-stop.cjs +30 -20
- package/dist/chat-ui/thread/composer-send-or-stop.cjs.map +1 -1
- package/dist/chat-ui/thread/composer-send-or-stop.d.ts +8 -0
- package/dist/chat-ui/thread/composer-send-or-stop.js +29 -19
- package/dist/chat-ui/thread/composer-send-or-stop.js.map +1 -1
- package/dist/chat-ui/thread/statewire-history-edge.cjs +20 -21
- package/dist/chat-ui/thread/statewire-history-edge.cjs.map +1 -1
- package/dist/chat-ui/thread/statewire-history-edge.js +3 -4
- package/dist/chat-ui/thread/statewire-history-edge.js.map +1 -1
- package/dist/chat-ui/thread/thread-loading-overlay.cjs +5 -5
- package/dist/chat-ui/thread/thread-loading-overlay.cjs.map +1 -1
- package/dist/collab/client.cjs +40 -3
- package/dist/collab/client.cjs.map +1 -1
- package/dist/collab/client.d.ts +25 -0
- package/dist/collab/client.js +40 -3
- package/dist/collab/client.js.map +1 -1
- package/dist/collab/document-status.cjs +150 -0
- package/dist/collab/document-status.cjs.map +1 -0
- package/dist/collab/document-status.d.ts +68 -0
- package/dist/collab/document-status.js +150 -0
- package/dist/collab/document-status.js.map +1 -0
- package/dist/collab/index.cjs +7 -0
- package/dist/collab/index.cjs.map +1 -1
- package/dist/collab/index.d.ts +6 -1
- package/dist/collab/index.js +7 -0
- package/dist/collab/index.js.map +1 -1
- package/dist/collab/presence-react.cjs +11 -11
- package/dist/collab/presence-react.cjs.map +1 -1
- package/dist/collab/react.cjs +6 -6
- package/dist/collab/react.cjs.map +1 -1
- package/dist/composer/AttachmentContext.cjs +24 -11
- package/dist/composer/AttachmentContext.cjs.map +1 -1
- package/dist/composer/AttachmentContext.js +18 -5
- package/dist/composer/AttachmentContext.js.map +1 -1
- package/dist/composer/ComposerAttachmentPreview.cjs +78 -23
- package/dist/composer/ComposerAttachmentPreview.cjs.map +1 -1
- package/dist/composer/ComposerAttachmentPreview.d.ts +5 -3
- package/dist/composer/ComposerAttachmentPreview.js +79 -24
- package/dist/composer/ComposerAttachmentPreview.js.map +1 -1
- package/dist/composer/ComposerDropZone.cjs +7 -7
- package/dist/composer/ComposerDropZone.cjs.map +1 -1
- package/dist/composer/FileUploadButton.cjs +37 -22
- package/dist/composer/FileUploadButton.cjs.map +1 -1
- package/dist/composer/FileUploadButton.d.ts +6 -0
- package/dist/composer/FileUploadButton.js +34 -19
- package/dist/composer/FileUploadButton.js.map +1 -1
- package/dist/composer/QuoteContext.cjs +8 -8
- package/dist/composer/QuoteContext.cjs.map +1 -1
- package/dist/composer/composer-handoff.cjs +4 -4
- package/dist/composer/composer-handoff.cjs.map +1 -1
- package/dist/composer/useAppendToComposer.cjs +4 -4
- package/dist/composer/useAppendToComposer.cjs.map +1 -1
- package/dist/composer/useAttachFiles.cjs +23 -6
- package/dist/composer/useAttachFiles.cjs.map +1 -1
- package/dist/composer/useAttachFiles.d.ts +15 -7
- package/dist/composer/useAttachFiles.js +22 -5
- package/dist/composer/useAttachFiles.js.map +1 -1
- package/dist/composer/useComposerAttachment.cjs +4 -4
- package/dist/composer/useComposerAttachment.cjs.map +1 -1
- package/dist/composer/useFileUpload.cjs +21 -16
- package/dist/composer/useFileUpload.cjs.map +1 -1
- package/dist/composer/useFileUpload.d.ts +12 -0
- package/dist/composer/useFileUpload.js +12 -7
- package/dist/composer/useFileUpload.js.map +1 -1
- package/dist/composer/useReadComposerDraft.cjs +2 -2
- package/dist/composer/useReadComposerDraft.cjs.map +1 -1
- package/dist/composer/useSendMessage.cjs +4 -4
- package/dist/composer/useSendMessage.cjs.map +1 -1
- package/dist/diagnostics/useAthenaDiagnostics.cjs +4 -4
- package/dist/diagnostics/useAthenaDiagnostics.cjs.map +1 -1
- package/dist/dictation/audio-level-history.cjs +3 -3
- package/dist/dictation/audio-level-history.cjs.map +1 -1
- package/dist/dictation/dictation-controls.cjs +24 -20
- package/dist/dictation/dictation-controls.cjs.map +1 -1
- package/dist/dictation/dictation-controls.d.ts +6 -1
- package/dist/dictation/dictation-controls.js +24 -20
- package/dist/dictation/dictation-controls.js.map +1 -1
- package/dist/dictation/use-athena-dictation-engine.cjs +3 -3
- package/dist/dictation/use-athena-dictation-engine.cjs.map +1 -1
- package/dist/dictation/use-dictation.cjs +22 -22
- package/dist/dictation/use-dictation.cjs.map +1 -1
- package/dist/index.cjs +26 -2
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +15 -3
- package/dist/index.js +26 -2
- package/dist/index.js.map +1 -1
- package/dist/keryx-http/src/receive-only-socket.cjs +40 -0
- package/dist/keryx-http/src/receive-only-socket.cjs.map +1 -0
- package/dist/keryx-http/src/receive-only-socket.d.ts +27 -0
- package/dist/keryx-http/src/receive-only-socket.js +40 -0
- package/dist/keryx-http/src/receive-only-socket.js.map +1 -0
- package/dist/keryx-http/src/update-attributions.cjs +111 -0
- package/dist/keryx-http/src/update-attributions.cjs.map +1 -0
- package/dist/keryx-http/src/update-attributions.d.ts +75 -0
- package/dist/keryx-http/src/update-attributions.js +111 -0
- package/dist/keryx-http/src/update-attributions.js.map +1 -0
- package/dist/lib/owner-document.cjs +6 -6
- package/dist/lib/owner-document.cjs.map +1 -1
- package/dist/lib/use-athena-rest-query.cjs +4 -4
- package/dist/lib/use-athena-rest-query.cjs.map +1 -1
- package/dist/lib/use-document-active.cjs +4 -4
- package/dist/lib/use-document-active.cjs.map +1 -1
- package/dist/lib/use-prefers-reduced-motion.cjs +2 -2
- package/dist/lib/use-prefers-reduced-motion.cjs.map +1 -1
- package/dist/offline/offline-history.cjs +7 -7
- package/dist/offline/offline-history.cjs.map +1 -1
- package/dist/provider/AthenaContext.cjs +3 -3
- package/dist/provider/AthenaContext.cjs.map +1 -1
- package/dist/provider/AthenaProvider.cjs +116 -79
- package/dist/provider/AthenaProvider.cjs.map +1 -1
- package/dist/provider/AthenaProvider.js +40 -3
- package/dist/provider/AthenaProvider.js.map +1 -1
- package/dist/provider/PostHogProvider.cjs +2 -2
- package/dist/provider/PostHogProvider.cjs.map +1 -1
- package/dist/provider/agent-selection-context.cjs +2 -2
- package/dist/provider/agent-selection-context.cjs.map +1 -1
- package/dist/provider/chat-mode-context.cjs +2 -2
- package/dist/provider/chat-mode-context.cjs.map +1 -1
- package/dist/provider/session-persistence-context.cjs +10 -0
- package/dist/provider/session-persistence-context.cjs.map +1 -0
- package/dist/provider/session-persistence-context.d.ts +15 -0
- package/dist/provider/session-persistence-context.js +10 -0
- package/dist/provider/session-persistence-context.js.map +1 -0
- package/dist/provider/statewire-history-context.cjs +4 -4
- package/dist/provider/statewire-history-context.cjs.map +1 -1
- package/dist/provider/statewire-lifecycle-context.cjs +3 -3
- package/dist/provider/statewire-lifecycle-context.cjs.map +1 -1
- package/dist/provider/statewire-window-context.cjs +3 -3
- package/dist/provider/statewire-window-context.cjs.map +1 -1
- package/dist/provider/theme-style-context.cjs +3 -3
- package/dist/provider/theme-style-context.cjs.map +1 -1
- package/dist/react/package.json.cjs +1 -1
- package/dist/react/package.json.js +1 -1
- package/dist/runtime/StatewireThreadConfigLaneSync.cjs +10 -10
- package/dist/runtime/StatewireThreadConfigLaneSync.cjs.map +1 -1
- package/dist/runtime/auth-refusal-restart.cjs +7 -7
- package/dist/runtime/auth-refusal-restart.cjs.map +1 -1
- package/dist/runtime/auth.cjs +13 -13
- package/dist/runtime/auth.cjs.map +1 -1
- package/dist/runtime/statewire-lifecycle.cjs +1 -0
- package/dist/runtime/statewire-lifecycle.cjs.map +1 -1
- package/dist/runtime/statewire-lifecycle.d.ts +3 -1
- package/dist/runtime/statewire-lifecycle.js +2 -1
- package/dist/runtime/statewire-lifecycle.js.map +1 -1
- package/dist/runtime/statewire-server-lane-context.cjs +2 -2
- package/dist/runtime/statewire-server-lane-context.cjs.map +1 -1
- package/dist/runtime/statewire-session-lane.cjs +4 -4
- package/dist/runtime/statewire-session-lane.cjs.map +1 -1
- package/dist/runtime/useAthenaStatewireRuntime.cjs +10 -8
- package/dist/runtime/useAthenaStatewireRuntime.cjs.map +1 -1
- package/dist/runtime/useAthenaStatewireRuntime.d.ts +2 -0
- package/dist/runtime/useAthenaStatewireRuntime.js +2 -0
- package/dist/runtime/useAthenaStatewireRuntime.js.map +1 -1
- package/dist/styles.css +1 -1
- package/dist/threads/Inbox.cjs +8 -8
- package/dist/threads/Inbox.cjs.map +1 -1
- package/dist/threads/SessionList.cjs +9 -9
- package/dist/threads/SessionList.cjs.map +1 -1
- package/dist/threads/SessionsPage.cjs +11 -11
- package/dist/threads/SessionsPage.cjs.map +1 -1
- package/dist/threads/index-triggered-refresh.cjs +10 -10
- package/dist/threads/index-triggered-refresh.cjs.map +1 -1
- package/dist/threads/mark-viewed-thread-read.cjs +12 -12
- package/dist/threads/mark-viewed-thread-read.cjs.map +1 -1
- package/dist/threads/offline-session-list.cjs +3 -3
- package/dist/threads/offline-session-list.cjs.map +1 -1
- package/dist/threads/session-list-tab-share.cjs +5 -5
- package/dist/threads/session-list-tab-share.cjs.map +1 -1
- package/dist/threads/statewire-thread-list.cjs +51 -51
- package/dist/threads/statewire-thread-list.cjs.map +1 -1
- package/dist/threads/thread-id-context.cjs +5 -5
- package/dist/threads/thread-id-context.cjs.map +1 -1
- package/dist/threads/use-athena-session-attention.cjs +2 -2
- package/dist/threads/use-athena-session-attention.cjs.map +1 -1
- package/dist/threads/use-athena-sessions.cjs +10 -10
- package/dist/threads/use-athena-sessions.cjs.map +1 -1
- package/dist/threads/use-athena-thread-model.cjs +3 -3
- package/dist/threads/use-athena-thread-model.cjs.map +1 -1
- package/dist/threads/use-rest-conversation-history.cjs +3 -3
- package/dist/threads/use-rest-conversation-history.cjs.map +1 -1
- package/dist/threads/use-statewire-conversation-history.cjs +8 -8
- package/dist/threads/use-statewire-conversation-history.cjs.map +1 -1
- package/dist/threads/use-thread-archive.cjs +9 -9
- package/dist/threads/use-thread-archive.cjs.map +1 -1
- package/dist/threads/use-thread-favorite.cjs +2 -2
- package/dist/threads/use-thread-favorite.cjs.map +1 -1
- package/dist/threads/use-thread-field-override.cjs +20 -20
- package/dist/threads/use-thread-field-override.cjs.map +1 -1
- package/dist/threads/use-thread-read-state.cjs +4 -4
- package/dist/threads/use-thread-read-state.cjs.map +1 -1
- package/dist/threads/use-thread-rename.cjs +2 -2
- package/dist/threads/use-thread-rename.cjs.map +1 -1
- package/dist/threads/useAthenaThreadManager.cjs +2 -2
- package/dist/threads/useAthenaThreadManager.cjs.map +1 -1
- package/dist/tools/NestedPtcMessages.cjs +6 -6
- package/dist/tools/NestedPtcMessages.cjs.map +1 -1
- package/dist/tools/append-document-tool-ui.cjs +7 -7
- package/dist/tools/append-document-tool-ui.cjs.map +1 -1
- package/dist/tools/file-tool-uis.cjs +2 -2
- package/dist/tools/file-tool-uis.cjs.map +1 -1
- package/dist/tools/misc-tool-uis.cjs +2 -2
- package/dist/tools/misc-tool-uis.cjs.map +1 -1
- package/dist/tools/primitives.cjs +6 -6
- package/dist/tools/primitives.cjs.map +1 -1
- package/dist/tools/read-asset-tool-ui.cjs +6 -6
- package/dist/tools/read-asset-tool-ui.cjs.map +1 -1
- package/dist/tools/subagent-task-tool-ui.cjs +21 -21
- package/dist/tools/subagent-task-tool-ui.cjs.map +1 -1
- package/dist/tools/test-recording-tool-uis.cjs +16 -16
- package/dist/tools/test-recording-tool-uis.cjs.map +1 -1
- package/dist/tools/todo-plan-store.cjs +4 -4
- package/dist/tools/todo-plan-store.cjs.map +1 -1
- package/dist/tools/tool-appearance.cjs +3 -3
- package/dist/tools/tool-appearance.cjs.map +1 -1
- package/dist/tools/tool-fallback.cjs +14 -14
- package/dist/tools/tool-fallback.cjs.map +1 -1
- package/dist/tools/tool-uis.cjs +74 -74
- package/dist/tools/tool-uis.cjs.map +1 -1
- package/dist/tools/use-elapsed-seconds.cjs +3 -3
- package/dist/tools/use-elapsed-seconds.cjs.map +1 -1
- package/dist/tools/write-todos-tool-ui.cjs +9 -9
- package/dist/tools/write-todos-tool-ui.cjs.map +1 -1
- package/dist/ui/image-viewer.cjs +382 -0
- package/dist/ui/image-viewer.cjs.map +1 -0
- package/dist/ui/image-viewer.d.ts +50 -0
- package/dist/ui/image-viewer.js +382 -0
- package/dist/ui/image-viewer.js.map +1 -0
- package/dist/voice/chat.cjs +6 -0
- package/dist/voice/chat.cjs.map +1 -1
- package/dist/voice/chat.d.ts +1 -1
- package/dist/voice/chat.js +8 -2
- package/dist/voice/livekit-join.cjs +52 -101
- package/dist/voice/livekit-join.cjs.map +1 -1
- package/dist/voice/livekit-join.d.ts +1 -6
- package/dist/voice/livekit-join.js +52 -101
- package/dist/voice/livekit-join.js.map +1 -1
- package/dist/voice/livekit.cjs.map +1 -1
- package/dist/voice/livekit.d.ts +11 -1
- package/dist/voice/livekit.js.map +1 -1
- package/dist/voice/use-athena-voice-session.cjs +34 -34
- package/dist/voice/use-athena-voice-session.cjs.map +1 -1
- package/dist/workbench/ComputerLiveDesktop.cjs +13 -13
- package/dist/workbench/ComputerLiveDesktop.cjs.map +1 -1
- package/dist/workbench/SessionWorkbench.cjs +22 -22
- package/dist/workbench/SessionWorkbench.cjs.map +1 -1
- package/dist/workbench/session-workbench-context.cjs +3 -3
- package/dist/workbench/session-workbench-context.cjs.map +1 -1
- package/dist/workbench/session-workbench-panes.cjs +8 -8
- package/dist/workbench/session-workbench-panes.cjs.map +1 -1
- package/dist/workbench/workbench-layout-context.cjs +3 -3
- package/dist/workbench/workbench-layout-context.cjs.map +1 -1
- package/package.json +2 -1
|
@@ -0,0 +1,756 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Cross-surface "Continue on…" thread handoff — the client half of agora's
|
|
3
|
+
* `/api/handoffs` protocol shared by Spaces, the mobile app, Athena in Chrome,
|
|
4
|
+
* the desktop app and the Office add-ins.
|
|
5
|
+
*
|
|
6
|
+
* A handoff carries no conversation content beyond the source composer's
|
|
7
|
+
* unsent draft. The server binds an opaque `handoff_id` to the durable thread,
|
|
8
|
+
* and the destination surface claims that id and acknowledges once it owns the
|
|
9
|
+
* thread. The source surface closes its own copilot only after that
|
|
10
|
+
* acknowledgement; nothing switches surfaces on its own.
|
|
11
|
+
*/
|
|
12
|
+
import { z } from 'zod';
|
|
13
|
+
/** Destinations a readiness response reports a row for (a closed set older readers validate). */
|
|
14
|
+
export declare const HANDOFF_DESTINATIONS: readonly ['chrome', 'mobile', 'word', 'powerpoint', 'excel'];
|
|
15
|
+
export type HandoffDestination = (typeof HANDOFF_DESTINATIONS)[number];
|
|
16
|
+
/**
|
|
17
|
+
* Every destination a handoff record can name. `spaces` lands on a Spaces link
|
|
18
|
+
* or an open Spaces tab; `next` is "wherever I pick up next" (the first of the
|
|
19
|
+
* four surfaces to come to the front and accept it); `desktop` is the desktop
|
|
20
|
+
* app, created through `/api/handoffs/desktop` but polled like the rest.
|
|
21
|
+
*/
|
|
22
|
+
export declare const THREAD_HANDOFF_DESTINATIONS: readonly ["chrome", "mobile", "word", "powerpoint", "excel", "spaces", "next", "desktop"];
|
|
23
|
+
export type ThreadHandoffDestination = (typeof THREAD_HANDOFF_DESTINATIONS)[number];
|
|
24
|
+
/** The four surfaces of a phase-one handover; each can claim a `next` handoff. */
|
|
25
|
+
export declare const PICKUP_SURFACES: readonly ['spaces', 'mobile', 'chrome', 'desktop'];
|
|
26
|
+
export type PickupSurface = (typeof PICKUP_SURFACES)[number];
|
|
27
|
+
/** What "Continue on…" offers among the four surfaces, in picker order. */
|
|
28
|
+
export declare const SURFACE_HANDOFF_DESTINATIONS: readonly ['spaces', 'mobile', 'chrome', 'desktop', 'next'];
|
|
29
|
+
export type SurfaceHandoffDestination = (typeof SURFACE_HANDOFF_DESTINATIONS)[number];
|
|
30
|
+
/** The source composer's unsent text that travels prefilled, never sent. */
|
|
31
|
+
export declare const MAX_HANDOFF_DRAFT_LENGTH = 4000;
|
|
32
|
+
/**
|
|
33
|
+
* How the person chose to continue. `voice` is an offer the destination shows
|
|
34
|
+
* ("Continue by voice"); it never starts a microphone by itself. Older servers
|
|
35
|
+
* omit it, which reads as `text`.
|
|
36
|
+
*/
|
|
37
|
+
export declare const handoffModeSchema: z.ZodEnum<{
|
|
38
|
+
text: "text";
|
|
39
|
+
voice: "voice";
|
|
40
|
+
}>;
|
|
41
|
+
export type HandoffMode = z.infer<typeof handoffModeSchema>;
|
|
42
|
+
/** Destinations that can continue by voice: the four surfaces and "next". */
|
|
43
|
+
export declare const isVoiceHandoffDestination: (destination: ThreadHandoffDestination) => boolean;
|
|
44
|
+
export declare const OFFICE_HANDOFF_DESTINATIONS: readonly ['word', 'powerpoint', 'excel'];
|
|
45
|
+
export type OfficeHandoffDestination = (typeof OFFICE_HANDOFF_DESTINATIONS)[number];
|
|
46
|
+
export declare const officeLaunchModeSchema: z.ZodEnum<{
|
|
47
|
+
invitation: "invitation";
|
|
48
|
+
new_document: "new_document";
|
|
49
|
+
}>;
|
|
50
|
+
export type OfficeLaunchMode = z.infer<typeof officeLaunchModeSchema>;
|
|
51
|
+
/** Destinations agora brokers; Chrome is launched page-side by the extension. */
|
|
52
|
+
export declare const SERVER_HANDOFF_DESTINATIONS: readonly ["mobile", "word", "powerpoint", "excel"];
|
|
53
|
+
export type ServerHandoffDestination = (typeof SERVER_HANDOFF_DESTINATIONS)[number];
|
|
54
|
+
export type HandoffSource = 'spaces' | 'chrome' | 'mobile' | 'word' | 'powerpoint' | 'excel' | 'desktop';
|
|
55
|
+
export declare const handoffEnvironmentSchema: z.ZodEnum<{
|
|
56
|
+
localhost: "localhost";
|
|
57
|
+
production: "production";
|
|
58
|
+
staging: "staging";
|
|
59
|
+
}>;
|
|
60
|
+
export type HandoffEnvironment = z.infer<typeof handoffEnvironmentSchema>;
|
|
61
|
+
export declare const handoffStateSchema: z.ZodEnum<{
|
|
62
|
+
acknowledged: "acknowledged";
|
|
63
|
+
claimed: "claimed";
|
|
64
|
+
failed: "failed";
|
|
65
|
+
issued: "issued";
|
|
66
|
+
launched: "launched";
|
|
67
|
+
}>;
|
|
68
|
+
export type HandoffState = z.infer<typeof handoffStateSchema>;
|
|
69
|
+
export declare const handoffReadinessStateSchema: z.ZodEnum<{
|
|
70
|
+
not_registered: "not_registered";
|
|
71
|
+
registered: "registered";
|
|
72
|
+
stale: "stale";
|
|
73
|
+
unknown: "unknown";
|
|
74
|
+
unsupported: "unsupported";
|
|
75
|
+
}>;
|
|
76
|
+
export type HandoffReadinessState = z.infer<typeof handoffReadinessStateSchema>;
|
|
77
|
+
export declare const destinationReadinessSchema: z.ZodObject<{
|
|
78
|
+
destination: z.ZodEnum<{
|
|
79
|
+
chrome: "chrome";
|
|
80
|
+
excel: "excel";
|
|
81
|
+
mobile: "mobile";
|
|
82
|
+
powerpoint: "powerpoint";
|
|
83
|
+
word: "word";
|
|
84
|
+
}>;
|
|
85
|
+
state: z.ZodEnum<{
|
|
86
|
+
not_registered: "not_registered";
|
|
87
|
+
registered: "registered";
|
|
88
|
+
stale: "stale";
|
|
89
|
+
unknown: "unknown";
|
|
90
|
+
unsupported: "unsupported";
|
|
91
|
+
}>;
|
|
92
|
+
last_seen_at: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
93
|
+
label: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
94
|
+
marketplace_url: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
95
|
+
}, z.core.$strip>;
|
|
96
|
+
export type DestinationReadiness = z.infer<typeof destinationReadinessSchema>;
|
|
97
|
+
export declare const handoffReadinessResponseSchema: z.ZodObject<{
|
|
98
|
+
environment: z.ZodEnum<{
|
|
99
|
+
localhost: "localhost";
|
|
100
|
+
production: "production";
|
|
101
|
+
staging: "staging";
|
|
102
|
+
}>;
|
|
103
|
+
destinations: z.ZodArray<z.ZodObject<{
|
|
104
|
+
destination: z.ZodEnum<{
|
|
105
|
+
chrome: "chrome";
|
|
106
|
+
excel: "excel";
|
|
107
|
+
mobile: "mobile";
|
|
108
|
+
powerpoint: "powerpoint";
|
|
109
|
+
word: "word";
|
|
110
|
+
}>;
|
|
111
|
+
state: z.ZodEnum<{
|
|
112
|
+
not_registered: "not_registered";
|
|
113
|
+
registered: "registered";
|
|
114
|
+
stale: "stale";
|
|
115
|
+
unknown: "unknown";
|
|
116
|
+
unsupported: "unsupported";
|
|
117
|
+
}>;
|
|
118
|
+
last_seen_at: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
119
|
+
label: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
120
|
+
marketplace_url: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
121
|
+
}, z.core.$strip>>;
|
|
122
|
+
supports_office_invitations: z.ZodOptional<z.ZodBoolean>;
|
|
123
|
+
supports_desktop_source: z.ZodOptional<z.ZodBoolean>;
|
|
124
|
+
supports_surface_destinations: z.ZodOptional<z.ZodBoolean>;
|
|
125
|
+
}, z.core.$strip>;
|
|
126
|
+
export type HandoffReadinessResponse = z.infer<typeof handoffReadinessResponseSchema>;
|
|
127
|
+
export declare const supportsDesktopHandoffSource: (readiness: HandoffReadinessResponse | null | undefined) => boolean;
|
|
128
|
+
/** Whether the server can broker the four-surface destinations; absent means an older agora. */
|
|
129
|
+
export declare const supportsSurfaceHandoffDestinations: (readiness: HandoffReadinessResponse | null | undefined) => boolean;
|
|
130
|
+
export declare const threadHandoffViewSchema: z.ZodObject<{
|
|
131
|
+
handoff_id: z.ZodString;
|
|
132
|
+
thread_id: z.ZodString;
|
|
133
|
+
session_asset_id: z.ZodNullable<z.ZodString>;
|
|
134
|
+
source: z.ZodString;
|
|
135
|
+
destination: z.ZodEnum<{
|
|
136
|
+
chrome: "chrome";
|
|
137
|
+
desktop: "desktop";
|
|
138
|
+
excel: "excel";
|
|
139
|
+
mobile: "mobile";
|
|
140
|
+
next: "next";
|
|
141
|
+
powerpoint: "powerpoint";
|
|
142
|
+
spaces: "spaces";
|
|
143
|
+
word: "word";
|
|
144
|
+
}>;
|
|
145
|
+
office_launch_mode: z.ZodOptional<z.ZodNullable<z.ZodEnum<{
|
|
146
|
+
invitation: "invitation";
|
|
147
|
+
new_document: "new_document";
|
|
148
|
+
}>>>;
|
|
149
|
+
environment: z.ZodEnum<{
|
|
150
|
+
localhost: "localhost";
|
|
151
|
+
production: "production";
|
|
152
|
+
staging: "staging";
|
|
153
|
+
}>;
|
|
154
|
+
state: z.ZodEnum<{
|
|
155
|
+
acknowledged: "acknowledged";
|
|
156
|
+
claimed: "claimed";
|
|
157
|
+
failed: "failed";
|
|
158
|
+
issued: "issued";
|
|
159
|
+
launched: "launched";
|
|
160
|
+
}>;
|
|
161
|
+
issued_at: z.ZodString;
|
|
162
|
+
expires_at: z.ZodString;
|
|
163
|
+
claimed_at: z.ZodNullable<z.ZodString>;
|
|
164
|
+
acknowledged_at: z.ZodNullable<z.ZodString>;
|
|
165
|
+
failure_reason: z.ZodNullable<z.ZodString>;
|
|
166
|
+
push_delivered: z.ZodNullable<z.ZodBoolean>;
|
|
167
|
+
claimed_surface: z.ZodOptional<z.ZodNullable<z.ZodEnum<{
|
|
168
|
+
chrome: "chrome";
|
|
169
|
+
desktop: "desktop";
|
|
170
|
+
mobile: "mobile";
|
|
171
|
+
spaces: "spaces";
|
|
172
|
+
}>>>;
|
|
173
|
+
mode: z.ZodOptional<z.ZodEnum<{
|
|
174
|
+
text: "text";
|
|
175
|
+
voice: "voice";
|
|
176
|
+
}>>;
|
|
177
|
+
draft: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
178
|
+
}, z.core.$strip>;
|
|
179
|
+
export type ThreadHandoffView = z.infer<typeof threadHandoffViewSchema>;
|
|
180
|
+
export declare const mobileHandoffLaunchSchema: z.ZodObject<{
|
|
181
|
+
kind: z.ZodLiteral<"mobile">;
|
|
182
|
+
push_attempted: z.ZodBoolean;
|
|
183
|
+
push_delivered: z.ZodBoolean;
|
|
184
|
+
device_count: z.ZodNumber;
|
|
185
|
+
link_url: z.ZodString;
|
|
186
|
+
scheme_url: z.ZodString;
|
|
187
|
+
}, z.core.$strip>;
|
|
188
|
+
export type MobileHandoffLaunch = z.infer<typeof mobileHandoffLaunchSchema>;
|
|
189
|
+
export declare const officeHandoffLaunchSchema: z.ZodObject<{
|
|
190
|
+
kind: z.ZodLiteral<"office">;
|
|
191
|
+
host: z.ZodEnum<{
|
|
192
|
+
excel: "excel";
|
|
193
|
+
powerpoint: "powerpoint";
|
|
194
|
+
word: "word";
|
|
195
|
+
}>;
|
|
196
|
+
desktop_url: z.ZodString;
|
|
197
|
+
template_url: z.ZodString;
|
|
198
|
+
web_url: z.ZodString;
|
|
199
|
+
marketplace_url: z.ZodNullable<z.ZodString>;
|
|
200
|
+
}, z.core.$strip>;
|
|
201
|
+
export type OfficeHandoffLaunch = z.infer<typeof officeHandoffLaunchSchema>;
|
|
202
|
+
export declare const officeInvitationLaunchSchema: z.ZodObject<{
|
|
203
|
+
kind: z.ZodLiteral<"office_invitation">;
|
|
204
|
+
host: z.ZodEnum<{
|
|
205
|
+
excel: "excel";
|
|
206
|
+
powerpoint: "powerpoint";
|
|
207
|
+
word: "word";
|
|
208
|
+
}>;
|
|
209
|
+
}, z.core.$strip>;
|
|
210
|
+
export type OfficeInvitationLaunch = z.infer<typeof officeInvitationLaunchSchema>;
|
|
211
|
+
export declare const chromeHandoffLaunchSchema: z.ZodObject<{
|
|
212
|
+
kind: z.ZodLiteral<"chrome">;
|
|
213
|
+
}, z.core.$strip>;
|
|
214
|
+
/** Spaces lands on `url`; an open Spaces tab also finds the record on its own. */
|
|
215
|
+
export declare const spacesHandoffLaunchSchema: z.ZodObject<{
|
|
216
|
+
kind: z.ZodLiteral<"spaces">;
|
|
217
|
+
url: z.ZodString;
|
|
218
|
+
}, z.core.$strip>;
|
|
219
|
+
export type SpacesHandoffLaunch = z.infer<typeof spacesHandoffLaunchSchema>;
|
|
220
|
+
/** Nothing to open: the next surface to come to the front offers it. */
|
|
221
|
+
export declare const nextHandoffLaunchSchema: z.ZodObject<{
|
|
222
|
+
kind: z.ZodLiteral<"next">;
|
|
223
|
+
}, z.core.$strip>;
|
|
224
|
+
/** The desktop app: `scheme_url` on the same computer; from a phone, it finds the record itself. */
|
|
225
|
+
export declare const desktopThreadHandoffLaunchSchema: z.ZodObject<{
|
|
226
|
+
kind: z.ZodLiteral<"desktop">;
|
|
227
|
+
scheme_url: z.ZodString;
|
|
228
|
+
download_url: z.ZodString;
|
|
229
|
+
deployment_url: z.ZodString;
|
|
230
|
+
protocol_version: z.ZodLiteral<1>;
|
|
231
|
+
}, z.core.$strip>;
|
|
232
|
+
export type DesktopThreadHandoffLaunch = z.infer<typeof desktopThreadHandoffLaunchSchema>;
|
|
233
|
+
export declare const handoffLaunchSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
234
|
+
kind: z.ZodLiteral<"mobile">;
|
|
235
|
+
push_attempted: z.ZodBoolean;
|
|
236
|
+
push_delivered: z.ZodBoolean;
|
|
237
|
+
device_count: z.ZodNumber;
|
|
238
|
+
link_url: z.ZodString;
|
|
239
|
+
scheme_url: z.ZodString;
|
|
240
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
241
|
+
kind: z.ZodLiteral<"office">;
|
|
242
|
+
host: z.ZodEnum<{
|
|
243
|
+
excel: "excel";
|
|
244
|
+
powerpoint: "powerpoint";
|
|
245
|
+
word: "word";
|
|
246
|
+
}>;
|
|
247
|
+
desktop_url: z.ZodString;
|
|
248
|
+
template_url: z.ZodString;
|
|
249
|
+
web_url: z.ZodString;
|
|
250
|
+
marketplace_url: z.ZodNullable<z.ZodString>;
|
|
251
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
252
|
+
kind: z.ZodLiteral<"office_invitation">;
|
|
253
|
+
host: z.ZodEnum<{
|
|
254
|
+
excel: "excel";
|
|
255
|
+
powerpoint: "powerpoint";
|
|
256
|
+
word: "word";
|
|
257
|
+
}>;
|
|
258
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
259
|
+
kind: z.ZodLiteral<"chrome">;
|
|
260
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
261
|
+
kind: z.ZodLiteral<"spaces">;
|
|
262
|
+
url: z.ZodString;
|
|
263
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
264
|
+
kind: z.ZodLiteral<"next">;
|
|
265
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
266
|
+
kind: z.ZodLiteral<"desktop">;
|
|
267
|
+
scheme_url: z.ZodString;
|
|
268
|
+
download_url: z.ZodString;
|
|
269
|
+
deployment_url: z.ZodString;
|
|
270
|
+
protocol_version: z.ZodLiteral<1>;
|
|
271
|
+
}, z.core.$strip>], "kind">;
|
|
272
|
+
export type HandoffLaunch = z.infer<typeof handoffLaunchSchema>;
|
|
273
|
+
export declare const createThreadHandoffResponseSchema: z.ZodObject<{
|
|
274
|
+
handoff: z.ZodObject<{
|
|
275
|
+
handoff_id: z.ZodString;
|
|
276
|
+
thread_id: z.ZodString;
|
|
277
|
+
session_asset_id: z.ZodNullable<z.ZodString>;
|
|
278
|
+
source: z.ZodString;
|
|
279
|
+
destination: z.ZodEnum<{
|
|
280
|
+
chrome: "chrome";
|
|
281
|
+
desktop: "desktop";
|
|
282
|
+
excel: "excel";
|
|
283
|
+
mobile: "mobile";
|
|
284
|
+
next: "next";
|
|
285
|
+
powerpoint: "powerpoint";
|
|
286
|
+
spaces: "spaces";
|
|
287
|
+
word: "word";
|
|
288
|
+
}>;
|
|
289
|
+
office_launch_mode: z.ZodOptional<z.ZodNullable<z.ZodEnum<{
|
|
290
|
+
invitation: "invitation";
|
|
291
|
+
new_document: "new_document";
|
|
292
|
+
}>>>;
|
|
293
|
+
environment: z.ZodEnum<{
|
|
294
|
+
localhost: "localhost";
|
|
295
|
+
production: "production";
|
|
296
|
+
staging: "staging";
|
|
297
|
+
}>;
|
|
298
|
+
state: z.ZodEnum<{
|
|
299
|
+
acknowledged: "acknowledged";
|
|
300
|
+
claimed: "claimed";
|
|
301
|
+
failed: "failed";
|
|
302
|
+
issued: "issued";
|
|
303
|
+
launched: "launched";
|
|
304
|
+
}>;
|
|
305
|
+
issued_at: z.ZodString;
|
|
306
|
+
expires_at: z.ZodString;
|
|
307
|
+
claimed_at: z.ZodNullable<z.ZodString>;
|
|
308
|
+
acknowledged_at: z.ZodNullable<z.ZodString>;
|
|
309
|
+
failure_reason: z.ZodNullable<z.ZodString>;
|
|
310
|
+
push_delivered: z.ZodNullable<z.ZodBoolean>;
|
|
311
|
+
claimed_surface: z.ZodOptional<z.ZodNullable<z.ZodEnum<{
|
|
312
|
+
chrome: "chrome";
|
|
313
|
+
desktop: "desktop";
|
|
314
|
+
mobile: "mobile";
|
|
315
|
+
spaces: "spaces";
|
|
316
|
+
}>>>;
|
|
317
|
+
mode: z.ZodOptional<z.ZodEnum<{
|
|
318
|
+
text: "text";
|
|
319
|
+
voice: "voice";
|
|
320
|
+
}>>;
|
|
321
|
+
draft: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
322
|
+
}, z.core.$strip>;
|
|
323
|
+
launch: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
324
|
+
kind: z.ZodLiteral<"mobile">;
|
|
325
|
+
push_attempted: z.ZodBoolean;
|
|
326
|
+
push_delivered: z.ZodBoolean;
|
|
327
|
+
device_count: z.ZodNumber;
|
|
328
|
+
link_url: z.ZodString;
|
|
329
|
+
scheme_url: z.ZodString;
|
|
330
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
331
|
+
kind: z.ZodLiteral<"office">;
|
|
332
|
+
host: z.ZodEnum<{
|
|
333
|
+
excel: "excel";
|
|
334
|
+
powerpoint: "powerpoint";
|
|
335
|
+
word: "word";
|
|
336
|
+
}>;
|
|
337
|
+
desktop_url: z.ZodString;
|
|
338
|
+
template_url: z.ZodString;
|
|
339
|
+
web_url: z.ZodString;
|
|
340
|
+
marketplace_url: z.ZodNullable<z.ZodString>;
|
|
341
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
342
|
+
kind: z.ZodLiteral<"office_invitation">;
|
|
343
|
+
host: z.ZodEnum<{
|
|
344
|
+
excel: "excel";
|
|
345
|
+
powerpoint: "powerpoint";
|
|
346
|
+
word: "word";
|
|
347
|
+
}>;
|
|
348
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
349
|
+
kind: z.ZodLiteral<"chrome">;
|
|
350
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
351
|
+
kind: z.ZodLiteral<"spaces">;
|
|
352
|
+
url: z.ZodString;
|
|
353
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
354
|
+
kind: z.ZodLiteral<"next">;
|
|
355
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
356
|
+
kind: z.ZodLiteral<"desktop">;
|
|
357
|
+
scheme_url: z.ZodString;
|
|
358
|
+
download_url: z.ZodString;
|
|
359
|
+
deployment_url: z.ZodString;
|
|
360
|
+
protocol_version: z.ZodLiteral<1>;
|
|
361
|
+
}, z.core.$strip>], "kind">;
|
|
362
|
+
}, z.core.$strip>;
|
|
363
|
+
export type CreateThreadHandoffResponse = z.infer<typeof createThreadHandoffResponseSchema>;
|
|
364
|
+
export interface CreateThreadHandoffInput {
|
|
365
|
+
threadId: string;
|
|
366
|
+
destination: ThreadHandoffDestination;
|
|
367
|
+
source: HandoffSource;
|
|
368
|
+
officeLaunchMode?: OfficeLaunchMode;
|
|
369
|
+
/** An observed workspace precondition, never an authorization grant. */
|
|
370
|
+
expectedWorkspaceId?: string;
|
|
371
|
+
/** The composer's unsent text; the destination prefills it and never sends it. */
|
|
372
|
+
draft?: string;
|
|
373
|
+
/** `voice` offers "Continue by voice" on the destination. Omitted means text. */
|
|
374
|
+
mode?: HandoffMode;
|
|
375
|
+
}
|
|
376
|
+
/** A phone invites the computer's pane; other sources keep their existing launch. */
|
|
377
|
+
export declare function resolveOfficeHandoffLaunchMode({ source, destination, officeLaunchMode, }: CreateThreadHandoffInput): OfficeLaunchMode | undefined;
|
|
378
|
+
/** The same request body for every host's authenticated HTTP adapter. */
|
|
379
|
+
export declare function threadHandoffCreateBody({ threadId, destination, source, officeLaunchMode, expectedWorkspaceId, draft, mode: handoffMode, }: CreateThreadHandoffInput): {
|
|
380
|
+
thread_id: string;
|
|
381
|
+
destination: "chrome" | "desktop" | "excel" | "mobile" | "next" | "powerpoint" | "spaces" | "word";
|
|
382
|
+
source: HandoffSource;
|
|
383
|
+
expected_workspace_id?: string | undefined;
|
|
384
|
+
office_launch_mode?: "invitation" | "new_document" | undefined;
|
|
385
|
+
draft?: string | undefined;
|
|
386
|
+
mode?: "voice" | undefined;
|
|
387
|
+
};
|
|
388
|
+
/** Keep a draft within the server's limit at a character boundary; never send more. */
|
|
389
|
+
export declare const clampHandoffDraft: (draft: string) => string;
|
|
390
|
+
/**
|
|
391
|
+
* Where an HTTP adapter sends a create. The desktop app has its own protocol
|
|
392
|
+
* (its record also carries asset tabs), so `desktop` posts a conversation-only
|
|
393
|
+
* desktop handoff to `/desktop`; everything else posts to `/api/handoffs`.
|
|
394
|
+
* Pair with {@link parseThreadHandoffCreateResponse}.
|
|
395
|
+
*/
|
|
396
|
+
export declare function threadHandoffCreateRequest(input: CreateThreadHandoffInput): {
|
|
397
|
+
path: '' | '/desktop';
|
|
398
|
+
body: Record<string, unknown>;
|
|
399
|
+
};
|
|
400
|
+
/** Parse either create reply into the one shape the shared flow waits on. */
|
|
401
|
+
export declare function parseThreadHandoffCreateResponse(input: Pick<CreateThreadHandoffInput, 'destination'>, payload: unknown): CreateThreadHandoffResponse;
|
|
402
|
+
/** Body of `POST /api/handoffs/claim`. `surface` is required for a `next` pickup. */
|
|
403
|
+
export declare function threadHandoffClaimBody({ handoffId, destination, surfaceInstance, surface, }: {
|
|
404
|
+
handoffId?: string;
|
|
405
|
+
destination: Exclude<ThreadHandoffDestination, 'desktop'>;
|
|
406
|
+
surfaceInstance: string;
|
|
407
|
+
surface?: PickupSurface;
|
|
408
|
+
}): {
|
|
409
|
+
handoff_id?: string | undefined;
|
|
410
|
+
destination: "chrome" | "excel" | "mobile" | "next" | "powerpoint" | "spaces" | "word";
|
|
411
|
+
surface_instance: string;
|
|
412
|
+
surface?: "chrome" | "desktop" | "mobile" | "spaces" | undefined;
|
|
413
|
+
};
|
|
414
|
+
/** The most ticket ids a receiver may ask `/pending` to skip. */
|
|
415
|
+
export declare const MAX_PENDING_EXCLUDE = 20;
|
|
416
|
+
/**
|
|
417
|
+
* The ids a receiver asks `/pending` to skip (declined here, or issued here),
|
|
418
|
+
* newest last in, bounded to the server's limit and to the id shape it issues.
|
|
419
|
+
* A filter only: the server still binds every candidate to the caller.
|
|
420
|
+
*/
|
|
421
|
+
export declare function pendingExcludeIds(ids: Iterable<string>): string[];
|
|
422
|
+
/**
|
|
423
|
+
* A receiver's `exclude`: the newest half of what it issued and the newest half of what it
|
|
424
|
+
* declined (each oldest first, as a Set keeps them). Neither kind can crowd the other out of
|
|
425
|
+
* the server's bound, so a long-lived tab's old declines never hide its newest own ticket and
|
|
426
|
+
* many sends never drop its latest "Not now".
|
|
427
|
+
*/
|
|
428
|
+
export declare function pickupExcludeIds({ issuedHere, declined, }: {
|
|
429
|
+
issuedHere: Iterable<string>;
|
|
430
|
+
declined: Iterable<string>;
|
|
431
|
+
}): string[];
|
|
432
|
+
/** `/pending?destination=…&exclude=…` relative to `/api/handoffs`. */
|
|
433
|
+
export declare function pendingHandoffPath({ destination, exclude, }: {
|
|
434
|
+
destination: Exclude<ThreadHandoffDestination, 'desktop'> | 'desktop';
|
|
435
|
+
exclude?: Iterable<string>;
|
|
436
|
+
}): string;
|
|
437
|
+
export declare const claimThreadHandoffResponseSchema: z.ZodObject<{
|
|
438
|
+
handoff: z.ZodObject<{
|
|
439
|
+
handoff_id: z.ZodString;
|
|
440
|
+
thread_id: z.ZodString;
|
|
441
|
+
session_asset_id: z.ZodNullable<z.ZodString>;
|
|
442
|
+
source: z.ZodString;
|
|
443
|
+
destination: z.ZodEnum<{
|
|
444
|
+
chrome: "chrome";
|
|
445
|
+
desktop: "desktop";
|
|
446
|
+
excel: "excel";
|
|
447
|
+
mobile: "mobile";
|
|
448
|
+
next: "next";
|
|
449
|
+
powerpoint: "powerpoint";
|
|
450
|
+
spaces: "spaces";
|
|
451
|
+
word: "word";
|
|
452
|
+
}>;
|
|
453
|
+
office_launch_mode: z.ZodOptional<z.ZodNullable<z.ZodEnum<{
|
|
454
|
+
invitation: "invitation";
|
|
455
|
+
new_document: "new_document";
|
|
456
|
+
}>>>;
|
|
457
|
+
environment: z.ZodEnum<{
|
|
458
|
+
localhost: "localhost";
|
|
459
|
+
production: "production";
|
|
460
|
+
staging: "staging";
|
|
461
|
+
}>;
|
|
462
|
+
state: z.ZodEnum<{
|
|
463
|
+
acknowledged: "acknowledged";
|
|
464
|
+
claimed: "claimed";
|
|
465
|
+
failed: "failed";
|
|
466
|
+
issued: "issued";
|
|
467
|
+
launched: "launched";
|
|
468
|
+
}>;
|
|
469
|
+
issued_at: z.ZodString;
|
|
470
|
+
expires_at: z.ZodString;
|
|
471
|
+
claimed_at: z.ZodNullable<z.ZodString>;
|
|
472
|
+
acknowledged_at: z.ZodNullable<z.ZodString>;
|
|
473
|
+
failure_reason: z.ZodNullable<z.ZodString>;
|
|
474
|
+
push_delivered: z.ZodNullable<z.ZodBoolean>;
|
|
475
|
+
claimed_surface: z.ZodOptional<z.ZodNullable<z.ZodEnum<{
|
|
476
|
+
chrome: "chrome";
|
|
477
|
+
desktop: "desktop";
|
|
478
|
+
mobile: "mobile";
|
|
479
|
+
spaces: "spaces";
|
|
480
|
+
}>>>;
|
|
481
|
+
mode: z.ZodOptional<z.ZodEnum<{
|
|
482
|
+
text: "text";
|
|
483
|
+
voice: "voice";
|
|
484
|
+
}>>;
|
|
485
|
+
draft: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
486
|
+
}, z.core.$strip>;
|
|
487
|
+
}, z.core.$strip>;
|
|
488
|
+
export type ClaimThreadHandoffResponse = z.infer<typeof claimThreadHandoffResponseSchema>;
|
|
489
|
+
/** `GET /api/handoffs/pending` answers `null` (not 404) when nothing waits. */
|
|
490
|
+
export declare const pendingThreadHandoffResponseSchema: z.ZodNullable<z.ZodObject<{
|
|
491
|
+
handoff: z.ZodObject<{
|
|
492
|
+
handoff_id: z.ZodString;
|
|
493
|
+
thread_id: z.ZodString;
|
|
494
|
+
session_asset_id: z.ZodNullable<z.ZodString>;
|
|
495
|
+
source: z.ZodString;
|
|
496
|
+
destination: z.ZodEnum<{
|
|
497
|
+
chrome: "chrome";
|
|
498
|
+
desktop: "desktop";
|
|
499
|
+
excel: "excel";
|
|
500
|
+
mobile: "mobile";
|
|
501
|
+
next: "next";
|
|
502
|
+
powerpoint: "powerpoint";
|
|
503
|
+
spaces: "spaces";
|
|
504
|
+
word: "word";
|
|
505
|
+
}>;
|
|
506
|
+
office_launch_mode: z.ZodOptional<z.ZodNullable<z.ZodEnum<{
|
|
507
|
+
invitation: "invitation";
|
|
508
|
+
new_document: "new_document";
|
|
509
|
+
}>>>;
|
|
510
|
+
environment: z.ZodEnum<{
|
|
511
|
+
localhost: "localhost";
|
|
512
|
+
production: "production";
|
|
513
|
+
staging: "staging";
|
|
514
|
+
}>;
|
|
515
|
+
state: z.ZodEnum<{
|
|
516
|
+
acknowledged: "acknowledged";
|
|
517
|
+
claimed: "claimed";
|
|
518
|
+
failed: "failed";
|
|
519
|
+
issued: "issued";
|
|
520
|
+
launched: "launched";
|
|
521
|
+
}>;
|
|
522
|
+
issued_at: z.ZodString;
|
|
523
|
+
expires_at: z.ZodString;
|
|
524
|
+
claimed_at: z.ZodNullable<z.ZodString>;
|
|
525
|
+
acknowledged_at: z.ZodNullable<z.ZodString>;
|
|
526
|
+
failure_reason: z.ZodNullable<z.ZodString>;
|
|
527
|
+
push_delivered: z.ZodNullable<z.ZodBoolean>;
|
|
528
|
+
claimed_surface: z.ZodOptional<z.ZodNullable<z.ZodEnum<{
|
|
529
|
+
chrome: "chrome";
|
|
530
|
+
desktop: "desktop";
|
|
531
|
+
mobile: "mobile";
|
|
532
|
+
spaces: "spaces";
|
|
533
|
+
}>>>;
|
|
534
|
+
mode: z.ZodOptional<z.ZodEnum<{
|
|
535
|
+
text: "text";
|
|
536
|
+
voice: "voice";
|
|
537
|
+
}>>;
|
|
538
|
+
draft: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
539
|
+
}, z.core.$strip>;
|
|
540
|
+
}, z.core.$strip>>;
|
|
541
|
+
/**
|
|
542
|
+
* Receiving half of the protocol: an open Spaces tab, the extension or the
|
|
543
|
+
* phone finds a handoff sent to it (or to `next`), claims it exactly once and
|
|
544
|
+
* reports the outcome. Every call is bound server-side to the signed-in
|
|
545
|
+
* person, workspace and environment. The desktop app is not a destination
|
|
546
|
+
* here: its own receiver claims `/api/handoffs/desktop` and acknowledges with
|
|
547
|
+
* per-asset results, which is why `desktop` is excluded from these calls.
|
|
548
|
+
*/
|
|
549
|
+
export interface ThreadHandoffReceiverTransport {
|
|
550
|
+
getPending: (options: {
|
|
551
|
+
destination: Exclude<ThreadHandoffDestination, 'desktop'>;
|
|
552
|
+
/** Tickets this receiver declined or issued itself; the newest other one is returned. */
|
|
553
|
+
exclude?: readonly string[];
|
|
554
|
+
signal?: AbortSignal;
|
|
555
|
+
}) => Promise<ClaimThreadHandoffResponse | null>;
|
|
556
|
+
claim: (options: {
|
|
557
|
+
handoffId?: string;
|
|
558
|
+
destination: Exclude<ThreadHandoffDestination, 'desktop'>;
|
|
559
|
+
surfaceInstance: string;
|
|
560
|
+
surface?: PickupSurface;
|
|
561
|
+
signal?: AbortSignal;
|
|
562
|
+
}) => Promise<ClaimThreadHandoffResponse>;
|
|
563
|
+
acknowledge: (options: {
|
|
564
|
+
handoffId: string;
|
|
565
|
+
outcome: 'acknowledged' | 'failed';
|
|
566
|
+
reason?: string;
|
|
567
|
+
surfaceInstance: string;
|
|
568
|
+
signal?: AbortSignal;
|
|
569
|
+
}) => Promise<ThreadHandoffView>;
|
|
570
|
+
}
|
|
571
|
+
/**
|
|
572
|
+
* Whether a pending handoff should be offered on this surface: still open,
|
|
573
|
+
* not one this device issued itself, and not one it already declined.
|
|
574
|
+
* Offering never claims; the person's tap does.
|
|
575
|
+
*/
|
|
576
|
+
export declare function shouldOfferPendingHandoff({ pending, issuedHere, declined, now, }: {
|
|
577
|
+
pending: ThreadHandoffView | null | undefined;
|
|
578
|
+
issuedHere: ReadonlySet<string>;
|
|
579
|
+
declined: ReadonlySet<string>;
|
|
580
|
+
now?: number;
|
|
581
|
+
}): boolean;
|
|
582
|
+
/**
|
|
583
|
+
* Surface-specific HTTP adapter. Olympus binds it to `apiClient`; the
|
|
584
|
+
* extension binds it to its authenticated fetch. Both must resolve (not
|
|
585
|
+
* reject) with parsed responses so the flow can attribute failures.
|
|
586
|
+
*/
|
|
587
|
+
export interface ThreadHandoffTransport {
|
|
588
|
+
getReadiness: (options: {
|
|
589
|
+
signal?: AbortSignal;
|
|
590
|
+
}) => Promise<HandoffReadinessResponse>;
|
|
591
|
+
createHandoff: (input: CreateThreadHandoffInput & {
|
|
592
|
+
signal?: AbortSignal;
|
|
593
|
+
}) => Promise<CreateThreadHandoffResponse>;
|
|
594
|
+
getHandoff: (options: {
|
|
595
|
+
handoffId: string;
|
|
596
|
+
signal?: AbortSignal;
|
|
597
|
+
}) => Promise<ThreadHandoffView>;
|
|
598
|
+
}
|
|
599
|
+
export declare const HANDOFF_DESTINATION_LABELS: Record<HandoffDestination, string>;
|
|
600
|
+
/** Picker labels for every destination a "Continue on…" row can name. */
|
|
601
|
+
export declare const THREAD_HANDOFF_DESTINATION_LABELS: Record<ThreadHandoffDestination, string>;
|
|
602
|
+
/** "Pick up your conversation from your phone?" — a destination's offer, before any claim. */
|
|
603
|
+
export declare const pickUpOfferLabel: (source: string) => string;
|
|
604
|
+
/** "Continued from your phone" — the divider a destination shows where it picked up. */
|
|
605
|
+
export declare const continuedFromLabel: (source: string) => string;
|
|
606
|
+
/** "Pick up your conversation from your phone?" — a destination's offer outside its own window. */
|
|
607
|
+
export declare const pickUpFromLabel: (source: string) => string;
|
|
608
|
+
/** What a source says once a `next` handoff was picked up somewhere. */
|
|
609
|
+
export declare const pickedUpOnLabel: (surface: PickupSurface | null | undefined) => string;
|
|
610
|
+
export declare const driverSurfaceForChannel: (channel: string | null | undefined) => PickupSurface | null;
|
|
611
|
+
/**
|
|
612
|
+
* "Driving on your phone" when another of the four surfaces sent last;
|
|
613
|
+
* `null` when this surface is the driver or the driver is unknown.
|
|
614
|
+
*/
|
|
615
|
+
export declare const drivingOnLabel: ({ lastChannel, here, }: {
|
|
616
|
+
lastChannel: string | null | undefined;
|
|
617
|
+
here: PickupSurface;
|
|
618
|
+
}) => string | null;
|
|
619
|
+
/** A landing the destination shows once it owns the thread. */
|
|
620
|
+
export interface HandoffLanding {
|
|
621
|
+
handoffId: string;
|
|
622
|
+
threadId: string;
|
|
623
|
+
/** The raw `source` of the record (`spaces`, `mobile`, …). */
|
|
624
|
+
source: string;
|
|
625
|
+
/** Prefill it; never send it. `null` when the source had nothing typed. */
|
|
626
|
+
draft: string | null;
|
|
627
|
+
/**
|
|
628
|
+
* The person chose to continue by voice. The host offers a one-tap
|
|
629
|
+
* "Continue by voice"; nothing starts the microphone on its own.
|
|
630
|
+
*/
|
|
631
|
+
continueByVoice: boolean;
|
|
632
|
+
}
|
|
633
|
+
export declare const handoffLandingFromView: (view: ThreadHandoffView) => HandoffLanding;
|
|
634
|
+
export declare const isOfficeHandoffDestination: (destination: ThreadHandoffDestination) => destination is OfficeHandoffDestination;
|
|
635
|
+
export declare const isServerHandoffDestination: (destination: HandoffDestination) => destination is ServerHandoffDestination;
|
|
636
|
+
export declare const isPickupSurface: (value: unknown) => value is PickupSurface;
|
|
637
|
+
/** Index a readiness response by destination; missing rows read as `unknown`. */
|
|
638
|
+
export declare const readinessByDestination: (response: HandoffReadinessResponse | null | undefined) => Record<HandoffDestination, DestinationReadiness>;
|
|
639
|
+
/**
|
|
640
|
+
* How a mobile handoff should be presented before the phone answers.
|
|
641
|
+
*
|
|
642
|
+
* - `app`: a fresh push token exists — the phone gets a notification and the
|
|
643
|
+
* QR is only offered as a secondary path.
|
|
644
|
+
* - `qr`: no usable device is known — lead with the QR / link.
|
|
645
|
+
*/
|
|
646
|
+
export type MobileLaunchMode = 'app' | 'qr';
|
|
647
|
+
export declare const selectMobileLaunchMode: (readiness: DestinationReadiness | null | undefined) => MobileLaunchMode;
|
|
648
|
+
/**
|
|
649
|
+
* What a "Continue in…" row should say for a destination given its readiness.
|
|
650
|
+
* Shared so Spaces and the extension render identical copy.
|
|
651
|
+
*/
|
|
652
|
+
export interface HandoffDestinationPresentation {
|
|
653
|
+
destination: HandoffDestination;
|
|
654
|
+
label: string;
|
|
655
|
+
/** Secondary line under the label; `null` when the row needs no caveat. */
|
|
656
|
+
detail: string | null;
|
|
657
|
+
/**
|
|
658
|
+
* `install` rows do not create a handoff — they point at install help;
|
|
659
|
+
* `unavailable` rows are disabled.
|
|
660
|
+
*/
|
|
661
|
+
action: 'handoff' | 'install' | 'unavailable';
|
|
662
|
+
}
|
|
663
|
+
export declare const presentHandoffDestination: ({ destination, readiness, }: {
|
|
664
|
+
destination: HandoffDestination;
|
|
665
|
+
readiness: DestinationReadiness | null | undefined;
|
|
666
|
+
}) => HandoffDestinationPresentation;
|
|
667
|
+
export type HandoffOutcome = {
|
|
668
|
+
status: 'acknowledged';
|
|
669
|
+
handoff: ThreadHandoffView;
|
|
670
|
+
} | {
|
|
671
|
+
status: 'failed';
|
|
672
|
+
handoff: ThreadHandoffView | null;
|
|
673
|
+
reason: string;
|
|
674
|
+
} | {
|
|
675
|
+
status: 'timeout';
|
|
676
|
+
handoff: ThreadHandoffView | null;
|
|
677
|
+
} | {
|
|
678
|
+
status: 'cancelled';
|
|
679
|
+
handoff: ThreadHandoffView | null;
|
|
680
|
+
};
|
|
681
|
+
export declare const isTerminalHandoffState: (state: HandoffState) => boolean;
|
|
682
|
+
export interface WaitForHandoffOutcomeOptions {
|
|
683
|
+
transport: Pick<ThreadHandoffTransport, 'getHandoff'>;
|
|
684
|
+
handoffId: string;
|
|
685
|
+
/** Wall-clock budget; mobile pushes typically land in seconds, Office launches in tens of seconds. */
|
|
686
|
+
timeoutMs: number;
|
|
687
|
+
pollIntervalMs?: number;
|
|
688
|
+
signal?: AbortSignal;
|
|
689
|
+
onUpdate?: (handoff: ThreadHandoffView) => void;
|
|
690
|
+
/** Injected for tests. */
|
|
691
|
+
now?: () => number;
|
|
692
|
+
sleep?: (ms: number, signal?: AbortSignal) => Promise<void>;
|
|
693
|
+
}
|
|
694
|
+
/**
|
|
695
|
+
* Poll one handoff until the destination acknowledges, the server marks it
|
|
696
|
+
* failed, the budget elapses, or the caller aborts. Each request is bound to
|
|
697
|
+
* the remaining budget so a stalled response cannot outlive the deadline.
|
|
698
|
+
* Retryable transport errors are retried within the budget; permanent ones
|
|
699
|
+
* (auth, wrong deployment, malformed payload) fail immediately with their
|
|
700
|
+
* actionable message. The last known view is reported.
|
|
701
|
+
*/
|
|
702
|
+
export declare function waitForHandoffOutcome({ transport, handoffId, timeoutMs, pollIntervalMs, signal, onUpdate, now, sleep, }: WaitForHandoffOutcomeOptions): Promise<HandoffOutcome>;
|
|
703
|
+
/** Error raised by a transport when the server no longer knows the handoff (404). */
|
|
704
|
+
export declare class HandoffGoneError extends Error {
|
|
705
|
+
constructor(handoffId: string);
|
|
706
|
+
}
|
|
707
|
+
export declare const isHandoffGoneError: (error: unknown) => error is HandoffGoneError;
|
|
708
|
+
/**
|
|
709
|
+
* Transport failure that polling the same handoff can never recover from:
|
|
710
|
+
* the session is signed out, the token belongs to another deployment, the
|
|
711
|
+
* server rejected the request, or the payload did not match the schema.
|
|
712
|
+
*/
|
|
713
|
+
export declare class HandoffPermanentError extends Error {
|
|
714
|
+
constructor(message: string, options?: {
|
|
715
|
+
cause?: unknown;
|
|
716
|
+
});
|
|
717
|
+
}
|
|
718
|
+
export declare const isHandoffPermanentError: (error: unknown) => error is HandoffPermanentError;
|
|
719
|
+
export type HandoffTransportErrorKind = 'gone' | 'permanent' | 'retryable';
|
|
720
|
+
/**
|
|
721
|
+
* Shared classification for both transports: only network failures and
|
|
722
|
+
* retryable server statuses keep the poll alive. Schema mismatches surface as
|
|
723
|
+
* `ZodError` from either adapter and are permanent.
|
|
724
|
+
*/
|
|
725
|
+
export declare const classifyHandoffTransportError: (error: unknown) => HandoffTransportErrorKind;
|
|
726
|
+
/** 5xx, timeouts and rate limits may clear on the next poll; any other 4xx will not. */
|
|
727
|
+
export declare const isRetryableHandoffHttpStatus: (status: number) => boolean;
|
|
728
|
+
/**
|
|
729
|
+
* Map a non-2xx status to the transport error the poll loop understands.
|
|
730
|
+
* `detail` is the server's actionable message when it sent one.
|
|
731
|
+
*/
|
|
732
|
+
export declare const handoffHttpError: ({ handoffId, status, detail, }: {
|
|
733
|
+
handoffId: string;
|
|
734
|
+
status: number;
|
|
735
|
+
detail: string | null;
|
|
736
|
+
}) => Error;
|
|
737
|
+
export declare const describeHandoffTransportError: (error: unknown) => string;
|
|
738
|
+
/** `?handoff=<id>` — the query parameter mobile-web and QR links carry. */
|
|
739
|
+
export declare const HANDOFF_URL_PARAM = "handoff";
|
|
740
|
+
/** `?continue_handoff=<id>` — where a continuation lands in Spaces (never a phone's ticket). */
|
|
741
|
+
export declare const SPACES_HANDOFF_URL_PARAM = "continue_handoff";
|
|
742
|
+
/**
|
|
743
|
+
* Read a handoff id from a URL. Ids are server-issued, URL-safe tokens; anything
|
|
744
|
+
* else is rejected so a tampered link never reaches the claim path.
|
|
745
|
+
*/
|
|
746
|
+
export declare const parseHandoffIdParam: (value: string | null | undefined) => string | null;
|
|
747
|
+
/** Athena Mobile's custom URL scheme (`mobile-app-react-native/app.json` → `scheme`). */
|
|
748
|
+
export declare const MOBILE_APP_SCHEME = "athenavisionapplication";
|
|
749
|
+
/**
|
|
750
|
+
* Custom-scheme launch for a handoff — what a phone's browser opens when the
|
|
751
|
+
* Universal/App Link landed on mobile web instead of in the app. Mirrors
|
|
752
|
+
* agora's `_mobile_scheme_url`; carries only the opaque handoff id.
|
|
753
|
+
*/
|
|
754
|
+
export declare const buildMobileHandoffSchemeUrl: ({ handoffId }: {
|
|
755
|
+
handoffId: string;
|
|
756
|
+
}) => string;
|