@cg-devcenter/rtc-fpnn-webjs-sdk 1.0.0-cg.10 → 1.0.0-cg.12

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 CHANGED
@@ -72,7 +72,7 @@ async function startChat(rtm, { pid, endpoint, uid, peerUid, credential }) {
72
72
  }
73
73
  ```
74
74
 
75
- 此片段假定调用方已加载 SDK,并取得 `pid`、完整 WebSocket endpoint、`uid`、`peerUid` 和服务端签发的 `credential`。带 credential 获取方式、错误处理、关闭流程、参数和返回值的完整示例见 [SDK 接入指南](docs/USAGE.md#2-快速开始登录收-push发消息关闭)。
75
+ 此片段假定调用方已加载 SDK,并取得 `pid`、WebSocket endpoint(带 `ws://` 或 `wss://`,无路径时 SDK 补齐 `/service/websocket`)、`uid`、`peerUid` 和服务端签发的 `credential`。带 credential 获取方式、错误处理、关闭流程、参数和返回值的完整示例见 [SDK 接入指南](docs/USAGE.md#2-快速开始登录收-push发消息关闭)。
76
76
 
77
77
  ## 同 UID 多窗口
78
78
 
package/dist/rtm.d.ts CHANGED
@@ -130,7 +130,7 @@ declare namespace rtm {
130
130
  [key: string]: unknown;
131
131
  }
132
132
 
133
- /** Protocol is FPNN by default; TLV requires an explicit protocol. Legacy WebSocket URL aliases remain supported for TLV. */
133
+ /** Protocol is FPNN by default; TLV requires an explicit protocol. TLV ws(s) URLs with no path or only / use /service/websocket; explicit paths are preserved. Legacy URL aliases remain supported. */
134
134
  export type RTMClientOptions = RTMClientBaseOptions & (
135
135
  | ({ protocol?: 'fpnn' } & (
136
136
  { endpoint: string; ssl_endpoint?: string }
@@ -285,7 +285,7 @@ declare namespace rtm {
285
285
  regressiveStrategy?: RTMRegressiveStrategy;
286
286
  }
287
287
 
288
- /** Defaults to FPNN; use protocol: 'tlv-v1' to opt into TLV. Functions cannot cross the Worker boundary. */
288
+ /** Defaults to FPNN; use protocol: 'tlv-v1' to opt into TLV. TLV ws(s) URLs with no path or only / use /service/websocket; explicit paths are preserved. Functions cannot cross the Worker boundary. */
289
289
  export type RTMSharedWorkerClientOptions = RTMSharedWorkerBaseClientOptions & (
290
290
  ({ protocol?: 'fpnn' } & (
291
291
  { endpoint: string; ssl_endpoint?: string } | { ssl_endpoint: string; endpoint?: string }
@@ -576,7 +576,7 @@ declare namespace rtm {
576
576
  protocol?: RTMProtocol;
577
577
  pid: string | number;
578
578
  uid: RTMId;
579
- /** Optional explicit environment isolation; omitted in default client identities. */
579
+ /** Optional explicit environment isolation; TLV ws(s) URLs use the same default /service/websocket path as client connections. */
580
580
  endpoint?: string;
581
581
  namespace?: string;
582
582
  }
@@ -625,6 +625,7 @@ declare namespace rtm {
625
625
  }
626
626
 
627
627
  export class TLVWebSocketClient {
628
+ /** endpoint must be a ws(s) URL; no path or only / uses /service/websocket, while explicit paths are preserved. */
628
629
  constructor(options);
629
630
  connect();
630
631
  close();