@azure/notification-hubs 2.0.1-alpha.20241029.1 → 2.0.1-alpha.20241031.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 (526) hide show
  1. package/dist/api/notification-hubs.d.ts +8 -8
  2. package/dist/browser/api/beginSubmitNotificationHubJob.d.ts +3 -3
  3. package/dist/browser/api/beginSubmitNotificationHubJob.d.ts.map +1 -1
  4. package/dist/browser/api/beginSubmitNotificationHubJob.js.map +1 -1
  5. package/dist/browser/api/cancelScheduledNotification.d.ts +3 -3
  6. package/dist/browser/api/cancelScheduledNotification.d.ts.map +1 -1
  7. package/dist/browser/api/cancelScheduledNotification.js.map +1 -1
  8. package/dist/browser/api/clientContext.d.ts +2 -2
  9. package/dist/browser/api/clientContext.d.ts.map +1 -1
  10. package/dist/browser/api/clientContext.js +1 -1
  11. package/dist/browser/api/clientContext.js.map +1 -1
  12. package/dist/browser/api/createOrUpdateInstallation.d.ts +4 -4
  13. package/dist/browser/api/createOrUpdateInstallation.d.ts.map +1 -1
  14. package/dist/browser/api/createOrUpdateInstallation.js.map +1 -1
  15. package/dist/browser/api/createOrUpdateRegistration.d.ts +3 -3
  16. package/dist/browser/api/createOrUpdateRegistration.d.ts.map +1 -1
  17. package/dist/browser/api/createOrUpdateRegistration.js.map +1 -1
  18. package/dist/browser/api/createRegistration.d.ts +3 -3
  19. package/dist/browser/api/createRegistration.d.ts.map +1 -1
  20. package/dist/browser/api/createRegistration.js.map +1 -1
  21. package/dist/browser/api/createRegistrationId.d.ts +2 -2
  22. package/dist/browser/api/createRegistrationId.d.ts.map +1 -1
  23. package/dist/browser/api/createRegistrationId.js.map +1 -1
  24. package/dist/browser/api/deleteInstallation.d.ts +3 -3
  25. package/dist/browser/api/deleteInstallation.d.ts.map +1 -1
  26. package/dist/browser/api/deleteInstallation.js.map +1 -1
  27. package/dist/browser/api/deleteRegistration.d.ts +3 -3
  28. package/dist/browser/api/deleteRegistration.d.ts.map +1 -1
  29. package/dist/browser/api/deleteRegistration.js.map +1 -1
  30. package/dist/browser/api/getFeedbackContainerUrl.d.ts +2 -2
  31. package/dist/browser/api/getFeedbackContainerUrl.d.ts.map +1 -1
  32. package/dist/browser/api/getFeedbackContainerUrl.js.map +1 -1
  33. package/dist/browser/api/getInstallation.d.ts +3 -3
  34. package/dist/browser/api/getInstallation.d.ts.map +1 -1
  35. package/dist/browser/api/getInstallation.js.map +1 -1
  36. package/dist/browser/api/getNotificationHubJob.d.ts +3 -3
  37. package/dist/browser/api/getNotificationHubJob.d.ts.map +1 -1
  38. package/dist/browser/api/getNotificationHubJob.js.map +1 -1
  39. package/dist/browser/api/getNotificationOutcomeDetails.d.ts +3 -3
  40. package/dist/browser/api/getNotificationOutcomeDetails.d.ts.map +1 -1
  41. package/dist/browser/api/getNotificationOutcomeDetails.js.map +1 -1
  42. package/dist/browser/api/getRegistration.d.ts +3 -3
  43. package/dist/browser/api/getRegistration.d.ts.map +1 -1
  44. package/dist/browser/api/getRegistration.js.map +1 -1
  45. package/dist/browser/api/internal/_client.d.ts +4 -4
  46. package/dist/browser/api/internal/_client.d.ts.map +1 -1
  47. package/dist/browser/api/internal/_client.js +1 -1
  48. package/dist/browser/api/internal/_client.js.map +1 -1
  49. package/dist/browser/api/internal/_createOrUpdateRegistrationDescription.d.ts +3 -3
  50. package/dist/browser/api/internal/_createOrUpdateRegistrationDescription.d.ts.map +1 -1
  51. package/dist/browser/api/internal/_createOrUpdateRegistrationDescription.js.map +1 -1
  52. package/dist/browser/api/internal/_listRegistrations.d.ts +3 -3
  53. package/dist/browser/api/internal/_listRegistrations.d.ts.map +1 -1
  54. package/dist/browser/api/internal/_listRegistrations.js.map +1 -1
  55. package/dist/browser/api/internal/_scheduleNotification.d.ts +4 -4
  56. package/dist/browser/api/internal/_scheduleNotification.d.ts.map +1 -1
  57. package/dist/browser/api/internal/_scheduleNotification.js.map +1 -1
  58. package/dist/browser/api/internal/_sendNotification.d.ts +4 -4
  59. package/dist/browser/api/internal/_sendNotification.d.ts.map +1 -1
  60. package/dist/browser/api/internal/_sendNotification.js.map +1 -1
  61. package/dist/browser/api/listNotificationHubJobs.d.ts +3 -3
  62. package/dist/browser/api/listNotificationHubJobs.d.ts.map +1 -1
  63. package/dist/browser/api/listNotificationHubJobs.js.map +1 -1
  64. package/dist/browser/api/listRegistrations.d.ts +4 -4
  65. package/dist/browser/api/listRegistrations.d.ts.map +1 -1
  66. package/dist/browser/api/listRegistrations.js.map +1 -1
  67. package/dist/browser/api/listRegistrationsByChannel.d.ts +4 -4
  68. package/dist/browser/api/listRegistrationsByChannel.d.ts.map +1 -1
  69. package/dist/browser/api/listRegistrationsByChannel.js.map +1 -1
  70. package/dist/browser/api/listRegistrationsByTag.d.ts +4 -4
  71. package/dist/browser/api/listRegistrationsByTag.d.ts.map +1 -1
  72. package/dist/browser/api/listRegistrationsByTag.js.map +1 -1
  73. package/dist/browser/api/scheduleBroadcastNotification.d.ts +4 -4
  74. package/dist/browser/api/scheduleBroadcastNotification.d.ts.map +1 -1
  75. package/dist/browser/api/scheduleBroadcastNotification.js.map +1 -1
  76. package/dist/browser/api/scheduleNotification.d.ts +4 -4
  77. package/dist/browser/api/scheduleNotification.d.ts.map +1 -1
  78. package/dist/browser/api/scheduleNotification.js.map +1 -1
  79. package/dist/browser/api/sendBroadcastNotification.d.ts +4 -4
  80. package/dist/browser/api/sendBroadcastNotification.d.ts.map +1 -1
  81. package/dist/browser/api/sendBroadcastNotification.js.map +1 -1
  82. package/dist/browser/api/sendNotification.d.ts +4 -4
  83. package/dist/browser/api/sendNotification.d.ts.map +1 -1
  84. package/dist/browser/api/sendNotification.js.map +1 -1
  85. package/dist/browser/api/submitNotificationHubJob.d.ts +3 -3
  86. package/dist/browser/api/submitNotificationHubJob.d.ts.map +1 -1
  87. package/dist/browser/api/submitNotificationHubJob.js.map +1 -1
  88. package/dist/browser/api/updateInstallation.d.ts +4 -4
  89. package/dist/browser/api/updateInstallation.d.ts.map +1 -1
  90. package/dist/browser/api/updateInstallation.js.map +1 -1
  91. package/dist/browser/api/updateRegistration.d.ts +3 -3
  92. package/dist/browser/api/updateRegistration.d.ts.map +1 -1
  93. package/dist/browser/api/updateRegistration.js.map +1 -1
  94. package/dist/browser/auth/sasTokenCredential.d.ts +1 -1
  95. package/dist/browser/auth/sasTokenCredential.d.ts.map +1 -1
  96. package/dist/browser/auth/sasTokenCredential.js.map +1 -1
  97. package/dist/browser/models/notification.d.ts +2 -2
  98. package/dist/browser/models/notification.d.ts.map +1 -1
  99. package/dist/browser/models/notification.js.map +1 -1
  100. package/dist/browser/models/notificationHubJob.d.ts +1 -1
  101. package/dist/browser/models/notificationHubJob.d.ts.map +1 -1
  102. package/dist/browser/models/notificationHubJob.js.map +1 -1
  103. package/dist/browser/models/options.d.ts +2 -2
  104. package/dist/browser/models/options.d.ts.map +1 -1
  105. package/dist/browser/models/options.js.map +1 -1
  106. package/dist/browser/models/response.d.ts +1 -1
  107. package/dist/browser/models/response.d.ts.map +1 -1
  108. package/dist/browser/models/response.js.map +1 -1
  109. package/dist/browser/notificationHubsClient.d.ts +8 -8
  110. package/dist/browser/notificationHubsClient.d.ts.map +1 -1
  111. package/dist/browser/notificationHubsClient.js.map +1 -1
  112. package/dist/browser/serializers/notificationDetailsSerializer.d.ts +1 -1
  113. package/dist/browser/serializers/notificationDetailsSerializer.d.ts.map +1 -1
  114. package/dist/browser/serializers/notificationDetailsSerializer.js.map +1 -1
  115. package/dist/browser/serializers/notificationHubJobSerializer.d.ts +1 -1
  116. package/dist/browser/serializers/notificationHubJobSerializer.d.ts.map +1 -1
  117. package/dist/browser/serializers/notificationHubJobSerializer.js.map +1 -1
  118. package/dist/browser/serializers/notificationOutcomeSerializer.d.ts +1 -1
  119. package/dist/browser/serializers/notificationOutcomeSerializer.d.ts.map +1 -1
  120. package/dist/browser/serializers/notificationOutcomeSerializer.js.map +1 -1
  121. package/dist/browser/serializers/registrationSerializer.d.ts +1 -1
  122. package/dist/browser/serializers/registrationSerializer.d.ts.map +1 -1
  123. package/dist/browser/serializers/registrationSerializer.js.map +1 -1
  124. package/dist/browser/utils/notificationUtils.d.ts +1 -1
  125. package/dist/browser/utils/notificationUtils.d.ts.map +1 -1
  126. package/dist/browser/utils/notificationUtils.js.map +1 -1
  127. package/dist/browser/utils/optionUtils.d.ts +1 -1
  128. package/dist/browser/utils/optionUtils.d.ts.map +1 -1
  129. package/dist/browser/utils/optionUtils.js.map +1 -1
  130. package/dist/browser/utils/registrationUtils.d.ts +1 -1
  131. package/dist/browser/utils/registrationUtils.d.ts.map +1 -1
  132. package/dist/browser/utils/registrationUtils.js.map +1 -1
  133. package/dist/commonjs/api/beginSubmitNotificationHubJob.d.ts +3 -3
  134. package/dist/commonjs/api/beginSubmitNotificationHubJob.d.ts.map +1 -1
  135. package/dist/commonjs/api/beginSubmitNotificationHubJob.js.map +1 -1
  136. package/dist/commonjs/api/cancelScheduledNotification.d.ts +3 -3
  137. package/dist/commonjs/api/cancelScheduledNotification.d.ts.map +1 -1
  138. package/dist/commonjs/api/cancelScheduledNotification.js.map +1 -1
  139. package/dist/commonjs/api/clientContext.d.ts +2 -2
  140. package/dist/commonjs/api/clientContext.d.ts.map +1 -1
  141. package/dist/commonjs/api/clientContext.js.map +1 -1
  142. package/dist/commonjs/api/createOrUpdateInstallation.d.ts +4 -4
  143. package/dist/commonjs/api/createOrUpdateInstallation.d.ts.map +1 -1
  144. package/dist/commonjs/api/createOrUpdateInstallation.js.map +1 -1
  145. package/dist/commonjs/api/createOrUpdateRegistration.d.ts +3 -3
  146. package/dist/commonjs/api/createOrUpdateRegistration.d.ts.map +1 -1
  147. package/dist/commonjs/api/createOrUpdateRegistration.js.map +1 -1
  148. package/dist/commonjs/api/createRegistration.d.ts +3 -3
  149. package/dist/commonjs/api/createRegistration.d.ts.map +1 -1
  150. package/dist/commonjs/api/createRegistration.js.map +1 -1
  151. package/dist/commonjs/api/createRegistrationId.d.ts +2 -2
  152. package/dist/commonjs/api/createRegistrationId.d.ts.map +1 -1
  153. package/dist/commonjs/api/createRegistrationId.js.map +1 -1
  154. package/dist/commonjs/api/deleteInstallation.d.ts +3 -3
  155. package/dist/commonjs/api/deleteInstallation.d.ts.map +1 -1
  156. package/dist/commonjs/api/deleteInstallation.js.map +1 -1
  157. package/dist/commonjs/api/deleteRegistration.d.ts +3 -3
  158. package/dist/commonjs/api/deleteRegistration.d.ts.map +1 -1
  159. package/dist/commonjs/api/deleteRegistration.js.map +1 -1
  160. package/dist/commonjs/api/getFeedbackContainerUrl.d.ts +2 -2
  161. package/dist/commonjs/api/getFeedbackContainerUrl.d.ts.map +1 -1
  162. package/dist/commonjs/api/getFeedbackContainerUrl.js.map +1 -1
  163. package/dist/commonjs/api/getInstallation.d.ts +3 -3
  164. package/dist/commonjs/api/getInstallation.d.ts.map +1 -1
  165. package/dist/commonjs/api/getInstallation.js.map +1 -1
  166. package/dist/commonjs/api/getNotificationHubJob.d.ts +3 -3
  167. package/dist/commonjs/api/getNotificationHubJob.d.ts.map +1 -1
  168. package/dist/commonjs/api/getNotificationHubJob.js.map +1 -1
  169. package/dist/commonjs/api/getNotificationOutcomeDetails.d.ts +3 -3
  170. package/dist/commonjs/api/getNotificationOutcomeDetails.d.ts.map +1 -1
  171. package/dist/commonjs/api/getNotificationOutcomeDetails.js.map +1 -1
  172. package/dist/commonjs/api/getRegistration.d.ts +3 -3
  173. package/dist/commonjs/api/getRegistration.d.ts.map +1 -1
  174. package/dist/commonjs/api/getRegistration.js.map +1 -1
  175. package/dist/commonjs/api/internal/_client.d.ts +4 -4
  176. package/dist/commonjs/api/internal/_client.d.ts.map +1 -1
  177. package/dist/commonjs/api/internal/_client.js.map +1 -1
  178. package/dist/commonjs/api/internal/_createOrUpdateRegistrationDescription.d.ts +3 -3
  179. package/dist/commonjs/api/internal/_createOrUpdateRegistrationDescription.d.ts.map +1 -1
  180. package/dist/commonjs/api/internal/_createOrUpdateRegistrationDescription.js.map +1 -1
  181. package/dist/commonjs/api/internal/_listRegistrations.d.ts +3 -3
  182. package/dist/commonjs/api/internal/_listRegistrations.d.ts.map +1 -1
  183. package/dist/commonjs/api/internal/_listRegistrations.js.map +1 -1
  184. package/dist/commonjs/api/internal/_scheduleNotification.d.ts +4 -4
  185. package/dist/commonjs/api/internal/_scheduleNotification.d.ts.map +1 -1
  186. package/dist/commonjs/api/internal/_scheduleNotification.js.map +1 -1
  187. package/dist/commonjs/api/internal/_sendNotification.d.ts +4 -4
  188. package/dist/commonjs/api/internal/_sendNotification.d.ts.map +1 -1
  189. package/dist/commonjs/api/internal/_sendNotification.js.map +1 -1
  190. package/dist/commonjs/api/listNotificationHubJobs.d.ts +3 -3
  191. package/dist/commonjs/api/listNotificationHubJobs.d.ts.map +1 -1
  192. package/dist/commonjs/api/listNotificationHubJobs.js.map +1 -1
  193. package/dist/commonjs/api/listRegistrations.d.ts +4 -4
  194. package/dist/commonjs/api/listRegistrations.d.ts.map +1 -1
  195. package/dist/commonjs/api/listRegistrations.js.map +1 -1
  196. package/dist/commonjs/api/listRegistrationsByChannel.d.ts +4 -4
  197. package/dist/commonjs/api/listRegistrationsByChannel.d.ts.map +1 -1
  198. package/dist/commonjs/api/listRegistrationsByChannel.js.map +1 -1
  199. package/dist/commonjs/api/listRegistrationsByTag.d.ts +4 -4
  200. package/dist/commonjs/api/listRegistrationsByTag.d.ts.map +1 -1
  201. package/dist/commonjs/api/listRegistrationsByTag.js.map +1 -1
  202. package/dist/commonjs/api/scheduleBroadcastNotification.d.ts +4 -4
  203. package/dist/commonjs/api/scheduleBroadcastNotification.d.ts.map +1 -1
  204. package/dist/commonjs/api/scheduleBroadcastNotification.js.map +1 -1
  205. package/dist/commonjs/api/scheduleNotification.d.ts +4 -4
  206. package/dist/commonjs/api/scheduleNotification.d.ts.map +1 -1
  207. package/dist/commonjs/api/scheduleNotification.js.map +1 -1
  208. package/dist/commonjs/api/sendBroadcastNotification.d.ts +4 -4
  209. package/dist/commonjs/api/sendBroadcastNotification.d.ts.map +1 -1
  210. package/dist/commonjs/api/sendBroadcastNotification.js.map +1 -1
  211. package/dist/commonjs/api/sendNotification.d.ts +4 -4
  212. package/dist/commonjs/api/sendNotification.d.ts.map +1 -1
  213. package/dist/commonjs/api/sendNotification.js.map +1 -1
  214. package/dist/commonjs/api/submitNotificationHubJob.d.ts +3 -3
  215. package/dist/commonjs/api/submitNotificationHubJob.d.ts.map +1 -1
  216. package/dist/commonjs/api/submitNotificationHubJob.js.map +1 -1
  217. package/dist/commonjs/api/updateInstallation.d.ts +4 -4
  218. package/dist/commonjs/api/updateInstallation.d.ts.map +1 -1
  219. package/dist/commonjs/api/updateInstallation.js.map +1 -1
  220. package/dist/commonjs/api/updateRegistration.d.ts +3 -3
  221. package/dist/commonjs/api/updateRegistration.d.ts.map +1 -1
  222. package/dist/commonjs/api/updateRegistration.js.map +1 -1
  223. package/dist/commonjs/auth/sasTokenCredential.d.ts +1 -1
  224. package/dist/commonjs/auth/sasTokenCredential.d.ts.map +1 -1
  225. package/dist/commonjs/auth/sasTokenCredential.js.map +1 -1
  226. package/dist/commonjs/models/notification.d.ts +2 -2
  227. package/dist/commonjs/models/notification.d.ts.map +1 -1
  228. package/dist/commonjs/models/notification.js.map +1 -1
  229. package/dist/commonjs/models/notificationHubJob.d.ts +1 -1
  230. package/dist/commonjs/models/notificationHubJob.d.ts.map +1 -1
  231. package/dist/commonjs/models/notificationHubJob.js.map +1 -1
  232. package/dist/commonjs/models/options.d.ts +2 -2
  233. package/dist/commonjs/models/options.d.ts.map +1 -1
  234. package/dist/commonjs/models/options.js.map +1 -1
  235. package/dist/commonjs/models/response.d.ts +1 -1
  236. package/dist/commonjs/models/response.d.ts.map +1 -1
  237. package/dist/commonjs/models/response.js.map +1 -1
  238. package/dist/commonjs/notificationHubsClient.d.ts +8 -8
  239. package/dist/commonjs/notificationHubsClient.d.ts.map +1 -1
  240. package/dist/commonjs/notificationHubsClient.js.map +1 -1
  241. package/dist/commonjs/serializers/notificationDetailsSerializer.d.ts +1 -1
  242. package/dist/commonjs/serializers/notificationDetailsSerializer.d.ts.map +1 -1
  243. package/dist/commonjs/serializers/notificationDetailsSerializer.js.map +1 -1
  244. package/dist/commonjs/serializers/notificationHubJobSerializer.d.ts +1 -1
  245. package/dist/commonjs/serializers/notificationHubJobSerializer.d.ts.map +1 -1
  246. package/dist/commonjs/serializers/notificationHubJobSerializer.js.map +1 -1
  247. package/dist/commonjs/serializers/notificationOutcomeSerializer.d.ts +1 -1
  248. package/dist/commonjs/serializers/notificationOutcomeSerializer.d.ts.map +1 -1
  249. package/dist/commonjs/serializers/notificationOutcomeSerializer.js.map +1 -1
  250. package/dist/commonjs/serializers/registrationSerializer.d.ts +1 -1
  251. package/dist/commonjs/serializers/registrationSerializer.d.ts.map +1 -1
  252. package/dist/commonjs/serializers/registrationSerializer.js.map +1 -1
  253. package/dist/commonjs/utils/notificationUtils.d.ts +1 -1
  254. package/dist/commonjs/utils/notificationUtils.d.ts.map +1 -1
  255. package/dist/commonjs/utils/notificationUtils.js.map +1 -1
  256. package/dist/commonjs/utils/optionUtils.d.ts +1 -1
  257. package/dist/commonjs/utils/optionUtils.d.ts.map +1 -1
  258. package/dist/commonjs/utils/optionUtils.js.map +1 -1
  259. package/dist/commonjs/utils/registrationUtils.d.ts +1 -1
  260. package/dist/commonjs/utils/registrationUtils.d.ts.map +1 -1
  261. package/dist/commonjs/utils/registrationUtils.js.map +1 -1
  262. package/dist/esm/api/beginSubmitNotificationHubJob.d.ts +3 -3
  263. package/dist/esm/api/beginSubmitNotificationHubJob.d.ts.map +1 -1
  264. package/dist/esm/api/beginSubmitNotificationHubJob.js.map +1 -1
  265. package/dist/esm/api/cancelScheduledNotification.d.ts +3 -3
  266. package/dist/esm/api/cancelScheduledNotification.d.ts.map +1 -1
  267. package/dist/esm/api/cancelScheduledNotification.js.map +1 -1
  268. package/dist/esm/api/clientContext.d.ts +2 -2
  269. package/dist/esm/api/clientContext.d.ts.map +1 -1
  270. package/dist/esm/api/clientContext.js +1 -1
  271. package/dist/esm/api/clientContext.js.map +1 -1
  272. package/dist/esm/api/createOrUpdateInstallation.d.ts +4 -4
  273. package/dist/esm/api/createOrUpdateInstallation.d.ts.map +1 -1
  274. package/dist/esm/api/createOrUpdateInstallation.js.map +1 -1
  275. package/dist/esm/api/createOrUpdateRegistration.d.ts +3 -3
  276. package/dist/esm/api/createOrUpdateRegistration.d.ts.map +1 -1
  277. package/dist/esm/api/createOrUpdateRegistration.js.map +1 -1
  278. package/dist/esm/api/createRegistration.d.ts +3 -3
  279. package/dist/esm/api/createRegistration.d.ts.map +1 -1
  280. package/dist/esm/api/createRegistration.js.map +1 -1
  281. package/dist/esm/api/createRegistrationId.d.ts +2 -2
  282. package/dist/esm/api/createRegistrationId.d.ts.map +1 -1
  283. package/dist/esm/api/createRegistrationId.js.map +1 -1
  284. package/dist/esm/api/deleteInstallation.d.ts +3 -3
  285. package/dist/esm/api/deleteInstallation.d.ts.map +1 -1
  286. package/dist/esm/api/deleteInstallation.js.map +1 -1
  287. package/dist/esm/api/deleteRegistration.d.ts +3 -3
  288. package/dist/esm/api/deleteRegistration.d.ts.map +1 -1
  289. package/dist/esm/api/deleteRegistration.js.map +1 -1
  290. package/dist/esm/api/getFeedbackContainerUrl.d.ts +2 -2
  291. package/dist/esm/api/getFeedbackContainerUrl.d.ts.map +1 -1
  292. package/dist/esm/api/getFeedbackContainerUrl.js.map +1 -1
  293. package/dist/esm/api/getInstallation.d.ts +3 -3
  294. package/dist/esm/api/getInstallation.d.ts.map +1 -1
  295. package/dist/esm/api/getInstallation.js.map +1 -1
  296. package/dist/esm/api/getNotificationHubJob.d.ts +3 -3
  297. package/dist/esm/api/getNotificationHubJob.d.ts.map +1 -1
  298. package/dist/esm/api/getNotificationHubJob.js.map +1 -1
  299. package/dist/esm/api/getNotificationOutcomeDetails.d.ts +3 -3
  300. package/dist/esm/api/getNotificationOutcomeDetails.d.ts.map +1 -1
  301. package/dist/esm/api/getNotificationOutcomeDetails.js.map +1 -1
  302. package/dist/esm/api/getRegistration.d.ts +3 -3
  303. package/dist/esm/api/getRegistration.d.ts.map +1 -1
  304. package/dist/esm/api/getRegistration.js.map +1 -1
  305. package/dist/esm/api/internal/_client.d.ts +4 -4
  306. package/dist/esm/api/internal/_client.d.ts.map +1 -1
  307. package/dist/esm/api/internal/_client.js +1 -1
  308. package/dist/esm/api/internal/_client.js.map +1 -1
  309. package/dist/esm/api/internal/_createOrUpdateRegistrationDescription.d.ts +3 -3
  310. package/dist/esm/api/internal/_createOrUpdateRegistrationDescription.d.ts.map +1 -1
  311. package/dist/esm/api/internal/_createOrUpdateRegistrationDescription.js.map +1 -1
  312. package/dist/esm/api/internal/_listRegistrations.d.ts +3 -3
  313. package/dist/esm/api/internal/_listRegistrations.d.ts.map +1 -1
  314. package/dist/esm/api/internal/_listRegistrations.js.map +1 -1
  315. package/dist/esm/api/internal/_scheduleNotification.d.ts +4 -4
  316. package/dist/esm/api/internal/_scheduleNotification.d.ts.map +1 -1
  317. package/dist/esm/api/internal/_scheduleNotification.js.map +1 -1
  318. package/dist/esm/api/internal/_sendNotification.d.ts +4 -4
  319. package/dist/esm/api/internal/_sendNotification.d.ts.map +1 -1
  320. package/dist/esm/api/internal/_sendNotification.js.map +1 -1
  321. package/dist/esm/api/listNotificationHubJobs.d.ts +3 -3
  322. package/dist/esm/api/listNotificationHubJobs.d.ts.map +1 -1
  323. package/dist/esm/api/listNotificationHubJobs.js.map +1 -1
  324. package/dist/esm/api/listRegistrations.d.ts +4 -4
  325. package/dist/esm/api/listRegistrations.d.ts.map +1 -1
  326. package/dist/esm/api/listRegistrations.js.map +1 -1
  327. package/dist/esm/api/listRegistrationsByChannel.d.ts +4 -4
  328. package/dist/esm/api/listRegistrationsByChannel.d.ts.map +1 -1
  329. package/dist/esm/api/listRegistrationsByChannel.js.map +1 -1
  330. package/dist/esm/api/listRegistrationsByTag.d.ts +4 -4
  331. package/dist/esm/api/listRegistrationsByTag.d.ts.map +1 -1
  332. package/dist/esm/api/listRegistrationsByTag.js.map +1 -1
  333. package/dist/esm/api/scheduleBroadcastNotification.d.ts +4 -4
  334. package/dist/esm/api/scheduleBroadcastNotification.d.ts.map +1 -1
  335. package/dist/esm/api/scheduleBroadcastNotification.js.map +1 -1
  336. package/dist/esm/api/scheduleNotification.d.ts +4 -4
  337. package/dist/esm/api/scheduleNotification.d.ts.map +1 -1
  338. package/dist/esm/api/scheduleNotification.js.map +1 -1
  339. package/dist/esm/api/sendBroadcastNotification.d.ts +4 -4
  340. package/dist/esm/api/sendBroadcastNotification.d.ts.map +1 -1
  341. package/dist/esm/api/sendBroadcastNotification.js.map +1 -1
  342. package/dist/esm/api/sendNotification.d.ts +4 -4
  343. package/dist/esm/api/sendNotification.d.ts.map +1 -1
  344. package/dist/esm/api/sendNotification.js.map +1 -1
  345. package/dist/esm/api/submitNotificationHubJob.d.ts +3 -3
  346. package/dist/esm/api/submitNotificationHubJob.d.ts.map +1 -1
  347. package/dist/esm/api/submitNotificationHubJob.js.map +1 -1
  348. package/dist/esm/api/updateInstallation.d.ts +4 -4
  349. package/dist/esm/api/updateInstallation.d.ts.map +1 -1
  350. package/dist/esm/api/updateInstallation.js.map +1 -1
  351. package/dist/esm/api/updateRegistration.d.ts +3 -3
  352. package/dist/esm/api/updateRegistration.d.ts.map +1 -1
  353. package/dist/esm/api/updateRegistration.js.map +1 -1
  354. package/dist/esm/auth/sasTokenCredential.d.ts +1 -1
  355. package/dist/esm/auth/sasTokenCredential.d.ts.map +1 -1
  356. package/dist/esm/auth/sasTokenCredential.js.map +1 -1
  357. package/dist/esm/models/notification.d.ts +2 -2
  358. package/dist/esm/models/notification.d.ts.map +1 -1
  359. package/dist/esm/models/notification.js.map +1 -1
  360. package/dist/esm/models/notificationHubJob.d.ts +1 -1
  361. package/dist/esm/models/notificationHubJob.d.ts.map +1 -1
  362. package/dist/esm/models/notificationHubJob.js.map +1 -1
  363. package/dist/esm/models/options.d.ts +2 -2
  364. package/dist/esm/models/options.d.ts.map +1 -1
  365. package/dist/esm/models/options.js.map +1 -1
  366. package/dist/esm/models/response.d.ts +1 -1
  367. package/dist/esm/models/response.d.ts.map +1 -1
  368. package/dist/esm/models/response.js.map +1 -1
  369. package/dist/esm/notificationHubsClient.d.ts +8 -8
  370. package/dist/esm/notificationHubsClient.d.ts.map +1 -1
  371. package/dist/esm/notificationHubsClient.js.map +1 -1
  372. package/dist/esm/serializers/notificationDetailsSerializer.d.ts +1 -1
  373. package/dist/esm/serializers/notificationDetailsSerializer.d.ts.map +1 -1
  374. package/dist/esm/serializers/notificationDetailsSerializer.js.map +1 -1
  375. package/dist/esm/serializers/notificationHubJobSerializer.d.ts +1 -1
  376. package/dist/esm/serializers/notificationHubJobSerializer.d.ts.map +1 -1
  377. package/dist/esm/serializers/notificationHubJobSerializer.js.map +1 -1
  378. package/dist/esm/serializers/notificationOutcomeSerializer.d.ts +1 -1
  379. package/dist/esm/serializers/notificationOutcomeSerializer.d.ts.map +1 -1
  380. package/dist/esm/serializers/notificationOutcomeSerializer.js.map +1 -1
  381. package/dist/esm/serializers/registrationSerializer.d.ts +1 -1
  382. package/dist/esm/serializers/registrationSerializer.d.ts.map +1 -1
  383. package/dist/esm/serializers/registrationSerializer.js.map +1 -1
  384. package/dist/esm/utils/notificationUtils.d.ts +1 -1
  385. package/dist/esm/utils/notificationUtils.d.ts.map +1 -1
  386. package/dist/esm/utils/notificationUtils.js.map +1 -1
  387. package/dist/esm/utils/optionUtils.d.ts +1 -1
  388. package/dist/esm/utils/optionUtils.d.ts.map +1 -1
  389. package/dist/esm/utils/optionUtils.js.map +1 -1
  390. package/dist/esm/utils/registrationUtils.d.ts +1 -1
  391. package/dist/esm/utils/registrationUtils.d.ts.map +1 -1
  392. package/dist/esm/utils/registrationUtils.js.map +1 -1
  393. package/dist/models/notification-hubs.d.ts +4 -4
  394. package/dist/notification-hubs.d.ts +5 -5
  395. package/dist/react-native/api/beginSubmitNotificationHubJob.d.ts +3 -3
  396. package/dist/react-native/api/beginSubmitNotificationHubJob.d.ts.map +1 -1
  397. package/dist/react-native/api/beginSubmitNotificationHubJob.js.map +1 -1
  398. package/dist/react-native/api/cancelScheduledNotification.d.ts +3 -3
  399. package/dist/react-native/api/cancelScheduledNotification.d.ts.map +1 -1
  400. package/dist/react-native/api/cancelScheduledNotification.js.map +1 -1
  401. package/dist/react-native/api/clientContext.d.ts +2 -2
  402. package/dist/react-native/api/clientContext.d.ts.map +1 -1
  403. package/dist/react-native/api/clientContext.js +1 -1
  404. package/dist/react-native/api/clientContext.js.map +1 -1
  405. package/dist/react-native/api/createOrUpdateInstallation.d.ts +4 -4
  406. package/dist/react-native/api/createOrUpdateInstallation.d.ts.map +1 -1
  407. package/dist/react-native/api/createOrUpdateInstallation.js.map +1 -1
  408. package/dist/react-native/api/createOrUpdateRegistration.d.ts +3 -3
  409. package/dist/react-native/api/createOrUpdateRegistration.d.ts.map +1 -1
  410. package/dist/react-native/api/createOrUpdateRegistration.js.map +1 -1
  411. package/dist/react-native/api/createRegistration.d.ts +3 -3
  412. package/dist/react-native/api/createRegistration.d.ts.map +1 -1
  413. package/dist/react-native/api/createRegistration.js.map +1 -1
  414. package/dist/react-native/api/createRegistrationId.d.ts +2 -2
  415. package/dist/react-native/api/createRegistrationId.d.ts.map +1 -1
  416. package/dist/react-native/api/createRegistrationId.js.map +1 -1
  417. package/dist/react-native/api/deleteInstallation.d.ts +3 -3
  418. package/dist/react-native/api/deleteInstallation.d.ts.map +1 -1
  419. package/dist/react-native/api/deleteInstallation.js.map +1 -1
  420. package/dist/react-native/api/deleteRegistration.d.ts +3 -3
  421. package/dist/react-native/api/deleteRegistration.d.ts.map +1 -1
  422. package/dist/react-native/api/deleteRegistration.js.map +1 -1
  423. package/dist/react-native/api/getFeedbackContainerUrl.d.ts +2 -2
  424. package/dist/react-native/api/getFeedbackContainerUrl.d.ts.map +1 -1
  425. package/dist/react-native/api/getFeedbackContainerUrl.js.map +1 -1
  426. package/dist/react-native/api/getInstallation.d.ts +3 -3
  427. package/dist/react-native/api/getInstallation.d.ts.map +1 -1
  428. package/dist/react-native/api/getInstallation.js.map +1 -1
  429. package/dist/react-native/api/getNotificationHubJob.d.ts +3 -3
  430. package/dist/react-native/api/getNotificationHubJob.d.ts.map +1 -1
  431. package/dist/react-native/api/getNotificationHubJob.js.map +1 -1
  432. package/dist/react-native/api/getNotificationOutcomeDetails.d.ts +3 -3
  433. package/dist/react-native/api/getNotificationOutcomeDetails.d.ts.map +1 -1
  434. package/dist/react-native/api/getNotificationOutcomeDetails.js.map +1 -1
  435. package/dist/react-native/api/getRegistration.d.ts +3 -3
  436. package/dist/react-native/api/getRegistration.d.ts.map +1 -1
  437. package/dist/react-native/api/getRegistration.js.map +1 -1
  438. package/dist/react-native/api/internal/_client.d.ts +4 -4
  439. package/dist/react-native/api/internal/_client.d.ts.map +1 -1
  440. package/dist/react-native/api/internal/_client.js +1 -1
  441. package/dist/react-native/api/internal/_client.js.map +1 -1
  442. package/dist/react-native/api/internal/_createOrUpdateRegistrationDescription.d.ts +3 -3
  443. package/dist/react-native/api/internal/_createOrUpdateRegistrationDescription.d.ts.map +1 -1
  444. package/dist/react-native/api/internal/_createOrUpdateRegistrationDescription.js.map +1 -1
  445. package/dist/react-native/api/internal/_listRegistrations.d.ts +3 -3
  446. package/dist/react-native/api/internal/_listRegistrations.d.ts.map +1 -1
  447. package/dist/react-native/api/internal/_listRegistrations.js.map +1 -1
  448. package/dist/react-native/api/internal/_scheduleNotification.d.ts +4 -4
  449. package/dist/react-native/api/internal/_scheduleNotification.d.ts.map +1 -1
  450. package/dist/react-native/api/internal/_scheduleNotification.js.map +1 -1
  451. package/dist/react-native/api/internal/_sendNotification.d.ts +4 -4
  452. package/dist/react-native/api/internal/_sendNotification.d.ts.map +1 -1
  453. package/dist/react-native/api/internal/_sendNotification.js.map +1 -1
  454. package/dist/react-native/api/listNotificationHubJobs.d.ts +3 -3
  455. package/dist/react-native/api/listNotificationHubJobs.d.ts.map +1 -1
  456. package/dist/react-native/api/listNotificationHubJobs.js.map +1 -1
  457. package/dist/react-native/api/listRegistrations.d.ts +4 -4
  458. package/dist/react-native/api/listRegistrations.d.ts.map +1 -1
  459. package/dist/react-native/api/listRegistrations.js.map +1 -1
  460. package/dist/react-native/api/listRegistrationsByChannel.d.ts +4 -4
  461. package/dist/react-native/api/listRegistrationsByChannel.d.ts.map +1 -1
  462. package/dist/react-native/api/listRegistrationsByChannel.js.map +1 -1
  463. package/dist/react-native/api/listRegistrationsByTag.d.ts +4 -4
  464. package/dist/react-native/api/listRegistrationsByTag.d.ts.map +1 -1
  465. package/dist/react-native/api/listRegistrationsByTag.js.map +1 -1
  466. package/dist/react-native/api/scheduleBroadcastNotification.d.ts +4 -4
  467. package/dist/react-native/api/scheduleBroadcastNotification.d.ts.map +1 -1
  468. package/dist/react-native/api/scheduleBroadcastNotification.js.map +1 -1
  469. package/dist/react-native/api/scheduleNotification.d.ts +4 -4
  470. package/dist/react-native/api/scheduleNotification.d.ts.map +1 -1
  471. package/dist/react-native/api/scheduleNotification.js.map +1 -1
  472. package/dist/react-native/api/sendBroadcastNotification.d.ts +4 -4
  473. package/dist/react-native/api/sendBroadcastNotification.d.ts.map +1 -1
  474. package/dist/react-native/api/sendBroadcastNotification.js.map +1 -1
  475. package/dist/react-native/api/sendNotification.d.ts +4 -4
  476. package/dist/react-native/api/sendNotification.d.ts.map +1 -1
  477. package/dist/react-native/api/sendNotification.js.map +1 -1
  478. package/dist/react-native/api/submitNotificationHubJob.d.ts +3 -3
  479. package/dist/react-native/api/submitNotificationHubJob.d.ts.map +1 -1
  480. package/dist/react-native/api/submitNotificationHubJob.js.map +1 -1
  481. package/dist/react-native/api/updateInstallation.d.ts +4 -4
  482. package/dist/react-native/api/updateInstallation.d.ts.map +1 -1
  483. package/dist/react-native/api/updateInstallation.js.map +1 -1
  484. package/dist/react-native/api/updateRegistration.d.ts +3 -3
  485. package/dist/react-native/api/updateRegistration.d.ts.map +1 -1
  486. package/dist/react-native/api/updateRegistration.js.map +1 -1
  487. package/dist/react-native/auth/sasTokenCredential.d.ts +1 -1
  488. package/dist/react-native/auth/sasTokenCredential.d.ts.map +1 -1
  489. package/dist/react-native/auth/sasTokenCredential.js.map +1 -1
  490. package/dist/react-native/models/notification.d.ts +2 -2
  491. package/dist/react-native/models/notification.d.ts.map +1 -1
  492. package/dist/react-native/models/notification.js.map +1 -1
  493. package/dist/react-native/models/notificationHubJob.d.ts +1 -1
  494. package/dist/react-native/models/notificationHubJob.d.ts.map +1 -1
  495. package/dist/react-native/models/notificationHubJob.js.map +1 -1
  496. package/dist/react-native/models/options.d.ts +2 -2
  497. package/dist/react-native/models/options.d.ts.map +1 -1
  498. package/dist/react-native/models/options.js.map +1 -1
  499. package/dist/react-native/models/response.d.ts +1 -1
  500. package/dist/react-native/models/response.d.ts.map +1 -1
  501. package/dist/react-native/models/response.js.map +1 -1
  502. package/dist/react-native/notificationHubsClient.d.ts +8 -8
  503. package/dist/react-native/notificationHubsClient.d.ts.map +1 -1
  504. package/dist/react-native/notificationHubsClient.js.map +1 -1
  505. package/dist/react-native/serializers/notificationDetailsSerializer.d.ts +1 -1
  506. package/dist/react-native/serializers/notificationDetailsSerializer.d.ts.map +1 -1
  507. package/dist/react-native/serializers/notificationDetailsSerializer.js.map +1 -1
  508. package/dist/react-native/serializers/notificationHubJobSerializer.d.ts +1 -1
  509. package/dist/react-native/serializers/notificationHubJobSerializer.d.ts.map +1 -1
  510. package/dist/react-native/serializers/notificationHubJobSerializer.js.map +1 -1
  511. package/dist/react-native/serializers/notificationOutcomeSerializer.d.ts +1 -1
  512. package/dist/react-native/serializers/notificationOutcomeSerializer.d.ts.map +1 -1
  513. package/dist/react-native/serializers/notificationOutcomeSerializer.js.map +1 -1
  514. package/dist/react-native/serializers/registrationSerializer.d.ts +1 -1
  515. package/dist/react-native/serializers/registrationSerializer.d.ts.map +1 -1
  516. package/dist/react-native/serializers/registrationSerializer.js.map +1 -1
  517. package/dist/react-native/utils/notificationUtils.d.ts +1 -1
  518. package/dist/react-native/utils/notificationUtils.d.ts.map +1 -1
  519. package/dist/react-native/utils/notificationUtils.js.map +1 -1
  520. package/dist/react-native/utils/optionUtils.d.ts +1 -1
  521. package/dist/react-native/utils/optionUtils.d.ts.map +1 -1
  522. package/dist/react-native/utils/optionUtils.js.map +1 -1
  523. package/dist/react-native/utils/registrationUtils.d.ts +1 -1
  524. package/dist/react-native/utils/registrationUtils.d.ts.map +1 -1
  525. package/dist/react-native/utils/registrationUtils.js.map +1 -1
  526. package/package.json +1 -1
