ue-softphone-sdk 2.2.3 → 2.2.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.
Files changed (390) hide show
  1. package/dist/api/bye.d.ts +16 -0
  2. package/dist/api/dtmf.d.ts +15 -0
  3. package/dist/api/emitter.d.ts +88 -0
  4. package/dist/api/exceptions/content-type-unsupported.d.ts +8 -0
  5. package/dist/api/exceptions/index.d.ts +5 -0
  6. package/dist/api/exceptions/request-pending.d.ts +9 -0
  7. package/dist/api/exceptions/session-description-handler.d.ts +8 -0
  8. package/dist/api/exceptions/session-terminated.d.ts +8 -0
  9. package/dist/api/exceptions/state-transition.d.ts +8 -0
  10. package/dist/api/index.d.ts +58 -0
  11. package/dist/api/info.d.ts +16 -0
  12. package/dist/api/invitation-accept-options.d.ts +19 -0
  13. package/dist/api/invitation-progress-options.d.ts +38 -0
  14. package/dist/api/invitation-reject-options.d.ts +25 -0
  15. package/dist/api/invitation.d.ts +179 -0
  16. package/dist/api/inviter-cancel-options.d.ts +9 -0
  17. package/dist/api/inviter-invite-options.d.ts +28 -0
  18. package/dist/api/inviter-options.d.ts +43 -0
  19. package/dist/api/inviter.d.ts +236 -0
  20. package/dist/api/message.d.ts +16 -0
  21. package/dist/api/messager-message-options.d.ts +11 -0
  22. package/dist/api/messager-options.d.ts +17 -0
  23. package/dist/api/messager.d.ts +26 -0
  24. package/dist/api/notification.d.ts +16 -0
  25. package/dist/api/notifier.d.ts +8 -0
  26. package/dist/api/publisher-options.d.ts +33 -0
  27. package/dist/api/publisher-publish-options.d.ts +6 -0
  28. package/dist/api/publisher-state.d.ts +21 -0
  29. package/dist/api/publisher-unpublish-options.d.ts +6 -0
  30. package/dist/api/publisher.d.ts +65 -0
  31. package/dist/api/referral.d.ts +38 -0
  32. package/dist/api/registerer-options.d.ts +46 -0
  33. package/dist/api/registerer-register-options.d.ts +11 -0
  34. package/dist/api/registerer-state.d.ts +21 -0
  35. package/dist/api/registerer-unregister-options.d.ts +16 -0
  36. package/dist/api/registerer.d.ts +144 -0
  37. package/dist/api/session-bye-options.d.ts +11 -0
  38. package/dist/api/session-delegate.d.ts +73 -0
  39. package/dist/api/session-description-handler-factory.d.ts +15 -0
  40. package/dist/api/session-description-handler.d.ts +74 -0
  41. package/dist/api/session-info-options.d.ts +11 -0
  42. package/dist/api/session-invite-options.d.ts +28 -0
  43. package/dist/api/session-message-options.d.ts +11 -0
  44. package/dist/api/session-options.d.ts +8 -0
  45. package/dist/api/session-refer-options.d.ts +14 -0
  46. package/dist/api/session-state.d.ts +45 -0
  47. package/dist/api/session.d.ts +359 -0
  48. package/dist/api/subscriber-options.d.ts +11 -0
  49. package/dist/api/subscriber-subscribe-options.d.ts +6 -0
  50. package/dist/api/subscriber.d.ts +94 -0
  51. package/dist/api/subscription-delegate.d.ts +12 -0
  52. package/dist/api/subscription-options.d.ts +8 -0
  53. package/dist/api/subscription-state.d.ts +19 -0
  54. package/dist/api/subscription-subscribe-options.d.ts +6 -0
  55. package/dist/api/subscription-unsubscribe-options.d.ts +6 -0
  56. package/dist/api/subscription.d.ts +84 -0
  57. package/dist/api/transport-state.d.ts +37 -0
  58. package/dist/api/transport.d.ts +159 -0
  59. package/dist/api/user-agent-delegate.d.ts +84 -0
  60. package/dist/api/user-agent-options.d.ts +253 -0
  61. package/dist/api/user-agent-state.d.ts +14 -0
  62. package/dist/api/user-agent.d.ts +200 -0
  63. package/dist/core/dialogs/dialog-state.d.ts +34 -0
  64. package/dist/core/dialogs/dialog.d.ts +161 -0
  65. package/dist/core/dialogs/index.d.ts +4 -0
  66. package/dist/core/dialogs/session-dialog.d.ts +196 -0
  67. package/dist/core/dialogs/subscription-dialog.d.ts +120 -0
  68. package/dist/core/exceptions/exception.d.ts +8 -0
  69. package/dist/core/exceptions/index.d.ts +3 -0
  70. package/dist/core/exceptions/transaction-state-error.d.ts +8 -0
  71. package/dist/core/exceptions/transport-error.d.ts +8 -0
  72. package/dist/core/index.d.ts +15 -0
  73. package/dist/core/log/index.d.ts +3 -0
  74. package/dist/core/log/levels.d.ts +10 -0
  75. package/dist/core/log/logger-factory.d.ts +21 -0
  76. package/dist/core/log/logger.d.ts +19 -0
  77. package/dist/core/messages/body.d.ts +64 -0
  78. package/dist/core/messages/digest-authentication.d.ts +51 -0
  79. package/dist/core/messages/incoming-message.d.ts +79 -0
  80. package/dist/core/messages/incoming-request-message.d.ts +10 -0
  81. package/dist/core/messages/incoming-request.d.ts +67 -0
  82. package/dist/core/messages/incoming-response-message.d.ts +10 -0
  83. package/dist/core/messages/incoming-response.d.ts +12 -0
  84. package/dist/core/messages/index.d.ts +13 -0
  85. package/dist/core/messages/md5.d.ts +32 -0
  86. package/dist/core/messages/methods/ack.d.ts +18 -0
  87. package/dist/core/messages/methods/bye.d.ts +21 -0
  88. package/dist/core/messages/methods/cancel.d.ts +21 -0
  89. package/dist/core/messages/methods/constants.d.ts +20 -0
  90. package/dist/core/messages/methods/index.d.ts +13 -0
  91. package/dist/core/messages/methods/info.d.ts +21 -0
  92. package/dist/core/messages/methods/invite.d.ts +86 -0
  93. package/dist/core/messages/methods/message.d.ts +21 -0
  94. package/dist/core/messages/methods/notify.d.ts +21 -0
  95. package/dist/core/messages/methods/prack.d.ts +21 -0
  96. package/dist/core/messages/methods/publish.d.ts +21 -0
  97. package/dist/core/messages/methods/refer.d.ts +21 -0
  98. package/dist/core/messages/methods/register.d.ts +21 -0
  99. package/dist/core/messages/methods/subscribe.d.ts +54 -0
  100. package/dist/core/messages/outgoing-request-message.d.ts +94 -0
  101. package/dist/core/messages/outgoing-request.d.ts +67 -0
  102. package/dist/core/messages/outgoing-response.d.ts +42 -0
  103. package/dist/core/messages/parser.d.ts +14 -0
  104. package/dist/core/messages/utils.d.ts +24 -0
  105. package/dist/core/session/index.d.ts +2 -0
  106. package/dist/core/session/session-delegate.d.ts +70 -0
  107. package/dist/core/session/session.d.ts +134 -0
  108. package/dist/core/subscription/index.d.ts +2 -0
  109. package/dist/core/subscription/subscription-delegate.d.ts +27 -0
  110. package/dist/core/subscription/subscription.d.ts +55 -0
  111. package/dist/core/timers.d.ts +20 -0
  112. package/dist/core/transactions/client-transaction.d.ts +45 -0
  113. package/dist/core/transactions/index.d.ts +10 -0
  114. package/dist/core/transactions/invite-client-transaction.d.ts +116 -0
  115. package/dist/core/transactions/invite-server-transaction.d.ts +127 -0
  116. package/dist/core/transactions/non-invite-client-transaction.d.ts +69 -0
  117. package/dist/core/transactions/non-invite-server-transaction.d.ts +57 -0
  118. package/dist/core/transactions/server-transaction.d.ts +35 -0
  119. package/dist/core/transactions/transaction-state.d.ts +13 -0
  120. package/dist/core/transactions/transaction-user.d.ts +72 -0
  121. package/dist/core/transactions/transaction.d.ts +79 -0
  122. package/dist/core/transport.d.ts +31 -0
  123. package/dist/core/user-agent-core/allowed-methods.d.ts +4 -0
  124. package/dist/core/user-agent-core/index.d.ts +3 -0
  125. package/dist/core/user-agent-core/user-agent-core-configuration.d.ts +99 -0
  126. package/dist/core/user-agent-core/user-agent-core-delegate.d.ts +37 -0
  127. package/dist/core/user-agent-core/user-agent-core.d.ts +179 -0
  128. package/dist/core/user-agents/bye-user-agent-client.d.ts +10 -0
  129. package/dist/core/user-agents/bye-user-agent-server.d.ts +10 -0
  130. package/dist/core/user-agents/cancel-user-agent-client.d.ts +10 -0
  131. package/dist/core/user-agents/index.d.ts +26 -0
  132. package/dist/core/user-agents/info-user-agent-client.d.ts +10 -0
  133. package/dist/core/user-agents/info-user-agent-server.d.ts +10 -0
  134. package/dist/core/user-agents/invite-user-agent-client.d.ts +35 -0
  135. package/dist/core/user-agents/invite-user-agent-server.d.ts +77 -0
  136. package/dist/core/user-agents/message-user-agent-client.d.ts +10 -0
  137. package/dist/core/user-agents/message-user-agent-server.d.ts +10 -0
  138. package/dist/core/user-agents/notify-user-agent-client.d.ts +10 -0
  139. package/dist/core/user-agents/notify-user-agent-server.d.ts +16 -0
  140. package/dist/core/user-agents/prack-user-agent-client.d.ts +10 -0
  141. package/dist/core/user-agents/prack-user-agent-server.d.ts +16 -0
  142. package/dist/core/user-agents/publish-user-agent-client.d.ts +10 -0
  143. package/dist/core/user-agents/re-invite-user-agent-client.d.ts +18 -0
  144. package/dist/core/user-agents/re-invite-user-agent-server.d.ts +41 -0
  145. package/dist/core/user-agents/re-subscribe-user-agent-client.d.ts +17 -0
  146. package/dist/core/user-agents/re-subscribe-user-agent-server.d.ts +10 -0
  147. package/dist/core/user-agents/refer-user-agent-client.d.ts +10 -0
  148. package/dist/core/user-agents/refer-user-agent-server.d.ts +16 -0
  149. package/dist/core/user-agents/register-user-agent-client.d.ts +10 -0
  150. package/dist/core/user-agents/register-user-agent-server.d.ts +11 -0
  151. package/dist/core/user-agents/subscribe-user-agent-client.d.ts +65 -0
  152. package/dist/core/user-agents/subscribe-user-agent-server.d.ts +11 -0
  153. package/dist/core/user-agents/user-agent-client.d.ts +103 -0
  154. package/dist/core/user-agents/user-agent-server.d.ts +79 -0
  155. package/dist/grammar/grammar.d.ts +26 -0
  156. package/dist/grammar/index.d.ts +4 -0
  157. package/dist/grammar/name-addr-header.d.ts +24 -0
  158. package/dist/grammar/parameters.d.ts +16 -0
  159. package/dist/grammar/pegjs/dist/grammar.d.ts +50 -0
  160. package/dist/grammar/uri.d.ts +62 -0
  161. package/dist/{types/index.d.ts → index.d.ts} +7 -3
  162. package/dist/main.d.ts +9 -0
  163. package/dist/new-index.d.ts +199 -0
  164. package/dist/platform/web/index.d.ts +4 -0
  165. package/dist/platform/web/modifiers/index.d.ts +5 -0
  166. package/dist/platform/web/modifiers/modifiers.d.ts +41 -0
  167. package/dist/platform/web/session-description-handler/index.d.ts +14 -0
  168. package/dist/platform/web/session-description-handler/media-stream-factory-default.d.ts +6 -0
  169. package/dist/platform/web/session-description-handler/media-stream-factory.d.ts +6 -0
  170. package/dist/platform/web/session-description-handler/peer-connection-configuration-default.d.ts +5 -0
  171. package/dist/platform/web/session-description-handler/peer-connection-delegate.d.ts +63 -0
  172. package/dist/platform/web/session-description-handler/session-description-handler-configuration.d.ts +16 -0
  173. package/dist/platform/web/session-description-handler/session-description-handler-factory-default.d.ts +11 -0
  174. package/dist/platform/web/session-description-handler/session-description-handler-factory-options.d.ts +9 -0
  175. package/dist/platform/web/session-description-handler/session-description-handler-factory.d.ts +16 -0
  176. package/dist/platform/web/session-description-handler/session-description-handler-options.d.ts +47 -0
  177. package/dist/platform/web/session-description-handler/session-description-handler.d.ts +212 -0
  178. package/dist/platform/web/simple-user/index.d.ts +7 -0
  179. package/dist/platform/web/simple-user/simple-user-delegate.d.ts +72 -0
  180. package/dist/platform/web/simple-user/simple-user-options.d.ts +90 -0
  181. package/dist/platform/web/simple-user/simple-user.d.ts +226 -0
  182. package/dist/platform/web/transport/index.d.ts +6 -0
  183. package/dist/platform/web/transport/transport-options.d.ts +30 -0
  184. package/dist/platform/web/transport/transport.d.ts +125 -0
  185. package/dist/ue-softphone-sdk.js +2 -1
  186. package/dist/ue-softphone-sdk.js.map +1 -0
  187. package/dist/version.d.ts +1 -0
  188. package/dist/webPhoneSdk.d.ts +24 -0
  189. package/dist/webrtc.d.ts +17 -0
  190. package/{rollup-new.config.mjs → new-rollup.config.mjs} +1 -1
  191. package/package.json +6 -6
  192. package/rollup.config.js +15 -14
  193. package/src/api/api-extractor.json +358 -0
  194. package/src/api/bye.ts +27 -0
  195. package/src/api/dtmf.ts +27 -0
  196. package/src/api/emitter.ts +110 -0
  197. package/src/api/exceptions/content-type-unsupported.ts +11 -0
  198. package/src/api/exceptions/index.ts +5 -0
  199. package/src/api/exceptions/request-pending.ts +12 -0
  200. package/src/api/exceptions/session-description-handler.ts +11 -0
  201. package/src/api/exceptions/session-terminated.ts +11 -0
  202. package/src/api/exceptions/state-transition.ts +11 -0
  203. package/src/api/index.ts +58 -0
  204. package/src/api/info.ts +27 -0
  205. package/src/api/invitation-accept-options.ts +20 -0
  206. package/src/api/invitation-progress-options.ts +36 -0
  207. package/src/api/invitation-reject-options.ts +22 -0
  208. package/src/api/invitation.ts +816 -0
  209. package/src/api/inviter-cancel-options.ts +9 -0
  210. package/src/api/inviter-invite-options.ts +29 -0
  211. package/src/api/inviter-options.ts +44 -0
  212. package/src/api/inviter.ts +1126 -0
  213. package/src/api/message.ts +27 -0
  214. package/src/api/messager-message-options.ts +12 -0
  215. package/src/api/messager-options.ts +18 -0
  216. package/src/api/messager.ts +89 -0
  217. package/src/api/notification.ts +27 -0
  218. package/src/api/notifier.ts +7 -0
  219. package/src/api/publisher-options.ts +34 -0
  220. package/src/api/publisher-publish-options.ts +6 -0
  221. package/src/api/publisher-state.ts +21 -0
  222. package/src/api/publisher-unpublish-options.ts +6 -0
  223. package/src/api/publisher.ts +418 -0
  224. package/src/api/referral.ts +89 -0
  225. package/src/api/registerer-options.ts +55 -0
  226. package/src/api/registerer-register-options.ts +12 -0
  227. package/src/api/registerer-state.ts +21 -0
  228. package/src/api/registerer-unregister-options.ts +17 -0
  229. package/src/api/registerer.ts +814 -0
  230. package/src/api/session-bye-options.ts +12 -0
  231. package/src/api/session-delegate.ts +80 -0
  232. package/src/api/session-description-handler-factory.ts +16 -0
  233. package/src/api/session-description-handler.ts +89 -0
  234. package/src/api/session-info-options.ts +12 -0
  235. package/src/api/session-invite-options.ts +29 -0
  236. package/src/api/session-message-options.ts +12 -0
  237. package/src/api/session-options.ts +8 -0
  238. package/src/api/session-refer-options.ts +15 -0
  239. package/src/api/session-state.ts +45 -0
  240. package/src/api/session.ts +1448 -0
  241. package/src/api/subscriber-options.ts +12 -0
  242. package/src/api/subscriber-subscribe-options.ts +6 -0
  243. package/src/api/subscriber.ts +536 -0
  244. package/src/api/subscription-delegate.ts +13 -0
  245. package/src/api/subscription-options.ts +8 -0
  246. package/src/api/subscription-state.ts +19 -0
  247. package/src/api/subscription-subscribe-options.ts +6 -0
  248. package/src/api/subscription-unsubscribe-options.ts +6 -0
  249. package/src/api/subscription.ts +161 -0
  250. package/src/api/transport-state.ts +37 -0
  251. package/src/api/transport.ts +169 -0
  252. package/src/api/user-agent-delegate.ts +95 -0
  253. package/src/api/user-agent-options.ts +322 -0
  254. package/src/api/user-agent-state.ts +14 -0
  255. package/src/api/user-agent.ts +1014 -0
  256. package/src/core/api-extractor.json +358 -0
  257. package/src/core/dialogs/dialog-state.ts +35 -0
  258. package/src/core/dialogs/dialog.ts +605 -0
  259. package/src/core/dialogs/index.ts +4 -0
  260. package/src/core/dialogs/session-dialog.ts +996 -0
  261. package/src/core/dialogs/subscription-dialog.ts +557 -0
  262. package/src/core/exceptions/exception.ts +11 -0
  263. package/src/core/exceptions/index.ts +3 -0
  264. package/src/core/exceptions/transaction-state-error.ts +11 -0
  265. package/src/core/exceptions/transport-error.ts +11 -0
  266. package/src/core/index.ts +19 -0
  267. package/src/core/log/index.ts +3 -0
  268. package/src/core/log/levels.ts +10 -0
  269. package/src/core/log/logger-factory.ts +119 -0
  270. package/src/core/log/logger.ts +42 -0
  271. package/src/core/messages/body.ts +171 -0
  272. package/src/core/messages/digest-authentication.ts +190 -0
  273. package/src/core/messages/incoming-message.ts +152 -0
  274. package/src/core/messages/incoming-request-message.ts +14 -0
  275. package/src/core/messages/incoming-request.ts +75 -0
  276. package/src/core/messages/incoming-response-message.ts +14 -0
  277. package/src/core/messages/incoming-response.ts +13 -0
  278. package/src/core/messages/index.ts +18 -0
  279. package/src/core/messages/md5.ts +437 -0
  280. package/src/core/messages/methods/ack.ts +22 -0
  281. package/src/core/messages/methods/bye.ts +22 -0
  282. package/src/core/messages/methods/cancel.ts +22 -0
  283. package/src/core/messages/methods/constants.ts +21 -0
  284. package/src/core/messages/methods/index.ts +13 -0
  285. package/src/core/messages/methods/info.ts +22 -0
  286. package/src/core/messages/methods/invite.ts +104 -0
  287. package/src/core/messages/methods/message.ts +22 -0
  288. package/src/core/messages/methods/notify.ts +22 -0
  289. package/src/core/messages/methods/prack.ts +22 -0
  290. package/src/core/messages/methods/publish.ts +22 -0
  291. package/src/core/messages/methods/refer.ts +22 -0
  292. package/src/core/messages/methods/register.ts +22 -0
  293. package/src/core/messages/methods/subscribe.ts +59 -0
  294. package/src/core/messages/outgoing-request-message.ts +299 -0
  295. package/src/core/messages/outgoing-request.ts +77 -0
  296. package/src/core/messages/outgoing-response.ts +174 -0
  297. package/src/core/messages/parser.ts +265 -0
  298. package/src/core/messages/utils.ts +144 -0
  299. package/src/core/session/index.ts +2 -0
  300. package/src/core/session/session-delegate.ts +88 -0
  301. package/src/core/session/session.ts +158 -0
  302. package/src/core/subscription/index.ts +2 -0
  303. package/src/core/subscription/subscription-delegate.ts +30 -0
  304. package/src/core/subscription/subscription.ts +61 -0
  305. package/src/core/timers.ts +24 -0
  306. package/src/core/transactions/client-transaction.ts +78 -0
  307. package/src/core/transactions/index.ts +10 -0
  308. package/src/core/transactions/invite-client-transaction.ts +504 -0
  309. package/src/core/transactions/invite-server-transaction.ts +432 -0
  310. package/src/core/transactions/non-invite-client-transaction.ts +257 -0
  311. package/src/core/transactions/non-invite-server-transaction.ts +241 -0
  312. package/src/core/transactions/server-transaction.ts +47 -0
  313. package/src/core/transactions/transaction-state.ts +13 -0
  314. package/src/core/transactions/transaction-user.ts +82 -0
  315. package/src/core/transactions/transaction.ts +149 -0
  316. package/src/core/transport.ts +32 -0
  317. package/src/core/user-agent-core/allowed-methods.ts +19 -0
  318. package/src/core/user-agent-core/index.ts +3 -0
  319. package/src/core/user-agent-core/user-agent-core-configuration.ts +111 -0
  320. package/src/core/user-agent-core/user-agent-core-delegate.ts +50 -0
  321. package/src/core/user-agent-core/user-agent-core.ts +905 -0
  322. package/src/core/user-agents/bye-user-agent-client.ts +16 -0
  323. package/src/core/user-agents/bye-user-agent-server.ts +14 -0
  324. package/src/core/user-agents/cancel-user-agent-client.ts +14 -0
  325. package/src/core/user-agents/index.ts +26 -0
  326. package/src/core/user-agents/info-user-agent-client.ts +15 -0
  327. package/src/core/user-agents/info-user-agent-server.ts +14 -0
  328. package/src/core/user-agents/invite-user-agent-client.ts +405 -0
  329. package/src/core/user-agents/invite-user-agent-server.ts +269 -0
  330. package/src/core/user-agents/message-user-agent-client.ts +14 -0
  331. package/src/core/user-agents/message-user-agent-server.ts +14 -0
  332. package/src/core/user-agents/notify-user-agent-client.ts +15 -0
  333. package/src/core/user-agents/notify-user-agent-server.ts +30 -0
  334. package/src/core/user-agents/prack-user-agent-client.ts +16 -0
  335. package/src/core/user-agents/prack-user-agent-server.ts +37 -0
  336. package/src/core/user-agents/publish-user-agent-client.ts +14 -0
  337. package/src/core/user-agents/re-invite-user-agent-client.ts +127 -0
  338. package/src/core/user-agents/re-invite-user-agent-server.ts +109 -0
  339. package/src/core/user-agents/re-subscribe-user-agent-client.ts +78 -0
  340. package/src/core/user-agents/re-subscribe-user-agent-server.ts +14 -0
  341. package/src/core/user-agents/refer-user-agent-client.ts +15 -0
  342. package/src/core/user-agents/refer-user-agent-server.ts +30 -0
  343. package/src/core/user-agents/register-user-agent-client.ts +14 -0
  344. package/src/core/user-agents/register-user-agent-server.ts +14 -0
  345. package/src/core/user-agents/subscribe-user-agent-client.ts +341 -0
  346. package/src/core/user-agents/subscribe-user-agent-server.ts +14 -0
  347. package/src/core/user-agents/user-agent-client.ts +378 -0
  348. package/src/core/user-agents/user-agent-server.ts +276 -0
  349. package/src/grammar/grammar.ts +55 -0
  350. package/src/grammar/index.ts +4 -0
  351. package/src/grammar/name-addr-header.ts +58 -0
  352. package/src/grammar/parameters.ts +45 -0
  353. package/src/grammar/pegjs/README.md +9 -0
  354. package/src/grammar/pegjs/dist/grammar.ts +1557 -0
  355. package/src/grammar/pegjs/src/grammar.pegjs +1009 -0
  356. package/src/grammar/uri.ts +370 -0
  357. package/src/index.ts +49 -26
  358. package/src/lib/socket.io.esm.min.js +7 -0
  359. package/src/main.ts +26 -0
  360. package/src/new-index.ts +2478 -0
  361. package/src/platform/react/README.md +1 -0
  362. package/src/platform/web/index.ts +4 -0
  363. package/src/platform/web/modifiers/index.ts +5 -0
  364. package/src/platform/web/modifiers/modifiers.ts +180 -0
  365. package/src/platform/web/session-description-handler/api-extractor.json +358 -0
  366. package/src/platform/web/session-description-handler/index.ts +14 -0
  367. package/src/platform/web/session-description-handler/media-stream-factory-default.ts +22 -0
  368. package/src/platform/web/session-description-handler/media-stream-factory.ts +10 -0
  369. package/src/platform/web/session-description-handler/peer-connection-configuration-default.ts +17 -0
  370. package/src/platform/web/session-description-handler/peer-connection-delegate.ts +72 -0
  371. package/src/platform/web/session-description-handler/session-description-handler-configuration.ts +17 -0
  372. package/src/platform/web/session-description-handler/session-description-handler-factory-default.ts +45 -0
  373. package/src/platform/web/session-description-handler/session-description-handler-factory-options.ts +10 -0
  374. package/src/platform/web/session-description-handler/session-description-handler-factory.ts +17 -0
  375. package/src/platform/web/session-description-handler/session-description-handler-options.ts +56 -0
  376. package/src/platform/web/session-description-handler/session-description-handler.ts +938 -0
  377. package/src/platform/web/simple-user/api-extractor.json +358 -0
  378. package/src/platform/web/simple-user/index.ts +7 -0
  379. package/src/platform/web/simple-user/simple-user-delegate.ts +82 -0
  380. package/src/platform/web/simple-user/simple-user-options.ts +102 -0
  381. package/src/platform/web/simple-user/simple-user.ts +1099 -0
  382. package/src/platform/web/transport/api-extractor.json +358 -0
  383. package/src/platform/web/transport/index.ts +6 -0
  384. package/src/platform/web/transport/transport-options.ts +34 -0
  385. package/src/platform/web/transport/transport.ts +742 -0
  386. package/src/version.ts +8 -0
  387. package/src/webPhoneSdk.ts +67 -0
  388. package/src/webrtc.ts +318 -0
  389. package/tsconfig.json +26 -10
  390. /package/dist/{types/config.d.ts → config.d.ts} +0 -0
