@azure/arm-eventgrid 12.0.0 → 13.0.0

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 (287) hide show
  1. package/CHANGELOG.md +11 -0
  2. package/{LICENSE.txt → LICENSE} +1 -1
  3. package/README.md +70 -82
  4. package/dist/index.js +7613 -0
  5. package/dist/index.js.map +1 -0
  6. package/dist/index.min.js +1 -0
  7. package/dist/index.min.js.map +1 -0
  8. package/dist-esm/src/eventGridManagementClient.d.ts +29 -0
  9. package/dist-esm/src/eventGridManagementClient.d.ts.map +1 -0
  10. package/dist-esm/src/eventGridManagementClient.js +62 -0
  11. package/dist-esm/src/eventGridManagementClient.js.map +1 -0
  12. package/dist-esm/src/index.d.ts +5 -0
  13. package/dist-esm/src/index.d.ts.map +1 -0
  14. package/dist-esm/src/index.js +12 -0
  15. package/dist-esm/src/index.js.map +1 -0
  16. package/dist-esm/src/lroImpl.d.ts +16 -0
  17. package/dist-esm/src/lroImpl.d.ts.map +1 -0
  18. package/dist-esm/src/lroImpl.js +29 -0
  19. package/dist-esm/src/lroImpl.js.map +1 -0
  20. package/dist-esm/src/models/index.d.ts +1943 -0
  21. package/dist-esm/src/models/index.d.ts.map +1 -0
  22. package/dist-esm/src/models/index.js +204 -0
  23. package/dist-esm/src/models/index.js.map +1 -0
  24. package/dist-esm/src/models/mappers.d.ts +107 -0
  25. package/dist-esm/src/models/mappers.d.ts.map +1 -0
  26. package/{esm → dist-esm/src}/models/mappers.js +1216 -1303
  27. package/dist-esm/src/models/mappers.js.map +1 -0
  28. package/dist-esm/src/models/parameters.d.ts +42 -0
  29. package/dist-esm/src/models/parameters.d.ts.map +1 -0
  30. package/dist-esm/src/models/parameters.js +347 -0
  31. package/dist-esm/src/models/parameters.js.map +1 -0
  32. package/dist-esm/src/operations/domainTopics.d.ts +79 -0
  33. package/dist-esm/src/operations/domainTopics.d.ts.map +1 -0
  34. package/dist-esm/src/operations/domainTopics.js +310 -0
  35. package/dist-esm/src/operations/domainTopics.js.map +1 -0
  36. package/dist-esm/src/operations/domains.d.ts +122 -0
  37. package/dist-esm/src/operations/domains.d.ts.map +1 -0
  38. package/dist-esm/src/operations/domains.js +522 -0
  39. package/dist-esm/src/operations/domains.js.map +1 -0
  40. package/dist-esm/src/operations/eventSubscriptions.d.ts +404 -0
  41. package/dist-esm/src/operations/eventSubscriptions.d.ts.map +1 -0
  42. package/dist-esm/src/operations/eventSubscriptions.js +1504 -0
  43. package/dist-esm/src/operations/eventSubscriptions.js.map +1 -0
  44. package/dist-esm/src/operations/extensionTopics.d.ts +24 -0
  45. package/dist-esm/src/operations/extensionTopics.d.ts.map +1 -0
  46. package/dist-esm/src/operations/extensionTopics.js +50 -0
  47. package/dist-esm/src/operations/extensionTopics.js.map +1 -0
  48. package/{esm → dist-esm/src}/operations/index.d.ts +0 -0
  49. package/dist-esm/src/operations/index.d.ts.map +1 -0
  50. package/{esm → dist-esm/src}/operations/index.js +1 -2
  51. package/dist-esm/src/operations/index.js.map +1 -0
  52. package/dist-esm/src/operations/operations.d.ts +26 -0
  53. package/dist-esm/src/operations/operations.d.ts.map +1 -0
  54. package/dist-esm/src/operations/operations.js +88 -0
  55. package/dist-esm/src/operations/operations.js.map +1 -0
  56. package/dist-esm/src/operations/privateEndpointConnections.d.ts +89 -0
  57. package/dist-esm/src/operations/privateEndpointConnections.d.ts.map +1 -0
  58. package/dist-esm/src/operations/privateEndpointConnections.js +346 -0
  59. package/dist-esm/src/operations/privateEndpointConnections.js.map +1 -0
  60. package/dist-esm/src/operations/privateLinkResources.d.ts +50 -0
  61. package/dist-esm/src/operations/privateLinkResources.d.ts.map +1 -0
  62. package/dist-esm/src/operations/privateLinkResources.js +176 -0
  63. package/dist-esm/src/operations/privateLinkResources.js.map +1 -0
  64. package/dist-esm/src/operations/systemTopicEventSubscriptions.d.ts +128 -0
  65. package/dist-esm/src/operations/systemTopicEventSubscriptions.d.ts.map +1 -0
  66. package/dist-esm/src/operations/systemTopicEventSubscriptions.js +483 -0
  67. package/dist-esm/src/operations/systemTopicEventSubscriptions.js.map +1 -0
  68. package/dist-esm/src/operations/systemTopics.d.ts +107 -0
  69. package/dist-esm/src/operations/systemTopics.d.ts.map +1 -0
  70. package/dist-esm/src/operations/systemTopics.js +482 -0
  71. package/dist-esm/src/operations/systemTopics.js.map +1 -0
  72. package/dist-esm/src/operations/topicTypes.d.ts +46 -0
  73. package/dist-esm/src/operations/topicTypes.d.ts.map +1 -0
  74. package/dist-esm/src/operations/topicTypes.js +175 -0
  75. package/dist-esm/src/operations/topicTypes.js.map +1 -0
  76. package/dist-esm/src/operations/topics.d.ts +150 -0
  77. package/dist-esm/src/operations/topics.d.ts.map +1 -0
  78. package/dist-esm/src/operations/topics.js +656 -0
  79. package/dist-esm/src/operations/topics.js.map +1 -0
  80. package/dist-esm/src/operationsInterfaces/domainTopics.d.ts +54 -0
  81. package/dist-esm/src/operationsInterfaces/domainTopics.d.ts.map +1 -0
  82. package/{src/models/operationsMappers.ts → dist-esm/src/operationsInterfaces/domainTopics.js} +2 -8
  83. package/dist-esm/src/operationsInterfaces/domainTopics.js.map +1 -0
  84. package/dist-esm/src/operationsInterfaces/domains.d.ts +86 -0
  85. package/dist-esm/src/operationsInterfaces/domains.d.ts.map +1 -0
  86. package/{src/models/privateLinkResourcesMappers.ts → dist-esm/src/operationsInterfaces/domains.js} +2 -7
  87. package/dist-esm/src/operationsInterfaces/domains.js.map +1 -0
  88. package/dist-esm/src/operationsInterfaces/eventSubscriptions.d.ts +217 -0
  89. package/dist-esm/src/operationsInterfaces/eventSubscriptions.d.ts.map +1 -0
  90. package/{esm/models/operationsMappers.js → dist-esm/src/operationsInterfaces/eventSubscriptions.js} +2 -2
  91. package/dist-esm/src/operationsInterfaces/eventSubscriptions.js.map +1 -0
  92. package/dist-esm/src/operationsInterfaces/extensionTopics.d.ts +16 -0
  93. package/dist-esm/src/operationsInterfaces/extensionTopics.d.ts.map +1 -0
  94. package/dist-esm/src/operationsInterfaces/extensionTopics.js +9 -0
  95. package/dist-esm/src/operationsInterfaces/extensionTopics.js.map +1 -0
  96. package/dist-esm/src/operationsInterfaces/index.d.ts +12 -0
  97. package/dist-esm/src/operationsInterfaces/index.d.ts.map +1 -0
  98. package/dist-esm/src/operationsInterfaces/index.js +19 -0
  99. package/dist-esm/src/operationsInterfaces/index.js.map +1 -0
  100. package/dist-esm/src/operationsInterfaces/operations.d.ts +11 -0
  101. package/dist-esm/src/operationsInterfaces/operations.d.ts.map +1 -0
  102. package/dist-esm/src/operationsInterfaces/operations.js +9 -0
  103. package/dist-esm/src/operationsInterfaces/operations.js.map +1 -0
  104. package/dist-esm/src/operationsInterfaces/privateEndpointConnections.d.ts +62 -0
  105. package/dist-esm/src/operationsInterfaces/privateEndpointConnections.d.ts.map +1 -0
  106. package/dist-esm/src/operationsInterfaces/privateEndpointConnections.js +9 -0
  107. package/dist-esm/src/operationsInterfaces/privateEndpointConnections.js.map +1 -0
  108. package/dist-esm/src/operationsInterfaces/privateLinkResources.d.ts +23 -0
  109. package/dist-esm/src/operationsInterfaces/privateLinkResources.d.ts.map +1 -0
  110. package/dist-esm/src/operationsInterfaces/privateLinkResources.js +9 -0
  111. package/dist-esm/src/operationsInterfaces/privateLinkResources.js.map +1 -0
  112. package/dist-esm/src/operationsInterfaces/systemTopicEventSubscriptions.d.ts +103 -0
  113. package/dist-esm/src/operationsInterfaces/systemTopicEventSubscriptions.d.ts.map +1 -0
  114. package/dist-esm/src/operationsInterfaces/systemTopicEventSubscriptions.js +9 -0
  115. package/dist-esm/src/operationsInterfaces/systemTopicEventSubscriptions.js.map +1 -0
  116. package/dist-esm/src/operationsInterfaces/systemTopics.d.ts +71 -0
  117. package/dist-esm/src/operationsInterfaces/systemTopics.d.ts.map +1 -0
  118. package/dist-esm/src/operationsInterfaces/systemTopics.js +9 -0
  119. package/dist-esm/src/operationsInterfaces/systemTopics.js.map +1 -0
  120. package/dist-esm/src/operationsInterfaces/topicTypes.d.ts +23 -0
  121. package/dist-esm/src/operationsInterfaces/topicTypes.d.ts.map +1 -0
  122. package/dist-esm/src/operationsInterfaces/topicTypes.js +9 -0
  123. package/dist-esm/src/operationsInterfaces/topicTypes.js.map +1 -0
  124. package/dist-esm/src/operationsInterfaces/topics.d.ts +103 -0
  125. package/dist-esm/src/operationsInterfaces/topics.d.ts.map +1 -0
  126. package/{esm/models/index.js → dist-esm/src/operationsInterfaces/topics.js} +2 -1
  127. package/dist-esm/src/operationsInterfaces/topics.js.map +1 -0
  128. package/dist-esm/test/eventgrid_examples.d.ts +4 -0
  129. package/dist-esm/test/eventgrid_examples.d.ts.map +1 -0
  130. package/dist-esm/test/eventgrid_examples.js +166 -0
  131. package/dist-esm/test/eventgrid_examples.js.map +1 -0
  132. package/package.json +65 -32
  133. package/review/arm-eventgrid.api.md +1777 -0
  134. package/rollup.config.js +181 -30
  135. package/src/eventGridManagementClient.ts +107 -53
  136. package/{esm/models/privateLinkResourcesMappers.js → src/index.ts} +5 -2
  137. package/src/lroImpl.ts +34 -0
  138. package/src/models/index.ts +1844 -3910
  139. package/src/models/mappers.ts +1261 -1339
  140. package/src/models/parameters.ts +239 -82
  141. package/src/operations/domainTopics.ts +346 -224
  142. package/src/operations/domains.ts +545 -454
  143. package/src/operations/eventSubscriptions.ts +1658 -1236
  144. package/src/operations/extensionTopics.ts +37 -66
  145. package/src/operations/index.ts +1 -2
  146. package/src/operations/operations.ts +65 -43
  147. package/src/operations/privateEndpointConnections.ts +386 -253
  148. package/src/operations/privateLinkResources.ts +178 -150
  149. package/src/operations/systemTopicEventSubscriptions.ts +537 -394
  150. package/src/operations/systemTopics.ts +505 -349
  151. package/src/operations/topicTypes.ts +138 -114
  152. package/src/operations/topics.ts +728 -494
  153. package/src/operationsInterfaces/domainTopics.ts +105 -0
  154. package/src/operationsInterfaces/domains.ts +162 -0
  155. package/src/operationsInterfaces/eventSubscriptions.ts +339 -0
  156. package/src/operationsInterfaces/extensionTopics.ts +30 -0
  157. package/src/operationsInterfaces/index.ts +19 -0
  158. package/src/operationsInterfaces/operations.ts +22 -0
  159. package/src/operationsInterfaces/privateEndpointConnections.ts +125 -0
  160. package/src/operationsInterfaces/privateLinkResources.ts +48 -0
  161. package/src/operationsInterfaces/systemTopicEventSubscriptions.ts +190 -0
  162. package/src/operationsInterfaces/systemTopics.ts +139 -0
  163. package/src/operationsInterfaces/topicTypes.ts +47 -0
  164. package/src/operationsInterfaces/topics.ts +197 -0
  165. package/tsconfig.json +3 -3
  166. package/types/arm-eventgrid.d.ts +2998 -0
  167. package/types/tsdoc-metadata.json +11 -0
  168. package/dist/arm-eventgrid.js +0 -6824
  169. package/dist/arm-eventgrid.js.map +0 -1
  170. package/dist/arm-eventgrid.min.js +0 -1
  171. package/dist/arm-eventgrid.min.js.map +0 -1
  172. package/esm/eventGridManagementClient.d.ts +0 -35
  173. package/esm/eventGridManagementClient.d.ts.map +0 -1
  174. package/esm/eventGridManagementClient.js +0 -48
  175. package/esm/eventGridManagementClient.js.map +0 -1
  176. package/esm/eventGridManagementClientContext.d.ts +0 -23
  177. package/esm/eventGridManagementClientContext.d.ts.map +0 -1
  178. package/esm/eventGridManagementClientContext.js +0 -61
  179. package/esm/eventGridManagementClientContext.js.map +0 -1
  180. package/esm/models/domainTopicsMappers.d.ts +0 -2
  181. package/esm/models/domainTopicsMappers.d.ts.map +0 -1
  182. package/esm/models/domainTopicsMappers.js +0 -9
  183. package/esm/models/domainTopicsMappers.js.map +0 -1
  184. package/esm/models/domainsMappers.d.ts +0 -2
  185. package/esm/models/domainsMappers.d.ts.map +0 -1
  186. package/esm/models/domainsMappers.js +0 -9
  187. package/esm/models/domainsMappers.js.map +0 -1
  188. package/esm/models/eventSubscriptionsMappers.d.ts +0 -2
  189. package/esm/models/eventSubscriptionsMappers.d.ts.map +0 -1
  190. package/esm/models/eventSubscriptionsMappers.js +0 -9
  191. package/esm/models/eventSubscriptionsMappers.js.map +0 -1
  192. package/esm/models/extensionTopicsMappers.d.ts +0 -2
  193. package/esm/models/extensionTopicsMappers.d.ts.map +0 -1
  194. package/esm/models/extensionTopicsMappers.js +0 -9
  195. package/esm/models/extensionTopicsMappers.js.map +0 -1
  196. package/esm/models/index.d.ts +0 -4080
  197. package/esm/models/index.d.ts.map +0 -1
  198. package/esm/models/index.js.map +0 -1
  199. package/esm/models/mappers.d.ts +0 -109
  200. package/esm/models/mappers.d.ts.map +0 -1
  201. package/esm/models/mappers.js.map +0 -1
  202. package/esm/models/operationsMappers.d.ts +0 -2
  203. package/esm/models/operationsMappers.d.ts.map +0 -1
  204. package/esm/models/operationsMappers.js.map +0 -1
  205. package/esm/models/parameters.d.ts +0 -25
  206. package/esm/models/parameters.d.ts.map +0 -1
  207. package/esm/models/parameters.js +0 -245
  208. package/esm/models/parameters.js.map +0 -1
  209. package/esm/models/privateEndpointConnectionsMappers.d.ts +0 -2
  210. package/esm/models/privateEndpointConnectionsMappers.d.ts.map +0 -1
  211. package/esm/models/privateEndpointConnectionsMappers.js +0 -9
  212. package/esm/models/privateEndpointConnectionsMappers.js.map +0 -1
  213. package/esm/models/privateLinkResourcesMappers.d.ts +0 -2
  214. package/esm/models/privateLinkResourcesMappers.d.ts.map +0 -1
  215. package/esm/models/privateLinkResourcesMappers.js.map +0 -1
  216. package/esm/models/systemTopicEventSubscriptionsMappers.d.ts +0 -2
  217. package/esm/models/systemTopicEventSubscriptionsMappers.d.ts.map +0 -1
  218. package/esm/models/systemTopicEventSubscriptionsMappers.js +0 -9
  219. package/esm/models/systemTopicEventSubscriptionsMappers.js.map +0 -1
  220. package/esm/models/systemTopicsMappers.d.ts +0 -2
  221. package/esm/models/systemTopicsMappers.d.ts.map +0 -1
  222. package/esm/models/systemTopicsMappers.js +0 -9
  223. package/esm/models/systemTopicsMappers.js.map +0 -1
  224. package/esm/models/topicTypesMappers.d.ts +0 -2
  225. package/esm/models/topicTypesMappers.d.ts.map +0 -1
  226. package/esm/models/topicTypesMappers.js +0 -9
  227. package/esm/models/topicTypesMappers.js.map +0 -1
  228. package/esm/models/topicsMappers.d.ts +0 -2
  229. package/esm/models/topicsMappers.d.ts.map +0 -1
  230. package/esm/models/topicsMappers.js +0 -9
  231. package/esm/models/topicsMappers.js.map +0 -1
  232. package/esm/operations/domainTopics.d.ts +0 -120
  233. package/esm/operations/domainTopics.d.ts.map +0 -1
  234. package/esm/operations/domainTopics.js +0 -233
  235. package/esm/operations/domainTopics.js.map +0 -1
  236. package/esm/operations/domains.d.ts +0 -214
  237. package/esm/operations/domains.d.ts.map +0 -1
  238. package/esm/operations/domains.js +0 -415
  239. package/esm/operations/domains.js.map +0 -1
  240. package/esm/operations/eventSubscriptions.d.ts +0 -666
  241. package/esm/operations/eventSubscriptions.d.ts.map +0 -1
  242. package/esm/operations/eventSubscriptions.js +0 -969
  243. package/esm/operations/eventSubscriptions.js.map +0 -1
  244. package/esm/operations/extensionTopics.d.ts +0 -47
  245. package/esm/operations/extensionTopics.d.ts.map +0 -1
  246. package/esm/operations/extensionTopics.js +0 -54
  247. package/esm/operations/extensionTopics.js.map +0 -1
  248. package/esm/operations/index.d.ts.map +0 -1
  249. package/esm/operations/index.js.map +0 -1
  250. package/esm/operations/operations.d.ts +0 -29
  251. package/esm/operations/operations.d.ts.map +0 -1
  252. package/esm/operations/operations.js +0 -50
  253. package/esm/operations/operations.js.map +0 -1
  254. package/esm/operations/privateEndpointConnections.d.ts +0 -152
  255. package/esm/operations/privateEndpointConnections.d.ts.map +0 -1
  256. package/esm/operations/privateEndpointConnections.js +0 -263
  257. package/esm/operations/privateEndpointConnections.js.map +0 -1
  258. package/esm/operations/privateLinkResources.d.ts +0 -91
  259. package/esm/operations/privateLinkResources.d.ts.map +0 -1
  260. package/esm/operations/privateLinkResources.js +0 -127
  261. package/esm/operations/privateLinkResources.js.map +0 -1
  262. package/esm/operations/systemTopicEventSubscriptions.d.ts +0 -213
  263. package/esm/operations/systemTopicEventSubscriptions.d.ts.map +0 -1
  264. package/esm/operations/systemTopicEventSubscriptions.js +0 -379
  265. package/esm/operations/systemTopicEventSubscriptions.js.map +0 -1
  266. package/esm/operations/systemTopics.d.ts +0 -167
  267. package/esm/operations/systemTopics.d.ts.map +0 -1
  268. package/esm/operations/systemTopics.js +0 -353
  269. package/esm/operations/systemTopics.js.map +0 -1
  270. package/esm/operations/topicTypes.d.ts +0 -67
  271. package/esm/operations/topicTypes.d.ts.map +0 -1
  272. package/esm/operations/topicTypes.js +0 -106
  273. package/esm/operations/topicTypes.js.map +0 -1
  274. package/esm/operations/topics.d.ts +0 -237
  275. package/esm/operations/topics.d.ts.map +0 -1
  276. package/esm/operations/topics.js +0 -471
  277. package/esm/operations/topics.js.map +0 -1
  278. package/src/eventGridManagementClientContext.ts +0 -68
  279. package/src/models/domainTopicsMappers.ts +0 -66
  280. package/src/models/domainsMappers.ts +0 -69
  281. package/src/models/eventSubscriptionsMappers.ts +0 -69
  282. package/src/models/extensionTopicsMappers.ts +0 -65
  283. package/src/models/privateEndpointConnectionsMappers.ts +0 -66
  284. package/src/models/systemTopicEventSubscriptionsMappers.ts +0 -69
  285. package/src/models/systemTopicsMappers.ts +0 -67
  286. package/src/models/topicTypesMappers.ts +0 -67
  287. package/src/models/topicsMappers.ts +0 -70