@@ -1 +1 @@
1
- {"version":3,"file":"createRegistration.d.ts","sourceRoot":"","sources":["../../../src/api/createRegistration.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,6BAA6B,EAAE,MAAM,YAAY,CAAC;AAC3D,OAAO,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAC3D,OAAO,EAAE,uBAAuB,EAAE,MAAM,2BAA2B,CAAC;AAOpE;;;;;;;GAOG;AACH,wBAAgB,kBAAkB,CAChC,OAAO,EAAE,6BAA6B,EACtC,YAAY,EAAE,uBAAuB,EACrC,OAAO,GAAE,gBAAqB,GAC7B,OAAO,CAAC,uBAAuB,CAAC,CAclC"}
1
+ {"version":3,"file":"createRegistration.d.ts","sourceRoot":"","sources":["../../../src/api/createRegistration.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,6BAA6B,EAAE,MAAM,YAAY,CAAC;AAChE,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAChE,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,2BAA2B,CAAC;AAOzE;;;;;;;GAOG;AACH,wBAAgB,kBAAkB,CAChC,OAAO,EAAE,6BAA6B,EACtC,YAAY,EAAE,uBAAuB,EACrC,OAAO,GAAE,gBAAqB,GAC7B,OAAO,CAAC,uBAAuB,CAAC,CAclC"}
@@ -1 +1 @@
1
- {"version":3,"file":"createRegistration.js","sourceRoot":"","sources":["../../../src/api/createRegistration.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAKlC,OAAO,EAAE,SAAS,EAAE,MAAM,2BAA2B,CAAC;AACtD,OAAO,EAAE,qCAAqC,EAAE,MAAM,sDAAsD,CAAC;AAC7G,OAAO,EAAE,aAAa,EAAE,MAAM,qBAAqB,CAAC;AAEpD,MAAM,cAAc,GAAG,oBAAoB,CAAC;AAE5C;;;;;;;GAOG;AACH,MAAM,UAAU,kBAAkB,CAChC,OAAsC,EACtC,YAAqC,EACrC,UAA4B,EAAE;IAE9B,OAAO,aAAa,CAAC,QAAQ,CAC3B,iCAAiC,cAAc,EAAE,EACjD,OAAO,EACP,KAAK,EAAE,cAAc,EAAE,EAAE;QACvB,IAAI,YAAY,CAAC,cAAc,EAAE,CAAC;YAChC,MAAM,IAAI,SAAS,CAAC,0DAA0D,EAAE;gBAC9E,UAAU,EAAE,GAAG;aAChB,CAAC,CAAC;QACL,CAAC;QAED,OAAO,qCAAqC,CAAC,OAAO,EAAE,YAAY,EAAE,QAAQ,EAAE,cAAc,CAAC,CAAC;IAChG,CAAC,CACF,CAAC;AACJ,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nimport { NotificationHubsClientContext } from \"./index.js\";\nimport { OperationOptions } from \"@azure-rest/core-client\";\nimport { RegistrationDescription } from \"../models/registration.js\";\nimport { RestError } from \"@azure/core-rest-pipeline\";\nimport { createOrUpdateRegistrationDescription } from \"./internal/_createOrUpdateRegistrationDescription.js\";\nimport { tracingClient } from \"../utils/tracing.js\";\n\nconst OPERATION_NAME = \"createRegistration\";\n\n/**\n * Creates a new registration. This method generates a registration ID,\n * which you can subsequently use to retrieve, update, and delete this registration.\n * @param context - The Notification Hubs client.\n * @param registration - The registration to create.\n * @param options - Options for creating a new registration.\n * @returns The newly created registration description.\n */\nexport function createRegistration(\n context: NotificationHubsClientContext,\n registration: RegistrationDescription,\n options: OperationOptions = {},\n): Promise<RegistrationDescription> {\n return tracingClient.withSpan(\n `NotificationHubsClientContext.${OPERATION_NAME}`,\n options,\n async (updatedOptions) => {\n if (registration.registrationId) {\n throw new RestError(\"registrationId must not be set during a create operation\", {\n statusCode: 400,\n });\n }\n\n return createOrUpdateRegistrationDescription(context, registration, \"create\", updatedOptions);\n },\n );\n}\n"]}
1
+ {"version":3,"file":"createRegistration.js","sourceRoot":"","sources":["../../../src/api/createRegistration.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAKlC,OAAO,EAAE,SAAS,EAAE,MAAM,2BAA2B,CAAC;AACtD,OAAO,EAAE,qCAAqC,EAAE,MAAM,sDAAsD,CAAC;AAC7G,OAAO,EAAE,aAAa,EAAE,MAAM,qBAAqB,CAAC;AAEpD,MAAM,cAAc,GAAG,oBAAoB,CAAC;AAE5C;;;;;;;GAOG;AACH,MAAM,UAAU,kBAAkB,CAChC,OAAsC,EACtC,YAAqC,EACrC,UAA4B,EAAE;IAE9B,OAAO,aAAa,CAAC,QAAQ,CAC3B,iCAAiC,cAAc,EAAE,EACjD,OAAO,EACP,KAAK,EAAE,cAAc,EAAE,EAAE;QACvB,IAAI,YAAY,CAAC,cAAc,EAAE,CAAC;YAChC,MAAM,IAAI,SAAS,CAAC,0DAA0D,EAAE;gBAC9E,UAAU,EAAE,GAAG;aAChB,CAAC,CAAC;QACL,CAAC;QAED,OAAO,qCAAqC,CAAC,OAAO,EAAE,YAAY,EAAE,QAAQ,EAAE,cAAc,CAAC,CAAC;IAChG,CAAC,CACF,CAAC;AACJ,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nimport type { NotificationHubsClientContext } from \"./index.js\";\nimport type { OperationOptions } from \"@azure-rest/core-client\";\nimport type { RegistrationDescription } from \"../models/registration.js\";\nimport { RestError } from \"@azure/core-rest-pipeline\";\nimport { createOrUpdateRegistrationDescription } from \"./internal/_createOrUpdateRegistrationDescription.js\";\nimport { tracingClient } from \"../utils/tracing.js\";\n\nconst OPERATION_NAME = \"createRegistration\";\n\n/**\n * Creates a new registration. This method generates a registration ID,\n * which you can subsequently use to retrieve, update, and delete this registration.\n * @param context - The Notification Hubs client.\n * @param registration - The registration to create.\n * @param options - Options for creating a new registration.\n * @returns The newly created registration description.\n */\nexport function createRegistration(\n context: NotificationHubsClientContext,\n registration: RegistrationDescription,\n options: OperationOptions = {},\n): Promise<RegistrationDescription> {\n return tracingClient.withSpan(\n `NotificationHubsClientContext.${OPERATION_NAME}`,\n options,\n async (updatedOptions) => {\n if (registration.registrationId) {\n throw new RestError(\"registrationId must not be set during a create operation\", {\n statusCode: 400,\n });\n }\n\n return createOrUpdateRegistrationDescription(context, registration, \"create\", updatedOptions);\n },\n );\n}\n"]}
@@ -1,5 +1,5 @@
1
- import { NotificationHubsClientContext } from "./index.js";
2
- import { OperationOptions } from "@azure-rest/core-client";
1
+ import type { NotificationHubsClientContext } from "./index.js";
2
+ import type { OperationOptions } from "@azure-rest/core-client";
3
3
  /**
4
4
  * Creates a new registration ID.
5
5
  * @param context - The Notification Hubs client.
@@ -1 +1 @@
1
- {"version":3,"file":"createRegistrationId.d.ts","sourceRoot":"","sources":["../../../src/api/createRegistrationId.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,6BAA6B,EAAE,MAAM,YAAY,CAAC;AAC3D,OAAO,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAM3D;;;;;GAKG;AACH,wBAAgB,oBAAoB,CAClC,OAAO,EAAE,6BAA6B,EACtC,OAAO,GAAE,gBAAqB,GAC7B,OAAO,CAAC,MAAM,CAAC,CA6BjB"}
1
+ {"version":3,"file":"createRegistrationId.d.ts","sourceRoot":"","sources":["../../../src/api/createRegistrationId.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,6BAA6B,EAAE,MAAM,YAAY,CAAC;AAChE,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAMhE;;;;;GAKG;AACH,wBAAgB,oBAAoB,CAClC,OAAO,EAAE,6BAA6B,EACtC,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zE,UAAU,EAAE,GAAG;gBACf,OAAO;gBACP,QAAQ;aACT,CAAC,CAAC;QACL,CAAC;QACD,MAAM,WAAW,GAAG,IAAI,GAAG,CAAC,cAAe,CAAC,CAAC;QAC7C,MAAM,cAAc,GAAG,WAAW,CAAC,QAAQ,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,CAAC;QAE1D,OAAO,cAAc,CAAC;IACxB,CAAC,CACF,CAAC;AACJ,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nimport { createRequest, sendRequest } from \"./internal/_client.js\";\nimport { NotificationHubsClientContext } from \"./index.js\";\nimport { OperationOptions } from \"@azure-rest/core-client\";\nimport { RestError } from \"@azure/core-rest-pipeline\";\nimport { tracingClient } from \"../utils/tracing.js\";\n\nconst OPERATION_NAME = \"createRegistrationId\";\n\n/**\n * Creates a new registration ID.\n * @param context - The Notification Hubs client.\n * @param options - The options for creating a new registration ID.\n * @returns The newly created registration ID.\n */\nexport function createRegistrationId(\n context: NotificationHubsClientContext,\n options: OperationOptions = {},\n): Promise<string> {\n return tracingClient.withSpan(\n `NotificationHubsClientContext.${OPERATION_NAME}`,\n options,\n async (updatedOptions) => {\n const endpoint = context.requestUrl();\n endpoint.pathname += \"/registrationIDs\";\n\n const headers = await context.createHeaders(OPERATION_NAME);\n headers.set(\"Content-Type\", \"application/xml;type=entry;charset=utf-8\");\n\n const request = createRequest(endpoint, \"POST\", headers, updatedOptions);\n const response = await sendRequest(context, request, 201);\n\n // In the form: https://{namespace}.servicebus.windows.net/{NotificationHub}/registrations/<registrationId>\n const locationHeader = response.headers.get(\"Location\");\n if (!locationHeader || !locationHeader.startsWith(\"https://\")) {\n throw new RestError(`Location header ${locationHeader} is an invalid URL`, {\n statusCode: 500,\n request,\n response,\n });\n }\n const locationUrl = new URL(locationHeader!);\n const registrationId = locationUrl.pathname.split(\"/\")[3];\n\n return registrationId;\n },\n );\n}\n"]}
1
+ {"version":3,"file":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GAAG,IAAI,GAAG,CAAC,cAAe,CAAC,CAAC;QAC7C,MAAM,cAAc,GAAG,WAAW,CAAC,QAAQ,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,CAAC;QAE1D,OAAO,cAAc,CAAC;IACxB,CAAC,CACF,CAAC;AACJ,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nimport { createRequest, sendRequest } from \"./internal/_client.js\";\nimport type { NotificationHubsClientContext } from \"./index.js\";\nimport type { OperationOptions } from \"@azure-rest/core-client\";\nimport { RestError } from \"@azure/core-rest-pipeline\";\nimport { tracingClient } from \"../utils/tracing.js\";\n\nconst OPERATION_NAME = \"createRegistrationId\";\n\n/**\n * Creates a new registration ID.\n * @param context - The Notification Hubs client.\n * @param options - The options for creating a new registration ID.\n * @returns The newly created registration ID.\n */\nexport function createRegistrationId(\n context: NotificationHubsClientContext,\n options: OperationOptions = {},\n): Promise<string> {\n return tracingClient.withSpan(\n `NotificationHubsClientContext.${OPERATION_NAME}`,\n options,\n async (updatedOptions) => {\n const endpoint = context.requestUrl();\n endpoint.pathname += \"/registrationIDs\";\n\n const headers = await context.createHeaders(OPERATION_NAME);\n headers.set(\"Content-Type\", \"application/xml;type=entry;charset=utf-8\");\n\n const request = createRequest(endpoint, \"POST\", headers, updatedOptions);\n const response = await sendRequest(context, request, 201);\n\n // In the form: https://{namespace}.servicebus.windows.net/{NotificationHub}/registrations/<registrationId>\n const locationHeader = response.headers.get(\"Location\");\n if (!locationHeader || !locationHeader.startsWith(\"https://\")) {\n throw new RestError(`Location header ${locationHeader} is an invalid URL`, {\n statusCode: 500,\n request,\n response,\n });\n }\n const locationUrl = new URL(locationHeader!);\n const registrationId = locationUrl.pathname.split(\"/\")[3];\n\n return registrationId;\n },\n );\n}\n"]}
@@ -1,6 +1,6 @@
1
- import { NotificationHubsClientContext } from "./index.js";
2
- import { NotificationHubsResponse } from "../models/notificationDetails.js";
3
- import { OperationOptions } from "@azure-rest/core-client";
1
+ import type { NotificationHubsClientContext } from "./index.js";
2
+ import type { NotificationHubsResponse } from "../models/notificationDetails.js";
3
+ import type { OperationOptions } from "@azure-rest/core-client";
4
4
  /**
5
5
  * Deletes an installation from a Notification Hub.
6
6
  * @param context - The Notification Hubs client.
@@ -1 +1 @@
1
- {"version":3,"file":"deleteInstallation.d.ts","sourceRoot":"","sources":["../../../src/api/deleteInstallation.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,6BAA6B,EAAE,MAAM,YAAY,CAAC;AAC3D,OAAO,EAAE,wBAAwB,EAAE,MAAM,kCAAkC,CAAC;AAC5E,OAAO,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAK3D;;;;;;GAMG;AACH,wBAAgB,kBAAkB,CAChC,OAAO,EAAE,6BAA6B,EACtC,cAAc,EAAE,MAAM,EACtB,OAAO,GAAE,gBAAqB,GAC7B,OAAO,CAAC,wBAAwB,CAAC,CAenC"}
1
+ {"version":3,"file":"deleteInstallation.d.ts","sourceRoot":"","sources":["../../../src/api/deleteInstallation.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,6BAA6B,EAAE,MAAM,YAAY,CAAC;AAChE,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,kCAAkC,CAAC;AACjF,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAKhE;;;;;;GAMG;AACH,wBAAgB,kBAAkB,CAChC,OAAO,EAAE,6BAA6B,EACtC,cAAc,EAAE,MAAM,EACtB,OAAO,GAAE,gBAAqB,GAC7B,OAAO,CAAC,wBAAwB,CAAC,CAenC"}
@@ -1 +1 @@
1
- {"version":3,"file":"deleteInstallation.js","sourceRoot":"","sources":["../../../src/api/deleteInstallation.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,OAAO,EAAE,aAAa,EAAE,yBAAyB,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;AAI9F,OAAO,EAAE,aAAa,EAAE,MAAM,qBAAqB,CAAC;AAEpD,MAAM,cAAc,GAAG,oBAAoB,CAAC;AAE5C;;;;;;GAMG;AACH,MAAM,UAAU,kBAAkB,CAChC,OAAsC,EACtC,cAAsB,EACtB,UAA4B,EAAE;IAE9B,OAAO,aAAa,CAAC,QAAQ,CAC3B,iCAAiC,cAAc,EAAE,EACjD,OAAO,EACP,KAAK,EAAE,cAAc,EAAE,EAAE;QACvB,MAAM,QAAQ,GAAG,OAAO,CAAC,UAAU,EAAE,CAAC;QACtC,QAAQ,CAAC,QAAQ,IAAI,kBAAkB,cAAc,EAAE,CAAC;QAExD,MAAM,OAAO,GAAG,MAAM,OAAO,CAAC,aAAa,CAAC,cAAc,CAAC,CAAC;QAC5D,MAAM,OAAO,GAAG,aAAa,CAAC,QAAQ,EAAE,QAAQ,EAAE,OAAO,EAAE,cAAc,CAAC,CAAC;QAC3E,MAAM,QAAQ,GAAG,MAAM,WAAW,CAAC,OAAO,EAAE,OAAO,EAAE,GAAG,CAAC,CAAC;QAE1D,OAAO,yBAAyB,CAAC,QAAQ,CAAC,CAAC;IAC7C,CAAC,CACF,CAAC;AACJ,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nimport { createRequest, parseNotificationResponse, sendRequest } from \"./internal/_client.js\";\nimport { NotificationHubsClientContext } from \"./index.js\";\nimport { NotificationHubsResponse } from \"../models/notificationDetails.js\";\nimport { OperationOptions } from \"@azure-rest/core-client\";\nimport { tracingClient } from \"../utils/tracing.js\";\n\nconst OPERATION_NAME = \"deleteInstallation\";\n\n/**\n * Deletes an installation from a Notification Hub.\n * @param context - The Notification Hubs client.\n * @param installationId - The installation ID of the installation to delete.\n * @param options - Configuration options for the installation delete operation.\n * @returns A NotificationHubResponse with the tracking ID, correlation ID and location.\n */\nexport function deleteInstallation(\n context: NotificationHubsClientContext,\n installationId: string,\n options: OperationOptions = {},\n): Promise<NotificationHubsResponse> {\n return tracingClient.withSpan(\n `NotificationHubsClientContext.${OPERATION_NAME}`,\n options,\n async (updatedOptions) => {\n const endpoint = context.requestUrl();\n endpoint.pathname += `/installations/${installationId}`;\n\n const headers = await context.createHeaders(OPERATION_NAME);\n const request = createRequest(endpoint, \"DELETE\", headers, updatedOptions);\n const response = await sendRequest(context, request, 204);\n\n return parseNotificationResponse(response);\n },\n );\n}\n"]}
1
+ {"version":3,"file":"deleteInstallation.js","sourceRoot":"","sources":["../../../src/api/deleteInstallation.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,OAAO,EAAE,aAAa,EAAE,yBAAyB,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;AAI9F,OAAO,EAAE,aAAa,EAAE,MAAM,qBAAqB,CAAC;AAEpD,MAAM,cAAc,GAAG,oBAAoB,CAAC;AAE5C;;;;;;GAMG;AACH,MAAM,UAAU,kBAAkB,CAChC,OAAsC,EACtC,cAAsB,EACtB,UAA4B,EAAE;IAE9B,OAAO,aAAa,CAAC,QAAQ,CAC3B,iCAAiC,cAAc,EAAE,EACjD,OAAO,EACP,KAAK,EAAE,cAAc,EAAE,EAAE;QACvB,MAAM,QAAQ,GAAG,OAAO,CAAC,UAAU,EAAE,CAAC;QACtC,QAAQ,CAAC,QAAQ,IAAI,kBAAkB,cAAc,EAAE,CAAC;QAExD,MAAM,OAAO,GAAG,MAAM,OAAO,CAAC,aAAa,CAAC,cAAc,CAAC,CAAC;QAC5D,MAAM,OAAO,GAAG,aAAa,CAAC,QAAQ,EAAE,QAAQ,EAAE,OAAO,EAAE,cAAc,CAAC,CAAC;QAC3E,MAAM,QAAQ,GAAG,MAAM,WAAW,CAAC,OAAO,EAAE,OAAO,EAAE,GAAG,CAAC,CAAC;QAE1D,OAAO,yBAAyB,CAAC,QAAQ,CAAC,CAAC;IAC7C,CAAC,CACF,CAAC;AACJ,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nimport { createRequest, parseNotificationResponse, sendRequest } from \"./internal/_client.js\";\nimport type { NotificationHubsClientContext } from \"./index.js\";\nimport type { NotificationHubsResponse } from \"../models/notificationDetails.js\";\nimport type { OperationOptions } from \"@azure-rest/core-client\";\nimport { tracingClient } from \"../utils/tracing.js\";\n\nconst OPERATION_NAME = \"deleteInstallation\";\n\n/**\n * Deletes an installation from a Notification Hub.\n * @param context - The Notification Hubs client.\n * @param installationId - The installation ID of the installation to delete.\n * @param options - Configuration options for the installation delete operation.\n * @returns A NotificationHubResponse with the tracking ID, correlation ID and location.\n */\nexport function deleteInstallation(\n context: NotificationHubsClientContext,\n installationId: string,\n options: OperationOptions = {},\n): Promise<NotificationHubsResponse> {\n return tracingClient.withSpan(\n `NotificationHubsClientContext.${OPERATION_NAME}`,\n options,\n async (updatedOptions) => {\n const endpoint = context.requestUrl();\n endpoint.pathname += `/installations/${installationId}`;\n\n const headers = await context.createHeaders(OPERATION_NAME);\n const request = createRequest(endpoint, \"DELETE\", headers, updatedOptions);\n const response = await sendRequest(context, request, 204);\n\n return parseNotificationResponse(response);\n },\n );\n}\n"]}
@@ -1,6 +1,6 @@
1
- import { EntityOperationOptions } from "../models/options.js";
2
- import { NotificationHubsClientContext } from "./index.js";
3
- import { NotificationHubsResponse } from "../models/notificationDetails.js";
1
+ import type { EntityOperationOptions } from "../models/options.js";
2
+ import type { NotificationHubsClientContext } from "./index.js";
3
+ import type { NotificationHubsResponse } from "../models/notificationDetails.js";
4
4
  /**
5
5
  * Deletes a registration with the given registration ID.
6
6
  * @param context - The Notification Hubs client.
@@ -1 +1 @@
1
- {"version":3,"file":"deleteRegistration.d.ts","sourceRoot":"","sources":["../../../src/api/deleteRegistration.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,sBAAsB,EAAE,MAAM,sBAAsB,CAAC;AAC9D,OAAO,EAAE,6BAA6B,EAAE,MAAM,YAAY,CAAC;AAC3D,OAAO,EAAE,wBAAwB,EAAE,MAAM,kCAAkC,CAAC;AAM5E;;;;;;GAMG;AACH,wBAAgB,kBAAkB,CAChC,OAAO,EAAE,6BAA6B,EACtC,cAAc,EAAE,MAAM,EACtB,OAAO,GAAE,sBAA2B,GACnC,OAAO,CAAC,wBAAwB,CAAC,CAkBnC"}
1
+ {"version":3,"file":"deleteRegistration.d.ts","sourceRoot":"","sources":["../../../src/api/deleteRegistration.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,sBAAsB,CAAC;AACnE,OAAO,KAAK,EAAE,6BAA6B,EAAE,MAAM,YAAY,CAAC;AAChE,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,kCAAkC,CAAC;AAMjF;;;;;;GAMG;AACH,wBAAgB,kBAAkB,CAChC,OAAO,EAAE,6BAA6B,EACtC,cAAc,EAAE,MAAM,EACtB,OAAO,GAAE,sBAA2B,GACnC,OAAO,CAAC,wBAAwB,CAAC,CAkBnC"}
@@ -1 +1 @@
1
- {"version":3,"file":"deleteRegistration.js","sourceRoot":"","sources":["../../../src/api/deleteRegistration.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,OAAO,EAAE,aAAa,EAAE,yBAAyB,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;AAI9F,OAAO,EAAE,SAAS,EAAE,MAAM,mBAAmB,CAAC;AAC9C,OAAO,EAAE,aAAa,EAAE,MAAM,qBAAqB,CAAC;AAEpD,MAAM,cAAc,GAAG,oBAAoB,CAAC;AAE5C;;;;;;GAMG;AACH,MAAM,UAAU,kBAAkB,CAChC,OAAsC,EACtC,cAAsB,EACtB,UAAkC,EAAE;IAEpC,OAAO,aAAa,CAAC,QAAQ,CAC3B,iCAAiC,cAAc,EAAE,EACjD,OAAO,EACP,KAAK,EAAE,cAAc,EAAE,EAAE;QACvB,MAAM,QAAQ,GAAG,OAAO,CAAC,UAAU,EAAE,CAAC;QACtC,QAAQ,CAAC,QAAQ,IAAI,kBAAkB,cAAc,EAAE,CAAC;QAExD,MAAM,OAAO,GAAG,MAAM,OAAO,CAAC,aAAa,CAAC,cAAc,CAAC,CAAC;QAC5D,OAAO,CAAC,GAAG,CAAC,cAAc,EAAE,+CAA+C,CAAC,CAAC;QAC7E,OAAO,CAAC,GAAG,CAAC,UAAU,EAAE,SAAS,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,IAAI,OAAO,CAAC,IAAI,GAAG,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC;QAE7E,MAAM,OAAO,GAAG,aAAa,CAAC,QAAQ,EAAE,QAAQ,EAAE,OAAO,EAAE,cAAc,CAAC,CAAC;QAC3E,MAAM,QAAQ,GAAG,MAAM,WAAW,CAAC,OAAO,EAAE,OAAO,EAAE,GAAG,CAAC,CAAC;QAE1D,OAAO,yBAAyB,CAAC,QAAQ,CAAC,CAAC;IAC7C,CAAC,CACF,CAAC;AACJ,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nimport { createRequest, parseNotificationResponse, sendRequest } from \"./internal/_client.js\";\nimport { EntityOperationOptions } from \"../models/options.js\";\nimport { NotificationHubsClientContext } from \"./index.js\";\nimport { NotificationHubsResponse } from \"../models/notificationDetails.js\";\nimport { isDefined } from \"../utils/utils.js\";\nimport { tracingClient } from \"../utils/tracing.js\";\n\nconst OPERATION_NAME = \"deleteRegistration\";\n\n/**\n * Deletes a registration with the given registration ID.\n * @param context - The Notification Hubs client.\n * @param registrationId - The registration ID of the registration to delete.\n * @param options - The options for delete operations including the ETag\n * @returns A NotificationHubResponse with the tracking ID, correlation ID and location.\n */\nexport function deleteRegistration(\n context: NotificationHubsClientContext,\n registrationId: string,\n options: EntityOperationOptions = {},\n): Promise<NotificationHubsResponse> {\n return tracingClient.withSpan(\n `NotificationHubsClientContext.${OPERATION_NAME}`,\n options,\n async (updatedOptions) => {\n const endpoint = context.requestUrl();\n endpoint.pathname += `/registrations/${registrationId}`;\n\n const headers = await context.createHeaders(OPERATION_NAME);\n headers.set(\"Content-Type\", \"application/atom+xml;type=entry;charset=utf-8\");\n headers.set(\"If-Match\", isDefined(options.etag) ? `\"${options.etag}\"` : \"*\");\n\n const request = createRequest(endpoint, \"DELETE\", headers, updatedOptions);\n const response = await sendRequest(context, request, 200);\n\n return parseNotificationResponse(response);\n },\n );\n}\n"]}
1
+ {"version":3,"file":"deleteRegistration.js","sourceRoot":"","sources":["../../../src/api/deleteRegistration.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,OAAO,EAAE,aAAa,EAAE,yBAAyB,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;AAI9F,OAAO,EAAE,SAAS,EAAE,MAAM,mBAAmB,CAAC;AAC9C,OAAO,EAAE,aAAa,EAAE,MAAM,qBAAqB,CAAC;AAEpD,MAAM,cAAc,GAAG,oBAAoB,CAAC;AAE5C;;;;;;GAMG;AACH,MAAM,UAAU,kBAAkB,CAChC,OAAsC,EACtC,cAAsB,EACtB,UAAkC,EAAE;IAEpC,OAAO,aAAa,CAAC,QAAQ,CAC3B,iCAAiC,cAAc,EAAE,EACjD,OAAO,EACP,KAAK,EAAE,cAAc,EAAE,EAAE;QACvB,MAAM,QAAQ,GAAG,OAAO,CAAC,UAAU,EAAE,CAAC;QACtC,QAAQ,CAAC,QAAQ,IAAI,kBAAkB,cAAc,EAAE,CAAC;QAExD,MAAM,OAAO,GAAG,MAAM,OAAO,CAAC,aAAa,CAAC,cAAc,CAAC,CAAC;QAC5D,OAAO,CAAC,GAAG,CAAC,cAAc,EAAE,+CAA+C,CAAC,CAAC;QAC7E,OAAO,CAAC,GAAG,CAAC,UAAU,EAAE,SAAS,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,IAAI,OAAO,CAAC,IAAI,GAAG,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC;QAE7E,MAAM,OAAO,GAAG,aAAa,CAAC,QAAQ,EAAE,QAAQ,EAAE,OAAO,EAAE,cAAc,CAAC,CAAC;QAC3E,MAAM,QAAQ,GAAG,MAAM,WAAW,CAAC,OAAO,EAAE,OAAO,EAAE,GAAG,CAAC,CAAC;QAE1D,OAAO,yBAAyB,CAAC,QAAQ,CAAC,CAAC;IAC7C,CAAC,CACF,CAAC;AACJ,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nimport { createRequest, parseNotificationResponse, sendRequest } from \"./internal/_client.js\";\nimport type { EntityOperationOptions } from \"../models/options.js\";\nimport type { NotificationHubsClientContext } from \"./index.js\";\nimport type { NotificationHubsResponse } from \"../models/notificationDetails.js\";\nimport { isDefined } from \"../utils/utils.js\";\nimport { tracingClient } from \"../utils/tracing.js\";\n\nconst OPERATION_NAME = \"deleteRegistration\";\n\n/**\n * Deletes a registration with the given registration ID.\n * @param context - The Notification Hubs client.\n * @param registrationId - The registration ID of the registration to delete.\n * @param options - The options for delete operations including the ETag\n * @returns A NotificationHubResponse with the tracking ID, correlation ID and location.\n */\nexport function deleteRegistration(\n context: NotificationHubsClientContext,\n registrationId: string,\n options: EntityOperationOptions = {},\n): Promise<NotificationHubsResponse> {\n return tracingClient.withSpan(\n `NotificationHubsClientContext.${OPERATION_NAME}`,\n options,\n async (updatedOptions) => {\n const endpoint = context.requestUrl();\n endpoint.pathname += `/registrations/${registrationId}`;\n\n const headers = await context.createHeaders(OPERATION_NAME);\n headers.set(\"Content-Type\", \"application/atom+xml;type=entry;charset=utf-8\");\n headers.set(\"If-Match\", isDefined(options.etag) ? `\"${options.etag}\"` : \"*\");\n\n const request = createRequest(endpoint, \"DELETE\", headers, updatedOptions);\n const response = await sendRequest(context, request, 200);\n\n return parseNotificationResponse(response);\n },\n );\n}\n"]}
@@ -1,5 +1,5 @@
1
- import { NotificationHubsClientContext } from "./index.js";
2
- import { OperationOptions } from "@azure-rest/core-client";
1
+ import type { NotificationHubsClientContext } from "./index.js";
2
+ import type { OperationOptions } from "@azure-rest/core-client";
3
3
  /**
4
4
  * Retrieves an Azure Storage container URL. The container has feedback data for the notification hub.
5
5
  * The caller can then use the Azure Storage Services SDK to retrieve the contents of the container.
@@ -1 +1 @@
1
- {"version":3,"file":"getFeedbackContainerUrl.d.ts","sourceRoot":"","sources":["../../../src/api/getFeedbackContainerUrl.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,6BAA6B,EAAE,MAAM,YAAY,CAAC;AAC3D,OAAO,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAK3D;;;;;;GAMG;AACH,wBAAgB,uBAAuB,CACrC,OAAO,EAAE,6BAA6B,EACtC,OAAO,GAAE,gBAAqB,GAC7B,OAAO,CAAC,MAAM,CAAC,CAiBjB"}
1
+ {"version":3,"file":"getFeedbackContainerUrl.d.ts","sourceRoot":"","sources":["../../../src/api/getFeedbackContainerUrl.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,6BAA6B,EAAE,MAAM,YAAY,CAAC;AAChE,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAKhE;;;;;;GAMG;AACH,wBAAgB,uBAAuB,CACrC,OAAO,EAAE,6BAA6B,EACtC,OAAO,GAAE,gBAAqB,GAC7B,OAAO,CAAC,MAAM,CAAC,CAiBjB"}
@@ -1 +1 @@
1
- {"version":3,"file":"getFeedbackContainerUrl.js","sourceRoot":"","sources":["../../../src/api/getFeedbackContainerUrl.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,OAAO,EAAE,aAAa,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;AAGnE,OAAO,EAAE,aAAa,EAAE,MAAM,qBAAqB,CAAC;AAEpD,MAAM,cAAc,GAAG,yBAAyB,CAAC;AAEjD;;;;;;GAMG;AACH,MAAM,UAAU,uBAAuB,CACrC,OAAsC,EACtC,UAA4B,EAAE;IAE9B,OAAO,aAAa,CAAC,QAAQ,CAC3B,iCAAiC,cAAc,EAAE,EACjD,OAAO,EACP,KAAK,EAAE,cAAc,EAAE,EAAE;QACvB,MAAM,QAAQ,GAAG,OAAO,CAAC,UAAU,EAAE,CAAC;QACtC,QAAQ,CAAC,QAAQ,IAAI,oBAAoB,CAAC;QAE1C,MAAM,OAAO,GAAG,MAAM,OAAO,CAAC,aAAa,CAAC,cAAc,CAAC,CAAC;QAC5D,OAAO,CAAC,GAAG,CAAC,cAAc,EAAE,0CAA0C,CAAC,CAAC;QAExE,MAAM,OAAO,GAAG,aAAa,CAAC,QAAQ,EAAE,KAAK,EAAE,OAAO,EAAE,cAAc,CAAC,CAAC;QACxE,MAAM,QAAQ,GAAG,MAAM,WAAW,CAAC,OAAO,EAAE,OAAO,EAAE,GAAG,CAAC,CAAC;QAE1D,OAAO,QAAQ,CAAC,UAAW,CAAC;IAC9B,CAAC,CACF,CAAC;AACJ,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nimport { createRequest, sendRequest } from \"./internal/_client.js\";\nimport { NotificationHubsClientContext } from \"./index.js\";\nimport { OperationOptions } from \"@azure-rest/core-client\";\nimport { tracingClient } from \"../utils/tracing.js\";\n\nconst OPERATION_NAME = \"getFeedbackContainerUrl\";\n\n/**\n * Retrieves an Azure Storage container URL. The container has feedback data for the notification hub.\n * The caller can then use the Azure Storage Services SDK to retrieve the contents of the container.\n * @param context - The Notification Hubs client.\n * @param options - The options for getting the push notification feedback container URL.\n * @returns The URL of the Azure Storage Container containing the feedback data.\n */\nexport function getFeedbackContainerUrl(\n context: NotificationHubsClientContext,\n options: OperationOptions = {},\n): Promise<string> {\n return tracingClient.withSpan(\n `NotificationHubsClientContext.${OPERATION_NAME}`,\n options,\n async (updatedOptions) => {\n const endpoint = context.requestUrl();\n endpoint.pathname += \"/feedbackcontainer\";\n\n const headers = await context.createHeaders(OPERATION_NAME);\n headers.set(\"Content-Type\", \"application/xml;type=entry;charset=utf-8\");\n\n const request = createRequest(endpoint, \"GET\", headers, updatedOptions);\n const response = await sendRequest(context, request, 200);\n\n return response.bodyAsText!;\n },\n );\n}\n"]}
1
+ {"version":3,"file":"getFeedbackContainerUrl.js","sourceRoot":"","sources":["../../../src/api/getFeedbackContainerUrl.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,OAAO,EAAE,aAAa,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;AAGnE,OAAO,EAAE,aAAa,EAAE,MAAM,qBAAqB,CAAC;AAEpD,MAAM,cAAc,GAAG,yBAAyB,CAAC;AAEjD;;;;;;GAMG;AACH,MAAM,UAAU,uBAAuB,CACrC,OAAsC,EACtC,UAA4B,EAAE;IAE9B,OAAO,aAAa,CAAC,QAAQ,CAC3B,iCAAiC,cAAc,EAAE,EACjD,OAAO,EACP,KAAK,EAAE,cAAc,EAAE,EAAE;QACvB,MAAM,QAAQ,GAAG,OAAO,CAAC,UAAU,EAAE,CAAC;QACtC,QAAQ,CAAC,QAAQ,IAAI,oBAAoB,CAAC;QAE1C,MAAM,OAAO,GAAG,MAAM,OAAO,CAAC,aAAa,CAAC,cAAc,CAAC,CAAC;QAC5D,OAAO,CAAC,GAAG,CAAC,cAAc,EAAE,0CAA0C,CAAC,CAAC;QAExE,MAAM,OAAO,GAAG,aAAa,CAAC,QAAQ,EAAE,KAAK,EAAE,OAAO,EAAE,cAAc,CAAC,CAAC;QACxE,MAAM,QAAQ,GAAG,MAAM,WAAW,CAAC,OAAO,EAAE,OAAO,EAAE,GAAG,CAAC,CAAC;QAE1D,OAAO,QAAQ,CAAC,UAAW,CAAC;IAC9B,CAAC,CACF,CAAC;AACJ,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nimport { createRequest, sendRequest } from \"./internal/_client.js\";\nimport type { NotificationHubsClientContext } from \"./index.js\";\nimport type { OperationOptions } from \"@azure-rest/core-client\";\nimport { tracingClient } from \"../utils/tracing.js\";\n\nconst OPERATION_NAME = \"getFeedbackContainerUrl\";\n\n/**\n * Retrieves an Azure Storage container URL. The container has feedback data for the notification hub.\n * The caller can then use the Azure Storage Services SDK to retrieve the contents of the container.\n * @param context - The Notification Hubs client.\n * @param options - The options for getting the push notification feedback container URL.\n * @returns The URL of the Azure Storage Container containing the feedback data.\n */\nexport function getFeedbackContainerUrl(\n context: NotificationHubsClientContext,\n options: OperationOptions = {},\n): Promise<string> {\n return tracingClient.withSpan(\n `NotificationHubsClientContext.${OPERATION_NAME}`,\n options,\n async (updatedOptions) => {\n const endpoint = context.requestUrl();\n endpoint.pathname += \"/feedbackcontainer\";\n\n const headers = await context.createHeaders(OPERATION_NAME);\n headers.set(\"Content-Type\", \"application/xml;type=entry;charset=utf-8\");\n\n const request = createRequest(endpoint, \"GET\", headers, updatedOptions);\n const response = await sendRequest(context, request, 200);\n\n return response.bodyAsText!;\n },\n );\n}\n"]}
@@ -1,6 +1,6 @@
1
- import { Installation } from "../models/installation.js";
2
- import { NotificationHubsClientContext } from "./index.js";
3
- import { OperationOptions } from "@azure-rest/core-client";
1
+ import type { Installation } from "../models/installation.js";
2
+ import type { NotificationHubsClientContext } from "./index.js";
3
+ import type { OperationOptions } from "@azure-rest/core-client";
4
4
  /**
5
5
  * Gets an Azure Notification Hub installation by the installation ID.
6
6
  * @param context - The Notification Hubs client.
@@ -1 +1 @@
1
- {"version":3,"file":"getInstallation.d.ts","sourceRoot":"","sources":["../../../src/api/getInstallation.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,YAAY,EAAE,MAAM,2BAA2B,CAAC;AACzD,OAAO,EAAE,6BAA6B,EAAE,MAAM,YAAY,CAAC;AAC3D,OAAO,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAK3D;;;;;;GAMG;AACH,wBAAgB,eAAe,CAC7B,OAAO,EAAE,6BAA6B,EACtC,cAAc,EAAE,MAAM,EACtB,OAAO,GAAE,gBAAqB,GAC7B,OAAO,CAAC,YAAY,CAAC,CAiBvB"}
1
+ {"version":3,"file":"getInstallation.d.ts","sourceRoot":"","sources":["../../../src/api/getInstallation.ts"],"names":[],"mappings":"A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,OAAO,IAAI,CAAC,KAAK,CAAC,QAAQ,CAAC,UAAW,CAAiB,CAAC;IAC1D,CAAC,CACF,CAAC;AACJ,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nimport { createRequest, sendRequest } from \"./internal/_client.js\";\nimport { Installation } from \"../models/installation.js\";\nimport { NotificationHubsClientContext } from \"./index.js\";\nimport { OperationOptions } from \"@azure-rest/core-client\";\nimport { tracingClient } from \"../utils/tracing.js\";\n\nconst OPERATION_NAME = \"getInstallation\";\n\n/**\n * Gets an Azure Notification Hub installation by the installation ID.\n * @param context - The Notification Hubs client.\n * @param installationId - The ID of the installation to get.\n * @param options - Configuration options for the get installation operation.\n * @returns The installation that matches the installation ID.\n */\nexport function getInstallation(\n context: NotificationHubsClientContext,\n installationId: string,\n options: OperationOptions = {},\n): Promise<Installation> {\n return tracingClient.withSpan(\n `NotificationHubsClientContext.${OPERATION_NAME}`,\n options,\n async (updatedOptions) => {\n const endpoint = context.requestUrl();\n endpoint.pathname += `/installations/${installationId}`;\n\n const headers = await context.createHeaders(OPERATION_NAME);\n headers.set(\"Content-Type\", \"application/json\");\n\n const request = createRequest(endpoint, \"GET\", headers, updatedOptions);\n const response = await sendRequest(context, request, 200);\n\n return JSON.parse(response.bodyAsText!) as Installation;\n },\n );\n}\n"]}
1
+ {"version":3,"file":"getInstallation.js","sourceRoot":"","sources":["../../../src/api/getInstallation.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,OAAO,EAAE,aAAa,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;AAInE,OAAO,EAAE,aAAa,EAAE,MAAM,qBAAqB,CAAC;AAEpD,MAAM,cAAc,GAAG,iBAAiB,CAAC;AAEzC;;;;;;GAMG;AACH,MAAM,UAAU,eAAe,CAC7B,OAAsC,EACtC,cAAsB,EACtB,UAA4B,EAAE;IAE9B,OAAO,aAAa,CAAC,QAAQ,CAC3B,iCAAiC,cAAc,EAAE,EACjD,OAAO,EACP,KAAK,EAAE,cAAc,EAAE,EAAE;QACvB,MAAM,QAAQ,GAAG,OAAO,CAAC,UAAU,EAAE,CAAC;QACtC,QAAQ,CAAC,QAAQ,IAAI,kBAAkB,cAAc,EAAE,CAAC;QAExD,MAAM,OAAO,GAAG,MAAM,OAAO,CAAC,aAAa,CAAC,cAAc,CAAC,CAAC;QAC5D,OAAO,CAAC,GAAG,CAAC,cAAc,EAAE,kBAAkB,CAAC,CAAC;QAEhD,MAAM,OAAO,GAAG,aAAa,CAAC,QAAQ,EAAE,KAAK,EAAE,OAAO,EAAE,cAAc,CAAC,CAAC;QACxE,MAAM,QAAQ,GAAG,MAAM,WAAW,CAAC,OAAO,EAAE,OAAO,EAAE,GAAG,CAAC,CAAC;QAE1D,OAAO,IAAI,CAAC,KAAK,CAAC,QAAQ,CAAC,UAAW,CAAiB,CAAC;IAC1D,CAAC,CACF,CAAC;AACJ,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nimport { createRequest, sendRequest } from \"./internal/_client.js\";\nimport type { Installation } from \"../models/installation.js\";\nimport type { NotificationHubsClientContext } from \"./index.js\";\nimport type { OperationOptions } from \"@azure-rest/core-client\";\nimport { tracingClient } from \"../utils/tracing.js\";\n\nconst OPERATION_NAME = \"getInstallation\";\n\n/**\n * Gets an Azure Notification Hub installation by the installation ID.\n * @param context - The Notification Hubs client.\n * @param installationId - The ID of the installation to get.\n * @param options - Configuration options for the get installation operation.\n * @returns The installation that matches the installation ID.\n */\nexport function getInstallation(\n context: NotificationHubsClientContext,\n installationId: string,\n options: OperationOptions = {},\n): Promise<Installation> {\n return tracingClient.withSpan(\n `NotificationHubsClientContext.${OPERATION_NAME}`,\n options,\n async (updatedOptions) => {\n const endpoint = context.requestUrl();\n endpoint.pathname += `/installations/${installationId}`;\n\n const headers = await context.createHeaders(OPERATION_NAME);\n headers.set(\"Content-Type\", \"application/json\");\n\n const request = createRequest(endpoint, \"GET\", headers, updatedOptions);\n const response = await sendRequest(context, request, 200);\n\n return JSON.parse(response.bodyAsText!) as Installation;\n },\n );\n}\n"]}
@@ -1,6 +1,6 @@
1
- import { NotificationHubJob } from "../models/notificationHubJob.js";
2
- import { NotificationHubsClientContext } from "./index.js";
3
- import { OperationOptions } from "@azure-rest/core-client";
1
+ import type { NotificationHubJob } from "../models/notificationHubJob.js";
2
+ import type { NotificationHubsClientContext } from "./index.js";
3
+ import type { OperationOptions } from "@azure-rest/core-client";
4
4
  /**
5
5
  * Gets a Notification Hub Job by the ID.
6
6
  * @param context - The Notification Hubs client.
@@ -1 +1 @@
1
- {"version":3,"file":"getNotificationHubJob.d.ts","sourceRoot":"","sources":["../../../src/api/getNotificationHubJob.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,kBAAkB,EAAE,MAAM,iCAAiC,CAAC;AACrE,OAAO,EAAE,6BAA6B,EAAE,MAAM,YAAY,CAAC;AAC3D,OAAO,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAM3D;;;;;;GAMG;AACH,wBAAgB,qBAAqB,CACnC,OAAO,EAAE,6BAA6B,EACtC,KAAK,EAAE,MAAM,EACb,OAAO,GAAE,gBAAqB,GAC7B,OAAO,CAAC,kBAAkB,CAAC,CAiB7B"}
1
+ {"version":3,"file":"getNotificationHubJob.d.ts","sourceRoot":"","sources":["../../../src/api/getNotificationHubJob.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,iCAAiC,CAAC;AAC1E,OAAO,KAAK,EAAE,6BAA6B,EAAE,MAAM,YAAY,CAAC;AAChE,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAMhE;;;;;;GAMG;AACH,wBAAgB,qBAAqB,CACnC,OAAO,EAAE,6BAA6B,EACtC,KAAK,EAAE,MAAM,EACb,OAAO,GAAE,gBAAqB,GAC7B,OAAO,CAAC,kBAAkB,CAAC,CAiB7B"}
@@ -1 +1 @@
1
- {"version":3,"file":"getNotificationHubJob.js","sourceRoot":"","sources":["../../../src/api/getNotificationHubJob.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,OAAO,EAAE,aAAa,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;AAInE,OAAO,EAAE,4BAA4B,EAAE,MAAM,gDAAgD,CAAC;AAC9F,OAAO,EAAE,aAAa,EAAE,MAAM,qBAAqB,CAAC;AAEpD,MAAM,cAAc,GAAG,uBAAuB,CAAC;AAE/C;;;;;;GAMG;AACH,MAAM,UAAU,qBAAqB,CACnC,OAAsC,EACtC,KAAa,EACb,UAA4B,EAAE;IAE9B,OAAO,aAAa,CAAC,QAAQ,CAC3B,iCAAiC,cAAc,EAAE,EACjD,OAAO,EACP,KAAK,EAAE,cAAc,EAAE,EAAE;QACvB,MAAM,QAAQ,GAAG,OAAO,CAAC,UAAU,EAAE,CAAC;QACtC,QAAQ,CAAC,QAAQ,IAAI,SAAS,KAAK,EAAE,CAAC;QAEtC,MAAM,OAAO,GAAG,MAAM,OAAO,CAAC,aAAa,CAAC,cAAc,CAAC,CAAC;QAC5D,OAAO,CAAC,GAAG,CAAC,cAAc,EAAE,+CAA+C,CAAC,CAAC;QAE7E,MAAM,OAAO,GAAG,aAAa,CAAC,QAAQ,EAAE,KAAK,EAAE,OAAO,EAAE,cAAc,CAAC,CAAC;QACxE,MAAM,QAAQ,GAAG,MAAM,WAAW,CAAC,OAAO,EAAE,OAAO,EAAE,GAAG,CAAC,CAAC;QAE1D,OAAO,4BAA4B,CAAC,QAAQ,CAAC,UAAW,CAAC,CAAC;IAC5D,CAAC,CACF,CAAC;AACJ,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nimport { createRequest, sendRequest } from \"./internal/_client.js\";\nimport { NotificationHubJob } from \"../models/notificationHubJob.js\";\nimport { NotificationHubsClientContext } from \"./index.js\";\nimport { OperationOptions } from \"@azure-rest/core-client\";\nimport { parseNotificationHubJobEntry } from \"../serializers/notificationHubJobSerializer.js\";\nimport { tracingClient } from \"../utils/tracing.js\";\n\nconst OPERATION_NAME = \"getNotificationHubJob\";\n\n/**\n * Gets a Notification Hub Job by the ID.\n * @param context - The Notification Hubs client.\n * @param jobId - The Notification Hub Job ID.\n * @param options - The operation options.\n * @returns The Notification Hub Job with the matching ID.\n */\nexport function getNotificationHubJob(\n context: NotificationHubsClientContext,\n jobId: string,\n options: OperationOptions = {},\n): Promise<NotificationHubJob> {\n return tracingClient.withSpan(\n `NotificationHubsClientContext.${OPERATION_NAME}`,\n options,\n async (updatedOptions) => {\n const endpoint = context.requestUrl();\n endpoint.pathname += `/jobs/${jobId}`;\n\n const headers = await context.createHeaders(OPERATION_NAME);\n headers.set(\"Content-Type\", \"application/atom+xml;type=entry;charset=utf-8\");\n\n const request = createRequest(endpoint, \"GET\", headers, updatedOptions);\n const response = await sendRequest(context, request, 200);\n\n return parseNotificationHubJobEntry(response.bodyAsText!);\n },\n );\n}\n"]}
1
+ {"version":3,"file":"getNotificationHubJob.js","sourceRoot":"","sources":["../../../src/api/getNotificationHubJob.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,OAAO,EAAE,aAAa,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;AAInE,OAAO,EAAE,4BAA4B,EAAE,MAAM,gDAAgD,CAAC;AAC9F,OAAO,EAAE,aAAa,EAAE,MAAM,qBAAqB,CAAC;AAEpD,MAAM,cAAc,GAAG,uBAAuB,CAAC;AAE/C;;;;;;GAMG;AACH,MAAM,UAAU,qBAAqB,CACnC,OAAsC,EACtC,KAAa,EACb,UAA4B,EAAE;IAE9B,OAAO,aAAa,CAAC,QAAQ,CAC3B,iCAAiC,cAAc,EAAE,EACjD,OAAO,EACP,KAAK,EAAE,cAAc,EAAE,EAAE;QACvB,MAAM,QAAQ,GAAG,OAAO,CAAC,UAAU,EAAE,CAAC;QACtC,QAAQ,CAAC,QAAQ,IAAI,SAAS,KAAK,EAAE,CAAC;QAEtC,MAAM,OAAO,GAAG,MAAM,OAAO,CAAC,aAAa,CAAC,cAAc,CAAC,CAAC;QAC5D,OAAO,CAAC,GAAG,CAAC,cAAc,EAAE,+CAA+C,CAAC,CAAC;QAE7E,MAAM,OAAO,GAAG,aAAa,CAAC,QAAQ,EAAE,KAAK,EAAE,OAAO,EAAE,cAAc,CAAC,CAAC;QACxE,MAAM,QAAQ,GAAG,MAAM,WAAW,CAAC,OAAO,EAAE,OAAO,EAAE,GAAG,CAAC,CAAC;QAE1D,OAAO,4BAA4B,CAAC,QAAQ,CAAC,UAAW,CAAC,CAAC;IAC5D,CAAC,CACF,CAAC;AACJ,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nimport { createRequest, sendRequest } from \"./internal/_client.js\";\nimport type { NotificationHubJob } from \"../models/notificationHubJob.js\";\nimport type { NotificationHubsClientContext } from \"./index.js\";\nimport type { OperationOptions } from \"@azure-rest/core-client\";\nimport { parseNotificationHubJobEntry } from \"../serializers/notificationHubJobSerializer.js\";\nimport { tracingClient } from \"../utils/tracing.js\";\n\nconst OPERATION_NAME = \"getNotificationHubJob\";\n\n/**\n * Gets a Notification Hub Job by the ID.\n * @param context - The Notification Hubs client.\n * @param jobId - The Notification Hub Job ID.\n * @param options - The operation options.\n * @returns The Notification Hub Job with the matching ID.\n */\nexport function getNotificationHubJob(\n context: NotificationHubsClientContext,\n jobId: string,\n options: OperationOptions = {},\n): Promise<NotificationHubJob> {\n return tracingClient.withSpan(\n `NotificationHubsClientContext.${OPERATION_NAME}`,\n options,\n async (updatedOptions) => {\n const endpoint = context.requestUrl();\n endpoint.pathname += `/jobs/${jobId}`;\n\n const headers = await context.createHeaders(OPERATION_NAME);\n headers.set(\"Content-Type\", \"application/atom+xml;type=entry;charset=utf-8\");\n\n const request = createRequest(endpoint, \"GET\", headers, updatedOptions);\n const response = await sendRequest(context, request, 200);\n\n return parseNotificationHubJobEntry(response.bodyAsText!);\n },\n );\n}\n"]}
@@ -1,6 +1,6 @@
1
- import { NotificationDetails } from "../models/notificationDetails.js";
2
- import { NotificationHubsClientContext } from "./index.js";
3
- import { OperationOptions } from "@azure-rest/core-client";
1
+ import type { NotificationDetails } from "../models/notificationDetails.js";
2
+ import type { NotificationHubsClientContext } from "./index.js";
3
+ import type { OperationOptions } from "@azure-rest/core-client";
4
4
  /**
5
5
  * Retrieves the results of a send operation. This can retrieve intermediate results if the send is being processed
6
6
  * or final results if the Send* has completed. This API can only be called for Standard SKU and above.
@@ -1 +1 @@
1
- {"version":3,"file":"getNotificationOutcomeDetails.d.ts","sourceRoot":"","sources":["../../../src/api/getNotificationOutcomeDetails.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,mBAAmB,EAAE,MAAM,kCAAkC,CAAC;AACvE,OAAO,EAAE,6BAA6B,EAAE,MAAM,YAAY,CAAC;AAC3D,OAAO,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAM3D;;;;;;;GAOG;AACH,wBAAgB,6BAA6B,CAC3C,OAAO,EAAE,6BAA6B,EACtC,cAAc,EAAE,MAAM,EACtB,OAAO,GAAE,gBAAqB,GAC7B,OAAO,CAAC,mBAAmB,CAAC,CAe9B"}
1
+ {"version":3,"file":"getNotificationOutcomeDetails.d.ts","sourceRoot":"","sources":["../../../src/api/getNotificationOutcomeDetails.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,kCAAkC,CAAC;AAC5E,OAAO,KAAK,EAAE,6BAA6B,EAAE,MAAM,YAAY,CAAC;AAChE,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAMhE;;;;;;;GAOG;AACH,wBAAgB,6BAA6B,CAC3C,OAAO,EAAE,6BAA6B,EACtC,cAAc,EAAE,MAAM,EACtB,OAAO,GAAE,gBAAqB,GAC7B,OAAO,CAAC,mBAAmB,CAAC,CAe9B"}
@@ -1 +1 @@
1
- {"version":3,"file":"getNotificationOutcomeDetails.js","sourceRoot":"","sources":["../../../src/api/getNotificationOutcomeDetails.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,OAAO,EAAE,aAAa,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;AAInE,OAAO,EAAE,wBAAwB,EAAE,MAAM,iDAAiD,CAAC;AAC3F,OAAO,EAAE,aAAa,EAAE,MAAM,qBAAqB,CAAC;AAEpD,MAAM,cAAc,GAAG,+BAA+B,CAAC;AAEvD;;;;;;;GAOG;AACH,MAAM,UAAU,6BAA6B,CAC3C,OAAsC,EACtC,cAAsB,EACtB,UAA4B,EAAE;IAE9B,OAAO,aAAa,CAAC,QAAQ,CAC3B,iCAAiC,cAAc,EAAE,EACjD,OAAO,EACP,KAAK,EAAE,cAAc,EAAE,EAAE;QACvB,MAAM,QAAQ,GAAG,OAAO,CAAC,UAAU,EAAE,CAAC;QACtC,QAAQ,CAAC,QAAQ,IAAI,aAAa,cAAc,EAAE,CAAC;QAEnD,MAAM,OAAO,GAAG,MAAM,OAAO,CAAC,aAAa,CAAC,cAAc,CAAC,CAAC;QAC5D,MAAM,OAAO,GAAG,aAAa,CAAC,QAAQ,EAAE,KAAK,EAAE,OAAO,EAAE,cAAc,CAAC,CAAC;QACxE,MAAM,QAAQ,GAAG,MAAM,WAAW,CAAC,OAAO,EAAE,OAAO,EAAE,GAAG,CAAC,CAAC;QAE1D,OAAO,wBAAwB,CAAC,QAAQ,CAAC,UAAW,CAAC,CAAC;IACxD,CAAC,CACF,CAAC;AACJ,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nimport { createRequest, sendRequest } from \"./internal/_client.js\";\nimport { NotificationDetails } from \"../models/notificationDetails.js\";\nimport { NotificationHubsClientContext } from \"./index.js\";\nimport { OperationOptions } from \"@azure-rest/core-client\";\nimport { parseNotificationDetails } from \"../serializers/notificationDetailsSerializer.js\";\nimport { tracingClient } from \"../utils/tracing.js\";\n\nconst OPERATION_NAME = \"getNotificationOutcomeDetails\";\n\n/**\n * Retrieves the results of a send operation. This can retrieve intermediate results if the send is being processed\n * or final results if the Send* has completed. This API can only be called for Standard SKU and above.\n * @param context - The Notification Hubs client.\n * @param notificationId - The notification ID returned from the send operation.\n * @param options - The operation options.\n * @returns The results of the send operation.\n */\nexport function getNotificationOutcomeDetails(\n context: NotificationHubsClientContext,\n notificationId: string,\n options: OperationOptions = {},\n): Promise<NotificationDetails> {\n return tracingClient.withSpan(\n `NotificationHubsClientContext.${OPERATION_NAME}`,\n options,\n async (updatedOptions) => {\n const endpoint = context.requestUrl();\n endpoint.pathname += `/messages/${notificationId}`;\n\n const headers = await context.createHeaders(OPERATION_NAME);\n const request = createRequest(endpoint, \"GET\", headers, updatedOptions);\n const response = await sendRequest(context, request, 200);\n\n return parseNotificationDetails(response.bodyAsText!);\n },\n );\n}\n"]}
1
+ {"version":3,"file":"getNotificationOutcomeDetails.js","sourceRoot":"","sources":["../../../src/api/getNotificationOutcomeDetails.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,OAAO,EAAE,aAAa,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;AAInE,OAAO,EAAE,wBAAwB,EAAE,MAAM,iDAAiD,CAAC;AAC3F,OAAO,EAAE,aAAa,EAAE,MAAM,qBAAqB,CAAC;AAEpD,MAAM,cAAc,GAAG,+BAA+B,CAAC;AAEvD;;;;;;;GAOG;AACH,MAAM,UAAU,6BAA6B,CAC3C,OAAsC,EACtC,cAAsB,EACtB,UAA4B,EAAE;IAE9B,OAAO,aAAa,CAAC,QAAQ,CAC3B,iCAAiC,cAAc,EAAE,EACjD,OAAO,EACP,KAAK,EAAE,cAAc,EAAE,EAAE;QACvB,MAAM,QAAQ,GAAG,OAAO,CAAC,UAAU,EAAE,CAAC;QACtC,QAAQ,CAAC,QAAQ,IAAI,aAAa,cAAc,EAAE,CAAC;QAEnD,MAAM,OAAO,GAAG,MAAM,OAAO,CAAC,aAAa,CAAC,cAAc,CAAC,CAAC;QAC5D,MAAM,OAAO,GAAG,aAAa,CAAC,QAAQ,EAAE,KAAK,EAAE,OAAO,EAAE,cAAc,CAAC,CAAC;QACxE,MAAM,QAAQ,GAAG,MAAM,WAAW,CAAC,OAAO,EAAE,OAAO,EAAE,GAAG,CAAC,CAAC;QAE1D,OAAO,wBAAwB,CAAC,QAAQ,CAAC,UAAW,CAAC,CAAC;IACxD,CAAC,CACF,CAAC;AACJ,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nimport { createRequest, sendRequest } from \"./internal/_client.js\";\nimport type { NotificationDetails } from \"../models/notificationDetails.js\";\nimport type { NotificationHubsClientContext } from \"./index.js\";\nimport type { OperationOptions } from \"@azure-rest/core-client\";\nimport { parseNotificationDetails } from \"../serializers/notificationDetailsSerializer.js\";\nimport { tracingClient } from \"../utils/tracing.js\";\n\nconst OPERATION_NAME = \"getNotificationOutcomeDetails\";\n\n/**\n * Retrieves the results of a send operation. This can retrieve intermediate results if the send is being processed\n * or final results if the Send* has completed. This API can only be called for Standard SKU and above.\n * @param context - The Notification Hubs client.\n * @param notificationId - The notification ID returned from the send operation.\n * @param options - The operation options.\n * @returns The results of the send operation.\n */\nexport function getNotificationOutcomeDetails(\n context: NotificationHubsClientContext,\n notificationId: string,\n options: OperationOptions = {},\n): Promise<NotificationDetails> {\n return tracingClient.withSpan(\n `NotificationHubsClientContext.${OPERATION_NAME}`,\n options,\n async (updatedOptions) => {\n const endpoint = context.requestUrl();\n endpoint.pathname += `/messages/${notificationId}`;\n\n const headers = await context.createHeaders(OPERATION_NAME);\n const request = createRequest(endpoint, \"GET\", headers, updatedOptions);\n const response = await sendRequest(context, request, 200);\n\n return parseNotificationDetails(response.bodyAsText!);\n },\n );\n}\n"]}
@@ -1,6 +1,6 @@
1
- import { NotificationHubsClientContext } from "./index.js";
2
- import { OperationOptions } from "@azure-rest/core-client";
3
- import { RegistrationDescription } from "../models/registration.js";
1
+ import type { NotificationHubsClientContext } from "./index.js";
2
+ import type { OperationOptions } from "@azure-rest/core-client";
3
+ import type { RegistrationDescription } from "../models/registration.js";
4
4
  /**
5
5
  * Gets a registration by the given registration ID.
6
6
  * @param context - The Notification Hubs client.
@@ -1 +1 @@
1
- {"version":3,"file":"getRegistration.d.ts","sourceRoot":"","sources":["../../../src/api/getRegistration.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,6BAA6B,EAAE,MAAM,YAAY,CAAC;AAC3D,OAAO,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAC3D,OAAO,EAAE,uBAAuB,EAAE,MAAM,2BAA2B,CAAC;AAMpE;;;;;;GAMG;AACH,wBAAgB,eAAe,CAC7B,OAAO,EAAE,6BAA6B,EACtC,cAAc,EAAE,MAAM,EACtB,OAAO,GAAE,gBAAqB,GAC7B,OAAO,CAAC,uBAAuB,CAAC,CAiBlC"}
1
+ {"version":3,"file":"getRegistration.d.ts","sourceRoot":"","sources":["../../../src/api/getRegistration.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,6BAA6B,EAAE,MAAM,YAAY,CAAC;AAChE,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAChE,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,2BAA2B,CAAC;AAMzE;;;;;;GAMG;AACH,wBAAgB,eAAe,CAC7B,OAAO,EAAE,6BAA6B,EACtC,cAAc,EAAE,MAAM,EACtB,OAAO,GAAE,gBAAqB,GAC7B,OAAO,CAAC,uBAAuB,CAAC,CAiBlC"}
@@ -1 +1 @@
1
- {"version":3,"file":"getRegistration.js","sourceRoot":"","sources":["../../../src/api/getRegistration.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,OAAO,EAAE,aAAa,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;AAInE,OAAO,EAAE,6BAA6B,EAAE,MAAM,0CAA0C,CAAC;AACzF,OAAO,EAAE,aAAa,EAAE,MAAM,qBAAqB,CAAC;AAEpD,MAAM,cAAc,GAAG,iBAAiB,CAAC;AAEzC;;;;;;GAMG;AACH,MAAM,UAAU,eAAe,CAC7B,OAAsC,EACtC,cAAsB,EACtB,UAA4B,EAAE;IAE9B,OAAO,aAAa,CAAC,QAAQ,CAC3B,iCAAiC,cAAc,EAAE,EACjD,OAAO,EACP,KAAK,EAAE,cAAc,EAAE,EAAE;QACvB,MAAM,QAAQ,GAAG,OAAO,CAAC,UAAU,EAAE,CAAC;QACtC,QAAQ,CAAC,QAAQ,IAAI,kBAAkB,cAAc,EAAE,CAAC;QAExD,MAAM,OAAO,GAAG,MAAM,OAAO,CAAC,aAAa,CAAC,cAAc,CAAC,CAAC;QAC5D,OAAO,CAAC,GAAG,CAAC,cAAc,EAAE,0CAA0C,CAAC,CAAC;QAExE,MAAM,OAAO,GAAG,aAAa,CAAC,QAAQ,EAAE,KAAK,EAAE,OAAO,EAAE,cAAc,CAAC,CAAC;QACxE,MAAM,QAAQ,GAAG,MAAM,WAAW,CAAC,OAAO,EAAE,OAAO,EAAE,GAAG,CAAC,CAAC;QAE1D,OAAO,6BAA6B,CAAC,sBAAsB,CAAC,QAAQ,CAAC,UAAW,CAAC,CAAC;IACpF,CAAC,CACF,CAAC;AACJ,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nimport { createRequest, sendRequest } from \"./internal/_client.js\";\nimport { NotificationHubsClientContext } from \"./index.js\";\nimport { OperationOptions } from \"@azure-rest/core-client\";\nimport { RegistrationDescription } from \"../models/registration.js\";\nimport { registrationDescriptionParser } from \"../serializers/registrationSerializer.js\";\nimport { tracingClient } from \"../utils/tracing.js\";\n\nconst OPERATION_NAME = \"getRegistration\";\n\n/**\n * Gets a registration by the given registration ID.\n * @param context - The Notification Hubs client.\n * @param registrationId - The ID of the registration to get.\n * @param options - The options for getting a registration by ID.\n * @returns A RegistrationDescription that has the given registration ID.\n */\nexport function getRegistration(\n context: NotificationHubsClientContext,\n registrationId: string,\n options: OperationOptions = {},\n): Promise<RegistrationDescription> {\n return tracingClient.withSpan(\n `NotificationHubsClientContext.${OPERATION_NAME}`,\n options,\n async (updatedOptions) => {\n const endpoint = context.requestUrl();\n endpoint.pathname += `/registrations/${registrationId}`;\n\n const headers = await context.createHeaders(OPERATION_NAME);\n headers.set(\"Content-Type\", \"application/xml;type=entry;charset=utf-8\");\n\n const request = createRequest(endpoint, \"GET\", headers, updatedOptions);\n const response = await sendRequest(context, request, 200);\n\n return registrationDescriptionParser.parseRegistrationEntry(response.bodyAsText!);\n },\n );\n}\n"]}
1
+ {"version":3,"file":"getRegistration.js","sourceRoot":"","sources":["../../../src/api/getRegistration.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,OAAO,EAAE,aAAa,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;AAInE,OAAO,EAAE,6BAA6B,EAAE,MAAM,0CAA0C,CAAC;AACzF,OAAO,EAAE,aAAa,EAAE,MAAM,qBAAqB,CAAC;AAEpD,MAAM,cAAc,GAAG,iBAAiB,CAAC;AAEzC;;;;;;GAMG;AACH,MAAM,UAAU,eAAe,CAC7B,OAAsC,EACtC,cAAsB,EACtB,UAA4B,EAAE;IAE9B,OAAO,aAAa,CAAC,QAAQ,CAC3B,iCAAiC,cAAc,EAAE,EACjD,OAAO,EACP,KAAK,EAAE,cAAc,EAAE,EAAE;QACvB,MAAM,QAAQ,GAAG,OAAO,CAAC,UAAU,EAAE,CAAC;QACtC,QAAQ,CAAC,QAAQ,IAAI,kBAAkB,cAAc,EAAE,CAAC;QAExD,MAAM,OAAO,GAAG,MAAM,OAAO,CAAC,aAAa,CAAC,cAAc,CAAC,CAAC;QAC5D,OAAO,CAAC,GAAG,CAAC,cAAc,EAAE,0CAA0C,CAAC,CAAC;QAExE,MAAM,OAAO,GAAG,aAAa,CAAC,QAAQ,EAAE,KAAK,EAAE,OAAO,EAAE,cAAc,CAAC,CAAC;QACxE,MAAM,QAAQ,GAAG,MAAM,WAAW,CAAC,OAAO,EAAE,OAAO,EAAE,GAAG,CAAC,CAAC;QAE1D,OAAO,6BAA6B,CAAC,sBAAsB,CAAC,QAAQ,CAAC,UAAW,CAAC,CAAC;IACpF,CAAC,CACF,CAAC;AACJ,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nimport { createRequest, sendRequest } from \"./internal/_client.js\";\nimport type { NotificationHubsClientContext } from \"./index.js\";\nimport type { OperationOptions } from \"@azure-rest/core-client\";\nimport type { RegistrationDescription } from \"../models/registration.js\";\nimport { registrationDescriptionParser } from \"../serializers/registrationSerializer.js\";\nimport { tracingClient } from \"../utils/tracing.js\";\n\nconst OPERATION_NAME = \"getRegistration\";\n\n/**\n * Gets a registration by the given registration ID.\n * @param context - The Notification Hubs client.\n * @param registrationId - The ID of the registration to get.\n * @param options - The options for getting a registration by ID.\n * @returns A RegistrationDescription that has the given registration ID.\n */\nexport function getRegistration(\n context: NotificationHubsClientContext,\n registrationId: string,\n options: OperationOptions = {},\n): Promise<RegistrationDescription> {\n return tracingClient.withSpan(\n `NotificationHubsClientContext.${OPERATION_NAME}`,\n options,\n async (updatedOptions) => {\n const endpoint = context.requestUrl();\n endpoint.pathname += `/registrations/${registrationId}`;\n\n const headers = await context.createHeaders(OPERATION_NAME);\n headers.set(\"Content-Type\", \"application/xml;type=entry;charset=utf-8\");\n\n const request = createRequest(endpoint, \"GET\", headers, updatedOptions);\n const response = await sendRequest(context, request, 200);\n\n return registrationDescriptionParser.parseRegistrationEntry(response.bodyAsText!);\n },\n );\n}\n"]}
@@ -1,7 +1,7 @@
1
- import { HttpHeaders, HttpMethods, PipelineRequest, PipelineResponse } from "@azure/core-rest-pipeline";
2
- import { NotificationHubsMessageResponse, NotificationHubsResponse } from "../../models/notificationDetails.js";
3
- import { NotificationHubsClientContext } from "../index.js";
4
- import { OperationOptions } from "@azure-rest/core-client";
1
+ import type { HttpHeaders, HttpMethods, PipelineRequest, PipelineResponse } from "@azure/core-rest-pipeline";
2
+ import type { NotificationHubsMessageResponse, NotificationHubsResponse } from "../../models/notificationDetails.js";
3
+ import type { NotificationHubsClientContext } from "../index.js";
4
+ import type { OperationOptions } from "@azure-rest/core-client";
5
5
  export declare function createRequest(endpoint: URL, method: HttpMethods, headers: HttpHeaders, options: OperationOptions): PipelineRequest;
6
6
  /**
7
7
  * Parses the HTTP response and creates a NotificationHubsResponse with header information from the operation.
@@ -1 +1 @@
1
- {"version":3,"file":"_client.d.ts","sourceRoot":"","sources":["../../../../src/api/internal/_client.ts"],"names":[],"mappings":"AAGA,OAAO,EACL,WAAW,EACX,WAAW,EACX,eAAe,EACf,gBAAgB,EAGjB,MAAM,2BAA2B,CAAC;AACnC,OAAO,EACL,+BAA+B,EAC/B,wBAAwB,EACzB,MAAM,qCAAqC,CAAC;AAC7C,OAAO,EAAE,6BAA6B,EAAE,MAAM,aAAa,CAAC;AAC5D,OAAO,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAK3D,wBAAgB,aAAa,CAC3B,QAAQ,EAAE,GAAG,EACb,MAAM,EAAE,WAAW,EACnB,OAAO,EAAE,WAAW,EACpB,OAAO,EAAE,gBAAgB,GACxB,eAAe,CASjB;AAED;;;;GAIG;AACH,wBAAgB,yBAAyB,CAAC,QAAQ,EAAE,gBAAgB,GAAG,wBAAwB,CAU9F;AAED;;;;GAIG;AACH,wBAAsB,6BAA6B,CACjD,QAAQ,EAAE,gBAAgB,GACzB,OAAO,CAAC,+BAA+B,CAAC,CAwB1C;AAgBD;;;;;;GAMG;AACH,wBAAsB,WAAW,CAC/B,OAAO,EAAE,6BAA6B,EACtC,OAAO,EAAE,eAAe,EACxB,iBAAiB,EAAE,MAAM,GAAG,MAAM,EAAE,GACnC,OAAO,CAAC,gBAAgB,CAAC,CA4B3B"}
1
+ {"version":3,"file":"_client.d.ts","sourceRoot":"","sources":["../../../../src/api/internal/_client.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EACV,WAAW,EACX,WAAW,EACX,eAAe,EACf,gBAAgB,EACjB,MAAM,2BAA2B,CAAC;AAEnC,OAAO,KAAK,EACV,+BAA+B,EAC/B,wBAAwB,EACzB,MAAM,qCAAqC,CAAC;AAC7C,OAAO,KAAK,EAAE,6BAA6B,EAAE,MAAM,aAAa,CAAC;AACjE,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAKhE,wBAAgB,aAAa,CAC3B,QAAQ,EAAE,GAAG,EACb,MAAM,EAAE,WAAW,EACnB,OAAO,EAAE,WAAW,EACpB,OAAO,EAAE,gBAAgB,GACxB,eAAe,CASjB;AAED;;;;GAIG;AACH,wBAAgB,yBAAyB,CAAC,QAAQ,EAAE,gBAAgB,GAAG,wBAAwB,CAU9F;AAED;;;;GAIG;AACH,wBAAsB,6BAA6B,CACjD,QAAQ,EAAE,gBAAgB,GACzB,OAAO,CAAC,+BAA+B,CAAC,CAwB1C;AAgBD;;;;;;GAMG;AACH,wBAAsB,WAAW,CAC/B,OAAO,EAAE,6BAA6B,EACtC,OAAO,EAAE,eAAe,EACxB,iBAAiB,EAAE,MAAM,GAAG,MAAM,EAAE,GACnC,OAAO,CAAC,gBAAgB,CAAC,CA4B3B"}
@@ -1,6 +1,6 @@
1
1
  // Copyright (c) Microsoft Corporation.
2
2
  // Licensed under the MIT License.
3
- import { RestError, createPipelineRequest, } from "@azure/core-rest-pipeline";
3
+ import { RestError, createPipelineRequest } from "@azure/core-rest-pipeline";
4
4
  import { isDefined } from "../../utils/utils.js";
5
5
  import { parseNotificationOutcome } from "../../serializers/notificationOutcomeSerializer.js";
6
6
  import { parseXMLError } from "../../utils/xmlUtils.js";
@@ -1 +1 @@
1
- {"version":3,"file":"_client.js","sourceRoot":"","sources":["../../../../src/api/internal/_client.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,OAAO,EAKL,SAAS,EACT,qBAAq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I,OAA2B,CAAC;QAChC,IAAI,SAAS,CAAC,YAAY,CAAC,EAAE,CAAC;YAC5B,OAAO,GAAG,MAAM,aAAa,CAAC,YAAY,CAAC,CAAC;QAC9C,CAAC;QAED,IAAI,YAAgC,CAAC;QACrC,IAAI,SAAS,CAAC,OAAO,CAAC,EAAE,CAAC;YACvB,YAAY,GAAG,2BAA2B,OAAO,EAAE,CAAC;QACtD,CAAC;aAAM,CAAC;YACN,YAAY,GAAG,gCAAgC,QAAQ,CAAC,MAAM,EAAE,CAAC;QACnE,CAAC;QAED,MAAM,IAAI,SAAS,CAAC,YAAY,EAAE;YAChC,UAAU,EAAE,QAAQ,CAAC,MAAM;YAC3B,QAAQ;SACT,CAAC,CAAC;IACL,CAAC;IAED,OAAO,QAAQ,CAAC;AAClB,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nimport {\n HttpHeaders,\n HttpMethods,\n PipelineRequest,\n PipelineResponse,\n RestError,\n createPipelineRequest,\n} from \"@azure/core-rest-pipeline\";\nimport {\n NotificationHubsMessageResponse,\n NotificationHubsResponse,\n} from \"../../models/notificationDetails.js\";\nimport { NotificationHubsClientContext } from \"../index.js\";\nimport { OperationOptions } from \"@azure-rest/core-client\";\nimport { isDefined } from \"../../utils/utils.js\";\nimport { parseNotificationOutcome } from \"../../serializers/notificationOutcomeSerializer.js\";\nimport { parseXMLError } from \"../../utils/xmlUtils.js\";\n\nexport function createRequest(\n endpoint: URL,\n method: HttpMethods,\n headers: HttpHeaders,\n options: OperationOptions,\n): PipelineRequest {\n return createPipelineRequest({\n ...options.tracingOptions,\n ...options.requestOptions,\n url: endpoint.toString(),\n abortSignal: options.abortSignal,\n method,\n headers,\n });\n}\n\n/**\n * Parses the HTTP response and creates a NotificationHubsResponse with header information from the operation.\n * @param response - The HTTP response used to populate the result.\n * @returns A NotificationHubsResponse with header information from the operation.\n */\nexport function parseNotificationResponse(response: PipelineResponse): NotificationHubsResponse {\n const correlationId = response.headers.get(\"x-ms-correlation-request-id\");\n const trackingId = response.headers.get(\"TrackingId\");\n const location = response.headers.get(\"Location\");\n\n return {\n correlationId,\n trackingId,\n location,\n };\n}\n\n/**\n * Parses the HTTP response and creates a NotificationHubsMessageResponse with results from the notification.\n * @param response - The HTTP response used to populate the result.\n * @returns A NotificationHubsMessageResponse with results from the notification.\n */\nexport async function parseNotificationSendResponse(\n response: PipelineResponse,\n): Promise<NotificationHubsMessageResponse> {\n const result = parseNotificationResponse(response);\n let notificationId: string | undefined;\n if (result.location) {\n const locationUrl = new URL(result.location);\n notificationId = locationUrl.pathname.split(\"/\")[3];\n }\n\n const requestUrl = new URL(response.request.url);\n const isTestSend = requestUrl.searchParams.has(\"test\");\n const isDirectSend = requestUrl.searchParams.has(\"direct\");\n\n // Only broadcast/tag based sends are supported for test send\n const responseBody = response.bodyAsText;\n if (isTestSend && !isDirectSend && isDefined(responseBody)) {\n const outcome = await parseNotificationOutcome(responseBody);\n return {\n ...result,\n ...outcome,\n notificationId,\n };\n } else {\n return createDefaultResponse(result, notificationId);\n }\n}\n\nfunction createDefaultResponse(\n response: NotificationHubsResponse,\n notificationId?: string,\n): NotificationHubsMessageResponse {\n return {\n ...response,\n notificationId,\n successCount: 0,\n failureCount: 0,\n results: [],\n state: \"Enqueued\",\n };\n}\n\n/**\n * Sends a request through the client context.\n * @param context - The client context to use.\n * @param request - The HTTP request to send.\n * @param successStatusCode - A status code or list of status codes to check for success.\n * @returns The HTTP Response.\n */\nexport async function sendRequest(\n context: NotificationHubsClientContext,\n request: PipelineRequest,\n successStatusCode: number | number[],\n): Promise<PipelineResponse> {\n const statuses: number[] = Array.isArray(successStatusCode)\n ? successStatusCode\n : [successStatusCode];\n\n const response = await context.sendRequest(request);\n\n if (!statuses.some((statusCode) => statusCode === response.status)) {\n const responseBody = response.bodyAsText;\n let details: string | undefined;\n if (isDefined(responseBody)) {\n details = await parseXMLError(responseBody);\n }\n\n let errorMessage: string | undefined;\n if (isDefined(details)) {\n errorMessage = `operations failed with: ${details}`;\n } else {\n errorMessage = `operation failed with status ${response.status}`;\n }\n\n throw new RestError(errorMessage, {\n statusCode: response.status,\n response,\n });\n }\n\n return response;\n}\n"]}
1
+ {"version":3,"file":"_client.js","sourceRoot":"","sources":["../../../../src/api/internal/_client.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAQlC,OAAO,EAAE,SAAS,EAAE,qBAAqB,EAAE,MAAM,2BAA2B,CAAC;AAO7E,OAAO,EAAE,SAAS,EAAE,MAAM,sBAAsB,CAAC;AACjD,OAAO,EAAE,wBAAwB,EAAE,MAAM,oDAAoD,CAAC;AAC9F,OAAO,EAAE,aAAa,EAAE,MAAM,yBAAyB,CAAC;AAExD,MAAM,UAAU,aAAa,CAC3B,QAAa,EACb,MAAmB,EACnB,OAAoB,EACpB,OAAyB;IAEzB,OAAO,qBAAqB,+CACvB,OAAO,CAAC,cAAc,GACtB,OAAO,CAAC,cAAc,KACzB,GAAG,EAAE,QAAQ,CAAC,QAAQ,EAAE,EACxB,WAAW,EAAE,OAAO,CAAC,WAAW,EAChC,MAAM;QACN,OAAO,IACP,CAAC;AACL,CAAC;AAED;;;;GAIG;AACH,MAAM,UAAU,yBAAyB,CAAC,QAA0B;IAClE,MAAM,aAAa,GAAG,QAAQ,CAAC,OAAO,CAAC,GAAG,CAAC,6BAA6B,CAAC,CAAC;IAC1E,MAAM,UAAU,GAAG,QAAQ,CAAC,OAAO,CAAC,GAAG,CAAC,YAAY,CAAC,CAAC;IACtD,MAAM,QAAQ,GAAG,QAAQ,CAAC,OAAO,CAAC,GAAG,CAAC,UAAU,CAAC,CAAC;IAElD,OAAO;QACL,aAAa;QACb,UAAU;QACV,QAAQ;KACT,CAAC;AACJ,CAAC;AAED;;;;GAIG;AACH,MAAM,CAAC,KAAK,UAAU,6BAA6B,CACjD,QAA0B;IAE1B,MAAM,MAAM,GAAG,yBAAyB,CAAC,QAAQ,CAAC,CAAC;IACnD,IAAI,cAAkC,CAA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,CAAC;IAExB,MAAM,QAAQ,GAAG,MAAM,OAAO,CAAC,WAAW,CAAC,OAAO,CAAC,CAAC;IAEpD,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC,CAAC,UAAU,EAAE,EAAE,CAAC,UAAU,KAAK,QAAQ,CAAC,MAAM,CAAC,EAAE,CAAC;QACnE,MAAM,YAAY,GAAG,QAAQ,CAAC,UAAU,CAAC;QACzC,IAAI,OAA2B,CAAC;QAChC,IAAI,SAAS,CAAC,YAAY,CAAC,EAAE,CAAC;YAC5B,OAAO,GAAG,MAAM,aAAa,CAAC,YAAY,CAAC,CAAC;QAC9C,CAAC;QAED,IAAI,YAAgC,CAAC;QACrC,IAAI,SAAS,CAAC,OAAO,CAAC,EAAE,CAAC;YACvB,YAAY,GAAG,2BAA2B,OAAO,EAAE,CAAC;QACtD,CAAC;aAAM,CAAC;YACN,YAAY,GAAG,gCAAgC,QAAQ,CAAC,MAAM,EAAE,CAAC;QACnE,CAAC;QAED,MAAM,IAAI,SAAS,CAAC,YAAY,EAAE;YAChC,UAAU,EAAE,QAAQ,CAAC,MAAM;YAC3B,QAAQ;SACT,CAAC,CAAC;IACL,CAAC;IAED,OAAO,QAAQ,CAAC;AAClB,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nimport type {\n HttpHeaders,\n HttpMethods,\n PipelineRequest,\n PipelineResponse,\n} from \"@azure/core-rest-pipeline\";\nimport { RestError, createPipelineRequest } from \"@azure/core-rest-pipeline\";\nimport type {\n NotificationHubsMessageResponse,\n NotificationHubsResponse,\n} from \"../../models/notificationDetails.js\";\nimport type { NotificationHubsClientContext } from \"../index.js\";\nimport type { OperationOptions } from \"@azure-rest/core-client\";\nimport { isDefined } from \"../../utils/utils.js\";\nimport { parseNotificationOutcome } from \"../../serializers/notificationOutcomeSerializer.js\";\nimport { parseXMLError } from \"../../utils/xmlUtils.js\";\n\nexport function createRequest(\n endpoint: URL,\n method: HttpMethods,\n headers: HttpHeaders,\n options: OperationOptions,\n): PipelineRequest {\n return createPipelineRequest({\n ...options.tracingOptions,\n ...options.requestOptions,\n url: endpoint.toString(),\n abortSignal: options.abortSignal,\n method,\n headers,\n });\n}\n\n/**\n * Parses the HTTP response and creates a NotificationHubsResponse with header information from the operation.\n * @param response - The HTTP response used to populate the result.\n * @returns A NotificationHubsResponse with header information from the operation.\n */\nexport function parseNotificationResponse(response: PipelineResponse): NotificationHubsResponse {\n const correlationId = response.headers.get(\"x-ms-correlation-request-id\");\n const trackingId = response.headers.get(\"TrackingId\");\n const location = response.headers.get(\"Location\");\n\n return {\n correlationId,\n trackingId,\n location,\n };\n}\n\n/**\n * Parses the HTTP response and creates a NotificationHubsMessageResponse with results from the notification.\n * @param response - The HTTP response used to populate the result.\n * @returns A NotificationHubsMessageResponse with results from the notification.\n */\nexport async function parseNotificationSendResponse(\n response: PipelineResponse,\n): Promise<NotificationHubsMessageResponse> {\n const result = parseNotificationResponse(response);\n let notificationId: string | undefined;\n if (result.location) {\n const locationUrl = new URL(result.location);\n notificationId = locationUrl.pathname.split(\"/\")[3];\n }\n\n const requestUrl = new URL(response.request.url);\n const isTestSend = requestUrl.searchParams.has(\"test\");\n const isDirectSend = requestUrl.searchParams.has(\"direct\");\n\n // Only broadcast/tag based sends are supported for test send\n const responseBody = response.bodyAsText;\n if (isTestSend && !isDirectSend && isDefined(responseBody)) {\n const outcome = await parseNotificationOutcome(responseBody);\n return {\n ...result,\n ...outcome,\n notificationId,\n };\n } else {\n return createDefaultResponse(result, notificationId);\n }\n}\n\nfunction createDefaultResponse(\n response: NotificationHubsResponse,\n notificationId?: string,\n): NotificationHubsMessageResponse {\n return {\n ...response,\n notificationId,\n successCount: 0,\n failureCount: 0,\n results: [],\n state: \"Enqueued\",\n };\n}\n\n/**\n * Sends a request through the client context.\n * @param context - The client context to use.\n * @param request - The HTTP request to send.\n * @param successStatusCode - A status code or list of status codes to check for success.\n * @returns The HTTP Response.\n */\nexport async function sendRequest(\n context: NotificationHubsClientContext,\n request: PipelineRequest,\n successStatusCode: number | number[],\n): Promise<PipelineResponse> {\n const statuses: number[] = Array.isArray(successStatusCode)\n ? successStatusCode\n : [successStatusCode];\n\n const response = await context.sendRequest(request);\n\n if (!statuses.some((statusCode) => statusCode === response.status)) {\n const responseBody = response.bodyAsText;\n let details: string | undefined;\n if (isDefined(responseBody)) {\n details = await parseXMLError(responseBody);\n }\n\n let errorMessage: string | undefined;\n if (isDefined(details)) {\n errorMessage = `operations failed with: ${details}`;\n } else {\n errorMessage = `operation failed with status ${response.status}`;\n }\n\n throw new RestError(errorMessage, {\n statusCode: response.status,\n response,\n });\n }\n\n return response;\n}\n"]}
@@ -1,6 +1,6 @@
1
- import { NotificationHubsClientContext } from "../index.js";
2
- import { OperationOptions } from "@azure-rest/core-client";
3
- import { RegistrationDescription } from "../../models/registration.js";
1
+ import type { NotificationHubsClientContext } from "../index.js";
2
+ import type { OperationOptions } from "@azure-rest/core-client";
3
+ import type { RegistrationDescription } from "../../models/registration.js";
4
4
  /**
5
5
  * @internal
6
6
  */
@@ -1 +1 @@
1
- {"version":3,"file":"_createOrUpdateRegistrationDescription.d.ts","sourceRoot":"","sources":["../../../../src/api/internal/_createOrUpdateRegistrationDescription.ts"],"names":[],"mappings":"AASA,OAAO,EAAE,6BAA6B,EAAE,MAAM,aAAa,CAAC;AAC5D,OAAO,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAC3D,OAAO,EAAE,uBAAuB,EAAE,MAAM,8BAA8B,CAAC;AAGvE;;GAEG;AACH,wBAAsB,qCAAqC,CACzD,OAAO,EAAE,6BAA6B,EACtC,YAAY,EAAE,uBAAuB,EACrC,aAAa,EAAE,QAAQ,GAAG,gBAAgB,GAAG,QAAQ,EACrD,OAAO,EAAE,gBAAgB,GACxB,OAAO,CAAC,uBAAuB,CAAC,CA4BlC"}
1
+ {"version":3,"file":"_createOrUpdateRegistrationDescription.d.ts","sourceRoot":"","sources":["../../../../src/api/internal/_createOrUpdateRegistrationDescription.ts"],"names":[],"mappings":"AASA,OAAO,KAAK,EAAE,6BAA6B,EAAE,MAAM,aAAa,CAAC;AACjE,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAChE,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,8BAA8B,CAAC;AAG5E;;GAEG;AACH,wBAAsB,qCAAqC,CACzD,OAAO,EAAE,6BAA6B,EACtC,YAAY,EAAE,uBAAuB,EACrC,aAAa,EAAE,QAAQ,GAAG,gBAAgB,GAAG,QAAQ,EACrD,OAAO,EAAE,gBAAgB,GACxB,OAAO,CAAC,uBAAuB,CAAC,CA4BlC"}
@@ -1 +1 @@
1
- {"version":3,"file":"_createOrUpdateRegistrationDescription.js","sourceRoot":"","sources":["../../../../src/api/internal/_createOrUpdateRegistrationDescription.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,OAAO,EAAE,aAAa,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AAC1D,OAAO,EACL,6BAA6B,EAC7B,iCAAiC,GAClC,MAAM,6CAA6C,CAAC;AAKrD,OAAO,EAAE,SAAS,EAAE,MAAM,sBAAsB,CAAC;AAEjD;;GAEG;AACH,MAAM,CAAC,KAAK,UAAU,qCAAqC,CACzD,OAAsC,EACtC,YAAqC,EACrC,aAAqD,EACrD,OAAyB;IAEzB,MAAM,QAAQ,GAAG,OAAO,CAAC,UAAU,EAAE,CAAC;IACtC,QAAQ,CAAC,QAAQ,IAAI,gBAAgB,CAAC;IACtC,IAAI,UAAU,GAAgB,MAAM,CAAC;IAErC,IAAI,aAAa,KAAK,gBAAgB,IAAI,aAAa,KAAK,QAAQ,EAAE,CAAC;QACrE,QAAQ,CAAC,QAAQ,IAAI,IAAI,YAAY,CAAC,cAAc,EAAE,CAAC;QACvD,UAAU,GAAG,KAAK,CAAC;IACrB,CAAC;IAED,MAAM,IAAI,GAAG,YAAY,CAAC,IAAI,CAAC;IAE/B,gCAAgC;IAChC,YAAY,CAAC,cAAc,GAAG,SAAS,CAAC;IACxC,YAAY,CAAC,IAAI,GAAG,SAAS,CAAC;IAE9B,MAAM,OAAO,GAAG,MAAM,OAAO,CAAC,aAAa,CAAC,GAAG,aAAa,cAAc,CAAC,CAAC;IAC5E,OAAO,CAAC,GAAG,CAAC,cAAc,EAAE,+CAA+C,CAAC,CAAC;IAE7E,IAAI,aAAa,KAAK,QAAQ,EAAE,CAAC;QAC/B,OAAO,CAAC,GAAG,CAAC,UAAU,EAAE,SAAS,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,IAAI,IAAI,GAAG,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC;IAC/D,CAAC;IAED,MAAM,OAAO,GAAG,aAAa,CAAC,QAAQ,EAAE,UAAU,EAAE,OAAO,EAAE,OAAO,CAAC,CAAC;IACtE,OAAO,CAAC,IAAI,GAAG,iCAAiC,CAAC,gCAAgC,CAAC,YAAY,CAAC,CAAC;IAChG,MAAM,QAAQ,GAAG,MAAM,WAAW,CAAC,OAAO,EAAE,OAAO,EAAE,CAAC,GAAG,EAAE,GAAG,CAAC,CAAC,CAAC;IAEjE,OAAO,6BAA6B,CAAC,sBAAsB,CAAC,QAAQ,CAAC,UAAW,CAAC,CAAC;AACpF,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nimport { createRequest, sendRequest } from \"./_client.js\";\nimport {\n registrationDescriptionParser,\n registrationDescriptionSerializer,\n} from \"../../serializers/registrationSerializer.js\";\nimport { HttpMethods } from \"@azure/core-rest-pipeline\";\nimport { NotificationHubsClientContext } from \"../index.js\";\nimport { OperationOptions } from \"@azure-rest/core-client\";\nimport { RegistrationDescription } from \"../../models/registration.js\";\nimport { isDefined } from \"../../utils/utils.js\";\n\n/**\n * @internal\n */\nexport async function createOrUpdateRegistrationDescription(\n context: NotificationHubsClientContext,\n registration: RegistrationDescription,\n operationName: \"create\" | \"createOrUpdate\" | \"update\",\n options: OperationOptions,\n): Promise<RegistrationDescription> {\n const endpoint = context.requestUrl();\n endpoint.pathname += \"/registrations\";\n let httpMethod: HttpMethods = \"POST\";\n\n if (operationName === \"createOrUpdate\" || operationName === \"update\") {\n endpoint.pathname += `/${registration.registrationId}`;\n httpMethod = \"PUT\";\n }\n\n const etag = registration.etag;\n\n // Clear out readonly properties\n registration.registrationId = undefined;\n registration.etag = undefined;\n\n const headers = await context.createHeaders(`${operationName}Registration`);\n headers.set(\"Content-Type\", \"application/atom+xml;type=entry;charset=utf-8\");\n\n if (operationName === \"update\") {\n headers.set(\"If-Match\", isDefined(etag) ? `\"${etag}\"` : \"*\");\n }\n\n const request = createRequest(endpoint, httpMethod, headers, options);\n request.body = registrationDescriptionSerializer.serializeRegistrationDescription(registration);\n const response = await sendRequest(context, request, [200, 201]);\n\n return registrationDescriptionParser.parseRegistrationEntry(response.bodyAsText!);\n}\n"]}
1
+ {"version":3,"file":"_createOrUpdateRegistrationDescription.js","sourceRoot":"","sources":["../../../../src/api/internal/_createOrUpdateRegistrationDescription.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,OAAO,EAAE,aAAa,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AAC1D,OAAO,EACL,6BAA6B,EAC7B,iCAAiC,GAClC,MAAM,6CAA6C,CAAC;AAKrD,OAAO,EAAE,SAAS,EAAE,MAAM,sBAAsB,CAAC;AAEjD;;GAEG;AACH,MAAM,CAAC,KAAK,UAAU,qCAAqC,CACzD,OAAsC,EACtC,YAAqC,EACrC,aAAqD,EACrD,OAAyB;IAEzB,MAAM,QAAQ,GAAG,OAAO,CAAC,UAAU,EAAE,CAAC;IACtC,QAAQ,CAAC,QAAQ,IAAI,gBAAgB,CAAC;IACtC,IAAI,UAAU,GAAgB,MAAM,CAAC;IAErC,IAAI,aAAa,KAAK,gBAAgB,IAAI,aAAa,KAAK,QAAQ,EAAE,CAAC;QACrE,QAAQ,CAAC,QAAQ,IAAI,IAAI,YAAY,CAAC,cAAc,EAAE,CAAC;QACvD,UAAU,GAAG,KAAK,CAAC;IACrB,CAAC;IAED,MAAM,IAAI,GAAG,YAAY,CAAC,IAAI,CAAC;IAE/B,gCAAgC;IAChC,YAAY,CAAC,cAAc,GAAG,SAAS,CAAC;IACxC,YAAY,CAAC,IAAI,GAAG,SAAS,CAAC;IAE9B,MAAM,OAAO,GAAG,MAAM,OAAO,CAAC,aAAa,CAAC,GAAG,aAAa,cAAc,CAAC,CAAC;IAC5E,OAAO,CAAC,GAAG,CAAC,cAAc,EAAE,+CAA+C,CAAC,CAAC;IAE7E,IAAI,aAAa,KAAK,QAAQ,EAAE,CAAC;QAC/B,OAAO,CAAC,GAAG,CAAC,UAAU,EAAE,SAAS,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,IAAI,IAAI,GAAG,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC;IAC/D,CAAC;IAED,MAAM,OAAO,GAAG,aAAa,CAAC,QAAQ,EAAE,UAAU,EAAE,OAAO,EAAE,OAAO,CAAC,CAAC;IACtE,OAAO,CAAC,IAAI,GAAG,iCAAiC,CAAC,gCAAgC,CAAC,YAAY,CAAC,CAAC;IAChG,MAAM,QAAQ,GAAG,MAAM,WAAW,CAAC,OAAO,EAAE,OAAO,EAAE,CAAC,GAAG,EAAE,GAAG,CAAC,CAAC,CAAC;IAEjE,OAAO,6BAA6B,CAAC,sBAAsB,CAAC,QAAQ,CAAC,UAAW,CAAC,CAAC;AACpF,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nimport { createRequest, sendRequest } from \"./_client.js\";\nimport {\n registrationDescriptionParser,\n registrationDescriptionSerializer,\n} from \"../../serializers/registrationSerializer.js\";\nimport type { HttpMethods } from \"@azure/core-rest-pipeline\";\nimport type { NotificationHubsClientContext } from \"../index.js\";\nimport type { OperationOptions } from \"@azure-rest/core-client\";\nimport type { RegistrationDescription } from \"../../models/registration.js\";\nimport { isDefined } from \"../../utils/utils.js\";\n\n/**\n * @internal\n */\nexport async function createOrUpdateRegistrationDescription(\n context: NotificationHubsClientContext,\n registration: RegistrationDescription,\n operationName: \"create\" | \"createOrUpdate\" | \"update\",\n options: OperationOptions,\n): Promise<RegistrationDescription> {\n const endpoint = context.requestUrl();\n endpoint.pathname += \"/registrations\";\n let httpMethod: HttpMethods = \"POST\";\n\n if (operationName === \"createOrUpdate\" || operationName === \"update\") {\n endpoint.pathname += `/${registration.registrationId}`;\n httpMethod = \"PUT\";\n }\n\n const etag = registration.etag;\n\n // Clear out readonly properties\n registration.registrationId = undefined;\n registration.etag = undefined;\n\n const headers = await context.createHeaders(`${operationName}Registration`);\n headers.set(\"Content-Type\", \"application/atom+xml;type=entry;charset=utf-8\");\n\n if (operationName === \"update\") {\n headers.set(\"If-Match\", isDefined(etag) ? `\"${etag}\"` : \"*\");\n }\n\n const request = createRequest(endpoint, httpMethod, headers, options);\n request.body = registrationDescriptionSerializer.serializeRegistrationDescription(registration);\n const response = await sendRequest(context, request, [200, 201]);\n\n return registrationDescriptionParser.parseRegistrationEntry(response.bodyAsText!);\n}\n"]}
@@ -1,6 +1,6 @@
1
- import { NotificationHubsClientContext } from "../index.js";
2
- import { RegistrationDescription } from "../../models/registration.js";
3
- import { RegistrationQueryOptions } from "../../models/options.js";
1
+ import type { NotificationHubsClientContext } from "../index.js";
2
+ import type { RegistrationDescription } from "../../models/registration.js";
3
+ import type { RegistrationQueryOptions } from "../../models/options.js";
4
4
  export declare function listRegistrationsAll(context: NotificationHubsClientContext, options: RegistrationQueryOptions): AsyncIterableIterator<RegistrationDescription>;
5
5
  export declare function listRegistrationPagingPage(context: NotificationHubsClientContext, options: RegistrationQueryOptions): AsyncIterableIterator<RegistrationDescription[]>;
6
6
  //# sourceMappingURL=_listRegistrations.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"_listRegistrations.d.ts","sourceRoot":"","sources":["../../../../src/api/internal/_listRegistrations.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,6BAA6B,EAAE,MAAM,aAAa,CAAC;AAC5D,OAAO,EAAE,uBAAuB,EAAE,MAAM,8BAA8B,CAAC;AACvE,OAAO,EAAE,wBAAwB,EAAE,MAAM,yBAAyB,CAAC;AAInE,wBAAuB,oBAAoB,CACzC,OAAO,EAAE,6BAA6B,EACtC,OAAO,EAAE,wBAAwB,GAChC,qBAAqB,CAAC,uBAAuB,CAAC,CAIhD;AAED,wBAAuB,0BAA0B,CAC/C,OAAO,EAAE,6BAA6B,EACtC,OAAO,EAAE,wBAAwB,GAChC,qBAAqB,CAAC,uBAAuB,EAAE,CAAC,CASlD"}
1
+ {"version":3,"file":"_listRegistrations.d.ts","sourceRoot":"","sources":["../../../../src/api/internal/_listRegistrations.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,6BAA6B,EAAE,MAAM,aAAa,CAAC;AACjE,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,8BAA8B,CAAC;AAC5E,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,yBAAyB,CAAC;AAIxE,wBAAuB,oBAAoB,CACzC,OAAO,EAAE,6BAA6B,EACtC,OAAO,EAAE,wBAAwB,GAChC,qBAAqB,CAAC,uBAAuB,CAAC,CAIhD;AAED,wBAAuB,0BAA0B,CAC/C,OAAO,EAAE,6BAA6B,EACtC,OAAO,EAAE,wBAAwB,GAChC,qBAAqB,CAAC,uBAAuB,EAAE,CAAC,CASlD"}
@@ -1 +1 @@
1
- {"version":3,"file":"_listRegistrations.js","sourceRoot":"","sources":["../../../../src/api/internal/_listRegistrations.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;;AAElC,OAAO,EAAE,aAAa,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AAK1D,OAAO,EAAE,6BAA6B,EAAE,MAAM,6CAA6C,CAAC;AAE5F,MAAM,UAAiB,oBAAoB,CACzC,OAAsC,EACtC,OAAiC;;;;YAEjC,KAAyB,eAAA,KAAA,cAAA,0BAA0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AAiB,KAAK,SAAS,EAAE,CAAC;QACpC,QAAQ,CAAC,YAAY,CAAC,GAAG,CAAC,mBAAmB,EAAE,iBAAiB,CAAC,CAAC;IACpE,CAAC;IAED,MAAM,OAAO,GAAG,MAAM,OAAO,CAAC,aAAa,CAAC,mBAAmB,CAAC,CAAC;IACjE,MAAM,OAAO,GAAG,aAAa,CAAC,QAAQ,EAAE,KAAK,EAAE,OAAO,EAAE,OAAO,CAAC,CAAC;IACjE,MAAM,QAAQ,GAAG,MAAM,WAAW,CAAC,OAAO,EAAE,OAAO,EAAE,GAAG,CAAC,CAAC;IAE1D,MAAM,aAAa,GAAG,MAAM,6BAA6B,CAAC,qBAAqB,CAC7E,QAAQ,CAAC,UAAW,CACrB,CAAC;IACF,MAAM,SAAS,GAAG,QAAQ,CAAC,OAAO,CAAC,GAAG,CAAC,wBAAwB,CAAC,CAAC;IACjE,OAAO;QACL,aAAa;QACb,iBAAiB,EAAE,SAAS;KAC7B,CAAC;AACJ,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nimport { createRequest, sendRequest } from \"./_client.js\";\nimport { NotificationHubsClientContext } from \"../index.js\";\nimport { RegistrationDescription } from \"../../models/registration.js\";\nimport { RegistrationQueryOptions } from \"../../models/options.js\";\nimport { RegistrationQueryResponse } from \"../../models/response.js\";\nimport { registrationDescriptionParser } from \"../../serializers/registrationSerializer.js\";\n\nexport async function* listRegistrationsAll(\n context: NotificationHubsClientContext,\n options: RegistrationQueryOptions,\n): AsyncIterableIterator<RegistrationDescription> {\n for await (const page of listRegistrationPagingPage(context, options)) {\n yield* page;\n }\n}\n\nexport async function* listRegistrationPagingPage(\n context: NotificationHubsClientContext,\n options: RegistrationQueryOptions,\n): AsyncIterableIterator<RegistrationDescription[]> {\n let result = await _listRegistrations(context, options);\n yield result.registrations || [];\n let continuationToken = result.continuationToken;\n while (continuationToken) {\n result = await _listRegistrations(context, options, continuationToken);\n continuationToken = result.continuationToken;\n yield result.registrations || [];\n }\n}\n\nasync function _listRegistrations(\n context: NotificationHubsClientContext,\n options: RegistrationQueryOptions,\n continuationToken?: string,\n): Promise<RegistrationQueryResponse> {\n const endpoint = context.requestUrl();\n endpoint.pathname += \"/registrations\";\n if (options.top !== undefined) {\n endpoint.searchParams.set(\"$top\", `${options.top}`);\n }\n\n if (options.filter !== undefined) {\n endpoint.searchParams.set(\"$filter\", options.filter);\n }\n\n if (continuationToken !== undefined) {\n endpoint.searchParams.set(\"continuationtoken\", continuationToken);\n }\n\n const headers = await context.createHeaders(\"listRegistrations\");\n const request = createRequest(endpoint, \"GET\", headers, options);\n const response = await sendRequest(context, request, 200);\n\n const registrations = await registrationDescriptionParser.parseRegistrationFeed(\n response.bodyAsText!,\n );\n const nextToken = response.headers.get(\"x-ms-continuationtoken\");\n return {\n registrations,\n continuationToken: nextToken,\n };\n}\n"]}
1
+ {"version":3,"file":"_listRegistrations.js","sourceRoot":"","sources":["../../../../src/api/internal/_listRegistrations.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;;AAElC,OAAO,EAAE,aAAa,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AAK1D,OAAO,EAAE,6BAA6B,EAAE,MAAM,6CAA6C,CAAC;AAE5F,MAAM,UAAiB,oBAAoB,CACzC,OAAsC,EACtC,OAAiC;;;;YAEjC,KAAyB,eAAA,KAAA,cAAA,0BAA0B,CAAC,OAAO,EAAE,OAAO,CAAC,CAAA,IAAA,+DAAE,CAAC;gBAA/C,cAA4C;gBAA5C,WAA4C;gBAA1D,MAAM,IAAI,KAAA,CAAA;gBACnB,cAAA,KAAK,CAAC,CAAC,iBAAA,cAAA,IAAI,CAAA,CAAA,CAAA,CAAC;YACd,CAAC;;;;;;;;;IACH,CAAC;CAAA;AAED,MAAM,UAAiB,0BAA0B,CAC/C,OAAsC,EACtC,OAAiC;;QAEjC,IAAI,MAAM,GAAG,cAAM,kBAAkB,CAAC,OAAO,EAAE,OAAO,CAAC,CAA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C,CAAC;IAE1D,MAAM,aAAa,GAAG,MAAM,6BAA6B,CAAC,qBAAqB,CAC7E,QAAQ,CAAC,UAAW,CACrB,CAAC;IACF,MAAM,SAAS,GAAG,QAAQ,CAAC,OAAO,CAAC,GAAG,CAAC,wBAAwB,CAAC,CAAC;IACjE,OAAO;QACL,aAAa;QACb,iBAAiB,EAAE,SAAS;KAC7B,CAAC;AACJ,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nimport { createRequest, sendRequest } from \"./_client.js\";\nimport type { NotificationHubsClientContext } from \"../index.js\";\nimport type { RegistrationDescription } from \"../../models/registration.js\";\nimport type { RegistrationQueryOptions } from \"../../models/options.js\";\nimport type { RegistrationQueryResponse } from \"../../models/response.js\";\nimport { registrationDescriptionParser } from \"../../serializers/registrationSerializer.js\";\n\nexport async function* listRegistrationsAll(\n context: NotificationHubsClientContext,\n options: RegistrationQueryOptions,\n): AsyncIterableIterator<RegistrationDescription> {\n for await (const page of listRegistrationPagingPage(context, options)) {\n yield* page;\n }\n}\n\nexport async function* listRegistrationPagingPage(\n context: NotificationHubsClientContext,\n options: RegistrationQueryOptions,\n): AsyncIterableIterator<RegistrationDescription[]> {\n let result = await _listRegistrations(context, options);\n yield result.registrations || [];\n let continuationToken = result.continuationToken;\n while (continuationToken) {\n result = await _listRegistrations(context, options, continuationToken);\n continuationToken = result.continuationToken;\n yield result.registrations || [];\n }\n}\n\nasync function _listRegistrations(\n context: NotificationHubsClientContext,\n options: RegistrationQueryOptions,\n continuationToken?: string,\n): Promise<RegistrationQueryResponse> {\n const endpoint = context.requestUrl();\n endpoint.pathname += \"/registrations\";\n if (options.top !== undefined) {\n endpoint.searchParams.set(\"$top\", `${options.top}`);\n }\n\n if (options.filter !== undefined) {\n endpoint.searchParams.set(\"$filter\", options.filter);\n }\n\n if (continuationToken !== undefined) {\n endpoint.searchParams.set(\"continuationtoken\", continuationToken);\n }\n\n const headers = await context.createHeaders(\"listRegistrations\");\n const request = createRequest(endpoint, \"GET\", headers, options);\n const response = await sendRequest(context, request, 200);\n\n const registrations = await registrationDescriptionParser.parseRegistrationFeed(\n response.bodyAsText!,\n );\n const nextToken = response.headers.get(\"x-ms-continuationtoken\");\n return {\n registrations,\n continuationToken: nextToken,\n };\n}\n"]}
@@ -1,7 +1,7 @@
1
- import { Notification } from "../../models/notification.js";
2
- import { NotificationHubsClientContext } from "../index.js";
3
- import { NotificationHubsMessageResponse } from "../../models/notificationDetails.js";
4
- import { OperationOptions } from "@azure-rest/core-client";
1
+ import type { Notification } from "../../models/notification.js";
2
+ import type { NotificationHubsClientContext } from "../index.js";
3
+ import type { NotificationHubsMessageResponse } from "../../models/notificationDetails.js";
4
+ import type { OperationOptions } from "@azure-rest/core-client";
5
5
  /**
6
6
  * Schedules a push notification to devices that match the given tags or tag expression at the specified time.
7
7
  * NOTE: This is only available in Standard SKU Azure Notification Hubs.
@@ -1 +1 @@
1
- {"version":3,"file":"_scheduleNotification.d.ts","sourceRoot":"","sources":["../../../../src/api/internal/_scheduleNotification.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,YAAY,EAAE,MAAM,8BAA8B,CAAC;AAC5D,OAAO,EAAE,6BAA6B,EAAE,MAAM,aAAa,CAAC;AAC5D,OAAO,EAAE,+BAA+B,EAAE,MAAM,qCAAqC,CAAC;AAEtF,OAAO,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAE3D;;;;;;;;GAQG;AACH,wBAAgB,4BAA4B,CAC1C,OAAO,EAAE,6BAA6B,EACtC,aAAa,EAAE,IAAI,EACnB,YAAY,EAAE,YAAY,EAC1B,OAAO,EAAE,gBAAgB,EACzB,MAAM,EAAE,MAAM,EACd,aAAa,CAAC,EAAE,MAAM,GACrB,OAAO,CAAC,+BAA+B,CAAC,CA2B1C"}
1
+ {"version":3,"file":"_scheduleNotification.d.ts","sourceRoot":"","sources":["../../../../src/api/internal/_scheduleNotification.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,8BAA8B,CAAC;AACjE,OAAO,KAAK,EAAE,6BAA6B,EAAE,MAAM,aAAa,CAAC;AACjE,OAAO,KAAK,EAAE,+BAA+B,EAAE,MAAM,qCAAqC,CAAC;AAE3F,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAEhE;;;;;;;;GAQG;AACH,wBAAgB,4BAA4B,CAC1C,OAAO,EAAE,6BAA6B,EACtC,aAAa,EAAE,IAAI,EACnB,YAAY,EAAE,YAAY,EAC1B,OAAO,EAAE,gBAAgB,EACzB,MAAM,EAAE,MAAM,EACd,aAAa,CAAC,EAAE,MAAM,GACrB,OAAO,CAAC,+BAA+B,CAAC,CA2B1C"}
@@ -1 +1 @@
1
- {"version":3,"file":"_scheduleNotification.js","sourceRoot":"","sources":["../../../../src/api/internal/_scheduleNotification.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,OAAO,EAAE,aAAa,EAAE,6BAA6B,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AAKzF,OAAO,EAAE,aAAa,EAAE,MAAM,wBAAwB,CAAC;AAGvD;;;;;;;;GAQG;AACH,MAAM,UAAU,4BAA4B,CAC1C,OAAsC,EACtC,aAAmB,EACnB,YAA0B,EAC1B,OAAyB,EACzB,MAAc,EACd,aAAsB;IAEtB,OAAO,aAAa,CAAC,QAAQ,CAC3B,iCAAiC,MAAM,EAAE,EACzC,OAAO,EACP,KAAK,EAAE,cAAc,EAAE,EAAE;QACvB,MAAM,QAAQ,GAAG,OAAO,CAAC,UAAU,EAAE,CAAC;QACtC,QAAQ,CAAC,QAAQ,IAAI,0BAA0B,CAAC;QAEhD,MAAM,OAAO,GAAG,MAAM,OAAO,CAAC,aAAa,CACzC,sBAAsB,EACtB,YAAY,CAAC,OAA4B,CAC1C,CAAC;QACF,OAAO,CAAC,GAAG,CAAC,qCAAqC,EAAE,aAAa,CAAC,WAAW,EAAE,CAAC,CAAC;QAChF,OAAO,CAAC,GAAG,CAAC,cAAc,EAAE,YAAY,CAAC,WAAW,CAAC,CAAC;QACtD,OAAO,CAAC,GAAG,CAAC,+BAA+B,EAAE,YAAY,CAAC,QAAQ,CAAC,CAAC;QACpE,IAAI,aAAa,EAAE,CAAC;YAClB,OAAO,CAAC,GAAG,CAAC,6BAA6B,EAAE,aAAa,CAAC,CAAC;QAC5D,CAAC;QAED,MAAM,OAAO,GAAG,aAAa,CAAC,QAAQ,EAAE,MAAM,EAAE,OAAO,EAAE,cAAc,CAAC,CAAC;QACzE,OAAO,CAAC,IAAI,GAAG,YAAY,CAAC,IAAI,CAAC;QAEjC,MAAM,QAAQ,GAAG,MAAM,WAAW,CAAC,OAAO,EAAE,OAAO,EAAE,GAAG,CAAC,CAAC;QAE1D,OAAO,6BAA6B,CAAC,QAAQ,CAAC,CAAC;IACjD,CAAC,CACF,CAAC;AACJ,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nimport { createRequest, parseNotificationSendResponse, sendRequest } from \"./_client.js\";\nimport { NonNullableRecord } from \"../../utils/utils.js\";\nimport { Notification } from \"../../models/notification.js\";\nimport { NotificationHubsClientContext } from \"../index.js\";\nimport { NotificationHubsMessageResponse } from \"../../models/notificationDetails.js\";\nimport { tracingClient } from \"../../utils/tracing.js\";\nimport { OperationOptions } from \"@azure-rest/core-client\";\n\n/**\n * Schedules a push notification to devices that match the given tags or tag expression at the specified time.\n * NOTE: This is only available in Standard SKU Azure Notification Hubs.\n * @param context - The Notification Hubs client.\n * @param scheduledTime - The Date to send the push notification.\n * @param notification - The notification to send to the matching devices.\n * @param options - Options which include tags used to target the device for push notifications in either an array or tag expression.\n * @returns A NotificationHubResponse with the tracking ID, correlation ID and location.\n */\nexport function scheduleNotificationInternal(\n context: NotificationHubsClientContext,\n scheduledTime: Date,\n notification: Notification,\n options: OperationOptions,\n method: string,\n tagExpression?: string,\n): Promise<NotificationHubsMessageResponse> {\n return tracingClient.withSpan(\n `NotificationHubsClientContext.${method}`,\n options,\n async (updatedOptions) => {\n const endpoint = context.requestUrl();\n endpoint.pathname += \"/schedulednotifications/\";\n\n const headers = await context.createHeaders(\n \"scheduleNotification\",\n notification.headers as NonNullableRecord,\n );\n headers.set(\"ServiceBusNotification-ScheduleTime\", scheduledTime.toISOString());\n headers.set(\"Content-Type\", notification.contentType);\n headers.set(\"ServiceBusNotification-Format\", notification.platform);\n if (tagExpression) {\n headers.set(\"ServiceBusNotification-Tags\", tagExpression);\n }\n\n const request = createRequest(endpoint, \"POST\", headers, updatedOptions);\n request.body = notification.body;\n\n const response = await sendRequest(context, request, 201);\n\n return parseNotificationSendResponse(response);\n },\n );\n}\n"]}
1
+ {"version":3,"file":"_scheduleNotification.js","sourceRoot":"","sources":["../../../../src/api/internal/_scheduleNotification.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,OAAO,EAAE,aAAa,EAAE,6BAA6B,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AAKzF,OAAO,EAAE,aAAa,EAAE,MAAM,wBAAwB,CAAC;AAGvD;;;;;;;;GAQG;AACH,MAAM,UAAU,4BAA4B,CAC1C,OAAsC,EACtC,aAAmB,EACnB,YAA0B,EAC1B,OAAyB,EACzB,MAAc,EACd,aAAsB;IAEtB,OAAO,aAAa,CAAC,QAAQ,CAC3B,iCAAiC,MAAM,EAAE,EACzC,OAAO,EACP,KAAK,EAAE,cAAc,EAAE,EAAE;QACvB,MAAM,QAAQ,GAAG,OAAO,CAAC,UAAU,EAAE,CAAC;QACtC,QAAQ,CAAC,QAAQ,IAAI,0BAA0B,CAAC;QAEhD,MAAM,OAAO,GAAG,MAAM,OAAO,CAAC,aAAa,CACzC,sBAAsB,EACtB,YAAY,CAAC,OAA4B,CAC1C,CAAC;QACF,OAAO,CAAC,GAAG,CAAC,qCAAqC,EAAE,aAAa,CAAC,WAAW,EAAE,CAAC,CAAC;QAChF,OAAO,CAAC,GAAG,CAAC,cAAc,EAAE,YAAY,CAAC,WAAW,CAAC,CAAC;QACtD,OAAO,CAAC,GAAG,CAAC,+BAA+B,EAAE,YAAY,CAAC,QAAQ,CAAC,CAAC;QACpE,IAAI,aAAa,EAAE,CAAC;YAClB,OAAO,CAAC,GAAG,CAAC,6BAA6B,EAAE,aAAa,CAAC,CAAC;QAC5D,CAAC;QAED,MAAM,OAAO,GAAG,aAAa,CAAC,QAAQ,EAAE,MAAM,EAAE,OAAO,EAAE,cAAc,CAAC,CAAC;QACzE,OAAO,CAAC,IAAI,GAAG,YAAY,CAAC,IAAI,CAAC;QAEjC,MAAM,QAAQ,GAAG,MAAM,WAAW,CAAC,OAAO,EAAE,OAAO,EAAE,GAAG,CAAC,CAAC;QAE1D,OAAO,6BAA6B,CAAC,QAAQ,CAAC,CAAC;IACjD,CAAC,CACF,CAAC;AACJ,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nimport { createRequest, parseNotificationSendResponse, sendRequest } from \"./_client.js\";\nimport type { NonNullableRecord } from \"../../utils/utils.js\";\nimport type { Notification } from \"../../models/notification.js\";\nimport type { NotificationHubsClientContext } from \"../index.js\";\nimport type { NotificationHubsMessageResponse } from \"../../models/notificationDetails.js\";\nimport { tracingClient } from \"../../utils/tracing.js\";\nimport type { OperationOptions } from \"@azure-rest/core-client\";\n\n/**\n * Schedules a push notification to devices that match the given tags or tag expression at the specified time.\n * NOTE: This is only available in Standard SKU Azure Notification Hubs.\n * @param context - The Notification Hubs client.\n * @param scheduledTime - The Date to send the push notification.\n * @param notification - The notification to send to the matching devices.\n * @param options - Options which include tags used to target the device for push notifications in either an array or tag expression.\n * @returns A NotificationHubResponse with the tracking ID, correlation ID and location.\n */\nexport function scheduleNotificationInternal(\n context: NotificationHubsClientContext,\n scheduledTime: Date,\n notification: Notification,\n options: OperationOptions,\n method: string,\n tagExpression?: string,\n): Promise<NotificationHubsMessageResponse> {\n return tracingClient.withSpan(\n `NotificationHubsClientContext.${method}`,\n options,\n async (updatedOptions) => {\n const endpoint = context.requestUrl();\n endpoint.pathname += \"/schedulednotifications/\";\n\n const headers = await context.createHeaders(\n \"scheduleNotification\",\n notification.headers as NonNullableRecord,\n );\n headers.set(\"ServiceBusNotification-ScheduleTime\", scheduledTime.toISOString());\n headers.set(\"Content-Type\", notification.contentType);\n headers.set(\"ServiceBusNotification-Format\", notification.platform);\n if (tagExpression) {\n headers.set(\"ServiceBusNotification-Tags\", tagExpression);\n }\n\n const request = createRequest(endpoint, \"POST\", headers, updatedOptions);\n request.body = notification.body;\n\n const response = await sendRequest(context, request, 201);\n\n return parseNotificationSendResponse(response);\n },\n );\n}\n"]}
@@ -1,7 +1,7 @@
1
- import { BroadcastSendNotificationOptions, DirectSendNotificationOptions, SendNotificationOptions } from "../../models/options.js";
2
- import { Notification } from "../../models/notification.js";
3
- import { NotificationHubsClientContext } from "../index.js";
4
- import { NotificationHubsMessageResponse } from "../../models/notificationDetails.js";
1
+ import type { BroadcastSendNotificationOptions, DirectSendNotificationOptions, SendNotificationOptions } from "../../models/options.js";
2
+ import type { Notification } from "../../models/notification.js";
3
+ import type { NotificationHubsClientContext } from "../index.js";
4
+ import type { NotificationHubsMessageResponse } from "../../models/notificationDetails.js";
5
5
  /**
6
6
  * Sends push notifications to devices that match the given tags or tag expression.
7
7
  * @param context - The Notification Hubs client.
@@ -1 +1 @@
1
- {"version":3,"file":"_sendNotification.d.ts","sourceRoot":"","sources":["../../../../src/api/internal/_sendNotification.ts"],"names":[],"mappings":"AAGA,OAAO,EACL,gCAAgC,EAChC,6BAA6B,EAC7B,uBAAuB,EACxB,MAAM,yBAAyB,CAAC;AASjC,OAAO,EAAE,YAAY,EAAE,MAAM,8BAA8B,CAAC;AAC5D,OAAO,EAAE,6BAA6B,EAAE,MAAM,aAAa,CAAC;AAC5D,OAAO,EAAE,+BAA+B,EAAE,MAAM,qCAAqC,CAAC;AAKtF;;;;;;GAMG;AACH,wBAAgB,wBAAwB,CACtC,OAAO,EAAE,6BAA6B,EACtC,YAAY,EAAE,YAAY,EAC1B,OAAO,EACH,6BAA6B,GAC7B,uBAAuB,GACvB,gCAAgC,GACnC,OAAO,CAAC,+BAA+B,CAAC,CA8D1C"}
1
+ {"version":3,"file":"_sendNotification.d.ts","sourceRoot":"","sources":["../../../../src/api/internal/_sendNotification.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EACV,gCAAgC,EAChC,6BAA6B,EAC7B,uBAAuB,EACxB,MAAM,yBAAyB,CAAC;AASjC,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,8BAA8B,CAAC;AACjE,OAAO,KAAK,EAAE,6BAA6B,EAAE,MAAM,aAAa,CAAC;AACjE,OAAO,KAAK,EAAE,+BAA+B,EAAE,MAAM,qCAAqC,CAAC;AAK3F;;;;;;GAMG;AACH,wBAAgB,wBAAwB,CACtC,OAAO,EAAE,6BAA6B,EACtC,YAAY,EAAE,YAAY,EAC1B,OAAO,EACH,6BAA6B,GAC7B,uBAAuB,GACvB,gCAAgC,GACnC,OAAO,CAAC,+BAA+B,CAAC,CA8D1C"}
@@ -1 +1 @@
1
- {"version":3,"file":"_sendNotification.js","sourceRoot":"","sources":["../../../../src/api/internal/_sendNotification.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAOlC,OAAO,EAAE,aAAa,EAAE,6BAA6B,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AACzF,OAAO,EACL,kCAAkC,EAClC,+BAA+B,EAC/B,yBAAyB,GAC1B,MAAM,4BAA4B,CAAC;AAMpC,OAAO,EAAE,iCAAiC,EAAE,MAAM,kCAAkC,CAAC;AACrF,OAAO,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAC;AAC9C,OAAO,EAAE,aAAa,EAAE,MAAM,wBAAwB,CAAC;AAEvD;;;;;;GAMG;AACH,MAAM,UAAU,wBAAwB,CACtC,OAAsC,EACtC,YAA0B,EAC1B,OAGoC;IAEpC,OAAO,aAAa,CAAC,QAAQ,C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ions,\n DirectSendNotificationOptions,\n SendNotificationOptions,\n} from \"../../models/options.js\";\nimport { createRequest, parseNotificationSendResponse, sendRequest } from \"./_client.js\";\nimport {\n isBroadcastSendNotificationOptions,\n isDirectSendNotificationOptions,\n isSendNotificationOptions,\n} from \"../../utils/optionUtils.js\";\nimport { BrowserPushChannel } from \"../../models/installation.js\";\nimport { NonNullableRecord } from \"../../utils/utils.js\";\nimport { Notification } from \"../../models/notification.js\";\nimport { NotificationHubsClientContext } from \"../index.js\";\nimport { NotificationHubsMessageResponse } from \"../../models/notificationDetails.js\";\nimport { createMultipartDirectNotification } from \"../../utils/notificationUtils.js\";\nimport { randomUUID } from \"@azure/core-util\";\nimport { tracingClient } from \"../../utils/tracing.js\";\n\n/**\n * Sends push notifications to devices that match the given tags or tag expression.\n * @param context - The Notification Hubs client.\n * @param notification - The notification to send to the matching devices.\n * @param options - Options for the notification including tags, device handles and whether to enable test send.\n * @returns A NotificationHubResponse with the tracking ID, correlation ID and location.\n */\nexport function sendNotificationInternal(\n context: NotificationHubsClientContext,\n notification: Notification,\n options:\n | DirectSendNotificationOptions\n | SendNotificationOptions\n | BroadcastSendNotificationOptions,\n): Promise<NotificationHubsMessageResponse> {\n return tracingClient.withSpan(\n `NotificationHubsClientContext.sendNotification`,\n options,\n async (updatedOptions) => {\n const endpoint = context.requestUrl();\n endpoint.pathname += \"/messages/\";\n\n // Check if batch direct send\n if (isDirectSendNotificationOptions(options) && Array.isArray(options.deviceHandle)) {\n endpoint.pathname += \"$batch\";\n }\n\n // Check for test send\n if (\n (isSendNotificationOptions(options) || isBroadcastSendNotificationOptions(options)) &&\n options.enableTestSend\n ) {\n endpoint.searchParams.append(\"test\", \"true\");\n }\n\n const headers = await context.createHeaders(\n \"sendNotification\",\n notification.headers as NonNullableRecord,\n );\n headers.set(\"ServiceBusNotification-Format\", notification.platform);\n\n let body = notification.body;\n let contentType: string = notification.contentType;\n\n // Check for direct batch send\n if (isDirectSendNotificationOptions(options) && Array.isArray(options.deviceHandle)) {\n endpoint.searchParams.append(\"direct\", \"true\");\n const boundary = `nh-boundary-${randomUUID()}`;\n contentType = `multipart/mixed; boundary = \"${boundary}\"`;\n body = createMultipartDirectNotification(boundary, notification, options.deviceHandle);\n } else if (isDirectSendNotificationOptions(options)) {\n endpoint.searchParams.append(\"direct\", \"true\");\n\n if (notification.platform === \"browser\") {\n const browserHandle = options.deviceHandle as BrowserPushChannel;\n headers.set(\"ServiceBusNotification-DeviceHandle\", browserHandle.endpoint);\n headers.set(\"Auth\", browserHandle.auth);\n headers.set(\"P256DH\", browserHandle.p256dh);\n } else {\n headers.set(\"ServiceBusNotification-DeviceHandle\", options.deviceHandle as string);\n }\n } else if (isSendNotificationOptions(options)) {\n headers.set(\"ServiceBusNotification-Tags\", options.tagExpression);\n }\n\n headers.set(\"Content-Type\", contentType);\n headers.set(\"ServiceBusNotification-Format\", notification.platform);\n\n const request = createRequest(endpoint, \"POST\", headers, updatedOptions);\n request.body = body;\n\n const response = await sendRequest(context, request, 201);\n\n return parseNotificationSendResponse(response);\n },\n );\n}\n"]}
1
+ {"version":3,"file":"_sendNotification.js","sourceRoot":"","sources":["../../../../src/api/internal/_sendNotification.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAOlC,OAAO,EAAE,aAAa,EAAE,6BAA6B,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AACzF,OAAO,EACL,kCAAkC,EAClC,+BAA+B,EAC/B,yBAAyB,GAC1B,MAAM,4BAA4B,CAAC;AAMpC,OAAO,EAAE,iCAAiC,EAAE,MAAM,kCAAkC,CAAC;AACrF,OAAO,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAC;AAC9C,OAAO,EAAE,aAAa,EAAE,MAAM,wBAAwB,CAAC;AAEvD;;;;;;GAMG;AACH,MAAM,UAAU,wBAAwB,CACtC,OAAsC,EACtC,YAA0B,EAC1B,OAGoC;IAEpC,OAAO,aAAa,CAAC,QAAQ,CAC3B,gDAAgD,EACh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ptions,\n SendNotificationOptions,\n} from \"../../models/options.js\";\nimport { createRequest, parseNotificationSendResponse, sendRequest } from \"./_client.js\";\nimport {\n isBroadcastSendNotificationOptions,\n isDirectSendNotificationOptions,\n isSendNotificationOptions,\n} from \"../../utils/optionUtils.js\";\nimport type { BrowserPushChannel } from \"../../models/installation.js\";\nimport type { NonNullableRecord } from \"../../utils/utils.js\";\nimport type { Notification } from \"../../models/notification.js\";\nimport type { NotificationHubsClientContext } from \"../index.js\";\nimport type { NotificationHubsMessageResponse } from \"../../models/notificationDetails.js\";\nimport { createMultipartDirectNotification } from \"../../utils/notificationUtils.js\";\nimport { randomUUID } from \"@azure/core-util\";\nimport { tracingClient } from \"../../utils/tracing.js\";\n\n/**\n * Sends push notifications to devices that match the given tags or tag expression.\n * @param context - The Notification Hubs client.\n * @param notification - The notification to send to the matching devices.\n * @param options - Options for the notification including tags, device handles and whether to enable test send.\n * @returns A NotificationHubResponse with the tracking ID, correlation ID and location.\n */\nexport function sendNotificationInternal(\n context: NotificationHubsClientContext,\n notification: Notification,\n options:\n | DirectSendNotificationOptions\n | SendNotificationOptions\n | BroadcastSendNotificationOptions,\n): Promise<NotificationHubsMessageResponse> {\n return tracingClient.withSpan(\n `NotificationHubsClientContext.sendNotification`,\n options,\n async (updatedOptions) => {\n const endpoint = context.requestUrl();\n endpoint.pathname += \"/messages/\";\n\n // Check if batch direct send\n if (isDirectSendNotificationOptions(options) && Array.isArray(options.deviceHandle)) {\n endpoint.pathname += \"$batch\";\n }\n\n // Check for test send\n if (\n (isSendNotificationOptions(options) || isBroadcastSendNotificationOptions(options)) &&\n options.enableTestSend\n ) {\n endpoint.searchParams.append(\"test\", \"true\");\n }\n\n const headers = await context.createHeaders(\n \"sendNotification\",\n notification.headers as NonNullableRecord,\n );\n headers.set(\"ServiceBusNotification-Format\", notification.platform);\n\n let body = notification.body;\n let contentType: string = notification.contentType;\n\n // Check for direct batch send\n if (isDirectSendNotificationOptions(options) && Array.isArray(options.deviceHandle)) {\n endpoint.searchParams.append(\"direct\", \"true\");\n const boundary = `nh-boundary-${randomUUID()}`;\n contentType = `multipart/mixed; boundary = \"${boundary}\"`;\n body = createMultipartDirectNotification(boundary, notification, options.deviceHandle);\n } else if (isDirectSendNotificationOptions(options)) {\n endpoint.searchParams.append(\"direct\", \"true\");\n\n if (notification.platform === \"browser\") {\n const browserHandle = options.deviceHandle as BrowserPushChannel;\n headers.set(\"ServiceBusNotification-DeviceHandle\", browserHandle.endpoint);\n headers.set(\"Auth\", browserHandle.auth);\n headers.set(\"P256DH\", browserHandle.p256dh);\n } else {\n headers.set(\"ServiceBusNotification-DeviceHandle\", options.deviceHandle as string);\n }\n } else if (isSendNotificationOptions(options)) {\n headers.set(\"ServiceBusNotification-Tags\", options.tagExpression);\n }\n\n headers.set(\"Content-Type\", contentType);\n headers.set(\"ServiceBusNotification-Format\", notification.platform);\n\n const request = createRequest(endpoint, \"POST\", headers, updatedOptions);\n request.body = body;\n\n const response = await sendRequest(context, request, 201);\n\n return parseNotificationSendResponse(response);\n },\n );\n}\n"]}
@@ -1,6 +1,6 @@
1
- import { NotificationHubJob } from "../models/notificationHubJob.js";
2
- import { NotificationHubsClientContext } from "./index.js";
3
- import { OperationOptions } from "@azure-rest/core-client";
1
+ import type { NotificationHubJob } from "../models/notificationHubJob.js";
2
+ import type { NotificationHubsClientContext } from "./index.js";
3
+ import type { OperationOptions } from "@azure-rest/core-client";
4
4
  /**
5
5
  * Gets all Notification Hub Jobs for this Notification Hub.
6
6
  * @param context - The Notification Hubs client.xs
@@ -1 +1 @@
1
- {"version":3,"file":"listNotificationHubJobs.d.ts","sourceRoot":"","sources":["../../../src/api/listNotificationHubJobs.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,kBAAkB,EAAE,MAAM,iCAAiC,CAAC;AACrE,OAAO,EAAE,6BAA6B,EAAE,MAAM,YAAY,CAAC;AAC3D,OAAO,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAM3D;;;;;GAKG;AACH,wBAAgB,uBAAuB,CACrC,OAAO,EAAE,6BAA6B,EACtC,OAAO,GAAE,gBAAqB,GAC7B,OAAO,CAAC,kBAAkB,EAAE,CAAC,CAiB/B"}
1
+ {"version":3,"file":"listNotificationHubJobs.d.ts","sourceRoot":"","sources":["../../../src/api/listNotificationHubJobs.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,iCAAiC,CAAC;AAC1E,OAAO,KAAK,EAAE,6BAA6B,EAAE,MAAM,YAAY,CAAC;AAChE,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAMhE;;;;;GAKG;AACH,wBAAgB,uBAAuB,CACrC,OAAO,EAAE,6BAA6B,EACtC,OAAO,GAAE,gBAAqB,GAC7B,OAAO,CAAC,kBAAkB,EAAE,CAAC,CAiB/B"}