@@ -0,0 +1,200 @@
1
+ import { Contact, Logger, LoggerFactory, URI, UserAgentCore } from "../core";
2
+ import { Emitter } from "./emitter";
3
+ import { Inviter } from "./inviter";
4
+ import { InviterOptions } from "./inviter-options";
5
+ import { Publisher } from "./publisher";
6
+ import { Registerer } from "./registerer";
7
+ import { Session } from "./session";
8
+ import { Subscription } from "./subscription";
9
+ import { Transport } from "./transport";
10
+ import { UserAgentDelegate } from "./user-agent-delegate";
11
+ import { UserAgentOptions } from "./user-agent-options";
12
+ import { UserAgentState } from "./user-agent-state";
13
+ /**
14
+ * A user agent sends and receives requests using a `Transport`.
15
+ *
16
+ * @remarks
17
+ * A user agent (UA) is associated with a user via the user's SIP address of record (AOR)
18
+ * and acts on behalf of that user to send and receive SIP requests. The user agent can
19
+ * register to receive incoming requests, as well as create and send outbound messages.
20
+ * The user agent also maintains the Transport over which its signaling travels.
21
+ *
22
+ * @public
23
+ */
24
+ export declare class UserAgent {
25
+ /**
26
+ * Property reserved for use by instance owner.
27
+ * @defaultValue `undefined`
28
+ */
29
+ data: unknown;
30
+ /**
31
+ * Delegate.
32
+ */
33
+ delegate: UserAgentDelegate | undefined;
34
+ /** @internal */
35
+ _publishers: {
36
+ [id: string]: Publisher;
37
+ };
38
+ /** @internal */
39
+ _registerers: {
40
+ [id: string]: Registerer;
41
+ };
42
+ /** @internal */
43
+ _sessions: {
44
+ [id: string]: Session;
45
+ };
46
+ /** @internal */
47
+ _subscriptions: {
48
+ [id: string]: Subscription;
49
+ };
50
+ private _contact;
51
+ private _state;
52
+ private _stateEventEmitter;
53
+ private _transport;
54
+ private _userAgentCore;
55
+ /** Logger. */
56
+ private logger;
57
+ /** LoggerFactory. */
58
+ private loggerFactory;
59
+ /** Options. */
60
+ private options;
61
+ /**
62
+ * Constructs a new instance of the `UserAgent` class.
63
+ * @param options - Options bucket. See {@link UserAgentOptions} for details.
64
+ */
65
+ constructor(options?: Partial<UserAgentOptions>);
66
+ /**
67
+ * Create a URI instance from a string.
68
+ * @param uri - The string to parse.
69
+ *
70
+ * @example
71
+ * ```ts
72
+ * const uri = UserAgent.makeURI("sip:edgar@example.com");
73
+ * ```
74
+ */
75
+ static makeURI(uri: string): URI | undefined;
76
+ /** Default user agent options. */
77
+ private static defaultOptions;
78
+ /**
79
+ * Strip properties with undefined values from options.
80
+ * This is a work around while waiting for missing vs undefined to be addressed (or not)...
81
+ * https://github.com/Microsoft/TypeScript/issues/13195
82
+ * @param options - Options to reduce
83
+ */
84
+ private static stripUndefinedProperties;
85
+ /**
86
+ * User agent configuration.
87
+ */
88
+ get configuration(): Required<UserAgentOptions>;
89
+ /**
90
+ * User agent contact.
91
+ */
92
+ get contact(): Contact;
93
+ /**
94
+ * User agent state.
95
+ */
96
+ get state(): UserAgentState;
97
+ /**
98
+ * User agent state change emitter.
99
+ */
100
+ get stateChange(): Emitter<UserAgentState>;
101
+ /**
102
+ * User agent transport.
103
+ */
104
+ get transport(): Transport;
105
+ /**
106
+ * User agent core.
107
+ */
108
+ get userAgentCore(): UserAgentCore;
109
+ /**
110
+ * The logger.
111
+ */
112
+ getLogger(category: string, label?: string): Logger;
113
+ /**
114
+ * The logger factory.
115
+ */
116
+ getLoggerFactory(): LoggerFactory;
117
+ /**
118
+ * True if transport is connected.
119
+ */
120
+ isConnected(): boolean;
121
+ /**
122
+ * Reconnect the transport.
123
+ */
124
+ reconnect(): Promise<void>;
125
+ /**
126
+ * Start the user agent.
127
+ *
128
+ * @remarks
129
+ * Resolves if transport connects, otherwise rejects.
130
+ *
131
+ * @example
132
+ * ```ts
133
+ * userAgent.start()
134
+ * .then(() => {
135
+ * // userAgent.isConnected() === true
136
+ * })
137
+ * .catch((error: Error) => {
138
+ * // userAgent.isConnected() === false
139
+ * });
140
+ * ```
141
+ */
142
+ start(): Promise<void>;
143
+ /**
144
+ * Stop the user agent.
145
+ *
146
+ * @remarks
147
+ * Resolves when the user agent has completed a graceful shutdown.
148
+ * ```txt
149
+ * 1) Sessions terminate.
150
+ * 2) Registerers unregister.
151
+ * 3) Subscribers unsubscribe.
152
+ * 4) Publishers unpublish.
153
+ * 5) Transport disconnects.
154
+ * 6) User Agent Core resets.
155
+ * ```
156
+ * NOTE: While this is a "graceful shutdown", it can also be very slow one if you
157
+ * are waiting for the returned Promise to resolve. The disposal of the clients and
158
+ * dialogs is done serially - waiting on one to finish before moving on to the next.
159
+ * This can be slow if there are lot of subscriptions to unsubscribe for example.
160
+ *
161
+ * THE SLOW PACE IS INTENTIONAL!
162
+ * While one could spin them all down in parallel, this could slam the remote server.
163
+ * It is bad practice to denial of service attack (DoS attack) servers!!!
164
+ * Moreover, production servers will automatically blacklist clients which send too
165
+ * many requests in too short a period of time - dropping any additional requests.
166
+ *
167
+ * If a different approach to disposing is needed, one can implement whatever is
168
+ * needed and execute that prior to calling `stop()`. Alternatively one may simply
169
+ * not wait for the Promise returned by `stop()` to complete.
170
+ */
171
+ stop(): Promise<void>;
172
+ /**
173
+ * Used to avoid circular references.
174
+ * @internal
175
+ */
176
+ _makeInviter(targetURI: URI, options?: InviterOptions): Inviter;
177
+ /**
178
+ * Attempt reconnection up to `maxReconnectionAttempts` times.
179
+ * @param reconnectionAttempt - Current attempt number.
180
+ */
181
+ private attemptReconnection;
182
+ /**
183
+ * Initialize contact.
184
+ */
185
+ private initContact;
186
+ /**
187
+ * Initialize user agent core.
188
+ */
189
+ private initCore;
190
+ private initTransportCallbacks;
191
+ private onTransportConnect;
192
+ private onTransportDisconnect;
193
+ private onTransportMessage;
194
+ /**
195
+ * Transition state.
196
+ */
197
+ private transitionState;
198
+ /** Unload listener. */
199
+ private unloadListener;
200
+ }
@@ -0,0 +1,34 @@
1
+ import { URI } from "../../grammar";
2
+ /**
3
+ * Dialog state.
4
+ * @remarks
5
+ * A dialog contains certain pieces of state needed for further message
6
+ * transmissions within the dialog. This state consists of the dialog
7
+ * ID, a local sequence number (used to order requests from the UA to
8
+ * its peer), a remote sequence number (used to order requests from its
9
+ * peer to the UA), a local URI, a remote URI, remote target, a boolean
10
+ * flag called "secure", and a route set, which is an ordered list of
11
+ * URIs. The route set is the list of servers that need to be traversed
12
+ * to send a request to the peer. A dialog can also be in the "early"
13
+ * state, which occurs when it is created with a provisional response,
14
+ * and then transition to the "confirmed" state when a 2xx final
15
+ * response arrives. For other responses, or if no response arrives at
16
+ * all on that dialog, the early dialog terminates.
17
+ *
18
+ * https://tools.ietf.org/html/rfc3261#section-12
19
+ * @public
20
+ */
21
+ export interface DialogState {
22
+ id: string;
23
+ early: boolean;
24
+ callId: string;
25
+ localTag: string;
26
+ remoteTag: string;
27
+ localSequenceNumber: number | undefined;
28
+ remoteSequenceNumber: number | undefined;
29
+ localURI: URI;
30
+ remoteURI: URI;
31
+ remoteTarget: URI;
32
+ routeSet: Array<string>;
33
+ secure: boolean;
34
+ }
@@ -0,0 +1,161 @@
1
+ import { Body, IncomingRequestMessage, IncomingResponseMessage, OutgoingRequestMessage, URI } from "../messages";
2
+ import { UserAgentCore } from "../user-agent-core";
3
+ import { DialogState } from "./dialog-state";
4
+ /**
5
+ * Dialog.
6
+ * @remarks
7
+ * A key concept for a user agent is that of a dialog. A dialog
8
+ * represents a peer-to-peer SIP relationship between two user agents
9
+ * that persists for some time. The dialog facilitates sequencing of
10
+ * messages between the user agents and proper routing of requests
11
+ * between both of them. The dialog represents a context in which to
12
+ * interpret SIP messages.
13
+ * https://tools.ietf.org/html/rfc3261#section-12
14
+ * @public
15
+ */
16
+ export declare class Dialog {
17
+ protected core: UserAgentCore;
18
+ protected dialogState: DialogState;
19
+ /**
20
+ * Dialog constructor.
21
+ * @param core - User agent core.
22
+ * @param dialogState - Initial dialog state.
23
+ */
24
+ protected constructor(core: UserAgentCore, dialogState: DialogState);
25
+ /**
26
+ * When a UAC receives a response that establishes a dialog, it
27
+ * constructs the state of the dialog. This state MUST be maintained
28
+ * for the duration of the dialog.
29
+ * https://tools.ietf.org/html/rfc3261#section-12.1.2
30
+ * @param outgoingRequestMessage - Outgoing request message for dialog.
31
+ * @param incomingResponseMessage - Incoming response message creating dialog.
32
+ */
33
+ static initialDialogStateForUserAgentClient(outgoingRequestMessage: OutgoingRequestMessage, incomingResponseMessage: IncomingResponseMessage): DialogState;
34
+ /**
35
+ * The UAS then constructs the state of the dialog. This state MUST be
36
+ * maintained for the duration of the dialog.
37
+ * https://tools.ietf.org/html/rfc3261#section-12.1.1
38
+ * @param incomingRequestMessage - Incoming request message creating dialog.
39
+ * @param toTag - Tag in the To field in the response to the incoming request.
40
+ */
41
+ static initialDialogStateForUserAgentServer(incomingRequestMessage: IncomingRequestMessage, toTag: string, early?: boolean): DialogState;
42
+ /** Destructor. */
43
+ dispose(): void;
44
+ /**
45
+ * A dialog is identified at each UA with a dialog ID, which consists of
46
+ * a Call-ID value, a local tag and a remote tag. The dialog ID at each
47
+ * UA involved in the dialog is not the same. Specifically, the local
48
+ * tag at one UA is identical to the remote tag at the peer UA. The
49
+ * tags are opaque tokens that facilitate the generation of unique
50
+ * dialog IDs.
51
+ * https://tools.ietf.org/html/rfc3261#section-12
52
+ */
53
+ get id(): string;
54
+ /**
55
+ * A dialog can also be in the "early" state, which occurs when it is
56
+ * created with a provisional response, and then it transition to the
57
+ * "confirmed" state when a 2xx final response received or is sent.
58
+ *
59
+ * Note: RFC 3261 is concise on when a dialog is "confirmed", but it
60
+ * can be a point of confusion if an INVITE dialog is "confirmed" after
61
+ * a 2xx is sent or after receiving the ACK for the 2xx response.
62
+ * With careful reading it can be inferred a dialog is always is
63
+ * "confirmed" when the 2xx is sent (regardless of type of dialog).
64
+ * However a INVITE dialog does have additional considerations
65
+ * when it is confirmed but an ACK has not yet been received (in
66
+ * particular with regard to a callee sending BYE requests).
67
+ */
68
+ get early(): boolean;
69
+ /** Call identifier component of the dialog id. */
70
+ get callId(): string;
71
+ /** Local tag component of the dialog id. */
72
+ get localTag(): string;
73
+ /** Remote tag component of the dialog id. */
74
+ get remoteTag(): string;
75
+ /** Local sequence number (used to order requests from the UA to its peer). */
76
+ get localSequenceNumber(): number | undefined;
77
+ /** Remote sequence number (used to order requests from its peer to the UA). */
78
+ get remoteSequenceNumber(): number | undefined;
79
+ /** Local URI. */
80
+ get localURI(): URI;
81
+ /** Remote URI. */
82
+ get remoteURI(): URI;
83
+ /** Remote target. */
84
+ get remoteTarget(): URI;
85
+ /**
86
+ * Route set, which is an ordered list of URIs. The route set is the
87
+ * list of servers that need to be traversed to send a request to the peer.
88
+ */
89
+ get routeSet(): Array<string>;
90
+ /**
91
+ * If the request was sent over TLS, and the Request-URI contained
92
+ * a SIPS URI, the "secure" flag is set to true. *NOT IMPLEMENTED*
93
+ */
94
+ get secure(): boolean;
95
+ /** The user agent core servicing this dialog. */
96
+ get userAgentCore(): UserAgentCore;
97
+ /** Confirm the dialog. Only matters if dialog is currently early. */
98
+ confirm(): void;
99
+ /**
100
+ * Requests sent within a dialog, as any other requests, are atomic. If
101
+ * a particular request is accepted by the UAS, all the state changes
102
+ * associated with it are performed. If the request is rejected, none
103
+ * of the state changes are performed.
104
+ *
105
+ * Note that some requests, such as INVITEs, affect several pieces of
106
+ * state.
107
+ *
108
+ * https://tools.ietf.org/html/rfc3261#section-12.2.2
109
+ * @param message - Incoming request message within this dialog.
110
+ */
111
+ receiveRequest(message: IncomingRequestMessage): void;
112
+ /**
113
+ * If the dialog identifier in the 2xx response matches the dialog
114
+ * identifier of an existing dialog, the dialog MUST be transitioned to
115
+ * the "confirmed" state, and the route set for the dialog MUST be
116
+ * recomputed based on the 2xx response using the procedures of Section
117
+ * 12.2.1.2. Otherwise, a new dialog in the "confirmed" state MUST be
118
+ * constructed using the procedures of Section 12.1.2.
119
+ *
120
+ * Note that the only piece of state that is recomputed is the route
121
+ * set. Other pieces of state such as the highest sequence numbers
122
+ * (remote and local) sent within the dialog are not recomputed. The
123
+ * route set only is recomputed for backwards compatibility. RFC
124
+ * 2543 did not mandate mirroring of the Record-Route header field in
125
+ * a 1xx, only 2xx. However, we cannot update the entire state of
126
+ * the dialog, since mid-dialog requests may have been sent within
127
+ * the early dialog, modifying the sequence numbers, for example.
128
+ *
129
+ * https://tools.ietf.org/html/rfc3261#section-13.2.2.4
130
+ */
131
+ recomputeRouteSet(message: IncomingResponseMessage): void;
132
+ /**
133
+ * A request within a dialog is constructed by using many of the
134
+ * components of the state stored as part of the dialog.
135
+ * https://tools.ietf.org/html/rfc3261#section-12.2.1.1
136
+ * @param method - Outgoing request method.
137
+ */
138
+ createOutgoingRequestMessage(method: string, options?: {
139
+ cseq?: number;
140
+ extraHeaders?: Array<string>;
141
+ body?: Body;
142
+ }): OutgoingRequestMessage;
143
+ /**
144
+ * Increment the local sequence number by one.
145
+ * It feels like this should be protected, but the current authentication handling currently
146
+ * needs this to keep the dialog in sync when "auto re-sends" request messages.
147
+ * @internal
148
+ */
149
+ incrementLocalSequenceNumber(): void;
150
+ /**
151
+ * If the remote sequence number was not empty, but the sequence number
152
+ * of the request is lower than the remote sequence number, the request
153
+ * is out of order and MUST be rejected with a 500 (Server Internal
154
+ * Error) response.
155
+ * https://tools.ietf.org/html/rfc3261#section-12.2.2
156
+ * @param request - Incoming request to guard.
157
+ * @returns True if the program execution is to continue in the branch in question.
158
+ * Otherwise a 500 Server Internal Error was stateless sent and request processing must stop.
159
+ */
160
+ protected sequenceGuard(message: IncomingRequestMessage): boolean;
161
+ }
@@ -0,0 +1,4 @@
1
+ export * from "./dialog";
2
+ export * from "./dialog-state";
3
+ export * from "./session-dialog";
4
+ export * from "./subscription-dialog";
@@ -0,0 +1,196 @@
1
+ import { Body, IncomingRequestMessage, IncomingResponseMessage, OutgoingAckRequest, OutgoingByeRequest, OutgoingInfoRequest, OutgoingInviteRequest, OutgoingInviteRequestDelegate, OutgoingMessageRequest, OutgoingNotifyRequest, OutgoingPrackRequest, OutgoingReferRequest, OutgoingRequestDelegate, OutgoingRequestMessage, RequestOptions } from "../messages";
2
+ import { Session, SessionDelegate, SessionState, SignalingState } from "../session";
3
+ import { InviteClientTransaction, InviteServerTransaction } from "../transactions";
4
+ import { UserAgentCore } from "../user-agent-core";
5
+ import { ReInviteUserAgentClient } from "../user-agents/re-invite-user-agent-client";
6
+ import { ReInviteUserAgentServer } from "../user-agents/re-invite-user-agent-server";
7
+ import { Dialog } from "./dialog";
8
+ import { DialogState } from "./dialog-state";
9
+ /**
10
+ * Session Dialog.
11
+ * @public
12
+ */
13
+ export declare class SessionDialog extends Dialog implements Session {
14
+ private initialTransaction;
15
+ delegate: SessionDelegate | undefined;
16
+ reinviteUserAgentClient: ReInviteUserAgentClient | undefined;
17
+ reinviteUserAgentServer: ReInviteUserAgentServer | undefined;
18
+ /** The state of the offer/answer exchange. */
19
+ private _signalingState;
20
+ /** The current offer. Undefined unless signaling state HaveLocalOffer, HaveRemoteOffer, or Stable. */
21
+ private _offer;
22
+ /** The current answer. Undefined unless signaling state Stable. */
23
+ private _answer;
24
+ /** The rollback offer. Undefined unless signaling state HaveLocalOffer or HaveRemoteOffer. */
25
+ private _rollbackOffer;
26
+ /** The rollback answer. Undefined unless signaling state HaveLocalOffer or HaveRemoteOffer. */
27
+ private _rollbackAnswer;
28
+ /** True if waiting for an ACK to the initial transaction 2xx (UAS only). */
29
+ private ackWait;
30
+ /** True if processing an ACK to the initial transaction 2xx (UAS only). */
31
+ private ackProcessing;
32
+ /** Retransmission timer for 2xx response which confirmed the dialog. */
33
+ private invite2xxTimer;
34
+ /** The rseq of the last reliable response. */
35
+ private rseq;
36
+ private logger;
37
+ constructor(initialTransaction: InviteClientTransaction | InviteServerTransaction, core: UserAgentCore, state: DialogState, delegate?: SessionDelegate);
38
+ dispose(): void;
39
+ get sessionState(): SessionState;
40
+ /** The state of the offer/answer exchange. */
41
+ get signalingState(): SignalingState;
42
+ /** The current offer. Undefined unless signaling state HaveLocalOffer, HaveRemoteOffer, of Stable. */
43
+ get offer(): Body | undefined;
44
+ /** The current answer. Undefined unless signaling state Stable. */
45
+ get answer(): Body | undefined;
46
+ /** Confirm the dialog. Only matters if dialog is currently early. */
47
+ confirm(): void;
48
+ /** Re-confirm the dialog. Only matters if handling re-INVITE request. */
49
+ reConfirm(): void;
50
+ /**
51
+ * The UAC core MUST generate an ACK request for each 2xx received from
52
+ * the transaction layer. The header fields of the ACK are constructed
53
+ * in the same way as for any request sent within a dialog (see Section
54
+ * 12) with the exception of the CSeq and the header fields related to
55
+ * authentication. The sequence number of the CSeq header field MUST be
56
+ * the same as the INVITE being acknowledged, but the CSeq method MUST
57
+ * be ACK. The ACK MUST contain the same credentials as the INVITE. If
58
+ * the 2xx contains an offer (based on the rules above), the ACK MUST
59
+ * carry an answer in its body. If the offer in the 2xx response is not
60
+ * acceptable, the UAC core MUST generate a valid answer in the ACK and
61
+ * then send a BYE immediately.
62
+ * https://tools.ietf.org/html/rfc3261#section-13.2.2.4
63
+ * @param options - ACK options bucket.
64
+ */
65
+ ack(options?: RequestOptions): OutgoingAckRequest;
66
+ /**
67
+ * Terminating a Session
68
+ *
69
+ * This section describes the procedures for terminating a session
70
+ * established by SIP. The state of the session and the state of the
71
+ * dialog are very closely related. When a session is initiated with an
72
+ * INVITE, each 1xx or 2xx response from a distinct UAS creates a
73
+ * dialog, and if that response completes the offer/answer exchange, it
74
+ * also creates a session. As a result, each session is "associated"
75
+ * with a single dialog - the one which resulted in its creation. If an
76
+ * initial INVITE generates a non-2xx final response, that terminates
77
+ * all sessions (if any) and all dialogs (if any) that were created
78
+ * through responses to the request. By virtue of completing the
79
+ * transaction, a non-2xx final response also prevents further sessions
80
+ * from being created as a result of the INVITE. The BYE request is
81
+ * used to terminate a specific session or attempted session. In this
82
+ * case, the specific session is the one with the peer UA on the other
83
+ * side of the dialog. When a BYE is received on a dialog, any session
84
+ * associated with that dialog SHOULD terminate. A UA MUST NOT send a
85
+ * BYE outside of a dialog. The caller's UA MAY send a BYE for either
86
+ * confirmed or early dialogs, and the callee's UA MAY send a BYE on
87
+ * confirmed dialogs, but MUST NOT send a BYE on early dialogs.
88
+ *
89
+ * However, the callee's UA MUST NOT send a BYE on a confirmed dialog
90
+ * until it has received an ACK for its 2xx response or until the server
91
+ * transaction times out. If no SIP extensions have defined other
92
+ * application layer states associated with the dialog, the BYE also
93
+ * terminates the dialog.
94
+ *
95
+ * https://tools.ietf.org/html/rfc3261#section-15
96
+ * FIXME: Make these proper Exceptions...
97
+ * @param options - BYE options bucket.
98
+ * @returns
99
+ * Throws `Error` if callee's UA attempts a BYE on an early dialog.
100
+ * Throws `Error` if callee's UA attempts a BYE on a confirmed dialog
101
+ * while it's waiting on the ACK for its 2xx response.
102
+ */
103
+ bye(delegate?: OutgoingRequestDelegate, options?: RequestOptions): OutgoingByeRequest;
104
+ /**
105
+ * An INFO request can be associated with an Info Package (see
106
+ * Section 5), or associated with a legacy INFO usage (see Section 2).
107
+ *
108
+ * The construction of the INFO request is the same as any other
109
+ * non-target refresh request within an existing invite dialog usage as
110
+ * described in Section 12.2 of RFC 3261.
111
+ * https://tools.ietf.org/html/rfc6086#section-4.2.1
112
+ * @param options - Options bucket.
113
+ */
114
+ info(delegate?: OutgoingRequestDelegate, options?: RequestOptions): OutgoingInfoRequest;
115
+ /**
116
+ * Modifying an Existing Session
117
+ *
118
+ * A successful INVITE request (see Section 13) establishes both a
119
+ * dialog between two user agents and a session using the offer-answer
120
+ * model. Section 12 explains how to modify an existing dialog using a
121
+ * target refresh request (for example, changing the remote target URI
122
+ * of the dialog). This section describes how to modify the actual
123
+ * session. This modification can involve changing addresses or ports,
124
+ * adding a media stream, deleting a media stream, and so on. This is
125
+ * accomplished by sending a new INVITE request within the same dialog
126
+ * that established the session. An INVITE request sent within an
127
+ * existing dialog is known as a re-INVITE.
128
+ *
129
+ * Note that a single re-INVITE can modify the dialog and the
130
+ * parameters of the session at the same time.
131
+ *
132
+ * Either the caller or callee can modify an existing session.
133
+ * https://tools.ietf.org/html/rfc3261#section-14
134
+ * @param options - Options bucket
135
+ */
136
+ invite(delegate?: OutgoingInviteRequestDelegate, options?: RequestOptions): OutgoingInviteRequest;
137
+ /**
138
+ * A UAC MAY associate a MESSAGE request with an existing dialog. If a
139
+ * MESSAGE request is sent within a dialog, it is "associated" with any
140
+ * media session or sessions associated with that dialog.
141
+ * https://tools.ietf.org/html/rfc3428#section-4
142
+ * @param options - Options bucket.
143
+ */
144
+ message(delegate: OutgoingRequestDelegate, options?: RequestOptions): OutgoingMessageRequest;
145
+ /**
146
+ * The NOTIFY mechanism defined in [2] MUST be used to inform the agent
147
+ * sending the REFER of the status of the reference.
148
+ * https://tools.ietf.org/html/rfc3515#section-2.4.4
149
+ * @param options - Options bucket.
150
+ */
151
+ notify(delegate?: OutgoingRequestDelegate, options?: RequestOptions): OutgoingNotifyRequest;
152
+ /**
153
+ * Assuming the response is to be transmitted reliably, the UAC MUST
154
+ * create a new request with method PRACK. This request is sent within
155
+ * the dialog associated with the provisional response (indeed, the
156
+ * provisional response may have created the dialog). PRACK requests
157
+ * MAY contain bodies, which are interpreted according to their type and
158
+ * disposition.
159
+ * https://tools.ietf.org/html/rfc3262#section-4
160
+ * @param options - Options bucket.
161
+ */
162
+ prack(delegate?: OutgoingRequestDelegate, options?: RequestOptions): OutgoingPrackRequest;
163
+ /**
164
+ * REFER is a SIP request and is constructed as defined in [1]. A REFER
165
+ * request MUST contain exactly one Refer-To header field value.
166
+ * https://tools.ietf.org/html/rfc3515#section-2.4.1
167
+ * @param options - Options bucket.
168
+ */
169
+ refer(delegate?: OutgoingRequestDelegate, options?: RequestOptions): OutgoingReferRequest;
170
+ /**
171
+ * Requests sent within a dialog, as any other requests, are atomic. If
172
+ * a particular request is accepted by the UAS, all the state changes
173
+ * associated with it are performed. If the request is rejected, none
174
+ * of the state changes are performed.
175
+ * https://tools.ietf.org/html/rfc3261#section-12.2.2
176
+ * @param message - Incoming request message within this dialog.
177
+ */
178
+ receiveRequest(message: IncomingRequestMessage): void;
179
+ /**
180
+ * Guard against out of order reliable provisional responses and retransmissions.
181
+ * Returns false if the response should be discarded, otherwise true.
182
+ * @param message - Incoming response message within this dialog.
183
+ */
184
+ reliableSequenceGuard(message: IncomingResponseMessage): boolean;
185
+ /**
186
+ * If not in a stable signaling state, rollback to prior stable signaling state.
187
+ */
188
+ signalingStateRollback(): void;
189
+ /**
190
+ * Update the signaling state of the dialog.
191
+ * @param message - The message to base the update off of.
192
+ */
193
+ signalingStateTransition(message: IncomingRequestMessage | IncomingResponseMessage | OutgoingRequestMessage | Body): void;
194
+ private start2xxRetransmissionTimer;
195
+ private startReInvite2xxRetransmissionTimer;
196
+ }