@coventia/softphone 0.5.0 → 0.5.1

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.
Files changed (37) hide show
  1. package/dist/{call-FqcvDg1t.d.cts → call-iGvr2ZnO.d.cts} +26 -2
  2. package/dist/{call-FqcvDg1t.d.ts → call-iGvr2ZnO.d.ts} +26 -2
  3. package/dist/chunk-3UTUWGVG.js +1891 -0
  4. package/dist/chunk-3UTUWGVG.js.map +1 -0
  5. package/dist/chunk-DZRSSZWB.js +39 -0
  6. package/dist/chunk-DZRSSZWB.js.map +1 -0
  7. package/dist/element/index.d.ts +25 -1
  8. package/dist/{engine-CzOCrfY9.d.cts → engine-BKoT_Pj7.d.cts} +10 -1
  9. package/dist/{engine-CsNRD7B7.d.ts → engine-CeGh5Yai.d.ts} +10 -1
  10. package/dist/index.cjs +1049 -130
  11. package/dist/index.cjs.map +1 -1
  12. package/dist/index.d.cts +5 -5
  13. package/dist/index.d.ts +5 -5
  14. package/dist/index.js +179 -13
  15. package/dist/index.js.map +1 -1
  16. package/dist/react/index.d.cts +2 -2
  17. package/dist/react/index.d.ts +2 -2
  18. package/dist/{softphone-By9sizlV.d.ts → softphone-D0ao5W4z.d.ts} +1 -1
  19. package/dist/{softphone-JZvJdzU3.d.cts → softphone-DRoS0jJR.d.cts} +1 -1
  20. package/dist/{sources-QL2LRZVH.js → sources-LGFJG7W2.js} +10 -38
  21. package/dist/sources-LGFJG7W2.js.map +1 -0
  22. package/dist/testing/index.d.cts +2 -2
  23. package/dist/testing/index.d.ts +2 -2
  24. package/dist/ui/index.d.cts +2 -2
  25. package/dist/ui/index.d.ts +2 -2
  26. package/dist/zadarma/index.cjs +865 -116
  27. package/dist/zadarma/index.cjs.map +1 -1
  28. package/dist/zadarma/index.d.cts +37 -10
  29. package/dist/zadarma/index.d.ts +37 -10
  30. package/dist/zadarma/index.js +2 -1
  31. package/dist/zadarma-engine-VYIXLBQG.js +7 -0
  32. package/dist/{zadarma-engine-TIUE7PZ7.js.map → zadarma-engine-VYIXLBQG.js.map} +1 -1
  33. package/package.json +1 -1
  34. package/dist/chunk-6RR6G35E.js +0 -1146
  35. package/dist/chunk-6RR6G35E.js.map +0 -1
  36. package/dist/sources-QL2LRZVH.js.map +0 -1
  37. package/dist/zadarma-engine-TIUE7PZ7.js +0 -6
@@ -1,5 +1,5 @@
1
- import { A as TokenSource } from '../call-FqcvDg1t.cjs';
2
- import { C as CallEngine } from '../engine-CzOCrfY9.cjs';
1
+ import { A as TokenSource } from '../call-iGvr2ZnO.cjs';
2
+ import { C as CallEngine } from '../engine-BKoT_Pj7.cjs';
3
3
 
4
4
  /**
5
5
  * Provider quirk timers. All optional. A self-hosted provider supplies none of them — which is the
@@ -23,20 +23,47 @@ interface ProviderQuirks {
23
23
  */
24
24
  readonly userAgent?: string;
25
25
  /**
26
- * After a reject, ignore inbound INVITEs for this long.
26
+ * Setting it turns the decline guard on; its value is the guard's FALLBACK window.
27
27
  *
28
- * Zadarma: 35 000. Its `return_timeout` is ~30 s, during which it RE-RINGS the extension you just
29
- * declined. Without this the user is re-rung immediately after hanging up on a caller.
28
+ * Zadarma: 35 000. Zadarma re-offers a declined call until its ring time ends (the route's
29
+ * `return_timeout`, ~30 s by default), and nothing in the re-offer tells it from a new call. So after a
30
+ * decline the engine ignores offers from THE DECLINED CALLER — never anyone else's — while that call is
31
+ * alive: until the backend says it ended, when it announced it (`CallEngine.noteOffer`); otherwise for
32
+ * this long after the decline (incoming-call-reliability.md §4.4, Q1).
33
+ *
34
+ * Was `rejectGuardMs`, which swallowed every offer and every INVITE in the window, whoever called (CWA-81).
30
35
  */
