@wizai/agent-sip-sdk 0.1.13-alpha → 0.1.15-alpha

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.
@@ -23,6 +23,7 @@ declare class Api {
23
23
  getAgentSetting(params: IGetAgentSettingParams): Promise<IGetAgentSettingResponse>;
24
24
  updateAgentHangup(agentId: number): Promise<IGetAgentSettingResponse>;
25
25
  updateAgentTicket(data: IUpdateAgentTicketParams): Promise<IRespones<any>>;
26
+ sendSSEACK(agentId: number): Promise<any>;
26
27
  registerSSE(data: IRegisterSSEParams): Promise<unknown>;
27
28
  closeSSE(data: ICloseSSEParams): Promise<IRespones<any> | undefined>;
28
29
  switchAgentStatus(data: ISwitchAgentStatusParams): Promise<IRespones<IAgentStatusResponse>>;
@@ -17,6 +17,7 @@ declare class SIP {
17
17
  private newMessageEvent;
18
18
  private sessionEvent;
19
19
  private callDetails;
20
+ private cancelCallId;
20
21
  private readonly incomingCallCallback;
21
22
  private readonly getMediaStream;
22
23
  constructor(props: {
@@ -41,7 +42,11 @@ declare class SIP {
41
42
  start(): Promise<boolean>;
42
43
  stop(isManualStop?: boolean): void;
43
44
  destroy(): void;
45
+ parseSIPMessage(raw: string): Record<string, any>;
44
46
  getSocketWS(): any;
47
+ wsEventListener(event: any): void;
48
+ addListenerWSMessage(): void;
49
+ removeListenerWSMessage(): void;
45
50
  sendPing(): void;
46
51
  playRing(): void;
47
52
  stopRing(): void;
package/package.json CHANGED
@@ -1,53 +1,53 @@
1
- {
2
- "name": "@wizai/agent-sip-sdk",
3
- "version": "0.1.13-alpha",
4
- "description": "Manages SIP clients and agent status, simplifying calls and events.",
5
- "main": "lib/agent-sip-sdk-cjs.js",
6
- "module": "lib/agent-sip-sdk-es.js",
7
- "types": "lib/types/index.d.ts",
8
- "type": "module",
9
- "files": [
10
- "lib/"
11
- ],
12
- "scripts": {
13
- "test": "node test/index.js",
14
- "jest": "jest",
15
- "lint": "eslint --fix",
16
- "build": "rollup -c"
17
- },
18
- "keywords": [
19
- "sip",
20
- "agent",
21
- "sdk"
22
- ],
23
- "author": "Yuki Xie",
24
- "license": "ISC",
25
- "devDependencies": {
26
- "@eslint/js": "^9.6.0",
27
- "@rollup/plugin-alias": "^5.1.1",
28
- "@rollup/plugin-commonjs": "^26.0.1",
29
- "@rollup/plugin-json": "^6.1.0",
30
- "@rollup/plugin-node-resolve": "^15.2.3",
31
- "@rollup/plugin-terser": "^0.4.4",
32
- "@rollup/plugin-typescript": "^11.1.6",
33
- "@rollup/plugin-url": "^8.0.2",
34
- "@types/event-source-polyfill": "^1.0.5",
35
- "@types/jest": "^29.5.12",
36
- "@types/node": "^22.7.8",
37
- "eslint": "^9.6.0",
38
- "globals": "^15.8.0",
39
- "jest": "^29.7.0",
40
- "rollup": "^4.18.0",
41
- "rollup-plugin-polyfill-node": "^0.13.0",
42
- "ts-jest": "^29.2.2",
43
- "tslib": "^2.6.3",
44
- "typescript": "^5.5.2",
45
- "typescript-eslint": "^7.16.0"
46
- },
47
- "dependencies": {
48
- "dayjs": "^1.11.18",
49
- "event-source-polyfill": "^1.0.31",
50
- "jssip": "^3.10.1",
51
- "nanoid": "^5.0.8"
52
- }
53
- }
1
+ {
2
+ "name": "@wizai/agent-sip-sdk",
3
+ "version": "0.1.15-alpha",
4
+ "description": "Manages SIP clients and agent status, simplifying calls and events.",
5
+ "main": "lib/agent-sip-sdk-cjs.js",
6
+ "module": "lib/agent-sip-sdk-es.js",
7
+ "types": "lib/types/index.d.ts",
8
+ "type": "module",
9
+ "files": [
10
+ "lib/"
11
+ ],
12
+ "scripts": {
13
+ "test": "node test/index.js",
14
+ "jest": "jest",
15
+ "lint": "eslint --fix",
16
+ "build": "rollup -c"
17
+ },
18
+ "keywords": [
19
+ "sip",
20
+ "agent",
21
+ "sdk"
22
+ ],
23
+ "author": "Yuki Xie",
24
+ "license": "ISC",
25
+ "devDependencies": {
26
+ "@eslint/js": "^9.6.0",
27
+ "@rollup/plugin-alias": "^5.1.1",
28
+ "@rollup/plugin-commonjs": "^26.0.1",
29
+ "@rollup/plugin-json": "^6.1.0",
30
+ "@rollup/plugin-node-resolve": "^15.2.3",
31
+ "@rollup/plugin-terser": "^0.4.4",
32
+ "@rollup/plugin-typescript": "^11.1.6",
33
+ "@rollup/plugin-url": "^8.0.2",
34
+ "@types/event-source-polyfill": "^1.0.5",
35
+ "@types/jest": "^29.5.12",
36
+ "@types/node": "^22.7.8",
37
+ "eslint": "^9.6.0",
38
+ "globals": "^15.8.0",
39
+ "jest": "^29.7.0",
40
+ "rollup": "^4.18.0",
41
+ "rollup-plugin-polyfill-node": "^0.13.0",
42
+ "ts-jest": "^29.2.2",
43
+ "tslib": "^2.6.3",
44
+ "typescript": "^5.5.2",
45
+ "typescript-eslint": "^7.16.0"
46
+ },
47
+ "dependencies": {
48
+ "dayjs": "^1.11.18",
49
+ "event-source-polyfill": "^1.0.31",
50
+ "jssip": "^3.10.1",
51
+ "nanoid": "^5.0.8"
52
+ }
53
+ }