@tencent-rtc/mcp 1.0.9 → 1.1.6
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 +92 -0
- package/resource/doc/chatuikit/react/integration.md +14 -10
- 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/server-config.js +35 -0
- package/server-config.js.map +1 -0
- 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-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 +24 -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/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,279 +0,0 @@
|
|
|
1
|
-
## Introduction
|
|
2
|
-
|
|
3
|
-
chat-uikit-react is a react UI component library based on Tencent Cloud Chat SDK. It provides some common UI components, including session, chat, group and other features. Based on these well-designed UI components, you can quickly build elegant, reliable and scalable chat applications.
|
|
4
|
-
|
|
5
|
-
You can directly experience the chat below. Meanwhile, you can quickly try online code implementation through [**Try On CodeSandbox**](https://codesandbox.io/p/sandbox/trtc-chat-full-48sffc?from-embed=).
|
|
6
|
-
<iframe src="https://web.sdk.qcloud.com/im/demo/docs-example/sample-chat/index.html#/inbox?page=intergration" style="width:100%;height:700px;border:none" allow="camera; microphone; 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 set up 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 for use in the project.
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
【shell】
|
|
37
|
-
``` bash
|
|
38
|
-
npm i @tencentcloud/chat-uikit-react
|
|
39
|
-
```
|
|
40
|
-
|
|
41
|
-
Copy the debug directory to the src/debug folder in the project directory. This is required when generating user signatures locally.
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
【MacOS】
|
|
47
|
-
``` bash
|
|
48
|
-
cp -r node_modules/@tencentcloud/chat-uikit-react/debug ./src
|
|
49
|
-
```
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
【Windows】
|
|
53
|
-
``` bash
|
|
54
|
-
xcopy node_modules\@tencentcloud\chat-uikit-react\debug .\src\debug /i /e
|
|
55
|
-
```
|
|
56
|
-
|
|
57
|
-
### Step 3: Introducing the Chat-Uikit-React Component
|
|
58
|
-
|
|
59
|
-
> **Note:**
|
|
60
|
-
>
|
|
61
|
-
> - The following code does not include `SDKAppID`, `userID`, and `UserSig`. You need to replace them with the relevant information obtained in [Step 4](https://write.woa.com/document/108053210129276928).
|
|
62
|
-
> - To respect the copyright of emoji designs, the Chat Demo/TUIKit project does not include large emoji graphics. Please replace them with your own designs or other emoji packs for which you hold the copyright before officially launching for commercial use. **The default smiley face emoji pack shown below is copyrighted by Tencent RTC** and is available for licensed use for a fee. If you need to obtain a license, please [submit a ticket](https://trtc.io/contact) contact us.
|
|
63
|
-
|
|
64
|
-
> 
|
|
65
|
-
>
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
Replace the content in App.tsx, or you can create a new component and import it. [**→ Experience in sandbox**](https://codesandbox.io/p/sandbox/trtc-chat-full-48sffc?from-embed=)**.**
|
|
69
|
-
``` typescript
|
|
70
|
-
import {
|
|
71
|
-
UIKitProvider,
|
|
72
|
-
useLoginState,
|
|
73
|
-
LoginStatus,
|
|
74
|
-
ConversationList,
|
|
75
|
-
Chat,
|
|
76
|
-
ChatHeader,
|
|
77
|
-
MessageList,
|
|
78
|
-
MessageInput,
|
|
79
|
-
useUIOpenControlState,
|
|
80
|
-
ChatSetting,
|
|
81
|
-
Search,
|
|
82
|
-
VariantType,
|
|
83
|
-
ContactList,
|
|
84
|
-
ContactInfo,
|
|
85
|
-
} from "@tencentcloud/chat-uikit-react";
|
|
86
|
-
import { useState } from "react";
|
|
87
|
-
import * as GenerateTestUserSig from "./debug/GenerateTestUserSig-es";
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
function App() {
|
|
91
|
-
const userID = ''; // TODO: Replace with your userID
|
|
92
|
-
const SDKAppID = 0; // TODO: Replace with your SDKAppID (Notice: SDKAppID is of type number)
|
|
93
|
-
const SDKSecretKey = ''; // TODO: Replace with your SDKSecretKey
|
|
94
|
-
|
|
95
|
-
const { isChatSettingOpen, isChatSearchOpen } = useUIOpenControlState();
|
|
96
|
-
const [activeTab, setActiveTab] = useState('chats');
|
|
97
|
-
|
|
98
|
-
const { userSig } = GenerateTestUserSig.genTestUserSig({
|
|
99
|
-
userID,
|
|
100
|
-
SDKAppID,
|
|
101
|
-
SecretKey: SDKSecretKey,
|
|
102
|
-
});
|
|
103
|
-
|
|
104
|
-
const { status } = useLoginState({
|
|
105
|
-
SDKAppID,
|
|
106
|
-
userID,
|
|
107
|
-
userSig,
|
|
108
|
-
})
|
|
109
|
-
|
|
110
|
-
if (status !== LoginStatus.SUCCESS) {
|
|
111
|
-
return <div>Loading...</div>
|
|
112
|
-
}
|
|
113
|
-
|
|
114
|
-
// Language support en-US(default) / zh-CN / ja-JP / ko-KR / zh-TW
|
|
115
|
-
// Theme support light(default) / dark
|
|
116
|
-
return (
|
|
117
|
-
<UIKitProvider>
|
|
118
|
-
<div style={{ height: '100vh', width: '100vw', display: 'flex', flexDirection: 'row' }}>
|
|
119
|
-
<ul>
|
|
120
|
-
<li onClick={() => {setActiveTab('chats')}}>chats</li>
|
|
121
|
-
<li onClick={() => {setActiveTab('contacts')}}>contact</li>
|
|
122
|
-
</ul>
|
|
123
|
-
{
|
|
124
|
-
activeTab === 'chats' && (
|
|
125
|
-
<>
|
|
126
|
-
<ConversationList style={{ minWidth: '300px', maxWidth: '350px' }}/>
|
|
127
|
-
<Chat PlaceholderEmpty="No messages yet">
|
|
128
|
-
<ChatHeader />
|
|
129
|
-
<MessageList />
|
|
130
|
-
<MessageInput />
|
|
131
|
-
</Chat>
|
|
132
|
-
{isChatSettingOpen && <ChatSetting />}
|
|
133
|
-
{isChatSearchOpen && <Search style={{ minWidth: '300px'}} variant={VariantType.EMBEDDED} />}
|
|
134
|
-
</>
|
|
135
|
-
)
|
|
136
|
-
}
|
|
137
|
-
{
|
|
138
|
-
activeTab === 'contacts' && (
|
|
139
|
-
<>
|
|
140
|
-
<ContactList style={{ minWidth: '300px', maxWidth: '350px' }}/>
|
|
141
|
-
<ContactInfo
|
|
142
|
-
PlaceholderEmpty="No contact yet"
|
|
143
|
-
onSendMessage={() => {setActiveTab('chats')}}
|
|
144
|
-
onEnterGroup={() => {setActiveTab('chats')}}
|
|
145
|
-
/>
|
|
146
|
-
</>
|
|
147
|
-
)
|
|
148
|
-
}
|
|
149
|
-
</div>
|
|
150
|
-
</UIKitProvider>
|
|
151
|
-
);
|
|
152
|
-
}
|
|
153
|
-
|
|
154
|
-
export default App;
|
|
155
|
-
```
|
|
156
|
-
<table>
|
|
157
|
-
<tr>
|
|
158
|
-
<td rowspan="1" colSpan="1" >Parameter</td>
|
|
159
|
-
|
|
160
|
-
<td rowspan="1" colSpan="1" >Type</td>
|
|
161
|
-
|
|
162
|
-
<td rowspan="1" colSpan="1" >Note</td>
|
|
163
|
-
</tr>
|
|
164
|
-
|
|
165
|
-
<tr>
|
|
166
|
-
<td rowspan="1" colSpan="1" >userID</td>
|
|
167
|
-
|
|
168
|
-
<td rowspan="1" colSpan="1" >String</td>
|
|
169
|
-
|
|
170
|
-
<td rowspan="1" colSpan="1" >Unique identifier of the user, defined by you, it is allowed to contain only upper and lower case letters (a-z, A-Z), numbers (0-9), underscores, and hyphens.</td>
|
|
171
|
-
</tr>
|
|
172
|
-
|
|
173
|
-
<tr>
|
|
174
|
-
<td rowspan="1" colSpan="1" >SDKAppID</td>
|
|
175
|
-
|
|
176
|
-
<td rowspan="1" colSpan="1" >Number</td>
|
|
177
|
-
|
|
178
|
-
<td rowspan="1" colSpan="1" >The unique identifier for the audio and video application created in the [Tencent RTC Console](https://console.trtc.io/).</td>
|
|
179
|
-
</tr>
|
|
180
|
-
|
|
181
|
-
<tr>
|
|
182
|
-
<td rowspan="1" colSpan="1" >SDKSecretKey</td>
|
|
183
|
-
|
|
184
|
-
<td rowspan="1" colSpan="1" >String</td>
|
|
185
|
-
|
|
186
|
-
<td rowspan="1" colSpan="1" >The SDKSecretKey of the audio and video application created in the [Tencent RTC Console](https://console.trtc.io/).</td>
|
|
187
|
-
</tr>
|
|
188
|
-
|
|
189
|
-
<tr>
|
|
190
|
-
<td rowspan="1" colSpan="1" >userSig</td>
|
|
191
|
-
|
|
192
|
-
<td rowspan="1" colSpan="1" >String</td>
|
|
193
|
-
|
|
194
|
-
<td rowspan="1" colSpan="1" >A security protection signature used for user log in authentication to confirm the user's identity and prevent malicious attackers from stealing your cloud service usage rights.</td>
|
|
195
|
-
</tr>
|
|
196
|
-
</table>
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
> **Explanation of UserSig:**
|
|
200
|
-
>
|
|
201
|
-
|
|
202
|
-
> **Development environment**: If you are running a demo locally and developing or debugging, you can use the `genTestUserSig` (Refer to Step 3.2) function in the debug file to generate a 'userSig'. In this method, SDKSecretKey is vulnerable to decompilation and reverse engineering. Once your key is leaked, attackers can steal your Tencent Cloud traffic.
|
|
203
|
-
>
|
|
204
|
-
|
|
205
|
-
> **Production environment**: If your project is going live, please use the [Server-side Generation of UserSig](https://trtc.io/document/34385) method.
|
|
206
|
-
>
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
### Step 4: Create an application
|
|
210
|
-
1. Log in to [Chat Console](https://console.trtc.io/) .
|
|
211
|
-
|
|
212
|
-
2. Click **Create Application**, enter your application name, then click **Create**.
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-

|
|
216
|
-
|
|
217
|
-
3. After creation, you can view the Application Status, service version, SDKAppID, creation time, Tag, and expiration time of the new application on the console overview page.
|
|
218
|
-
|
|
219
|
-

|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
### Step 5: Start the Project
|
|
223
|
-
|
|
224
|
-
Replace SDKAppID, UserID, and UserSig in App.tsx, then run the following command:
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
【shell】
|
|
228
|
-
``` bash
|
|
229
|
-
npm run dev
|
|
230
|
-
```
|
|
231
|
-
|
|
232
|
-
> **Note:**
|
|
233
|
-
>
|
|
234
|
-
> 1. Please ensure that in Step 3 code, SDKAppID, UserID, and UserSig are all successfully replaced. Failure to replace them will result in abnormal project behavior.
|
|
235
|
-
> 2. A `userID` corresponds to a `userSig`, for more information, see [Generating UserSig](https://trtc.io/document/39074?product=consoleguide).
|
|
236
|
-
> 3. If the project fails to start, please check whether the [development environment requirements](https://write.woa.com/document/108053210129276928) are met.
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
### Step 6: Send your first message
|
|
240
|
-
|
|
241
|
-
Enter your message in the input box and press Enter to send.
|
|
242
|
-
|
|
243
|
-

|
|
244
|
-
|
|
245
|
-
## FAQs
|
|
246
|
-
|
|
247
|
-
#### What is UserSig?
|
|
248
|
-
|
|
249
|
-
A UserSig is a password for users to log in to Chat. It is essentially the ciphertext generated by encrypting information such as the UserID.
|
|
250
|
-
|
|
251
|
-
#### How can I generate a UserSig?
|
|
252
|
-
|
|
253
|
-
The issuance method for UserSig involves integrating the calculation code of UserSig into your server, and providing an interface oriented towards your project. When UserSig is needed, your project sends a request to the business server to access the dynamic UserSig. For more information, please see [How to Generate a UserSig on the Server](https://trtc.io/document/39074?product=consoleguide).
|
|
254
|
-
|
|
255
|
-
> **Note:**
|
|
256
|
-
>
|
|
257
|
-
|
|
258
|
-
> The exemplary code provided in this document retrieves the UserSig by embedding the SECRETKEY in the client code. This approach makes the SECRETKEY highly susceptible to decompilation and reverse engineering. Once your encryption key is compromised, attackers can misappropriate your Tencent Cloud traffic. Hence, **this procedure is exclusively recommended for running functional debugging locally**. For the correct issuance of UserSig, please refer to the previous sections.
|
|
259
|
-
>
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
## Communication and Feedback
|
|
263
|
-
|
|
264
|
-
Join the [Telegram Technical Exchange Group](https://t.me/tencent_imsdk) or [WhatsApp Exchange Group](https://chat.whatsapp.com/IVa11ZkVmKTEwSWsAzSyik) to enjoy support from professional engineers and solve your problems.
|
|
265
|
-
|
|
266
|
-
## Documentation
|
|
267
|
-
|
|
268
|
-
#### UIKit Related:
|
|
269
|
-
- [chat-uikit-react npm](https://www.npmjs.com/package/@tencentcloud/chat-uikit-react)
|
|
270
|
-
|
|
271
|
-
- [Demo Source Code and Running Example](https://github.com/TencentCloud/chat-uikit-react)
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
#### For more features, refer to the ChatEngine API documentation:
|
|
275
|
-
- [chat-uikit-engine API Manual](https://web.sdk.qcloud.com/im/doc/chat-engine/index.html)
|
|
276
|
-
|
|
277
|
-
- [chat-uikit-engine npm](https://www.npmjs.com/package/@tencentcloud/chat-uikit-engine)
|
|
278
|
-
|
|
279
|
-
|
|
@@ -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
|
-
|