31
- readonly rejectGuardMs?: number;
36
+ readonly declinedCallerGuardMs?: number;
32
37
  /**
33
- * After an incoming signal, tear the UA down if no INVITE arrives within this long.
38
+ * Once a REGISTER sent for an offer is answered (its 200 OK), tear the UA down if no INVITE follows within
39
+ * this long.
40
+ *
41
+ * Zadarma: 10 000. Zadarma sends the INVITE ~0.1 s after the 200 OK; a UA left registered with nothing
42
+ * coming is the standing registration SPEC §3.2 rules out. Counted from the 200 OK, never from `start()`:
43
+ * on a slow network the WSS alone can take longer than any fixed window (incoming-call-reliability.md F3).
34
44
  *
35
- * Zadarma: 5 000. The push fires for ANY activity on the extension — transfers, retries, hangups —
36
- * not just for a call to answer. Without the teardown a spurious push leaves a UA registered,
37
- * which blocks the next real call.
45
+ * Was `noInviteTeardownMs` (5 000), counted from `ua.start()`.
46
+ */
47
+ readonly noInviteAfterRegisterMs?: number;
48
+ /**
49
+ * @deprecated Since 0.5.1: `declinedCallerGuardMs`. Kept, with the same value, only because `ZADARMA_QUIRKS`
50
+ * is exported from `@coventia/softphone/zadarma` and a patch release must not drop a field from it. The engine
51
+ * does not read it.
52
+ */
53
+ readonly rejectGuardMs?: number;
54
+ /**
55
+ * @deprecated Since 0.5.1: `noInviteAfterRegisterMs`. Kept, with the same value, for the same reason as
56
+ * `rejectGuardMs`. The engine does not read it.
38
57
  */
39
58
  readonly noInviteTeardownMs?: number;
59
+ /**
60
+ * The longest an offer may wait for its INVITE, counted from the signal: a leak guard, nothing more.
61
+ *
62
+ * Zadarma: 120 000. The wait normally ends with the INVITE, with the offer ending (`offer-ended`), or with
63
+ * `noInviteAfterRegisterMs`; this only stops a registration that never completes from living forever. It
64
+ * never fires on a real offer, so it reports nothing (incoming-call-reliability.md §4.3).
65
+ */
66
+ readonly offerWaitMaxMs?: number;
40
67
  /**
41
68
  * Give up waiting for ICE gathering after this long and send the INVITE anyway.
42
69
  *
@@ -1,5 +1,5 @@
1
- import { A as TokenSource } from '../call-FqcvDg1t.js';
2
- import { C as CallEngine } from '../engine-CsNRD7B7.js';
1
+ import { A as TokenSource } from '../call-iGvr2ZnO.js';
2
+ import { C as CallEngine } from '../engine-CeGh5Yai.js';
3
3
 
4
4
  /**
5
5
  * Provider quirk timers. All optional. A self-hosted provider supplies none of them — which is the
@@ -23,20 +23,47 @@ interface ProviderQuirks {
23
23
  */
24
24
  readonly userAgent?: string;
25
25
  /**
26
- * After a reject, ignore inbound INVITEs for this long.
26
+ * Setting it turns the decline guard on; its value is the guard's FALLBACK window.
27
27
  *
28
- * Zadarma: 35 000. Its `return_timeout` is ~30 s, during which it RE-RINGS the extension you just
29
- * declined. Without this the user is re-rung immediately after hanging up on a caller.
28
+ * Zadarma: 35 000. Zadarma re-offers a declined call until its ring time ends (the route's
29
+ * `return_timeout`, ~30 s by default), and nothing in the re-offer tells it from a new call. So after a
30
+ * decline the engine ignores offers from THE DECLINED CALLER — never anyone else's — while that call is
31
+ * alive: until the backend says it ended, when it announced it (`CallEngine.noteOffer`); otherwise for
32
+ * this long after the decline (incoming-call-reliability.md §4.4, Q1).
33
+ *
34
+ * Was `rejectGuardMs`, which swallowed every offer and every INVITE in the window, whoever called (CWA-81).
30
35
  */
