@ale-rainbow/web-sdk 5.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +44 -0
- package/lib/index.d.ts +8 -0
- package/lib/index.d.ts.map +1 -0
- package/lib/index.js +501 -0
- package/lib/index.js.map +7 -0
- package/lib/libs/index.d.ts +3 -0
- package/lib/libs/index.d.ts.map +1 -0
- package/lib/libs/strophe/strophe-plugin.d.ts +13 -0
- package/lib/libs/strophe/strophe-plugin.d.ts.map +1 -0
- package/lib/libs/strophe/strophe.jingle.d.ts +35 -0
- package/lib/libs/strophe/strophe.jingle.d.ts.map +1 -0
- package/lib/libs/strophe/strophe.jingle.sdp.d.ts +44 -0
- package/lib/libs/strophe/strophe.jingle.sdp.d.ts.map +1 -0
- package/lib/libs/strophe/strophe.jingle.session.d.ts +624 -0
- package/lib/libs/strophe/strophe.jingle.session.d.ts.map +1 -0
- package/lib/libs/strophe/strophe.jingle.session.stats.d.ts +791 -0
- package/lib/libs/strophe/strophe.jingle.session.stats.d.ts.map +1 -0
- package/lib/libs/strophe/strophe.lastactivity.d.ts +9 -0
- package/lib/libs/strophe/strophe.lastactivity.d.ts.map +1 -0
- package/lib/libs/strophe/strophe.mam.d.ts +11 -0
- package/lib/libs/strophe/strophe.mam.d.ts.map +1 -0
- package/lib/libs/strophe/strophe.ping.d.ts +39 -0
- package/lib/libs/strophe/strophe.ping.d.ts.map +1 -0
- package/lib/libs/strophe/strophe.rsm.d.ts +24 -0
- package/lib/libs/strophe/strophe.rsm.d.ts.map +1 -0
- package/lib/libs/strophe/types.d.ts +23 -0
- package/lib/libs/strophe/types.d.ts.map +1 -0
- package/lib/models/authSettings.model.d.ts +38 -0
- package/lib/models/authSettings.model.d.ts.map +1 -0
- package/lib/models/bubble.model.d.ts +1114 -0
- package/lib/models/bubble.model.d.ts.map +1 -0
- package/lib/models/bubbleConferenceRecap.model.d.ts +532 -0
- package/lib/models/bubbleConferenceRecap.model.d.ts.map +1 -0
- package/lib/models/call.model.d.ts +1271 -0
- package/lib/models/call.model.d.ts.map +1 -0
- package/lib/models/callLog.model.d.ts +361 -0
- package/lib/models/callLog.model.d.ts.map +1 -0
- package/lib/models/channel.model.d.ts +692 -0
- package/lib/models/channel.model.d.ts.map +1 -0
- package/lib/models/channelMessage.model.d.ts +300 -0
- package/lib/models/channelMessage.model.d.ts.map +1 -0
- package/lib/models/cli.model.d.ts +59 -0
- package/lib/models/cli.model.d.ts.map +1 -0
- package/lib/models/common/context.d.ts +37 -0
- package/lib/models/common/context.d.ts.map +1 -0
- package/lib/models/common/error.d.ts +26 -0
- package/lib/models/common/error.d.ts.map +1 -0
- package/lib/models/common/fileDescriptor.d.ts +317 -0
- package/lib/models/common/fileDescriptor.d.ts.map +1 -0
- package/lib/models/common/filePublicDownload.d.ts +26 -0
- package/lib/models/common/filePublicDownload.d.ts.map +1 -0
- package/lib/models/common/fileViewer.d.ts +20 -0
- package/lib/models/common/fileViewer.d.ts.map +1 -0
- package/lib/models/common/index.d.ts +9 -0
- package/lib/models/common/index.d.ts.map +1 -0
- package/lib/models/common/theme.d.ts +185 -0
- package/lib/models/common/theme.d.ts.map +1 -0
- package/lib/models/common/themeColor.d.ts +47 -0
- package/lib/models/common/themeColor.d.ts.map +1 -0
- package/lib/models/common/userTheme.d.ts +42 -0
- package/lib/models/common/userTheme.d.ts.map +1 -0
- package/lib/models/company-invitation.model.d.ts +42 -0
- package/lib/models/company-invitation.model.d.ts.map +1 -0
- package/lib/models/company.model.d.ts +639 -0
- package/lib/models/company.model.d.ts.map +1 -0
- package/lib/models/contact.model.d.ts +1208 -0
- package/lib/models/contact.model.d.ts.map +1 -0
- package/lib/models/conversation.model.d.ts +768 -0
- package/lib/models/conversation.model.d.ts.map +1 -0
- package/lib/models/customManifest.model.d.ts +82 -0
- package/lib/models/customManifest.model.d.ts.map +1 -0
- package/lib/models/dataChannel.model.d.ts +178 -0
- package/lib/models/dataChannel.model.d.ts.map +1 -0
- package/lib/models/dial-in-phone-numbers.model.d.ts +18 -0
- package/lib/models/dial-in-phone-numbers.model.d.ts.map +1 -0
- package/lib/models/directoryContact.model.d.ts +205 -0
- package/lib/models/directoryContact.model.d.ts.map +1 -0
- package/lib/models/event.model.d.ts +14 -0
- package/lib/models/event.model.d.ts.map +1 -0
- package/lib/models/favorite.model.d.ts +94 -0
- package/lib/models/favorite.model.d.ts.map +1 -0
- package/lib/models/fileDocument.model.d.ts +345 -0
- package/lib/models/fileDocument.model.d.ts.map +1 -0
- package/lib/models/geoLoc.model.d.ts +6 -0
- package/lib/models/geoLoc.model.d.ts.map +1 -0
- package/lib/models/index.d.ts +46 -0
- package/lib/models/index.d.ts.map +1 -0
- package/lib/models/invitation.model.d.ts +88 -0
- package/lib/models/invitation.model.d.ts.map +1 -0
- package/lib/models/invoices.model.d.ts +76 -0
- package/lib/models/invoices.model.d.ts.map +1 -0
- package/lib/models/logEntry.model.d.ts +23 -0
- package/lib/models/logEntry.model.d.ts.map +1 -0
- package/lib/models/message.model.d.ts +400 -0
- package/lib/models/message.model.d.ts.map +1 -0
- package/lib/models/messageAdditionalContent.parsers.d.ts +32 -0
- package/lib/models/messageAdditionalContent.parsers.d.ts.map +1 -0
- package/lib/models/offer.model.d.ts +16 -0
- package/lib/models/offer.model.d.ts.map +1 -0
- package/lib/models/p2pRecap.model.d.ts +372 -0
- package/lib/models/p2pRecap.model.d.ts.map +1 -0
- package/lib/models/paymentMethods.model.d.ts +98 -0
- package/lib/models/paymentMethods.model.d.ts.map +1 -0
- package/lib/models/personalRoutine.model.d.ts +173 -0
- package/lib/models/personalRoutine.model.d.ts.map +1 -0
- package/lib/models/poll.model.d.ts +139 -0
- package/lib/models/poll.model.d.ts.map +1 -0
- package/lib/models/rainbow-auth.model.d.ts +137 -0
- package/lib/models/rainbow-auth.model.d.ts.map +1 -0
- package/lib/models/searchTextConvResults.model.d.ts +30 -0
- package/lib/models/searchTextConvResults.model.d.ts.map +1 -0
- package/lib/models/site.model.d.ts +165 -0
- package/lib/models/site.model.d.ts.map +1 -0
- package/lib/models/subscription.model.d.ts +592 -0
- package/lib/models/subscription.model.d.ts.map +1 -0
- package/lib/models/telephonyConfig.model.d.ts +144 -0
- package/lib/models/telephonyConfig.model.d.ts.map +1 -0
- package/lib/models/telephonyForward.model.d.ts +47 -0
- package/lib/models/telephonyForward.model.d.ts.map +1 -0
- package/lib/models/todo.model.d.ts +103 -0
- package/lib/models/todo.model.d.ts.map +1 -0
- package/lib/models/transcription.model.d.ts +59 -0
- package/lib/models/transcription.model.d.ts.map +1 -0
- package/lib/models/user.model.d.ts +1008 -0
- package/lib/models/user.model.d.ts.map +1 -0
- package/lib/models/userProfileTemplate.model.d.ts +735 -0
- package/lib/models/userProfileTemplate.model.d.ts.map +1 -0
- package/lib/models/usersList.model.d.ts +117 -0
- package/lib/models/usersList.model.d.ts.map +1 -0
- package/lib/models/webConferenceParticipant.model.d.ts +135 -0
- package/lib/models/webConferenceParticipant.model.d.ts.map +1 -0
- package/lib/models/webConferenceSession.model.d.ts +658 -0
- package/lib/models/webConferenceSession.model.d.ts.map +1 -0
- package/lib/models/webinar.model.d.ts +738 -0
- package/lib/models/webinar.model.d.ts.map +1 -0
- package/lib/models/webinarRecap.model.d.ts +118 -0
- package/lib/models/webinarRecap.model.d.ts.map +1 -0
- package/lib/node.d.ts +3 -0
- package/lib/node.d.ts.map +1 -0
- package/lib/node.js +423 -0
- package/lib/node.js.map +7 -0
- package/lib/node.sdk.d.ts +41 -0
- package/lib/node.sdk.d.ts.map +1 -0
- package/lib/plugins/admin.plugin.d.ts +6 -0
- package/lib/plugins/admin.plugin.d.ts.map +1 -0
- package/lib/plugins/bubbleConference.plugin.d.ts +6 -0
- package/lib/plugins/bubbleConference.plugin.d.ts.map +1 -0
- package/lib/plugins/bubbleTag.plugin.d.ts +6 -0
- package/lib/plugins/bubbleTag.plugin.d.ts.map +1 -0
- package/lib/plugins/bubbles.plugin.d.ts +6 -0
- package/lib/plugins/bubbles.plugin.d.ts.map +1 -0
- package/lib/plugins/businessDirectory.plugin.d.ts +6 -0
- package/lib/plugins/businessDirectory.plugin.d.ts.map +1 -0
- package/lib/plugins/callRecorder.plugin.d.ts +6 -0
- package/lib/plugins/callRecorder.plugin.d.ts.map +1 -0
- package/lib/plugins/calllog.plugin.d.ts +6 -0
- package/lib/plugins/calllog.plugin.d.ts.map +1 -0
- package/lib/plugins/calls.plugin.d.ts +6 -0
- package/lib/plugins/calls.plugin.d.ts.map +1 -0
- package/lib/plugins/channels.plugin.d.ts +6 -0
- package/lib/plugins/channels.plugin.d.ts.map +1 -0
- package/lib/plugins/dataChannel.plugin.d.ts +6 -0
- package/lib/plugins/dataChannel.plugin.d.ts.map +1 -0
- package/lib/plugins/deviceManagement.plugin.d.ts +6 -0
- package/lib/plugins/deviceManagement.plugin.d.ts.map +1 -0
- package/lib/plugins/favorites.plugin.d.ts +6 -0
- package/lib/plugins/favorites.plugin.d.ts.map +1 -0
- package/lib/plugins/fileDocument.plugin.d.ts +6 -0
- package/lib/plugins/fileDocument.plugin.d.ts.map +1 -0
- package/lib/plugins/helpCenter.plugin.d.ts +6 -0
- package/lib/plugins/helpCenter.plugin.d.ts.map +1 -0
- package/lib/plugins/index.d.ts +27 -0
- package/lib/plugins/index.d.ts.map +1 -0
- package/lib/plugins/microsoft0365Ad.plugin.d.ts +6 -0
- package/lib/plugins/microsoft0365Ad.plugin.d.ts.map +1 -0
- package/lib/plugins/pbxUsers.plugin.d.ts +6 -0
- package/lib/plugins/pbxUsers.plugin.d.ts.map +1 -0
- package/lib/plugins/personalDirectory.plugin.d.ts +6 -0
- package/lib/plugins/personalDirectory.plugin.d.ts.map +1 -0
- package/lib/plugins/plugin.d.ts +8 -0
- package/lib/plugins/plugin.d.ts.map +1 -0
- package/lib/plugins/polls.plugin.d.ts +6 -0
- package/lib/plugins/polls.plugin.d.ts.map +1 -0
- package/lib/plugins/rpc.plugin.d.ts +6 -0
- package/lib/plugins/rpc.plugin.d.ts.map +1 -0
- package/lib/plugins/telemetry.plugin.d.ts +6 -0
- package/lib/plugins/telemetry.plugin.d.ts.map +1 -0
- package/lib/plugins/telephony.plugin.d.ts +6 -0
- package/lib/plugins/telephony.plugin.d.ts.map +1 -0
- package/lib/plugins/telephonyConfig.plugin.d.ts +6 -0
- package/lib/plugins/telephonyConfig.plugin.d.ts.map +1 -0
- package/lib/plugins/transcription.plugin.d.ts +6 -0
- package/lib/plugins/transcription.plugin.d.ts.map +1 -0
- package/lib/plugins/usersList.plugin.d.ts +6 -0
- package/lib/plugins/usersList.plugin.d.ts.map +1 -0
- package/lib/plugins/virtualBackground.plugin.d.ts +6 -0
- package/lib/plugins/virtualBackground.plugin.d.ts.map +1 -0
- package/lib/plugins/webinar.plugin.d.ts +6 -0
- package/lib/plugins/webinar.plugin.d.ts.map +1 -0
- package/lib/rainbow.sdk.d.ts +309 -0
- package/lib/rainbow.sdk.d.ts.map +1 -0
- package/lib/services/admin/admin-alarm.service.d.ts +42 -0
- package/lib/services/admin/admin-alarm.service.d.ts.map +1 -0
- package/lib/services/admin/admin-company.service.d.ts +167 -0
- package/lib/services/admin/admin-company.service.d.ts.map +1 -0
- package/lib/services/admin/admin-department.service.d.ts +39 -0
- package/lib/services/admin/admin-department.service.d.ts.map +1 -0
- package/lib/services/admin/admin-invitation.service.d.ts +114 -0
- package/lib/services/admin/admin-invitation.service.d.ts.map +1 -0
- package/lib/services/admin/admin-management.service.d.ts +100 -0
- package/lib/services/admin/admin-management.service.d.ts.map +1 -0
- package/lib/services/admin/admin-rvcp.service.d.ts +43 -0
- package/lib/services/admin/admin-rvcp.service.d.ts.map +1 -0
- package/lib/services/admin/admin-site.service.d.ts +64 -0
- package/lib/services/admin/admin-site.service.d.ts.map +1 -0
- package/lib/services/admin/admin-subscription.service.d.ts +135 -0
- package/lib/services/admin/admin-subscription.service.d.ts.map +1 -0
- package/lib/services/admin/admin-tag.service.d.ts +79 -0
- package/lib/services/admin/admin-tag.service.d.ts.map +1 -0
- package/lib/services/admin/admin-user-profile.service.d.ts +76 -0
- package/lib/services/admin/admin-user-profile.service.d.ts.map +1 -0
- package/lib/services/admin/admin-user.service.d.ts +338 -0
- package/lib/services/admin/admin-user.service.d.ts.map +1 -0
- package/lib/services/admin/admin.common.d.ts +40 -0
- package/lib/services/admin/admin.common.d.ts.map +1 -0
- package/lib/services/admin/admin.service.d.ts +138 -0
- package/lib/services/admin/admin.service.d.ts.map +1 -0
- package/lib/services/admin/index.d.ts +14 -0
- package/lib/services/admin/index.d.ts.map +1 -0
- package/lib/services/bot/bot.service.d.ts +121 -0
- package/lib/services/bot/bot.service.d.ts.map +1 -0
- package/lib/services/bubbles/bubble.service.d.ts +889 -0
- package/lib/services/bubbles/bubble.service.d.ts.map +1 -0
- package/lib/services/bubbles/bubbleTag.service.d.ts +132 -0
- package/lib/services/bubbles/bubbleTag.service.d.ts.map +1 -0
- package/lib/services/bubbles/index.d.ts +3 -0
- package/lib/services/bubbles/index.d.ts.map +1 -0
- package/lib/services/call/call.service.d.ts +297 -0
- package/lib/services/call/call.service.d.ts.map +1 -0
- package/lib/services/call/callRecorder.service.d.ts +358 -0
- package/lib/services/call/callRecorder.service.d.ts.map +1 -0
- package/lib/services/call/index.d.ts +3 -0
- package/lib/services/call/index.d.ts.map +1 -0
- package/lib/services/callLog/callLog.service.d.ts +563 -0
- package/lib/services/callLog/callLog.service.d.ts.map +1 -0
- package/lib/services/callLog/index.d.ts +5 -0
- package/lib/services/callLog/index.d.ts.map +1 -0
- package/lib/services/callLog/p2pRecap.service.d.ts +206 -0
- package/lib/services/callLog/p2pRecap.service.d.ts.map +1 -0
- package/lib/services/channels/channel.service.d.ts +626 -0
- package/lib/services/channels/channel.service.d.ts.map +1 -0
- package/lib/services/channels/index.d.ts +3 -0
- package/lib/services/channels/index.d.ts.map +1 -0
- package/lib/services/citrix/citrix.service.d.ts +30 -0
- package/lib/services/citrix/citrix.service.d.ts.map +1 -0
- package/lib/services/citrix/index.d.ts +3 -0
- package/lib/services/citrix/index.d.ts.map +1 -0
- package/lib/services/company/company-directory.service.d.ts +222 -0
- package/lib/services/company/company-directory.service.d.ts.map +1 -0
- package/lib/services/conference/bubbleConference.service.d.ts +1237 -0
- package/lib/services/conference/bubbleConference.service.d.ts.map +1 -0
- package/lib/services/conference/bubbleConferenceRecap.service.d.ts +159 -0
- package/lib/services/conference/bubbleConferenceRecap.service.d.ts.map +1 -0
- package/lib/services/conference/index.d.ts +5 -0
- package/lib/services/conference/index.d.ts.map +1 -0
- package/lib/services/conference/webConferenceHelper.d.ts +25 -0
- package/lib/services/conference/webConferenceHelper.d.ts.map +1 -0
- package/lib/services/conversation/conversation.service.d.ts +723 -0
- package/lib/services/conversation/conversation.service.d.ts.map +1 -0
- package/lib/services/conversation/conversationServiceBulkHistoryHandler.d.ts +39 -0
- package/lib/services/conversation/conversationServiceBulkHistoryHandler.d.ts.map +1 -0
- package/lib/services/conversation/conversationServiceEventHandler.d.ts +78 -0
- package/lib/services/conversation/conversationServiceEventHandler.d.ts.map +1 -0
- package/lib/services/conversation/index.d.ts +3 -0
- package/lib/services/conversation/index.d.ts.map +1 -0
- package/lib/services/core/account.service.d.ts +98 -0
- package/lib/services/core/account.service.d.ts.map +1 -0
- package/lib/services/core/auth.service.d.ts +303 -0
- package/lib/services/core/auth.service.d.ts.map +1 -0
- package/lib/services/core/company.service.d.ts +30 -0
- package/lib/services/core/company.service.d.ts.map +1 -0
- package/lib/services/core/connection.service.d.ts +209 -0
- package/lib/services/core/connection.service.d.ts.map +1 -0
- package/lib/services/core/contact.service.d.ts +617 -0
- package/lib/services/core/contact.service.d.ts.map +1 -0
- package/lib/services/core/country.service.d.ts +66 -0
- package/lib/services/core/country.service.d.ts.map +1 -0
- package/lib/services/core/directorySearch.service.d.ts +305 -0
- package/lib/services/core/directorySearch.service.d.ts.map +1 -0
- package/lib/services/core/event.service.d.ts +31 -0
- package/lib/services/core/event.service.d.ts.map +1 -0
- package/lib/services/core/i18n.service.d.ts +19 -0
- package/lib/services/core/i18n.service.d.ts.map +1 -0
- package/lib/services/core/imageUtils.service.d.ts +15 -0
- package/lib/services/core/imageUtils.service.d.ts.map +1 -0
- package/lib/services/core/index.d.ts +19 -0
- package/lib/services/core/index.d.ts.map +1 -0
- package/lib/services/core/logger.service.d.ts +143 -0
- package/lib/services/core/logger.service.d.ts.map +1 -0
- package/lib/services/core/logging.service.d.ts +51 -0
- package/lib/services/core/logging.service.d.ts.map +1 -0
- package/lib/services/core/main.service.d.ts +124 -0
- package/lib/services/core/main.service.d.ts.map +1 -0
- package/lib/services/core/presenceHelper.service.d.ts +73 -0
- package/lib/services/core/presenceHelper.service.d.ts.map +1 -0
- package/lib/services/core/profile.service.d.ts +453 -0
- package/lib/services/core/profile.service.d.ts.map +1 -0
- package/lib/services/core/settings.service.d.ts +82 -0
- package/lib/services/core/settings.service.d.ts.map +1 -0
- package/lib/services/core/userInfo.service.d.ts +25 -0
- package/lib/services/core/userInfo.service.d.ts.map +1 -0
- package/lib/services/core/userNetwork.service.d.ts +171 -0
- package/lib/services/core/userNetwork.service.d.ts.map +1 -0
- package/lib/services/core/xmpp.service.d.ts +99 -0
- package/lib/services/core/xmpp.service.d.ts.map +1 -0
- package/lib/services/dataChannel/dataChannel.service.d.ts +102 -0
- package/lib/services/dataChannel/dataChannel.service.d.ts.map +1 -0
- package/lib/services/dataChannel/index.d.ts +3 -0
- package/lib/services/dataChannel/index.d.ts.map +1 -0
- package/lib/services/deviceManagement/deviceEchoFilter.d.ts +86 -0
- package/lib/services/deviceManagement/deviceEchoFilter.d.ts.map +1 -0
- package/lib/services/deviceManagement/deviceManagement.service.d.ts +290 -0
- package/lib/services/deviceManagement/deviceManagement.service.d.ts.map +1 -0
- package/lib/services/deviceManagement/index.d.ts +2 -0
- package/lib/services/deviceManagement/index.d.ts.map +1 -0
- package/lib/services/deviceManagement/webHidManager.service.d.ts +616 -0
- package/lib/services/deviceManagement/webHidManager.service.d.ts.map +1 -0
- package/lib/services/directory/directory.service.d.ts +108 -0
- package/lib/services/directory/directory.service.d.ts.map +1 -0
- package/lib/services/directory/index.d.ts +3 -0
- package/lib/services/directory/index.d.ts.map +1 -0
- package/lib/services/directory/office365ad.service.d.ts +74 -0
- package/lib/services/directory/office365ad.service.d.ts.map +1 -0
- package/lib/services/directory/personal-directory.service.d.ts +425 -0
- package/lib/services/directory/personal-directory.service.d.ts.map +1 -0
- package/lib/services/directory/phonebook.service.d.ts +43 -0
- package/lib/services/directory/phonebook.service.d.ts.map +1 -0
- package/lib/services/event-mixin.d.ts +75 -0
- package/lib/services/event-mixin.d.ts.map +1 -0
- package/lib/services/favorites/favorites.service.d.ts +313 -0
- package/lib/services/favorites/favorites.service.d.ts.map +1 -0
- package/lib/services/favorites/index.d.ts +3 -0
- package/lib/services/favorites/index.d.ts.map +1 -0
- package/lib/services/fileDocument/fileDocument.service.d.ts +229 -0
- package/lib/services/fileDocument/fileDocument.service.d.ts.map +1 -0
- package/lib/services/fileDocument/index.d.ts +5 -0
- package/lib/services/fileDocument/index.d.ts.map +1 -0
- package/lib/services/files/fileDescriptorEventHandler.service.d.ts +18 -0
- package/lib/services/files/fileDescriptorEventHandler.service.d.ts.map +1 -0
- package/lib/services/files/fileServer.service.d.ts +268 -0
- package/lib/services/files/fileServer.service.d.ts.map +1 -0
- package/lib/services/files/fileStorage.service.d.ts +426 -0
- package/lib/services/files/fileStorage.service.d.ts.map +1 -0
- package/lib/services/helpcenter/helpCenter.service.d.ts +207 -0
- package/lib/services/helpcenter/helpCenter.service.d.ts.map +1 -0
- package/lib/services/helpcenter/index.d.ts +4 -0
- package/lib/services/helpcenter/index.d.ts.map +1 -0
- package/lib/services/helpcenter/whatsNew.service.d.ts +47 -0
- package/lib/services/helpcenter/whatsNew.service.d.ts.map +1 -0
- package/lib/services/horizon/horizon.service.d.ts +31 -0
- package/lib/services/horizon/horizon.service.d.ts.map +1 -0
- package/lib/services/horizon/index.d.ts +3 -0
- package/lib/services/horizon/index.d.ts.map +1 -0
- package/lib/services/index.d.ts +35 -0
- package/lib/services/index.d.ts.map +1 -0
- package/lib/services/launcher/config/sdkLaunchConfig.d.ts +8 -0
- package/lib/services/launcher/config/sdkLaunchConfig.d.ts.map +1 -0
- package/lib/services/localTranslation/chromeTranslation.engine.d.ts +79 -0
- package/lib/services/localTranslation/chromeTranslation.engine.d.ts.map +1 -0
- package/lib/services/localTranslation/index.d.ts +6 -0
- package/lib/services/localTranslation/index.d.ts.map +1 -0
- package/lib/services/localTranslation/localTranslation.service.d.ts +129 -0
- package/lib/services/localTranslation/localTranslation.service.d.ts.map +1 -0
- package/lib/services/localTranslation/translationEngine.d.ts +81 -0
- package/lib/services/localTranslation/translationEngine.d.ts.map +1 -0
- package/lib/services/metrics/analytics.service.d.ts +63 -0
- package/lib/services/metrics/analytics.service.d.ts.map +1 -0
- package/lib/services/metrics/index.d.ts +2 -0
- package/lib/services/metrics/index.d.ts.map +1 -0
- package/lib/services/notifications/index.d.ts +2 -0
- package/lib/services/notifications/index.d.ts.map +1 -0
- package/lib/services/notifications/notificationCenter.service.d.ts +178 -0
- package/lib/services/notifications/notificationCenter.service.d.ts.map +1 -0
- package/lib/services/notifications/notificationsViewer.service.d.ts +46 -0
- package/lib/services/notifications/notificationsViewer.service.d.ts.map +1 -0
- package/lib/services/personalRoutines/personal-routines.service.d.ts +159 -0
- package/lib/services/personalRoutines/personal-routines.service.d.ts.map +1 -0
- package/lib/services/polls/index.d.ts +2 -0
- package/lib/services/polls/index.d.ts.map +1 -0
- package/lib/services/polls/polls.service.d.ts +139 -0
- package/lib/services/polls/polls.service.d.ts.map +1 -0
- package/lib/services/ringing/index.d.ts +2 -0
- package/lib/services/ringing/index.d.ts.map +1 -0
- package/lib/services/ringing/ringing.service.d.ts +535 -0
- package/lib/services/ringing/ringing.service.d.ts.map +1 -0
- package/lib/services/rpc/index.d.ts +2 -0
- package/lib/services/rpc/index.d.ts.map +1 -0
- package/lib/services/rpc/rpc.service.d.ts +75 -0
- package/lib/services/rpc/rpc.service.d.ts.map +1 -0
- package/lib/services/service.d.ts +9 -0
- package/lib/services/service.d.ts.map +1 -0
- package/lib/services/speechRecognitionService/speechRecognition.service.d.ts +87 -0
- package/lib/services/speechRecognitionService/speechRecognition.service.d.ts.map +1 -0
- package/lib/services/subscription/index.d.ts +4 -0
- package/lib/services/subscription/index.d.ts.map +1 -0
- package/lib/services/subscription/invoices.service.d.ts +78 -0
- package/lib/services/subscription/invoices.service.d.ts.map +1 -0
- package/lib/services/subscription/paymentMethods.service.d.ts +164 -0
- package/lib/services/subscription/paymentMethods.service.d.ts.map +1 -0
- package/lib/services/subscription/subscription.service.d.ts +510 -0
- package/lib/services/subscription/subscription.service.d.ts.map +1 -0
- package/lib/services/support/index.d.ts +2 -0
- package/lib/services/support/index.d.ts.map +1 -0
- package/lib/services/support/support.model.d.ts +143 -0
- package/lib/services/support/support.model.d.ts.map +1 -0
- package/lib/services/support/support.service.d.ts +162 -0
- package/lib/services/support/support.service.d.ts.map +1 -0
- package/lib/services/telemetry/index.d.ts +3 -0
- package/lib/services/telemetry/index.d.ts.map +1 -0
- package/lib/services/telemetry/jsonRPC.service.d.ts +25 -0
- package/lib/services/telemetry/jsonRPC.service.d.ts.map +1 -0
- package/lib/services/telemetry/telemetry.service.d.ts +22 -0
- package/lib/services/telemetry/telemetry.service.d.ts.map +1 -0
- package/lib/services/telephony/index.d.ts +4 -0
- package/lib/services/telephony/index.d.ts.map +1 -0
- package/lib/services/telephony/supervision.service.d.ts +277 -0
- package/lib/services/telephony/supervision.service.d.ts.map +1 -0
- package/lib/services/telephony/telephony.service.d.ts +1476 -0
- package/lib/services/telephony/telephony.service.d.ts.map +1 -0
- package/lib/services/telephony/telephonyCcdAgent.service.d.ts +63 -0
- package/lib/services/telephony/telephonyCcdAgent.service.d.ts.map +1 -0
- package/lib/services/telephony/telephonyHybridEventHandler.d.ts +360 -0
- package/lib/services/telephony/telephonyHybridEventHandler.d.ts.map +1 -0
- package/lib/services/telephony/telephonyKeys.service.d.ts +86 -0
- package/lib/services/telephony/telephonyKeys.service.d.ts.map +1 -0
- package/lib/services/telephony/telephonySipWise.service.d.ts +543 -0
- package/lib/services/telephony/telephonySipWise.service.d.ts.map +1 -0
- package/lib/services/telephony/telephonySipWiseEventHandler.d.ts +462 -0
- package/lib/services/telephony/telephonySipWiseEventHandler.d.ts.map +1 -0
- package/lib/services/telephonyConfig/index.d.ts +3 -0
- package/lib/services/telephonyConfig/index.d.ts.map +1 -0
- package/lib/services/telephonyConfig/telephonyConfig.service.d.ts +150 -0
- package/lib/services/telephonyConfig/telephonyConfig.service.d.ts.map +1 -0
- package/lib/services/todo/todo.service.d.ts +358 -0
- package/lib/services/todo/todo.service.d.ts.map +1 -0
- package/lib/services/transcription/index.d.ts +2 -0
- package/lib/services/transcription/index.d.ts.map +1 -0
- package/lib/services/transcription/liveTranscription.service.d.ts +94 -0
- package/lib/services/transcription/liveTranscription.service.d.ts.map +1 -0
- package/lib/services/ulrMetadata/urlMetadata.service.d.ts +51 -0
- package/lib/services/ulrMetadata/urlMetadata.service.d.ts.map +1 -0
- package/lib/services/users/index.d.ts +3 -0
- package/lib/services/users/index.d.ts.map +1 -0
- package/lib/services/users/user.service.d.ts +146 -0
- package/lib/services/users/user.service.d.ts.map +1 -0
- package/lib/services/users/usersLists.service.d.ts +239 -0
- package/lib/services/users/usersLists.service.d.ts.map +1 -0
- package/lib/services/utilities/browserDatabase.service.d.ts +69 -0
- package/lib/services/utilities/browserDatabase.service.d.ts.map +1 -0
- package/lib/services/utilities/errorHelper.service.d.ts +24 -0
- package/lib/services/utilities/errorHelper.service.d.ts.map +1 -0
- package/lib/services/utilities/index.d.ts +4 -0
- package/lib/services/utilities/index.d.ts.map +1 -0
- package/lib/services/utilities/utilities.service.d.ts +74 -0
- package/lib/services/utilities/utilities.service.d.ts.map +1 -0
- package/lib/services/virtualBackground/RBVirtualBackground.service.d.ts +228 -0
- package/lib/services/virtualBackground/RBVirtualBackground.service.d.ts.map +1 -0
- package/lib/services/virtualBackground/index.d.ts +4 -0
- package/lib/services/virtualBackground/index.d.ts.map +1 -0
- package/lib/services/virtualBackground/personalVideoBackground.d.ts +190 -0
- package/lib/services/virtualBackground/personalVideoBackground.d.ts.map +1 -0
- package/lib/services/virtualBackground/pipeline/canvas2D/canvas2DPipeline.d.ts +66 -0
- package/lib/services/virtualBackground/pipeline/canvas2D/canvas2DPipeline.d.ts.map +1 -0
- package/lib/services/virtualBackground/pipeline/webgl2/blurStage.d.ts +88 -0
- package/lib/services/virtualBackground/pipeline/webgl2/blurStage.d.ts.map +1 -0
- package/lib/services/virtualBackground/pipeline/webgl2/imageStage.d.ts +69 -0
- package/lib/services/virtualBackground/pipeline/webgl2/imageStage.d.ts.map +1 -0
- package/lib/services/virtualBackground/pipeline/webgl2/jointBilateralFilter.d.ts +55 -0
- package/lib/services/virtualBackground/pipeline/webgl2/jointBilateralFilter.d.ts.map +1 -0
- package/lib/services/virtualBackground/pipeline/webgl2/resizingStage.d.ts +59 -0
- package/lib/services/virtualBackground/pipeline/webgl2/resizingStage.d.ts.map +1 -0
- package/lib/services/virtualBackground/pipeline/webgl2/softMax.d.ts +34 -0
- package/lib/services/virtualBackground/pipeline/webgl2/softMax.d.ts.map +1 -0
- package/lib/services/virtualBackground/pipeline/webgl2/webgl2Pipeline.d.ts +62 -0
- package/lib/services/virtualBackground/pipeline/webgl2/webgl2Pipeline.d.ts.map +1 -0
- package/lib/services/virtualBackground/pipeline/webgl2/webglHelper.d.ts +56 -0
- package/lib/services/virtualBackground/pipeline/webgl2/webglHelper.d.ts.map +1 -0
- package/lib/services/virtualBackground/virtualBackground.service.d.ts +399 -0
- package/lib/services/virtualBackground/virtualBackground.service.d.ts.map +1 -0
- package/lib/services/webinars/index.d.ts +10 -0
- package/lib/services/webinars/index.d.ts.map +1 -0
- package/lib/services/webinars/telemetry/webinarTelemetry.model.d.ts +71 -0
- package/lib/services/webinars/telemetry/webinarTelemetry.model.d.ts.map +1 -0
- package/lib/services/webinars/telemetry/webinarTelemetry.service.d.ts +86 -0
- package/lib/services/webinars/telemetry/webinarTelemetry.service.d.ts.map +1 -0
- package/lib/services/webinars/telemetry/webinarTelemetryDatabase.d.ts +31 -0
- package/lib/services/webinars/telemetry/webinarTelemetryDatabase.d.ts.map +1 -0
- package/lib/services/webinars/webinarAudioMixer.d.ts +45 -0
- package/lib/services/webinars/webinarAudioMixer.d.ts.map +1 -0
- package/lib/services/webinars/webinarConference.service.d.ts +323 -0
- package/lib/services/webinars/webinarConference.service.d.ts.map +1 -0
- package/lib/services/webinars/webinarConference.utils.d.ts +24 -0
- package/lib/services/webinars/webinarConference.utils.d.ts.map +1 -0
- package/lib/services/webinars/webinarParticipants.service.d.ts +43 -0
- package/lib/services/webinars/webinarParticipants.service.d.ts.map +1 -0
- package/lib/services/webinars/webinarSpeakers.service.d.ts +25 -0
- package/lib/services/webinars/webinarSpeakers.service.d.ts.map +1 -0
- package/lib/services/webinars/webinarStoryLine.service.d.ts +117 -0
- package/lib/services/webinars/webinarStoryLine.service.d.ts.map +1 -0
- package/lib/services/webinars/webinars.service.d.ts +600 -0
- package/lib/services/webinars/webinars.service.d.ts.map +1 -0
- package/lib/services/webrtc/index.d.ts +5 -0
- package/lib/services/webrtc/index.d.ts.map +1 -0
- package/lib/services/webrtc/webrtcConfigAndUtils.d.ts +170 -0
- package/lib/services/webrtc/webrtcConfigAndUtils.d.ts.map +1 -0
- package/lib/services/webrtc/webrtcP2P.service.d.ts +521 -0
- package/lib/services/webrtc/webrtcP2P.service.d.ts.map +1 -0
- package/lib/services/webrtc/webrtcP2PEventHandler.d.ts +55 -0
- package/lib/services/webrtc/webrtcP2PEventHandler.d.ts.map +1 -0
- package/lib/services/webrtcGateway/webrtcGateway.service.d.ts +605 -0
- package/lib/services/webrtcGateway/webrtcGateway.service.d.ts.map +1 -0
- package/lib/strophejs.d.ts +3 -0
- package/lib/strophejs.d.ts.map +1 -0
- package/lib/typings/helpers.d.ts +3 -0
- package/lib/typings/helpers.d.ts.map +1 -0
- package/lib/utils/allSettled.d.ts +2 -0
- package/lib/utils/allSettled.d.ts.map +1 -0
- package/lib/utils/anonymizer.d.ts +28 -0
- package/lib/utils/anonymizer.d.ts.map +1 -0
- package/lib/utils/branded.d.ts +4 -0
- package/lib/utils/branded.d.ts.map +1 -0
- package/lib/utils/browser.d.ts +231 -0
- package/lib/utils/browser.d.ts.map +1 -0
- package/lib/utils/index.d.ts +12 -0
- package/lib/utils/index.d.ts.map +1 -0
- package/lib/utils/mediaPermissionError.d.ts +2 -0
- package/lib/utils/mediaPermissionError.d.ts.map +1 -0
- package/lib/utils/promiseQueue.d.ts +10 -0
- package/lib/utils/promiseQueue.d.ts.map +1 -0
- package/lib/utils/randomString.d.ts +3 -0
- package/lib/utils/randomString.d.ts.map +1 -0
- package/lib/utils/recordingArchiveName.d.ts +13 -0
- package/lib/utils/recordingArchiveName.d.ts.map +1 -0
- package/lib/utils/serverTimestamp.d.ts +15 -0
- package/lib/utils/serverTimestamp.d.ts.map +1 -0
- package/lib/utils/stringifyError.d.ts +2 -0
- package/lib/utils/stringifyError.d.ts.map +1 -0
- package/lib/utils/video.d.ts +27 -0
- package/lib/utils/video.d.ts.map +1 -0
- package/lib/utils/wait.d.ts +2 -0
- package/lib/utils/wait.d.ts.map +1 -0
- package/lib/utils/xmlParser.d.ts +102 -0
- package/lib/utils/xmlParser.d.ts.map +1 -0
- package/lib/utils/xmlValidation.d.ts +119 -0
- package/lib/utils/xmlValidation.d.ts.map +1 -0
- package/package.json +58 -0
|
@@ -0,0 +1,510 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @module Subscription
|
|
3
|
+
*/
|
|
4
|
+
import type { EventableService } from "../../services/service";
|
|
5
|
+
import { CompanySubscription, TrialStatus } from "../../models/subscription.model";
|
|
6
|
+
import type { CommercialState, OfferGroup, PurchaseOptions, SeatUsage, SubscriptionOffer, SubscriptionPurchaseOrder, SubscriptionQuotation, SubscriptionQuotationOptions, UpdateSubscriptionPatch } from "../../models/subscription.model";
|
|
7
|
+
export declare const SUBSCRIPTION_SVC = "SubscriptionService";
|
|
8
|
+
export interface ISubscriptionServiceEvents {
|
|
9
|
+
/**
|
|
10
|
+
* @eventProperty
|
|
11
|
+
* This `RBEvent` is sent when the company's subscriptions have changed — bought, updated,
|
|
12
|
+
* cancelled, or announced by the backend over XMPP.
|
|
13
|
+
*
|
|
14
|
+
* Carries no payload: it says the previous read is stale, not what now holds. Ask the service
|
|
15
|
+
* again — the cache is already dropped when this fires, so the next read hits the server.
|
|
16
|
+
*/
|
|
17
|
+
ON_COMPANY_SUBSCRIPTIONS_CHANGED: unknown;
|
|
18
|
+
}
|
|
19
|
+
export interface SubscriptionService extends EventableService<ISubscriptionServiceEvents> {
|
|
20
|
+
/**
|
|
21
|
+
* Fetches all available subscription offers (the catalog).
|
|
22
|
+
*
|
|
23
|
+
* Does not require authentication. Results may be geo-filtered based on the caller's location.
|
|
24
|
+
*
|
|
25
|
+
* @returns An array of available {@link SubscriptionOffer} objects.
|
|
26
|
+
* @throws {@link RainbowError} when the request fails.
|
|
27
|
+
*/
|
|
28
|
+
getOffers: () => Promise<SubscriptionOffer[]>;
|
|
29
|
+
/**
|
|
30
|
+
* Subscribes the authenticated user to an offer. The user id is read from the current session;
|
|
31
|
+
* {@link SubscriptionOffer.isFreemium} decides the path:
|
|
32
|
+
* - **Freemium**: free self-service. The backend creates the company on the fly, named after
|
|
33
|
+
* `companyName` when given, otherwise a placeholder the caller is expected to replace via
|
|
34
|
+
* {@link CompanyService.updateCompany}.
|
|
35
|
+
* - **Paid**: requires `purchaseOptions` (billing cycle, seats, billing address).
|
|
36
|
+
*
|
|
37
|
+
* @param purchaseOptions - Required for a paid offer, ignored for freemium.
|
|
38
|
+
* @param companyName - Only meaningful for a user with no company yet; ignored for a paid offer.
|
|
39
|
+
* @returns The {@link SubscriptionPurchaseOrder} for a paid offer; `undefined` for freemium.
|
|
40
|
+
* @throws {@link RainbowError} when the request fails, or an error when a paid offer is
|
|
41
|
+
* subscribed without `purchaseOptions`.
|
|
42
|
+
*/
|
|
43
|
+
subscribeToOffer: (offer: SubscriptionOffer, purchaseOptions?: PurchaseOptions, companyName?: string) => Promise<SubscriptionPurchaseOrder | undefined>;
|
|
44
|
+
/**
|
|
45
|
+
* Fetches the subscriptions of the authenticated user's company, read from the current
|
|
46
|
+
* session. Cached in memory until invalidated (a new subscription, or a `companysubscription`
|
|
47
|
+
* XMPP event).
|
|
48
|
+
*
|
|
49
|
+
* @param forceRefresh - Bypasses the cache and refetches.
|
|
50
|
+
*/
|
|
51
|
+
getCompanySubscriptions: (forceRefresh?: boolean) => Promise<CompanySubscription[]>;
|
|
52
|
+
/**
|
|
53
|
+
* Fetches a single subscription of the authenticated user's company.
|
|
54
|
+
*
|
|
55
|
+
* @returns The {@link CompanySubscription} or `undefined` if not found.
|
|
56
|
+
*/
|
|
57
|
+
getCompanySubscription: (subscriptionId: string) => Promise<CompanySubscription | undefined>;
|
|
58
|
+
/**
|
|
59
|
+
* Updates an existing subscription. Mainly used to change the licence count:
|
|
60
|
+
* `patch.maxNumberUsers` is the new **absolute total**, not a delta.
|
|
61
|
+
*
|
|
62
|
+
* Takes no payment method — the billing consequence (immediate pro-rata charge or adjustment
|
|
63
|
+
* at the next renewal) is decided server-side.
|
|
64
|
+
*
|
|
65
|
+
* @param patch - Only the keys present are sent; the backend leaves the others untouched.
|
|
66
|
+
* @throws {@link RainbowError} when the request fails (e.g. the new seat count is below the
|
|
67
|
+
* number of assigned licences, or the admin lacks the right).
|
|
68
|
+
*/
|
|
69
|
+
updateSubscription: (subscriptionId: string, patch: UpdateSubscriptionPatch) => Promise<CompanySubscription>;
|
|
70
|
+
/**
|
|
71
|
+
* Cancels a subscription. **Never immediate** — the period already paid for runs out, then
|
|
72
|
+
* access stops.
|
|
73
|
+
*
|
|
74
|
+
* Two backend calls, chosen from the billing cycle:
|
|
75
|
+
* - **monthly** — `DELETE .../companies/:companyId/subscriptions/:subscriptionId`. Keeps
|
|
76
|
+
* `status: "active"` with an `expirationDate`; a cron moves it to `terminated` on that date,
|
|
77
|
+
* so it stays listed meanwhile.
|
|
78
|
+
* - **prepaid** — `DELETE` is refused whatever the date (`403450`, "Prepaid subscriptions
|
|
79
|
+
* cannot be deleted in direct sell model"); automatic renewal is switched off instead, via
|
|
80
|
+
* {@link updateSubscription} as `{ autoRenew: false }`. Same outcome.
|
|
81
|
+
*
|
|
82
|
+
* {@link CompanySubscription.isCancelled} tells either apart from a live subscription.
|
|
83
|
+
*
|
|
84
|
+
* Also refused by the backend: sync with Business Store / Zuora in flight (`403311`), licences
|
|
85
|
+
* still allocated (`403316`, `403317`, `403318`), promo code outside its window on a monthly
|
|
86
|
+
* subscription (`403394`). The default subscription is never cancellable. A
|
|
87
|
+
* `linkedSubscriptionId` is cancelled in the same request. No cancellation reason is accepted
|
|
88
|
+
* by either endpoint — collect it separately if the product needs one.
|
|
89
|
+
*/
|
|
90
|
+
cancelSubscription: (subscriptionId: string) => Promise<void>;
|
|
91
|
+
/**
|
|
92
|
+
* Un-cancels a prepaid subscription by switching automatic renewal back on — the mirror of
|
|
93
|
+
* {@link cancelSubscription}'s prepaid branch.
|
|
94
|
+
*
|
|
95
|
+
* Prepaid only: a cancelled monthly one was `DELETE`d and carries an `expirationDate` nothing
|
|
96
|
+
* takes back. Running only: past the end date the backend has terminated it and released its
|
|
97
|
+
* licences, so the offer has to be bought again. Renewal already on returns without a call —
|
|
98
|
+
* the backend answers a second `autoRenew: true` with a `409`.
|
|
99
|
+
*
|
|
100
|
+
* The backend may still refuse: sync with Business Store / Zuora in flight answers `403311`.
|
|
101
|
+
*
|
|
102
|
+
* @throws When the subscription is unknown, monthly, or already over.
|
|
103
|
+
*/
|
|
104
|
+
restoreSubscription: (subscriptionId: string) => Promise<void>;
|
|
105
|
+
/**
|
|
106
|
+
* Prices a prospective change without applying it — read-only, nothing is written.
|
|
107
|
+
*
|
|
108
|
+
* Which fields come back depends on the subscription: a monthly one reports recurring amounts
|
|
109
|
+
* ({@link SubscriptionQuotation.contractedMrr}, {@link SubscriptionQuotation.totalDeltaMrr}), a
|
|
110
|
+
* prepaid one reports contract values ({@link SubscriptionQuotation.totalContractedValue},
|
|
111
|
+
* {@link SubscriptionQuotation.totalDeltaTcv}). Branch on
|
|
112
|
+
* {@link CompanySubscription.isMonthly} — reading `contractedMrr` on a prepaid subscription
|
|
113
|
+
* reports a monthly figure as if it were the contract total.
|
|
114
|
+
*
|
|
115
|
+
* Every field is optional: treat an absent one as "do not show that row" rather than
|
|
116
|
+
* substituting a computed value. {@link SubscriptionQuotation.taxAmount} in particular is the
|
|
117
|
+
* only trustworthy tax figure.
|
|
118
|
+
*
|
|
119
|
+
* @throws {@link RainbowError} when the request fails (e.g. invalid promo code).
|
|
120
|
+
*/
|
|
121
|
+
getSubscriptionQuotation: (subscriptionId: string, options: SubscriptionQuotationOptions) => Promise<SubscriptionQuotation>;
|
|
122
|
+
/**
|
|
123
|
+
* Prices a catalog offer without buying it — read-only, nothing is written.
|
|
124
|
+
*
|
|
125
|
+
* What {@link getSubscriptionQuotation} does for an existing subscription, keyed by the offer
|
|
126
|
+
* instead. Monthly and annual are separate offers, so `offerId` already fixes the cycle.
|
|
127
|
+
*
|
|
128
|
+
* @throws {@link RainbowError} when the request fails.
|
|
129
|
+
*/
|
|
130
|
+
getOfferQuotation: (offerId: string, maxNumberUsers: number) => Promise<SubscriptionQuotation>;
|
|
131
|
+
/**
|
|
132
|
+
* The company's trial as the interface needs to talk about it: end date, days left, whether it
|
|
133
|
+
* is over, whether an upsell is still worth showing.
|
|
134
|
+
*
|
|
135
|
+
* The single answer to "should this screen show the trial banner?" — read
|
|
136
|
+
* {@link TrialStatus.shouldPromptUpsell} rather than re-combining the trial, the paid
|
|
137
|
+
* subscriptions and the user's flags, which is how the several banners drift apart.
|
|
138
|
+
*
|
|
139
|
+
* Synchronous: read off the in-memory subscription cache, which `start()` fills before any
|
|
140
|
+
* screen runs and every change refreshes in place.
|
|
141
|
+
*
|
|
142
|
+
* @param groupName - Case-insensitive group filter (e.g. `"webinar"`); all trials when omitted.
|
|
143
|
+
* @returns `undefined` when the user is on no trial offer, or the company runs no trial
|
|
144
|
+
* carrying an end date.
|
|
145
|
+
*/
|
|
146
|
+
getTrialStatus: (groupName?: string) => TrialStatus | undefined;
|
|
147
|
+
/**
|
|
148
|
+
* Every trial the banner has to talk about: one status per product among the running trials,
|
|
149
|
+
* soonest to end first. A company running a Webinar and a Collaboration trial gets both, which
|
|
150
|
+
* is what lets the banner name each product with its own day count.
|
|
151
|
+
*
|
|
152
|
+
* When no trial is running, the last one to have ended alone, as {@link getTrialStatus} would
|
|
153
|
+
* answer — there is only one "your trial has ended" to say.
|
|
154
|
+
*
|
|
155
|
+
* @returns An empty array when the user is on no trial offer, or the company runs no trial
|
|
156
|
+
* carrying an end date.
|
|
157
|
+
*/
|
|
158
|
+
getTrialStatuses: () => TrialStatus[];
|
|
159
|
+
/**
|
|
160
|
+
* Where the account stands commercially — see {@link CommercialState}.
|
|
161
|
+
*
|
|
162
|
+
* The one place to ask "may we sell to this user, and is there anything left to sell?". Do not
|
|
163
|
+
* rebuild it from the trial roles: those survive the trial's end and a purchase.
|
|
164
|
+
*/
|
|
165
|
+
getCommercialState: () => CommercialState;
|
|
166
|
+
/**
|
|
167
|
+
* Whether the company runs at least one live subscription in `groupName` — asked of the
|
|
168
|
+
* subscriptions, not of the login payload: {@link Contact.isWebinarTrial} /
|
|
169
|
+
* {@link Contact.isCollaborationTrial} are rebuilt from roles read at login, so an offer
|
|
170
|
+
* subscribed since leaves them false and one that ended leaves them true.
|
|
171
|
+
*
|
|
172
|
+
* Unlike a paid-only check, freemium trials **count** here — a trial grants the product,
|
|
173
|
+
* which is its point. A running one sits at `status: "trial"`, so this reads
|
|
174
|
+
* {@link ACCESS_STATUSES}, not the paid-only list; a spent trial keeps that status and is
|
|
175
|
+
* ruled out by its date.
|
|
176
|
+
*
|
|
177
|
+
* Excludes the default base tier (held by every company) and `terminated` / `terminating`.
|
|
178
|
+
*
|
|
179
|
+
* @param groupName - Matched case-insensitively (e.g. `"collaboration"`, `"webinar"`).
|
|
180
|
+
*/
|
|
181
|
+
hasLiveSubscriptionOfGroup: (groupName: string) => boolean;
|
|
182
|
+
/**
|
|
183
|
+
* The live **paid** subscriptions the company runs in `groupName` — what it bought, not what
|
|
184
|
+
* it was granted. The paid-only counterpart of {@link hasLiveSubscriptionOfGroup}: a freemium
|
|
185
|
+
* trial grants the product but is precisely what a purchase upgrades, so it is excluded here,
|
|
186
|
+
* as are the default base tier (held by every company) and the never-sold Beta offer.
|
|
187
|
+
*
|
|
188
|
+
* Reads {@link LIVE_STATUSES}, not {@link ACCESS_STATUSES}: a running trial sits at
|
|
189
|
+
* `status: "trial"`, absent from the paid list, and a spent one is ruled out by its date.
|
|
190
|
+
*
|
|
191
|
+
* Returns the subscriptions rather than a boolean so a caller can also tell *which* plans are
|
|
192
|
+
* held — the offer sizes, for instance, which a yes/no answer cannot give. Emptiness is the
|
|
193
|
+
* boolean: no live paid subscription in that group.
|
|
194
|
+
*
|
|
195
|
+
* Synchronous: read off the in-memory subscription cache, which `start()` fills before any
|
|
196
|
+
* screen runs and every change refreshes in place.
|
|
197
|
+
*
|
|
198
|
+
* @param groupName - Matched case-insensitively (e.g. `"webinar"`, `"collaboration"`).
|
|
199
|
+
*/
|
|
200
|
+
getLivePaidSubscriptionsOfGroup: (groupName: string) => CompanySubscription[];
|
|
201
|
+
/**
|
|
202
|
+
* The group the company holds **only** a running trial of, when that trial is the single thing
|
|
203
|
+
* it runs at all — `undefined` in every other case.
|
|
204
|
+
*
|
|
205
|
+
* Answers "is this account here on the strength of one free trial, and nothing else?", which is
|
|
206
|
+
* what an offer catalog reads to decide which family to open on: a company trialling one
|
|
207
|
+
* product and owning nothing wants that product's offers in front of it, not the first family
|
|
208
|
+
* of the catalog's own order.
|
|
209
|
+
*
|
|
210
|
+
* Deliberately stricter than {@link hasLiveSubscriptionOfGroup}, which answers per group and
|
|
211
|
+
* says nothing of what else is held. Every subscription of the company is weighed here: a
|
|
212
|
+
* second trial in another family, or any live paid plan, means the account is not defined by
|
|
213
|
+
* the one trial and this returns `undefined` rather than picking a winner.
|
|
214
|
+
*
|
|
215
|
+
* Ignores what {@link getLivePaidSubscriptionsOfGroup} ignores, and for the same reasons: the
|
|
216
|
+
* default base tier every company holds, and the never-sold Beta offer. A spent trial is ruled
|
|
217
|
+
* out by its date, not its status, which the backend leaves at `trial`.
|
|
218
|
+
*
|
|
219
|
+
* Group-agnostic: it reports whichever family the trial belongs to, so no caller has to name
|
|
220
|
+
* the products it expects.
|
|
221
|
+
*
|
|
222
|
+
* Synchronous, off the in-memory cache `start()` fills and every change refreshes.
|
|
223
|
+
*
|
|
224
|
+
* @returns The trial's group name as the catalog spells it (e.g. `"Webinar"`), or `undefined`.
|
|
225
|
+
*/
|
|
226
|
+
getSoleTrialGroupName: () => string | undefined;
|
|
227
|
+
/**
|
|
228
|
+
* Seats the company holds and seats already taken — read this before offering to invite
|
|
229
|
+
* anyone, and to show any "x / y licences" figure.
|
|
230
|
+
*
|
|
231
|
+
* Sums only the subscriptions whose licences are seats
|
|
232
|
+
* ({@link CompanySubscription.isUserLicense}): Webinar and the other `nb_services` offers hold
|
|
233
|
+
* their licences against the company, not against a user, so adding them would credit the
|
|
234
|
+
* company with places nobody can take.
|
|
235
|
+
*
|
|
236
|
+
* A cancelled subscription still counts until its last paid day — its seats are still assigned
|
|
237
|
+
* and still billed. A terminated or expired one does not: its licences are released.
|
|
238
|
+
*
|
|
239
|
+
* Synchronous, off the in-memory cache `start()` fills and every change refreshes.
|
|
240
|
+
*/
|
|
241
|
+
getSeatUsage: () => SeatUsage;
|
|
242
|
+
/**
|
|
243
|
+
* Purchasable offers grouped by product and variant: one {@link OfferGroup} per product family
|
|
244
|
+
* (e.g. "Webinar"), one {@link OfferVariant} per size (e.g. "Webinar 120") with its monthly
|
|
245
|
+
* and/or annual offer.
|
|
246
|
+
*
|
|
247
|
+
* A group whose trial is still available carries it in {@link OfferVariant.trial}. Trials
|
|
248
|
+
* already granted are filtered out upstream by {@link getPurchasableOffers}.
|
|
249
|
+
*
|
|
250
|
+
* @param groupName - Case-insensitive filter on the group name.
|
|
251
|
+
*/
|
|
252
|
+
getPurchasableOfferGroups: (groupName?: string) => Promise<OfferGroup[]>;
|
|
253
|
+
}
|
|
254
|
+
declare const SubscriptionServiceRB_base: object & (abstract new (...args: any[]) => import("../../services/service").EventsMixinTemplate<ISubscriptionServiceEvents>);
|
|
255
|
+
/** @internal */
|
|
256
|
+
export declare class SubscriptionServiceRB extends SubscriptionServiceRB_base implements SubscriptionService {
|
|
257
|
+
/**
|
|
258
|
+
* Statuses of a running *paid* subscription — "has this company bought anything?". Excludes
|
|
259
|
+
* `terminated` (licences released) and `terminating` (cancellation requested — the offer must
|
|
260
|
+
* stay re-purchasable). A trial carries none of them; it sits at `trial`. To ask whether the
|
|
261
|
+
* company *holds* the product rather than paid for it, read {@link ACCESS_STATUSES}.
|
|
262
|
+
*/
|
|
263
|
+
private static readonly LIVE_STATUSES;
|
|
264
|
+
/**
|
|
265
|
+
* Statuses under which the company holds the product — {@link LIVE_STATUSES} plus `trial`,
|
|
266
|
+
* a trial granting it exactly as a purchase does.
|
|
267
|
+
* Says nothing of the trial's end: a spent trial stays at `status: "trial"`, so the date ends
|
|
268
|
+
* it, not the status. Pair with {@link CompanySubscription.isExpired}.
|
|
269
|
+
*/
|
|
270
|
+
private static readonly ACCESS_STATUSES;
|
|
271
|
+
private readonly loggerService;
|
|
272
|
+
private readonly errorHelperService;
|
|
273
|
+
private readonly xmppService;
|
|
274
|
+
private xmppHandler;
|
|
275
|
+
private pendingSubscriptionResolvers;
|
|
276
|
+
private companySubscriptions;
|
|
277
|
+
static getInstance(): SubscriptionServiceRB;
|
|
278
|
+
static build(): SubscriptionServiceRB;
|
|
279
|
+
private constructor();
|
|
280
|
+
start(): Promise<void>;
|
|
281
|
+
reconnect(): Promise<void>;
|
|
282
|
+
stop(): void;
|
|
283
|
+
/**
|
|
284
|
+
* Refetch then announce — the subscriptions, and the company features they unlock. Both are
|
|
285
|
+
* awaited before the event so a listener reading either back is served the new state, and the
|
|
286
|
+
* cache is never left empty in between: `getCompanySubscriptions` only overwrites it once the
|
|
287
|
+
* response is in.
|
|
288
|
+
*/
|
|
289
|
+
private onSubscriptionsChanged;
|
|
290
|
+
private registerXmppHandler;
|
|
291
|
+
private removeXmppHandler;
|
|
292
|
+
private onManagementMessage;
|
|
293
|
+
private waitForXmppConfirmation;
|
|
294
|
+
getOffers(): Promise<SubscriptionOffer[]>;
|
|
295
|
+
subscribeToOffer(offer: SubscriptionOffer, purchaseOptions?: PurchaseOptions, companyName?: string): Promise<SubscriptionPurchaseOrder | undefined>;
|
|
296
|
+
/**
|
|
297
|
+
* Re-reads the user's own company in place on the connected contact, after any subscription.
|
|
298
|
+
*
|
|
299
|
+
* Nothing else pushes the company back: the user payload carries only `companyId` and
|
|
300
|
+
* `companyName`, and the company is otherwise re-read on reconnection alone. Yet a
|
|
301
|
+
* subscription changes it — a first purchase stamps its business model as direct-sell (see
|
|
302
|
+
* {@link purchaseFirstSubscription}), a trial stamps `freemiumTypes`, which
|
|
303
|
+
* {@link Company.trialTypes} reads and the launch pad gates on.
|
|
304
|
+
*
|
|
305
|
+
* Done for every purchase, the caller having no way to tell which fields the backend touched.
|
|
306
|
+
* Failure is swallowed: the purchase went through, and the refresh can be retried on its own.
|
|
307
|
+
*/
|
|
308
|
+
private refreshOwnCompany;
|
|
309
|
+
/**
|
|
310
|
+
* Re-reads the company features, which live on their own endpoint and are otherwise loaded at
|
|
311
|
+
* login alone — yet a subscription is precisely what turns one on, `webinarAccess` for a
|
|
312
|
+
* webinar offer, which {@link ConnectedUserRB.companyHasWebinarAccess} reads.
|
|
313
|
+
*
|
|
314
|
+
* Hung off the subscription change rather than off the purchase, so an offer bought from
|
|
315
|
+
* another tab or granted by an administrator lands here too.
|
|
316
|
+
*
|
|
317
|
+
* Failure is swallowed: the previous features are kept rather than cleared, so nothing the
|
|
318
|
+
* company holds is withdrawn from the interface over a failed refresh.
|
|
319
|
+
*/
|
|
320
|
+
private refreshOwnCompanyFeatures;
|
|
321
|
+
/**
|
|
322
|
+
* Freemium path: creates the company on the fly, waits for the XMPP provisioning
|
|
323
|
+
* confirmation, then optimistically applies the unlocked roles.
|
|
324
|
+
*
|
|
325
|
+
* @param companyName - When omitted, a recognizable placeholder is sent and the caller is
|
|
326
|
+
* expected to rename the company afterwards, as the onboarding wizard does.
|
|
327
|
+
*/
|
|
328
|
+
private subscribeFreemium;
|
|
329
|
+
/**
|
|
330
|
+
* Reads the authenticated user's company id from the current session.
|
|
331
|
+
* Mirrors how {@link subscribeToOffer} reads the user id — the caller is already logged in.
|
|
332
|
+
*/
|
|
333
|
+
private getCompanyId;
|
|
334
|
+
/**
|
|
335
|
+
* The connected user, non-optional: `CONTACT_SVC` starts `sync: true, blocking: true` ahead of
|
|
336
|
+
* this service in the launch config, so nothing here runs before it is set. Throws rather than
|
|
337
|
+
* answering a hollow object, which would read as "no company, no trial, not an admin" and
|
|
338
|
+
* silently deny what the user owns.
|
|
339
|
+
*/
|
|
340
|
+
private userContact;
|
|
341
|
+
getCompanySubscriptions(forceRefresh?: boolean): Promise<CompanySubscription[]>;
|
|
342
|
+
getCompanySubscription(subscriptionId: string): Promise<CompanySubscription | undefined>;
|
|
343
|
+
/** `PUT .../companies/:companyId/subscriptions/:subscriptionId` — see the interface. */
|
|
344
|
+
updateSubscription(subscriptionId: string, patch: UpdateSubscriptionPatch): Promise<CompanySubscription>;
|
|
345
|
+
/**
|
|
346
|
+
* The cycle is not carried by the id, hence the lookup first — served from the warm cache when
|
|
347
|
+
* a subscription list is what triggered this. See the interface.
|
|
348
|
+
*/
|
|
349
|
+
cancelSubscription(subscriptionId: string): Promise<void>;
|
|
350
|
+
/** See the interface. */
|
|
351
|
+
restoreSubscription(subscriptionId: string): Promise<void>;
|
|
352
|
+
/**
|
|
353
|
+
* Finds a subscription by id, for a caller given only the id. Cache first — a screen
|
|
354
|
+
* cancelling a subscription has just listed them — then the single-subscription endpoint.
|
|
355
|
+
*
|
|
356
|
+
* Answers `undefined` rather than throwing: callers use this to pick a branch, and a failed
|
|
357
|
+
* lookup should leave them on their default one, not abort them.
|
|
358
|
+
*/
|
|
359
|
+
private resolveSubscription;
|
|
360
|
+
/**
|
|
361
|
+
* `POST .../companies/:companyId/quotations` — read-only pricing, see the interface.
|
|
362
|
+
*/
|
|
363
|
+
getSubscriptionQuotation(subscriptionId: string, options: SubscriptionQuotationOptions): Promise<SubscriptionQuotation>;
|
|
364
|
+
/**
|
|
365
|
+
* `POST .../companies/:companyId/quotations` — read-only pricing, see the interface.
|
|
366
|
+
*/
|
|
367
|
+
getOfferQuotation(offerId: string, maxNumberUsers: number): Promise<SubscriptionQuotation>;
|
|
368
|
+
/** Shared POST + error handling for both quotation entry points. */
|
|
369
|
+
private postQuotation;
|
|
370
|
+
/**
|
|
371
|
+
* Keeps only the keys actually set in the patch — the backend treats an absent key
|
|
372
|
+
* as "leave unchanged", so sending `undefined` values would be a behaviour change.
|
|
373
|
+
*/
|
|
374
|
+
private buildUpdateBody;
|
|
375
|
+
/** The trial an upsell should talk about, picked from an already-read list. */
|
|
376
|
+
private pickTrial;
|
|
377
|
+
/**
|
|
378
|
+
* The trial to talk about among already-filtered ones.
|
|
379
|
+
*
|
|
380
|
+
* A trial keeps `status: "trial"` past its end date until the backend terminates it, so an
|
|
381
|
+
* expired one can sit next to a running one. Running ones answer first, soonest to end — the
|
|
382
|
+
* one about to run out, and the one an upsell should talk about. When all are expired, the
|
|
383
|
+
* last to have ended is the one the company just lost.
|
|
384
|
+
*/
|
|
385
|
+
private static pickAmong;
|
|
386
|
+
getTrialStatus(groupName?: string): TrialStatus | undefined;
|
|
387
|
+
getTrialStatuses(): TrialStatus[];
|
|
388
|
+
getCommercialState(): CommercialState;
|
|
389
|
+
/**
|
|
390
|
+
* The two populations who may buy: the company administrator, for the company, and the
|
|
391
|
+
* standalone user of the default company, for themselves.
|
|
392
|
+
*
|
|
393
|
+
* `isCompanyAdmin`, not `isAdmin`: site, organization and support admins carry the ADMIN role
|
|
394
|
+
* without being the ones who sign. Guests are excluded first — they land in the default
|
|
395
|
+
* company holding no admin role, so they would pass as standalone buyers. Platform-wide roles
|
|
396
|
+
* administer other people's companies and are never sold to.
|
|
397
|
+
*/
|
|
398
|
+
private mayBuyOffers;
|
|
399
|
+
/**
|
|
400
|
+
* The catalog offers the company can still purchase. An offer is excluded when:
|
|
401
|
+
* - `groupName` is given and the offer's does not match (case-insensitive);
|
|
402
|
+
* - it is freemium **and** the company already holds any subscription for that group, in any
|
|
403
|
+
* status. A trial is granted once, and a paid plan is never offered the free tier of what it
|
|
404
|
+
* already bought.
|
|
405
|
+
*
|
|
406
|
+
* Not on the public interface: callers want {@link getPurchasableOfferGroups}, which is what
|
|
407
|
+
* the offer cards render. Kept public for that method and its tests.
|
|
408
|
+
*
|
|
409
|
+
* @param groupName - Group filter (e.g. `"webinar"`, `"collaboration"`).
|
|
410
|
+
*/
|
|
411
|
+
getPurchasableOffers(groupName?: string): Promise<SubscriptionOffer[]>;
|
|
412
|
+
/**
|
|
413
|
+
* The company's own subscriptions, read straight off the cache — `start()` fills it before any
|
|
414
|
+
* screen runs and every change refreshes it in place, so there is nothing to await.
|
|
415
|
+
*
|
|
416
|
+
* A default-company user owns nothing: the shared company's lines are not theirs.
|
|
417
|
+
*/
|
|
418
|
+
private ownCompanySubscriptions;
|
|
419
|
+
getPurchasableOfferGroups(groupName?: string): Promise<OfferGroup[]>;
|
|
420
|
+
hasLiveSubscriptionOfGroup(groupName: string): boolean;
|
|
421
|
+
getLivePaidSubscriptionsOfGroup(groupName: string): CompanySubscription[];
|
|
422
|
+
getSoleTrialGroupName(): string | undefined;
|
|
423
|
+
getSeatUsage(): SeatUsage;
|
|
424
|
+
/**
|
|
425
|
+
* Whether the company actually bought something that is running right now.
|
|
426
|
+
*
|
|
427
|
+
* Drives the upsell surfaces — the boot offer catalog and the trial banner — so everything
|
|
428
|
+
* that is not a purchase has to be excluded, or a company holding none is told it already paid
|
|
429
|
+
* and never sees an offer again:
|
|
430
|
+
* - `isDefault` — the Essential base tier, granted to everyone.
|
|
431
|
+
* - `isFreemium` — the trials, which are precisely what the paid catalog upgrades.
|
|
432
|
+
* - `isInternal` — the Beta offer. Granted for feature testing, never sold, and it is
|
|
433
|
+
* `nb_users` with a licence of its own, so nothing but its reference tells it apart from a
|
|
434
|
+
* purchase. See {@link CompanySubscription.isInternal}.
|
|
435
|
+
*/
|
|
436
|
+
private static holdsLivePaid;
|
|
437
|
+
/**
|
|
438
|
+
* Lower-cased `offerReference` of every offer the company runs a live subscription to.
|
|
439
|
+
*
|
|
440
|
+
* "Live" excludes `terminated` (licences released, the offer is buyable again) and
|
|
441
|
+
* `terminating` (cancellation requested — the customer must be able to re-subscribe). The
|
|
442
|
+
* default base tier and the freemium trials are excluded too: not purchases, and a trial is
|
|
443
|
+
* precisely what the paid catalog upgrades.
|
|
444
|
+
*/
|
|
445
|
+
private getOwnedOfferReferences;
|
|
446
|
+
/**
|
|
447
|
+
* Folds the group's free trial into the paid variant it gives away — the cheapest — and orders
|
|
448
|
+
* the cards cheapest first.
|
|
449
|
+
*
|
|
450
|
+
* The trial is that cheapest paid offer free for a month, not a product of its own: as a card
|
|
451
|
+
* of its own beside it, the two read as competing plans. It becomes a property of that card,
|
|
452
|
+
* which the call to action then sells as a trial or as a purchase.
|
|
453
|
+
*
|
|
454
|
+
* Runs after the variants are built, not during the slotting: the prices it ranks on are only
|
|
455
|
+
* known once `monthly`/`annual` are in.
|
|
456
|
+
*/
|
|
457
|
+
private mergeTrialIntoCheapest;
|
|
458
|
+
/** Cheapest first, so the trial-bearing card leads and the row reads up in price. */
|
|
459
|
+
private sortByPrice;
|
|
460
|
+
/**
|
|
461
|
+
* What a seat of `variant` costs per month, whichever cycle it sells in — the only basis on
|
|
462
|
+
* which variants priced in different cycles compare.
|
|
463
|
+
*
|
|
464
|
+
* Mirrors the offer card's `currentPrice`, so the ranking matches the prices on screen. A
|
|
465
|
+
* variant sold in both cycles ranks on its cheaper one (in practice the annual, ~20% off):
|
|
466
|
+
* which one the card shows follows the billing switch, and "cheapest" must not move when the
|
|
467
|
+
* user flips it.
|
|
468
|
+
*
|
|
469
|
+
* A missing price ranks last, never at zero — it would otherwise win the cheapest race and
|
|
470
|
+
* take the trial with it.
|
|
471
|
+
*/
|
|
472
|
+
private monthlyEquivalentPrice;
|
|
473
|
+
/**
|
|
474
|
+
* Whether `offer` is already owned. Matches on the exact `offerReference`, so the
|
|
475
|
+
* monthly and annual variants of one product (`RB-Collab` vs `RB-Collab-1Y`) are
|
|
476
|
+
* independent — owning one leaves the other purchasable.
|
|
477
|
+
*/
|
|
478
|
+
private isOfferOwned;
|
|
479
|
+
/**
|
|
480
|
+
* Paid purchase. Two backend flows, chosen through `paymentMethodId`:
|
|
481
|
+
* - **First purchase** (set): `POST .../subscriptions/purchase` — atomically converts the
|
|
482
|
+
* company to direct-sell, creates the Zuora account from the payment method, and creates
|
|
483
|
+
* the subscription.
|
|
484
|
+
* - **Account exists** (absent): `POST .../subscriptions` — adds the subscription to it.
|
|
485
|
+
*
|
|
486
|
+
* Amounts are computed client-side, the endpoints returning the subscription rather than a
|
|
487
|
+
* priced order; `orderId` is the real subscription id from the backend.
|
|
488
|
+
*/
|
|
489
|
+
private purchasePaid;
|
|
490
|
+
/** First purchase: creates the Zuora account from the payment method and the subscription in one call. */
|
|
491
|
+
private purchaseFirstSubscription;
|
|
492
|
+
/** Subscribe on an existing Zuora account: only the subscription is created. */
|
|
493
|
+
private subscribeToExistingAccount;
|
|
494
|
+
/** Shared POST + error handling for the two subscription-creation endpoints. */
|
|
495
|
+
private postSubscription;
|
|
496
|
+
/**
|
|
497
|
+
* Optimistically pushes the matching freemium UserRole onto the in-memory user
|
|
498
|
+
* contact so the UI reflects unlocked features immediately after subscribing.
|
|
499
|
+
*
|
|
500
|
+
* ⚠️ TECH DEBT — patch, do not extend. Duplicates the role mapping already done
|
|
501
|
+
* during Contact hydration (contact.model.ts, `freemiumTypes` → UserRole). It
|
|
502
|
+
* exists only because the BE did not reliably return `freemiumTypes` right after
|
|
503
|
+
* a subscription. It derives the role from `hasWebinar` (NOT `freemiumTypes`) and
|
|
504
|
+
* does NOT handle the "webinar + collaboration" case. Remove once the BE returns
|
|
505
|
+
* correct subscription data and the contact refresh repopulates roles.
|
|
506
|
+
*/
|
|
507
|
+
private applySubscriptionRoles;
|
|
508
|
+
}
|
|
509
|
+
export {};
|
|
510
|
+
//# sourceMappingURL=subscription.service.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"subscription.service.d.ts","sourceRoot":"","sources":["../../../src/services/subscription/subscription.service.ts"],"names":[],"mappings":"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"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/services/support/index.ts"],"names":[],"mappings":"AAAA,cAAc,mBAAmB,CAAC"}
|
|
@@ -0,0 +1,143 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @module Support
|
|
3
|
+
*/
|
|
4
|
+
/**
|
|
5
|
+
* Lifecycle status of a support ticket.
|
|
6
|
+
*
|
|
7
|
+
* Mirrors the statuses exposed by the support backend. Any unknown value coming
|
|
8
|
+
* from the backend is normalized to `open` server-side, so this union is closed.
|
|
9
|
+
*/
|
|
10
|
+
export type SupportTicketStatus = "new" | "open" | "pending" | "hold" | "solved" | "closed";
|
|
11
|
+
/** A file attached to a ticket comment. */
|
|
12
|
+
export interface SupportAttachment {
|
|
13
|
+
/** Attachment id — feed to `downloadAttachment`. */
|
|
14
|
+
readonly id: string;
|
|
15
|
+
readonly fileName: string;
|
|
16
|
+
/** MIME type reported by the backend (e.g. `"image/png"`). */
|
|
17
|
+
readonly contentType: string;
|
|
18
|
+
readonly sizeBytes: number;
|
|
19
|
+
}
|
|
20
|
+
/**
|
|
21
|
+
* A ticket as listed by `getMyTickets` / `getCompanyTickets`.
|
|
22
|
+
*
|
|
23
|
+
* Only public information is exposed: the backend filters its own payload before
|
|
24
|
+
* returning it, so no internal identifier ever reaches the client.
|
|
25
|
+
*/
|
|
26
|
+
export interface SupportTicket {
|
|
27
|
+
readonly id: number;
|
|
28
|
+
readonly subject: string;
|
|
29
|
+
readonly status: SupportTicketStatus;
|
|
30
|
+
/** ISO 8601 creation date. */
|
|
31
|
+
readonly createdAt: string;
|
|
32
|
+
/** ISO 8601 date of the last update. */
|
|
33
|
+
readonly updatedAt: string;
|
|
34
|
+
/** Display name of the person who opened the ticket. */
|
|
35
|
+
readonly requesterName: string;
|
|
36
|
+
/**
|
|
37
|
+
* Email of the requester, only present when the caller is entitled to it:
|
|
38
|
+
* their own ticket, or a role covering the owning company.
|
|
39
|
+
*/
|
|
40
|
+
readonly requesterEmail?: string;
|
|
41
|
+
/**
|
|
42
|
+
* Rainbow userId of the requester, when their support account carries one.
|
|
43
|
+
*
|
|
44
|
+
* The key to join a ticket back to a Rainbow user: unlike `requesterEmail` it is not
|
|
45
|
+
* gated on the caller's entitlements, and unlike `requesterName` it survives a rename.
|
|
46
|
+
*/
|
|
47
|
+
readonly requesterRainbowId?: string;
|
|
48
|
+
/**
|
|
49
|
+
* Display name of the admin who filed the ticket on the requester's behalf.
|
|
50
|
+
*
|
|
51
|
+
* Absent on a ticket a user filed for themselves, which is the common case.
|
|
52
|
+
*/
|
|
53
|
+
readonly createdByName?: string;
|
|
54
|
+
/** Rainbow userId of that admin, when the ticket was filed on behalf of someone. */
|
|
55
|
+
readonly createdByRainbowId?: string;
|
|
56
|
+
readonly tags: readonly string[];
|
|
57
|
+
/** `true` when the authenticated caller is the requester of this ticket. */
|
|
58
|
+
readonly isOwnTicket: boolean;
|
|
59
|
+
}
|
|
60
|
+
/**
|
|
61
|
+
* A comment on a ticket.
|
|
62
|
+
*
|
|
63
|
+
* Non-public comments are dropped by the backend, and `htmlBody` is sanitized
|
|
64
|
+
* server-side before being returned.
|
|
65
|
+
*/
|
|
66
|
+
export interface SupportComment {
|
|
67
|
+
readonly id: number;
|
|
68
|
+
/** Display name of the comment author. */
|
|
69
|
+
readonly authorName: string;
|
|
70
|
+
/**
|
|
71
|
+
* Rainbow userId of the author, when their support account carries one.
|
|
72
|
+
*
|
|
73
|
+
* Absent for support agents, who have no Rainbow account.
|
|
74
|
+
*/
|
|
75
|
+
readonly authorRainbowId?: string;
|
|
76
|
+
/** Sanitized HTML body. */
|
|
77
|
+
readonly htmlBody: string;
|
|
78
|
+
readonly public: boolean;
|
|
79
|
+
/** ISO 8601 creation date. */
|
|
80
|
+
readonly createdAt: string;
|
|
81
|
+
readonly attachments: readonly SupportAttachment[];
|
|
82
|
+
}
|
|
83
|
+
/** A ticket with its description and full comment thread, as returned by `getTicket`. */
|
|
84
|
+
export interface SupportTicketDetail extends SupportTicket {
|
|
85
|
+
readonly description: string;
|
|
86
|
+
readonly comments: readonly SupportComment[];
|
|
87
|
+
/**
|
|
88
|
+
* Display name of the support agent handling the ticket, when one is assigned.
|
|
89
|
+
*
|
|
90
|
+
* Resolved backend-side — the client never sees the underlying support-tool identifier.
|
|
91
|
+
*/
|
|
92
|
+
readonly assigneeName?: string;
|
|
93
|
+
}
|
|
94
|
+
/** A Help Center article matching a knowledge base search. */
|
|
95
|
+
export interface HelpCenterArticle {
|
|
96
|
+
readonly id: number;
|
|
97
|
+
readonly title: string;
|
|
98
|
+
/** Public URL of the article. */
|
|
99
|
+
readonly url: string;
|
|
100
|
+
/** Short excerpt highlighting the match. */
|
|
101
|
+
readonly snippet: string;
|
|
102
|
+
}
|
|
103
|
+
/** Technical context attached to a new ticket. */
|
|
104
|
+
export interface SupportDeviceInfo {
|
|
105
|
+
readonly application?: string;
|
|
106
|
+
readonly browser?: string;
|
|
107
|
+
readonly hardware?: string;
|
|
108
|
+
readonly os?: string;
|
|
109
|
+
readonly version?: string;
|
|
110
|
+
}
|
|
111
|
+
/**
|
|
112
|
+
* Payload of `createTicket`.
|
|
113
|
+
*
|
|
114
|
+
* The requester defaults to the authenticated user and cannot be set freely — the
|
|
115
|
+
* only way to file for someone else is `onBehalfOfRainbowUserId`, which the backend
|
|
116
|
+
* accepts from a company admin and rejects from anyone else.
|
|
117
|
+
*/
|
|
118
|
+
export interface CreateTicketPayload {
|
|
119
|
+
readonly subject: string;
|
|
120
|
+
readonly description: string;
|
|
121
|
+
readonly tags?: readonly string[];
|
|
122
|
+
/** When the problem happened, as entered by the user. */
|
|
123
|
+
readonly occurrenceDate?: string;
|
|
124
|
+
readonly deviceInfo?: SupportDeviceInfo;
|
|
125
|
+
/** Tokens returned by `uploadAttachment`. */
|
|
126
|
+
readonly attachmentTokens?: readonly string[];
|
|
127
|
+
/** Reference to a related internal ticket, when the ticket is an escalation. */
|
|
128
|
+
readonly internalTicketId?: string;
|
|
129
|
+
/**
|
|
130
|
+
* Rainbow userId of the user this ticket is filed for, when an admin files it
|
|
131
|
+
* on their behalf. Omit for the ordinary case of a user filing their own ticket.
|
|
132
|
+
*
|
|
133
|
+
* That user becomes the requester — the ticket lands in their own list and they
|
|
134
|
+
* can follow it, comment on it and attach files. The caller is added as a CC, so
|
|
135
|
+
* both sides see the thread.
|
|
136
|
+
*
|
|
137
|
+
* The backend enforces who may use this: the caller must be a company admin and
|
|
138
|
+
* the target must belong to their company, otherwise the call is rejected. The
|
|
139
|
+
* client-side gate is a convenience, never the guarantee.
|
|
140
|
+
*/
|
|
141
|
+
readonly onBehalfOfRainbowUserId?: string;
|
|
142
|
+
}
|
|
143
|
+
//# sourceMappingURL=support.model.d.ts.map
|