@xmov/avatar 2.4.0-alpha.2 → 2.4.0-alpha.4

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.
@@ -25,6 +25,7 @@ export interface ISessionResponse {
25
25
  room: string;
26
26
  token: string;
27
27
  socket_io_url: string;
28
+ socket_io_path?: string;
28
29
  e2e_resp?: {
29
30
  ws_url?: string;
30
31
  e2e_token?: string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@xmov/avatar",
3
- "version": "2.4.0-alpha.2",
3
+ "version": "2.4.0-alpha.4",
4
4
  "description": "魔珐数字人 JS-SDK",
5
5
  "type": "module",
6
6
  "source": "src/index.ts",
@@ -39,6 +39,7 @@ const pointNameObj = {
39
39
  interface ITtsaOptions {
40
40
  sdkInstance: XmovAvatar;
41
41
  url: string;
42
+ path?: string;
42
43
  room: string;
43
44
  session_id: string;
44
45
  token: string;
@@ -174,6 +175,7 @@ export default class Ttsa {
174
175
  query: {
175
176
  token: this.token,
176
177
  },
178
+ path: options.path || "",
177
179
  transports: ['websocket'],
178
180
  // 自动重连不限制次数:在 reconnect_timeout(服务端断开旧房间的窗口)内持续尝试,
179
181
  // 失效房间必然重连失败;超过窗口由 disconnect 处理器中的停止定时器断开,
package/src/index.ts CHANGED
@@ -1135,6 +1135,7 @@ export default class XmovAvatar {
1135
1135
  return new Ttsa({
1136
1136
  sdkInstance: this,
1137
1137
  url: sessionInfo.socket_io_url,
1138
+ path: sessionInfo?.socket_io_path || "",
1138
1139
  room: sessionInfo.room,
1139
1140
  session_id: sessionInfo.session_id,
1140
1141
  token: sessionInfo.token,
@@ -40,6 +40,7 @@ export interface ISessionResponse {
40
40
  room: string;
41
41
  token: string;
42
42
  socket_io_url: string;
43
+ socket_io_path?: string;
43
44
  e2e_resp?: {
44
45
  ws_url?: string;
45
46
  e2e_token?: string;