31
- readonly rejectGuardMs?: number;
36
+ readonly declinedCallerGuardMs?: number;
32
37
  /**
33
- * After an incoming signal, tear the UA down if no INVITE arrives within this long.
38
+ * Once a REGISTER sent for an offer is answered (its 200 OK), tear the UA down if no INVITE follows within
39
+ * this long.
40
+ *
41
+ * Zadarma: 10 000. Zadarma sends the INVITE ~0.1 s after the 200 OK; a UA left registered with nothing
42
+ * coming is the standing registration SPEC §3.2 rules out. Counted from the 200 OK, never from `start()`:
43
+ * on a slow network the WSS alone can take longer than any fixed window (incoming-call-reliability.md F3).
34
44
  *
35
- * Zadarma: 5 000. The push fires for ANY activity on the extension — transfers, retries, hangups —
36
- * not just for a call to answer. Without the teardown a spurious push leaves a UA registered,
37
- * which blocks the next real call.
45
+ * Was `noInviteTeardownMs` (5 000), counted from `ua.start()`.
46
+ */
47
+ readonly noInviteAfterRegisterMs?: number;
48
+ /**
49
+ * @deprecated Since 0.5.1: `declinedCallerGuardMs`. Kept, with the same value, only because `ZADARMA_QUIRKS`
50
+ * is exported from `@coventia/softphone/zadarma` and a patch release must not drop a field from it. The engine
51
+ * does not read it.
52
+ */
53
+ readonly rejectGuardMs?: number;
54
+ /**
55
+ * @deprecated Since 0.5.1: `noInviteAfterRegisterMs`. Kept, with the same value, for the same reason as
56
+ * `rejectGuardMs`. The engine does not read it.
38
57
  */
39
58
  readonly noInviteTeardownMs?: number;
59
+ /**
60
+ * The longest an offer may wait for its INVITE, counted from the signal: a leak guard, nothing more.
61
+ *
62
+ * Zadarma: 120 000. The wait normally ends with the INVITE, with the offer ending (`offer-ended`), or with
63
+ * `noInviteAfterRegisterMs`; this only stops a registration that never completes from living forever. It
64
+ * never fires on a real offer, so it reports nothing (incoming-call-reliability.md §4.3).
65
+ */
66
+ readonly offerWaitMaxMs?: number;
40
67
  /**
41
68
  * Give up waiting for ICE gathering after this long and send the INVITE anyway.
42
69
  *
@@ -1,6 +1,7 @@
1
- export { ZADARMA_QUIRKS, createZadarmaEngine } from '../chunk-6RR6G35E.js';
1
+ export { ZADARMA_QUIRKS, createZadarmaEngine } from '../chunk-3UTUWGVG.js';
2
2
  import '../chunk-M76SAXXM.js';
3
3
  import '../chunk-FRXHEHQA.js';
4
+ import '../chunk-DZRSSZWB.js';
4
5
  import '../chunk-MHOJHG5E.js';
5
6
  //# sourceMappingURL=index.js.map
6
7
  //# sourceMappingURL=index.js.map
@@ -0,0 +1,7 @@
1
+ export { createZadarmaEngine } from './chunk-3UTUWGVG.js';
2
+ import './chunk-M76SAXXM.js';
3
+ import './chunk-FRXHEHQA.js';
4
+ import './chunk-DZRSSZWB.js';
5
+ import './chunk-MHOJHG5E.js';
6
+ //# sourceMappingURL=zadarma-engine-VYIXLBQG.js.map
7
+ //# sourceMappingURL=zadarma-engine-VYIXLBQG.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":[],"names":[],"mappings":"","file":"zadarma-engine-TIUE7PZ7.js"}
1
+ {"version":3,"sources":[],"names":[],"mappings":"","file":"zadarma-engine-VYIXLBQG.js"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@coventia/softphone",
3
- "version": "0.5.0",
3
+ "version": "0.5.1",
4
4
  "description": "Embeddable browser softphone SDK for Zadarma: a framework-free engine, React components, and a Web Component drop-in.",
5
5
  "type": "module",
6
6
  "author": "Coventia",