@@ -3,554 +3,697 @@
3
3
  * Licensed under the MIT License.
4
4
  *
5
5
  * Code generated by Microsoft (R) AutoRest Code Generator.
6
- * Changes may cause incorrect behavior and will be lost if the code is
7
- * regenerated.
6
+ * Changes may cause incorrect behavior and will be lost if the code is regenerated.
8
7
  */
9
8
 
10
- import * as msRest from "@azure/ms-rest-js";
11
- import * as msRestAzure from "@azure/ms-rest-azure-js";
12
- import * as Models from "../models";
13
- import * as Mappers from "../models/systemTopicEventSubscriptionsMappers";
9
+ import { PagedAsyncIterableIterator } from "@azure/core-paging";
10
+ import { SystemTopicEventSubscriptions } from "../operationsInterfaces";
11
+ import * as coreClient from "@azure/core-client";
12
+ import * as Mappers from "../models/mappers";
14
13
  import * as Parameters from "../models/parameters";
15
- import { EventGridManagementClientContext } from "../eventGridManagementClientContext";
14
+ import { EventGridManagementClient } from "../eventGridManagementClient";
15
+ import { PollerLike, PollOperationState, LroEngine } from "@azure/core-lro";
16
+ import { LroImpl } from "../lroImpl";
17
+ import {
18
+ EventSubscription,
19
+ SystemTopicEventSubscriptionsListBySystemTopicNextOptionalParams,
20
+ SystemTopicEventSubscriptionsListBySystemTopicOptionalParams,
21
+ SystemTopicEventSubscriptionsGetOptionalParams,
22
+ SystemTopicEventSubscriptionsGetResponse,
23
+ SystemTopicEventSubscriptionsCreateOrUpdateOptionalParams,
24
+ SystemTopicEventSubscriptionsCreateOrUpdateResponse,
25
+ SystemTopicEventSubscriptionsDeleteOptionalParams,
26
+ EventSubscriptionUpdateParameters,
27
+ SystemTopicEventSubscriptionsUpdateOptionalParams,
28
+ SystemTopicEventSubscriptionsUpdateResponse,
29
+ SystemTopicEventSubscriptionsGetFullUrlOptionalParams,
30
+ SystemTopicEventSubscriptionsGetFullUrlResponse,
31
+ SystemTopicEventSubscriptionsListBySystemTopicResponse,
32
+ SystemTopicEventSubscriptionsGetDeliveryAttributesOptionalParams,
33
+ SystemTopicEventSubscriptionsGetDeliveryAttributesResponse,
34
+ SystemTopicEventSubscriptionsListBySystemTopicNextResponse
35
+ } from "../models";
16
36
 
