@epam/ai-dial-chat-hooks 1.3.0-dev.5 → 1.3.0-dev.55
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/api-error/api-error.d.ts +30 -0
- package/api-error/api-error.d.ts.map +1 -0
- package/api-transport/create-csrf-middleware.d.ts +15 -0
- package/api-transport/create-csrf-middleware.d.ts.map +1 -0
- package/api-transport/create-unauthorized-middleware.d.ts +40 -0
- package/api-transport/create-unauthorized-middleware.d.ts.map +1 -0
- package/attachment/useAttachmentAction/useAttachmentAction.d.ts +32 -0
- package/attachment/useAttachmentAction/useAttachmentAction.d.ts.map +1 -0
- package/attachment/useAttachmentValidation/useAttachmentValidation.d.ts +50 -0
- package/attachment/useAttachmentValidation/useAttachmentValidation.d.ts.map +1 -0
- package/attachments.d.ts +2 -94
- package/catalog/catalog-derivations.d.ts +27 -0
- package/catalog/catalog-derivations.d.ts.map +1 -0
- package/catalog/catalog-primary-action.d.ts +47 -0
- package/catalog/catalog-primary-action.d.ts.map +1 -0
- package/catalog/create-publish-api.d.ts +32 -0
- package/catalog/create-publish-api.d.ts.map +1 -0
- package/catalog/deployment-endpoint-url.d.ts +19 -0
- package/catalog/deployment-endpoint-url.d.ts.map +1 -0
- package/catalog/deployment-id.d.ts +42 -0
- package/catalog/deployment-id.d.ts.map +1 -0
- package/catalog/entity-details.d.ts +146 -0
- package/catalog/entity-details.d.ts.map +1 -0
- package/catalog/map-deployment-limits-to-catalog.d.ts +34 -0
- package/catalog/map-deployment-limits-to-catalog.d.ts.map +1 -0
- package/catalog/map-deployment-limits-to-input.d.ts +28 -0
- package/catalog/map-deployment-limits-to-input.d.ts.map +1 -0
- package/catalog/map-deployment-to-catalog-item.d.ts +61 -0
- package/catalog/map-deployment-to-catalog-item.d.ts.map +1 -0
- package/catalog/map-entity-details-to-catalog.d.ts +81 -0
- package/catalog/map-entity-details-to-catalog.d.ts.map +1 -0
- package/catalog/map-prompt-to-catalog-item.d.ts +43 -0
- package/catalog/map-prompt-to-catalog-item.d.ts.map +1 -0
- package/catalog/map-skill-to-catalog-item.d.ts +113 -0
- package/catalog/map-skill-to-catalog-item.d.ts.map +1 -0
- package/catalog/mcp-endpoint-url.d.ts +18 -0
- package/catalog/mcp-endpoint-url.d.ts.map +1 -0
- package/catalog/publish.d.ts +35 -0
- package/catalog/publish.d.ts.map +1 -0
- package/catalog/useApplicationCredentials/useApplicationCredentials.d.ts +19 -0
- package/catalog/useApplicationCredentials/useApplicationCredentials.d.ts.map +1 -0
- package/catalog/useCatalogEditNavigation/useCatalogEditNavigation.d.ts +100 -0
- package/catalog/useCatalogEditNavigation/useCatalogEditNavigation.d.ts.map +1 -0
- package/catalog/useCatalogEditNavigation/useCatalogEditNavigation.js +139 -122
- package/catalog/useCatalogItemDetails.d.ts +70 -0
- package/catalog/useCatalogItemDetails.d.ts.map +1 -0
- package/catalog/useCatalogToolsetCredentials/useCatalogToolsetCredentials.d.ts +76 -0
- package/catalog/useCatalogToolsetCredentials/useCatalogToolsetCredentials.d.ts.map +1 -0
- package/catalog/useFavoriteEntitiesState/useFavoriteEntitiesState.d.ts +37 -0
- package/catalog/useFavoriteEntitiesState/useFavoriteEntitiesState.d.ts.map +1 -0
- package/catalog/usePublishFolders/usePublishFolders.d.ts +73 -0
- package/catalog/usePublishFolders/usePublishFolders.d.ts.map +1 -0
- package/catalog/useSkillDetailsPanelData/useSkillDetailsPanelData.d.ts +54 -0
- package/catalog/useSkillDetailsPanelData/useSkillDetailsPanelData.d.ts.map +1 -0
- package/catalog/useSkillItemDetails.d.ts +64 -0
- package/catalog/useSkillItemDetails.d.ts.map +1 -0
- package/catalog.d.ts +2 -1433
- package/conversation/announcement-message.d.ts +61 -0
- package/conversation/announcement-message.d.ts.map +1 -0
- package/conversation/conversation-transfer/async.d.ts +10 -0
- package/conversation/conversation-transfer/async.d.ts.map +1 -0
- package/conversation/conversation-transfer/attachment-refs.d.ts +42 -0
- package/conversation/conversation-transfer/attachment-refs.d.ts.map +1 -0
- package/conversation/conversation-transfer/build-upload-path.d.ts +42 -0
- package/conversation/conversation-transfer/build-upload-path.d.ts.map +1 -0
- package/conversation/conversation-transfer/date.d.ts +5 -0
- package/conversation/conversation-transfer/date.d.ts.map +1 -0
- package/conversation/conversation-transfer/dial-file-resolve.d.ts +10 -0
- package/conversation/conversation-transfer/dial-file-resolve.d.ts.map +1 -0
- package/conversation/conversation-transfer/export-conversation.d.ts +10 -0
- package/conversation/conversation-transfer/export-conversation.d.ts.map +1 -0
- package/conversation/conversation-transfer/import-conversation.d.ts +106 -0
- package/conversation/conversation-transfer/import-conversation.d.ts.map +1 -0
- package/conversation/conversation-transfer/progress.d.ts +60 -0
- package/conversation/conversation-transfer/progress.d.ts.map +1 -0
- package/conversation/conversation-transfer/queue.d.ts +54 -0
- package/conversation/conversation-transfer/queue.d.ts.map +1 -0
- package/conversation/conversation-transfer/types.d.ts +36 -0
- package/conversation/conversation-transfer/types.d.ts.map +1 -0
- package/conversation/conversation-transfer/zip-export.d.ts +31 -0
- package/conversation/conversation-transfer/zip-export.d.ts.map +1 -0
- package/conversation/conversation-transfer/zip-import.d.ts +17 -0
- package/conversation/conversation-transfer/zip-import.d.ts.map +1 -0
- package/conversation/create-chat-stream-api.d.ts +92 -0
- package/conversation/create-chat-stream-api.d.ts.map +1 -0
- package/conversation/deriveConversationRowActionState/deriveConversationRowActionState.d.ts +39 -0
- package/conversation/deriveConversationRowActionState/deriveConversationRowActionState.d.ts.map +1 -0
- package/conversation/display-name-watch.d.ts +4 -0
- package/conversation/display-name-watch.d.ts.map +1 -0
- package/conversation/footer-message.d.ts +10 -0
- package/conversation/footer-message.d.ts.map +1 -0
- package/conversation/get-model-id-from-conversation-id.d.ts +38 -0
- package/conversation/get-model-id-from-conversation-id.d.ts.map +1 -0
- package/conversation/greeting.d.ts +18 -0
- package/conversation/greeting.d.ts.map +1 -0
- package/conversation/message-factory.d.ts +7 -0
- package/conversation/message-factory.d.ts.map +1 -0
- package/conversation/message-utils.d.ts +67 -0
- package/conversation/message-utils.d.ts.map +1 -0
- package/conversation/overlay-messages.d.ts +5 -0
- package/conversation/overlay-messages.d.ts.map +1 -0
- package/conversation/quick-app-conversation-starters.d.ts +10 -0
- package/conversation/quick-app-conversation-starters.d.ts.map +1 -0
- package/conversation/stage.d.ts +77 -0
- package/conversation/stage.d.ts.map +1 -0
- package/conversation/starter-option.d.ts +21 -0
- package/conversation/starter-option.d.ts.map +1 -0
- package/conversation/useActiveConversationSync/useActiveConversationSync.d.ts +35 -0
- package/conversation/useActiveConversationSync/useActiveConversationSync.d.ts.map +1 -0
- package/conversation/useAsyncConfirmDialog/useAsyncConfirmDialog.d.ts +46 -0
- package/conversation/useAsyncConfirmDialog/useAsyncConfirmDialog.d.ts.map +1 -0
- package/conversation/useAttachmentUpload/useAttachmentUpload.d.ts +27 -0
- package/conversation/useAttachmentUpload/useAttachmentUpload.d.ts.map +1 -0
- package/conversation/useConversationExport/useConversationExport.d.ts +72 -0
- package/conversation/useConversationExport/useConversationExport.d.ts.map +1 -0
- package/conversation/useConversationHandlers/attachment-to-dto.d.ts +7 -0
- package/conversation/useConversationHandlers/attachment-to-dto.d.ts.map +1 -0
- package/conversation/useConversationHandlers/message-factory.d.ts +9 -0
- package/conversation/useConversationHandlers/message-factory.d.ts.map +1 -0
- package/conversation/useConversationHandlers/message-utils.d.ts +38 -0
- package/conversation/useConversationHandlers/message-utils.d.ts.map +1 -0
- package/conversation/useConversationHandlers/starter-option.d.ts +24 -0
- package/conversation/useConversationHandlers/starter-option.d.ts.map +1 -0
- package/conversation/useConversationHandlers/useConversationHandlers.d.ts +66 -0
- package/conversation/useConversationHandlers/useConversationHandlers.d.ts.map +1 -0
- package/conversation/useConversationImport/useConversationImport.d.ts +54 -0
- package/conversation/useConversationImport/useConversationImport.d.ts.map +1 -0
- package/conversation/useConversationLookupMaps/useConversationLookupMaps.d.ts +24 -0
- package/conversation/useConversationLookupMaps/useConversationLookupMaps.d.ts.map +1 -0
- package/conversation/useConversationPanelItems/useConversationPanelItems.d.ts +64 -0
- package/conversation/useConversationPanelItems/useConversationPanelItems.d.ts.map +1 -0
- package/conversation/useConversationScroll/useConversationScroll.d.ts +46 -0
- package/conversation/useConversationScroll/useConversationScroll.d.ts.map +1 -0
- package/conversation/useConversationStream/apply-chunk.d.ts +35 -0
- package/conversation/useConversationStream/apply-chunk.d.ts.map +1 -0
- package/conversation/useConversationStream/buffered-generation.d.ts +15 -0
- package/conversation/useConversationStream/buffered-generation.d.ts.map +1 -0
- package/conversation/useConversationStream/conversation-path.d.ts +7 -0
- package/conversation/useConversationStream/conversation-path.d.ts.map +1 -0
- package/conversation/useConversationStream/frame-scheduler.d.ts +14 -0
- package/conversation/useConversationStream/frame-scheduler.d.ts.map +1 -0
- package/conversation/useConversationStream/generation-resume.d.ts +85 -0
- package/conversation/useConversationStream/generation-resume.d.ts.map +1 -0
- package/conversation/useConversationStream/useConversationStream.d.ts +145 -0
- package/conversation/useConversationStream/useConversationStream.d.ts.map +1 -0
- package/conversation/useImportFilePicker/useImportFilePicker.d.ts +32 -0
- package/conversation/useImportFilePicker/useImportFilePicker.d.ts.map +1 -0
- package/conversation/useMessageSelectionReply/useMessageSelectionReply.d.ts +42 -0
- package/conversation/useMessageSelectionReply/useMessageSelectionReply.d.ts.map +1 -0
- package/conversation/useTranscribeAudio/audio-transcription-error.d.ts +19 -0
- package/conversation/useTranscribeAudio/audio-transcription-error.d.ts.map +1 -0
- package/conversation/useTranscribeAudio/transcription-retry.d.ts +2 -0
- package/conversation/useTranscribeAudio/transcription-retry.d.ts.map +1 -0
- package/conversation/useTranscribeAudio/useTranscribeAudio.d.ts +43 -0
- package/conversation/useTranscribeAudio/useTranscribeAudio.d.ts.map +1 -0
- package/conversation-overlay.d.ts +2 -7
- package/conversation-sources/useConversationSources/useConversationSources.d.ts +20 -0
- package/conversation-sources/useConversationSources/useConversationSources.d.ts.map +1 -0
- package/conversation-sources.d.ts +2 -25
- package/conversation-transfer.d.ts +2 -190
- package/conversation.d.ts +2 -1372
- package/entry-points/attachments.d.ts +3 -0
- package/entry-points/attachments.d.ts.map +1 -0
- package/entry-points/catalog.d.ts +25 -0
- package/entry-points/catalog.d.ts.map +1 -0
- package/entry-points/conversation-overlay.d.ts +2 -0
- package/entry-points/conversation-overlay.d.ts.map +1 -0
- package/entry-points/conversation-sources.d.ts +2 -0
- package/entry-points/conversation-sources.d.ts.map +1 -0
- package/entry-points/conversation-transfer.d.ts +7 -0
- package/entry-points/conversation-transfer.d.ts.map +1 -0
- package/entry-points/conversation.d.ts +33 -0
- package/entry-points/conversation.d.ts.map +1 -0
- package/entry-points/file-manager-canvas.d.ts +2 -0
- package/entry-points/file-manager-canvas.d.ts.map +1 -0
- package/entry-points/file-manager.d.ts +31 -0
- package/entry-points/file-manager.d.ts.map +1 -0
- package/entry-points/mcp-apps.d.ts +6 -0
- package/entry-points/mcp-apps.d.ts.map +1 -0
- package/entry-points/oauth.d.ts +10 -0
- package/entry-points/oauth.d.ts.map +1 -0
- package/entry-points/scheduled-tasks.d.ts +8 -0
- package/entry-points/scheduled-tasks.d.ts.map +1 -0
- package/entry-points/scroll-anchoring.d.ts +2 -0
- package/entry-points/scroll-anchoring.d.ts.map +1 -0
- package/entry-points/sharing.d.ts +3 -0
- package/entry-points/sharing.d.ts.map +1 -0
- package/entry-points/skill-editor.d.ts +9 -0
- package/entry-points/skill-editor.d.ts.map +1 -0
- package/entry-points/skills-state.d.ts +2 -0
- package/entry-points/skills-state.d.ts.map +1 -0
- package/entry-points/source-content.d.ts +2 -0
- package/entry-points/source-content.d.ts.map +1 -0
- package/entry-points/usage-limits.d.ts +8 -0
- package/entry-points/usage-limits.d.ts.map +1 -0
- package/entry-points/usage.d.ts +3 -0
- package/entry-points/usage.d.ts.map +1 -0
- package/entry-points/utils.d.ts +17 -0
- package/entry-points/utils.d.ts.map +1 -0
- package/entry-points/viewport-layout.d.ts +4 -0
- package/entry-points/viewport-layout.d.ts.map +1 -0
- package/file-manager-canvas.d.ts +2 -418
- package/file-manager.d.ts +2 -1237
- package/file-manager.js +25 -25
- package/files/annotation.d.ts +10 -0
- package/files/annotation.d.ts.map +1 -0
- package/files/attachment-canvas.d.ts +123 -0
- package/files/attachment-canvas.d.ts.map +1 -0
- package/files/attachment-dto-to-display.d.ts +10 -0
- package/files/attachment-dto-to-display.d.ts.map +1 -0
- package/files/attachment-types.d.ts +21 -0
- package/files/attachment-types.d.ts.map +1 -0
- package/files/create-files-api.d.ts +52 -0
- package/files/create-files-api.d.ts.map +1 -0
- package/files/create-upload-file-with-progress.d.ts +24 -0
- package/files/create-upload-file-with-progress.d.ts.map +1 -0
- package/files/dial-file-manager-copy-move.util.d.ts +15 -0
- package/files/dial-file-manager-copy-move.util.d.ts.map +1 -0
- package/files/dial-file-manager-mapping.util.d.ts +35 -0
- package/files/dial-file-manager-mapping.util.d.ts.map +1 -0
- package/files/dial-file-manager-path.util.d.ts +48 -0
- package/files/dial-file-manager-path.util.d.ts.map +1 -0
- package/files/dial-file-manager.model.d.ts +36 -0
- package/files/dial-file-manager.model.d.ts.map +1 -0
- package/files/dial-file-manager.model.js +7 -3
- package/files/dial-file-manager.types.d.ts +327 -0
- package/files/dial-file-manager.types.d.ts.map +1 -0
- package/files/dial-file-manager.types.js +1 -1
- package/files/dial-file-to-attachment.d.ts +26 -0
- package/files/dial-file-to-attachment.d.ts.map +1 -0
- package/files/dial-file.d.ts +17 -0
- package/files/dial-file.d.ts.map +1 -0
- package/files/dial-files-api.d.ts +71 -0
- package/files/dial-files-api.d.ts.map +1 -0
- package/files/download-destination.d.ts +31 -0
- package/files/download-destination.d.ts.map +1 -0
- package/files/file-manager-variant.d.ts +3 -0
- package/files/file-manager-variant.d.ts.map +1 -0
- package/files/file-name.d.ts +19 -0
- package/files/file-name.d.ts.map +1 -0
- package/files/prepare-download-destination.d.ts +8 -0
- package/files/prepare-download-destination.d.ts.map +1 -0
- package/files/resolve-dial-file-api-path.d.ts +12 -0
- package/files/resolve-dial-file-api-path.d.ts.map +1 -0
- package/files/source-content.d.ts +28 -0
- package/files/source-content.d.ts.map +1 -0
- package/files/useDialFileListing/useDialFileListing.d.ts +82 -0
- package/files/useDialFileListing/useDialFileListing.d.ts.map +1 -0
- package/files/useDialFileListing/useDialFileListing.js +24 -14
- package/files/useDialFileManager/useDialFileManager.d.ts +16 -0
- package/files/useDialFileManager/useDialFileManager.d.ts.map +1 -0
- package/files/useDialFileManager/useDialFileManager.js +148 -140
- package/files/useDialFileManagerSections/useDialFileManagerSections.d.ts +25 -0
- package/files/useDialFileManagerSections/useDialFileManagerSections.d.ts.map +1 -0
- package/files/useDialFileManagerTabConfig/useDialFileManagerTabConfig.d.ts +15 -0
- package/files/useDialFileManagerTabConfig/useDialFileManagerTabConfig.d.ts.map +1 -0
- package/files/useDialFileMetadata/useDialFileMetadata.d.ts +28 -0
- package/files/useDialFileMetadata/useDialFileMetadata.d.ts.map +1 -0
- package/files/useDialFileMutations/useDialFileMutations.d.ts +68 -0
- package/files/useDialFileMutations/useDialFileMutations.d.ts.map +1 -0
- package/files/useDialFileMutations/useDialFileMutations.js +206 -204
- package/files/useDialFileSharing/useDialFileSharing.d.ts +34 -0
- package/files/useDialFileSharing/useDialFileSharing.d.ts.map +1 -0
- package/files/useDialFileSharing/useDialFileSharing.js +45 -39
- package/files/useDialFileUploadBatch/useDialFileUploadBatch.d.ts +47 -0
- package/files/useDialFileUploadBatch/useDialFileUploadBatch.d.ts.map +1 -0
- package/files/useDialFileUploadBatch/useDialFileUploadBatch.js +8 -4
- package/files/useFileAttachmentPicker/useFileAttachmentPicker.d.ts +59 -0
- package/files/useFileAttachmentPicker/useFileAttachmentPicker.d.ts.map +1 -0
- package/index.d.ts +159 -6974
- package/index.d.ts.map +1 -0
- package/index.js +124 -117
- package/mcp-apps/mcp-apps-api-client.d.ts +28 -0
- package/mcp-apps/mcp-apps-api-client.d.ts.map +1 -0
- package/mcp-apps/useMcpAppHostAdapter/useMcpAppHostAdapter.d.ts +14 -0
- package/mcp-apps/useMcpAppHostAdapter/useMcpAppHostAdapter.d.ts.map +1 -0
- package/mcp-apps/useMcpAppHostContext/useMcpAppHostContext.d.ts +29 -0
- package/mcp-apps/useMcpAppHostContext/useMcpAppHostContext.d.ts.map +1 -0
- package/mcp-apps/useMcpAppTools/useMcpAppTools.d.ts +22 -0
- package/mcp-apps/useMcpAppTools/useMcpAppTools.d.ts.map +1 -0
- package/mcp-apps/useOpenMcpAppCanvas/useOpenMcpAppCanvas.d.ts +36 -0
- package/mcp-apps/useOpenMcpAppCanvas/useOpenMcpAppCanvas.d.ts.map +1 -0
- package/mcp-apps.d.ts +2 -256
- package/oauth/authorize-url.d.ts +16 -0
- package/oauth/authorize-url.d.ts.map +1 -0
- package/oauth/handshake.d.ts +30 -0
- package/oauth/handshake.d.ts.map +1 -0
- package/oauth/models.d.ts +81 -0
- package/oauth/models.d.ts.map +1 -0
- package/oauth/popup.d.ts +30 -0
- package/oauth/popup.d.ts.map +1 -0
- package/oauth/toolset-id.d.ts +53 -0
- package/oauth/toolset-id.d.ts.map +1 -0
- package/oauth/types.d.ts +84 -0
- package/oauth/types.d.ts.map +1 -0
- package/oauth/useOAuthCallbackCompletion/useOAuthCallbackCompletion.d.ts +54 -0
- package/oauth/useOAuthCallbackCompletion/useOAuthCallbackCompletion.d.ts.map +1 -0
- package/oauth/useToolsetLogin/useToolsetLogin.d.ts +79 -0
- package/oauth/useToolsetLogin/useToolsetLogin.d.ts.map +1 -0
- package/oauth.d.ts +2 -472
- package/package.json +26 -17
- package/prompt/export-prompt.d.ts +31 -0
- package/prompt/export-prompt.d.ts.map +1 -0
- package/prompt/prompt-resource.d.ts +30 -0
- package/prompt/prompt-resource.d.ts.map +1 -0
- package/prompt/prompt.d.ts +34 -0
- package/prompt/prompt.d.ts.map +1 -0
- package/prompt/usePromptsState/usePromptsState.d.ts +34 -0
- package/prompt/usePromptsState/usePromptsState.d.ts.map +1 -0
- package/scheduled-task/scheduled-task-description.d.ts +38 -0
- package/scheduled-task/scheduled-task-description.d.ts.map +1 -0
- package/scheduled-task/scheduled-task-mapping.d.ts +19 -0
- package/scheduled-task/scheduled-task-mapping.d.ts.map +1 -0
- package/scheduled-task/scheduled-task-preparation.d.ts +19 -0
- package/scheduled-task/scheduled-task-preparation.d.ts.map +1 -0
- package/scheduled-task/scheduled-task-trigger.d.ts +26 -0
- package/scheduled-task/scheduled-task-trigger.d.ts.map +1 -0
- package/scheduled-task/scheduled-tasks-api-client.d.ts +67 -0
- package/scheduled-task/scheduled-tasks-api-client.d.ts.map +1 -0
- package/scheduled-task/use-scheduled-task-runs.d.ts +40 -0
- package/scheduled-task/use-scheduled-task-runs.d.ts.map +1 -0
- package/scheduled-task/use-scheduled-task-runs.js +67 -67
- package/scheduled-task/use-scheduled-tasks.d.ts +28 -0
- package/scheduled-task/use-scheduled-tasks.d.ts.map +1 -0
- package/scheduled-tasks.d.ts +2 -250
- package/scroll-anchoring.d.ts +2 -50
- package/shared/application-schema.d.ts +18 -0
- package/shared/application-schema.d.ts.map +1 -0
- package/shared/application-schema.js +2 -2
- package/shared/browser-timezone.d.ts +7 -0
- package/shared/browser-timezone.d.ts.map +1 -0
- package/shared/cron-day-of-month.d.ts +21 -0
- package/shared/cron-day-of-month.d.ts.map +1 -0
- package/shared/cron-weekday.d.ts +5 -0
- package/shared/cron-weekday.d.ts.map +1 -0
- package/shared/custom-apps.d.ts +7 -0
- package/shared/custom-apps.d.ts.map +1 -0
- package/shared/external-services.d.ts +16 -0
- package/shared/external-services.d.ts.map +1 -0
- package/shared/formatting.d.ts +5 -0
- package/shared/formatting.d.ts.map +1 -0
- package/shared/locale.d.ts +45 -0
- package/shared/locale.d.ts.map +1 -0
- package/shared/string-utils.d.ts +11 -0
- package/shared/string-utils.d.ts.map +1 -0
- package/shared/toolset-login-events.d.ts +15 -0
- package/shared/toolset-login-events.d.ts.map +1 -0
- package/sharing.d.ts +2 -65
- package/skill/skill-archive.d.ts +7 -0
- package/skill/skill-archive.d.ts.map +1 -0
- package/skill/skill-file-batch-validation.d.ts +70 -0
- package/skill/skill-file-batch-validation.d.ts.map +1 -0
- package/skill/skill-file-preview.d.ts +25 -0
- package/skill/skill-file-preview.d.ts.map +1 -0
- package/skill/skill-manifest.d.ts +28 -0
- package/skill/skill-manifest.d.ts.map +1 -0
- package/skill/skill-types.d.ts +46 -0
- package/skill/skill-types.d.ts.map +1 -0
- package/skill/skill.d.ts +160 -0
- package/skill/skill.d.ts.map +1 -0
- package/skill/useSkillArchiveImport/useSkillArchiveImport.d.ts +65 -0
- package/skill/useSkillArchiveImport/useSkillArchiveImport.d.ts.map +1 -0
- package/skill/useSkillEditorLoad.d.ts +74 -0
- package/skill/useSkillEditorLoad.d.ts.map +1 -0
- package/skill/useSkillEditorSubmit.d.ts +125 -0
- package/skill/useSkillEditorSubmit.d.ts.map +1 -0
- package/skill/useSkillFileActions.d.ts +60 -0
- package/skill/useSkillFileActions.d.ts.map +1 -0
- package/skill/useSkillFilePreview.d.ts +38 -0
- package/skill/useSkillFilePreview.d.ts.map +1 -0
- package/skill/useSkillsState/useSkillsState.d.ts +35 -0
- package/skill/useSkillsState/useSkillsState.d.ts.map +1 -0
- package/skill-editor.d.ts +2 -655
- package/skills-state.d.ts +2 -40
- package/source-content.d.ts +2 -29
- package/usage/map-usage-data-to-dashboard.d.ts +39 -0
- package/usage/map-usage-data-to-dashboard.d.ts.map +1 -0
- package/usage/map-user-usage-to-model-limits.d.ts +62 -0
- package/usage/map-user-usage-to-model-limits.d.ts.map +1 -0
- package/usage/usage-banner-source.d.ts +23 -0
- package/usage/usage-banner-source.d.ts.map +1 -0
- package/usage/usage-banner-source.js +36 -0
- package/usage/usage-period.d.ts +7 -0
- package/usage/usage-period.d.ts.map +1 -0
- package/usage/usage-period.js +6 -0
- package/usage/usage-reset-time.d.ts +69 -0
- package/usage/usage-reset-time.d.ts.map +1 -0
- package/usage/usage-reset-time.js +72 -0
- package/usage/useDeploymentUsageLimits/useDeploymentUsageLimits.d.ts +32 -0
- package/usage/useDeploymentUsageLimits/useDeploymentUsageLimits.d.ts.map +1 -0
- package/usage/useDeploymentUsageLimits/useDeploymentUsageLimits.js +39 -0
- package/usage/useRefreshUsageAfterGeneration/useRefreshUsageAfterGeneration.d.ts +16 -0
- package/usage/useRefreshUsageAfterGeneration/useRefreshUsageAfterGeneration.d.ts.map +1 -0
- package/usage/useRefreshUsageAfterGeneration/useRefreshUsageAfterGeneration.js +14 -0
- package/usage/useUsageData/useUsageData.d.ts +28 -0
- package/usage/useUsageData/useUsageData.d.ts.map +1 -0
- package/usage/useUsageLimitBanner/useUsageLimitBanner.d.ts +56 -0
- package/usage/useUsageLimitBanner/useUsageLimitBanner.d.ts.map +1 -0
- package/usage/useUsageLimitBanner/useUsageLimitBanner.js +67 -0
- package/usage/useUsageLimitBannerDismissal/useUsageLimitBannerDismissal.d.ts +14 -0
- package/usage/useUsageLimitBannerDismissal/useUsageLimitBannerDismissal.d.ts.map +1 -0
- package/usage/useUsageLimitBannerDismissal/useUsageLimitBannerDismissal.js +19 -0
- package/usage-limits.d.ts +2 -0
- package/usage-limits.js +8 -0
- package/usage.d.ts +2 -125
- package/useChatSettingsFormConfig/useChatSettingsFormConfig.d.ts +128 -0
- package/useChatSettingsFormConfig/useChatSettingsFormConfig.d.ts.map +1 -0
- package/usePageFileDrag/usePageFileDrag.d.ts +16 -0
- package/usePageFileDrag/usePageFileDrag.d.ts.map +1 -0
- package/usePanelMaxWidth/usePanelMaxWidth.d.ts +6 -0
- package/usePanelMaxWidth/usePanelMaxWidth.d.ts.map +1 -0
- package/useShareLink/useShareLink.d.ts +23 -0
- package/useShareLink/useShareLink.d.ts.map +1 -0
- package/useShareRecipientsCount/useShareRecipientsCount.d.ts +36 -0
- package/useShareRecipientsCount/useShareRecipientsCount.d.ts.map +1 -0
- package/useToolsMenu/useToolsMenu.d.ts +31 -0
- package/useToolsMenu/useToolsMenu.d.ts.map +1 -0
- package/useViewportWidth/useViewportWidth.d.ts +3 -0
- package/useViewportWidth/useViewportWidth.d.ts.map +1 -0
- package/utils.d.ts +2 -404
- package/utils.js +10 -10
- package/viewport-layout.d.ts +2 -27
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
/** Normalized shape returned by {@link getApiErrorDetails}. */
|
|
2
|
+
export interface ApiErrorDetails {
|
|
3
|
+
/** Stable domain error code supplied by the API, when present. */
|
|
4
|
+
code?: string;
|
|
5
|
+
/** HTTP status code carried by the error, when available. */
|
|
6
|
+
status?: number;
|
|
7
|
+
/** Resolved human-readable error message, or `null` when none could be resolved. */
|
|
8
|
+
message: string | null;
|
|
9
|
+
/** Extracted W3C trace ID, when the error's response carries a valid `traceparent`. */
|
|
10
|
+
traceId?: string;
|
|
11
|
+
/**
|
|
12
|
+
* Error code reported by the service behind the API, when the API forwards one
|
|
13
|
+
* (`upstreamCode`). Passed through as-is; the host decides whether to act on it.
|
|
14
|
+
*/
|
|
15
|
+
upstreamCode?: string;
|
|
16
|
+
/**
|
|
17
|
+
* Error reason reported by the service behind the API, when the API forwards one
|
|
18
|
+
* (`upstreamMessage`). Untranslated; the host decides whether to display it.
|
|
19
|
+
*/
|
|
20
|
+
upstreamMessage?: string;
|
|
21
|
+
}
|
|
22
|
+
/** True when the API indicates the conversation resource no longer exists at the path. */
|
|
23
|
+
export declare const isConversationNotFoundError: (error: unknown) => boolean;
|
|
24
|
+
/** HTTP status code carried by a thrown API error, or `undefined` if none is attached. */
|
|
25
|
+
export declare const getApiErrorStatus: (error: unknown) => number | undefined;
|
|
26
|
+
/** Resolves a human-readable message from an API error's response body, or falls back to `Error.message`. */
|
|
27
|
+
export declare const getApiErrorMessage: (error: unknown) => Promise<string | null>;
|
|
28
|
+
/** Normalizes any API error into a `{ status?, message, traceId?, code?, upstreamCode?, upstreamMessage? }` shape. */
|
|
29
|
+
export declare const getApiErrorDetails: (error: unknown) => Promise<ApiErrorDetails>;
|
|
30
|
+
//# sourceMappingURL=api-error.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"api-error.d.ts","sourceRoot":"","sources":["../../src/api-error/api-error.ts"],"names":[],"mappings":"AAMA,+DAA+D;AAC/D,MAAM,WAAW,eAAe;IAC9B,kEAAkE;IAClE,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,6DAA6D;IAC7D,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,oFAAoF;IACpF,OAAO,EAAE,MAAM,GAAG,IAAI,CAAC;IACvB,uFAAuF;IACvF,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB;;;OAGG;IACH,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB;;;OAGG;IACH,eAAe,CAAC,EAAE,MAAM,CAAC;CAC1B;AAqED,0FAA0F;AAC1F,eAAO,MAAM,2BAA2B,GAAI,OAAO,OAAO,KAAG,OAI5D,CAAC;AAEF,0FAA0F;AAC1F,eAAO,MAAM,iBAAiB,GAAI,OAAO,OAAO,KAAG,MAAM,GAAG,SAC3B,CAAC;AAElC,6GAA6G;AAC7G,eAAO,MAAM,kBAAkB,GAC7B,OAAO,OAAO,KACb,OAAO,CAAC,MAAM,GAAG,IAAI,CAevB,CAAC;AAEF,sHAAsH;AActH,eAAO,MAAM,kBAAkB,GAC7B,OAAO,OAAO,KACb,OAAO,CAAC,eAAe,CAyDzB,CAAC"}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { Middleware } from '@epam/ai-dial-chat-api-client';
|
|
2
|
+
/** Host capabilities {@link createCsrfMiddleware} needs to attach and capture a CSRF token. */
|
|
3
|
+
export interface CreateCsrfMiddlewareDeps {
|
|
4
|
+
/** Returns the currently held CSRF token, or `null` when none is set. */
|
|
5
|
+
getCsrfToken: () => string | null;
|
|
6
|
+
/** Stores a CSRF token captured from a response header, or `null` to clear it. */
|
|
7
|
+
setCsrfToken: (token: string | null) => void;
|
|
8
|
+
}
|
|
9
|
+
/**
|
|
10
|
+
* Builds a generated-client `Middleware` that attaches `X-CSRF-Token` on every
|
|
11
|
+
* non-GET request when a token is set, and captures a rotated token from the
|
|
12
|
+
* `x-csrf-token` response header.
|
|
13
|
+
*/
|
|
14
|
+
export declare const createCsrfMiddleware: (deps: CreateCsrfMiddlewareDeps) => Middleware;
|
|
15
|
+
//# sourceMappingURL=create-csrf-middleware.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"create-csrf-middleware.d.ts","sourceRoot":"","sources":["../../src/api-transport/create-csrf-middleware.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,+BAA+B,CAAC;AAEhE,+FAA+F;AAC/F,MAAM,WAAW,wBAAwB;IACvC,yEAAyE;IACzE,YAAY,EAAE,MAAM,MAAM,GAAG,IAAI,CAAC;IAClC,kFAAkF;IAClF,YAAY,EAAE,CAAC,KAAK,EAAE,MAAM,GAAG,IAAI,KAAK,IAAI,CAAC;CAC9C;AAED;;;;GAIG;AACH,eAAO,MAAM,oBAAoB,GAC/B,MAAM,wBAAwB,KAC7B,UAqBD,CAAC"}
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
import { Middleware } from '@epam/ai-dial-chat-api-client';
|
|
2
|
+
/** Outcome of a CSRF-token refresh attempt, reported back to {@link createUnauthorizedMiddleware}. */
|
|
3
|
+
export type CsrfRefreshOutcome = {
|
|
4
|
+
status: 'ok';
|
|
5
|
+
token: string;
|
|
6
|
+
} | {
|
|
7
|
+
status: 'unauthorized' | 'failed';
|
|
8
|
+
};
|
|
9
|
+
/** An error thrown to indicate the caller is unauthenticated. */
|
|
10
|
+
export interface UnauthorizedErrorLike extends Error {
|
|
11
|
+
readonly status: 401;
|
|
12
|
+
readonly url: string;
|
|
13
|
+
}
|
|
14
|
+
/** Host capabilities {@link createUnauthorizedMiddleware} needs to handle 401s and invalid-CSRF retries. */
|
|
15
|
+
export interface CreateUnauthorizedMiddlewareDeps {
|
|
16
|
+
/** Notifies the host that a request was unauthorized (also expected to clear any held CSRF token). */
|
|
17
|
+
notifyUnauthorized: (url: string) => void;
|
|
18
|
+
/** Attempts to refresh the CSRF token, de-duplicating concurrent calls. */
|
|
19
|
+
refreshCsrfToken: () => Promise<CsrfRefreshOutcome>;
|
|
20
|
+
/** Classifies a response body as an invalid-CSRF error. */
|
|
21
|
+
isInvalidCsrfErrorBody: (body: string) => boolean;
|
|
22
|
+
/** Returns the currently held CSRF token, or `null` when none is set. */
|
|
23
|
+
getCsrfToken: () => string | null;
|
|
24
|
+
/**
|
|
25
|
+
* Stores a CSRF token captured from a response header. Needed here (in
|
|
26
|
+
* addition to the CSRF middleware's own `post` hook) because the
|
|
27
|
+
* invalid-CSRF retry issues its own `fetch` outside the generated-client
|
|
28
|
+
* middleware pipeline, so its response header is never seen by that hook.
|
|
29
|
+
*/
|
|
30
|
+
setCsrfToken: (token: string | null) => void;
|
|
31
|
+
/** Constructs the error thrown to signal an unauthorized request. */
|
|
32
|
+
createUnauthorizedError: (url: string) => UnauthorizedErrorLike;
|
|
33
|
+
}
|
|
34
|
+
/**
|
|
35
|
+
* Builds a generated-client `Middleware` that throws on 401, and on a
|
|
36
|
+
* classified invalid-CSRF 403 refreshes the token and retries the original
|
|
37
|
+
* request exactly once.
|
|
38
|
+
*/
|
|
39
|
+
export declare const createUnauthorizedMiddleware: (deps: CreateUnauthorizedMiddlewareDeps) => Middleware;
|
|
40
|
+
//# sourceMappingURL=create-unauthorized-middleware.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"create-unauthorized-middleware.d.ts","sourceRoot":"","sources":["../../src/api-transport/create-unauthorized-middleware.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,+BAA+B,CAAC;AAIhE,sGAAsG;AACtG,MAAM,MAAM,kBAAkB,GAC5B;IAAE,MAAM,EAAE,IAAI,CAAC;IAAC,KAAK,EAAE,MAAM,CAAA;CAAE,GAAG;IAAE,MAAM,EAAE,cAAc,GAAG,QAAQ,CAAA;CAAE,CAAC;AAE1E,iEAAiE;AACjE,MAAM,WAAW,qBAAsB,SAAQ,KAAK;IAClD,QAAQ,CAAC,MAAM,EAAE,GAAG,CAAC;IACrB,QAAQ,CAAC,GAAG,EAAE,MAAM,CAAC;CACtB;AAED,4GAA4G;AAC5G,MAAM,WAAW,gCAAgC;IAC/C,sGAAsG;IACtG,kBAAkB,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,IAAI,CAAC;IAC1C,2EAA2E;IAC3E,gBAAgB,EAAE,MAAM,OAAO,CAAC,kBAAkB,CAAC,CAAC;IACpD,2DAA2D;IAC3D,sBAAsB,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,OAAO,CAAC;IAClD,yEAAyE;IACzE,YAAY,EAAE,MAAM,MAAM,GAAG,IAAI,CAAC;IAClC;;;;;OAKG;IACH,YAAY,EAAE,CAAC,KAAK,EAAE,MAAM,GAAG,IAAI,KAAK,IAAI,CAAC;IAC7C,qEAAqE;IACrE,uBAAuB,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,qBAAqB,CAAC;CACjE;AAgCD;;;;GAIG;AACH,eAAO,MAAM,4BAA4B,GACvC,MAAM,gCAAgC,KACrC,UAoEF,CAAC"}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import { DisplayAttachment } from '@epam/ai-dial-chat-shared';
|
|
2
|
+
/** Resolves a DIAL Core file id to a downloadable URL. Host-owned — encodes the app's own file-download endpoint. */
|
|
3
|
+
export type ResolveDownloadUrl = (fileId: string) => string | undefined;
|
|
4
|
+
/** Parameters for {@link useAttachmentAction}. */
|
|
5
|
+
export interface UseAttachmentActionParams {
|
|
6
|
+
/** Resolves a DIAL Core file id to a downloadable URL. */
|
|
7
|
+
resolveDownloadUrl: ResolveDownloadUrl;
|
|
8
|
+
}
|
|
9
|
+
/** Return value of {@link useAttachmentAction}. */
|
|
10
|
+
export interface UseAttachmentActionResult {
|
|
11
|
+
/** Default click handler for an attachment tile: download, canvas-preview, or open-in-browser. */
|
|
12
|
+
handleAttachmentClick: (attachment: DisplayAttachment) => void;
|
|
13
|
+
}
|
|
14
|
+
/** Returns true when `downloadAttachment` can trigger a download for `attachment`. */
|
|
15
|
+
export declare const isDownloadableAttachment: (attachment: DisplayAttachment) => boolean;
|
|
16
|
+
/**
|
|
17
|
+
* Downloads an attachment that carries its own content: a DIAL-hosted file
|
|
18
|
+
* (`url` resolves to a DIAL file id) or an inline `data` payload. Returns
|
|
19
|
+
* whether a download was actually triggered, so callers can skip
|
|
20
|
+
* non-downloadable (reference-only) attachments without duplicating the
|
|
21
|
+
* DIAL-file-id / URL-resolution checks.
|
|
22
|
+
*/
|
|
23
|
+
export declare const downloadAttachment: (attachment: DisplayAttachment, resolveDownloadUrl: ResolveDownloadUrl) => boolean;
|
|
24
|
+
/**
|
|
25
|
+
* Default click behavior for a plain attachment tile: downloads DIAL-hosted
|
|
26
|
+
* and inline (`data`) files, and for reference-only attachments (no `url`/`data`,
|
|
27
|
+
* only `referenceUrl` — e.g. RAG/search-grounding chunks), opens a PDF
|
|
28
|
+
* `referenceUrl` in the canvas scrolled to its referenced page when present,
|
|
29
|
+
* otherwise opens/downloads the `referenceUrl` as-is.
|
|
30
|
+
*/
|
|
31
|
+
export declare const useAttachmentAction: ({ resolveDownloadUrl, }: UseAttachmentActionParams) => UseAttachmentActionResult;
|
|
32
|
+
//# sourceMappingURL=useAttachmentAction.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useAttachmentAction.d.ts","sourceRoot":"","sources":["../../../src/attachment/useAttachmentAction/useAttachmentAction.ts"],"names":[],"mappings":"AAKA,OAAO,EAOL,KAAK,iBAAiB,EACvB,MAAM,2BAA2B,CAAC;AAKnC,qHAAqH;AACrH,MAAM,MAAM,kBAAkB,GAAG,CAAC,MAAM,EAAE,MAAM,KAAK,MAAM,GAAG,SAAS,CAAC;AAExE,kDAAkD;AAClD,MAAM,WAAW,yBAAyB;IACxC,0DAA0D;IAC1D,kBAAkB,EAAE,kBAAkB,CAAC;CACxC;AAED,mDAAmD;AACnD,MAAM,WAAW,yBAAyB;IACxC,kGAAkG;IAClG,qBAAqB,EAAE,CAAC,UAAU,EAAE,iBAAiB,KAAK,IAAI,CAAC;CAChE;AAED,sFAAsF;AACtF,eAAO,MAAM,wBAAwB,GACnC,YAAY,iBAAiB,KAC5B,OAEsB,CAAC;AAE1B;;;;;;GAMG;AACH,eAAO,MAAM,kBAAkB,GAC7B,YAAY,iBAAiB,EAC7B,oBAAoB,kBAAkB,KACrC,OA0BF,CAAC;AAsDF;;;;;;GAMG;AACH,eAAO,MAAM,mBAAmB,GAAI,yBAEjC,yBAAyB,KAAG,yBAmC9B,CAAC"}
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
import { AttachmentErrorReason, Attachment } from '@epam/ai-dial-chat-shared';
|
|
2
|
+
/** Reason a rejected attachment failed validation. */
|
|
3
|
+
export declare enum AttachmentValidationErrorReason {
|
|
4
|
+
/** No MIME types are allowed at all — attachments are disabled entirely. */
|
|
5
|
+
NoTypesAllowed = "noTypesAllowed",
|
|
6
|
+
/** The attachment's content type is not among the allowed MIME types. */
|
|
7
|
+
UnsupportedType = "unsupportedType",
|
|
8
|
+
/** The attachment's file size exceeds `maxFileSizeBytes`. */
|
|
9
|
+
FileTooLarge = "fileTooLarge"
|
|
10
|
+
}
|
|
11
|
+
/** Structured, translation-free report of a rejected attachment, emitted at most once per debounce window. */
|
|
12
|
+
export interface AttachmentValidationErrorEvent {
|
|
13
|
+
/** Why the attachment(s) were rejected. */
|
|
14
|
+
reason: AttachmentValidationErrorReason;
|
|
15
|
+
/** The resolved MIME types the caller currently allows (possibly empty). Present only when `reason` is `NoTypesAllowed` or `UnsupportedType`. */
|
|
16
|
+
allowedMimeTypes?: string[];
|
|
17
|
+
/** Already-formatted, non-translated extension list (e.g. ".png, .jpg"), present only when `reason` is `UnsupportedType`. */
|
|
18
|
+
formats?: string;
|
|
19
|
+
/** The size limit, in bytes, that was exceeded. Present only when `reason` is `FileTooLarge`. */
|
|
20
|
+
maxFileSizeBytes?: number;
|
|
21
|
+
}
|
|
22
|
+
/** Parameters for {@link useAttachmentValidation}. */
|
|
23
|
+
export interface UseAttachmentValidationParams {
|
|
24
|
+
/** Resolved MIME types currently allowed for attachments. */
|
|
25
|
+
allowedMimeTypes: string[];
|
|
26
|
+
/** Maximum attachment file size, in bytes. When omitted, no file is rejected for size. */
|
|
27
|
+
maxFileSizeBytes?: number;
|
|
28
|
+
/** Called with a structured event when a rejected attachment is reported, at most once per debounce window. */
|
|
29
|
+
onValidationError?: (event: AttachmentValidationErrorEvent) => void;
|
|
30
|
+
/** Debounce window, in ms, before firing `onValidationError` for a rejected file. Defaults to `100`. */
|
|
31
|
+
debounceMs?: number;
|
|
32
|
+
}
|
|
33
|
+
/** Return value of {@link useAttachmentValidation}. */
|
|
34
|
+
export interface UseAttachmentValidationResult {
|
|
35
|
+
/** The resolved MIME types currently allowed for attachments (echoes the `allowedMimeTypes` param). */
|
|
36
|
+
inputAttachmentTypes: string[];
|
|
37
|
+
/** Whether at least one MIME type is currently allowed. */
|
|
38
|
+
isAttachmentsAllowed: boolean;
|
|
39
|
+
/** Classifies an attachment as allowed (`undefined`) or rejected (`AttachmentErrorReason`). */
|
|
40
|
+
validateAttachment: (attachment: Attachment) => AttachmentErrorReason | undefined;
|
|
41
|
+
/** `<input accept>` string derived from `allowedMimeTypes`, or `undefined` when any type accepts everything. */
|
|
42
|
+
fileAccept: string | undefined;
|
|
43
|
+
}
|
|
44
|
+
/**
|
|
45
|
+
* Validates an attachment's content type against a resolved list of allowed
|
|
46
|
+
* MIME types, debouncing a burst of rejected files into a single
|
|
47
|
+
* `onValidationError` call rather than firing one per file.
|
|
48
|
+
*/
|
|
49
|
+
export declare const useAttachmentValidation: ({ allowedMimeTypes, maxFileSizeBytes, onValidationError, debounceMs, }: UseAttachmentValidationParams) => UseAttachmentValidationResult;
|
|
50
|
+
//# sourceMappingURL=useAttachmentValidation.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useAttachmentValidation.d.ts","sourceRoot":"","sources":["../../../src/attachment/useAttachmentValidation/useAttachmentValidation.ts"],"names":[],"mappings":"AAIA,OAAO,EACL,qBAAqB,EACrB,KAAK,UAAU,EAChB,MAAM,2BAA2B,CAAC;AAMnC,sDAAsD;AACtD,oBAAY,+BAA+B;IACzC,4EAA4E;IAC5E,cAAc,mBAAmB;IACjC,yEAAyE;IACzE,eAAe,oBAAoB;IACnC,6DAA6D;IAC7D,YAAY,iBAAiB;CAC9B;AAED,8GAA8G;AAC9G,MAAM,WAAW,8BAA8B;IAC7C,2CAA2C;IAC3C,MAAM,EAAE,+BAA+B,CAAC;IACxC,iJAAiJ;IACjJ,gBAAgB,CAAC,EAAE,MAAM,EAAE,CAAC;IAC5B,6HAA6H;IAC7H,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,iGAAiG;IACjG,gBAAgB,CAAC,EAAE,MAAM,CAAC;CAC3B;AAED,sDAAsD;AACtD,MAAM,WAAW,6BAA6B;IAC5C,6DAA6D;IAC7D,gBAAgB,EAAE,MAAM,EAAE,CAAC;IAC3B,0FAA0F;IAC1F,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAC1B,+GAA+G;IAC/G,iBAAiB,CAAC,EAAE,CAAC,KAAK,EAAE,8BAA8B,KAAK,IAAI,CAAC;IACpE,wGAAwG;IACxG,UAAU,CAAC,EAAE,MAAM,CAAC;CACrB;AAED,uDAAuD;AACvD,MAAM,WAAW,6BAA6B;IAC5C,uGAAuG;IACvG,oBAAoB,EAAE,MAAM,EAAE,CAAC;IAC/B,2DAA2D;IAC3D,oBAAoB,EAAE,OAAO,CAAC;IAC9B,+FAA+F;IAC/F,kBAAkB,EAAE,CAClB,UAAU,EAAE,UAAU,KACnB,qBAAqB,GAAG,SAAS,CAAC;IACvC,gHAAgH;IAChH,UAAU,EAAE,MAAM,GAAG,SAAS,CAAC;CAChC;AAED;;;;GAIG;AACH,eAAO,MAAM,uBAAuB,GAAI,wEAKrC,6BAA6B,KAAG,6BAwFlC,CAAC"}
|
package/attachments.d.ts
CHANGED
|
@@ -1,94 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
import { DisplayAttachment } from '@epam/ai-dial-chat-shared';
|
|
4
|
-
|
|
5
|
-
/** Structured, translation-free report of a rejected attachment, emitted at most once per debounce window. */
|
|
6
|
-
export declare interface AttachmentValidationErrorEvent {
|
|
7
|
-
/** Why the attachment(s) were rejected. */
|
|
8
|
-
reason: AttachmentValidationErrorReason;
|
|
9
|
-
/** The resolved MIME types the caller currently allows (possibly empty). Present only when `reason` is `NoTypesAllowed` or `UnsupportedType`. */
|
|
10
|
-
allowedMimeTypes?: string[];
|
|
11
|
-
/** Already-formatted, non-translated extension list (e.g. ".png, .jpg"), present only when `reason` is `UnsupportedType`. */
|
|
12
|
-
formats?: string;
|
|
13
|
-
/** The size limit, in bytes, that was exceeded. Present only when `reason` is `FileTooLarge`. */
|
|
14
|
-
maxFileSizeBytes?: number;
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
/** Reason a rejected attachment failed validation. */
|
|
18
|
-
export declare enum AttachmentValidationErrorReason {
|
|
19
|
-
/** No MIME types are allowed at all — attachments are disabled entirely. */
|
|
20
|
-
NoTypesAllowed = "noTypesAllowed",
|
|
21
|
-
/** The attachment's content type is not among the allowed MIME types. */
|
|
22
|
-
UnsupportedType = "unsupportedType",
|
|
23
|
-
/** The attachment's file size exceeds `maxFileSizeBytes`. */
|
|
24
|
-
FileTooLarge = "fileTooLarge"
|
|
25
|
-
}
|
|
26
|
-
|
|
27
|
-
/**
|
|
28
|
-
* Downloads an attachment that carries its own content: a DIAL-hosted file
|
|
29
|
-
* (`url` resolves to a DIAL file id) or an inline `data` payload. Returns
|
|
30
|
-
* whether a download was actually triggered, so callers can skip
|
|
31
|
-
* non-downloadable (reference-only) attachments without duplicating the
|
|
32
|
-
* DIAL-file-id / URL-resolution checks.
|
|
33
|
-
*/
|
|
34
|
-
export declare const downloadAttachment: (attachment: DisplayAttachment, resolveDownloadUrl: ResolveDownloadUrl) => boolean;
|
|
35
|
-
|
|
36
|
-
/** Returns true when `downloadAttachment` can trigger a download for `attachment`. */
|
|
37
|
-
export declare const isDownloadableAttachment: (attachment: DisplayAttachment) => boolean;
|
|
38
|
-
|
|
39
|
-
/** Resolves a DIAL Core file id to a downloadable URL. Host-owned — encodes the app's own file-download endpoint. */
|
|
40
|
-
export declare type ResolveDownloadUrl = (fileId: string) => string | undefined;
|
|
41
|
-
|
|
42
|
-
/**
|
|
43
|
-
* Default click behavior for a plain attachment tile: downloads DIAL-hosted
|
|
44
|
-
* and inline (`data`) files, and for reference-only attachments (no `url`/`data`,
|
|
45
|
-
* only `referenceUrl` — e.g. RAG/search-grounding chunks), opens a PDF
|
|
46
|
-
* `referenceUrl` in the canvas scrolled to its referenced page when present,
|
|
47
|
-
* otherwise opens/downloads the `referenceUrl` as-is.
|
|
48
|
-
*/
|
|
49
|
-
export declare const useAttachmentAction: ({ resolveDownloadUrl, }: UseAttachmentActionParams) => UseAttachmentActionResult;
|
|
50
|
-
|
|
51
|
-
/** Parameters for {@link useAttachmentAction}. */
|
|
52
|
-
export declare interface UseAttachmentActionParams {
|
|
53
|
-
/** Resolves a DIAL Core file id to a downloadable URL. */
|
|
54
|
-
resolveDownloadUrl: ResolveDownloadUrl;
|
|
55
|
-
}
|
|
56
|
-
|
|
57
|
-
/** Return value of {@link useAttachmentAction}. */
|
|
58
|
-
export declare interface UseAttachmentActionResult {
|
|
59
|
-
/** Default click handler for an attachment tile: download, canvas-preview, or open-in-browser. */
|
|
60
|
-
handleAttachmentClick: (attachment: DisplayAttachment) => void;
|
|
61
|
-
}
|
|
62
|
-
|
|
63
|
-
/**
|
|
64
|
-
* Validates an attachment's content type against a resolved list of allowed
|
|
65
|
-
* MIME types, debouncing a burst of rejected files into a single
|
|
66
|
-
* `onValidationError` call rather than firing one per file.
|
|
67
|
-
*/
|
|
68
|
-
export declare const useAttachmentValidation: ({ allowedMimeTypes, maxFileSizeBytes, onValidationError, debounceMs, }: UseAttachmentValidationParams) => UseAttachmentValidationResult;
|
|
69
|
-
|
|
70
|
-
/** Parameters for {@link useAttachmentValidation}. */
|
|
71
|
-
export declare interface UseAttachmentValidationParams {
|
|
72
|
-
/** Resolved MIME types currently allowed for attachments. */
|
|
73
|
-
allowedMimeTypes: string[];
|
|
74
|
-
/** Maximum attachment file size, in bytes. When omitted, no file is rejected for size. */
|
|
75
|
-
maxFileSizeBytes?: number;
|
|
76
|
-
/** Called with a structured event when a rejected attachment is reported, at most once per debounce window. */
|
|
77
|
-
onValidationError?: (event: AttachmentValidationErrorEvent) => void;
|
|
78
|
-
/** Debounce window, in ms, before firing `onValidationError` for a rejected file. Defaults to `100`. */
|
|
79
|
-
debounceMs?: number;
|
|
80
|
-
}
|
|
81
|
-
|
|
82
|
-
/** Return value of {@link useAttachmentValidation}. */
|
|
83
|
-
export declare interface UseAttachmentValidationResult {
|
|
84
|
-
/** The resolved MIME types currently allowed for attachments (echoes the `allowedMimeTypes` param). */
|
|
85
|
-
inputAttachmentTypes: string[];
|
|
86
|
-
/** Whether at least one MIME type is currently allowed. */
|
|
87
|
-
isAttachmentsAllowed: boolean;
|
|
88
|
-
/** Classifies an attachment as allowed (`undefined`) or rejected (`AttachmentErrorReason`). */
|
|
89
|
-
validateAttachment: (attachment: Attachment) => AttachmentErrorReason | undefined;
|
|
90
|
-
/** `<input accept>` string derived from `allowedMimeTypes`, or `undefined` when any type accepts everything. */
|
|
91
|
-
fileAccept: string | undefined;
|
|
92
|
-
}
|
|
93
|
-
|
|
94
|
-
export { }
|
|
1
|
+
export * from './entry-points/attachments.js'
|
|
2
|
+
export {}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { CatalogItem } from '@epam/ai-dial-catalog';
|
|
2
|
+
import { CatalogEntityType } from '@epam/ai-dial-chat-shared';
|
|
3
|
+
/**
|
|
4
|
+
* Filters catalog items to those whose type is in `visibleTypes`.
|
|
5
|
+
* Call only when selector mode is active; otherwise pass through the original array.
|
|
6
|
+
*/
|
|
7
|
+
export declare const filterCatalogItemsBySelector: (items: readonly CatalogItem[], visibleTypes: ReadonlySet<CatalogEntityType>) => CatalogItem[];
|
|
8
|
+
/**
|
|
9
|
+
* Filters out items owned by the current user when `hideOwned` is true.
|
|
10
|
+
* Always returns a new array so callers may safely assign to mutable collections.
|
|
11
|
+
*/
|
|
12
|
+
export declare const filterHiddenOwnedItems: (items: readonly CatalogItem[], hideOwned: boolean) => CatalogItem[];
|
|
13
|
+
/**
|
|
14
|
+
* Returns items marked as a user favorite that are not hidden, in original order.
|
|
15
|
+
*/
|
|
16
|
+
export declare const deriveFavoriteItems: (items: readonly CatalogItem[]) => CatalogItem[];
|
|
17
|
+
/**
|
|
18
|
+
* Returns the subset of `tabOrder` entries whose entity type is present in
|
|
19
|
+
* `items`, preserving tab order.
|
|
20
|
+
*/
|
|
21
|
+
export declare const deriveAvailableTabIds: <T extends CatalogEntityType>(items: readonly CatalogItem[], tabOrder: readonly T[]) => T[];
|
|
22
|
+
/**
|
|
23
|
+
* Returns the intersection of `persistedTopics` with topics that appear in
|
|
24
|
+
* `items`. Returns a new Set and never mutates either input.
|
|
25
|
+
*/
|
|
26
|
+
export declare const reconcileFilterTopics: (persistedTopics: ReadonlySet<string>, items: readonly CatalogItem[]) => Set<string>;
|
|
27
|
+
//# sourceMappingURL=catalog-derivations.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"catalog-derivations.d.ts","sourceRoot":"","sources":["../../src/catalog/catalog-derivations.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;AACzD,OAAO,EAAE,iBAAiB,EAAE,MAAM,2BAA2B,CAAC;AAE9D;;;GAGG;AACH,eAAO,MAAM,4BAA4B,GACvC,OAAO,SAAS,WAAW,EAAE,EAC7B,cAAc,WAAW,CAAC,iBAAiB,CAAC,KAC3C,WAAW,EAAyD,CAAC;AAExE;;;GAGG;AACH,eAAO,MAAM,sBAAsB,GACjC,OAAO,SAAS,WAAW,EAAE,EAC7B,WAAW,OAAO,KACjB,WAAW,EACkD,CAAC;AAEjE;;GAEG;AACH,eAAO,MAAM,mBAAmB,GAC9B,OAAO,SAAS,WAAW,EAAE,KAC5B,WAAW,EACiD,CAAC;AAEhE;;;GAGG;AACH,eAAO,MAAM,qBAAqB,GAAI,CAAC,SAAS,iBAAiB,EAC/D,OAAO,SAAS,WAAW,EAAE,EAC7B,UAAU,SAAS,CAAC,EAAE,KACrB,CAAC,EAGH,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,qBAAqB,GAChC,iBAAiB,WAAW,CAAC,MAAM,CAAC,EACpC,OAAO,SAAS,WAAW,EAAE,KAC5B,GAAG,CAAC,MAAM,CAKZ,CAAC"}
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import { CatalogItem } from '@epam/ai-dial-catalog';
|
|
2
|
+
import { PromptResponseDto } from '@epam/ai-dial-chat-api-client';
|
|
3
|
+
/** Discriminant for primary-action result variants. */
|
|
4
|
+
export declare enum CatalogPrimaryActionType {
|
|
5
|
+
Deployment = "deployment",
|
|
6
|
+
Prompt = "prompt"
|
|
7
|
+
}
|
|
8
|
+
/** Primary action resolved for a deployment (model, agent, toolset, or skill). */
|
|
9
|
+
export interface CatalogPrimaryActionDeployment {
|
|
10
|
+
/** Discriminant. */
|
|
11
|
+
kind: CatalogPrimaryActionType.Deployment;
|
|
12
|
+
/** Deployment entity id. */
|
|
13
|
+
id: string;
|
|
14
|
+
}
|
|
15
|
+
/** Primary action resolved for a prompt. */
|
|
16
|
+
export interface CatalogPrimaryActionPrompt {
|
|
17
|
+
/** Discriminant. */
|
|
18
|
+
kind: CatalogPrimaryActionType.Prompt;
|
|
19
|
+
/** Prompt entity id. */
|
|
20
|
+
id: string;
|
|
21
|
+
/** Display name of the prompt. */
|
|
22
|
+
name: string;
|
|
23
|
+
/** Short description of the prompt. */
|
|
24
|
+
description: string;
|
|
25
|
+
/** Resolved prompt body (seeded from details or fetched). */
|
|
26
|
+
content: string;
|
|
27
|
+
/** Whether the prompt body contains at least one `{{parameter}}` placeholder. */
|
|
28
|
+
hasParameters: boolean;
|
|
29
|
+
}
|
|
30
|
+
/** Discriminated union of catalog primary-action results. */
|
|
31
|
+
export type CatalogPrimaryActionResult = CatalogPrimaryActionDeployment | CatalogPrimaryActionPrompt;
|
|
32
|
+
/**
|
|
33
|
+
* Resolves the primary action for a catalog item.
|
|
34
|
+
*
|
|
35
|
+
* For prompts: prefers already-seeded content from `item.details`; otherwise
|
|
36
|
+
* calls `fetchPrompt` once to retrieve the body. Sets `hasParameters` based on
|
|
37
|
+
* whether the content contains prompt-parameter placeholders.
|
|
38
|
+
*
|
|
39
|
+
* For all other entity types: returns a deployment result with the item id.
|
|
40
|
+
*
|
|
41
|
+
* The function does not navigate, select a deployment, show notifications, or
|
|
42
|
+
* import route constants — those remain the caller's responsibility.
|
|
43
|
+
*
|
|
44
|
+
* @throws When `fetchPrompt` rejects (propagated to the caller without wrapping).
|
|
45
|
+
*/
|
|
46
|
+
export declare const resolveCatalogPrimaryAction: (item: CatalogItem, fetchPrompt: (item: CatalogItem) => Promise<PromptResponseDto>) => Promise<CatalogPrimaryActionResult>;
|
|
47
|
+
//# sourceMappingURL=catalog-primary-action.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"catalog-primary-action.d.ts","sourceRoot":"","sources":["../../src/catalog/catalog-primary-action.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;AACzD,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,+BAA+B,CAAC;AAMvE,uDAAuD;AACvD,oBAAY,wBAAwB;IAClC,UAAU,eAAe;IACzB,MAAM,WAAW;CAClB;AAED,kFAAkF;AAClF,MAAM,WAAW,8BAA8B;IAC7C,oBAAoB;IACpB,IAAI,EAAE,wBAAwB,CAAC,UAAU,CAAC;IAC1C,4BAA4B;IAC5B,EAAE,EAAE,MAAM,CAAC;CACZ;AAED,4CAA4C;AAC5C,MAAM,WAAW,0BAA0B;IACzC,oBAAoB;IACpB,IAAI,EAAE,wBAAwB,CAAC,MAAM,CAAC;IACtC,wBAAwB;IACxB,EAAE,EAAE,MAAM,CAAC;IACX,kCAAkC;IAClC,IAAI,EAAE,MAAM,CAAC;IACb,uCAAuC;IACvC,WAAW,EAAE,MAAM,CAAC;IACpB,6DAA6D;IAC7D,OAAO,EAAE,MAAM,CAAC;IAChB,iFAAiF;IACjF,aAAa,EAAE,OAAO,CAAC;CACxB;AAED,6DAA6D;AAC7D,MAAM,MAAM,0BAA0B,GACpC,8BAA8B,GAAG,0BAA0B,CAAC;AAE9D;;;;;;;;;;;;;GAaG;AACH,eAAO,MAAM,2BAA2B,GACtC,MAAM,WAAW,EACjB,aAAa,CAAC,IAAI,EAAE,WAAW,KAAK,OAAO,CAAC,iBAAiB,CAAC,KAC7D,OAAO,CAAC,0BAA0B,CAmBpC,CAAC"}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import { PublishApi, PublishCatalogEntityDto, PublishHistoryEntryDto, PublishResultDto, PublishRuleDto, UnpublishCatalogEntityDto, UnpublishResultDto } from '@epam/ai-dial-chat-api-client';
|
|
2
|
+
import { PublicationRule } from '@epam/ai-dial-publish-panel';
|
|
3
|
+
import { CatalogPublishEntityType } from './publish';
|
|
4
|
+
/**
|
|
5
|
+
* Converts a `PublicationRule` (publish-panel lib model) to the generated
|
|
6
|
+
* client's `PublishRuleDto` shape. The two differ only in how the comparison
|
|
7
|
+
* function is typed, so the value passes through unchanged.
|
|
8
|
+
*/
|
|
9
|
+
export declare const toPublishRuleDto: (rule: PublicationRule) => PublishRuleDto;
|
|
10
|
+
/** The DIAL publish API surface produced by {@link createPublishApiClient}. */
|
|
11
|
+
export interface PublishApiClient {
|
|
12
|
+
/** Submits a publication request for one catalog entity into `folderPath`. */
|
|
13
|
+
publishCatalogEntity: (entityType: CatalogPublishEntityType, entityId: string, body: PublishCatalogEntityDto) => Promise<PublishResultDto>;
|
|
14
|
+
/**
|
|
15
|
+
* Submits a removal request for one already-published folder of a catalog
|
|
16
|
+
* entity. The removal takes effect only after an administrator approves it,
|
|
17
|
+
* so callers must report a pending request rather than a completed removal.
|
|
18
|
+
*/
|
|
19
|
+
unpublishCatalogEntity: (entityType: CatalogPublishEntityType, entityId: string, body: UnpublishCatalogEntityDto) => Promise<UnpublishResultDto>;
|
|
20
|
+
/** Reads the folders one catalog entity is already published to. */
|
|
21
|
+
getCatalogPublishHistory: (entityType: CatalogPublishEntityType, entityId: string) => Promise<PublishHistoryEntryDto[]>;
|
|
22
|
+
/** Reads a destination folder's already-configured access rules. */
|
|
23
|
+
getPublishRules: (folderPath: string) => Promise<PublicationRule[]>;
|
|
24
|
+
}
|
|
25
|
+
/**
|
|
26
|
+
* Wraps the generated `PublishApi` in the positional-argument surface the
|
|
27
|
+
* catalog and conversation publish flows call, so each host app re-exports one
|
|
28
|
+
* client instead of re-declaring the same four wrappers. Mirrors
|
|
29
|
+
* {@link createFilesApiClient}.
|
|
30
|
+
*/
|
|
31
|
+
export declare const createPublishApiClient: (publishApi: PublishApi) => PublishApiClient;
|
|
32
|
+
//# sourceMappingURL=create-publish-api.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"create-publish-api.d.ts","sourceRoot":"","sources":["../../src/catalog/create-publish-api.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,UAAU,EACV,uBAAuB,EACvB,sBAAsB,EACtB,gBAAgB,EAChB,cAAc,EACd,yBAAyB,EACzB,kBAAkB,EACnB,MAAM,+BAA+B,CAAC;AACvC,OAAO,KAAK,EACV,eAAe,EAEhB,MAAM,6BAA6B,CAAC;AACrC,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,WAAW,CAAC;AAE1D;;;;GAIG;AACH,eAAO,MAAM,gBAAgB,GAAI,MAAM,eAAe,KAAG,cAIvD,CAAC;AAEH,+EAA+E;AAC/E,MAAM,WAAW,gBAAgB;IAC/B,8EAA8E;IAC9E,oBAAoB,EAAE,CACpB,UAAU,EAAE,wBAAwB,EACpC,QAAQ,EAAE,MAAM,EAChB,IAAI,EAAE,uBAAuB,KAC1B,OAAO,CAAC,gBAAgB,CAAC,CAAC;IAC/B;;;;OAIG;IACH,sBAAsB,EAAE,CACtB,UAAU,EAAE,wBAAwB,EACpC,QAAQ,EAAE,MAAM,EAChB,IAAI,EAAE,yBAAyB,KAC5B,OAAO,CAAC,kBAAkB,CAAC,CAAC;IACjC,oEAAoE;IACpE,wBAAwB,EAAE,CACxB,UAAU,EAAE,wBAAwB,EACpC,QAAQ,EAAE,MAAM,KACb,OAAO,CAAC,sBAAsB,EAAE,CAAC,CAAC;IACvC,oEAAoE;IACpE,eAAe,EAAE,CAAC,UAAU,EAAE,MAAM,KAAK,OAAO,CAAC,eAAe,EAAE,CAAC,CAAC;CACrE;AAED;;;;;GAKG;AACH,eAAO,MAAM,sBAAsB,GACjC,YAAY,UAAU,KACrB,gBAsBD,CAAC"}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { CatalogItemApiDetails } from '@epam/ai-dial-catalog';
|
|
2
|
+
/** Builds the OpenAI-compatible Chat Completions endpoint URL for a deployment. */
|
|
3
|
+
export declare const buildChatCompletionsUrl: (baseUrl: string, id: string) => string;
|
|
4
|
+
/** Builds the Responses API endpoint URL for a deployment. */
|
|
5
|
+
export declare const buildResponsesUrl: (baseUrl: string) => string;
|
|
6
|
+
/** Which generation APIs a deployment reports supporting. */
|
|
7
|
+
export interface DeploymentGenerationApiSupport {
|
|
8
|
+
hasChatCompletion?: boolean;
|
|
9
|
+
hasResponsesApi?: boolean;
|
|
10
|
+
}
|
|
11
|
+
/**
|
|
12
|
+
* Builds the "Connect" tab's endpoint list for a model or application
|
|
13
|
+
* deployment: the OpenAI-compatible Chat Completions endpoint and/or the
|
|
14
|
+
* Responses API endpoint, each included only when the deployment reports
|
|
15
|
+
* supporting it. DIAL Core routes both APIs the same way for models and
|
|
16
|
+
* custom applications, keyed by the deployment id.
|
|
17
|
+
*/
|
|
18
|
+
export declare const buildDeploymentConnectApi: (baseUrl: string, id: string, { hasChatCompletion, hasResponsesApi }: DeploymentGenerationApiSupport) => CatalogItemApiDetails | undefined;
|
|
19
|
+
//# sourceMappingURL=deployment-endpoint-url.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"deployment-endpoint-url.d.ts","sourceRoot":"","sources":["../../src/catalog/deployment-endpoint-url.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,qBAAqB,EAEtB,MAAM,uBAAuB,CAAC;AAuB/B,mFAAmF;AACnF,eAAO,MAAM,uBAAuB,GAAI,SAAS,MAAM,EAAE,IAAI,MAAM,KAAG,MAC2B,CAAC;AAElG,8DAA8D;AAC9D,eAAO,MAAM,iBAAiB,GAAI,SAAS,MAAM,KAAG,MACC,CAAC;AAEtD,6DAA6D;AAC7D,MAAM,WAAW,8BAA8B;IAC7C,iBAAiB,CAAC,EAAE,OAAO,CAAC;IAC5B,eAAe,CAAC,EAAE,OAAO,CAAC;CAC3B;AAED;;;;;;GAMG;AACH,eAAO,MAAM,yBAAyB,GACpC,SAAS,MAAM,EACf,IAAI,MAAM,EACV,wCAAwC,8BAA8B,KACrE,qBAAqB,GAAG,SAqC1B,CAAC"}
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
import { DeploymentItemDto } from '@epam/ai-dial-chat-api-client';
|
|
2
|
+
/**
|
|
3
|
+
* Percent-encodes each `/`-separated segment of a deployment/application id
|
|
4
|
+
* so it satisfies the backend's `DEPLOYMENT_ID_PATTERN` (spaces and other
|
|
5
|
+
* reserved characters must be percent-encoded; `/` stays a literal path
|
|
6
|
+
* separator). Applications created via `POST /api/v1/applications` return an
|
|
7
|
+
* id built from the raw, human-readable name (e.g. `applications/<bucket>/My
|
|
8
|
+
* App__1.0`), which is only ever consumed by the settings iframe's postMessage
|
|
9
|
+
* protocol elsewhere — anywhere that id is used as a chat `deploymentId`, it
|
|
10
|
+
* must be encoded first.
|
|
11
|
+
*/
|
|
12
|
+
export declare const encodeDeploymentId: (id: string) => string;
|
|
13
|
+
/**
|
|
14
|
+
* Inverse of `encodeDeploymentId` — decodes each `/`-separated segment back
|
|
15
|
+
* to its raw, human-readable form. A segment that isn't valid
|
|
16
|
+
* percent-encoding is passed through unchanged rather than throwing, since
|
|
17
|
+
* this decodes externally-sourced ids (the settings iframe's postMessage
|
|
18
|
+
* protocol).
|
|
19
|
+
*/
|
|
20
|
+
export declare const decodeDeploymentId: (id: string) => string;
|
|
21
|
+
/**
|
|
22
|
+
* Encodes a deployment/application id to its single-encoded form regardless
|
|
23
|
+
* of whether the value it received was already percent-encoded or the raw,
|
|
24
|
+
* human-readable form — decoding first then re-encoding once is idempotent
|
|
25
|
+
* either way, since `decodeDeploymentId` on a raw (unencoded) id is a no-op.
|
|
26
|
+
* Use this instead of `encodeDeploymentId` at a boundary that cannot
|
|
27
|
+
* guarantee which form it receives, such as a `postMessage` payload from the
|
|
28
|
+
* settings iframe: calling `encodeDeploymentId` directly on a value the
|
|
29
|
+
* sender already encoded escapes the existing `%` characters a second time
|
|
30
|
+
* (`%20` becomes `%2520`), which the backend only ever undoes once and so
|
|
31
|
+
* 404s on.
|
|
32
|
+
*/
|
|
33
|
+
export declare const normalizeDeploymentId: (id: string) => string;
|
|
34
|
+
/**
|
|
35
|
+
* Finds a deployment matching `idOrReference` by `id` first, falling back to
|
|
36
|
+
* `reference` when no `id` matches. DIAL Core sometimes addresses a
|
|
37
|
+
* deployment by `reference` in places that store a deployment id (e.g. a
|
|
38
|
+
* conversation's or message's `model.id`), so lookups against the fetched
|
|
39
|
+
* deployments list must accept either value.
|
|
40
|
+
*/
|
|
41
|
+
export declare const findDeploymentByIdOrReference: (deployments: DeploymentItemDto[], idOrReference: string | null | undefined) => DeploymentItemDto | undefined;
|
|
42
|
+
//# sourceMappingURL=deployment-id.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"deployment-id.d.ts","sourceRoot":"","sources":["../../src/catalog/deployment-id.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,+BAA+B,CAAC;AAEvE;;;;;;;;;GASG;AACH,eAAO,MAAM,kBAAkB,GAAI,IAAI,MAAM,KAAG,MAIlC,CAAC;AAEf;;;;;;GAMG;AACH,eAAO,MAAM,kBAAkB,GAAI,IAAI,MAAM,KAAG,MAUlC,CAAC;AAEf;;;;;;;;;;;GAWG;AACH,eAAO,MAAM,qBAAqB,GAAI,IAAI,MAAM,KAAG,MACP,CAAC;AAE7C;;;;;;GAMG;AACH,eAAO,MAAM,6BAA6B,GACxC,aAAa,iBAAiB,EAAE,EAChC,eAAe,MAAM,GAAG,IAAI,GAAG,SAAS,KACvC,iBAAiB,GAAG,SAMtB,CAAC"}
|
|
@@ -0,0 +1,146 @@
|
|
|
1
|
+
/** Toolset authentication mechanism as reported by DIAL Core. */
|
|
2
|
+
export declare enum AuthenticationType {
|
|
3
|
+
None = "NONE",
|
|
4
|
+
ApiKey = "API_KEY",
|
|
5
|
+
OAuth = "OAUTH"
|
|
6
|
+
}
|
|
7
|
+
/** Feature-support flags for a model deployment. */
|
|
8
|
+
export interface ModelCapabilities {
|
|
9
|
+
hasTools?: boolean;
|
|
10
|
+
hasMcp?: boolean;
|
|
11
|
+
hasCaching?: boolean;
|
|
12
|
+
hasParallelToolCalls?: boolean;
|
|
13
|
+
hasUrlAttachments?: boolean;
|
|
14
|
+
hasFolderAttachments?: boolean;
|
|
15
|
+
hasSeed?: boolean;
|
|
16
|
+
hasSystemPrompt?: boolean;
|
|
17
|
+
hasResume?: boolean;
|
|
18
|
+
hasChatCompletion?: boolean;
|
|
19
|
+
hasResponsesApi?: boolean;
|
|
20
|
+
hasSkills?: boolean;
|
|
21
|
+
reasoningEfforts?: string[];
|
|
22
|
+
}
|
|
23
|
+
/** Catalog-facing specification fields for a model deployment. */
|
|
24
|
+
export interface ModelSpecification {
|
|
25
|
+
provider?: string;
|
|
26
|
+
vendor?: string;
|
|
27
|
+
license?: string;
|
|
28
|
+
knowledgeCutoffDate?: string;
|
|
29
|
+
parameters?: string;
|
|
30
|
+
contextWindowTokens?: number;
|
|
31
|
+
maxOutputTokens?: number;
|
|
32
|
+
inputTypes?: string[];
|
|
33
|
+
hostedBy?: string;
|
|
34
|
+
createdAt?: number;
|
|
35
|
+
}
|
|
36
|
+
/** One priced unit for a model deployment. */
|
|
37
|
+
export interface ModelPriceRow {
|
|
38
|
+
/** DIAL Core pricing key, e.g. `prompt`, `completion`, `cache_read`. */
|
|
39
|
+
key: string;
|
|
40
|
+
/** Per-unit price formatted for display, e.g. `$3/M tokens`. */
|
|
41
|
+
price: string;
|
|
42
|
+
}
|
|
43
|
+
/** A model deployment's full price list. */
|
|
44
|
+
export interface ModelPricing {
|
|
45
|
+
/** Every price DIAL Core reports for the deployment, `unit` excluded. */
|
|
46
|
+
prices?: ModelPriceRow[];
|
|
47
|
+
/** DIAL Core billing unit the prices are quoted in, e.g. `token` or `char_without_whitespace`; absent means tokens. */
|
|
48
|
+
unit?: string;
|
|
49
|
+
}
|
|
50
|
+
/** API-resource identifiers for a model deployment. */
|
|
51
|
+
export interface ModelApiDetails {
|
|
52
|
+
modelId?: string;
|
|
53
|
+
}
|
|
54
|
+
/** Full details payload for a model-type deployment. */
|
|
55
|
+
export interface ModelEntityDetails {
|
|
56
|
+
capabilities?: ModelCapabilities;
|
|
57
|
+
specification?: ModelSpecification;
|
|
58
|
+
pricing?: ModelPricing;
|
|
59
|
+
api?: ModelApiDetails;
|
|
60
|
+
}
|
|
61
|
+
/** Catalog-facing specification fields for an agent (application) deployment. */
|
|
62
|
+
export interface AgentSpecification {
|
|
63
|
+
provider?: string;
|
|
64
|
+
vendor?: string;
|
|
65
|
+
license?: string;
|
|
66
|
+
knowledgeCutoffDate?: string;
|
|
67
|
+
parameters?: string;
|
|
68
|
+
hostedBy?: string;
|
|
69
|
+
createdAt?: number;
|
|
70
|
+
routes?: string[];
|
|
71
|
+
}
|
|
72
|
+
/** Feature-support flags for an agent (application) deployment. */
|
|
73
|
+
export interface AgentCapabilities {
|
|
74
|
+
hasTools?: boolean;
|
|
75
|
+
hasMcp?: boolean;
|
|
76
|
+
hasCaching?: boolean;
|
|
77
|
+
hasParallelToolCalls?: boolean;
|
|
78
|
+
hasUrlAttachments?: boolean;
|
|
79
|
+
hasFolderAttachments?: boolean;
|
|
80
|
+
hasSeed?: boolean;
|
|
81
|
+
hasSystemPrompt?: boolean;
|
|
82
|
+
hasResume?: boolean;
|
|
83
|
+
hasConfiguration?: boolean;
|
|
84
|
+
hasChatCompletion?: boolean;
|
|
85
|
+
hasResponsesApi?: boolean;
|
|
86
|
+
hasSkills?: boolean;
|
|
87
|
+
}
|
|
88
|
+
/** Input-attachment configuration for an agent (application) deployment. */
|
|
89
|
+
export interface AgentConfiguration {
|
|
90
|
+
inputAttachmentTypes?: string[];
|
|
91
|
+
}
|
|
92
|
+
/** Full details payload for an agent (application)-type deployment. */
|
|
93
|
+
export interface AgentEntityDetails {
|
|
94
|
+
specification?: AgentSpecification;
|
|
95
|
+
configuration?: AgentConfiguration;
|
|
96
|
+
capabilities?: AgentCapabilities;
|
|
97
|
+
}
|
|
98
|
+
/** Sign-in status at both the personal and org-wide (global) level for a toolset. */
|
|
99
|
+
export interface ToolsetAuthStatusDetails {
|
|
100
|
+
global?: string;
|
|
101
|
+
appLevel?: string;
|
|
102
|
+
userLevel?: string;
|
|
103
|
+
scopesSupported?: string[];
|
|
104
|
+
authorizationEndpoint?: string;
|
|
105
|
+
tokenEndpoint?: string;
|
|
106
|
+
apiKeyHeader?: string;
|
|
107
|
+
}
|
|
108
|
+
/** Catalog-facing specification fields for a toolset. */
|
|
109
|
+
export interface ToolsetSpecification {
|
|
110
|
+
provider?: string;
|
|
111
|
+
vendor?: string;
|
|
112
|
+
license?: string;
|
|
113
|
+
knowledgeCutoffDate?: string;
|
|
114
|
+
parameters?: string;
|
|
115
|
+
authentication?: AuthenticationType;
|
|
116
|
+
permissions?: string[];
|
|
117
|
+
hostedBy?: string;
|
|
118
|
+
authStatus?: ToolsetAuthStatusDetails;
|
|
119
|
+
createdAt?: number;
|
|
120
|
+
/** Names of all tools the underlying MCP server supports, not just the allow-listed subset in `permissions`. */
|
|
121
|
+
allTools?: string[];
|
|
122
|
+
}
|
|
123
|
+
/** Feature-support flags for a toolset. */
|
|
124
|
+
export interface ToolsetCapabilities {
|
|
125
|
+
hasMcp?: boolean;
|
|
126
|
+
hasCaching?: boolean;
|
|
127
|
+
hasSystemPrompt?: boolean;
|
|
128
|
+
hasResume?: boolean;
|
|
129
|
+
}
|
|
130
|
+
/** Full details payload for a toolset-type deployment. */
|
|
131
|
+
export interface ToolsetEntityDetails {
|
|
132
|
+
specification?: ToolsetSpecification;
|
|
133
|
+
capabilities?: ToolsetCapabilities;
|
|
134
|
+
}
|
|
135
|
+
/** Discriminated-union entity details for a deployment, keyed by catalog entity type. */
|
|
136
|
+
export type EntitySpecificDetails = {
|
|
137
|
+
type: 'MODEL';
|
|
138
|
+
data: ModelEntityDetails;
|
|
139
|
+
} | {
|
|
140
|
+
type: 'AGENT';
|
|
141
|
+
data: AgentEntityDetails;
|
|
142
|
+
} | {
|
|
143
|
+
type: 'TOOLSET';
|
|
144
|
+
data: ToolsetEntityDetails;
|
|
145
|
+
};
|
|
146
|
+
//# sourceMappingURL=entity-details.d.ts.map
|