@tencent-rtc/mcp 1.0.9 → 1.1.8
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 +5 -1
- package/index.js +2 -0
- package/index.js.map +1 -1
- package/libs/TLSSigAPIv2.d.ts +134 -0
- package/libs/TLSSigAPIv2.js +243 -0
- package/package.json +1 -1
- package/resource/doc/chatuikit/react/chat_window_integration.md +95 -0
- package/resource/doc/chatuikit/react/integration.md +30 -18
- package/resource/doc/chatuikit/vue/chat_window_integration.md +155 -0
- package/resource/doc/chatuikit/vue/components/chat.md +8 -0
- package/resource/doc/chatuikit/vue/components/chatheader.md +1 -1
- package/resource/doc/chatuikit/vue/components/conversation-list.md +5 -0
- package/resource/doc/chatuikit/vue/components/message-input.md +4 -1
- package/resource/doc/chatuikit/vue/init.md +40 -0
- package/resource/doc/chatuikit/vue/integration.md +34 -74
- package/resource/doc/livekit/vue/components/barrage.md +616 -0
- package/resource/doc/livekit/vue/components/broadcast.md +595 -0
- package/resource/doc/livekit/vue/components/co-guest-panel.md +130 -0
- package/resource/doc/livekit/vue/components/live-audience-list.md +282 -0
- package/resource/doc/livekit/vue/components/live-list.md +200 -0
- package/resource/doc/livekit/vue/components/live-player.md +269 -0
- package/resource/doc/livekit/vue/components/live-scene-panel.md +175 -0
- package/resource/doc/livekit/vue/components/live-view.md +398 -0
- package/resource/doc/livekit/vue/components/stream-mixer.md +446 -0
- package/resource/doc/livekit/vue/states/live-state.md +3591 -0
- package/resource/doc/roomkit/vue/states/device-state.md +369 -0
- package/resource/doc/roomkit/vue/states/login-state.md +59 -0
- package/resource/doc/roomkit/vue/states/room-list-state.md +355 -0
- package/resource/doc/roomkit/vue/states/room-participant-state.md +388 -0
- package/resource/doc/tuicallkit/react/api.md +1383 -0
- package/resource/doc/tuicallkit/react/integration.md +101 -0
- package/resource/doc/tuicallkit/vue/api.md +1385 -0
- package/resource/doc/tuicallkit/vue/integration.md +98 -0
- package/server-config.js +35 -0
- package/server-config.js.map +1 -0
- package/tools/call/get-web-call-api.js +31 -0
- package/tools/call/get-web-call-api.js.map +1 -0
- package/tools/call/get-web-call-integration.js +8 -10
- package/tools/call/get-web-call-integration.js.map +1 -1
- package/tools/chat/get-chat-faq.js +3 -3
- package/tools/chat/get-chat-faq.js.map +1 -1
- package/tools/chat/get-native-chat-integration.js +4 -4
- package/tools/chat/get-web-chat-component-detail.js +4 -3
- package/tools/chat/get-web-chat-component-detail.js.map +1 -1
- package/tools/chat/get-web-chat-integration.js +9 -9
- package/tools/chat/get-web-chat-integration.js.map +1 -1
- package/tools/chat/{get-web-chat-uikit-login.js → get-web-chat-uikit-init.js} +7 -7
- package/tools/chat/get-web-chat-uikit-init.js.map +1 -0
- package/tools/chat/get-web-chat-window-integration.js +37 -0
- package/tools/chat/get-web-chat-window-integration.js.map +1 -0
- package/tools/common/get-official-experience-account.js +52 -0
- package/tools/common/get-official-experience-account.js.map +1 -0
- package/tools/common/get-usersig.js +31 -26
- package/tools/common/get-usersig.js.map +1 -1
- package/tools/common/present-framework-choice.js +1 -1
- package/tools/common/record-prompt.js +5 -5
- package/tools/common/record-result.js +8 -7
- package/tools/common/record-result.js.map +1 -1
- package/tools/index.js +28 -9
- package/tools/index.js.map +1 -1
- package/tools/live/get-web-live-component-detail.js +34 -0
- package/tools/live/get-web-live-component-detail.js.map +1 -0
- package/tools/live/get-web-live-state-detail.js +34 -0
- package/tools/live/get-web-live-state-detail.js.map +1 -0
- package/tools/room/get-web-room-state-detail.js +34 -0
- package/tools/room/get-web-room-state-detail.js.map +1 -0
- package/tools/rtcengine/get-rtcengine-web-sdk-integration-guide.js +35 -0
- package/tools/rtcengine/get-rtcengine-web-sdk-integration-guide.js.map +1 -0
- package/tools/rtcengine/{get-rtcenigne-faq.js → get-trtc-web-sdk-faq.js} +5 -5
- package/tools/rtcengine/get-trtc-web-sdk-faq.js.map +1 -0
- package/tools/rtcengine/get-trtc-web-sdk-integration-guide.js +36 -0
- package/tools/rtcengine/get-trtc-web-sdk-integration-guide.js.map +1 -0
- package/utils/generate-usersig.js +7 -9
- package/utils/generate-usersig.js.map +1 -1
- package/utils/handle-component-name.js +53 -8
- package/utils/handle-component-name.js.map +1 -1
- package/utils/handle-state-name.js +29 -0
- package/utils/handle-state-name.js.map +1 -0
- package/@tencent/aegis-node-sdk/CHANGELOG.md +0 -8
- package/@tencent/aegis-node-sdk/LICENSE +0 -21
- package/@tencent/aegis-node-sdk/README.md +0 -562
- package/@tencent/aegis-node-sdk/lib/aegis.min.js +0 -1
- package/@tencent/aegis-node-sdk/lib/packages/core/src/constant/config.d.ts +0 -14
- package/@tencent/aegis-node-sdk/lib/packages/core/src/constant/global.d.ts +0 -1
- package/@tencent/aegis-node-sdk/lib/packages/core/src/constant/index.d.ts +0 -9
- package/@tencent/aegis-node-sdk/lib/packages/core/src/constant/report-ignore.d.ts +0 -2
- package/@tencent/aegis-node-sdk/lib/packages/core/src/core.d.ts +0 -85
- package/@tencent/aegis-node-sdk/lib/packages/core/src/hooks/afterRequestHooks.d.ts +0 -3
- package/@tencent/aegis-node-sdk/lib/packages/core/src/hooks/beforeRequestHooks.d.ts +0 -9
- package/@tencent/aegis-node-sdk/lib/packages/core/src/hooks/modifyRequestHooks.d.ts +0 -3
- package/@tencent/aegis-node-sdk/lib/packages/core/src/index.d.ts +0 -9
- package/@tencent/aegis-node-sdk/lib/packages/core/src/interface/config.d.ts +0 -62
- package/@tencent/aegis-node-sdk/lib/packages/core/src/interface/env.d.ts +0 -11
- package/@tencent/aegis-node-sdk/lib/packages/core/src/interface/index.d.ts +0 -4
- package/@tencent/aegis-node-sdk/lib/packages/core/src/interface/log.d.ts +0 -130
- package/@tencent/aegis-node-sdk/lib/packages/core/src/interface/send.d.ts +0 -34
- package/@tencent/aegis-node-sdk/lib/packages/core/src/pipes/format.d.ts +0 -2
- package/@tencent/aegis-node-sdk/lib/packages/core/src/pipes/index.d.ts +0 -18
- package/@tencent/aegis-node-sdk/lib/packages/core/src/pipes/length-limit.d.ts +0 -8
- package/@tencent/aegis-node-sdk/lib/packages/core/src/pipes/pv.d.ts +0 -8
- package/@tencent/aegis-node-sdk/lib/packages/core/src/pipes/remove-payload.d.ts +0 -2
- package/@tencent/aegis-node-sdk/lib/packages/core/src/pipes/repeat-limit.d.ts +0 -4
- package/@tencent/aegis-node-sdk/lib/packages/core/src/pipes/report.d.ts +0 -10
- package/@tencent/aegis-node-sdk/lib/packages/core/src/pipes/sample.d.ts +0 -3
- package/@tencent/aegis-node-sdk/lib/packages/core/src/pipes/throttle.d.ts +0 -3
- package/@tencent/aegis-node-sdk/lib/packages/core/src/pipes/trace/index.d.ts +0 -34
- package/@tencent/aegis-node-sdk/lib/packages/core/src/pipes/trace/jwt.d.ts +0 -12
- package/@tencent/aegis-node-sdk/lib/packages/core/src/pipes/trace/ot-js.d.ts +0 -14
- package/@tencent/aegis-node-sdk/lib/packages/core/src/pipes/trace/uuid.d.ts +0 -2
- package/@tencent/aegis-node-sdk/lib/packages/core/src/pipes/whitelist.d.ts +0 -12
- package/@tencent/aegis-node-sdk/lib/packages/core/src/pipes/write-before.d.ts +0 -3
- package/@tencent/aegis-node-sdk/lib/packages/core/src/plugin.d.ts +0 -33
- package/@tencent/aegis-node-sdk/lib/packages/core/src/polyfill.d.ts +0 -0
- package/@tencent/aegis-node-sdk/lib/packages/core/src/util/destroy.d.ts +0 -2
- package/@tencent/aegis-node-sdk/lib/packages/core/src/util/event-emitter.d.ts +0 -18
- package/@tencent/aegis-node-sdk/lib/packages/core/src/util/index.d.ts +0 -60
- package/@tencent/aegis-node-sdk/lib/packages/node-sdk/src/index.d.ts +0 -15
- package/@tencent/aegis-node-sdk/lib/packages/node-sdk/src/interface/selector.d.ts +0 -5
- package/@tencent/aegis-node-sdk/lib/packages/node-sdk/src/pipes/batch-report-pipe.d.ts +0 -6
- package/@tencent/aegis-node-sdk/lib/packages/node-sdk/src/protocol/protocol_base.d.ts +0 -18
- package/@tencent/aegis-node-sdk/lib/packages/node-sdk/src/protocol/protocol_http.d.ts +0 -12
- package/@tencent/aegis-node-sdk/lib/packages/node-sdk/src/selector/ip_selector.d.ts +0 -10
- package/@tencent/aegis-node-sdk/lib/packages/node-sdk/src/selector/polaris_selector.d.ts +0 -20
- package/@tencent/aegis-node-sdk/lib/packages/node-sdk/src/selector/selector_base.d.ts +0 -27
- package/@tencent/aegis-node-sdk/lib/packages/node-sdk/src/util/eval_require.d.ts +0 -2
- package/@tencent/aegis-node-sdk/package.json +0 -19
- package/@tencent/polaris/README.md +0 -407
- package/@tencent/polaris/dist/consumer/health.d.ts +0 -126
- package/@tencent/polaris/dist/consumer/health.js +0 -283
- package/@tencent/polaris/dist/consumer/health.js.map +0 -1
- package/@tencent/polaris/dist/consumer/index.d.ts +0 -120
- package/@tencent/polaris/dist/consumer/index.js +0 -348
- package/@tencent/polaris/dist/consumer/index.js.map +0 -1
- package/@tencent/polaris/dist/consumer/monitor.d.ts +0 -145
- package/@tencent/polaris/dist/consumer/monitor.js +0 -343
- package/@tencent/polaris/dist/consumer/monitor.js.map +0 -1
- package/@tencent/polaris/dist/consumer/selector.d.ts +0 -73
- package/@tencent/polaris/dist/consumer/selector.js +0 -316
- package/@tencent/polaris/dist/consumer/selector.js.map +0 -1
- package/@tencent/polaris/dist/errors.d.ts +0 -373
- package/@tencent/polaris/dist/errors.js +0 -154
- package/@tencent/polaris/dist/errors.js.map +0 -1
- package/@tencent/polaris/dist/global.d.ts +0 -16
- package/@tencent/polaris/dist/global.js +0 -18
- package/@tencent/polaris/dist/global.js.map +0 -1
- package/@tencent/polaris/dist/index.d.ts +0 -62
- package/@tencent/polaris/dist/index.js +0 -145
- package/@tencent/polaris/dist/index.js.map +0 -1
- package/@tencent/polaris/dist/instance.d.ts +0 -109
- package/@tencent/polaris/dist/instance.js +0 -38
- package/@tencent/polaris/dist/instance.js.map +0 -1
- package/@tencent/polaris/dist/limiter/bucket.d.ts +0 -51
- package/@tencent/polaris/dist/limiter/bucket.js +0 -152
- package/@tencent/polaris/dist/limiter/bucket.js.map +0 -1
- package/@tencent/polaris/dist/limiter/index.d.ts +0 -73
- package/@tencent/polaris/dist/limiter/index.js +0 -149
- package/@tencent/polaris/dist/limiter/index.js.map +0 -1
- package/@tencent/polaris/dist/limiter/ratelimit.d.ts +0 -27
- package/@tencent/polaris/dist/limiter/ratelimit.js +0 -134
- package/@tencent/polaris/dist/limiter/ratelimit.js.map +0 -1
- package/@tencent/polaris/dist/limiter/ratelimiter/base.d.ts +0 -17
- package/@tencent/polaris/dist/limiter/ratelimiter/base.js +0 -15
- package/@tencent/polaris/dist/limiter/ratelimiter/base.js.map +0 -1
- package/@tencent/polaris/dist/limiter/ratelimiter/global.d.ts +0 -59
- package/@tencent/polaris/dist/limiter/ratelimiter/global.js +0 -397
- package/@tencent/polaris/dist/limiter/ratelimiter/global.js.map +0 -1
- package/@tencent/polaris/dist/limiter/ratelimiter/index.d.ts +0 -3
- package/@tencent/polaris/dist/limiter/ratelimiter/index.js +0 -19
- package/@tencent/polaris/dist/limiter/ratelimiter/index.js.map +0 -1
- package/@tencent/polaris/dist/limiter/ratelimiter/local.d.ts +0 -17
- package/@tencent/polaris/dist/limiter/ratelimiter/local.js +0 -52
- package/@tencent/polaris/dist/limiter/ratelimiter/local.js.map +0 -1
- package/@tencent/polaris/dist/location.d.ts +0 -48
- package/@tencent/polaris/dist/location.js +0 -67
- package/@tencent/polaris/dist/location.js.map +0 -1
- package/@tencent/polaris/dist/logging.d.ts +0 -106
- package/@tencent/polaris/dist/logging.js +0 -130
- package/@tencent/polaris/dist/logging.js.map +0 -1
- package/@tencent/polaris/dist/metadata.d.ts +0 -78
- package/@tencent/polaris/dist/metadata.js +0 -119
- package/@tencent/polaris/dist/metadata.js.map +0 -1
- package/@tencent/polaris/dist/plugins/breaker/polaris.d.ts +0 -47
- package/@tencent/polaris/dist/plugins/breaker/polaris.js +0 -162
- package/@tencent/polaris/dist/plugins/breaker/polaris.js.map +0 -1
- package/@tencent/polaris/dist/plugins/lb/base.d.ts +0 -24
- package/@tencent/polaris/dist/plugins/lb/base.js +0 -32
- package/@tencent/polaris/dist/plugins/lb/base.js.map +0 -1
- package/@tencent/polaris/dist/plugins/lb/edf.d.ts +0 -24
- package/@tencent/polaris/dist/plugins/lb/edf.js +0 -77
- package/@tencent/polaris/dist/plugins/lb/edf.js.map +0 -1
- package/@tencent/polaris/dist/plugins/lb/hashring.d.ts +0 -24
- package/@tencent/polaris/dist/plugins/lb/hashring.js +0 -53
- package/@tencent/polaris/dist/plugins/lb/hashring.js.map +0 -1
- package/@tencent/polaris/dist/plugins/lb/sticky.d.ts +0 -31
- package/@tencent/polaris/dist/plugins/lb/sticky.js +0 -88
- package/@tencent/polaris/dist/plugins/lb/sticky.js.map +0 -1
- package/@tencent/polaris/dist/plugins/lb/swrr.d.ts +0 -25
- package/@tencent/polaris/dist/plugins/lb/swrr.js +0 -72
- package/@tencent/polaris/dist/plugins/lb/swrr.js.map +0 -1
- package/@tencent/polaris/dist/plugins/lb/wr.d.ts +0 -17
- package/@tencent/polaris/dist/plugins/lb/wr.js +0 -50
- package/@tencent/polaris/dist/plugins/lb/wr.js.map +0 -1
- package/@tencent/polaris/dist/plugins/lb/wrr.d.ts +0 -19
- package/@tencent/polaris/dist/plugins/lb/wrr.js +0 -81
- package/@tencent/polaris/dist/plugins/lb/wrr.js.map +0 -1
- package/@tencent/polaris/dist/plugins/logging/console.d.ts +0 -10
- package/@tencent/polaris/dist/plugins/logging/console.js +0 -38
- package/@tencent/polaris/dist/plugins/logging/console.js.map +0 -1
- package/@tencent/polaris/dist/plugins/naming/local-server/index.d.ts +0 -32
- package/@tencent/polaris/dist/plugins/naming/local-server/index.js +0 -88
- package/@tencent/polaris/dist/plugins/naming/local-server/index.js.map +0 -1
- package/@tencent/polaris/dist/plugins/naming/polaris-server/adapter/base.d.ts +0 -124
- package/@tencent/polaris/dist/plugins/naming/polaris-server/adapter/base.js +0 -398
- package/@tencent/polaris/dist/plugins/naming/polaris-server/adapter/base.js.map +0 -1
- package/@tencent/polaris/dist/plugins/naming/polaris-server/adapter/discover.d.ts +0 -27
- package/@tencent/polaris/dist/plugins/naming/polaris-server/adapter/discover.js +0 -287
- package/@tencent/polaris/dist/plugins/naming/polaris-server/adapter/discover.js.map +0 -1
- package/@tencent/polaris/dist/plugins/naming/polaris-server/adapter/index.d.ts +0 -15
- package/@tencent/polaris/dist/plugins/naming/polaris-server/adapter/index.js +0 -43
- package/@tencent/polaris/dist/plugins/naming/polaris-server/adapter/index.js.map +0 -1
- package/@tencent/polaris/dist/plugins/naming/polaris-server/adapter/monitor.d.ts +0 -28
- package/@tencent/polaris/dist/plugins/naming/polaris-server/adapter/monitor.js +0 -249
- package/@tencent/polaris/dist/plugins/naming/polaris-server/adapter/monitor.js.map +0 -1
- package/@tencent/polaris/dist/plugins/naming/polaris-server/adapter/ratelimit.d.ts +0 -19
- package/@tencent/polaris/dist/plugins/naming/polaris-server/adapter/ratelimit.js +0 -222
- package/@tencent/polaris/dist/plugins/naming/polaris-server/adapter/ratelimit.js.map +0 -1
- package/@tencent/polaris/dist/plugins/naming/polaris-server/connector/grpc/bidi.d.ts +0 -26
- package/@tencent/polaris/dist/plugins/naming/polaris-server/connector/grpc/bidi.js +0 -99
- package/@tencent/polaris/dist/plugins/naming/polaris-server/connector/grpc/bidi.js.map +0 -1
- package/@tencent/polaris/dist/plugins/naming/polaris-server/connector/grpc/index.d.ts +0 -60
- package/@tencent/polaris/dist/plugins/naming/polaris-server/connector/grpc/index.js +0 -259
- package/@tencent/polaris/dist/plugins/naming/polaris-server/connector/grpc/index.js.map +0 -1
- package/@tencent/polaris/dist/plugins/naming/polaris-server/connector/grpc/pb/discover.proto +0 -24
- package/@tencent/polaris/dist/plugins/naming/polaris-server/connector/grpc/pb/monitor.proto +0 -18
- package/@tencent/polaris/dist/plugins/naming/polaris-server/connector/grpc/pb/ratelimit.proto +0 -12
- package/@tencent/polaris/dist/plugins/naming/polaris-server/connector/http/index.d.ts +0 -39
- package/@tencent/polaris/dist/plugins/naming/polaris-server/connector/http/index.js +0 -115
- package/@tencent/polaris/dist/plugins/naming/polaris-server/connector/http/index.js.map +0 -1
- package/@tencent/polaris/dist/plugins/naming/polaris-server/discover-pb/api.proto +0 -24
- package/@tencent/polaris/dist/plugins/naming/polaris-server/discover-pb/client.proto +0 -22
- package/@tencent/polaris/dist/plugins/naming/polaris-server/discover-pb/model.proto +0 -28
- package/@tencent/polaris/dist/plugins/naming/polaris-server/discover-pb/ratelimit.proto +0 -80
- package/@tencent/polaris/dist/plugins/naming/polaris-server/discover-pb/request.proto +0 -18
- package/@tencent/polaris/dist/plugins/naming/polaris-server/discover-pb/response.proto +0 -65
- package/@tencent/polaris/dist/plugins/naming/polaris-server/discover-pb/routing.proto +0 -66
- package/@tencent/polaris/dist/plugins/naming/polaris-server/discover-pb/service.proto +0 -95
- package/@tencent/polaris/dist/plugins/naming/polaris-server/discover-pb/types.d.ts +0 -1568
- package/@tencent/polaris/dist/plugins/naming/polaris-server/index.d.ts +0 -36
- package/@tencent/polaris/dist/plugins/naming/polaris-server/index.js +0 -51
- package/@tencent/polaris/dist/plugins/naming/polaris-server/index.js.map +0 -1
- package/@tencent/polaris/dist/plugins/naming/polaris-server/monitor-pb/api.proto +0 -18
- package/@tencent/polaris/dist/plugins/naming/polaris-server/monitor-pb/circuitbreak.proto +0 -67
- package/@tencent/polaris/dist/plugins/naming/polaris-server/monitor-pb/request.proto +0 -82
- package/@tencent/polaris/dist/plugins/naming/polaris-server/monitor-pb/response.proto +0 -11
- package/@tencent/polaris/dist/plugins/naming/polaris-server/monitor-pb/sdkcache.proto +0 -46
- package/@tencent/polaris/dist/plugins/naming/polaris-server/monitor-pb/sdkconfiguration.proto +0 -16
- package/@tencent/polaris/dist/plugins/naming/polaris-server/monitor-pb/sdktoken.proto +0 -10
- package/@tencent/polaris/dist/plugins/naming/polaris-server/monitor-pb/types.d.ts +0 -1102
- package/@tencent/polaris/dist/plugins/naming/polaris-server/pool.d.ts +0 -29
- package/@tencent/polaris/dist/plugins/naming/polaris-server/pool.js +0 -77
- package/@tencent/polaris/dist/plugins/naming/polaris-server/pool.js.map +0 -1
- package/@tencent/polaris/dist/plugins/naming/polaris-server/ratelimit-pb/api.proto +0 -12
- package/@tencent/polaris/dist/plugins/naming/polaris-server/ratelimit-pb/ratelimit.proto +0 -28
- package/@tencent/polaris/dist/plugins/naming/polaris-server/ratelimit-pb/types.d.ts +0 -395
- package/@tencent/polaris/dist/plugins/naming/polaris-server/rules.d.ts +0 -13
- package/@tencent/polaris/dist/plugins/naming/polaris-server/rules.js +0 -116
- package/@tencent/polaris/dist/plugins/naming/polaris-server/rules.js.map +0 -1
- package/@tencent/polaris/dist/plugins/naming/polaris-server/types.d.ts +0 -67
- package/@tencent/polaris/dist/plugins/naming/polaris-server/types.js +0 -67
- package/@tencent/polaris/dist/plugins/naming/polaris-server/types.js.map +0 -1
- package/@tencent/polaris/dist/plugins/naming/polaris-server/utils.d.ts +0 -99
- package/@tencent/polaris/dist/plugins/naming/polaris-server/utils.js +0 -217
- package/@tencent/polaris/dist/plugins/naming/polaris-server/utils.js.map +0 -1
- package/@tencent/polaris/dist/plugins/registry/memory.d.ts +0 -10
- package/@tencent/polaris/dist/plugins/registry/memory.js +0 -50
- package/@tencent/polaris/dist/plugins/registry/memory.js.map +0 -1
- package/@tencent/polaris/dist/plugins/router/polaris/nearby.d.ts +0 -51
- package/@tencent/polaris/dist/plugins/router/polaris/nearby.js +0 -145
- package/@tencent/polaris/dist/plugins/router/polaris/nearby.js.map +0 -1
- package/@tencent/polaris/dist/plugins/router/polaris/rule.d.ts +0 -11
- package/@tencent/polaris/dist/plugins/router/polaris/rule.js +0 -174
- package/@tencent/polaris/dist/plugins/router/polaris/rule.js.map +0 -1
- package/@tencent/polaris/dist/plugins/router/trpc/canary.d.ts +0 -25
- package/@tencent/polaris/dist/plugins/router/trpc/canary.js +0 -36
- package/@tencent/polaris/dist/plugins/router/trpc/canary.js.map +0 -1
- package/@tencent/polaris/dist/plugins/router/trpc/env.d.ts +0 -10
- package/@tencent/polaris/dist/plugins/router/trpc/env.js +0 -34
- package/@tencent/polaris/dist/plugins/router/trpc/env.js.map +0 -1
- package/@tencent/polaris/dist/plugins/router/trpc/set.d.ts +0 -56
- package/@tencent/polaris/dist/plugins/router/trpc/set.js +0 -106
- package/@tencent/polaris/dist/plugins/router/trpc/set.js.map +0 -1
- package/@tencent/polaris/dist/plugins/shaping/unirate.d.ts +0 -31
- package/@tencent/polaris/dist/plugins/shaping/unirate.js +0 -124
- package/@tencent/polaris/dist/plugins/shaping/unirate.js.map +0 -1
- package/@tencent/polaris/dist/plugins/shaping/warmup.d.ts +0 -61
- package/@tencent/polaris/dist/plugins/shaping/warmup.js +0 -171
- package/@tencent/polaris/dist/plugins/shaping/warmup.js.map +0 -1
- package/@tencent/polaris/dist/plugins/weight/polaris.d.ts +0 -23
- package/@tencent/polaris/dist/plugins/weight/polaris.js +0 -159
- package/@tencent/polaris/dist/plugins/weight/polaris.js.map +0 -1
- package/@tencent/polaris/dist/plugins.d.ts +0 -619
- package/@tencent/polaris/dist/plugins.js +0 -91
- package/@tencent/polaris/dist/plugins.js.map +0 -1
- package/@tencent/polaris/dist/polaris.d.ts +0 -33
- package/@tencent/polaris/dist/polaris.js +0 -59
- package/@tencent/polaris/dist/polaris.js.map +0 -1
- package/@tencent/polaris/dist/provider/index.d.ts +0 -102
- package/@tencent/polaris/dist/provider/index.js +0 -168
- package/@tencent/polaris/dist/provider/index.js.map +0 -1
- package/@tencent/polaris/dist/registry.d.ts +0 -174
- package/@tencent/polaris/dist/registry.js +0 -660
- package/@tencent/polaris/dist/registry.js.map +0 -1
- package/@tencent/polaris/dist/rules.d.ts +0 -163
- package/@tencent/polaris/dist/rules.js +0 -24
- package/@tencent/polaris/dist/rules.js.map +0 -1
- package/@tencent/polaris/dist/scripts/postinstall.d.ts +0 -1
- package/@tencent/polaris/dist/scripts/postinstall.js +0 -71
- package/@tencent/polaris/dist/scripts/postinstall.js.map +0 -1
- package/@tencent/polaris/dist/service.d.ts +0 -18
- package/@tencent/polaris/dist/service.js +0 -3
- package/@tencent/polaris/dist/service.js.map +0 -1
- package/@tencent/polaris/dist/skeleton.d.ts +0 -87
- package/@tencent/polaris/dist/skeleton.js +0 -282
- package/@tencent/polaris/dist/skeleton.js.map +0 -1
- package/@tencent/polaris/dist/utils.d.ts +0 -36
- package/@tencent/polaris/dist/utils.js +0 -74
- package/@tencent/polaris/dist/utils.js.map +0 -1
- package/@tencent/polaris/dist/weak.d.ts +0 -11
- package/@tencent/polaris/dist/weak.js +0 -44
- package/@tencent/polaris/dist/weak.js.map +0 -1
- package/@tencent/polaris/package.json +0 -114
- package/libs/lib-generate-test-usersig-es.min.d.ts +0 -6
- package/libs/lib-generate-test-usersig-es.min.js +0 -2
- package/resource/doc/chatuikit/react/generate_UserSig.md +0 -306
- package/resource/doc/chatuikit/react/integrate_tuichat_only_react.md +0 -202
- package/resource/doc/chatuikit/react/integrate_tuichat_react.md +0 -279
- package/resource/doc/chatuikit/vue/generate_UserSig.md +0 -306
- package/resource/doc/chatuikit/vue/integrate_only_tuichat_Vue_web.md +0 -124
- package/resource/doc/chatuikit/vue/integrate_tuikit_Vue_web.md +0 -552
- package/resource/doc/chatuikit/vue/login.md +0 -31
- package/resource/doc/chatuikit/vue3/components/MessageInput.md +0 -1272
- package/resource/doc/chatuikit/vue3/components/avatar.md +0 -137
- package/resource/doc/chatuikit/vue3/components/chatheader.md +0 -189
- package/resource/doc/chatuikit/vue3/components/component-list.md +0 -102
- package/resource/doc/chatuikit/vue3/components/userpicker.md +0 -315
- package/resource/doc/chatuikit/vue3/integration.md +0 -256
- package/resource/doc/tuicallkit/react/.gitkeep +0 -0
- package/resource/doc/tuicallkit/react/api_TUICallKit.md +0 -354
- package/resource/doc/tuicallkit/react/how_to_integrated_react_callkit.md +0 -195
- package/resource/doc/tuicallkit/react/how_to_run_react_callkit_demo.md +0 -61
- package/resource/doc/tuicallkit/vue/.gitkeep +0 -0
- package/resource/doc/tuicallkit/vue/api_TUICallKit.md +0 -354
- package/resource/doc/tuicallkit/vue/how_to_integrated_vue_callkit.md +0 -187
- package/resource/doc/tuicallkit/vue/how_to_run_vue_callkit_demo.md +0 -61
- package/streamableHttp.js +0 -74
- package/streamableHttp.js.map +0 -1
- package/tools/call/get-native-call-integration-guide.js +0 -36
- package/tools/call/get-native-call-integration-guide.js.map +0 -1
- package/tools/call/get-web-call-integration-guide.js +0 -35
- package/tools/call/get-web-call-integration-guide.js.map +0 -1
- package/tools/chat/get-native-chat-integration-guide.js +0 -34
- package/tools/chat/get-native-chat-integration-guide.js.map +0 -1
- package/tools/chat/get-web-chat-integration-guide.js +0 -35
- package/tools/chat/get-web-chat-integration-guide.js.map +0 -1
- package/tools/chat/get-web-chat-uikit-login.js.map +0 -1
- package/tools/rtcengine/get-rtcengine-integration-guide.js +0 -33
- package/tools/rtcengine/get-rtcengine-integration-guide.js.map +0 -1
- package/tools/rtcengine/get-rtcenigne-faq.js.map +0 -1
- /package/resource/doc/chatuikit/react/{login.md → init.md} +0 -0
|
@@ -1,306 +0,0 @@
|
|
|
1
|
-
This document outlines two authentication methods for Chat services, with a focus on UserSig, a security signature by Tencent Cloud to safeguard against unauthorized access. For basic cloud service usage, provide SDKAppID, UserID, and UserSig during SDK initialization or login.
|
|
2
|
-
- SDKAppID is used to identify your application.
|
|
3
|
-
|
|
4
|
-
- UserID is used to identify your user.
|
|
5
|
-
|
|
6
|
-
- UserSig is a security signature calculated based on the first two using the HMAC SHA256 encryption algorithm. As long as attackers cannot forge the UserSig, they cannot steal your cloud service traffic.
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
## Obtaining a Key
|
|
10
|
-
1. Log in to the [Chat console](https://console.trtc.io/chat).
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
> **Note: **
|
|
14
|
-
>
|
|
15
|
-
|
|
16
|
-
> If you do not have any app, [create an app](https://intl.cloud.tencent.com/document/product/1047/45914) and then perform [step 2](https://write.woa.com/#step2).
|
|
17
|
-
>
|
|
18
|
-
|
|
19
|
-
2. Click the target app card to go to its basic configuration page.
|
|
20
|
-
|
|
21
|
-
3. In the **Basic Information** section, click **Display key** to the right of **Key**.
|
|
22
|
-
|
|
23
|
-

|
|
24
|
-
|
|
25
|
-
4. Click **Copy** to copy and save the key information.
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
> **Note: **
|
|
29
|
-
>
|
|
30
|
-
|
|
31
|
-
> Store the key information properly to prevent disclosure.
|
|
32
|
-
>
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
## Calculating UserSig on the Client
|
|
36
|
-
|
|
37
|
-
The `GenerateTestUserSig` open-source module provided in the sample code of the Chat SDK can help you quickly generate a UserSig. You only need to configure three member variables, including SDKAPPID (SDKAppID of the app), EXPIRETIME (UserSig expiration time), and SECRETKEY (key information), and then call the genTestUserSig() function to quickly obtain a UserSig.
|
|
38
|
-
|
|
39
|
-
To simplify this process, we provide the source code for computing a UserSig for the following languages and platforms. You can directly download and integrate the source code into your client.
|
|
40
|
-
<table>
|
|
41
|
-
<tr>
|
|
42
|
-
<td rowspan="1" colSpan="1" >Programing Language</td>
|
|
43
|
-
|
|
44
|
-
<td rowspan="1" colSpan="1" >Platform</td>
|
|
45
|
-
|
|
46
|
-
<td rowspan="1" colSpan="1" >GenerateTestUserSig Source Code</td>
|
|
47
|
-
</tr>
|
|
48
|
-
|
|
49
|
-
<tr>
|
|
50
|
-
<td rowspan="1" colSpan="1" >Java</td>
|
|
51
|
-
|
|
52
|
-
<td rowspan="1" colSpan="1" >Android</td>
|
|
53
|
-
|
|
54
|
-
<td rowspan="1" colSpan="1" >[GenerateTestUserSig.java](https://github.com/tencentyun/TIMSDK/blob/master/Android/Demo/app/src/main/java/com/tencent/qcloud/tim/demo/signature/GenerateTestUserSig.java)</td>
|
|
55
|
-
</tr>
|
|
56
|
-
|
|
57
|
-
<tr>
|
|
58
|
-
<td rowspan="1" colSpan="1" >Objective-C</td>
|
|
59
|
-
|
|
60
|
-
<td rowspan="1" colSpan="1" >iOS</td>
|
|
61
|
-
|
|
62
|
-
<td rowspan="1" colSpan="1" >[GenerateTestUserSig.h](https://github.com/tencentyun/TIMSDK/blob/master/iOS/Demo/TUIKitDemo/Private/GenerateTestUserSig.h)</td>
|
|
63
|
-
</tr>
|
|
64
|
-
|
|
65
|
-
<tr>
|
|
66
|
-
<td rowspan="1" colSpan="1" >Objective-C</td>
|
|
67
|
-
|
|
68
|
-
<td rowspan="1" colSpan="1" >Mac</td>
|
|
69
|
-
|
|
70
|
-
<td rowspan="1" colSpan="1" >[GenerateTestUserSig.h](https://github.com/tencentyun/TIMSDK/blob/master/Mac/Demo/TUIKitDemo/Debug/GenerateTestUserSig.h)</td>
|
|
71
|
-
</tr>
|
|
72
|
-
|
|
73
|
-
<tr>
|
|
74
|
-
<td rowspan="1" colSpan="1" >C++</td>
|
|
75
|
-
|
|
76
|
-
<td rowspan="1" colSpan="1" >Windows</td>
|
|
77
|
-
|
|
78
|
-
<td rowspan="1" colSpan="1" >[GenerateTestUserSig.h](https://github.com/tencentyun/TIMSDK/blob/master/Windows/Demo/IMApp/GenerateTestUserSig.h)</td>
|
|
79
|
-
</tr>
|
|
80
|
-
|
|
81
|
-
<tr>
|
|
82
|
-
<td rowspan="1" colSpan="1" >Javascript</td>
|
|
83
|
-
|
|
84
|
-
<td rowspan="1" colSpan="1" >Web</td>
|
|
85
|
-
|
|
86
|
-
<td rowspan="1" colSpan="1" >[GenerateTestUserSig.js](https://github.com/TencentCloud/chat-uikit-uniapp/blob/main/TUIKit/debug/GenerateTestUserSig.js)</td>
|
|
87
|
-
</tr>
|
|
88
|
-
|
|
89
|
-
<tr>
|
|
90
|
-
<td rowspan="1" colSpan="1" >Dart</td>
|
|
91
|
-
|
|
92
|
-
<td rowspan="1" colSpan="1" >Flutter</td>
|
|
93
|
-
|
|
94
|
-
<td rowspan="1" colSpan="1" >[GenerateTestUserSig.dart](https://github.com/TencentCloud/chat-demo-flutter/blob/main/lib/utils/GenerateTestUserSig.dart )</td>
|
|
95
|
-
</tr>
|
|
96
|
-
</table>
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
> **Note: **
|
|
100
|
-
>
|
|
101
|
-
|
|
102
|
-
> In this method, the `SECRETKEY` is vulnerable to decompilation and reverse engineering. Once your `SECRETKEY` is disclosed, attackers can steal your Tencent Cloud traffic. Therefore, **this method is only suitable for locally running a demo project and feature debugging**.
|
|
103
|
-
The correct way to issue a UserSig is to integrate the UserSig computing code into your server and provide app-oriented APIs. When UserSig is needed, your app will send a request to the business server to obtain a dynamic UserSig. For more information, see [How to Calculate UserSig](https://write.woa.com/#GeneratingdynamicUserSig).
|
|
104
|
-
>
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
## Calculating UserSig on the Server
|
|
108
|
-
|
|
109
|
-
Generating a UserSig on the server provides maximum protection against the disclosure of the key used for calculating the UserSig. You only need to deploy the code for calculating the UserSig on your server and provide an app-oriented API. When a UserSig is needed, your app will send a request to the business server to obtain a dynamic UserSig.
|
|
110
|
-
To simplify this process, we provide the source code for calculating a UserSig for the following languages and platforms. You can directly download and integrate the source code into your server.
|
|
111
|
-
<table>
|
|
112
|
-
<tr>
|
|
113
|
-
<td rowspan="1" colSpan="1" >Programming Language</td>
|
|
114
|
-
|
|
115
|
-
<td rowspan="1" colSpan="1" >Key Function</td>
|
|
116
|
-
|
|
117
|
-
<td rowspan="1" colSpan="1" >Download URL</td>
|
|
118
|
-
</tr>
|
|
119
|
-
|
|
120
|
-
<tr>
|
|
121
|
-
<td rowspan="1" colSpan="1" >Java</td>
|
|
122
|
-
|
|
123
|
-
<td rowspan="1" colSpan="1" >HMAC-SHA256</td>
|
|
124
|
-
|
|
125
|
-
<td rowspan="1" colSpan="1" >[genSig](https://github.com/Tencent-RTC/tls-sig-api-v2-java/blob/main/src/main/java/com/tencentcloud/TLSSigAPIv2.java)</td>
|
|
126
|
-
</tr>
|
|
127
|
-
|
|
128
|
-
<tr>
|
|
129
|
-
<td rowspan="1" colSpan="1" >GO</td>
|
|
130
|
-
|
|
131
|
-
<td rowspan="1" colSpan="1" >HMAC-SHA256</td>
|
|
132
|
-
|
|
133
|
-
<td rowspan="1" colSpan="1" >[GenSig](https://github.com/Tencent-RTC/tls-sig-api-v2-golang/blob/main/tencentyun/TLSSigAPI.go)</td>
|
|
134
|
-
</tr>
|
|
135
|
-
|
|
136
|
-
<tr>
|
|
137
|
-
<td rowspan="1" colSpan="1" >PHP</td>
|
|
138
|
-
|
|
139
|
-
<td rowspan="1" colSpan="1" >HMAC-SHA256</td>
|
|
140
|
-
|
|
141
|
-
<td rowspan="1" colSpan="1" >[genSig](https://github.com/Tencent-RTC/tls-sig-api-v2-php/blob/main/src/TLSSigAPIv2.php)</td>
|
|
142
|
-
</tr>
|
|
143
|
-
|
|
144
|
-
<tr>
|
|
145
|
-
<td rowspan="1" colSpan="1" >Nodejs</td>
|
|
146
|
-
|
|
147
|
-
<td rowspan="1" colSpan="1" >HMAC-SHA256</td>
|
|
148
|
-
|
|
149
|
-
<td rowspan="1" colSpan="1" >[genSig](https://github.com/Tencent-RTC/tls-sig-api-v2-node/blob/main/TLSSigAPIv2.js)</td>
|
|
150
|
-
</tr>
|
|
151
|
-
|
|
152
|
-
<tr>
|
|
153
|
-
<td rowspan="1" colSpan="1" >Python</td>
|
|
154
|
-
|
|
155
|
-
<td rowspan="1" colSpan="1" >HMAC-SHA256</td>
|
|
156
|
-
|
|
157
|
-
<td rowspan="1" colSpan="1" >[gen_sig](https://github.com/Tencent-RTC/tls-sig-api-v2-python/blob/main/TLSSigAPIv2.py)</td>
|
|
158
|
-
</tr>
|
|
159
|
-
|
|
160
|
-
<tr>
|
|
161
|
-
<td rowspan="1" colSpan="1" >C#</td>
|
|
162
|
-
|
|
163
|
-
<td rowspan="1" colSpan="1" >HMAC-SHA256</td>
|
|
164
|
-
|
|
165
|
-
<td rowspan="1" colSpan="1" >[GenSig](https://github.com/Tencent-RTC/tls-sig-api-v2-cs/blob/main/tls-sig-api-v2-cs/TLSSigAPIv2.cs)</td>
|
|
166
|
-
</tr>
|
|
167
|
-
|
|
168
|
-
<tr>
|
|
169
|
-
<td rowspan="1" colSpan="1" >C++</td>
|
|
170
|
-
|
|
171
|
-
<td rowspan="1" colSpan="1" >HMAC-SHA256</td>
|
|
172
|
-
|
|
173
|
-
<td rowspan="1" colSpan="1" >[gen_sig](https://github.com/Tencent-RTC/tls-sig-api-v2-cpp)</td>
|
|
174
|
-
</tr>
|
|
175
|
-
</table>
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
Key fields in a UserSig calculation function include the SDKAppID, UserID, and UserSig validity period, as described in the following table.
|
|
179
|
-
|
|
180
|
-
> **Note: **
|
|
181
|
-
>
|
|
182
|
-
|
|
183
|
-
> The following table uses the field names in the Java source code as an example. The field names may be different in other languages.
|
|
184
|
-
>
|
|
185
|
-
|
|
186
|
-
<table>
|
|
187
|
-
<tr>
|
|
188
|
-
<td rowspan="1" colSpan="1" >Field Name (Example)</td>
|
|
189
|
-
|
|
190
|
-
<td rowspan="1" colSpan="1" >Description</td>
|
|
191
|
-
</tr>
|
|
192
|
-
|
|
193
|
-
<tr>
|
|
194
|
-
<td rowspan="1" colSpan="1" >sdkappid</td>
|
|
195
|
-
|
|
196
|
-
<td rowspan="1" colSpan="1" >SDKAppID of the app. You can obtain the SDKAppID on the app card in the [Chat console](https://console.trtc.io/chat).</td>
|
|
197
|
-
</tr>
|
|
198
|
-
|
|
199
|
-
<tr>
|
|
200
|
-
<td rowspan="1" colSpan="1" >userId</td>
|
|
201
|
-
|
|
202
|
-
<td rowspan="1" colSpan="1" >User ID (former name: `Identifier`).</td>
|
|
203
|
-
</tr>
|
|
204
|
-
|
|
205
|
-
<tr>
|
|
206
|
-
<td rowspan="1" colSpan="1" >expire</td>
|
|
207
|
-
|
|
208
|
-
<td rowspan="1" colSpan="1" >UserSig validity period, in seconds.</td>
|
|
209
|
-
</tr>
|
|
210
|
-
|
|
211
|
-
<tr>
|
|
212
|
-
<td rowspan="1" colSpan="1" >userbuf</td>
|
|
213
|
-
|
|
214
|
-
<td rowspan="1" colSpan="1" >This field is set to `null` by default because APIs without UserBuf are used in Chat by default.APIs with UserBuf may be required in some TRTC use cases, for example, when entering a room. For more information, see [Enabling Advanced Permission Control](https://intl.cloud.tencent.com/document/product/647/35157).</td>
|
|
215
|
-
</tr>
|
|
216
|
-
|
|
217
|
-
<tr>
|
|
218
|
-
<td rowspan="1" colSpan="1" >key</td>
|
|
219
|
-
|
|
220
|
-
<td rowspan="1" colSpan="1" >Key. You can obtain a key on the app details page in the [Chat console](https://console.trtc.io/chat). For more information, see [Obtaining a Key](https://write.woa.com/#getkey).</td>
|
|
221
|
-
</tr>
|
|
222
|
-
</table>
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
## Old Version of Algorithm
|
|
226
|
-
|
|
227
|
-
To simplify signature computing so that customers can conveniently and quickly use Tencent Cloud services, the signature algorithm of the Chat service has been upgraded from ECDSA-SHA256 to HMAC-SHA256 since July 19, 2019. This means that all SDKAppIDs created after July 19, 2019 will use the new HMAC-SHA256 algorithm.
|
|
228
|
-
|
|
229
|
-
If your SDKAppID was created before July 19, 2019, we recommend that you upgrade the signature algorithm to [HMAC-SHA256](https://write.woa.com/#GeneratingdynamicUserSig). The upgrade will not affect your business. Alternatively, you can still use the signature algorithm of an earlier version. The URLs for downloading the source code for the ECDSA-SHA256 algorithm are as follows:
|
|
230
|
-
<table>
|
|
231
|
-
<tr>
|
|
232
|
-
<td rowspan="1" colSpan="1" >Programming Language</td>
|
|
233
|
-
|
|
234
|
-
<td rowspan="1" colSpan="1" >Signature Algorithm</td>
|
|
235
|
-
|
|
236
|
-
<td rowspan="1" colSpan="1" >Download Link</td>
|
|
237
|
-
</tr>
|
|
238
|
-
|
|
239
|
-
<tr>
|
|
240
|
-
<td rowspan="1" colSpan="1" >Java</td>
|
|
241
|
-
|
|
242
|
-
<td rowspan="1" colSpan="1" >ECDSA-SHA256</td>
|
|
243
|
-
|
|
244
|
-
<td rowspan="1" colSpan="1" >[GitHub](https://github.com/tencentyun/tls-sig-api-java)</td>
|
|
245
|
-
</tr>
|
|
246
|
-
|
|
247
|
-
<tr>
|
|
248
|
-
<td rowspan="1" colSpan="1" >GO</td>
|
|
249
|
-
|
|
250
|
-
<td rowspan="1" colSpan="1" >ECDSA-SHA256</td>
|
|
251
|
-
|
|
252
|
-
<td rowspan="1" colSpan="1" >[GitHub](https://github.com/tencentyun/tls-sig-api-golang)</td>
|
|
253
|
-
</tr>
|
|
254
|
-
|
|
255
|
-
<tr>
|
|
256
|
-
<td rowspan="1" colSpan="1" >PHP</td>
|
|
257
|
-
|
|
258
|
-
<td rowspan="1" colSpan="1" >ECDSA-SHA256</td>
|
|
259
|
-
|
|
260
|
-
<td rowspan="1" colSpan="1" >[GitHub](https://github.com/tencentyun/tls-sig-api-php)</td>
|
|
261
|
-
</tr>
|
|
262
|
-
|
|
263
|
-
<tr>
|
|
264
|
-
<td rowspan="1" colSpan="1" >Nodejs</td>
|
|
265
|
-
|
|
266
|
-
<td rowspan="1" colSpan="1" >ECDSA-SHA256</td>
|
|
267
|
-
|
|
268
|
-
<td rowspan="1" colSpan="1" >[GitHub](https://github.com/tencentyun/tls-sig-api-node)</td>
|
|
269
|
-
</tr>
|
|
270
|
-
|
|
271
|
-
<tr>
|
|
272
|
-
<td rowspan="1" colSpan="1" >Python</td>
|
|
273
|
-
|
|
274
|
-
<td rowspan="1" colSpan="1" >ECDSA-SHA256</td>
|
|
275
|
-
|
|
276
|
-
<td rowspan="1" colSpan="1" >[GitHub](https://github.com/tencentyun/tls-sig-api-python)</td>
|
|
277
|
-
</tr>
|
|
278
|
-
|
|
279
|
-
<tr>
|
|
280
|
-
<td rowspan="1" colSpan="1" >C#</td>
|
|
281
|
-
|
|
282
|
-
<td rowspan="1" colSpan="1" >ECDSA-SHA256</td>
|
|
283
|
-
|
|
284
|
-
<td rowspan="1" colSpan="1" >[GitHub](https://github.com/tencentyun/tls-sig-api-cs)</td>
|
|
285
|
-
</tr>
|
|
286
|
-
|
|
287
|
-
<tr>
|
|
288
|
-
<td rowspan="1" colSpan="1" >C++</td>
|
|
289
|
-
|
|
290
|
-
<td rowspan="1" colSpan="1" >ECDSA-SHA256</td>
|
|
291
|
-
|
|
292
|
-
<td rowspan="1" colSpan="1" >[GitHub](https://github.com/tencentyun/tls-sig-api)</td>
|
|
293
|
-
</tr>
|
|
294
|
-
</table>
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
## Get UserSig from the console
|
|
298
|
-
- Log in to Tencent-RTC Console, navigate to Development Tools > [UserSig Tools](https://console.trtc.io/usersig).
|
|
299
|
-
|
|
300
|
-
- Under the UserSig Generation Tool, select the corresponding SDKAppID and UserID.
|
|
301
|
-
|
|
302
|
-
- Click the Generate button to compute the corresponding UserSig.
|
|
303
|
-
|
|
304
|
-

|
|
305
|
-
|
|
306
|
-
|
|
@@ -1,202 +0,0 @@
|
|
|
1
|
-
## Applicable Scenarios
|
|
2
|
-
|
|
3
|
-
Web & H5 platform, integrate independently private chat (1V1) or Group chat. This scenario is applicable for such as real estate consultancy, e-commerce customer service, remote insurance claims assessment.
|
|
4
|
-
|
|
5
|
-
You can directly experience the chat below. Meanwhile, you can quickly try online code implementation through [**Experience Sandbox**](https://codesandbox.io/p/sandbox/trtc-chat-only-gmtmfw).
|
|
6
|
-
<iframe src="https://sdk-web-1252463788.cos.ap-hongkong.myqcloud.com/im/demo/docs-example/sample-chat/index.html#/chatbox?page=intergrationchat" style="width:100%;height:700px;border:none" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" referrerpolicy="no-referrer-when-downgrade" allowfullscreen></iframe>
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
## Development Environment Requirement
|
|
10
|
-
- React version 18
|
|
11
|
-
|
|
12
|
-
- TypeScript
|
|
13
|
-
|
|
14
|
-
- [Node.js](https://nodejs.org/en/) version 18+
|
|
15
|
-
|
|
16
|
-
- npm (version should match node version)
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
## Chat-Uikit-React Integration
|
|
20
|
-
|
|
21
|
-
### Step 1: Create Project
|
|
22
|
-
|
|
23
|
-
Create a new React project named **chat-app** (select React 18 during project creation and recommend using the Typescript template), and follow the prompt to run the initial project.
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
【shell】
|
|
27
|
-
``` bash
|
|
28
|
-
npm create rsbuild@latest
|
|
29
|
-
```
|
|
30
|
-
|
|
31
|
-
### Step 2: Download the Chat-Uikit-React Component
|
|
32
|
-
|
|
33
|
-
Download [chat-uikit-react](https://www.npmjs.com/package/@tencentcloud/chat-uikit-react) via npm and use it in the project.
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
【shell】
|
|
37
|
-
``` bash
|
|
38
|
-
npm i @tencentcloud/chat-uikit-react
|
|
39
|
-
```
|
|
40
|
-
|
|
41
|
-
### Step 3: Introduce the Chat-Uikit-React Component, Create and Open a Session to Chat
|
|
42
|
-
|
|
43
|
-
> **Note:**
|
|
44
|
-
>
|
|
45
|
-
|
|
46
|
-
> Note: The following code does not auto-fill `SDKAppID`, `userID`, or `userSig`. Retrieve related information in [procedure 4](https://write.woa.com/#step4) and replace them.
|
|
47
|
-
>
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
> **Note:**
|
|
51
|
-
>
|
|
52
|
-
> - Call API [createC2CConversation](https://write.woa.com/document/155521474134589440) to create a one-to-one chat.
|
|
53
|
-
> - Call API [createGroupConversation](https://write.woa.com/document/155521474134589440) to create a group chat.
|
|
54
|
-
> - Ways to enter a chat:
|
|
55
|
-
> - Call API [setActiveConversation](https://write.woa.com/document/155521474134589440), input conversationID to enter the chat page.
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
Replace the content in App.tsx, or you can create a new component and introduce it. [Experience Sandbox ->](https://codesandbox.io/p/sandbox/trtc-chat-only-gmtmfw?from-embed=)
|
|
59
|
-
``` typescript
|
|
60
|
-
import {
|
|
61
|
-
UIKitProvider,
|
|
62
|
-
useLoginState,
|
|
63
|
-
LoginStatus,
|
|
64
|
-
useConversationListState,
|
|
65
|
-
Chat,
|
|
66
|
-
MessageList,
|
|
67
|
-
MessageInput,
|
|
68
|
-
ChatHeader,
|
|
69
|
-
useUIOpenControlState,
|
|
70
|
-
ChatSetting,
|
|
71
|
-
Search,
|
|
72
|
-
VariantType,
|
|
73
|
-
} from "@tencentcloud/chat-uikit-react"
|
|
74
|
-
|
|
75
|
-
export default function App() {
|
|
76
|
-
|
|
77
|
-
const { isChatSettingOpen, isChatSearchOpen } = useUIOpenControlState();
|
|
78
|
-
const { setActiveConversation, createC2CConversation } = useConversationListState();
|
|
79
|
-
const { status } = useLoginState({
|
|
80
|
-
SDKAppID: 0, // Your SDKAppID, see procedure 4
|
|
81
|
-
userID: '', // Your logged in UserID, see procedure 5
|
|
82
|
-
userSig: '', // Your userSig, see procedure 5
|
|
83
|
-
onSuccess() {
|
|
84
|
-
const userID = ''; // userID: recipient's userID
|
|
85
|
-
createC2CConversation(userID).then((conversation) => {
|
|
86
|
-
setActiveConversation(conversation.conversationID);
|
|
87
|
-
})
|
|
88
|
-
}
|
|
89
|
-
});
|
|
90
|
-
|
|
91
|
-
if (status !== LoginStatus.SUCCESS) {
|
|
92
|
-
return <div>loading...</div>;
|
|
93
|
-
}
|
|
94
|
-
|
|
95
|
-
// Language support en-US(default) / zh-CN / ja-JP / ko-KR / zh-TW
|
|
96
|
-
// Theme supports light(default) / dark
|
|
97
|
-
return (
|
|
98
|
-
<div style={{display: 'flex', height: '100vh'}}>
|
|
99
|
-
<UIKitProvider language='en-US' theme='light'>
|
|
100
|
-
<Chat style={{ width: '100vw' }}>
|
|
101
|
-
<ChatHeader />
|
|
102
|
-
<MessageList />
|
|
103
|
-
<MessageInput />
|
|
104
|
-
</Chat>
|
|
105
|
-
{isChatSettingOpen && <ChatSetting />}
|
|
106
|
-
{isChatSearchOpen && <Search style={{ minWidth: '300px'}} variant={VariantType.EMBEDDED} />}
|
|
107
|
-
</UIKitProvider>
|
|
108
|
-
</div>
|
|
109
|
-
);
|
|
110
|
-
}
|
|
111
|
-
```
|
|
112
|
-
|
|
113
|
-
### Step 4: Creating an Application
|
|
114
|
-
1. Log in to the [Chat Console](https://console.trtc.io/).
|
|
115
|
-
|
|
116
|
-
2. Click "Create Application", enter your application name, then click "Create".
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-

|
|
120
|
-
|
|
121
|
-
3. After creation, you can see the application status, service version, SDKAppID, createTime, tag, and expiration time on the console overview page.
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-

|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
### Procedure 5: Obtain UserID and UserSig
|
|
128
|
-
- `userID`
|
|
129
|
-
|
|
130
|
-
- Click to enter the [Application](https://console.trtc.io/app) you created above. The `Chat` product entry will be shown in the left sidebar. Click to enter.
|
|
131
|
-
|
|
132
|
-
- After entering the Chat product subpage, click `Users` to enter the user management page.
|
|
133
|
-
|
|
134
|
-
- Click `Create account`, and a pop-up input box for account information will appear. If you are merely an ordinary member, we recommend you select the `General` data type.
|
|
135
|
-
|
|
136
|
-
- For a better experience in message sending and receiving and other features, we recommend creating two userIDs.
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-

|
|
140
|
-
|
|
141
|
-
- `userSig`, usable development tools provided by the console to generate in real-time. Please click [Chat Console > Development Tools > UserSig Tools > Signature (UserSig) Generator](https://console.trtc.io/usersig).
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-

|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
### Step 6: Start Project
|
|
148
|
-
|
|
149
|
-
Replace the SDKAppID, userID, and userSig in App.tsx, then run the command as follows:
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
【shell】
|
|
153
|
-
``` bash
|
|
154
|
-
npm run start
|
|
155
|
-
```
|
|
156
|
-
|
|
157
|
-
> **Note:**
|
|
158
|
-
>
|
|
159
|
-
> 1. Please ensure the [procedure 3](https://write.woa.com/#step3) code has successfully replaced `SDKAppID`, `userID`, and `userSig`. If not replaced, it will lead to abnormal project performance.
|
|
160
|
-
> 2. `userID` and `userSig` have a one-to-one relationship. Refer to [generate UserSig](https://trtc.io/document/39074?product=consoleguide).
|
|
161
|
-
> 3. If the project fails to start, please check whether the [development environment requirement](https://write.woa.com/#required) are met.
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
### Step 7: Send Your First Message
|
|
165
|
-
|
|
166
|
-
enter the message in the input box and press **enter** to send.
|
|
167
|
-
<iframe src="https://codesandbox.io/embed/gmtmfw?view=split&module=%2Fsrc%2FApp.tsx" style="width:100%;height:750px;border:0;border-radius:4px;overflow:hidden" title="chat-react-test" allow="accelerometer; ambient-light-sensor; camera; encrypted-media; geolocation; gyroscope; hid; microphone; midi; payment; usb; vr; xr-spatial-tracking" sandbox="allow-forms allow-modals allow-popups allow-presentation allow-same-origin allow-scripts"></iframe>
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
## FAQs
|
|
171
|
-
|
|
172
|
-
#### What Is UserSig
|
|
173
|
-
|
|
174
|
-
UserSig is the password for user login to Chat, which is essentially the encrypted ciphertext of UserID and other information.
|
|
175
|
-
|
|
176
|
-
#### How to Generate UserSig
|
|
177
|
-
|
|
178
|
-
The UserSig issuance method involves integrating the UserSig calculation code into your server and providing a project-oriented API. When UserSig is required, your project initiates a request to the business server to obtain a dynamic UserSig. For more details, see [UserSig generation by the server](https://cloud.tencent.com/document/product/269/32688#GeneratingdynamicUserSig).
|
|
179
|
-
|
|
180
|
-
> **Note:**
|
|
181
|
-
>
|
|
182
|
-
|
|
183
|
-
> The example code in this document uses a solution to obtain UserSig by configuring SECRETKEY in client-side code. In this method, SECRETKEY can be easily decompiled and reverse-engineered. Once your key is leaked, attackers can steal your Tencent Cloud traffic. Therefore, **this method is only suitable for local debugging**. For the correct UserSig issuance method, please refer to the context before.
|
|
184
|
-
>
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
#### Does React 17.X Version Support
|
|
188
|
-
|
|
189
|
-
Currently does not support version 17.x. Only React ≥ v18.0 is supported.
|
|
190
|
-
|
|
191
|
-
## Reference Documentation
|
|
192
|
-
|
|
193
|
-
#### UIKit Related
|
|
194
|
-
- [chat-uikit-react npm](https://www.npmjs.com/package/@tencentcloud/chat-uikit-react)
|
|
195
|
-
|
|
196
|
-
- [Demo source code and running example](https://github.com/TencentCloud/chat-uikit-react)
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
#### Implementing More Features, Refer to ChatEngine API Document
|
|
200
|
-
- [chat-uikit-engine API manual](https://web.sdk.qcloud.com/im/doc/chat-engine/index.html)
|
|
201
|
-
|
|
202
|
-
- [chat-uikit-engine npm](https://www.npmjs.com/package/@tencentcloud/chat-uikit-engine)
|