17
- /** Class representing a SystemTopicEventSubscriptions. */
18
- export class SystemTopicEventSubscriptions {
19
- private readonly client: EventGridManagementClientContext;
37
+ /// <reference lib="esnext.asynciterable" />
38
+ /** Class containing SystemTopicEventSubscriptions operations. */
39
+ export class SystemTopicEventSubscriptionsImpl
40
+ implements SystemTopicEventSubscriptions {
41
+ private readonly client: EventGridManagementClient;
20
42
 
21
43
  /**
22
- * Create a SystemTopicEventSubscriptions.
23
- * @param {EventGridManagementClientContext} client Reference to the service client.
44
+ * Initialize a new instance of the class SystemTopicEventSubscriptions class.
45
+ * @param client Reference to the service client
24
46
  */
25
- constructor(client: EventGridManagementClientContext) {
47
+ constructor(client: EventGridManagementClient) {
26
48
  this.client = client;
27
49
  }
28
50
 
29
51
  /**
30
- * Get an event subscription.
31
- * @summary Get an event subscription of a system topic.
52
+ * List event subscriptions that belong to a specific system topic.
32
53
  * @param resourceGroupName The name of the resource group within the user's subscription.
33
54
  * @param systemTopicName Name of the system topic.
34
- * @param eventSubscriptionName Name of the event subscription to be created. Event subscription
35
- * names must be between 3 and 100 characters in length and use alphanumeric letters only.
36
- * @param [options] The optional parameters
37
- * @returns Promise<Models.SystemTopicEventSubscriptionsGetResponse>
55
+ * @param options The options parameters.
38
56
  */
39
- get(resourceGroupName: string, systemTopicName: string, eventSubscriptionName: string, options?: msRest.RequestOptionsBase): Promise<Models.SystemTopicEventSubscriptionsGetResponse>;
57
+ public listBySystemTopic(
58
+ resourceGroupName: string,
59
+ systemTopicName: string,
60
+ options?: SystemTopicEventSubscriptionsListBySystemTopicOptionalParams
61
+ ): PagedAsyncIterableIterator<EventSubscription> {
62
+ const iter = this.listBySystemTopicPagingAll(
63
+ resourceGroupName,
64
+ systemTopicName,
65
+ options
66
+ );
67
+ return {
68
+ next() {
69
+ return iter.next();
70
+ },
71
+ [Symbol.asyncIterator]() {
72
+ return this;
73
+ },
74
+ byPage: () => {
75
+ return this.listBySystemTopicPagingPage(
76
+ resourceGroupName,
77
+ systemTopicName,
78
+ options
79
+ );
80
+ }
81
+ };
82
+ }
83
+
84
+ private async *listBySystemTopicPagingPage(
85
+ resourceGroupName: string,
86
+ systemTopicName: string,
87
+ options?: SystemTopicEventSubscriptionsListBySystemTopicOptionalParams
88
+ ): AsyncIterableIterator<EventSubscription[]> {
89
+ let result = await this._listBySystemTopic(
90
+ resourceGroupName,
91
+ systemTopicName,
92
+ options
93
+ );
94
+ yield result.value || [];
95
+ let continuationToken = result.nextLink;
96
+ while (continuationToken) {
97
+ result = await this._listBySystemTopicNext(
98
+ resourceGroupName,
99
+ systemTopicName,
100
+ continuationToken,
101
+ options
102
+ );
103
+ continuationToken = result.nextLink;
104
+ yield result.value || [];
105
+ }
106
+ }
107
+
108
+ private async *listBySystemTopicPagingAll(
109
+ resourceGroupName: string,
110
+ systemTopicName: string,
111
+ options?: SystemTopicEventSubscriptionsListBySystemTopicOptionalParams
112
+ ): AsyncIterableIterator<EventSubscription> {
113
+ for await (const page of this.listBySystemTopicPagingPage(
114
+ resourceGroupName,
115
+ systemTopicName,
116
+ options
117
+ )) {
118
+ yield* page;
119
+ }
120
+ }
121
+
40
122
  /**
123
+ * Get an event subscription.
41
124
  * @param resourceGroupName The name of the resource group within the user's subscription.
42
125
  * @param systemTopicName Name of the system topic.
43
- * @param eventSubscriptionName Name of the event subscription to be created. Event subscription
44
- * names must be between 3 and 100 characters in length and use alphanumeric letters only.
45
- * @param callback The callback
126
+ * @param eventSubscriptionName Name of the event subscription to be created. Event subscription names
127
+ * must be between 3 and 100 characters in length and use alphanumeric letters only.
128
+ * @param options The options parameters.
46
129
  */
47
- get(resourceGroupName: string, systemTopicName: string, eventSubscriptionName: string, callback: msRest.ServiceCallback<Models.EventSubscription>): void;
130
+ get(
131
+ resourceGroupName: string,
132
+ systemTopicName: string,
133
+ eventSubscriptionName: string,
134
+ options?: SystemTopicEventSubscriptionsGetOptionalParams
135
+ ): Promise<SystemTopicEventSubscriptionsGetResponse> {
136
+ return this.client.sendOperationRequest(
137
+ { resourceGroupName, systemTopicName, eventSubscriptionName, options },
138
+ getOperationSpec
139
+ );
140
+ }
141
+
48
142
  /**
143
+ * Asynchronously creates or updates an event subscription with the specified parameters. Existing
144
+ * event subscriptions will be updated with this API.
49
145
  * @param resourceGroupName The name of the resource group within the user's subscription.
50
146
  * @param systemTopicName Name of the system topic.
51
- * @param eventSubscriptionName Name of the event subscription to be created. Event subscription
52
- * names must be between 3 and 100 characters in length and use alphanumeric letters only.
53
- * @param options The optional parameters
54
- * @param callback The callback
147
+ * @param eventSubscriptionName Name of the event subscription to be created. Event subscription names
148
+ * must be between 3 and 100 characters in length and use alphanumeric letters only.
149
+ * @param eventSubscriptionInfo Event subscription properties containing the destination and filter
150
+ * information.
151
+ * @param options The options parameters.
55
152
  */
56
- get(resourceGroupName: string, systemTopicName: string, eventSubscriptionName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback<Models.EventSubscription>): void;
57
- get(resourceGroupName: string, systemTopicName: string, eventSubscriptionName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback<Models.EventSubscription>, callback?: msRest.ServiceCallback<Models.EventSubscription>): Promise<Models.SystemTopicEventSubscriptionsGetResponse> {
58
- return this.client.sendOperationRequest(
153
+ async beginCreateOrUpdate(
154
+ resourceGroupName: string,
155
+ systemTopicName: string,
156
+ eventSubscriptionName: string,
157
+ eventSubscriptionInfo: EventSubscription,
158
+ options?: SystemTopicEventSubscriptionsCreateOrUpdateOptionalParams
159
+ ): Promise<
160
+ PollerLike<
161
+ PollOperationState<SystemTopicEventSubscriptionsCreateOrUpdateResponse>,
162
+ SystemTopicEventSubscriptionsCreateOrUpdateResponse
163
+ >
164
+ > {
165
+ const directSendOperation = async (
166
+ args: coreClient.OperationArguments,
167
+ spec: coreClient.OperationSpec
168
+ ): Promise<SystemTopicEventSubscriptionsCreateOrUpdateResponse> => {
169
+ return this.client.sendOperationRequest(args, spec);
170
+ };
171
+ const sendOperation = async (
172
+ args: coreClient.OperationArguments,
173
+ spec: coreClient.OperationSpec
174
+ ) => {
175
+ let currentRawResponse:
176
+ | coreClient.FullOperationResponse
177
+ | undefined = undefined;
178
+ const providedCallback = args.options?.onResponse;
179
+ const callback: coreClient.RawResponseCallback = (
180
+ rawResponse: coreClient.FullOperationResponse,
181
+ flatResponse: unknown
182
+ ) => {
183
+ currentRawResponse = rawResponse;
184
+ providedCallback?.(rawResponse, flatResponse);
185
+ };
186
+ const updatedArgs = {
187
+ ...args,
188
+ options: {
189
+ ...args.options,
190
+ onResponse: callback
191
+ }
192
+ };
193
+ const flatResponse = await directSendOperation(updatedArgs, spec);
194
+ return {
195
+ flatResponse,
196
+ rawResponse: {
197
+ statusCode: currentRawResponse!.status,
198
+ body: currentRawResponse!.parsedBody,
199
+ headers: currentRawResponse!.headers.toJSON()
200
+ }
201
+ };
202
+ };
203
+
204
+ const lro = new LroImpl(
205
+ sendOperation,
59
206
  {
60
207
  resourceGroupName,
61
208
  systemTopicName,
62
209
  eventSubscriptionName,
210
+ eventSubscriptionInfo,
63
211
  options
64
212
  },
65
- getOperationSpec,
66
- callback) as Promise<Models.SystemTopicEventSubscriptionsGetResponse>;
213
+ createOrUpdateOperationSpec
214
+ );
215
+ return new LroEngine(lro, {
216
+ resumeFrom: options?.resumeFrom,
217
+ intervalInMs: options?.updateIntervalInMs
218
+ });
67
219
  }
68
220
 
69
221
  /**
70
222
  * Asynchronously creates or updates an event subscription with the specified parameters. Existing
71
223
  * event subscriptions will be updated with this API.
72
- * @summary Create or update an event subscription for a system topic.
73
224
  * @param resourceGroupName The name of the resource group within the user's subscription.
74
225
  * @param systemTopicName Name of the system topic.
75
- * @param eventSubscriptionName Name of the event subscription to be created. Event subscription
76
- * names must be between 3 and 100 characters in length and use alphanumeric letters only.
226
+ * @param eventSubscriptionName Name of the event subscription to be created. Event subscription names
227
+ * must be between 3 and 100 characters in length and use alphanumeric letters only.
77
228
  * @param eventSubscriptionInfo Event subscription properties containing the destination and filter
78
- * information.
79
- * @param [options] The optional parameters
80
- * @returns Promise<Models.SystemTopicEventSubscriptionsCreateOrUpdateResponse>
229
+ * information.
230
+ * @param options The options parameters.
81
231
  */
82
- createOrUpdate(resourceGroupName: string, systemTopicName: string, eventSubscriptionName: string, eventSubscriptionInfo: Models.EventSubscription, options?: msRest.RequestOptionsBase): Promise<Models.SystemTopicEventSubscriptionsCreateOrUpdateResponse> {
83
- return this.beginCreateOrUpdate(resourceGroupName,systemTopicName,eventSubscriptionName,eventSubscriptionInfo,options)
84
- .then(lroPoller => lroPoller.pollUntilFinished()) as Promise<Models.SystemTopicEventSubscriptionsCreateOrUpdateResponse>;
232
+ async beginCreateOrUpdateAndWait(
233
+ resourceGroupName: string,
234
+ systemTopicName: string,
235
+ eventSubscriptionName: string,
236
+ eventSubscriptionInfo: EventSubscription,
237
+ options?: SystemTopicEventSubscriptionsCreateOrUpdateOptionalParams
238
+ ): Promise<SystemTopicEventSubscriptionsCreateOrUpdateResponse> {
239
+ const poller = await this.beginCreateOrUpdate(
240
+ resourceGroupName,
241
+ systemTopicName,
242
+ eventSubscriptionName,
243
+ eventSubscriptionInfo,
244
+ options
245
+ );
246
+ return poller.pollUntilDone();
85
247
  }
86
248
 
87
249
  /**
88
250
  * Delete an event subscription of a system topic.
89
- * @summary Delete an event subscription of a system topic.
90
251
  * @param resourceGroupName The name of the resource group within the user's subscription.
91
252
  * @param systemTopicName Name of the system topic.
92
- * @param eventSubscriptionName Name of the event subscription to be created. Event subscription
93
- * names must be between 3 and 100 characters in length and use alphanumeric letters only.
94
- * @param [options] The optional parameters
95
- * @returns Promise<msRest.RestResponse>
253
+ * @param eventSubscriptionName Name of the event subscription to be created. Event subscription names
254
+ * must be between 3 and 100 characters in length and use alphanumeric letters only.
255
+ * @param options The options parameters.
96
256
  */
97
- deleteMethod(resourceGroupName: string, systemTopicName: string, eventSubscriptionName: string, options?: msRest.RequestOptionsBase): Promise<msRest.RestResponse> {
98
- return this.beginDeleteMethod(resourceGroupName,systemTopicName,eventSubscriptionName,options)
99
- .then(lroPoller => lroPoller.pollUntilFinished());
257
+ async beginDelete(
258
+ resourceGroupName: string,
259
+ systemTopicName: string,
260
+ eventSubscriptionName: string,
261
+ options?: SystemTopicEventSubscriptionsDeleteOptionalParams
262
+ ): Promise<PollerLike<PollOperationState<void>, void>> {
263
+ const directSendOperation = async (
264
+ args: coreClient.OperationArguments,
265
+ spec: coreClient.OperationSpec
266
+ ): Promise<void> => {
267
+ return this.client.sendOperationRequest(args, spec);
268
+ };
269
+ const sendOperation = async (
270
+ args: coreClient.OperationArguments,
271
+ spec: coreClient.OperationSpec
272
+ ) => {
273
+ let currentRawResponse:
274
+ | coreClient.FullOperationResponse
275
+ | undefined = undefined;
276
+ const providedCallback = args.options?.onResponse;
277
+ const callback: coreClient.RawResponseCallback = (
278
+ rawResponse: coreClient.FullOperationResponse,
279
+ flatResponse: unknown
280
+ ) => {
281
+ currentRawResponse = rawResponse;
282
+ providedCallback?.(rawResponse, flatResponse);
283
+ };
284
+ const updatedArgs = {
285
+ ...args,
286
+ options: {
287
+ ...args.options,
288
+ onResponse: callback
289
+ }
290
+ };
291
+ const flatResponse = await directSendOperation(updatedArgs, spec);
292
+ return {
293
+ flatResponse,
294
+ rawResponse: {
295
+ statusCode: currentRawResponse!.status,
296
+ body: currentRawResponse!.parsedBody,
297
+ headers: currentRawResponse!.headers.toJSON()
298
+ }
299
+ };
300
+ };
301
+
302
+ const lro = new LroImpl(
303
+ sendOperation,
304
+ { resourceGroupName, systemTopicName, eventSubscriptionName, options },
305
+ deleteOperationSpec
306
+ );
307
+ return new LroEngine(lro, {
308
+ resumeFrom: options?.resumeFrom,
309
+ intervalInMs: options?.updateIntervalInMs
310
+ });
100
311
  }
101
312
 
102
313
  /**
103
- * Update event subscription of a system topic.
104
- * @summary Update event subscription of a system topic.
314
+ * Delete an event subscription of a system topic.
105
315
  * @param resourceGroupName The name of the resource group within the user's subscription.
106
316
  * @param systemTopicName Name of the system topic.
107
- * @param eventSubscriptionName Name of the event subscription to be created. Event subscription
108
- * names must be between 3 and 100 characters in length and use alphanumeric letters only.
109
- * @param eventSubscriptionUpdateParameters Updated event subscription information.
110
- * @param [options] The optional parameters
111
- * @returns Promise<Models.SystemTopicEventSubscriptionsUpdateResponse>
317
+ * @param eventSubscriptionName Name of the event subscription to be created. Event subscription names
318
+ * must be between 3 and 100 characters in length and use alphanumeric letters only.
319
+ * @param options The options parameters.
112
320
  */
113
- update(resourceGroupName: string, systemTopicName: string, eventSubscriptionName: string, eventSubscriptionUpdateParameters: Models.EventSubscriptionUpdateParameters, options?: msRest.RequestOptionsBase): Promise<Models.SystemTopicEventSubscriptionsUpdateResponse> {
114
- return this.beginUpdate(resourceGroupName,systemTopicName,eventSubscriptionName,eventSubscriptionUpdateParameters,options)
115
- .then(lroPoller => lroPoller.pollUntilFinished()) as Promise<Models.SystemTopicEventSubscriptionsUpdateResponse>;
321
+ async beginDeleteAndWait(
322
+ resourceGroupName: string,
323
+ systemTopicName: string,
324
+ eventSubscriptionName: string,
325
+ options?: SystemTopicEventSubscriptionsDeleteOptionalParams
326
+ ): Promise<void> {
327
+ const poller = await this.beginDelete(
328
+ resourceGroupName,
329
+ systemTopicName,
330
+ eventSubscriptionName,
331
+ options
332
+ );
333
+ return poller.pollUntilDone();
116
334
  }
117
335
 
118
336
  /**
119
- * Get the full endpoint URL for an event subscription of a system topic.
120
- * @summary Get full URL of an event subscription of a system topic
121
- * @param resourceGroupName The name of the resource group within the user's subscription.
122
- * @param systemTopicName Name of the system topic.
123
- * @param eventSubscriptionName Name of the event subscription to be created. Event subscription
124
- * names must be between 3 and 100 characters in length and use alphanumeric letters only.
125
- * @param [options] The optional parameters
126
- * @returns Promise<Models.SystemTopicEventSubscriptionsGetFullUrlResponse>
127
- */
128
- getFullUrl(resourceGroupName: string, systemTopicName: string, eventSubscriptionName: string, options?: msRest.RequestOptionsBase): Promise<Models.SystemTopicEventSubscriptionsGetFullUrlResponse>;
129
- /**
130
- * @param resourceGroupName The name of the resource group within the user's subscription.
131
- * @param systemTopicName Name of the system topic.
132
- * @param eventSubscriptionName Name of the event subscription to be created. Event subscription
133
- * names must be between 3 and 100 characters in length and use alphanumeric letters only.
134
- * @param callback The callback
135
- */
136
- getFullUrl(resourceGroupName: string, systemTopicName: string, eventSubscriptionName: string, callback: msRest.ServiceCallback<Models.EventSubscriptionFullUrl>): void;
137
- /**
337
+ * Update event subscription of a system topic.
138
338
  * @param resourceGroupName The name of the resource group within the user's subscription.
139
339
  * @param systemTopicName Name of the system topic.
140
- * @param eventSubscriptionName Name of the event subscription to be created. Event subscription
141
- * names must be between 3 and 100 characters in length and use alphanumeric letters only.
142
- * @param options The optional parameters
143
- * @param callback The callback
340
+ * @param eventSubscriptionName Name of the event subscription to be created. Event subscription names
341
+ * must be between 3 and 100 characters in length and use alphanumeric letters only.
342
+ * @param eventSubscriptionUpdateParameters Updated event subscription information.
343
+ * @param options The options parameters.
144
344
  */
145
- getFullUrl(resourceGroupName: string, systemTopicName: string, eventSubscriptionName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback<Models.EventSubscriptionFullUrl>): void;
146
- getFullUrl(resourceGroupName: string, systemTopicName: string, eventSubscriptionName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback<Models.EventSubscriptionFullUrl>, callback?: msRest.ServiceCallback<Models.EventSubscriptionFullUrl>): Promise<Models.SystemTopicEventSubscriptionsGetFullUrlResponse> {
147
- return this.client.sendOperationRequest(
345
+ async beginUpdate(
346
+ resourceGroupName: string,
347
+ systemTopicName: string,
348
+ eventSubscriptionName: string,
349
+ eventSubscriptionUpdateParameters: EventSubscriptionUpdateParameters,
350
+ options?: SystemTopicEventSubscriptionsUpdateOptionalParams
351
+ ): Promise<
352
+ PollerLike<
353
+ PollOperationState<SystemTopicEventSubscriptionsUpdateResponse>,
354
+ SystemTopicEventSubscriptionsUpdateResponse
355
+ >
356
+ > {
357
+ const directSendOperation = async (
358
+ args: coreClient.OperationArguments,
359
+ spec: coreClient.OperationSpec
360
+ ): Promise<SystemTopicEventSubscriptionsUpdateResponse> => {
361
+ return this.client.sendOperationRequest(args, spec);
362
+ };
363
+ const sendOperation = async (
364
+ args: coreClient.OperationArguments,
365
+ spec: coreClient.OperationSpec
366
+ ) => {
367
+ let currentRawResponse:
368
+ | coreClient.FullOperationResponse
369
+ | undefined = undefined;
370
+ const providedCallback = args.options?.onResponse;
371
+ const callback: coreClient.RawResponseCallback = (
372
+ rawResponse: coreClient.FullOperationResponse,
373
+ flatResponse: unknown
374
+ ) => {
375
+ currentRawResponse = rawResponse;
376
+ providedCallback?.(rawResponse, flatResponse);
377
+ };
378
+ const updatedArgs = {
379
+ ...args,
380
+ options: {
381
+ ...args.options,
382
+ onResponse: callback
383
+ }
384
+ };
385
+ const flatResponse = await directSendOperation(updatedArgs, spec);
386
+ return {
387
+ flatResponse,
388
+ rawResponse: {
389
+ statusCode: currentRawResponse!.status,
390
+ body: currentRawResponse!.parsedBody,
391
+ headers: currentRawResponse!.headers.toJSON()
392
+ }
393
+ };
394
+ };
395
+
396
+ const lro = new LroImpl(
397
+ sendOperation,
148
398
  {
149
399
  resourceGroupName,
150
400
  systemTopicName,
151
401
  eventSubscriptionName,
402
+ eventSubscriptionUpdateParameters,
152
403
  options
153
404
  },
154
- getFullUrlOperationSpec,
155
- callback) as Promise<Models.SystemTopicEventSubscriptionsGetFullUrlResponse>;
405
+ updateOperationSpec
406
+ );
407
+ return new LroEngine(lro, {
408
+ resumeFrom: options?.resumeFrom,
409
+ intervalInMs: options?.updateIntervalInMs
410
+ });
156
411
  }
157
412
 
158
413
  /**
159
- * List event subscriptions that belong to a specific system topic.
160
- * @summary List event subscriptions of a system topic.
161
- * @param resourceGroupName The name of the resource group within the user's subscription.
162
- * @param systemTopicName Name of the system topic.
163
- * @param [options] The optional parameters
164
- * @returns Promise<Models.SystemTopicEventSubscriptionsListBySystemTopicResponse>
165
- */
166
- listBySystemTopic(resourceGroupName: string, systemTopicName: string, options?: Models.SystemTopicEventSubscriptionsListBySystemTopicOptionalParams): Promise<Models.SystemTopicEventSubscriptionsListBySystemTopicResponse>;
167
- /**
168
- * @param resourceGroupName The name of the resource group within the user's subscription.
169
- * @param systemTopicName Name of the system topic.
170
- * @param callback The callback
171
- */
172
- listBySystemTopic(resourceGroupName: string, systemTopicName: string, callback: msRest.ServiceCallback<Models.EventSubscriptionsListResult>): void;
173
- /**
414
+ * Update event subscription of a system topic.
174
415
  * @param resourceGroupName The name of the resource group within the user's subscription.
175
416
  * @param systemTopicName Name of the system topic.
176
- * @param options The optional parameters
177
- * @param callback The callback
417
+ * @param eventSubscriptionName Name of the event subscription to be created. Event subscription names
418
+ * must be between 3 and 100 characters in length and use alphanumeric letters only.
419
+ * @param eventSubscriptionUpdateParameters Updated event subscription information.
420
+ * @param options The options parameters.
178
421
  */
179
- listBySystemTopic(resourceGroupName: string, systemTopicName: string, options: Models.SystemTopicEventSubscriptionsListBySystemTopicOptionalParams, callback: msRest.ServiceCallback<Models.EventSubscriptionsListResult>): void;
180
- listBySystemTopic(resourceGroupName: string, systemTopicName: string, options?: Models.SystemTopicEventSubscriptionsListBySystemTopicOptionalParams | msRest.ServiceCallback<Models.EventSubscriptionsListResult>, callback?: msRest.ServiceCallback<Models.EventSubscriptionsListResult>): Promise<Models.SystemTopicEventSubscriptionsListBySystemTopicResponse> {
181
- return this.client.sendOperationRequest(
182
- {
183
- resourceGroupName,
184
- systemTopicName,
185
- options
186
- },
187
- listBySystemTopicOperationSpec,
188
- callback) as Promise<Models.SystemTopicEventSubscriptionsListBySystemTopicResponse>;
422
+ async beginUpdateAndWait(
423
+ resourceGroupName: string,
424
+ systemTopicName: string,
425
+ eventSubscriptionName: string,
426
+ eventSubscriptionUpdateParameters: EventSubscriptionUpdateParameters,
427
+ options?: SystemTopicEventSubscriptionsUpdateOptionalParams
428
+ ): Promise<SystemTopicEventSubscriptionsUpdateResponse> {
429
+ const poller = await this.beginUpdate(
430
+ resourceGroupName,
431
+ systemTopicName,
432
+ eventSubscriptionName,
433
+ eventSubscriptionUpdateParameters,
434
+ options
435
+ );
436
+ return poller.pollUntilDone();
189
437
  }
190
438
 
191
439
  /**
192
- * Get all delivery attributes for an event subscription.
193
- * @summary Get delivery attributes for an event subscription.
194
- * @param resourceGroupName The name of the resource group within the user's subscription.
195
- * @param systemTopicName Name of the system topic.
196
- * @param eventSubscriptionName Name of the event subscription to be created. Event subscription
197
- * names must be between 3 and 100 characters in length and use alphanumeric letters only.
198
- * @param [options] The optional parameters
199
- * @returns Promise<Models.SystemTopicEventSubscriptionsGetDeliveryAttributesResponse>
200
- */
201
- getDeliveryAttributes(resourceGroupName: string, systemTopicName: string, eventSubscriptionName: string, options?: msRest.RequestOptionsBase): Promise<Models.SystemTopicEventSubscriptionsGetDeliveryAttributesResponse>;
202
- /**
203
- * @param resourceGroupName The name of the resource group within the user's subscription.
204
- * @param systemTopicName Name of the system topic.
205
- * @param eventSubscriptionName Name of the event subscription to be created. Event subscription
206
- * names must be between 3 and 100 characters in length and use alphanumeric letters only.
207
- * @param callback The callback
208
- */
209
- getDeliveryAttributes(resourceGroupName: string, systemTopicName: string, eventSubscriptionName: string, callback: msRest.ServiceCallback<Models.DeliveryAttributeListResult>): void;
210
- /**
440
+ * Get the full endpoint URL for an event subscription of a system topic.
211
441
  * @param resourceGroupName The name of the resource group within the user's subscription.
212
442
  * @param systemTopicName Name of the system topic.
213
- * @param eventSubscriptionName Name of the event subscription to be created. Event subscription
214
- * names must be between 3 and 100 characters in length and use alphanumeric letters only.
215
- * @param options The optional parameters
216
- * @param callback The callback
443
+ * @param eventSubscriptionName Name of the event subscription to be created. Event subscription names
444
+ * must be between 3 and 100 characters in length and use alphanumeric letters only.
445
+ * @param options The options parameters.
217
446
  */
218
- getDeliveryAttributes(resourceGroupName: string, systemTopicName: string, eventSubscriptionName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback<Models.DeliveryAttributeListResult>): void;
219
- getDeliveryAttributes(resourceGroupName: string, systemTopicName: string, eventSubscriptionName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback<Models.DeliveryAttributeListResult>, callback?: msRest.ServiceCallback<Models.DeliveryAttributeListResult>): Promise<Models.SystemTopicEventSubscriptionsGetDeliveryAttributesResponse> {
447
+ getFullUrl(
448
+ resourceGroupName: string,
449
+ systemTopicName: string,
450
+ eventSubscriptionName: string,
451
+ options?: SystemTopicEventSubscriptionsGetFullUrlOptionalParams
452
+ ): Promise<SystemTopicEventSubscriptionsGetFullUrlResponse> {
220
453
  return this.client.sendOperationRequest(
221
- {
222
- resourceGroupName,
223
- systemTopicName,
224
- eventSubscriptionName,
225
- options
226
- },
227
- getDeliveryAttributesOperationSpec,
228
- callback) as Promise<Models.SystemTopicEventSubscriptionsGetDeliveryAttributesResponse>;
454
+ { resourceGroupName, systemTopicName, eventSubscriptionName, options },
455
+ getFullUrlOperationSpec
456
+ );
229
457
  }
230
458
 
231
459
  /**
232
- * Asynchronously creates or updates an event subscription with the specified parameters. Existing
233
- * event subscriptions will be updated with this API.
234
- * @summary Create or update an event subscription for a system topic.
460
+ * List event subscriptions that belong to a specific system topic.
235
461
  * @param resourceGroupName The name of the resource group within the user's subscription.
236
462
  * @param systemTopicName Name of the system topic.
237
- * @param eventSubscriptionName Name of the event subscription to be created. Event subscription
238
- * names must be between 3 and 100 characters in length and use alphanumeric letters only.
239
- * @param eventSubscriptionInfo Event subscription properties containing the destination and filter
240
- * information.
241
- * @param [options] The optional parameters
242
- * @returns Promise<msRestAzure.LROPoller>
463
+ * @param options The options parameters.
243
464
  */
244
- beginCreateOrUpdate(resourceGroupName: string, systemTopicName: string, eventSubscriptionName: string, eventSubscriptionInfo: Models.EventSubscription, options?: msRest.RequestOptionsBase): Promise<msRestAzure.LROPoller> {
245
- return this.client.sendLRORequest(
246
- {
247
- resourceGroupName,
248
- systemTopicName,
249
- eventSubscriptionName,
250
- eventSubscriptionInfo,
251
- options
252
- },
253
- beginCreateOrUpdateOperationSpec,
254
- options);
465
+ private _listBySystemTopic(
466
+ resourceGroupName: string,
467
+ systemTopicName: string,
468
+ options?: SystemTopicEventSubscriptionsListBySystemTopicOptionalParams
469
+ ): Promise<SystemTopicEventSubscriptionsListBySystemTopicResponse> {
470
+ return this.client.sendOperationRequest(
471
+ { resourceGroupName, systemTopicName, options },
472
+ listBySystemTopicOperationSpec
473
+ );
255
474
  }
256
475
 
257
476
  /**
258
- * Delete an event subscription of a system topic.
259
- * @summary Delete an event subscription of a system topic.
477
+ * Get all delivery attributes for an event subscription.
260
478
  * @param resourceGroupName The name of the resource group within the user's subscription.
261
479
  * @param systemTopicName Name of the system topic.
262
- * @param eventSubscriptionName Name of the event subscription to be created. Event subscription
263
- * names must be between 3 and 100 characters in length and use alphanumeric letters only.
264
- * @param [options] The optional parameters
265
- * @returns Promise<msRestAzure.LROPoller>
480
+ * @param eventSubscriptionName Name of the event subscription to be created. Event subscription names
481
+ * must be between 3 and 100 characters in length and use alphanumeric letters only.
482
+ * @param options The options parameters.
266
483
  */
267
- beginDeleteMethod(resourceGroupName: string, systemTopicName: string, eventSubscriptionName: string, options?: msRest.RequestOptionsBase): Promise<msRestAzure.LROPoller> {
268
- return this.client.sendLRORequest(
269
- {
270
- resourceGroupName,
271
- systemTopicName,
272
- eventSubscriptionName,
273
- options
274
- },
275
- beginDeleteMethodOperationSpec,
276
- options);
484
+ getDeliveryAttributes(
485
+ resourceGroupName: string,
486
+ systemTopicName: string,
487
+ eventSubscriptionName: string,
488
+ options?: SystemTopicEventSubscriptionsGetDeliveryAttributesOptionalParams
489
+ ): Promise<SystemTopicEventSubscriptionsGetDeliveryAttributesResponse> {
490
+ return this.client.sendOperationRequest(
491
+ { resourceGroupName, systemTopicName, eventSubscriptionName, options },
492
+ getDeliveryAttributesOperationSpec
493
+ );
277
494
  }
278
495
 
279
496
  /**
280
- * Update event subscription of a system topic.
281
- * @summary Update event subscription of a system topic.
497
+ * ListBySystemTopicNext
282
498
  * @param resourceGroupName The name of the resource group within the user's subscription.
283
499
  * @param systemTopicName Name of the system topic.
284
- * @param eventSubscriptionName Name of the event subscription to be created. Event subscription
285
- * names must be between 3 and 100 characters in length and use alphanumeric letters only.
286
- * @param eventSubscriptionUpdateParameters Updated event subscription information.
287
- * @param [options] The optional parameters
288
- * @returns Promise<msRestAzure.LROPoller>
289
- */
290
- beginUpdate(resourceGroupName: string, systemTopicName: string, eventSubscriptionName: string, eventSubscriptionUpdateParameters: Models.EventSubscriptionUpdateParameters, options?: msRest.RequestOptionsBase): Promise<msRestAzure.LROPoller> {
291
- return this.client.sendLRORequest(
292
- {
293
- resourceGroupName,
294
- systemTopicName,
295
- eventSubscriptionName,
296
- eventSubscriptionUpdateParameters,
297
- options
298
- },
299
- beginUpdateOperationSpec,
300
- options);
301
- }
302
-
303
- /**
304
- * List event subscriptions that belong to a specific system topic.
305
- * @summary List event subscriptions of a system topic.
306
- * @param nextPageLink The NextLink from the previous successful call to List operation.
307
- * @param [options] The optional parameters
308
- * @returns Promise<Models.SystemTopicEventSubscriptionsListBySystemTopicNextResponse>
309
- */
310
- listBySystemTopicNext(nextPageLink: string, options?: Models.SystemTopicEventSubscriptionsListBySystemTopicNextOptionalParams): Promise<Models.SystemTopicEventSubscriptionsListBySystemTopicNextResponse>;
311
- /**
312
- * @param nextPageLink The NextLink from the previous successful call to List operation.
313
- * @param callback The callback
500
+ * @param nextLink The nextLink from the previous successful call to the ListBySystemTopic method.
501
+ * @param options The options parameters.
314
502
  */
315
- listBySystemTopicNext(nextPageLink: string, callback: msRest.ServiceCallback<Models.EventSubscriptionsListResult>): void;
316
- /**
317
- * @param nextPageLink The NextLink from the previous successful call to List operation.
318
- * @param options The optional parameters
319
- * @param callback The callback
320
- */
321
- listBySystemTopicNext(nextPageLink: string, options: Models.SystemTopicEventSubscriptionsListBySystemTopicNextOptionalParams, callback: msRest.ServiceCallback<Models.EventSubscriptionsListResult>): void;
322
- listBySystemTopicNext(nextPageLink: string, options?: Models.SystemTopicEventSubscriptionsListBySystemTopicNextOptionalParams | msRest.ServiceCallback<Models.EventSubscriptionsListResult>, callback?: msRest.ServiceCallback<Models.EventSubscriptionsListResult>): Promise<Models.SystemTopicEventSubscriptionsListBySystemTopicNextResponse> {
503
+ private _listBySystemTopicNext(
504
+ resourceGroupName: string,
505
+ systemTopicName: string,
506
+ nextLink: string,
507
+ options?: SystemTopicEventSubscriptionsListBySystemTopicNextOptionalParams
508
+ ): Promise<SystemTopicEventSubscriptionsListBySystemTopicNextResponse> {
323
509
  return this.client.sendOperationRequest(
324
- {
325
- nextPageLink,
326
- options
327
- },
328
- listBySystemTopicNextOperationSpec,
329
- callback) as Promise<Models.SystemTopicEventSubscriptionsListBySystemTopicNextResponse>;
510
+ { resourceGroupName, systemTopicName, nextLink, options },
511
+ listBySystemTopicNextOperationSpec
512
+ );
330
513
  }
331
514
  }
332
-
333
515
  // Operation Specifications
334
- const serializer = new msRest.Serializer(Mappers);
335
- const getOperationSpec: msRest.OperationSpec = {
516
+ const serializer = coreClient.createSerializer(Mappers, /* isXml */ false);
517
+
518
+ const getOperationSpec: coreClient.OperationSpec = {
519
+ path:
520
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.EventGrid/systemTopics/{systemTopicName}/eventSubscriptions/{eventSubscriptionName}",
336
521
  httpMethod: "GET",
337
- path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.EventGrid/systemTopics/{systemTopicName}/eventSubscriptions/{eventSubscriptionName}",
338
- urlParameters: [
339
- Parameters.subscriptionId,
340
- Parameters.resourceGroupName,
341
- Parameters.systemTopicName,
342
- Parameters.eventSubscriptionName
343
- ],
344
- queryParameters: [
345
- Parameters.apiVersion
346
- ],
347
- headerParameters: [
348
- Parameters.acceptLanguage
349
- ],
350
522
  responses: {
351
523
  200: {
352
524
  bodyMapper: Mappers.EventSubscription
353
525
  },
354
- default: {
355
- bodyMapper: Mappers.CloudError
356
- }
526
+ default: {}
357
527
  },
358
- serializer
359
- };
360
-
361
- const getFullUrlOperationSpec: msRest.OperationSpec = {
362
- httpMethod: "POST",
363
- path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.EventGrid/systemTopics/{systemTopicName}/eventSubscriptions/{eventSubscriptionName}/getFullUrl",
528
+ queryParameters: [Parameters.apiVersion],
364
529
  urlParameters: [
530
+ Parameters.$host,
365
531
  Parameters.subscriptionId,
366
532
  Parameters.resourceGroupName,
367
- Parameters.systemTopicName,
368
- Parameters.eventSubscriptionName
369
- ],
370
- queryParameters: [
371
- Parameters.apiVersion
372
- ],
373
- headerParameters: [
374
- Parameters.acceptLanguage
533
+ Parameters.eventSubscriptionName,
534
+ Parameters.systemTopicName
375
535
  ],
536
+ headerParameters: [Parameters.accept],
537
+ serializer
538
+ };
539
+ const createOrUpdateOperationSpec: coreClient.OperationSpec = {
540
+ path:
541
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.EventGrid/systemTopics/{systemTopicName}/eventSubscriptions/{eventSubscriptionName}",
542
+ httpMethod: "PUT",
376
543
  responses: {
377
544
  200: {
378
- bodyMapper: Mappers.EventSubscriptionFullUrl
545
+ bodyMapper: Mappers.EventSubscription
379
546
  },
380
- default: {
381
- bodyMapper: Mappers.CloudError
382
- }
547
+ 201: {
548
+ bodyMapper: Mappers.EventSubscription
549
+ },
550
+ 202: {
551
+ bodyMapper: Mappers.EventSubscription
552
+ },
553
+ 204: {
554
+ bodyMapper: Mappers.EventSubscription
555
+ },
556
+ default: {}
383
557
  },
558
+ requestBody: Parameters.eventSubscriptionInfo,
559
+ queryParameters: [Parameters.apiVersion],
560
+ urlParameters: [
561
+ Parameters.$host,
562
+ Parameters.subscriptionId,
563
+ Parameters.resourceGroupName,
564
+ Parameters.eventSubscriptionName,
565
+ Parameters.systemTopicName
566
+ ],
567
+ headerParameters: [Parameters.accept, Parameters.contentType],
568
+ mediaType: "json",
384
569
  serializer
385
570
  };
386
-
387
- const listBySystemTopicOperationSpec: msRest.OperationSpec = {
388
- httpMethod: "GET",
389
- path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.EventGrid/systemTopics/{systemTopicName}/eventSubscriptions",
571
+ const deleteOperationSpec: coreClient.OperationSpec = {
572
+ path:
573
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.EventGrid/systemTopics/{systemTopicName}/eventSubscriptions/{eventSubscriptionName}",
574
+ httpMethod: "DELETE",
575
+ responses: { 200: {}, 201: {}, 202: {}, 204: {}, default: {} },
576
+ queryParameters: [Parameters.apiVersion],
390
577
  urlParameters: [
578
+ Parameters.$host,
391
579
  Parameters.subscriptionId,
392
580
  Parameters.resourceGroupName,
581
+ Parameters.eventSubscriptionName,
393
582
  Parameters.systemTopicName
394
583
  ],
395
- queryParameters: [
396
- Parameters.apiVersion,
397
- Parameters.filter,
398
- Parameters.top
399
- ],
400
- headerParameters: [
401
- Parameters.acceptLanguage
402
- ],
584
+ serializer
585
+ };
586
+ const updateOperationSpec: coreClient.OperationSpec = {
587
+ path:
588
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.EventGrid/systemTopics/{systemTopicName}/eventSubscriptions/{eventSubscriptionName}",
589
+ httpMethod: "PATCH",
403
590
  responses: {
404
591
  200: {
405
- bodyMapper: Mappers.EventSubscriptionsListResult
592
+ bodyMapper: Mappers.EventSubscription
406
593
  },
407
- default: {
408
- bodyMapper: Mappers.CloudError
409
- }
594
+ 201: {
595
+ bodyMapper: Mappers.EventSubscription
596
+ },
597
+ 202: {
598
+ bodyMapper: Mappers.EventSubscription
599
+ },
600
+ 204: {
601
+ bodyMapper: Mappers.EventSubscription
602
+ },
603
+ default: {}
410
604
  },
411
- serializer
412
- };
413
-
414
- const getDeliveryAttributesOperationSpec: msRest.OperationSpec = {
415
- httpMethod: "POST",
416
- path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.EventGrid/systemTopics/{systemTopicName}/eventSubscriptions/{eventSubscriptionName}/getDeliveryAttributes",
605
+ requestBody: Parameters.eventSubscriptionUpdateParameters,
606
+ queryParameters: [Parameters.apiVersion],
417
607
  urlParameters: [
608
+ Parameters.$host,
418
609
  Parameters.subscriptionId,
419
610
  Parameters.resourceGroupName,
420
- Parameters.systemTopicName,
421
- Parameters.eventSubscriptionName
422
- ],
423
- queryParameters: [
424
- Parameters.apiVersion
425
- ],
426
- headerParameters: [
427
- Parameters.acceptLanguage
611
+ Parameters.eventSubscriptionName,
612
+ Parameters.systemTopicName
428
613
  ],
614
+ headerParameters: [Parameters.accept, Parameters.contentType],
615
+ mediaType: "json",
616
+ serializer
617
+ };
618
+ const getFullUrlOperationSpec: coreClient.OperationSpec = {
619
+ path:
620
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.EventGrid/systemTopics/{systemTopicName}/eventSubscriptions/{eventSubscriptionName}/getFullUrl",
621
+ httpMethod: "POST",
429
622
  responses: {
430
623
  200: {
431
- bodyMapper: Mappers.DeliveryAttributeListResult
624
+ bodyMapper: Mappers.EventSubscriptionFullUrl
432
625
  },
433
- default: {
434
- bodyMapper: Mappers.CloudError
435
- }
626
+ default: {}
436
627
  },
437
- serializer
438
- };
439
-
440
- const beginCreateOrUpdateOperationSpec: msRest.OperationSpec = {
441
- httpMethod: "PUT",
442
- path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.EventGrid/systemTopics/{systemTopicName}/eventSubscriptions/{eventSubscriptionName}",
628
+ queryParameters: [Parameters.apiVersion],
443
629
  urlParameters: [
630
+ Parameters.$host,
444
631
  Parameters.subscriptionId,
445
632
  Parameters.resourceGroupName,
446
- Parameters.systemTopicName,
447
- Parameters.eventSubscriptionName
448
- ],
449
- queryParameters: [
450
- Parameters.apiVersion
451
- ],
452
- headerParameters: [
453
- Parameters.acceptLanguage
633
+ Parameters.eventSubscriptionName,
634
+ Parameters.systemTopicName
454
635
  ],
455
- requestBody: {
456
- parameterPath: "eventSubscriptionInfo",
457
- mapper: {
458
- ...Mappers.EventSubscription,
459
- required: true
460
- }
461
- },
636
+ headerParameters: [Parameters.accept],
637
+ serializer
638
+ };
639
+ const listBySystemTopicOperationSpec: coreClient.OperationSpec = {
640
+ path:
641
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.EventGrid/systemTopics/{systemTopicName}/eventSubscriptions",
642
+ httpMethod: "GET",
462
643
  responses: {
463
- 201: {
464
- bodyMapper: Mappers.EventSubscription
644
+ 200: {
645
+ bodyMapper: Mappers.EventSubscriptionsListResult
465
646
  },
466
- default: {
467
- bodyMapper: Mappers.CloudError
468
- }
647
+ default: {}
469
648
  },
470
- serializer
471
- };
472
-
473
- const beginDeleteMethodOperationSpec: msRest.OperationSpec = {
474
- httpMethod: "DELETE",
475
- path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.EventGrid/systemTopics/{systemTopicName}/eventSubscriptions/{eventSubscriptionName}",
649
+ queryParameters: [Parameters.apiVersion, Parameters.filter, Parameters.top],
476
650
  urlParameters: [
651
+ Parameters.$host,
477
652
  Parameters.subscriptionId,
478
653
  Parameters.resourceGroupName,
479
- Parameters.systemTopicName,
480
- Parameters.eventSubscriptionName
481
- ],
482
- queryParameters: [
483
- Parameters.apiVersion
484
- ],
485
- headerParameters: [
486
- Parameters.acceptLanguage
654
+ Parameters.systemTopicName
487
655
  ],
488
- responses: {
489
- 200: {},
490
- 202: {},
491
- 204: {},
492
- default: {
493
- bodyMapper: Mappers.CloudError
494
- }
495
- },
656
+ headerParameters: [Parameters.accept],
496
657
  serializer
497
658
  };
498
-
499
- const beginUpdateOperationSpec: msRest.OperationSpec = {
500
- httpMethod: "PATCH",
501
- path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.EventGrid/systemTopics/{systemTopicName}/eventSubscriptions/{eventSubscriptionName}",
659
+ const getDeliveryAttributesOperationSpec: coreClient.OperationSpec = {
660
+ path:
661
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.EventGrid/systemTopics/{systemTopicName}/eventSubscriptions/{eventSubscriptionName}/getDeliveryAttributes",
662
+ httpMethod: "POST",
663
+ responses: {
664
+ 200: {
665
+ bodyMapper: Mappers.DeliveryAttributeListResult
666
+ },
667
+ default: {}
668
+ },
669
+ queryParameters: [Parameters.apiVersion],
502
670
  urlParameters: [
671
+ Parameters.$host,
503
672
  Parameters.subscriptionId,
504
673
  Parameters.resourceGroupName,
505
- Parameters.systemTopicName,
506
- Parameters.eventSubscriptionName
507
- ],
508
- queryParameters: [
509
- Parameters.apiVersion
510
- ],
511
- headerParameters: [
512
- Parameters.acceptLanguage
674
+ Parameters.eventSubscriptionName,
675
+ Parameters.systemTopicName
513
676
  ],
514
- requestBody: {
515
- parameterPath: "eventSubscriptionUpdateParameters",
516
- mapper: {
517
- ...Mappers.EventSubscriptionUpdateParameters,
518
- required: true
519
- }
520
- },
521
- responses: {
522
- 201: {
523
- bodyMapper: Mappers.EventSubscription
524
- },
525
- default: {
526
- bodyMapper: Mappers.CloudError
527
- }
528
- },
677
+ headerParameters: [Parameters.accept],
529
678
  serializer
530
679
  };
531
-
532
- const listBySystemTopicNextOperationSpec: msRest.OperationSpec = {
533
- httpMethod: "GET",
534
- baseUrl: "https://management.azure.com",
680
+ const listBySystemTopicNextOperationSpec: coreClient.OperationSpec = {
535
681
  path: "{nextLink}",
536
- urlParameters: [
537
- Parameters.nextPageLink
538
- ],
539
- queryParameters: [
540
- Parameters.apiVersion,
541
- Parameters.filter,
542
- Parameters.top
543
- ],
544
- headerParameters: [
545
- Parameters.acceptLanguage
546
- ],
682
+ httpMethod: "GET",
547
683
  responses: {
548
684
  200: {
549
685
  bodyMapper: Mappers.EventSubscriptionsListResult
550
686
  },
551
- default: {
552
- bodyMapper: Mappers.CloudError
553
- }
687
+ default: {}
554
688
  },
689
+ queryParameters: [Parameters.apiVersion, Parameters.filter, Parameters.top],
690
+ urlParameters: [
691
+ Parameters.$host,
692
+ Parameters.subscriptionId,
693
+ Parameters.resourceGroupName,
694
+ Parameters.nextLink,
695
+ Parameters.systemTopicName
696
+ ],
697
+ headerParameters: [Parameters.accept],
555
698
  serializer
556
699
  };