diff --git a/common/config/rush/pnpm-lock.yaml b/common/config/rush/pnpm-lock.yaml index d34f3473def7..1091c140f3b0 100644 --- a/common/config/rush/pnpm-lock.yaml +++ b/common/config/rush/pnpm-lock.yaml @@ -4759,7 +4759,7 @@ packages: /ajv-formats@3.0.1: resolution: {integrity: sha512-8iUql50EUR+uUcdRQ3HDqa6EVyo3docL8g5WJ3FNcWmu62IbkGUue/pEyLBW8VGKKucTPgqeks4fIU1DA4yowQ==} dependencies: - ajv: 8.13.0 + ajv: 8.17.1 dev: false /ajv@6.12.6: @@ -11946,7 +11946,7 @@ packages: dev: false file:projects/ai-language-conversations.tgz: - resolution: {integrity: sha512-wOaN69Lhlpb1JYXq110+dhqUs/LWyWKbmWcyW5Py/3tjfNNroj88cEmmiAVcSmQsHH1rxFNV0wNLCwsr+udEeA==, tarball: file:projects/ai-language-conversations.tgz} + resolution: {integrity: sha512-WObWM32nlgWBIk8v4DvtUD+fu5L0pw3Zt/UloSQBS3A1l7qvAT8W7QcZv03KfhAKjUY6sEHQIkA3k1L58W8vnw==, tarball: file:projects/ai-language-conversations.tgz} name: '@rush-temp/ai-language-conversations' version: 0.0.0 dependencies: @@ -12153,7 +12153,7 @@ packages: dev: false file:projects/ai-translation-document.tgz: - resolution: {integrity: sha512-jgp898nJu2T8LSEmHZJydRpvv6ayNehaMtQpiVSTMzv6KSpqlrREMYNsE7KYCE4GB+xYQa0kX9RbQb9a8ha1Sg==, tarball: file:projects/ai-translation-document.tgz} + resolution: {integrity: sha512-kLfAuurq8WLBA7YJbBtaXrCtEBAf72TbcQySRIBCEAOsqypoQogXLMCO70OnPooaggmRCf/Q509Aic0i3Pxp0Q==, tarball: file:projects/ai-translation-document.tgz} name: '@rush-temp/ai-translation-document' version: 0.0.0 dependencies: @@ -12439,7 +12439,7 @@ packages: dev: false file:projects/arm-advisor.tgz: - resolution: {integrity: sha512-lXPunApRQA1E0IIpSGx/sX3wlai5eoDDEQYgYOuIN2ekE2VsVDYVunl2wcie8/h6D0WdVDg22DqYoibNQxBF6Q==, tarball: file:projects/arm-advisor.tgz} + resolution: {integrity: sha512-96K9r+isrJRSN4Ywil2ni+AYKjXddK/CI2B0tkTw8tRJQvlC7aKliPbhOstEYQTQc2dNw+vMd2AEYFiLTyPJgw==, tarball: file:projects/arm-advisor.tgz} name: '@rush-temp/arm-advisor' version: 0.0.0 dependencies: @@ -12463,7 +12463,7 @@ packages: dev: false file:projects/arm-agrifood.tgz: - resolution: {integrity: sha512-xKV1c1bu4nFLJgHeBaYaeQzb8UvXPB612BTM6+/1OdO2/eMeL0LYhfRkfJUXmEa2DIZlf8PlfGh4k0+6iI2/iw==, tarball: file:projects/arm-agrifood.tgz} + resolution: {integrity: sha512-nx6KK6DlgfE4NmgeB4+MhfIT1BRisjau9/90IdEUXM6bSNQZOWWok/Z+gkOMjhw5TN4CuysYfeaYccZmWO4+nQ==, tarball: file:projects/arm-agrifood.tgz} name: '@rush-temp/arm-agrifood' version: 0.0.0 dependencies: @@ -12488,7 +12488,7 @@ packages: dev: false file:projects/arm-analysisservices.tgz: - resolution: {integrity: sha512-oc6EGuAHlwP5K5OzEilPW4RWYxpCqOyWNuHDLzYpsjVdK7bGGYZ6ZHnO5syW8SgbnUCBKMTbhe4tilK/tpr5fQ==, tarball: file:projects/arm-analysisservices.tgz} + resolution: {integrity: sha512-8HQPHChuzkh6p+7WDfLtdplI95WFvhkXGQCYwcmWz7Lw/1hTJqOqAtR+Gc107YJwW9XUkgAbEi+O+WFXx1e69g==, tarball: file:projects/arm-analysisservices.tgz} name: '@rush-temp/arm-analysisservices' version: 0.0.0 dependencies: @@ -12513,7 +12513,7 @@ packages: dev: false file:projects/arm-apicenter.tgz: - resolution: {integrity: sha512-VAOtLy9+v/iNPaNgWUl+hbG1gGI7bP4oJxlmOZxZw4V9DXl9yQW5ebdj+S2Y4SpnZRli272bPUbaa+7NLpdgZQ==, tarball: file:projects/arm-apicenter.tgz} + resolution: {integrity: sha512-fGBVp8CLlhGsrRMXr8FSP6PlvuQ1kWDlfMyWOwC349YatApii5XDS1M2isx767Cb/zRFwR/3BS1cnmRwMnXd1w==, tarball: file:projects/arm-apicenter.tgz} name: '@rush-temp/arm-apicenter' version: 0.0.0 dependencies: @@ -12539,7 +12539,7 @@ packages: dev: false file:projects/arm-apimanagement.tgz: - resolution: {integrity: sha512-oHKcDHI8p8zFFka4sdnpbjwOGx76cpOqkFkmbQ7OmYlZWhoxL2YQnOj54asjDZLGZQOb1pnO9lD+idN+u3kKmA==, tarball: file:projects/arm-apimanagement.tgz} + resolution: {integrity: sha512-Yj8CdUhpmpl4CX0Z8Fxbq4OF7af88UXBXEED5k6IyluVwGyMpQEFpnLOMSujqwI5M0FA+bCWKq/47+sLCKMtVw==, tarball: file:projects/arm-apimanagement.tgz} name: '@rush-temp/arm-apimanagement' version: 0.0.0 dependencies: @@ -12565,7 +12565,7 @@ packages: dev: false file:projects/arm-appcomplianceautomation.tgz: - resolution: {integrity: sha512-jp7YRn8fMc/QjDFTW8Ij4/PNmD6r7q/EUbCtp34oH25oLzx10wmqIjFW2pSP9bap91p6xT3ANcm/M9apSIgSUw==, tarball: file:projects/arm-appcomplianceautomation.tgz} + resolution: {integrity: sha512-1ChDKV3xbiXh58DBKnhHyoOBB68SyXP6+3zGXkHq5FjyjqMycTZVlVsBMyLnzFHjMHI3z7KGxsFBeA8G8vv5lg==, tarball: file:projects/arm-appcomplianceautomation.tgz} name: '@rush-temp/arm-appcomplianceautomation' version: 0.0.0 dependencies: @@ -12592,7 +12592,7 @@ packages: dev: false file:projects/arm-appconfiguration.tgz: - resolution: {integrity: sha512-+4Yotk7vkoqkdIAw/7oL1yFROuIU3Yo9mGoKoAjF9Cg+tWIuayyH1yruyXTZrepedvFTtjWZzQ1J9XqhBw2LyA==, tarball: file:projects/arm-appconfiguration.tgz} + resolution: {integrity: sha512-ZdHGYcLzjTz6E/DVZrHHx3TxcgoGEhYFclpgu/mo8t8+RMJgTRppQrJkeJ34+6VWSynloaZBqBdG5n5fin83Mw==, tarball: file:projects/arm-appconfiguration.tgz} name: '@rush-temp/arm-appconfiguration' version: 0.0.0 dependencies: @@ -12618,7 +12618,7 @@ packages: dev: false file:projects/arm-appcontainers.tgz: - resolution: {integrity: sha512-Yqtot2evM9nL+uI+iWzElSQpPP3/7pkaKkO1eYCqXzoQesY8FmqePzAjjicGA2xS45P2QAYGrVjrTyKKEGYxBw==, tarball: file:projects/arm-appcontainers.tgz} + resolution: {integrity: sha512-ePWniK50lacYZXAcLMr767VI3Qz5BPl/dQo2puoh6s5wowW12ssVgKwGQGaTyFqkGMpPzHPbu2s/RIayYXsmDQ==, tarball: file:projects/arm-appcontainers.tgz} name: '@rush-temp/arm-appcontainers' version: 0.0.0 dependencies: @@ -12645,7 +12645,7 @@ packages: dev: false file:projects/arm-appinsights.tgz: - resolution: {integrity: sha512-NlZXFalxbHFUSmbivhKz5DtwbtkJ9VH/rFMfQUYkvIKnrwT1qL+54ffmsTNqUTZZExPBAmuIMS/Q6x8OD+W7jg==, tarball: file:projects/arm-appinsights.tgz} + resolution: {integrity: sha512-yX3abbvgyFr5uIRQztKFIs96POke+cHvDUrH0+OkmaGwmp0i8Ket+7XOw7e6+yiV6ysneBFvrUDzpe3ScSuqDg==, tarball: file:projects/arm-appinsights.tgz} name: '@rush-temp/arm-appinsights' version: 0.0.0 dependencies: @@ -12668,7 +12668,7 @@ packages: dev: false file:projects/arm-appplatform.tgz: - resolution: {integrity: sha512-JHzhRPDwETT+Sf+n5KvVUpgbHCMLWv+Qi8FAh9lBKoOPSeNRM8G3RlhC8/3nH4IuGPTdFl/W0WRBBDVnBI5OKQ==, tarball: file:projects/arm-appplatform.tgz} + resolution: {integrity: sha512-9PkuNmLJ2RB8E+XUctioALk1k5dbEfNwcEpqHM9mAwoidr+gJNUPhh5DMLSZrf1VNREMcevpuExxAwwuoqZDGw==, tarball: file:projects/arm-appplatform.tgz} name: '@rush-temp/arm-appplatform' version: 0.0.0 dependencies: @@ -12694,7 +12694,7 @@ packages: dev: false file:projects/arm-appservice-1.tgz: - resolution: {integrity: sha512-er+OgyfLawSCmOJRyje6QwfLRnBY3khMGFkddI6KSwwoxmRw2AMBZMnkpUNlRhzHswo7/SHFItvp+6eqA41x4Q==, tarball: file:projects/arm-appservice-1.tgz} + resolution: {integrity: sha512-tZnDM/sB3CZkpdAdF9f2o90f87B+3aBVH5dRcY71FkHIKIWgo2NiFFiZAGAceeXIF4aJQ9hWRtzd5is9+IGDWg==, tarball: file:projects/arm-appservice-1.tgz} name: '@rush-temp/arm-appservice-1' version: 0.0.0 dependencies: @@ -12721,7 +12721,7 @@ packages: dev: false file:projects/arm-appservice-profile-2020-09-01-hybrid.tgz: - resolution: {integrity: sha512-OV3ATcuw/RkvLPBVPW+Z6OSZ3Fdi+O+PzyW9ulmnIjwvnRPx/dafJ03akRvbcTBIre65ZjIAIgSnByQAwq68Og==, tarball: file:projects/arm-appservice-profile-2020-09-01-hybrid.tgz} + resolution: {integrity: sha512-uJ7ti6oz8fkuRU/aCQTFqwGOaVLHjuYl78TUymah8ajZnXHlkSQxGzP3W681fmQFPEMlCQstQkRMekGn0RS4dQ==, tarball: file:projects/arm-appservice-profile-2020-09-01-hybrid.tgz} name: '@rush-temp/arm-appservice-profile-2020-09-01-hybrid' version: 0.0.0 dependencies: @@ -12790,7 +12790,7 @@ packages: dev: false file:projects/arm-astro.tgz: - resolution: {integrity: sha512-MT/MZ24cannAYr71ttZiMJKKEjkE4Jmev/eHBcD0V1bL0w/wAACqorlGjT8mnHi/fdHsGDLykZ/Se7RpqVod2g==, tarball: file:projects/arm-astro.tgz} + resolution: {integrity: sha512-RSOWNl30XerfCHmnqSLbJCHViDJpAa7meL64EiriqIMkaCMQEJOw2tjPIvMKIM3xP/KzJTd/qKNEdKNsYxLxnA==, tarball: file:projects/arm-astro.tgz} name: '@rush-temp/arm-astro' version: 0.0.0 dependencies: @@ -12816,7 +12816,7 @@ packages: dev: false file:projects/arm-attestation.tgz: - resolution: {integrity: sha512-wNzW4q3aknqDuAPymc7pXvu+GljSftEoxnSYg/0Cq6mYFLQgJ4YNQ08eoZu/0axsl9jnE/LeBXpJAr/ydfiX3Q==, tarball: file:projects/arm-attestation.tgz} + resolution: {integrity: sha512-gjU77HFVx3W110xJowypNmaT7JWWMpLKkRwQfrfyCJX1iIJHTERgPMyDtkvZPoI6ieUBDrjqJzA4L+HGKxuDzQ==, tarball: file:projects/arm-attestation.tgz} name: '@rush-temp/arm-attestation' version: 0.0.0 dependencies: @@ -12839,7 +12839,7 @@ packages: dev: false file:projects/arm-authorization-profile-2020-09-01-hybrid.tgz: - resolution: {integrity: sha512-+zSnxnvrloFewVhvzgam7AaDuw76dntwgqVY05p8U+TtNa+Rs4PDAEbGIdReuEMCu9nyPN6J6lhva/BIBmQSrQ==, tarball: file:projects/arm-authorization-profile-2020-09-01-hybrid.tgz} + resolution: {integrity: sha512-ltK190igyjDydtt72OnzDY0tsIBKriQLCaWDnoJQuvzCw2XoZagbPGuRnKMbNs+3fxDBUN8luZCZoN3a+segiw==, tarball: file:projects/arm-authorization-profile-2020-09-01-hybrid.tgz} name: '@rush-temp/arm-authorization-profile-2020-09-01-hybrid' version: 0.0.0 dependencies: @@ -12863,7 +12863,7 @@ packages: dev: false file:projects/arm-authorization.tgz: - resolution: {integrity: sha512-diPhG0bpvWZAwqD/17JbwX/klnUr8kVSyxq6RmJzJ8QEd6Rpk2fQ6p2K6h7ivOES7pfV8X0l46qJA2JgfnvMKw==, tarball: file:projects/arm-authorization.tgz} + resolution: {integrity: sha512-cDxg8NxS9qvQoTgoddBNxpDhm1ZollPOWS42tEu2PaRzwc54XjG9fPP5TqcIa2FNVqH6rtEZgRK7S9xQQGCoMQ==, tarball: file:projects/arm-authorization.tgz} name: '@rush-temp/arm-authorization' version: 0.0.0 dependencies: @@ -12889,7 +12889,7 @@ packages: dev: false file:projects/arm-automanage.tgz: - resolution: {integrity: sha512-zao/AKn0d5rZOXubo2Tv0PU9ChzLX8HwelqRiPlA/RKYmMi6Pywa5IhdjMJBKUe7IZBEBJ8Arvw9r2dPR7/hUw==, tarball: file:projects/arm-automanage.tgz} + resolution: {integrity: sha512-hsrw44WEUm1v6vRtD/6jRwiKVCbwFyMFWvSy/uZK02GrBdRYDtbbNMAH0WqCIjJ7sW42p7P11Y62HVcac0m6AQ==, tarball: file:projects/arm-automanage.tgz} name: '@rush-temp/arm-automanage' version: 0.0.0 dependencies: @@ -12913,7 +12913,7 @@ packages: dev: false file:projects/arm-automation.tgz: - resolution: {integrity: sha512-ovqSsjmpanZlHE7jGFez0QtgBczzu0h9Pf3OSDOX0DA7Z5emiI30khpmZWzastRte9PYiRrh0JOxjGKvM36YOg==, tarball: file:projects/arm-automation.tgz} + resolution: {integrity: sha512-091XwYl8IySHQiVRp/4l3SK+UDx9qFEDk1ycZmYuhXd6XLY63nn3fyX71slBqmpoFW+Z9PBANtAdEcgQ6s4x4w==, tarball: file:projects/arm-automation.tgz} name: '@rush-temp/arm-automation' version: 0.0.0 dependencies: @@ -12939,7 +12939,7 @@ packages: dev: false file:projects/arm-avs.tgz: - resolution: {integrity: sha512-STI3nKAxra8sob80xaSD8iK6m6SPQNcSYVLcafjNTVDzlac81oKmDtp2ZJMHOxlkqrVWGx6pgmU8zDbR5id8EA==, tarball: file:projects/arm-avs.tgz} + resolution: {integrity: sha512-8CTU1mmH2Yd+oVkjCzTz4XWflVPeXiKNjIonRg1ce9U8Ez37GUWJ6vpbZQ5kk3RR3z34BAu5xWBu7ZqOLy6IMg==, tarball: file:projects/arm-avs.tgz} name: '@rush-temp/arm-avs' version: 0.0.0 dependencies: @@ -12966,7 +12966,7 @@ packages: dev: false file:projects/arm-azureadexternalidentities.tgz: - resolution: {integrity: sha512-LSO8ioHR2deXO32OoeKJtyD4+LAxr5lSzbPpAE3gAHkn4sN9gemU9tYvW5pTDhlMcWHjUyqk4P/wlubGJaKxqw==, tarball: file:projects/arm-azureadexternalidentities.tgz} + resolution: {integrity: sha512-BYKKbMVbU+88JuAQUhqGjIertuNChW/vCrhNnxeeSisHeXMpIj4CnYxLeXoA1jPRC5Uq6OpaOVH3nUbQGarYsg==, tarball: file:projects/arm-azureadexternalidentities.tgz} name: '@rush-temp/arm-azureadexternalidentities' version: 0.0.0 dependencies: @@ -12991,7 +12991,7 @@ packages: dev: false file:projects/arm-azurestack.tgz: - resolution: {integrity: sha512-sYZ6Et9JUy/Jsy3xyBW2Et/ZPClAY7GP10LQyHPspDv+egbHy8KR6LCtzFP16ECrQ0nLR8Q0nTyfiv70POg0HA==, tarball: file:projects/arm-azurestack.tgz} + resolution: {integrity: sha512-PKDqhUPAmNuRNxbOxFn9WzrKIwQ5T1sKaeTq4FMexfmA3uFRZmrwb4Qw+Y5sW0KnnV5Ihx3fZFit37MsXaAlRg==, tarball: file:projects/arm-azurestack.tgz} name: '@rush-temp/arm-azurestack' version: 0.0.0 dependencies: @@ -13014,7 +13014,7 @@ packages: dev: false file:projects/arm-azurestackhci.tgz: - resolution: {integrity: sha512-kJjJM1hU0DhJ75wUkQJcSZWqOUJPortd1KrE4pNhk6vuED/VwAmgdfSzsfbgkuyEQTnRIYvT+fXy4UAWXmJ7vA==, tarball: file:projects/arm-azurestackhci.tgz} + resolution: {integrity: sha512-qRgOfVH3V3vN+9IhybvsUsu7ijr7YbytVGt6DtBUb4XJBCE20zu5A7Uw+G0QiU8mkfl2Qyh+QSw84hFpVo2mFQ==, tarball: file:projects/arm-azurestackhci.tgz} name: '@rush-temp/arm-azurestackhci' version: 0.0.0 dependencies: @@ -13041,7 +13041,7 @@ packages: dev: false file:projects/arm-baremetalinfrastructure.tgz: - resolution: {integrity: sha512-wHKiz6lpC8Qk6oxWY0tQByhZOeA4Dpl3hNH7XtH1ObLTQktQXOtLKbco53Ay58bGw1tBYsJLr331LqlZubEiCg==, tarball: file:projects/arm-baremetalinfrastructure.tgz} + resolution: {integrity: sha512-6G3GbWLuZovXfxfv7f8UEww7ZAhVDHOHh3/LuDJhQ6L9689VCCgms3xkRBON8fifwXZu8dwgFFia016OaAgbmQ==, tarball: file:projects/arm-baremetalinfrastructure.tgz} name: '@rush-temp/arm-baremetalinfrastructure' version: 0.0.0 dependencies: @@ -13067,7 +13067,7 @@ packages: dev: false file:projects/arm-batch.tgz: - resolution: {integrity: sha512-ngbWZV6a3NTsEP0ocVPtwt1PwW+bnv2IKhzA1X8F+9McxpLnTKGlRyqeJdjtRtRYyF8RhIJVs3kwePzDRBzuiQ==, tarball: file:projects/arm-batch.tgz} + resolution: {integrity: sha512-v9Q8fxtEjSwOP2KzCYgJimcg3m/P0K9MsGmOXubzE0zmsPTGtne98oyyw1D48/j5Tj43HXVewRrl9G6e4WT32w==, tarball: file:projects/arm-batch.tgz} name: '@rush-temp/arm-batch' version: 0.0.0 dependencies: @@ -13093,7 +13093,7 @@ packages: dev: false file:projects/arm-billing.tgz: - resolution: {integrity: sha512-cpL/vgRWRwhXEMWbC/YsUj7/BFhU9z95tgp58VesTaRc/yaJUq+xp84G6Zfxlnb0U1pVFbxJSvnKYktc71/9Bg==, tarball: file:projects/arm-billing.tgz} + resolution: {integrity: sha512-kbXfMcChjypYeTe2QmnLLdl80NqYBqWp3jw9dXF+ztMLBuWYPUAYcKj/rXtZzejq/872hPWmfUXnnjtbSx3NYw==, tarball: file:projects/arm-billing.tgz} name: '@rush-temp/arm-billing' version: 0.0.0 dependencies: @@ -13119,7 +13119,7 @@ packages: dev: false file:projects/arm-billingbenefits.tgz: - resolution: {integrity: sha512-na/HyLTsjC+jQwjyzGYgvgavQ8CCq7yKUv966tCnCS0BlYSExjPGtz+sJ43gIgmC89b+qOiwP4k2KkrUPumRjw==, tarball: file:projects/arm-billingbenefits.tgz} + resolution: {integrity: sha512-D32JK8ECiMkAM63TQKxXOT6fcT3X3GHizU7BWjDxSIvnM9a2uYkzWe2SYav75tIx/1BKo/50kt0E797m16DJHg==, tarball: file:projects/arm-billingbenefits.tgz} name: '@rush-temp/arm-billingbenefits' version: 0.0.0 dependencies: @@ -13144,7 +13144,7 @@ packages: dev: false file:projects/arm-botservice.tgz: - resolution: {integrity: sha512-dsaqyc8FEGfUXDAXBwhRNW5eYFErkTy+qJ4JGlPByS9F11gsaDkb0SbUmWTVWvpsuAiE+hCrz3SOlVAD1/SyQQ==, tarball: file:projects/arm-botservice.tgz} + resolution: {integrity: sha512-E6mpziixMK+8BWzXyRpgJz1sfxsd9gJmcR5MNQx7iTpEwW56lE/kwUiH5/m4jpI+2Qo3hoaEMz2aAWmkAnLC9g==, tarball: file:projects/arm-botservice.tgz} name: '@rush-temp/arm-botservice' version: 0.0.0 dependencies: @@ -13170,7 +13170,7 @@ packages: dev: false file:projects/arm-cdn.tgz: - resolution: {integrity: sha512-IwTYRDeixGbudArnOCWicv59RxNj0y0SoDbLFn5yRT54NBeNf+yVMeWMmWka+30fXp4LRFB0q4Is0jrFb5DTmA==, tarball: file:projects/arm-cdn.tgz} + resolution: {integrity: sha512-B1D7iLeqvOQXZ23cfCLmorc3zaNx8VYoBJ51JvjFDGePlqjZSrIqpAydFIcea6+Vq7KVztrAsprhOAVVyPpvpQ==, tarball: file:projects/arm-cdn.tgz} name: '@rush-temp/arm-cdn' version: 0.0.0 dependencies: @@ -13196,7 +13196,7 @@ packages: dev: false file:projects/arm-changeanalysis.tgz: - resolution: {integrity: sha512-GAcFodhNOY7d0rYRUhPKoN9AZq6Bxp6CkbtsEuBLbW259pcjWTtsz2PquiFhzhKCh53BeamckMEcTKTMut77KA==, tarball: file:projects/arm-changeanalysis.tgz} + resolution: {integrity: sha512-zOrdzN3s8Eiz/2GmEeTwJcjJovU8JvUlNQIFw3C6XiUnl4TG0WBZzsVFw4tfa6ZVvI8Qyh+j5oMYMy6UwzXmQA==, tarball: file:projects/arm-changeanalysis.tgz} name: '@rush-temp/arm-changeanalysis' version: 0.0.0 dependencies: @@ -13219,21 +13219,26 @@ packages: dev: false file:projects/arm-changes.tgz: - resolution: {integrity: sha512-uYeygj5O6eKY4E3BZxQa7CBNb/GnCDHn+5dMKJg3bVUmZ+YD0WkBCOvR+uPKX5Cl8QRLTpWrwF+sUMRVwnjmqw==, tarball: file:projects/arm-changes.tgz} + resolution: {integrity: sha512-lbMp5H2i3f5zN5uE2LIqDM7sVocOUTKs5hyzsI9QbdlaNDUIwwWUAj+eIkzwqNBGW9tayCPyIV3CvB1F1kXKMw==, tarball: file:projects/arm-changes.tgz} name: '@rush-temp/arm-changes' version: 0.0.0 dependencies: '@azure-tools/test-credential': 1.3.1 '@azure-tools/test-recorder': 3.5.2 + '@microsoft/api-extractor': 7.47.11(@types/node@18.19.60) '@types/chai': 4.3.20 '@types/mocha': 10.0.9 '@types/node': 18.19.60 chai: 4.3.10 cross-env: 7.0.3 + dotenv: 16.4.5 + mkdirp: 3.0.1 mocha: 10.7.3 - ts-node: 10.9.2(@types/node@18.19.60)(typescript@5.6.3) + rimraf: 5.0.10 + ts-node: 10.9.2(@types/node@18.19.60)(typescript@5.5.4) tslib: 2.8.0 - typescript: 5.6.3 + tsx: 4.19.2 + typescript: 5.5.4 uglify-js: 3.19.3 transitivePeerDependencies: - '@swc/core' @@ -13242,7 +13247,7 @@ packages: dev: false file:projects/arm-chaos.tgz: - resolution: {integrity: sha512-0rvdgEtFb5VpU9nsOb/AwiQQ/VsnO3iZtrGFq2V2XNIjCea0C97pSAOxVbDUXlVRxSsDm7no9GwbLhPheihL+g==, tarball: file:projects/arm-chaos.tgz} + resolution: {integrity: sha512-KvA6xuIKQNSeXS1dt8q2sh/xiiSiS9T9Uw6um7rDk/yQXWJzTJmEN2MUTfy6SkadWXSQ4C54RETb64UxpWCbow==, tarball: file:projects/arm-chaos.tgz} name: '@rush-temp/arm-chaos' version: 0.0.0 dependencies: @@ -13269,7 +13274,7 @@ packages: dev: false file:projects/arm-cognitiveservices.tgz: - resolution: {integrity: sha512-U0I0dgKA0Kyr2uaT3Nkl9c64HJvqGhNQqG6yKiQ//V0tcMF5fRSZmHPpdMLePPxl37G6DBL88rOKqqO6hqcOkw==, tarball: file:projects/arm-cognitiveservices.tgz} + resolution: {integrity: sha512-SJTIVi7cZ++J3yLqCWxqToG93GNYdJSe7bWiZT2grc2Bkfs+jnup4E82hz8ftmefnAzVkmbhDV17+acSi9Azww==, tarball: file:projects/arm-cognitiveservices.tgz} name: '@rush-temp/arm-cognitiveservices' version: 0.0.0 dependencies: @@ -13295,7 +13300,7 @@ packages: dev: false file:projects/arm-commerce-profile-2020-09-01-hybrid.tgz: - resolution: {integrity: sha512-+eJR1sDEXMLgYRcizEGZ+xIZP5y/2i4d64cgglRMeUopnGeC9DOGl5dfmNpIplG2rEuE1L1+hIG+sYnEldv6Yw==, tarball: file:projects/arm-commerce-profile-2020-09-01-hybrid.tgz} + resolution: {integrity: sha512-M4t3t6j9RkeK76HRscnqoVu5+e7aKLr4oJ4PCBxmbl9lACc0RICK4QdCE7q5YaCGzGXDOlzCNizi8V1Nyss4NQ==, tarball: file:projects/arm-commerce-profile-2020-09-01-hybrid.tgz} name: '@rush-temp/arm-commerce-profile-2020-09-01-hybrid' version: 0.0.0 dependencies: @@ -13319,7 +13324,7 @@ packages: dev: false file:projects/arm-commerce.tgz: - resolution: {integrity: sha512-aenkhgFTBdITuPZiljHHhL7kqn6M8At0DvWT//FhvOkQCQqeXq5bEGwqvaycL1plDNVXFJzD7H5gfXlKwc7yjg==, tarball: file:projects/arm-commerce.tgz} + resolution: {integrity: sha512-tdXtFr9sEU/XUNC7M/futnyhTGp68nX23qGZcfqs8UpJ6QJg4nWigEthAsBkEwr9cDVyos6YsQgEjqfZxECQhg==, tarball: file:projects/arm-commerce.tgz} name: '@rush-temp/arm-commerce' version: 0.0.0 dependencies: @@ -13342,7 +13347,7 @@ packages: dev: false file:projects/arm-commitmentplans.tgz: - resolution: {integrity: sha512-mAUGdTet7rh+x52kTVzJUr8Urnl0ICo+ybK9kVyXpcepgZvtLALzy5IMNWzJCMyh40HwxAw2xOWVyj3YRqjekg==, tarball: file:projects/arm-commitmentplans.tgz} + resolution: {integrity: sha512-wM/6H40GSdOLOwQhE3WVJlFeG2zKom0AW9JED7nm7kwahlwJsvXLcPelbec9G4y/O0F0WkUb1qkBlFNzjOyPcw==, tarball: file:projects/arm-commitmentplans.tgz} name: '@rush-temp/arm-commitmentplans' version: 0.0.0 dependencies: @@ -13365,7 +13370,7 @@ packages: dev: false file:projects/arm-communication.tgz: - resolution: {integrity: sha512-lCaKazaNRe0cWIvjCoLuGM8oldgC1NpcxouZQDaxruwd+XL1bPijqCeqO9kvW8rDFAqa88ZCI+oxOQ8PTNxo6g==, tarball: file:projects/arm-communication.tgz} + resolution: {integrity: sha512-jKYhoeQqipGWlqYlhr0SRv+uzw2UwJsiQN+3xzVGABK/70y0EZ8zcPYJOlq36Ua/z+xjbkl61dnEEkLTn8THpg==, tarball: file:projects/arm-communication.tgz} name: '@rush-temp/arm-communication' version: 0.0.0 dependencies: @@ -13391,7 +13396,7 @@ packages: dev: false file:projects/arm-compute-1.tgz: - resolution: {integrity: sha512-AFYxtCjlli3cKLYBcgSTu7RQLqeWiGoWqA7nktG0O0SupLUIW4WVPM9ssll0o/pcyIY4YoSb7NS5iV86TnDY5w==, tarball: file:projects/arm-compute-1.tgz} + resolution: {integrity: sha512-EyDbvSVJQdN5mTBE5SKq7vViQGeeRzLUvSrKTxV/oPldTQyvDWq64aTY86heyGwDFYh/kujsVsuwGSmCiIGDbA==, tarball: file:projects/arm-compute-1.tgz} name: '@rush-temp/arm-compute-1' version: 0.0.0 dependencies: @@ -13419,7 +13424,7 @@ packages: dev: false file:projects/arm-compute-profile-2020-09-01-hybrid.tgz: - resolution: {integrity: sha512-8HUiJcuebgNglTcSd3HnkQu45xrEOFzyxds/jtigYcLOcqB3ULvWJ6xekJXLOH7AvRPNBNROiH/a47zPmwpf6A==, tarball: file:projects/arm-compute-profile-2020-09-01-hybrid.tgz} + resolution: {integrity: sha512-Fl5Ukj0vZwymyY9tvWq9FgtW21B4WswQiC6RBYHkqhhtMQqk+acpH0umORt0cAXxpXxHkC5CqsgrnUUvifZn0Q==, tarball: file:projects/arm-compute-profile-2020-09-01-hybrid.tgz} name: '@rush-temp/arm-compute-profile-2020-09-01-hybrid' version: 0.0.0 dependencies: @@ -13489,7 +13494,7 @@ packages: dev: false file:projects/arm-computefleet.tgz: - resolution: {integrity: sha512-uX7CZEmbUHQEKVWvzk7I9zkFKMhlZnbDNbj9pQ/CR8+hvhAts/OUZFoKiu25n8YoyxH9iOTXiAqJzabEvAcMfg==, tarball: file:projects/arm-computefleet.tgz} + resolution: {integrity: sha512-6/T4PDvH2k2L4yVEAs/wyfYf8xhVHNvXNMlMFbDM+VxiLN37O2HI+uqTa6AGqx7qcPzRjyBZfTPAcUK8HI7G0A==, tarball: file:projects/arm-computefleet.tgz} name: '@rush-temp/arm-computefleet' version: 0.0.0 dependencies: @@ -13525,7 +13530,7 @@ packages: dev: false file:projects/arm-computeschedule.tgz: - resolution: {integrity: sha512-kQydbFDg9v7mEcbdz789oU+y/QD+PrWrszkjfctseMwEArveNWtV8lhRxV7pSREyvgJ6oDR/gQgRK9ch8nHWTg==, tarball: file:projects/arm-computeschedule.tgz} + resolution: {integrity: sha512-GgVAVrMUsXbo7MWQG9Ioi4dWOg1pNvhetLZpUXa92AyTgIK8WHuL3EqGpGjTy9HO1YYRC6v/YBho1KKF33vgUw==, tarball: file:projects/arm-computeschedule.tgz} name: '@rush-temp/arm-computeschedule' version: 0.0.0 dependencies: @@ -13562,7 +13567,7 @@ packages: dev: false file:projects/arm-confidentialledger.tgz: - resolution: {integrity: sha512-VVpYJGNvWHLV+IRgKs8NUiX7aWvmvliv7wcKPinYZBryp8u9yPLcw1kKKN7YjpsMUBxEM6DvshGAb/ix0MP0+A==, tarball: file:projects/arm-confidentialledger.tgz} + resolution: {integrity: sha512-F4z+LEXIo8zKzPWj8ahPy3J4KtWnMXCzc2r3IBCuiEjOg63RXdizCGxStC82ZwPQaX7CpmEQizwU4E2mgJrlgA==, tarball: file:projects/arm-confidentialledger.tgz} name: '@rush-temp/arm-confidentialledger' version: 0.0.0 dependencies: @@ -13589,7 +13594,7 @@ packages: dev: false file:projects/arm-confluent.tgz: - resolution: {integrity: sha512-Gw1OkTeP8gTkIm25kru8XLb/6ldvPbX48H+Wnh46nLEHxOOm/7UE+4Iiu7QopqcrTYCrfQRg3AbgAeMQRIoPKA==, tarball: file:projects/arm-confluent.tgz} + resolution: {integrity: sha512-YiupcSp0D4MRfgzc0L+diI2+TMR5E77csdZln1y/oXLxcm3Vra93fFRytsSBIsK7jlHm8iKeueu5UrQlb7CGJA==, tarball: file:projects/arm-confluent.tgz} name: '@rush-temp/arm-confluent' version: 0.0.0 dependencies: @@ -13615,7 +13620,7 @@ packages: dev: false file:projects/arm-connectedvmware.tgz: - resolution: {integrity: sha512-Yk3yxjx5lKrKGL4qWvqfI5lCaeocIjPpg5/hRHhKvqiTZ6wPrJGh1LgF9rc7hqGlkEjo0lLjTjdhMRoKCiod3A==, tarball: file:projects/arm-connectedvmware.tgz} + resolution: {integrity: sha512-qFfLv35xczGvQkzvxibYlmz1tSRIdNitu0K3g9J8OuiteNeelc92DvqfHn7t2j5S+ynbaJdoK1067f0pQbyDhA==, tarball: file:projects/arm-connectedvmware.tgz} name: '@rush-temp/arm-connectedvmware' version: 0.0.0 dependencies: @@ -13641,7 +13646,7 @@ packages: dev: false file:projects/arm-consumption.tgz: - resolution: {integrity: sha512-heYJ9NeAqRaIvbILc0r6hcuxQzd81HAGCOrNSmSc1MQv5IuUxg7MsiXvad+H4H6/NpswSMR3UWZlCSTmbqfzlg==, tarball: file:projects/arm-consumption.tgz} + resolution: {integrity: sha512-aW7DDv2DCKBSUrRVozuNijXGLdvKHFRdejyDbF6g2fu7IS8XGTJr+uHckjE88mK/SPev8GvyYLRJkG8tGk2BHg==, tarball: file:projects/arm-consumption.tgz} name: '@rush-temp/arm-consumption' version: 0.0.0 dependencies: @@ -13665,7 +13670,7 @@ packages: dev: false file:projects/arm-containerinstance.tgz: - resolution: {integrity: sha512-rQmNKnhKq8ieBAwtGrJejDNW/szDJXCv2YyEQ+y0NSaGw5VMs3qyz+SAc6Ee3OwQj9Wsz+4MgCfmFRPC0tQonQ==, tarball: file:projects/arm-containerinstance.tgz} + resolution: {integrity: sha512-Ck2Q7qwbsL3JyUaENSyYHLuJ/gT0yTVkVgV8d+Schjrh2Pruic58t5eIDrPq632BmTS5BmJfVfbZ0CO4HzNx7w==, tarball: file:projects/arm-containerinstance.tgz} name: '@rush-temp/arm-containerinstance' version: 0.0.0 dependencies: @@ -13691,7 +13696,7 @@ packages: dev: false file:projects/arm-containerorchestratorruntime.tgz: - resolution: {integrity: sha512-6mDLotsF4S9KDInSAWAVuQmOCqOgReU1i/IctXhh0abalQtssqfSFFd1wVa5FBsjZOnvHEasFh6Cc/EYOPjTqg==, tarball: file:projects/arm-containerorchestratorruntime.tgz} + resolution: {integrity: sha512-5SpApVxYGPizH4rRvkMlLK55bj9rkVVfoG5w5mBeB2uZX+mCY9g0g5j4gKf1g4rmbZ3HQgORWuE8TxmdLTdNHg==, tarball: file:projects/arm-containerorchestratorruntime.tgz} name: '@rush-temp/arm-containerorchestratorruntime' version: 0.0.0 dependencies: @@ -13727,7 +13732,7 @@ packages: dev: false file:projects/arm-containerregistry.tgz: - resolution: {integrity: sha512-JDr+5qTbEQ8epysusZfW23T7pxW0GMj9tKmCIioEIAZ4eDSHi3Xxcn96TizhsWKR1xLdY1tljfgrRIlM9CMuBA==, tarball: file:projects/arm-containerregistry.tgz} + resolution: {integrity: sha512-epVfOA1KABr2EAJ9n391wO3JLzjyiWxGHyJB7PrVrYxoySVx1hjEKmD9jPoHV2C4JfvplSwquOo35Q0T5Dbpcg==, tarball: file:projects/arm-containerregistry.tgz} name: '@rush-temp/arm-containerregistry' version: 0.0.0 dependencies: @@ -13753,7 +13758,7 @@ packages: dev: false file:projects/arm-containerservice-1.tgz: - resolution: {integrity: sha512-OzYrCZbTeVg23JVQg0S4HpI1wDoVmlMoEzHkzcwWPVgSe0vS+zb3134H/iQNwQf4947G7ey0Umfim9uByF3pEg==, tarball: file:projects/arm-containerservice-1.tgz} + resolution: {integrity: sha512-6Xq8ytwCKx1USsp1cTrHKt1RtwAqrMGjIBvEk4Wmjxub/+wLds/4/FRDMqA2la9bXeT9gBM80MBGHolGHgR6DA==, tarball: file:projects/arm-containerservice-1.tgz} name: '@rush-temp/arm-containerservice-1' version: 0.0.0 dependencies: @@ -13822,7 +13827,7 @@ packages: dev: false file:projects/arm-containerservicefleet.tgz: - resolution: {integrity: sha512-KCq2YZ77g9Zox8STQywVyLqzimQg13c9/7xMRo9+yZmf9x4EDxNZ2Q0CFpK6W4bhwERmmQwj1erO6hSJLaTQgQ==, tarball: file:projects/arm-containerservicefleet.tgz} + resolution: {integrity: sha512-rpY/sP1bJgk0Z0Wq8dx+oMT7/Y51AekFIk0mwzsRZi+o4kEkKp99ntc9ErVx8k05zHC0pPrQkHUHUslhuFgCXw==, tarball: file:projects/arm-containerservicefleet.tgz} name: '@rush-temp/arm-containerservicefleet' version: 0.0.0 dependencies: @@ -13848,7 +13853,7 @@ packages: dev: false file:projects/arm-cosmosdb.tgz: - resolution: {integrity: sha512-fXubMN+cHmmHXVNv1bgWUv5ZLSST0v2rrlyhh0CzxbzAuLhT4V04Vy9xRziizveGlXXgQQFd5HuheorTMtJChw==, tarball: file:projects/arm-cosmosdb.tgz} + resolution: {integrity: sha512-vPU3/m9btQ1ejwQGJfRkXyONfPZlXXA4qs3Sz/h6bdHJFvkatSxq0dcmdt1Natr7+anbvzX9uz1ttht5lneitA==, tarball: file:projects/arm-cosmosdb.tgz} name: '@rush-temp/arm-cosmosdb' version: 0.0.0 dependencies: @@ -13875,7 +13880,7 @@ packages: dev: false file:projects/arm-cosmosdbforpostgresql.tgz: - resolution: {integrity: sha512-ZujlFlvl6vWVWcOHHALoiEk9/G7CruvxcgMhd6TuIgvJgzRrC4R3oFE4V/9WhbCMTRe2nJKoG+SXASr0c379Kw==, tarball: file:projects/arm-cosmosdbforpostgresql.tgz} + resolution: {integrity: sha512-+hHiJgAVmIepfhjnWGPbgJwiuNwxSnOaUi25bHod+m4joHGhsuDj4Yv3EQAqQSbNCPhwkzR/IaC7SLpwca3cwg==, tarball: file:projects/arm-cosmosdbforpostgresql.tgz} name: '@rush-temp/arm-cosmosdbforpostgresql' version: 0.0.0 dependencies: @@ -13901,7 +13906,7 @@ packages: dev: false file:projects/arm-costmanagement.tgz: - resolution: {integrity: sha512-akrUuOjpCPtPROFXOGUV1nVew+IKl+Gt8Y1m+2QLqqRY08a6To/J5BZ3WjlNSCvYVc9wuX1ssIQrWLu8+dpoVg==, tarball: file:projects/arm-costmanagement.tgz} + resolution: {integrity: sha512-5yyIo4hl7BBDmlyf94LGoaux9TIRQ80eawWDddlyHBMk8UmLVJXbmfbmW/3E03Ygq924+K7i/jE6ajw9BsFzag==, tarball: file:projects/arm-costmanagement.tgz} name: '@rush-temp/arm-costmanagement' version: 0.0.0 dependencies: @@ -13927,7 +13932,7 @@ packages: dev: false file:projects/arm-customerinsights.tgz: - resolution: {integrity: sha512-xePnjbLCQ9+3BYMctgtxVB2trTbQ4SoQMwEl+c6+eCkWMRgYDdrRLPDFKHYpNdfYbqKAzU/d2Q/6yjGt6hVCNA==, tarball: file:projects/arm-customerinsights.tgz} + resolution: {integrity: sha512-bv/6ED6F/iG3Pa4NL9youOSf6G5q8QD9QaRykrcGF1ox6Ax0y/ZIM3Ev3fqFGFPbiLic6MSrjRN5BAMxTE6bpA==, tarball: file:projects/arm-customerinsights.tgz} name: '@rush-temp/arm-customerinsights' version: 0.0.0 dependencies: @@ -13952,7 +13957,7 @@ packages: dev: false file:projects/arm-dashboard.tgz: - resolution: {integrity: sha512-AQdEGMOmG+da3EgEHy1EDI6NlL3lOW/uQg+07iib2ogcNbXmKgyxQTXeVqgOy6+VNZ3SSLG7UH+zECieR6JzwA==, tarball: file:projects/arm-dashboard.tgz} + resolution: {integrity: sha512-dmz1HYYOvr4ZC5Ysnw37n6kapukUybwKH33yyTHvZabx5eHCE+Hhpz4WiY1ElumJPzuVbC3pniY5EP1zY3gzIg==, tarball: file:projects/arm-dashboard.tgz} name: '@rush-temp/arm-dashboard' version: 0.0.0 dependencies: @@ -13978,7 +13983,7 @@ packages: dev: false file:projects/arm-databoundaries.tgz: - resolution: {integrity: sha512-Fw6ijgZwAN7M320V/K8VLK3R8zO36Wu728GC3VZVcWMZJnkyCy8XypCKB2ciNooQOG72weEz3LYObsl8MPpfaQ==, tarball: file:projects/arm-databoundaries.tgz} + resolution: {integrity: sha512-H5W84QlB+ECWDZun3gushgb2q67T1CN3f3P0oGvsT5x90KMKbaY1Vd0bVysHu8+b8nFz1GIQnZmUKlf1VYdMOg==, tarball: file:projects/arm-databoundaries.tgz} name: '@rush-temp/arm-databoundaries' version: 0.0.0 dependencies: @@ -14006,7 +14011,7 @@ packages: dev: false file:projects/arm-databox.tgz: - resolution: {integrity: sha512-exRqOsMMt+ar0ORBYHzw0cPIpjfE5lBzlC7Oj4H1Sbck+cLM1eGLiQ5Cpan32uSJBRZkRhBZe7jju+TzMP9iAQ==, tarball: file:projects/arm-databox.tgz} + resolution: {integrity: sha512-Oleyq9Q4p4cOYYsJs2IX9IefNVElAuoT4H2goqcEyspaL/uckOF3fxo54P607/eislUZYUB13TaA8NvMJzsNtA==, tarball: file:projects/arm-databox.tgz} name: '@rush-temp/arm-databox' version: 0.0.0 dependencies: @@ -14032,7 +14037,7 @@ packages: dev: false file:projects/arm-databoxedge-profile-2020-09-01-hybrid.tgz: - resolution: {integrity: sha512-tEYl43XXqMVr2s2yLsKHa19mF2r7Y1QBWG6QKJ8tRehzavmPGTmBOIBOXpDB/nELo0zkZztavb8Ane3dKwihgw==, tarball: file:projects/arm-databoxedge-profile-2020-09-01-hybrid.tgz} + resolution: {integrity: sha512-+a0wKHDud7/j/UkTcmCWXALSXIG4d5mIO+Vt2MNKyTZQNjjNb25V/jrIm3tlIYPscrbw0c7s/1CbczqhQ+XCmA==, tarball: file:projects/arm-databoxedge-profile-2020-09-01-hybrid.tgz} name: '@rush-temp/arm-databoxedge-profile-2020-09-01-hybrid' version: 0.0.0 dependencies: @@ -14058,7 +14063,7 @@ packages: dev: false file:projects/arm-databoxedge.tgz: - resolution: {integrity: sha512-xCOaEU2ZFqEhkEwRZ42r9gM9Iv9hyIa9FHg7MEHRZquaRfDukFbCJRLxvwKT87pPTtAMGc0X5JegLlsOZbegIA==, tarball: file:projects/arm-databoxedge.tgz} + resolution: {integrity: sha512-hklsnbImVYbAwHmZ9w33g76eutT4b3br4b+wancIPP3bXV0HsyHDoTpuBKlGWslVhqDj5ADG57Kg8oB0S1/1nA==, tarball: file:projects/arm-databoxedge.tgz} name: '@rush-temp/arm-databoxedge' version: 0.0.0 dependencies: @@ -14083,7 +14088,7 @@ packages: dev: false file:projects/arm-databricks.tgz: - resolution: {integrity: sha512-DN+/lKwXgrZ8KeFjSa+AfeP/4lIsGQTgnG+4juHlGOOVwS9Ic8Z+WGsNNvDGggE11W5IvVNi5oUQisk9XyJSbg==, tarball: file:projects/arm-databricks.tgz} + resolution: {integrity: sha512-HaKboUqaNNK8l5PkpesNKOSm43yjQKTyBOQgPaAlgBWBcj/km24VUEcq6i5VLAO5kg+4eBH9eKmvfmo97gT0XA==, tarball: file:projects/arm-databricks.tgz} name: '@rush-temp/arm-databricks' version: 0.0.0 dependencies: @@ -14109,7 +14114,7 @@ packages: dev: false file:projects/arm-datacatalog.tgz: - resolution: {integrity: sha512-w5gUGsRg7Dj/fBmdjYVBrOSxfi3OvqZN8b7nM3C6wmHak0iu5bQd8ajLp83u9PdOt5tM4Bqo+J7S3bE9JpHPtg==, tarball: file:projects/arm-datacatalog.tgz} + resolution: {integrity: sha512-3qVfQgCivUWmCKDUJAqahdetJjol50kQci7GOoee7xcEVGYHpHsOOu5Ny16x8kqInz42DWCKfImFaibuCnGI2g==, tarball: file:projects/arm-datacatalog.tgz} name: '@rush-temp/arm-datacatalog' version: 0.0.0 dependencies: @@ -14134,7 +14139,7 @@ packages: dev: false file:projects/arm-datadog.tgz: - resolution: {integrity: sha512-EpepUwoEcTd4ksglMi/gGRQW5PriNl1pyyDmK8/mRr5Br1BvQQ980ZK/ZrQ/gNkYmbC5nUvKR8obRBNVhdxZHA==, tarball: file:projects/arm-datadog.tgz} + resolution: {integrity: sha512-7wggYtrecQFGat0Sp9AQz4nShdxM2uOz2+OkBhsYWlaE6V6cube9yCoLDoE8qg82EolJW6W+ecycnM/gM8qZ6w==, tarball: file:projects/arm-datadog.tgz} name: '@rush-temp/arm-datadog' version: 0.0.0 dependencies: @@ -14160,7 +14165,7 @@ packages: dev: false file:projects/arm-datafactory.tgz: - resolution: {integrity: sha512-GV31SN2dYrSXT7cQ8SkmUVnpepXIAB8tiiU14zVaDJ0Yr/twIVsGNEh+xTUG/Pb6+e+LQhqb4Cj2qlTu99opsg==, tarball: file:projects/arm-datafactory.tgz} + resolution: {integrity: sha512-HyPMuF1T6YwYrc0t4+wvw5Qkx9PBCdQb60do339v1auVP6a6Z8alTShtKme26j92YB1YJiUP180hmpv731zBJA==, tarball: file:projects/arm-datafactory.tgz} name: '@rush-temp/arm-datafactory' version: 0.0.0 dependencies: @@ -14186,7 +14191,7 @@ packages: dev: false file:projects/arm-datalake-analytics.tgz: - resolution: {integrity: sha512-TfId9nj9jRG9LFDrejrJeHbfeKKDQ4kgODGKdypXdROGPPSDtP0yOS+5AzhJ4/Pw4X3bXVKKzBoesAy23jv6aQ==, tarball: file:projects/arm-datalake-analytics.tgz} + resolution: {integrity: sha512-YTRWL+hpnRnL9tOYpQS3onkAP97XVwRCT6IzckUdb3mBGaYKPhfWFuf1LCdMBbis5yAxZuYFa9XjvuLnwBCZpA==, tarball: file:projects/arm-datalake-analytics.tgz} name: '@rush-temp/arm-datalake-analytics' version: 0.0.0 dependencies: @@ -14211,7 +14216,7 @@ packages: dev: false file:projects/arm-datamigration.tgz: - resolution: {integrity: sha512-mhVFla2EgRzMBzMmZzGYkgsEMqd+I1Zt2c/m7RWOW8eg+Th54LVKAKchrHF2BH265LxQM0RSrRvmn5BGLvBt0w==, tarball: file:projects/arm-datamigration.tgz} + resolution: {integrity: sha512-Vhhso6gS3a9+f+wT1DZlpbkl5pNZBKaEkMDwTeNi4X6jeN4YjAP7aBdRLw2Wh6+gjxqHidWNefzBvEJ4XaXBeQ==, tarball: file:projects/arm-datamigration.tgz} name: '@rush-temp/arm-datamigration' version: 0.0.0 dependencies: @@ -14236,7 +14241,7 @@ packages: dev: false file:projects/arm-dataprotection.tgz: - resolution: {integrity: sha512-+3aXNjkCpHL0thFCdXc27eg7SEVX2W++2p3SPVayMQUFtWgNU+PWcNQG8Lw8kFaTujXm8An/ng42HrnG61Ajbw==, tarball: file:projects/arm-dataprotection.tgz} + resolution: {integrity: sha512-kzJLG2wRufykSFrLgGX25aIgN7yeqBHLd+06xIK7s/XuCsEnw150GC7ZB5/cDfefDfrXFhBW9MsG5AaDgNxpRQ==, tarball: file:projects/arm-dataprotection.tgz} name: '@rush-temp/arm-dataprotection' version: 0.0.0 dependencies: @@ -14263,7 +14268,7 @@ packages: dev: false file:projects/arm-defendereasm.tgz: - resolution: {integrity: sha512-Ietz+STPzdP+lx5jnBQhjGTPDxo5lNO49cH+fCHtX5FHHaLGhDSeWg9SLwZMiaogBVSiz/5nmc3vrDq4Xx7f1g==, tarball: file:projects/arm-defendereasm.tgz} + resolution: {integrity: sha512-EtUFPyiaTbRLUGng8f1udWzoTDL/pgircC4G69d2/+La2fM2k81SxdMZed3Hw8EXUDGLmKyEklNhJtfbvUvlGg==, tarball: file:projects/arm-defendereasm.tgz} name: '@rush-temp/arm-defendereasm' version: 0.0.0 dependencies: @@ -14289,7 +14294,7 @@ packages: dev: false file:projects/arm-deploymentmanager.tgz: - resolution: {integrity: sha512-EoiUdt9CXVDXmmVS7wgVq1eRgegyVRqOrd4qeXZAtpOfqjE/RxASzamLB9ewK8WHIueYjRwQmh0HIYsXIjoKrg==, tarball: file:projects/arm-deploymentmanager.tgz} + resolution: {integrity: sha512-cWbeTdxB59tylz84zzFp//lZqEuTcBmCmw5TS++yAh4aWf8drqcr8KkATIeu7wSOhpQ9Kn/ucPjSEuOst1Yteg==, tarball: file:projects/arm-deploymentmanager.tgz} name: '@rush-temp/arm-deploymentmanager' version: 0.0.0 dependencies: @@ -14314,7 +14319,7 @@ packages: dev: false file:projects/arm-desktopvirtualization.tgz: - resolution: {integrity: sha512-bpqAcmaSX5REYTLTQkgRoqKGON/KoYz0GF6HJ85MhfiIDbh/QeaheLCuzCCSVl/C0sZ33aqZAYEZvJ9l3Ow30Q==, tarball: file:projects/arm-desktopvirtualization.tgz} + resolution: {integrity: sha512-J7dBtyuLBJaRel5iVqy0AKdRHak7eUDhELulS4O2j149YyF1VwzIiXcypImo6LyH0G1/4O+YkDxSXnBBdr8Ikg==, tarball: file:projects/arm-desktopvirtualization.tgz} name: '@rush-temp/arm-desktopvirtualization' version: 0.0.0 dependencies: @@ -14338,7 +14343,7 @@ packages: dev: false file:projects/arm-devcenter.tgz: - resolution: {integrity: sha512-yixLTL05L88V9hzJLOvKXR6eJzgHycfLFZO+Pb16wMZzgCNn5xdCbgYHSWQFV+hy2FNx1QmKOAubICZEjvTS7Q==, tarball: file:projects/arm-devcenter.tgz} + resolution: {integrity: sha512-gWVnO/1N0mR6ds03MaOXqdeFgjSg50amFaU7kZs+deLe7A0hF0cTf70fn57ctrHzilwd/NY01t44gUVd4t3r5w==, tarball: file:projects/arm-devcenter.tgz} name: '@rush-temp/arm-devcenter' version: 0.0.0 dependencies: @@ -14365,7 +14370,7 @@ packages: dev: false file:projects/arm-devhub.tgz: - resolution: {integrity: sha512-LuLFE1vKh5qQlAumLaDVqEcwoi2y2ctthYpEjL+uVLMg2B/WsBxhCeHA+/RN4PpfxoL1Tzp5NS0kglLi6Qi4BQ==, tarball: file:projects/arm-devhub.tgz} + resolution: {integrity: sha512-HOIu/J28QEzt/DEcbP57QDFZdkFprq0ms2d88J2DuxlvTgIIPab4pYCAhy/X0RPizMm72optu5JZoW+kSgwYaw==, tarball: file:projects/arm-devhub.tgz} name: '@rush-temp/arm-devhub' version: 0.0.0 dependencies: @@ -14389,7 +14394,7 @@ packages: dev: false file:projects/arm-deviceprovisioningservices.tgz: - resolution: {integrity: sha512-tjbUbWfCzt+yYUQZcLWakrSPrZNlcP/9v0Rk6nWcp0I8MwXPyK1j7yuNxgDd50RJ9rAKf+6VytM7vRekBfr63w==, tarball: file:projects/arm-deviceprovisioningservices.tgz} + resolution: {integrity: sha512-tsOGB1OX7JIPF9MjF8Vpn2daqfjkqo54WPDhzMgeTEGbgK0fS0mbjfbQJfPOdwtFosQnJ64rcDmQ86rNjwq3Cg==, tarball: file:projects/arm-deviceprovisioningservices.tgz} name: '@rush-temp/arm-deviceprovisioningservices' version: 0.0.0 dependencies: @@ -14415,7 +14420,7 @@ packages: dev: false file:projects/arm-deviceregistry.tgz: - resolution: {integrity: sha512-wlepiayi4r5il5osi3FZv4UZq8g28s5m0+KuDt970CO5uVxrvLI8CKIHGmq3A/E2HmOYDRoRaowd8sARQbvGtg==, tarball: file:projects/arm-deviceregistry.tgz} + resolution: {integrity: sha512-z8u3uJYdM7ASzu9gFYGbJENC1xkk1hMCsuZYyVMntIYW21n3yxzJ47mtVgZNsFX3IbVFMaG7RcUzuSZJMG/dDg==, tarball: file:projects/arm-deviceregistry.tgz} name: '@rush-temp/arm-deviceregistry' version: 0.0.0 dependencies: @@ -14442,7 +14447,7 @@ packages: dev: false file:projects/arm-deviceupdate.tgz: - resolution: {integrity: sha512-4LxwFqb1hzysBzrXF4GyhU4w6b8Tebt1wolR06XpNIZzAS8B/WM7dOh4ijCq9InGAuOqBIAvGU8ENYkuQ/qnDQ==, tarball: file:projects/arm-deviceupdate.tgz} + resolution: {integrity: sha512-VnwlFErT14tR8URqd9JPnge6Y3+N+eT7UsQFxdsjmpGuiERbTYEv8awkqqmdzxRLaeE+Az0PwJqFRIrDwEHpzQ==, tarball: file:projects/arm-deviceupdate.tgz} name: '@rush-temp/arm-deviceupdate' version: 0.0.0 dependencies: @@ -14468,7 +14473,7 @@ packages: dev: false file:projects/arm-devopsinfrastructure.tgz: - resolution: {integrity: sha512-OD6kRNajYQKuUMwOKIJf2qpWMTCGy818ZS06WglOQVRLvYjIU4vFM1CEAjfTz0snRCrGARtbfIW69onvWuhRLg==, tarball: file:projects/arm-devopsinfrastructure.tgz} + resolution: {integrity: sha512-BzXD0zjoyGtNCDMjRegLOCYsnEO420+/OteTxfUmSZyFymG0eI1e6KPyQbNN2bY9/KV5VcJ3HVkzOoTu7HG5kw==, tarball: file:projects/arm-devopsinfrastructure.tgz} name: '@rush-temp/arm-devopsinfrastructure' version: 0.0.0 dependencies: @@ -14495,7 +14500,7 @@ packages: dev: false file:projects/arm-devspaces.tgz: - resolution: {integrity: sha512-quL/EVvX8ImhbcJ8hZuqyOhPxVeY2B4c9meOIu8cuUbcc66beVB7VplG5sxWEMzbUytbRQxIQ5HhAMUnIEsGZg==, tarball: file:projects/arm-devspaces.tgz} + resolution: {integrity: sha512-2rqeUPXzFCoBouHJB4VYtcumzq1zLhld0YO9b8Um3sSWurcjv3fiUWSX7jrGW8yTy7dA7UDbQbTt8FCM6F0Ogg==, tarball: file:projects/arm-devspaces.tgz} name: '@rush-temp/arm-devspaces' version: 0.0.0 dependencies: @@ -14520,7 +14525,7 @@ packages: dev: false file:projects/arm-devtestlabs.tgz: - resolution: {integrity: sha512-dV9fBoK/yxBwGUW8dROdrDqS/4acNjSWwo36SDQkyf9jiGUKMVoMAMYcx77i+2UYuEiIdyelS63eqCWH3stgNg==, tarball: file:projects/arm-devtestlabs.tgz} + resolution: {integrity: sha512-xeWuGUZiHvK+yiYtApelQcnqa2WoqqxKmFUb45cBB4nXEf/OpiGxWvjJ6zc0Eqp1+DGIWKd2US1q29mJaZUR9g==, tarball: file:projects/arm-devtestlabs.tgz} name: '@rush-temp/arm-devtestlabs' version: 0.0.0 dependencies: @@ -14545,7 +14550,7 @@ packages: dev: false file:projects/arm-digitaltwins.tgz: - resolution: {integrity: sha512-uFNrJH1ekOc8Hfz4Fl0EV9wwUGfSZyP12Jf5kPyoFbnmRKrFT493rUrsnaCOLo1M2ScvUt+2EJsIRcEBfg+n8w==, tarball: file:projects/arm-digitaltwins.tgz} + resolution: {integrity: sha512-qhLmPt/1/wZeKvrU1PheiwAG7CU5QCvSBmRcXbwJdeeuZrPODjMk9HmE/LTvcgEJKNqr8eAOoLB09cVhLHoM1g==, tarball: file:projects/arm-digitaltwins.tgz} name: '@rush-temp/arm-digitaltwins' version: 0.0.0 dependencies: @@ -14571,7 +14576,7 @@ packages: dev: false file:projects/arm-dns-profile-2020-09-01-hybrid.tgz: - resolution: {integrity: sha512-m0uI2Tt4fHKDqaIONK+muCX1g6LLzCDAVLV8ZyAz84v4RFibDRyZRlJ7k6lZ+QndWJ67j6dUOn0k1Z7ItqXwAg==, tarball: file:projects/arm-dns-profile-2020-09-01-hybrid.tgz} + resolution: {integrity: sha512-vn9RV5nrl6trrsK3DKu/JJIhtvfimxmPhV20bWODqRAG/Kbn0/TYq/agBiUYI8M9jXz4r4uQvnk902YxvF90/Q==, tarball: file:projects/arm-dns-profile-2020-09-01-hybrid.tgz} name: '@rush-temp/arm-dns-profile-2020-09-01-hybrid' version: 0.0.0 dependencies: @@ -14597,7 +14602,7 @@ packages: dev: false file:projects/arm-dns.tgz: - resolution: {integrity: sha512-FP3+m6UVBiNg87XItEXkp8blZXIAtGSZ2etA2J9taiBdYL0rqCQQgfgxoD4sU5K8OKH6+wi5X/0PZeQH+Wenvw==, tarball: file:projects/arm-dns.tgz} + resolution: {integrity: sha512-VckMdXZK3L+SoQ6hyaDOGeI+ahPL/Dg25YJzDmskjgpbJKFLRPXioJ3jBjfGtjOIGe1gQEyAqM+j7th6JUSEfA==, tarball: file:projects/arm-dns.tgz} name: '@rush-temp/arm-dns' version: 0.0.0 dependencies: @@ -14623,7 +14628,7 @@ packages: dev: false file:projects/arm-dnsresolver.tgz: - resolution: {integrity: sha512-F4rdV9I2V9l77Eael5xYcrnWVxZetub79CO/uSVk4dfuax9wWkyZcTB74eqUWBOAJxv9lZ+y9Vnag59RHEHk/Q==, tarball: file:projects/arm-dnsresolver.tgz} + resolution: {integrity: sha512-ysqzfcxdOJi8Ly9WPK17fa8JSYmOh7euY8xUgARPtB+lzJkRc2s4vXH2hlfjZZUFYclW5t2peQojxxxFrHIHTQ==, tarball: file:projects/arm-dnsresolver.tgz} name: '@rush-temp/arm-dnsresolver' version: 0.0.0 dependencies: @@ -14649,7 +14654,7 @@ packages: dev: false file:projects/arm-domainservices.tgz: - resolution: {integrity: sha512-nHRICNhfLt4Y00OpGxhUxDkHP1IclHX6kPiDXWtqDzKUqye3rwjiYACkWnLY1J0wvJAJG7eYTjzukxrSHj2JBg==, tarball: file:projects/arm-domainservices.tgz} + resolution: {integrity: sha512-A3oe1D1kMU0ydwkMBYKWTWsZL7R+6kyEkzNigjmF6ZZHda9bxQUnpQIlCVOtzII0otyzt11BDhm7b+tIVpTyzQ==, tarball: file:projects/arm-domainservices.tgz} name: '@rush-temp/arm-domainservices' version: 0.0.0 dependencies: @@ -14674,7 +14679,7 @@ packages: dev: false file:projects/arm-dynatrace.tgz: - resolution: {integrity: sha512-Vrco3iQfEiGOYDhAWmFmg33flTPkk5o58TDI/J6i10xb/evoyw7mP8LhkEaum14h0Jia2KuIde3naYlEhUj7bg==, tarball: file:projects/arm-dynatrace.tgz} + resolution: {integrity: sha512-LwY7ny4FITo+KcgN/GLZIeLNGbTB7Ck9ueXeaREfb0W86X3KReSEg/Wms2oSr04OFPCzu2Qr6WeQM4/8EdLycQ==, tarball: file:projects/arm-dynatrace.tgz} name: '@rush-temp/arm-dynatrace' version: 0.0.0 dependencies: @@ -14737,7 +14742,7 @@ packages: dev: false file:projects/arm-education.tgz: - resolution: {integrity: sha512-72b39+p7fq2kpgX3GTvEpVdx6l7FRz0ZOcvTGpTH3rJZspZ+oosFNZlnNgedPzRIRvS0Mel/FGlHieUXIJF4zg==, tarball: file:projects/arm-education.tgz} + resolution: {integrity: sha512-HC1KSD65EGYMPgscAAm4kKI8yCerZ1tqnGfOyfnxk5m2ePVPX/cuAuw8Ral6HUZAXYzeOJsfPKKL/VLrVBCdPA==, tarball: file:projects/arm-education.tgz} name: '@rush-temp/arm-education' version: 0.0.0 dependencies: @@ -14761,7 +14766,7 @@ packages: dev: false file:projects/arm-elastic.tgz: - resolution: {integrity: sha512-t1V8IKPwH+aeIVNXCsVlper38gUfU/w3+YmmR23PUnDVnDK8eedVunJ66WffZ2BC44C5JlvmIRkfCpMqnWkW7A==, tarball: file:projects/arm-elastic.tgz} + resolution: {integrity: sha512-BrvDbvQD/8iDMx33VyzrHSCTKCrH7ibAOv6mlX/+O8uJ3s43V9cSZFu1cGJ3Y36ErQ0Q8Jc46zR1BD/b+G3+SQ==, tarball: file:projects/arm-elastic.tgz} name: '@rush-temp/arm-elastic' version: 0.0.0 dependencies: @@ -14787,7 +14792,7 @@ packages: dev: false file:projects/arm-elasticsan.tgz: - resolution: {integrity: sha512-5/gwmooleUnum1LJ7BaIOssENX8rSEtb6cy1TK3nh1CCzNlXIH+G5QF16/KPT4+OH6+WdAwLjrATGxX/caI6gg==, tarball: file:projects/arm-elasticsan.tgz} + resolution: {integrity: sha512-Bbkdnz3Rh4Rez5Pzc8ftLHpqRQcE9R7HCRuk9lxt02NkfBbcNUM7C6RRHQ7hPH959eWvs/O0XHUkBa7/E1XZzw==, tarball: file:projects/arm-elasticsan.tgz} name: '@rush-temp/arm-elasticsan' version: 0.0.0 dependencies: @@ -14813,7 +14818,7 @@ packages: dev: false file:projects/arm-eventgrid.tgz: - resolution: {integrity: sha512-nQ9OFFSQr8Y0zBulAwx7Uiv5DkMemz2tgN482N3mVTLK07/ojxGCBiw5dxKqzRYBUoHdskuq6X1j10WNkuAUGg==, tarball: file:projects/arm-eventgrid.tgz} + resolution: {integrity: sha512-bOPt5dhRosxDLe6MX4X9mQSALITfe/ntzfvud65lg5tyCca97ZSJbv+s4OmpbnaeopeaB0G1N3W14jVkL2cg3g==, tarball: file:projects/arm-eventgrid.tgz} name: '@rush-temp/arm-eventgrid' version: 0.0.0 dependencies: @@ -14839,7 +14844,7 @@ packages: dev: false file:projects/arm-eventhub-profile-2020-09-01-hybrid.tgz: - resolution: {integrity: sha512-uDMOFCz/yyRKM3En5Njmhl9KPAYNSWlaoLI10VE/4JNy1dy7NIbBEER5cWsXrbZVwi4xqZpmsJ0v0oRmyMUcVQ==, tarball: file:projects/arm-eventhub-profile-2020-09-01-hybrid.tgz} + resolution: {integrity: sha512-oOJSQwse4hZoLCQY8ZrfTSQKTXWa7jYhT2WlEvM1W4esOaI9LAmhPwTlVykj5QiQos+KNz6mj2EP/vbVtuhyzQ==, tarball: file:projects/arm-eventhub-profile-2020-09-01-hybrid.tgz} name: '@rush-temp/arm-eventhub-profile-2020-09-01-hybrid' version: 0.0.0 dependencies: @@ -14865,7 +14870,7 @@ packages: dev: false file:projects/arm-eventhub.tgz: - resolution: {integrity: sha512-h7qwEeLrf3Vi+BdVP7Wu6eWrsF7xWT/pGfZY8tkr1llTGjVHCEMvvpNmxm9FseP275DDti1gaqNHeUoLVIVqmw==, tarball: file:projects/arm-eventhub.tgz} + resolution: {integrity: sha512-WTQzTHIIk1s5sbZcmi9mpKL2G8Ux2cd/Yl5OphTfoTtzMR5iTkVrSmYtgI75kUcldeIIHicG3TzoiLHRmKUrww==, tarball: file:projects/arm-eventhub.tgz} name: '@rush-temp/arm-eventhub' version: 0.0.0 dependencies: @@ -14893,7 +14898,7 @@ packages: dev: false file:projects/arm-extendedlocation.tgz: - resolution: {integrity: sha512-pxjAvPz/lhVqIWzO2UD7AxCzkQtgn4eAYs8mgs1yfGSA3vUt5CsU9uCjnaPXVrm7PBYy+7A7ySv7Ui7QHNefmw==, tarball: file:projects/arm-extendedlocation.tgz} + resolution: {integrity: sha512-MKsK25VGXrjMGop39herMgQQr/SCKf7YkIMpr8WiurbVdDT+b8KSeIfOHZdKdyQcKsdalA2QWSMW8zma0n2AHw==, tarball: file:projects/arm-extendedlocation.tgz} name: '@rush-temp/arm-extendedlocation' version: 0.0.0 dependencies: @@ -14919,7 +14924,7 @@ packages: dev: false file:projects/arm-fabric.tgz: - resolution: {integrity: sha512-DWfFgqHfgTiuH3NNu60qsQbVvXs1fKragfniZrJLTdbpqS+qbT6vpDjhYG/kuLN/FmX8ls89FAUd6T+etr8Hpg==, tarball: file:projects/arm-fabric.tgz} + resolution: {integrity: sha512-SFH1vDEKPQWOWsgrtk66s3+ZPKzVKFLD1961AAe/XLzHP6vNizf6JyCAOpS3Xh4/os4CeocBa9vT+CgA9UQBZg==, tarball: file:projects/arm-fabric.tgz} name: '@rush-temp/arm-fabric' version: 0.0.0 dependencies: @@ -14956,21 +14961,26 @@ packages: dev: false file:projects/arm-features.tgz: - resolution: {integrity: sha512-WkYvbOooJBmm2zjqxIgp6tQyXWeDK1GI66QEd5KPUwckAVwmEXf2EztcuvYmWA1hl7puJebr8DKMBPpMfk2V2Q==, tarball: file:projects/arm-features.tgz} + resolution: {integrity: sha512-ECpdBldGyV6DEzvzDHIzL5UwcTFQ5vDbuhkSy3eiQ22sPNXTLFw6NY0BBgrDHvDsY0rJtqGlyvogNdSV32xBPw==, tarball: file:projects/arm-features.tgz} name: '@rush-temp/arm-features' version: 0.0.0 dependencies: '@azure-tools/test-credential': 1.3.1 '@azure-tools/test-recorder': 3.5.2 + '@microsoft/api-extractor': 7.47.11(@types/node@18.19.60) '@types/chai': 4.3.20 '@types/mocha': 10.0.9 '@types/node': 18.19.60 chai: 4.3.10 cross-env: 7.0.3 + dotenv: 16.4.5 + mkdirp: 3.0.1 mocha: 10.7.3 - ts-node: 10.9.2(@types/node@18.19.60)(typescript@5.6.3) + rimraf: 5.0.10 + ts-node: 10.9.2(@types/node@18.19.60)(typescript@5.5.4) tslib: 2.8.0 - typescript: 5.6.3 + tsx: 4.19.2 + typescript: 5.5.4 uglify-js: 3.19.3 transitivePeerDependencies: - '@swc/core' @@ -14979,7 +14989,7 @@ packages: dev: false file:projects/arm-fluidrelay.tgz: - resolution: {integrity: sha512-AJ1n1Aiin9rJk1vPKepFKCdzYlsUXt7cI24Q8OMGBrdorOnONF0Ipy87q1wzLIjCeaxqMQVnxhG7p1HJGhfimA==, tarball: file:projects/arm-fluidrelay.tgz} + resolution: {integrity: sha512-ld9+tzYYZsZc2rJsK4cwlnQDQnbDXnU37XA75fWJYF2763KLphKptJdIcTjkqhyRhB+tNg3QfIiCLph0gPRyqw==, tarball: file:projects/arm-fluidrelay.tgz} name: '@rush-temp/arm-fluidrelay' version: 0.0.0 dependencies: @@ -15003,7 +15013,7 @@ packages: dev: false file:projects/arm-frontdoor.tgz: - resolution: {integrity: sha512-jOgqLlJUlAQ18Upd1FHbbH6fvbf1J5HYtIq6baoQu45YMNmBgL7i1+f7+PKt8XikD0o+NCpvxQD7NlOFbP/LaA==, tarball: file:projects/arm-frontdoor.tgz} + resolution: {integrity: sha512-c888etqkCX9LaonYiRixkyYL+bs3d7EoBIRuxptrOLSlzxTt0HoSWfF4bfYtNd9WEkPhr0mbzc8OnFYap1yxTw==, tarball: file:projects/arm-frontdoor.tgz} name: '@rush-temp/arm-frontdoor' version: 0.0.0 dependencies: @@ -15029,7 +15039,7 @@ packages: dev: false file:projects/arm-graphservices.tgz: - resolution: {integrity: sha512-M49+qyEQa05xJ7p+BF6CASKoU52eepD5q/5CA4kLVCsaI3YH6pNNRpnTWeg+Tzud3wS51OYHzSl3yPOjdB9lDw==, tarball: file:projects/arm-graphservices.tgz} + resolution: {integrity: sha512-c8C87E5zsfnICYh26xa+e73n9a21IB62rmY4cvdAXBem/MMf5xT7/OZFsEbeOLEA+uzqQKH7kXeScqM4tveCBw==, tarball: file:projects/arm-graphservices.tgz} name: '@rush-temp/arm-graphservices' version: 0.0.0 dependencies: @@ -15055,7 +15065,7 @@ packages: dev: false file:projects/arm-guestconfiguration.tgz: - resolution: {integrity: sha512-e0nhI+e3ePkZ90jyI74+L5ibTh0MCODDu8joRmlnq6y7jbpSzXettLhYoj4jRFYgvurI3KbSP8Phq5CeRm8YHw==, tarball: file:projects/arm-guestconfiguration.tgz} + resolution: {integrity: sha512-T0K04rfh+nioShzvtQyV+wiECPVTnxaDMBRTSt8Voe2NoOONl9QNUAGC7agxZRH2HDK/r2KqJLbZtlmjvAVtvA==, tarball: file:projects/arm-guestconfiguration.tgz} name: '@rush-temp/arm-guestconfiguration' version: 0.0.0 dependencies: @@ -15080,7 +15090,7 @@ packages: dev: false file:projects/arm-hanaonazure.tgz: - resolution: {integrity: sha512-ax2ILiEK6jQm4sFJzD5WN7DgKk5QTtAJQpSuYVDL7ed1sLe29AiH7hxk3aJxL5LpRNi3LOxrTzGsqwdFFX1/Fg==, tarball: file:projects/arm-hanaonazure.tgz} + resolution: {integrity: sha512-ELBfID/5uG3UfsUGaS6X2vwcaWn/GGKu3jXV+DUodiPq9mi6Z06xmyz7NjjKfDUVzV0PfxVoL87TDH3tHsacuA==, tarball: file:projects/arm-hanaonazure.tgz} name: '@rush-temp/arm-hanaonazure' version: 0.0.0 dependencies: @@ -15105,7 +15115,7 @@ packages: dev: false file:projects/arm-hardwaresecuritymodules.tgz: - resolution: {integrity: sha512-Fx3HE9uTX1vPDU+iOpdKgiDv7nVUkR5Xq8TsdZVd5sYg/G8a0nH5C4FnCytj2GKKOKyJcF4fX6nqxaOL8U1E4A==, tarball: file:projects/arm-hardwaresecuritymodules.tgz} + resolution: {integrity: sha512-cHEVKirem7eaYedXd3XuHTENJI95EQEM5bQpjTb4KsUXAC/afh09tupuyDXVgSkysIME1Ax+WD8BjVV+35KpXg==, tarball: file:projects/arm-hardwaresecuritymodules.tgz} name: '@rush-temp/arm-hardwaresecuritymodules' version: 0.0.0 dependencies: @@ -15131,7 +15141,7 @@ packages: dev: false file:projects/arm-hdinsight.tgz: - resolution: {integrity: sha512-KF24Mn8kpwPhpTxVl90EGTUVASDOqTaKoKLJt9RyTRHW4mVklQGjRVhpT0/XAxu12gErs49OJU19Lj7/QJVAxQ==, tarball: file:projects/arm-hdinsight.tgz} + resolution: {integrity: sha512-Diq19x/nZTHp1tmAsWYHlxsw8vVvoMjVIX6aQUIWwKcA4KCvK9u/MGWHnSR0B7+zol91sZWCQ4SbIyu5IwoKGw==, tarball: file:projects/arm-hdinsight.tgz} name: '@rush-temp/arm-hdinsight' version: 0.0.0 dependencies: @@ -15158,7 +15168,7 @@ packages: dev: false file:projects/arm-hdinsightcontainers.tgz: - resolution: {integrity: sha512-HjESaDNw/iW+31AKSA2Y85nGDo/kyWReIb1v0FYLg7o/umKT8PPDObxBus5RQ/YbvmIaA9ohaw2mQdW5GXM7ig==, tarball: file:projects/arm-hdinsightcontainers.tgz} + resolution: {integrity: sha512-AMQ9mHW5v5KQ9ktBxPw9pSXi+0kvioFYimPNvDdQ8nrQmTxBpOWlS9gGcPZg9ZhTB/WOHD1XXFFrPdsjrUR6Sw==, tarball: file:projects/arm-hdinsightcontainers.tgz} name: '@rush-temp/arm-hdinsightcontainers' version: 0.0.0 dependencies: @@ -15184,7 +15194,7 @@ packages: dev: false file:projects/arm-healthbot.tgz: - resolution: {integrity: sha512-EuhAUHmcpcWIl4BrBC/vGEhxK1Ky+fauv3vphoJnugtet0ZXG0VKJqCHmvImhZxE0LvW+bVhDbMIRbcWZ/s7Nw==, tarball: file:projects/arm-healthbot.tgz} + resolution: {integrity: sha512-LOrjcZgi/yUWrd1qOhuN6dg4Ba7uWOuvYiQnF71Ib3rjX3IvJRcyi5WOXan+mHYveG2EBKnv+V0F5DwJXE6uIw==, tarball: file:projects/arm-healthbot.tgz} name: '@rush-temp/arm-healthbot' version: 0.0.0 dependencies: @@ -15209,7 +15219,7 @@ packages: dev: false file:projects/arm-healthcareapis.tgz: - resolution: {integrity: sha512-+AC6M6cLa0mNM2pyfdL/etK6pp+oSNfxpgJv6UXYV+A8e4MhkW/kD2AnZCqZBdzbZD11wcyj7QIRS+17JyQOCQ==, tarball: file:projects/arm-healthcareapis.tgz} + resolution: {integrity: sha512-pt2U06O4j84tLOOQkTILEqlr5YSrKRybcdFqlhJ2fbu01iaVGi1XUu53gF0l9XuSf1dkCGgu2ithTkECvCxeng==, tarball: file:projects/arm-healthcareapis.tgz} name: '@rush-temp/arm-healthcareapis' version: 0.0.0 dependencies: @@ -15272,7 +15282,7 @@ packages: dev: false file:projects/arm-hybridcompute.tgz: - resolution: {integrity: sha512-BqpgXZVU7hHZMs5aOk6HfKDqwfNGQYIPg4zfUEAqAs+zzC+UQ3tK+7XM308kT7ZGGYclhxqWUEGJtxoWPhC7Fw==, tarball: file:projects/arm-hybridcompute.tgz} + resolution: {integrity: sha512-TYcm1kyoPpbERQwPWErPFhB1sz5LqaZF0rY7/ooEDfAZhfj00YPsLlOjkmJDbOocYlsBRAlpGhUTk4GZ9hou9A==, tarball: file:projects/arm-hybridcompute.tgz} name: '@rush-temp/arm-hybridcompute' version: 0.0.0 dependencies: @@ -15298,7 +15308,7 @@ packages: dev: false file:projects/arm-hybridconnectivity.tgz: - resolution: {integrity: sha512-Rr6hn9lb1kqqvIG8x2/REry627yi2MZu71htQaej3WVZt3mPSNRUm1Ug737lzeCGOxDEQ/aJroRhjx9/jTZs8g==, tarball: file:projects/arm-hybridconnectivity.tgz} + resolution: {integrity: sha512-w4CWUv6ig9UINwdy58QBJniGbeWAvnw6/5I/tjxPPYLhG6oYP0PROMEhfVybfvkojkSODdrjQu8JCL8+s9h66A==, tarball: file:projects/arm-hybridconnectivity.tgz} name: '@rush-temp/arm-hybridconnectivity' version: 0.0.0 dependencies: @@ -15322,7 +15332,7 @@ packages: dev: false file:projects/arm-hybridcontainerservice.tgz: - resolution: {integrity: sha512-1QbIrebgHWmdEzSmCsNZSaxLh/s5577vLlqyCJ3hAphEq7+FNW8Ct/PrCa1NWtYp7YFzpHURz53776DOeS6S7Q==, tarball: file:projects/arm-hybridcontainerservice.tgz} + resolution: {integrity: sha512-Du8CMo6tW4pFvRT2xEY2pTnlKiBRWRWnqIwZgcv0KYO1GIHl9RyXkUbuWlNRXROodlaqjRXgoAPWlll5Sph8pw==, tarball: file:projects/arm-hybridcontainerservice.tgz} name: '@rush-temp/arm-hybridcontainerservice' version: 0.0.0 dependencies: @@ -15348,7 +15358,7 @@ packages: dev: false file:projects/arm-hybridkubernetes.tgz: - resolution: {integrity: sha512-usfrtHvQvAEmJ5dvtvrgTk2UXTNi1judIMoj/aoy+RHmMGJ3IBqI5SBqogOYcvIFpVdsKFvi5znlxSp2yVF0+Q==, tarball: file:projects/arm-hybridkubernetes.tgz} + resolution: {integrity: sha512-c87gVfSUhcKDNwoUp9C3uCzibkv00rkMa59uyYaufn5h4RIKnu4lEUM/WVj2UsuN4Fd4guvpFvPyZawqiQdbNw==, tarball: file:projects/arm-hybridkubernetes.tgz} name: '@rush-temp/arm-hybridkubernetes' version: 0.0.0 dependencies: @@ -15373,7 +15383,7 @@ packages: dev: false file:projects/arm-hybridnetwork.tgz: - resolution: {integrity: sha512-PVOVbkCrbNV1GhMx32Gf7eY35QHUQ6uZZOxQedWy0yxSRCBjRR04xOgZ1VJj5GK6nk8Tzm+OeCMjTatsVhzW9w==, tarball: file:projects/arm-hybridnetwork.tgz} + resolution: {integrity: sha512-1pG0ef/kn2Yae8YXc3mnR9kiylT8Y8tmA2XZOOoCZcKXcfXkLOb9rdVS7VLOOHBWRtEXkhP8DtxbS7ZyrKHHHw==, tarball: file:projects/arm-hybridnetwork.tgz} name: '@rush-temp/arm-hybridnetwork' version: 0.0.0 dependencies: @@ -15399,7 +15409,7 @@ packages: dev: false file:projects/arm-imagebuilder.tgz: - resolution: {integrity: sha512-T/iDfbXnT6K6IWSa2vFh6PFYQnywRAijmoUH8HRsytV4cvwc9ssM89ZCeQS446bCec/r80jXXmjjSPwtNuMRjA==, tarball: file:projects/arm-imagebuilder.tgz} + resolution: {integrity: sha512-jLOcvk5DqSHaIMIRff4f4nVa0pIRBQYVrnGe3x5lLcdnxFT9hvzxQpBsxcvzeCo3QaRJWmiVo6hanNhb7o+YCg==, tarball: file:projects/arm-imagebuilder.tgz} name: '@rush-temp/arm-imagebuilder' version: 0.0.0 dependencies: @@ -15427,7 +15437,7 @@ packages: dev: false file:projects/arm-informaticadatamanagement.tgz: - resolution: {integrity: sha512-sqe7tc1vJKeQsxOZliPglBMHdfWi6TzI+SlTCyHZkBp4+4jSFTre7Csubv3ky+6c0G55lBf0GxdIzgDLJ/Hj+Q==, tarball: file:projects/arm-informaticadatamanagement.tgz} + resolution: {integrity: sha512-OhyPfix/q4V4zBdU4tXtEuq0e8l+Ez2uc/Qozdt2YgbPMH31k99jO609zJYQklhCR1l/hV7shy99cYNga19K3Q==, tarball: file:projects/arm-informaticadatamanagement.tgz} name: '@rush-temp/arm-informaticadatamanagement' version: 0.0.0 dependencies: @@ -15454,7 +15464,7 @@ packages: dev: false file:projects/arm-iotcentral.tgz: - resolution: {integrity: sha512-G6Vb7xYDbdZszXiwNyzoUINnRV+1tDchTH5XWYvntrvmBg+Hhd85VDrDwKnUuEDxUsloUNdys+YjuSV5XI1JyA==, tarball: file:projects/arm-iotcentral.tgz} + resolution: {integrity: sha512-NmrMH9PX2eeJLeKXUh+eyO/kZ7zp7KWWyhdW9QLrpL8Xc1a+eu+tj5z7w3FlFI0NDY6KNikQ72Iqfdgsfh8iTw==, tarball: file:projects/arm-iotcentral.tgz} name: '@rush-temp/arm-iotcentral' version: 0.0.0 dependencies: @@ -15479,7 +15489,7 @@ packages: dev: false file:projects/arm-iotfirmwaredefense.tgz: - resolution: {integrity: sha512-+Ff2msLx+LEkxSND3xdph8SWWE91djw840+GGfd+UyRuXIBNb9fsAnqGMDPItv/G2/OtBg/uu6CEmzbwSPVzcg==, tarball: file:projects/arm-iotfirmwaredefense.tgz} + resolution: {integrity: sha512-3NT2fRSJcCHQs7WgyUrruomXTfUwypIZ/0znCQKcEvIj0I6FF+wgOAiLpxhYUrhZXLgrt9oFoqyF4WrksWPPig==, tarball: file:projects/arm-iotfirmwaredefense.tgz} name: '@rush-temp/arm-iotfirmwaredefense' version: 0.0.0 dependencies: @@ -15503,7 +15513,7 @@ packages: dev: false file:projects/arm-iothub-profile-2020-09-01-hybrid.tgz: - resolution: {integrity: sha512-+BX1UA96ypd1pBMSfaZHeLMeXLhUwORDEL1bi9n0iaGNTaIhmPt2cGoNA+nMsGwk9zP/CIWzZnStk9Ab5I7DlA==, tarball: file:projects/arm-iothub-profile-2020-09-01-hybrid.tgz} + resolution: {integrity: sha512-olY1GDr4G8ew48RF9S1aMOc3pN+nZ1Qvq15qCj8l0i8f8i+GMXjzkd7KOSerfzWJLr5gDKS1QJvoZ/j8v+7YKg==, tarball: file:projects/arm-iothub-profile-2020-09-01-hybrid.tgz} name: '@rush-temp/arm-iothub-profile-2020-09-01-hybrid' version: 0.0.0 dependencies: @@ -15529,7 +15539,7 @@ packages: dev: false file:projects/arm-iothub.tgz: - resolution: {integrity: sha512-a9yWtbAbqY5dr4hDp9/Nybmv9TkHCHUxLnjevcOvIOGSMuDyOPOoMvBwKn6gessn8uhZkLlekKYTQVS3PFZv7A==, tarball: file:projects/arm-iothub.tgz} + resolution: {integrity: sha512-/Kv8S/UTIkA8w3R0E8MqppPMQLPwoUlcwfcZMLDkfugmoQAd+6V16fmL+GOJUkg+cwmDSuv6beWKthHhCHgMQw==, tarball: file:projects/arm-iothub.tgz} name: '@rush-temp/arm-iothub' version: 0.0.0 dependencies: @@ -15555,7 +15565,7 @@ packages: dev: false file:projects/arm-iotoperations.tgz: - resolution: {integrity: sha512-05wnGxIuuCy3nJ4z2Pd4Taqvo1N3b3lxd24za/KYk/lQ+wiSt2+fGRmG3WTNo0/Okp0rVy4BsGW6Xp2wNYH1ow==, tarball: file:projects/arm-iotoperations.tgz} + resolution: {integrity: sha512-t5QJr31o81EF3dX5/7stmGinUIk/yNXXkq27iowhAgZIPcKV27V9MxHmvsmnvBnZR5kPndkRaqnJl+gDavTCFw==, tarball: file:projects/arm-iotoperations.tgz} name: '@rush-temp/arm-iotoperations' version: 0.0.0 dependencies: @@ -15591,7 +15601,7 @@ packages: dev: false file:projects/arm-keyvault-profile-2020-09-01-hybrid.tgz: - resolution: {integrity: sha512-4r1lqa7+ntofaiJLY2T/MgUwpUFK/uMtEt2AAJTqqtZ/U86wcigBfeo8boJpBzqrtFroSC6ELyuO6kwUrwTDOw==, tarball: file:projects/arm-keyvault-profile-2020-09-01-hybrid.tgz} + resolution: {integrity: sha512-YjR104jAddoNnM/T3JV24M9PmH89SK+H/8Av0Mz5YN+2rJyg2T2vZqWv6YcGSlr1rzWSoEW9nM0yJE+UHu8Zng==, tarball: file:projects/arm-keyvault-profile-2020-09-01-hybrid.tgz} name: '@rush-temp/arm-keyvault-profile-2020-09-01-hybrid' version: 0.0.0 dependencies: @@ -15617,7 +15627,7 @@ packages: dev: false file:projects/arm-keyvault.tgz: - resolution: {integrity: sha512-eVCe6Z4akX5+6KtYkyQCkv86JoChAC/EGxTDus+vbo/2GItaLEhbEv2vW4TBL9bTSTC8XK1oxbgfzRrFxf2iBA==, tarball: file:projects/arm-keyvault.tgz} + resolution: {integrity: sha512-7cGAQeUpXlj7shUCplhjfEAvg8Bf3WzcsfK1EZ5rRaDLHYg7PHVFbnj8mu3NWWtR0FY75VyFNgAARUGuKJ4H0A==, tarball: file:projects/arm-keyvault.tgz} name: '@rush-temp/arm-keyvault' version: 0.0.0 dependencies: @@ -15643,7 +15653,7 @@ packages: dev: false file:projects/arm-kubernetesconfiguration.tgz: - resolution: {integrity: sha512-f5AwaMqFVoOUkHp5XCBD1YTmCCorS7NYkvRo+3WhqCQyqSpWm7giofq1SD51IyA/D32f0dPviKV+vYQ0imm1WA==, tarball: file:projects/arm-kubernetesconfiguration.tgz} + resolution: {integrity: sha512-7B9rvU7RANYbPIdn5m5K6mkL229DCTNUEnl6JlF06ASMScbk8PQU7qLfYq0tUBI+Uz1AZNsYqudDeZaYRzCxxw==, tarball: file:projects/arm-kubernetesconfiguration.tgz} name: '@rush-temp/arm-kubernetesconfiguration' version: 0.0.0 dependencies: @@ -15669,7 +15679,7 @@ packages: dev: false file:projects/arm-kusto.tgz: - resolution: {integrity: sha512-Grw9gGASFNADVDHRwxqU91JOjs3IMpyXRWOLx08Ga6C173yZ4g69PAYoPZ9wt2AT1ak3BLPsktCZ4RX0K3LNhQ==, tarball: file:projects/arm-kusto.tgz} + resolution: {integrity: sha512-qQj0z0k60jQNlL7qiDBcSbaYPmGOJz7TfbYHR+uzxZMBfWRA3gxbhSaUBonycen4fyCE61Wo/vEH9mHEwzj1eg==, tarball: file:projects/arm-kusto.tgz} name: '@rush-temp/arm-kusto' version: 0.0.0 dependencies: @@ -15695,7 +15705,7 @@ packages: dev: false file:projects/arm-labservices.tgz: - resolution: {integrity: sha512-B0CMA4gjnVF0ooxiHMfrJVJN4RL5HbAWwbjOY9PbAJAFglGY3T2zKc1EBRSbulI+wStUH2jIsi8hfWAFOWh6iA==, tarball: file:projects/arm-labservices.tgz} + resolution: {integrity: sha512-vlRfD9M+aS0Q/ZqGYCqfEHQw4/WK/QhtfkTFpw9TioLUe0opRBnmK8QkVn28HcegvCkKKqM69kVfb/ZoLifn4g==, tarball: file:projects/arm-labservices.tgz} name: '@rush-temp/arm-labservices' version: 0.0.0 dependencies: @@ -15721,7 +15731,7 @@ packages: dev: false file:projects/arm-largeinstance.tgz: - resolution: {integrity: sha512-eBquTEW1kgrd11n5skGCdi4Ka0P4sdzoc451YK0BI8fyFCW7OnjD9lRHydUOnA/yB+RB2mVYhMI4Um8/KuLfYw==, tarball: file:projects/arm-largeinstance.tgz} + resolution: {integrity: sha512-vlJ+Hv66fok19UONazhReAI+47AVLeheFtr0FX0MLbkAhIhiW9WKTKyV1W6QI4TZ/Y10ToFdaFXjMGxomnq1Rw==, tarball: file:projects/arm-largeinstance.tgz} name: '@rush-temp/arm-largeinstance' version: 0.0.0 dependencies: @@ -15747,21 +15757,26 @@ packages: dev: false file:projects/arm-links.tgz: - resolution: {integrity: sha512-4HMM3UpYrOMk9KukRlNiq6bNLjq1KcTk/GaAqW1UyoqmL2upaQUmXKO6i1g2IrYezeuEUGKeAyhg353ZgaWEwA==, tarball: file:projects/arm-links.tgz} + resolution: {integrity: sha512-cRBR8chr23fr9iq3fPK1PvccGlrNO1e3gIL4tjEpgt5RFYPr9J9kNJEXqUZz0Z81FYErjV6Cl6h9bSDF/cpUOQ==, tarball: file:projects/arm-links.tgz} name: '@rush-temp/arm-links' version: 0.0.0 dependencies: '@azure-tools/test-credential': 1.3.1 '@azure-tools/test-recorder': 3.5.2 + '@microsoft/api-extractor': 7.47.11(@types/node@18.19.60) '@types/chai': 4.3.20 '@types/mocha': 10.0.9 '@types/node': 18.19.60 chai: 4.3.10 cross-env: 7.0.3 + dotenv: 16.4.5 + mkdirp: 3.0.1 mocha: 10.7.3 - ts-node: 10.9.2(@types/node@18.19.60)(typescript@5.6.3) + rimraf: 5.0.10 + ts-node: 10.9.2(@types/node@18.19.60)(typescript@5.5.4) tslib: 2.8.0 - typescript: 5.6.3 + tsx: 4.19.2 + typescript: 5.5.4 uglify-js: 3.19.3 transitivePeerDependencies: - '@swc/core' @@ -15770,7 +15785,7 @@ packages: dev: false file:projects/arm-loadtesting.tgz: - resolution: {integrity: sha512-sJ2pkdhk14kd+L7xxDOEGUiZ1xwOSM6fCbg2n9PIYek4uo45/KdHip97ly/jEyY0goUreLBZo97szG2z/DyAJQ==, tarball: file:projects/arm-loadtesting.tgz} + resolution: {integrity: sha512-1Y/vWXUuiJzli4hQlmG6nRDZu61YOOKEaRZlRKhoeN8sh8jVNAG3YHCe9lA2uFWRwQCrYLFkClj/+d/RtVBvPA==, tarball: file:projects/arm-loadtesting.tgz} name: '@rush-temp/arm-loadtesting' version: 0.0.0 dependencies: @@ -15795,7 +15810,7 @@ packages: dev: false file:projects/arm-locks-profile-2020-09-01-hybrid.tgz: - resolution: {integrity: sha512-z85sEM6WgoqBFrWiWLemJQm3Zqfqw1JQrb5BdRl8fekO+uxayFmx2sfvmc4trUno0W3YMzj0B3v6uFgasUKW0Q==, tarball: file:projects/arm-locks-profile-2020-09-01-hybrid.tgz} + resolution: {integrity: sha512-wngN5cR6mkJs8hUsd/hoM8S54W5EklCFnmFCWJtFzJbgOb7usKl7c/w7HHqeSen0WJ+Suc17jecGC8L/9dpTkQ==, tarball: file:projects/arm-locks-profile-2020-09-01-hybrid.tgz} name: '@rush-temp/arm-locks-profile-2020-09-01-hybrid' version: 0.0.0 dependencies: @@ -15819,21 +15834,26 @@ packages: dev: false file:projects/arm-locks.tgz: - resolution: {integrity: sha512-muBktqtGCr8pZXpL1+R2A6cKfXcaK+b1+ykF658ZgMRARruU69ndlR5mjLN4wwDuu1lJM4H2mpA+U1yTM1WJdA==, tarball: file:projects/arm-locks.tgz} + resolution: {integrity: sha512-WmP8o7iLjpmEF7AlXl6Hg9EyxC201m+vpbVH+CISfO3x/drtDHTBtvx8R3Vie2MkPUz/Z9kjDn9nO3MICvj8+w==, tarball: file:projects/arm-locks.tgz} name: '@rush-temp/arm-locks' version: 0.0.0 dependencies: '@azure-tools/test-credential': 1.3.1 '@azure-tools/test-recorder': 3.5.2 + '@microsoft/api-extractor': 7.47.11(@types/node@18.19.60) '@types/chai': 4.3.20 '@types/mocha': 10.0.9 '@types/node': 18.19.60 chai: 4.3.10 cross-env: 7.0.3 + dotenv: 16.4.5 + mkdirp: 3.0.1 mocha: 10.7.3 - ts-node: 10.9.2(@types/node@18.19.60)(typescript@5.6.3) + rimraf: 5.0.10 + ts-node: 10.9.2(@types/node@18.19.60)(typescript@5.5.4) tslib: 2.8.0 - typescript: 5.6.3 + tsx: 4.19.2 + typescript: 5.5.4 uglify-js: 3.19.3 transitivePeerDependencies: - '@swc/core' @@ -15842,7 +15862,7 @@ packages: dev: false file:projects/arm-logic.tgz: - resolution: {integrity: sha512-FkvSgigS1wxB2ZWsZtYgw/NxIynetE2hi/M/TmRfK/VIOhv8wQLN+mvOW2akmDJI1ON5hlHZtm+GVxtqTsRBrQ==, tarball: file:projects/arm-logic.tgz} + resolution: {integrity: sha512-fx6k0HV+QEJ5Z9EFY1H1jx7qexgdmY9ZQthZYaHT3yX/mS8GOOtT2M97E26L+y4C2TBk0i17KS7LKURocdcqXw==, tarball: file:projects/arm-logic.tgz} name: '@rush-temp/arm-logic' version: 0.0.0 dependencies: @@ -15868,7 +15888,7 @@ packages: dev: false file:projects/arm-machinelearning.tgz: - resolution: {integrity: sha512-hrAyt26um0EgmCvkkIOiEgP4jSNyHw9N+i8zfHs31IJ7D7vmDcrAQyE8NnmbZ0qlrbkHiO73WQ6VH1oPKqzdtA==, tarball: file:projects/arm-machinelearning.tgz} + resolution: {integrity: sha512-gu9V9apfW6/Xwfb1x+WD6Do5+CAUPb2jGFIsOYswol/vF8U/+8UU1OcuhExVe2ez/SjpbaYLt+F4rWACdAChcw==, tarball: file:projects/arm-machinelearning.tgz} name: '@rush-temp/arm-machinelearning' version: 0.0.0 dependencies: @@ -15895,7 +15915,7 @@ packages: dev: false file:projects/arm-machinelearningcompute.tgz: - resolution: {integrity: sha512-FTeMF96TUpEr126T+vTkM308LQWRakDTl5UDsBnFlSalatA3ZyEqcPmN9UXt0tqLwvLelMCE4jObQKKGl8ukqw==, tarball: file:projects/arm-machinelearningcompute.tgz} + resolution: {integrity: sha512-Z1jXs0Z/INnQOBxLxOSLkWviLLFjQzG0Znn4MiK5mYQLsbZDVRyMcqGLBj2pO4XdF4rVkOH/XFehifFoiBPl8A==, tarball: file:projects/arm-machinelearningcompute.tgz} name: '@rush-temp/arm-machinelearningcompute' version: 0.0.0 dependencies: @@ -15920,7 +15940,7 @@ packages: dev: false file:projects/arm-machinelearningexperimentation.tgz: - resolution: {integrity: sha512-hiINJpoJ6+wP9tjvWtt4ojEXy1XJQF7z1Sa2d8KMlsEQycP0Laneti9tjeXGU4HemZPOrSrJISg2Rpu5BaBZLQ==, tarball: file:projects/arm-machinelearningexperimentation.tgz} + resolution: {integrity: sha512-15Fwgzv29bhj6/qXiGvrzHFa0RAZNNhB2tU/Sp0SoEgnJNCavCyVSphufy3uBZD4jgXJL/cbXZNjpSmxzv/X6A==, tarball: file:projects/arm-machinelearningexperimentation.tgz} name: '@rush-temp/arm-machinelearningexperimentation' version: 0.0.0 dependencies: @@ -15944,7 +15964,7 @@ packages: dev: false file:projects/arm-maintenance.tgz: - resolution: {integrity: sha512-sE8lH6HfqhE38mihDfbMEZLgMm/p6gnarX28bY7Tb4ie9edWYZg96d0gcoh2g2MrQt8oVtuHkahwcn/jJQRjaQ==, tarball: file:projects/arm-maintenance.tgz} + resolution: {integrity: sha512-KSXIj14/jJdbDPL6xrX71iSRWLNMol/eqLs3d7E/zYOVbVaOeiTQCctxSI7pJq9rj3dQ82aTL32OhtfZ3Fh4Ug==, tarball: file:projects/arm-maintenance.tgz} name: '@rush-temp/arm-maintenance' version: 0.0.0 dependencies: @@ -15969,7 +15989,7 @@ packages: dev: false file:projects/arm-managedapplications.tgz: - resolution: {integrity: sha512-84+8GBQ2UAWFVdNJMgTToVNzGKSUpdgOXS0SCPPzFszd1Pi2KWtMz2Ew7SaUFtYGifv89s+NfG6JMhcvgUXmOQ==, tarball: file:projects/arm-managedapplications.tgz} + resolution: {integrity: sha512-3ddLGh/ddUUoB7j1PmtLhUfca9B/cuVsFLKIfN3xT4JEbf82+Xb/gmaYyX//kaGYRd2DmX+ysWZ7NI2AYl2Q2A==, tarball: file:projects/arm-managedapplications.tgz} name: '@rush-temp/arm-managedapplications' version: 0.0.0 dependencies: @@ -15977,16 +15997,20 @@ packages: '@azure-tools/test-recorder': 3.5.2 '@azure/abort-controller': 1.1.0 '@azure/core-lro': 2.7.2 + '@microsoft/api-extractor': 7.47.11(@types/node@18.19.60) '@types/chai': 4.3.20 '@types/mocha': 10.0.9 '@types/node': 18.19.60 chai: 4.3.10 cross-env: 7.0.3 dotenv: 16.4.5 + mkdirp: 3.0.1 mocha: 10.7.3 - ts-node: 10.9.2(@types/node@18.19.60)(typescript@5.6.3) + rimraf: 5.0.10 + ts-node: 10.9.2(@types/node@18.19.60)(typescript@5.5.4) tslib: 2.8.0 - typescript: 5.6.3 + tsx: 4.19.2 + typescript: 5.5.4 uglify-js: 3.19.3 transitivePeerDependencies: - '@swc/core' @@ -15995,7 +16019,7 @@ packages: dev: false file:projects/arm-managednetworkfabric.tgz: - resolution: {integrity: sha512-jHuN+sI2Kg5PNm3u6eMIzu3vjWC2DcXoy5cuzl4hoTKdCVLpPDHd5OsuJxjNa1ojQeYHyjBuYN1UcMeAeLPFbw==, tarball: file:projects/arm-managednetworkfabric.tgz} + resolution: {integrity: sha512-zy1pZalFntDsTEtElku/Xq48o9jwg+9yMO8MKgz1B7Ia1r2N1TezfsRsZejVT0jbDEJ1vWFtvHPs2mmLOu6zvQ==, tarball: file:projects/arm-managednetworkfabric.tgz} name: '@rush-temp/arm-managednetworkfabric' version: 0.0.0 dependencies: @@ -16021,7 +16045,7 @@ packages: dev: false file:projects/arm-managementgroups.tgz: - resolution: {integrity: sha512-jnPGjAtSuRPmX1zXS5zZ9oyHoGLfmbJ41Er6fieCvM/fXI6O3ouVXj0vd+P7sU/m3+af3RixD7RI26jTpzlmog==, tarball: file:projects/arm-managementgroups.tgz} + resolution: {integrity: sha512-SCn6STza3y96YcIjaoVaUUf4nuGwRJ4eIkoE0blqyaSlZ1RyPUaP0vhZKFtygyXtcbxmqPM2aiCoY0xl59KREw==, tarball: file:projects/arm-managementgroups.tgz} name: '@rush-temp/arm-managementgroups' version: 0.0.0 dependencies: @@ -16046,7 +16070,7 @@ packages: dev: false file:projects/arm-managementpartner.tgz: - resolution: {integrity: sha512-mDhEZOJANT9Fs6ATWu4/4bxDinMJKGAomJ+GSelgh65A55IoBuFWaaQoisPCqkrkobcw9bxiE/Nia7yJW6ViEQ==, tarball: file:projects/arm-managementpartner.tgz} + resolution: {integrity: sha512-3YhQtP9FMEHnN05UPZY1gAJRlNxr/7FVkCS412BHxY/8y96QsVG0Bs3iKDkBpu140mUlqXEX0+NGx0VCwuWM7w==, tarball: file:projects/arm-managementpartner.tgz} name: '@rush-temp/arm-managementpartner' version: 0.0.0 dependencies: @@ -16070,7 +16094,7 @@ packages: dev: false file:projects/arm-maps.tgz: - resolution: {integrity: sha512-fM4XqVdoM7FxgaxDxX3VvKwlpbMXwsNKzu10SecLeY++xTrHbcsPx5/vzK9mlw7rPELRAQ13T/pqfCcS6s/hXQ==, tarball: file:projects/arm-maps.tgz} + resolution: {integrity: sha512-+RqX+ovhWXW30qEUt89xbBocmZsdJcus8qNOlPyYCsLCTqy+SJRdvAfA13oWz5l6Mo7/mmptTeIxvOQgVkKhiw==, tarball: file:projects/arm-maps.tgz} name: '@rush-temp/arm-maps' version: 0.0.0 dependencies: @@ -16094,7 +16118,7 @@ packages: dev: false file:projects/arm-mariadb.tgz: - resolution: {integrity: sha512-u77GjF67jgqB9SsJ7v67rNVQvZY/ETcTV2Tfas1PgC06RVjcC26WR2gctcI9FMQafpASArYdsKtnX5h47BkDXQ==, tarball: file:projects/arm-mariadb.tgz} + resolution: {integrity: sha512-dLDa2IkoH2rzdJ1vXxLzXIbktOtD3V72zRHCi88qQwx/TLJlzIzGkfBwCrNa3QbMw2jPol6pd+NmeW7UimhKPg==, tarball: file:projects/arm-mariadb.tgz} name: '@rush-temp/arm-mariadb' version: 0.0.0 dependencies: @@ -16119,7 +16143,7 @@ packages: dev: false file:projects/arm-marketplaceordering.tgz: - resolution: {integrity: sha512-AOGyOIITVa93suU8SA1ggIbHwCgPRwiJE2MA3+piP1pk3LVjo1z36Odr1/g80+9ovHBFDKiKa5eE4ETJIVAFew==, tarball: file:projects/arm-marketplaceordering.tgz} + resolution: {integrity: sha512-fabsC8twhK4rKVe4sJSfqECRFk66NfdZpWRatlBjrw/DXcselS5g37rCQw3TIs3YdPh0zpAdlvYdO9/JNGR4zw==, tarball: file:projects/arm-marketplaceordering.tgz} name: '@rush-temp/arm-marketplaceordering' version: 0.0.0 dependencies: @@ -16143,7 +16167,7 @@ packages: dev: false file:projects/arm-mediaservices.tgz: - resolution: {integrity: sha512-aMzt5I5T9Do3+L8IuSWYzGQ+bWJ6Uh1mMemJG5ahpcx3DUMx+dNPL4q3DiFeRxMDOItgDzneEJB2rzvlTQma9g==, tarball: file:projects/arm-mediaservices.tgz} + resolution: {integrity: sha512-FlrKqkxmnpksywwZ91ccNfRFyc/m0OhColbYU0MCjLzYgSpZM0T/aJxqGG56GoAh0x8H+MYI3Rpl6A3s74vuOQ==, tarball: file:projects/arm-mediaservices.tgz} name: '@rush-temp/arm-mediaservices' version: 0.0.0 dependencies: @@ -16169,7 +16193,7 @@ packages: dev: false file:projects/arm-migrate.tgz: - resolution: {integrity: sha512-LGio8trj5+AQvTRSpcNvxOc/m6jwQ58GIDfsj/0bdXevMr+AdrSVDdcFxZL1rSK6F+UpVVOp9R3gtHQdwPoGwA==, tarball: file:projects/arm-migrate.tgz} + resolution: {integrity: sha512-zLwrkihe9UB81LustbD4KZpXrNKOXQehMeTxeQM7ig08I6+mek4Bs7qGMV/1vFKnXbbUJuI2kpzDx3C0HF/9JQ==, tarball: file:projects/arm-migrate.tgz} name: '@rush-temp/arm-migrate' version: 0.0.0 dependencies: @@ -16193,7 +16217,7 @@ packages: dev: false file:projects/arm-migrationdiscoverysap.tgz: - resolution: {integrity: sha512-ze1OQcF8whxpu+/o5WlrqWx+5gPx2KluBwnh93Hw3sZWjBYkASCzGl1+w622tq+Bk0piJxHpAkD5uLP5oW8HhA==, tarball: file:projects/arm-migrationdiscoverysap.tgz} + resolution: {integrity: sha512-44YwbrJV2co8vAKLzygJvDHQdL/lvJ/5h7aRCNNIWPvnJH684ORkOdIfjJqRDxraLxO7kK79RvJheXv/n5bFkQ==, tarball: file:projects/arm-migrationdiscoverysap.tgz} name: '@rush-temp/arm-migrationdiscoverysap' version: 0.0.0 dependencies: @@ -16219,7 +16243,7 @@ packages: dev: false file:projects/arm-mixedreality.tgz: - resolution: {integrity: sha512-maij0XebtJhk2kkDuC1k5K6Vl5bci2D8KJLrk3DrHTJUCg5w/kZiWJbBXra7jWo1qoXt42CTwMfSs8EXunQTPQ==, tarball: file:projects/arm-mixedreality.tgz} + resolution: {integrity: sha512-47+02mXOHNZQEDBXGMcICtaMcFFNCiE+5GIuqKaH3kBJ7ka6bhlaOCYgdSEaaS/rhqwZ3RW2ItuawqjE+H55Kw==, tarball: file:projects/arm-mixedreality.tgz} name: '@rush-temp/arm-mixedreality' version: 0.0.0 dependencies: @@ -16242,7 +16266,7 @@ packages: dev: false file:projects/arm-mobilenetwork.tgz: - resolution: {integrity: sha512-S3kVZStJZKTdRCAX86TPEwGAM/PVB4vJx7xuaSOipyFhAgfE6jXBSiptPBjfVflB4qcHTXBZ5L7Od2pjptGF8Q==, tarball: file:projects/arm-mobilenetwork.tgz} + resolution: {integrity: sha512-7kHoHGHHusys0ftW/77nqGAmRLW9a4LShzxWt96y5Q59JpU/3q04wzx2KffU0mYpdPAOGbsRvENtY54Ve+p1IQ==, tarball: file:projects/arm-mobilenetwork.tgz} name: '@rush-temp/arm-mobilenetwork' version: 0.0.0 dependencies: @@ -16269,7 +16293,7 @@ packages: dev: false file:projects/arm-mongocluster.tgz: - resolution: {integrity: sha512-hlWf28oBX4FCDiH4yROX4odiVqH/YZEF+HvzEw90MYaoIoI/rQax7NB+b2cKzPB7eeColUb3rrX9ecJePNKRPQ==, tarball: file:projects/arm-mongocluster.tgz} + resolution: {integrity: sha512-0cIKdDqo8SucLoVDs7HobYbgm2dX7HXlQ7WaCHLrPLrLmKVvfOGAs7TjYERvORqKlIUs/tIzAtp9oM1zOPaN3A==, tarball: file:projects/arm-mongocluster.tgz} name: '@rush-temp/arm-mongocluster' version: 0.0.0 dependencies: @@ -16306,7 +16330,7 @@ packages: dev: false file:projects/arm-monitor-profile-2020-09-01-hybrid.tgz: - resolution: {integrity: sha512-vvpef9XrD1AXDyycUZ871J/O0ZQtTlcC1j4rvgicTkgaCkSl5px2jx+JO3z432anuptIrRQq4a/kCvi7DZsoEg==, tarball: file:projects/arm-monitor-profile-2020-09-01-hybrid.tgz} + resolution: {integrity: sha512-6/hR610ju/blOatwn2IMrCLBxwPTyQh0EkyyE24GZEmzw5FOBM8BlYGB1ZLh4so+8gGAJfcGqMsqDCvLZatSyQ==, tarball: file:projects/arm-monitor-profile-2020-09-01-hybrid.tgz} name: '@rush-temp/arm-monitor-profile-2020-09-01-hybrid' version: 0.0.0 dependencies: @@ -16330,7 +16354,7 @@ packages: dev: false file:projects/arm-monitor.tgz: - resolution: {integrity: sha512-hRd95y9SQArJM6QQ2Tl+MtroRCNVVyIFOsZIInnLbNhO39ecZV9dQjOngmsZD9gFtTjZPrrnlO3rDI/amK+K0Q==, tarball: file:projects/arm-monitor.tgz} + resolution: {integrity: sha512-KcDgKSU1UxUmvkQdJz3cwMoVWS+/jjdpG4CjBhoSRSAWG6k6YJOmHzlH2CnJFl8DKIi/YY6Xfrp1Lv/4hm2Rlg==, tarball: file:projects/arm-monitor.tgz} name: '@rush-temp/arm-monitor' version: 0.0.0 dependencies: @@ -16356,7 +16380,7 @@ packages: dev: false file:projects/arm-msi.tgz: - resolution: {integrity: sha512-6q1DSFrVL6bO7drVVHVhfYXRl1XilhwQMXPAPFukjAzYA8PYRWjCJgvZlxuFMD4Qn9AL1hcNulml5oVwdXNoBw==, tarball: file:projects/arm-msi.tgz} + resolution: {integrity: sha512-MOF/3cCw43qG2a/+zvOyYEJvoOe3VKjQBGP7rNxXH5Rdo2zGxl7aCWDW/FGLiDTa0dq4dbGXiTtSH9z9XQ1Atg==, tarball: file:projects/arm-msi.tgz} name: '@rush-temp/arm-msi' version: 0.0.0 dependencies: @@ -16380,7 +16404,7 @@ packages: dev: false file:projects/arm-mysql-flexible.tgz: - resolution: {integrity: sha512-JAd2VxwbmLW8o4oxcSwQ5Qm0fUGXWZJG1qVS13X/wR5agbSVrbi8PGT3D3AWbPW6rC0cyQLKHB6t0MKchYEc8g==, tarball: file:projects/arm-mysql-flexible.tgz} + resolution: {integrity: sha512-lOxNrhJfXCM3++j7wa418cyFhWKgaaGOwMo4PavsFn7Ds8DRyowNqUfsGEp6ylE64dGop/mXGqlQrFNOp4eczQ==, tarball: file:projects/arm-mysql-flexible.tgz} name: '@rush-temp/arm-mysql-flexible' version: 0.0.0 dependencies: @@ -16407,7 +16431,7 @@ packages: dev: false file:projects/arm-mysql.tgz: - resolution: {integrity: sha512-zKw7ksu4cCpw4nV9ESMJC5HkTGLVlOUj8M0Fopy08Aa+l/1YZ1b8QgMcfi931W2eNthbxi3oxULjsKdOET/scQ==, tarball: file:projects/arm-mysql.tgz} + resolution: {integrity: sha512-lu5lmiQ+vU2eHZHe7LyanrP9U7VCaT0T88PwIvfMbVzQdqlyjXnAlWcYZa5F2zQC9XwYb20Lcze39u5PDsCvwg==, tarball: file:projects/arm-mysql.tgz} name: '@rush-temp/arm-mysql' version: 0.0.0 dependencies: @@ -16432,7 +16456,7 @@ packages: dev: false file:projects/arm-netapp.tgz: - resolution: {integrity: sha512-zdIMf2MynU2WP/Z9LuHs2A30Ctp5HNCpYtq+5DZMPGN0FEWwAiphMVeWablB33JBdsGxZEiALPOHfgADUZvL+Q==, tarball: file:projects/arm-netapp.tgz} + resolution: {integrity: sha512-08cvMQ76IkP6GTDvgOJeFdIZ0LCSxX/1gbXsKYcoaW+kpQUXhHuJ/ppdS83m2jysV2n3HfrX1sE8tUdO1J2nxA==, tarball: file:projects/arm-netapp.tgz} name: '@rush-temp/arm-netapp' version: 0.0.0 dependencies: @@ -16458,7 +16482,7 @@ packages: dev: false file:projects/arm-network-1.tgz: - resolution: {integrity: sha512-rydPIm7bBkrlg0KnFUVQKAdLDdaHg1KSg40b7DdnhMA5hKjo9aEq75P+dgUUqz3Bms2m7Dw9CPU0BAt7uyAI7A==, tarball: file:projects/arm-network-1.tgz} + resolution: {integrity: sha512-uTZHs81K1xEdqHMoQw4mSIhPD9zYRtUwIYCrZaT6J5IgRQWWDlgmk7OtaRSOX1Vq/0DMeCtQeMf7TNzYojUc2Q==, tarball: file:projects/arm-network-1.tgz} name: '@rush-temp/arm-network-1' version: 0.0.0 dependencies: @@ -16485,7 +16509,7 @@ packages: dev: false file:projects/arm-network-profile-2020-09-01-hybrid.tgz: - resolution: {integrity: sha512-20d4QmgGJP/5zmIZH0kKbAXq+IJJMsP6xca2kZi3n0zNLilbAVqL9B4ghzmejHau/qAYTJh+rvfTqATKLV7l1w==, tarball: file:projects/arm-network-profile-2020-09-01-hybrid.tgz} + resolution: {integrity: sha512-7HarC2c1fhy3e1Fgr7L+SpKi/HXJLL3XK0WleoVaB0ky8AmClQGG9d785tKeTeRpfp1BBM+aTFdsY0X9/1uUGA==, tarball: file:projects/arm-network-profile-2020-09-01-hybrid.tgz} name: '@rush-temp/arm-network-profile-2020-09-01-hybrid' version: 0.0.0 dependencies: @@ -16554,7 +16578,7 @@ packages: dev: false file:projects/arm-networkanalytics.tgz: - resolution: {integrity: sha512-rZhwu4YjDSUCeTWJ+WLDnFj+4jF22i0hkQsgjEL9IBPMZa5b3KUTzM3xIVf8W3Vs1QSUEQgnGArfOnmv/mt0Nw==, tarball: file:projects/arm-networkanalytics.tgz} + resolution: {integrity: sha512-YjZaLi99tCI7+x1kjMVH7O5j6OT7sNnHp8e2rvHYGhJf6BEmvMTvA52n/2UOA5ynuzzGWxk+wzeGkERrnmqP6w==, tarball: file:projects/arm-networkanalytics.tgz} name: '@rush-temp/arm-networkanalytics' version: 0.0.0 dependencies: @@ -16580,7 +16604,7 @@ packages: dev: false file:projects/arm-networkcloud.tgz: - resolution: {integrity: sha512-wssqp1hy41p86dFx8Wt35Y3FsDi1X0o50lWG45nfOetr6bV/xFnrNWjGKmNwHRa2Qf+YJTkTWOXYeKwYdRL2AA==, tarball: file:projects/arm-networkcloud.tgz} + resolution: {integrity: sha512-ftRAllp+maZWGq8e8ItoqmRBDSqyl4HhOMc2f8fH+duARdNMW6SdVhPEs89USZhId3RLh58zQsgNRvnyoNbMgw==, tarball: file:projects/arm-networkcloud.tgz} name: '@rush-temp/arm-networkcloud' version: 0.0.0 dependencies: @@ -16606,7 +16630,7 @@ packages: dev: false file:projects/arm-networkfunction.tgz: - resolution: {integrity: sha512-UIL2CD3onQftWLTaDbso+2n4pS9YbE4CwI+eUaoTmfWJ0aXUQlNA6DZbEdy0kBGrt244DS01xry7xd0MAdLb1g==, tarball: file:projects/arm-networkfunction.tgz} + resolution: {integrity: sha512-T9ndrcplnW2M4WNnpFNavqql4n5l7Dnq7vTERzDFcEDMu2u/HZPDipDmTUy/dojcO+848FxuljKggWvl7ki6iw==, tarball: file:projects/arm-networkfunction.tgz} name: '@rush-temp/arm-networkfunction' version: 0.0.0 dependencies: @@ -16631,7 +16655,7 @@ packages: dev: false file:projects/arm-newrelicobservability.tgz: - resolution: {integrity: sha512-MOWJaU9tRmjEvuQSjklCgHz22Mrue+6zcWxoSAadqCcqpKP4VH1xhMnkGabArQUZj6re/YUuj1zitom8ocYNXQ==, tarball: file:projects/arm-newrelicobservability.tgz} + resolution: {integrity: sha512-BF7/XBAYs/2wjgOEDGxTcGffZ8sSDU+QU3ooJ/AP3Z0fgDVrW9CGLKnozkkaFUSRqTaowEdELXYe+EPdLLthtw==, tarball: file:projects/arm-newrelicobservability.tgz} name: '@rush-temp/arm-newrelicobservability' version: 0.0.0 dependencies: @@ -16657,7 +16681,7 @@ packages: dev: false file:projects/arm-nginx.tgz: - resolution: {integrity: sha512-p5OZ43j3C9KluRaLiwMTvRsfc7HctQ7oIkaVwQhkiLGuUYrliiHsrG39Y0RbC+mN99w9oT5CTXwciMb3Bec+xA==, tarball: file:projects/arm-nginx.tgz} + resolution: {integrity: sha512-Jbvjfz6S0V0aBfNVlZfmKKdUWuD7yOo/IyPVrvrAdh4HyrJqkSeqNdwkfv0eTXdXuWaMeoD4UfiDE2PQLLA3yw==, tarball: file:projects/arm-nginx.tgz} name: '@rush-temp/arm-nginx' version: 0.0.0 dependencies: @@ -16683,7 +16707,7 @@ packages: dev: false file:projects/arm-notificationhubs.tgz: - resolution: {integrity: sha512-Dnhe0GK1wvk/F6/Y8XmRQ1W5V2lTw87d2NftRZJYi9o2Tw1aEcMMVQcGU4if+S4P+Y0OjTe5+BsxUc4mZCgxpQ==, tarball: file:projects/arm-notificationhubs.tgz} + resolution: {integrity: sha512-x71k338WbPv5GBkbkXFWH03DKbB9B/HGs10RAxJ+WaTL1UFPXqjd+Ube9nS7qcajiy8uDMIh9R5NZDO3SccwGQ==, tarball: file:projects/arm-notificationhubs.tgz} name: '@rush-temp/arm-notificationhubs' version: 0.0.0 dependencies: @@ -16709,7 +16733,7 @@ packages: dev: false file:projects/arm-oep.tgz: - resolution: {integrity: sha512-fqbYCOSGGmwGSenvRzQw9vbg8RvqiQNO/9p4JE6WjmDR+jqg77GGSJAB1ZH7g6/yoiAuEJtZxxcsjalJ+LKh+g==, tarball: file:projects/arm-oep.tgz} + resolution: {integrity: sha512-TBJ9H29Qn9RSlTMSvkJn9bxHmEUbHxv1fuPTI3xlGZYtLHWOeTcCmqOebaJ4aIZo48Qdle/wxA0H6WbEXcoL1g==, tarball: file:projects/arm-oep.tgz} name: '@rush-temp/arm-oep' version: 0.0.0 dependencies: @@ -16734,7 +16758,7 @@ packages: dev: false file:projects/arm-operationalinsights.tgz: - resolution: {integrity: sha512-0LiKTGcH+218aFQ58QuYtboY3I+LcQ+6749nZNUpT3L8MWQa1NSZ30v2jV2aKVcFz3w2mSGK//Vetq3qPd6xvg==, tarball: file:projects/arm-operationalinsights.tgz} + resolution: {integrity: sha512-kRyKbpeO3iUp2B126QmGl89U7USC1w4sHH6I+IqDII1PVBVL740yt761FKPMCj0CEPtSQyEkIL7DQd0nCJjaFQ==, tarball: file:projects/arm-operationalinsights.tgz} name: '@rush-temp/arm-operationalinsights' version: 0.0.0 dependencies: @@ -16760,7 +16784,7 @@ packages: dev: false file:projects/arm-operations.tgz: - resolution: {integrity: sha512-k0j8abAYll1aFjMaQ4HCdCJMPVdWL9GB0gIEIaIsAeZJzvrFEiApzAHN/3OOmpY/tF8QxYXLO+C2Lcz457DICw==, tarball: file:projects/arm-operations.tgz} + resolution: {integrity: sha512-p0WxHmGG0rCq+U5XQrK1p2LnDm7RBsvzCSZOby3ysOIpjXZKKTx7m5XBIIFQtOYKBdG+qBuo6Wtz91whwbDclg==, tarball: file:projects/arm-operations.tgz} name: '@rush-temp/arm-operations' version: 0.0.0 dependencies: @@ -16785,7 +16809,7 @@ packages: dev: false file:projects/arm-oracledatabase.tgz: - resolution: {integrity: sha512-5b8jnUwImu3H2WaGH/1CdJy2qpkW6m/Q+lNG/ueWm9+dE3B7BI433eMflQwQ3W/1tDJAJpw6qH8nONMaGFiFlg==, tarball: file:projects/arm-oracledatabase.tgz} + resolution: {integrity: sha512-qdjBPMM8LletmYSJRG0Ir60tTBVfPnpPQmCgoB5zqbILc9RcGZ1C+lD0nnT/G2+B/60WoSvS5M84j1VPwhkJzA==, tarball: file:projects/arm-oracledatabase.tgz} name: '@rush-temp/arm-oracledatabase' version: 0.0.0 dependencies: @@ -16812,7 +16836,7 @@ packages: dev: false file:projects/arm-orbital.tgz: - resolution: {integrity: sha512-rGv6wJ3Wgk36Fk7B+EeJhbFsq/LRC7Ct/NJ7umTYDwe+tOHKhIJKtPfE68sGcNDP4/fA8W2loxXvRlRiSBsnyQ==, tarball: file:projects/arm-orbital.tgz} + resolution: {integrity: sha512-7ioo3afp+9e5bJVuvxbWzqrqCuSZnas5pnHaoZgIa92Sn4XO1bFsMV2gR/obof3zAvLfEgaZLwf8o9yVf+YneQ==, tarball: file:projects/arm-orbital.tgz} name: '@rush-temp/arm-orbital' version: 0.0.0 dependencies: @@ -16838,7 +16862,7 @@ packages: dev: false file:projects/arm-paloaltonetworksngfw.tgz: - resolution: {integrity: sha512-mMtTAC33uoEr7UnDvfoCBtsrvgTL2X9+Ld/M9Mf4TAkQyqlAxN77YFvL1GGvFdpatWteFhKiE9+wknb13J0SZg==, tarball: file:projects/arm-paloaltonetworksngfw.tgz} + resolution: {integrity: sha512-hhc2zZUs8u22q3xyQc3VoFLVVAyT2414pJgk5jTI3Eh8rdlMfPGOVLzJRNHWNulqccaPcoFOSzd2UtfRGokfIA==, tarball: file:projects/arm-paloaltonetworksngfw.tgz} name: '@rush-temp/arm-paloaltonetworksngfw' version: 0.0.0 dependencies: @@ -16864,7 +16888,7 @@ packages: dev: false file:projects/arm-peering.tgz: - resolution: {integrity: sha512-gS0Oi4Fxdnx/4pAzImoc/LMhaKCFO8FpTNuwWZWDBSHNcINAb12m+pJovFBSUxbRgnyrpWgxlCNVKE2XQp/MkA==, tarball: file:projects/arm-peering.tgz} + resolution: {integrity: sha512-6JMOwHLN3MNlt/C1CBiJFGONtiJjSroZtNphy5QfMPyi7nlQ/WQADARUn2EIbEAUE87criksaqh5FXXMtbLUIQ==, tarball: file:projects/arm-peering.tgz} name: '@rush-temp/arm-peering' version: 0.0.0 dependencies: @@ -16887,7 +16911,7 @@ packages: dev: false file:projects/arm-playwrighttesting.tgz: - resolution: {integrity: sha512-Nv4SiOXsWyMGCKQjir4EFTdzB2pCFdn0G6vKQsR+0qXIbWd9Bc8RIdEtrtl7OTru0s0U8ryU3NVx/VOL2sI3JA==, tarball: file:projects/arm-playwrighttesting.tgz} + resolution: {integrity: sha512-AALM/too+Z6vTpQ9Y71ZVdFHENggAv1WGpRj2Zh3GgTjj+TuBkkObxoEW8s88rJICe30ycGPG7IzmW1VKV4G1Q==, tarball: file:projects/arm-playwrighttesting.tgz} name: '@rush-temp/arm-playwrighttesting' version: 0.0.0 dependencies: @@ -16913,7 +16937,7 @@ packages: dev: false file:projects/arm-policy-profile-2020-09-01-hybrid.tgz: - resolution: {integrity: sha512-m2Q7EOu3JHSEHKliTCib6lrKjimg+Pj5/tue86h4Vg1sKqDi1WEX62sIDdw2To+5Q20rDW4JRCT7V8hRAhuTIw==, tarball: file:projects/arm-policy-profile-2020-09-01-hybrid.tgz} + resolution: {integrity: sha512-9HbWrJaBWjiz/1TAbiF7EXopcTN0hwRBPYPJ/y8aBO8IqV2vDPLzc4dEQo7/TeBwgAMZIHI5SAqdtEFylMw5/Q==, tarball: file:projects/arm-policy-profile-2020-09-01-hybrid.tgz} name: '@rush-temp/arm-policy-profile-2020-09-01-hybrid' version: 0.0.0 dependencies: @@ -16937,22 +16961,26 @@ packages: dev: false file:projects/arm-policy.tgz: - resolution: {integrity: sha512-jKZYFtRTSD0Sf1ml4HWz9yoYwanFn/5xpssGxzlPY7YRRWGHbCa/JfJd/s5ywELxv+DljBZ0iGQ/NMFNcXrgCw==, tarball: file:projects/arm-policy.tgz} + resolution: {integrity: sha512-kqWyHxDT9QH7fIioA9G/h502tu/99ECTmU0jYVfkvqdFomErwjz/unmvauKNbzGPkRcq7TrNlRxlXwIriDzzbQ==, tarball: file:projects/arm-policy.tgz} name: '@rush-temp/arm-policy' version: 0.0.0 dependencies: '@azure-tools/test-credential': 1.3.1 '@azure-tools/test-recorder': 3.5.2 + '@microsoft/api-extractor': 7.47.11(@types/node@18.19.60) '@types/chai': 4.3.20 '@types/mocha': 10.0.9 '@types/node': 18.19.60 chai: 4.3.10 cross-env: 7.0.3 dotenv: 16.4.5 + mkdirp: 3.0.1 mocha: 10.7.3 - ts-node: 10.9.2(@types/node@18.19.60)(typescript@5.6.3) + rimraf: 5.0.10 + ts-node: 10.9.2(@types/node@18.19.60)(typescript@5.5.4) tslib: 2.8.0 - typescript: 5.6.3 + tsx: 4.19.2 + typescript: 5.5.4 uglify-js: 3.19.3 transitivePeerDependencies: - '@swc/core' @@ -16961,7 +16989,7 @@ packages: dev: false file:projects/arm-policyinsights.tgz: - resolution: {integrity: sha512-x30pHlbnD6TmiRaQ8OVjSE11+mOA/+OQLUe0tpAUiwUe+ghGyPhXLklGqNZvudFFzodeBh02adOc5qp6cm2+fQ==, tarball: file:projects/arm-policyinsights.tgz} + resolution: {integrity: sha512-TfQ0NG8dJVrwYQQC7pBlWth/vb9dSQqnuh2ZB2HuxhmdWojZ2TbQ8rnsNlJfq2u2X6B1B83b0npgU7FSb72Yqg==, tarball: file:projects/arm-policyinsights.tgz} name: '@rush-temp/arm-policyinsights' version: 0.0.0 dependencies: @@ -16987,7 +17015,7 @@ packages: dev: false file:projects/arm-portal.tgz: - resolution: {integrity: sha512-NUkFhvWWHvwQKF9fG64wSAZvTyjY0bRfX+X7qgbZhsbeWV1R+DEKh5YTZ9eZcntfv/ogwTecvqy6V4ukliJecw==, tarball: file:projects/arm-portal.tgz} + resolution: {integrity: sha512-eODda9085aOTDSCzDexkK6ThngPl3nENbUzB3Uy+XFS3fGXIKlwc5WocMCyKYwFjLqvF9PldaP/FTEQ3CcmqIA==, tarball: file:projects/arm-portal.tgz} name: '@rush-temp/arm-portal' version: 0.0.0 dependencies: @@ -17011,7 +17039,7 @@ packages: dev: false file:projects/arm-postgresql-flexible.tgz: - resolution: {integrity: sha512-uAm/aWBYg/qKAfiPohm+Xd8m/VyZAN77Q/7qRTIfn100XpuyRK3nKffl55Y4hPZA4uz8XuxAtnXhCf8DkVl8rg==, tarball: file:projects/arm-postgresql-flexible.tgz} + resolution: {integrity: sha512-TiQo/gPVAKyNyJ3p3XpG46uxEYoZIwWFgEWJmN49mRevUvwyHUXGI3f8lRMtfG1OPbi3VgRDdHR4BsDQXkdA1A==, tarball: file:projects/arm-postgresql-flexible.tgz} name: '@rush-temp/arm-postgresql-flexible' version: 0.0.0 dependencies: @@ -17037,7 +17065,7 @@ packages: dev: false file:projects/arm-postgresql.tgz: - resolution: {integrity: sha512-t3UPm1H3re8AdrXPjYa4PEDIDp+BUNlCELheq1OYYFjHcR5vFq/JU7h9KfQG7Ap4Q37QLBPFCt9do/WvzbvQ0w==, tarball: file:projects/arm-postgresql.tgz} + resolution: {integrity: sha512-UH18lT3Lshi/EnKPMuyOwAN+D2rAE8wTz+QaNMXTs7B29UKVJjNkHyXQJbPTxPhuz8azR/4c9iWzJIvCcLlV4w==, tarball: file:projects/arm-postgresql.tgz} name: '@rush-temp/arm-postgresql' version: 0.0.0 dependencies: @@ -17062,7 +17090,7 @@ packages: dev: false file:projects/arm-powerbidedicated.tgz: - resolution: {integrity: sha512-aq75TNK/5h6nJ5TK4S2k9IfB6aA4QBfsioJD7xV62aDGz9CfesUIy1EAFd+1c3IlB1g8UJi42H0GhXTjLxvURA==, tarball: file:projects/arm-powerbidedicated.tgz} + resolution: {integrity: sha512-88Nfx6F1Vei3BmK8KGcvUPp9WiC5eyAfNnVCuXguSj3dLXdDuIkZIPT15yDkQuTpr4+OQ5LC7wYCtT19lpYDNA==, tarball: file:projects/arm-powerbidedicated.tgz} name: '@rush-temp/arm-powerbidedicated' version: 0.0.0 dependencies: @@ -17088,7 +17116,7 @@ packages: dev: false file:projects/arm-powerbiembedded.tgz: - resolution: {integrity: sha512-SJaaEFz4b3+uNaPCF30iv8jrH2afc9I3oCYxCdNKgBH5VISicykfGj6q3R0fojp5HTjABJRUISUN6qTIwlRrjA==, tarball: file:projects/arm-powerbiembedded.tgz} + resolution: {integrity: sha512-HJrhZGib/3hIAjSZaQPxk5db0RNKcwk5Y0stEQGVu7L0zijPCkqYATImmAOBOSkoah2Wis2oPeq7A8wquSVwBQ==, tarball: file:projects/arm-powerbiembedded.tgz} name: '@rush-temp/arm-powerbiembedded' version: 0.0.0 dependencies: @@ -17113,7 +17141,7 @@ packages: dev: false file:projects/arm-privatedns.tgz: - resolution: {integrity: sha512-2rMQ2vBiCw75PC2jkvdy4B2FmrrbdX6+JIB/5nusWzGxFgLN7JKJMSZVZIOW6zAVjvxuSmEnk0n0YnOiKMEaeQ==, tarball: file:projects/arm-privatedns.tgz} + resolution: {integrity: sha512-wOPaAR++biUqMQeUHMTPgK6jBrFGrRUIS4qmQ9EVA/RgZhOiwrBTfrU0bAXyZelApFtT9aLMahweHS4Tij57Kg==, tarball: file:projects/arm-privatedns.tgz} name: '@rush-temp/arm-privatedns' version: 0.0.0 dependencies: @@ -17139,7 +17167,7 @@ packages: dev: false file:projects/arm-purview.tgz: - resolution: {integrity: sha512-Wj1f5gMjVpl9pdYp9Yg112K+J8PjHMuYTDulyHaku8DLdf+GEqpUDppQQCRNy4Tl/WyB1+pwYqNNE8UG/amCRw==, tarball: file:projects/arm-purview.tgz} + resolution: {integrity: sha512-S5LAORqEylHZ+7kIVKxzWMXipxDwn5ZVI3KlGX1AJnJv2rLF/GDrndyLBnZg7jUfJ7xcmT6bkA+v4Gcqgjtmmw==, tarball: file:projects/arm-purview.tgz} name: '@rush-temp/arm-purview' version: 0.0.0 dependencies: @@ -17164,7 +17192,7 @@ packages: dev: false file:projects/arm-quantum.tgz: - resolution: {integrity: sha512-22/aJJ+wPTmLdG4el8m2uWw5fN+D3Qh6528y+LdMVuRM7Cfi8XC1/MiK+QbGTLtcvRz2HFUy+rcna2JSe+0oyA==, tarball: file:projects/arm-quantum.tgz} + resolution: {integrity: sha512-1cz4eXPCsY8F1t/YpFrovAvSOjqrHnJNOqy3oT3rhRgLcGrj7wfOoMZshfHp5MjZSyTguHezg5rjc2+wSdW6Pw==, tarball: file:projects/arm-quantum.tgz} name: '@rush-temp/arm-quantum' version: 0.0.0 dependencies: @@ -17190,7 +17218,7 @@ packages: dev: false file:projects/arm-qumulo.tgz: - resolution: {integrity: sha512-o7695Xq8gKzK3LF/FZrYTlTZS3B3mOwSDS8Uw/ajFzC/PStKr0wA8Zuikl23TcxS2Wt6D2mWjREICDEFDLTvdA==, tarball: file:projects/arm-qumulo.tgz} + resolution: {integrity: sha512-GZoa6ghbFP2nNWabJXBFQT3l/XskJRT+oRAzEmgVhNlP4oivjfDIo8owKFlq8AVMQNRgGn7COxExpBj7XZaDAw==, tarball: file:projects/arm-qumulo.tgz} name: '@rush-temp/arm-qumulo' version: 0.0.0 dependencies: @@ -17217,7 +17245,7 @@ packages: dev: false file:projects/arm-quota.tgz: - resolution: {integrity: sha512-k/ZchFgPhQ2h3t3X45FtUr+a+JNSwMtSmwFURYVMdkrIAGqwlpubpKNrKI3KStw0jn+9TTLnkuCq0jDscV9D1Q==, tarball: file:projects/arm-quota.tgz} + resolution: {integrity: sha512-/Bz/+SVZKNPV2DExUe/JAfBGZPwoQEjl7ezPZh243Dniy8KcfXdJ2dgEUUpWdlGNOintp7hOwUzLKabG7HZ7Lg==, tarball: file:projects/arm-quota.tgz} name: '@rush-temp/arm-quota' version: 0.0.0 dependencies: @@ -17243,7 +17271,7 @@ packages: dev: false file:projects/arm-recoveryservices-siterecovery.tgz: - resolution: {integrity: sha512-6Kbi8ceCb2xP9syzl4t8IF4NPuoQ8Bx7Hzx0C+qT56DZExre+AQxHWbvjR3AIyd65Y+qoMl6FQNSpu9E5Rrlfw==, tarball: file:projects/arm-recoveryservices-siterecovery.tgz} + resolution: {integrity: sha512-+9ePKGWtTl5f+QkiclFysuoTW1FMul1PjIeJGuIdDhlXQJh/K4itNLXzEFe4eGxIopZBksJTpNxPkXBqIFBd5Q==, tarball: file:projects/arm-recoveryservices-siterecovery.tgz} name: '@rush-temp/arm-recoveryservices-siterecovery' version: 0.0.0 dependencies: @@ -17269,7 +17297,7 @@ packages: dev: false file:projects/arm-recoveryservices.tgz: - resolution: {integrity: sha512-buz6PriqrAH1Iy6PU9v+jhCmctEZNgdFLBHassFz7rp4yNtpCA4z9j7Q2gx7MJyE98FO69FMAnve0oid97XLmQ==, tarball: file:projects/arm-recoveryservices.tgz} + resolution: {integrity: sha512-ytwagzX6cdmSQ2X7vA3vVvbuYX6hAx38estxcCIi+kcjZCUqlnRsveUSNJkBswsLUvuxFKJpCtKkuh57zPlDiQ==, tarball: file:projects/arm-recoveryservices.tgz} name: '@rush-temp/arm-recoveryservices' version: 0.0.0 dependencies: @@ -17296,7 +17324,7 @@ packages: dev: false file:projects/arm-recoveryservicesbackup.tgz: - resolution: {integrity: sha512-+RZzBbEtsdzdhclWAijGO0LjqSTxvdpKBxqgUyjZcIjzmlmTxTbDDnGG60tFFKf4ihkQqoWVQBdilrkoSxSCBQ==, tarball: file:projects/arm-recoveryservicesbackup.tgz} + resolution: {integrity: sha512-jrZ82m0kTFrWF8MKv8vk14J++t+c8nf6COpPTeK9O4PGSjUXuBpW3BmWXxKHtrI4+PLPIPnhlPPA6GJoKEhsjw==, tarball: file:projects/arm-recoveryservicesbackup.tgz} name: '@rush-temp/arm-recoveryservicesbackup' version: 0.0.0 dependencies: @@ -17324,7 +17352,7 @@ packages: dev: false file:projects/arm-recoveryservicesdatareplication.tgz: - resolution: {integrity: sha512-dRZL9ErHtBju0qd5X/gbgio8icwuELfBg2SXa/CIp1P6bt9UyUC0XB305CkRqtFX7LHB7hkL4XK9xwCpakOI3g==, tarball: file:projects/arm-recoveryservicesdatareplication.tgz} + resolution: {integrity: sha512-mznExEhBlPkd2RyRx4wfAoij4+exg+xyFJHAl1BC7Y3IqmMUfRbt+7dtHLVJp1OdxSBMufkow/stDDOgWuat0g==, tarball: file:projects/arm-recoveryservicesdatareplication.tgz} name: '@rush-temp/arm-recoveryservicesdatareplication' version: 0.0.0 dependencies: @@ -17350,7 +17378,7 @@ packages: dev: false file:projects/arm-redhatopenshift.tgz: - resolution: {integrity: sha512-FYS/fr1NduhuF3IiUMATQSrH+JlgrHl3SJ+IGuSHlEhBItUlKD6xjXpCGJB2h554JCRkWloAfB0Km+qkngW1ZA==, tarball: file:projects/arm-redhatopenshift.tgz} + resolution: {integrity: sha512-v7fm5mHLttlfWwoGfT6irFFTfmpRVvM6bLzGaYN165mKzCyJzj4UGsRqflUqoO3hP0tuMERgJoJiYiub0yBwHA==, tarball: file:projects/arm-redhatopenshift.tgz} name: '@rush-temp/arm-redhatopenshift' version: 0.0.0 dependencies: @@ -17377,7 +17405,7 @@ packages: dev: false file:projects/arm-rediscache.tgz: - resolution: {integrity: sha512-z5ujrNwDvsgrwZgsL0sqVXKIVTo3qwV8xvoXXR45csEC3Y1cUubRhLHASnGfqrJTg5XqXcfa9THkYRn6l75rqg==, tarball: file:projects/arm-rediscache.tgz} + resolution: {integrity: sha512-sirn9Z2lgEDZrc2JRcrAmU+t8aadVkdZI3qjUDTtq49zQuE+KxlG0yd2yrUboC/514EIvVYqM5taUaqpjz5xgQ==, tarball: file:projects/arm-rediscache.tgz} name: '@rush-temp/arm-rediscache' version: 0.0.0 dependencies: @@ -17405,7 +17433,7 @@ packages: dev: false file:projects/arm-redisenterprisecache.tgz: - resolution: {integrity: sha512-yxkJANETgcmrNKWmsJhyq3h+twfDCQhaVnjj5cPS2VYRVjONROf2SWki2icejLwuophdELuTCLrM2AgpUHT01w==, tarball: file:projects/arm-redisenterprisecache.tgz} + resolution: {integrity: sha512-XQg3k+pXcdTZHf+UM+5KbLnCwMb7C7+pYLeG3g6lrzasJWAeCKmnSy8T0/DXlmKpt77UWmox9/0/UhGneM7EcQ==, tarball: file:projects/arm-redisenterprisecache.tgz} name: '@rush-temp/arm-redisenterprisecache' version: 0.0.0 dependencies: @@ -17432,7 +17460,7 @@ packages: dev: false file:projects/arm-relay.tgz: - resolution: {integrity: sha512-5fGBgxUd5v37E/t/HyMYr0ElJHg/SeaZxKkd2hs8GB3O9CSi9YWRpLDP6KXBqfd0yfWO4csLeEMBZVqgg/rZSA==, tarball: file:projects/arm-relay.tgz} + resolution: {integrity: sha512-nY3NqCGhW+ZEq031sPToj1LTZ1a05KpaxtARjQDixMTdKZldeHRACsdMbXE/cMNHZrqw6XMa2HhlU80SXl2aqA==, tarball: file:projects/arm-relay.tgz} name: '@rush-temp/arm-relay' version: 0.0.0 dependencies: @@ -17458,7 +17486,7 @@ packages: dev: false file:projects/arm-reservations.tgz: - resolution: {integrity: sha512-w6Kp7E5BGDfCoUmM1eGYiM4lZ0a++ctZhTFEuyeqOi7yStjGEO4x6NyXgBwZ3i/2WO5ne+y3mhjQ8uNfT6LoDA==, tarball: file:projects/arm-reservations.tgz} + resolution: {integrity: sha512-9NndEqejs6aT0RqxeNR+nmoSUuAM55vQjqATEsU9by50RPhQowFS2Px92rLFQwXhD4SS2T46IE4/bqDxjGcsqg==, tarball: file:projects/arm-reservations.tgz} name: '@rush-temp/arm-reservations' version: 0.0.0 dependencies: @@ -17484,7 +17512,7 @@ packages: dev: false file:projects/arm-resourceconnector.tgz: - resolution: {integrity: sha512-OkIkVhMfmUXgaVZzpKNWwkW89ce/XHjJDWWVfGn4yOY720wMUJ15WqCP+KB8WKprEWpgB+oDhPs/LGe2hhXSJg==, tarball: file:projects/arm-resourceconnector.tgz} + resolution: {integrity: sha512-WvRBVd55BTyxySByj4m01OICyG2QuDHlXG+vb6h6x6aJhBfdKDfVIpkgc3mN7ZlLEf4/Y+M0y+LE6m2fHycNNQ==, tarball: file:projects/arm-resourceconnector.tgz} name: '@rush-temp/arm-resourceconnector' version: 0.0.0 dependencies: @@ -17510,7 +17538,7 @@ packages: dev: false file:projects/arm-resourcegraph.tgz: - resolution: {integrity: sha512-zt+Vq3JcyL3I8Ub+gIOciyGsPei1xSzr4avLlo/1Icu/DUKfjWRMB9/oPw3vcag6MpnyUJB4w2OJmYSvvocfAw==, tarball: file:projects/arm-resourcegraph.tgz} + resolution: {integrity: sha512-HEISrhVsPIGMZa6HF7h1sSM9hue3A3umpzEx5SXJ9qEvZtojnSrR5/HnQ3z8y4SXptvXTq0TncU/zrE+hmOdLA==, tarball: file:projects/arm-resourcegraph.tgz} name: '@rush-temp/arm-resourcegraph' version: 0.0.0 dependencies: @@ -17533,7 +17561,7 @@ packages: dev: false file:projects/arm-resourcehealth.tgz: - resolution: {integrity: sha512-CND6LxyCmxBUzrY5ni9mTBRL/kTp6PNC4NumMd/0pSumq7XpXxkeuvSxH7/W9vtXsW3bq4RnZ5ztGVAES0kY6A==, tarball: file:projects/arm-resourcehealth.tgz} + resolution: {integrity: sha512-wlQx4upNlk7GsjQ/OMiXtiHkzmhV2EDqWmi8i10OUOFzuLHVHO1In44LkAB3QgOwJw5jiHiGof/0ZD750BmFGg==, tarball: file:projects/arm-resourcehealth.tgz} name: '@rush-temp/arm-resourcehealth' version: 0.0.0 dependencies: @@ -17557,7 +17585,7 @@ packages: dev: false file:projects/arm-resourcemover.tgz: - resolution: {integrity: sha512-Azt5njXdfY6x+9jgQugEFe/YaycUr91RBFYHIEY1l4felKxSI3bar2T45+53rA85UEo8Sufkd7YT3PeFl9yFOw==, tarball: file:projects/arm-resourcemover.tgz} + resolution: {integrity: sha512-tocJoKmOBn6CzYE+WbQv/xW2OjI48VYIrwBfPR8No6n8p/rW+3J5iOvUAA9uyx/USpbb1KHN7eZZmFabildxfA==, tarball: file:projects/arm-resourcemover.tgz} name: '@rush-temp/arm-resourcemover' version: 0.0.0 dependencies: @@ -17583,7 +17611,7 @@ packages: dev: false file:projects/arm-resources-profile-2020-09-01-hybrid.tgz: - resolution: {integrity: sha512-VwAfpXfUHjRRHKkzw+/cMpsYDLylwMBVGRuytb9xPk9VzFkaxi5YfE7B6tFPh8ZJVSX4KG2DxF0u4FZPj8R0Og==, tarball: file:projects/arm-resources-profile-2020-09-01-hybrid.tgz} + resolution: {integrity: sha512-hElYtiiQ1WA7I/0SLcupfvlXI47QyWBcqN7+vgY6wLQOEzgl9DCucUHoTB3hdBLlzAfpyAK6UFXuY5h8eUXwDA==, tarball: file:projects/arm-resources-profile-2020-09-01-hybrid.tgz} name: '@rush-temp/arm-resources-profile-2020-09-01-hybrid' version: 0.0.0 dependencies: @@ -17609,22 +17637,26 @@ packages: dev: false file:projects/arm-resources-subscriptions.tgz: - resolution: {integrity: sha512-3GshuzJoZ2mMUbrXj2kgMGfKQ8F34Oet0t18nsgO8pkIgdimL3Z1t940dtZwzSCZp8oOmRYstcZTFw7tsJxY9w==, tarball: file:projects/arm-resources-subscriptions.tgz} + resolution: {integrity: sha512-POy06m89VsJ7Bizd9bgSGd9VzYa+m+xCX7T0Upjf+xZ5770ZEMemiMuxUu+7gVREuUPw0+wTOmhe1Pfg8+DowA==, tarball: file:projects/arm-resources-subscriptions.tgz} name: '@rush-temp/arm-resources-subscriptions' version: 0.0.0 dependencies: '@azure-tools/test-credential': 1.3.1 '@azure-tools/test-recorder': 3.5.2 + '@microsoft/api-extractor': 7.47.11(@types/node@18.19.60) '@types/chai': 4.3.20 '@types/mocha': 10.0.9 '@types/node': 18.19.60 chai: 4.3.10 cross-env: 7.0.3 dotenv: 16.4.5 + mkdirp: 3.0.1 mocha: 10.7.3 - ts-node: 10.9.2(@types/node@18.19.60)(typescript@5.6.3) + rimraf: 5.0.10 + ts-node: 10.9.2(@types/node@18.19.60)(typescript@5.5.4) tslib: 2.8.0 - typescript: 5.6.3 + tsx: 4.19.2 + typescript: 5.5.4 uglify-js: 3.19.3 transitivePeerDependencies: - '@swc/core' @@ -17633,7 +17665,7 @@ packages: dev: false file:projects/arm-resources.tgz: - resolution: {integrity: sha512-5mk6UhoGJx9GXeZAkT8xLGH7BU2Ltoeg8agQ2dFg7qFQDJcDSxk5eAOTq8kyQAwKavQoW2hZ+7vyJsfaFJkpKA==, tarball: file:projects/arm-resources.tgz} + resolution: {integrity: sha512-7fXPWgc8lPjg4hBsssBJjjfdn8Fxn6EHkoOxO2B3CWfPCFG2BGJDZwniSrDtSLO1E4YMErjipx+nF8ojzNMylw==, tarball: file:projects/arm-resources.tgz} name: '@rush-temp/arm-resources' version: 0.0.0 dependencies: @@ -17641,16 +17673,20 @@ packages: '@azure-tools/test-recorder': 3.5.2 '@azure/abort-controller': 1.1.0 '@azure/core-lro': 2.7.2 + '@microsoft/api-extractor': 7.47.11(@types/node@18.19.60) '@types/chai': 4.3.20 '@types/mocha': 10.0.9 '@types/node': 18.19.60 chai: 4.3.10 cross-env: 7.0.3 dotenv: 16.4.5 + mkdirp: 3.0.1 mocha: 10.7.3 - ts-node: 10.9.2(@types/node@18.19.60)(typescript@5.6.3) + rimraf: 5.0.10 + ts-node: 10.9.2(@types/node@18.19.60)(typescript@5.5.4) tslib: 2.8.0 - typescript: 5.6.3 + tsx: 4.19.2 + typescript: 5.5.4 uglify-js: 3.19.3 transitivePeerDependencies: - '@swc/core' @@ -17659,7 +17695,7 @@ packages: dev: false file:projects/arm-resourcesdeploymentstacks.tgz: - resolution: {integrity: sha512-SoY9+L2m9ofQtRps+BuWDH7tAYZvmRyUjh4qMr5cQA2Li434FzHdKlKsxUBQC9rHjsUHo3PSNXN5FwUtCicVmw==, tarball: file:projects/arm-resourcesdeploymentstacks.tgz} + resolution: {integrity: sha512-vyoZmMsIs7CmQbeb6zgstMi8xpkfC6kl1F9FTafeMEXjqQCjTyAXPJ4/p1kd00WxfKNEFoz2ac6BB8C+ktyJMA==, tarball: file:projects/arm-resourcesdeploymentstacks.tgz} name: '@rush-temp/arm-resourcesdeploymentstacks' version: 0.0.0 dependencies: @@ -17667,17 +17703,20 @@ packages: '@azure-tools/test-recorder': 3.5.2 '@azure/abort-controller': 1.1.0 '@azure/core-lro': 2.7.2 + '@microsoft/api-extractor': 7.47.11(@types/node@18.19.60) '@types/chai': 4.3.20 '@types/mocha': 10.0.9 '@types/node': 18.19.60 chai: 4.3.10 cross-env: 7.0.3 dotenv: 16.4.5 + mkdirp: 3.0.1 mocha: 10.7.3 - ts-node: 10.9.2(@types/node@18.19.60)(typescript@5.6.3) + rimraf: 5.0.10 + ts-node: 10.9.2(@types/node@18.19.60)(typescript@5.5.4) tslib: 2.8.0 tsx: 4.19.2 - typescript: 5.6.3 + typescript: 5.5.4 uglify-js: 3.19.3 transitivePeerDependencies: - '@swc/core' @@ -17686,7 +17725,7 @@ packages: dev: false file:projects/arm-scvmm.tgz: - resolution: {integrity: sha512-Wp44NCy8XQNOwxPjdNpyw0nlIeMZrxD08YtNqxkUBqMElFSzbQ6voWu/ppRl19CrmXaFfc4l61WzxW4IGy1+jA==, tarball: file:projects/arm-scvmm.tgz} + resolution: {integrity: sha512-IkDSuGRG/In8MZUE3PCDcj/tSpEZNGj0JTGdbsFHf4CKYvis8iUE/8XgdYbyyRBsyS47zXQl+gFJekNqiLNTCw==, tarball: file:projects/arm-scvmm.tgz} name: '@rush-temp/arm-scvmm' version: 0.0.0 dependencies: @@ -17713,7 +17752,7 @@ packages: dev: false file:projects/arm-search.tgz: - resolution: {integrity: sha512-yxGURB83OS6KMu4iZl1PQ0irwSwp41ty24xxHz5ieKwQx0+6oLJCc3zDLVWneQlCS4Tmy4p/SrdN549utANdVw==, tarball: file:projects/arm-search.tgz} + resolution: {integrity: sha512-n+s11i5BNDy+Rw5gO4trne5+HjikY6WR/QO9jPKq1tBRz/aFOkD9wo4sXBK/KX+MMa5xC0Wz4htXNRpY2eRrvw==, tarball: file:projects/arm-search.tgz} name: '@rush-temp/arm-search' version: 0.0.0 dependencies: @@ -17740,7 +17779,7 @@ packages: dev: false file:projects/arm-security.tgz: - resolution: {integrity: sha512-DzUyKx54FzbSgKvEgBX92Ldh1fOV7TIZhqlhK3uVAa3O2EfNnsvzRePy+DW5jTc4s/moOGZvarAyPTKkxT7G/g==, tarball: file:projects/arm-security.tgz} + resolution: {integrity: sha512-A4jz68oBz7rZ2oTZ/3Rokdyf0kVrMwmLMzzOFKPQ2aeo3uvhW54I/njQNx81ca8z9s4p0nrIa74plV61vDinGQ==, tarball: file:projects/arm-security.tgz} name: '@rush-temp/arm-security' version: 0.0.0 dependencies: @@ -17767,7 +17806,7 @@ packages: dev: false file:projects/arm-securitydevops.tgz: - resolution: {integrity: sha512-NaoBdffm161W6JyW9I51I5kenv2RQ20xdtzp97MgGd1Hl6HLRfqYTe90vB8R+XOUdCvrRhs7BU+0cN5frjmzNA==, tarball: file:projects/arm-securitydevops.tgz} + resolution: {integrity: sha512-koxVWAlX3HjFQ7C+k9E1Py60tVX21MMRkdcRl+tRfTloZDtr51M/dWxwXWXx45l0cvfuLTPPdQyInGyEd97mhg==, tarball: file:projects/arm-securitydevops.tgz} name: '@rush-temp/arm-securitydevops' version: 0.0.0 dependencies: @@ -17793,7 +17832,7 @@ packages: dev: false file:projects/arm-securityinsight.tgz: - resolution: {integrity: sha512-MsSKvuDHC/KxtXmjhmLATe/b9YsmzxPsmzlfkdro8nu8kHPDwJDvlVZxapBko9os4ktT9vWieViHubqDp9phwQ==, tarball: file:projects/arm-securityinsight.tgz} + resolution: {integrity: sha512-Mw1foXkkXkHAlQVMwLbHxusqxUHZhzEaJXX1oyF5vPV0S+9+hOTXA9F5W+EwxM5mKs6sgI5FTU0OCTvayCdSZQ==, tarball: file:projects/arm-securityinsight.tgz} name: '@rush-temp/arm-securityinsight' version: 0.0.0 dependencies: @@ -17819,7 +17858,7 @@ packages: dev: false file:projects/arm-selfhelp.tgz: - resolution: {integrity: sha512-FIM8bZQZfOqujixVQ6sBnZWcP2OMpHDxY2fmNNpoERA7hujTxgh0gASJpXOzHWkl7M6vC3PFMcV31kltlK1RXQ==, tarball: file:projects/arm-selfhelp.tgz} + resolution: {integrity: sha512-rAIMW9bdLgqaZZuN8bau8HZbFNOZSp00dzkCYLqW5Is3MwHMZfjtFxyrbZMRRq1lNUzEED8f2obMwH96dxf3qw==, tarball: file:projects/arm-selfhelp.tgz} name: '@rush-temp/arm-selfhelp' version: 0.0.0 dependencies: @@ -17846,7 +17885,7 @@ packages: dev: false file:projects/arm-serialconsole.tgz: - resolution: {integrity: sha512-KhKjQIXoN9kmzBuLDhNy94p99eV5Owxy14yMsHW2TUQXasVS86Y3GpV1h34FBqsRwHWZCCA0HohNUkj+5/He9A==, tarball: file:projects/arm-serialconsole.tgz} + resolution: {integrity: sha512-0eqI5gpaw5sPHxXkPL9SkMrjLIw7mHLFuN8Ym1CkaTerHazQU7/KbIrDzfA8NjwPJuyboGn+ZDrTyl9chuyWNQ==, tarball: file:projects/arm-serialconsole.tgz} name: '@rush-temp/arm-serialconsole' version: 0.0.0 dependencies: @@ -17869,7 +17908,7 @@ packages: dev: false file:projects/arm-servicebus.tgz: - resolution: {integrity: sha512-DLHJTD6lXhv53IAakQiac+ZCpkEBKCD90Yo2KnS3S1UW4wXOJP0VD75AE4Qh2tyjx3hfrI5pT/r6R8SBqjb+1A==, tarball: file:projects/arm-servicebus.tgz} + resolution: {integrity: sha512-XXpsjBsIBWnaFPo9/pvwuDJVGZzn6iDSK9BUwrElxXxRY7Y2pzTgsD8Gx53WCgARwYxbAOT+ewq1XYmsWArGQg==, tarball: file:projects/arm-servicebus.tgz} name: '@rush-temp/arm-servicebus' version: 0.0.0 dependencies: @@ -17895,7 +17934,7 @@ packages: dev: false file:projects/arm-servicefabric-1.tgz: - resolution: {integrity: sha512-1ByotN30vmBNb0UCBdaIYWZWoBNzAhF8bUbOIDzuEAtvtEtkzodVZBTaM6YXUCWFwolFudZriK+34D8WAg2IwQ==, tarball: file:projects/arm-servicefabric-1.tgz} + resolution: {integrity: sha512-UkPW4KAUDPabOTuX7yEtA/gsztUDwgwJ6sOIYdxJbuEkPan5kH4FPWDoL7ZNL4uQQA+lgvTuq0suOsFsphPWTw==, tarball: file:projects/arm-servicefabric-1.tgz} name: '@rush-temp/arm-servicefabric-1' version: 0.0.0 dependencies: @@ -17964,7 +18003,7 @@ packages: dev: false file:projects/arm-servicefabricmanagedclusters.tgz: - resolution: {integrity: sha512-mBF9anrHozmDN7bROJOGmbZFSk2zU5k4QveDu5wau6DrxA5mShPzlfix+pn3mlqe2Mi8VEEWhiy6RjY2d447SQ==, tarball: file:projects/arm-servicefabricmanagedclusters.tgz} + resolution: {integrity: sha512-cYmLR/ywIid0ixqwr3d0b7ZsEZ13+WKL0ETEI2FQA8YMcnwQuiHmV0oZ9N/tZ2HCLtDsEXxMnu2p4O6QiskYXw==, tarball: file:projects/arm-servicefabricmanagedclusters.tgz} name: '@rush-temp/arm-servicefabricmanagedclusters' version: 0.0.0 dependencies: @@ -17990,7 +18029,7 @@ packages: dev: false file:projects/arm-servicefabricmesh.tgz: - resolution: {integrity: sha512-0Po1sKVq4JPYD+4/T8yIlg+LwCdkSCoF2Eac2pUyGlLlIxnUdDLy2jh3wfASzMu3XJUnwU59HLFnKf4swR59Sg==, tarball: file:projects/arm-servicefabricmesh.tgz} + resolution: {integrity: sha512-5S2KTrP9/bYBGWNhpOeWCtiHle0027EpJ70TtqpjMaflPxmkZG0jugt5MMapWgIvXQxKXzZe53s9lPCr5tjV6A==, tarball: file:projects/arm-servicefabricmesh.tgz} name: '@rush-temp/arm-servicefabricmesh' version: 0.0.0 dependencies: @@ -18014,7 +18053,7 @@ packages: dev: false file:projects/arm-servicelinker.tgz: - resolution: {integrity: sha512-LqYGnKNVKhgEUZGLvVxDO02uL/YOkB9CibwFvJqj4JXK8omBBEZ207WivqhvsVHu9Ot4VARa/WpXP/XWMxSd4A==, tarball: file:projects/arm-servicelinker.tgz} + resolution: {integrity: sha512-3R/rNbDNbk6WNHEw0rssfsc9pSVOQS2qdQt4gbpvsicHbbuaplndcl2PVIbR0k6TiwyjjhKDP1i+iB1Mr1cHMA==, tarball: file:projects/arm-servicelinker.tgz} name: '@rush-temp/arm-servicelinker' version: 0.0.0 dependencies: @@ -18040,7 +18079,7 @@ packages: dev: false file:projects/arm-servicemap.tgz: - resolution: {integrity: sha512-tH1naGzN2wEK1RBMwTDlC/XWHXSyUeJPJtSCiYojg9c0DqlK/xGKFL5B7zT07q1w8bgoTTEsNqnI9Y6UC6nq+Q==, tarball: file:projects/arm-servicemap.tgz} + resolution: {integrity: sha512-6sZ5fzUaQOUAQYvbI09HbSwJQlYw2AJfcPJeIlaxpoGQaroGOrQP+3juOQRV6CLKxKC3y+9hwkRRJ5+GQMN9ag==, tarball: file:projects/arm-servicemap.tgz} name: '@rush-temp/arm-servicemap' version: 0.0.0 dependencies: @@ -18064,7 +18103,7 @@ packages: dev: false file:projects/arm-servicenetworking.tgz: - resolution: {integrity: sha512-PDsDBz1ITiBx3DPAgd2AUvi/v6kBIfXbXM8a8jKE5BvJymrVfFvsEVx3CshoVCXA9jS3tioqlEDZHhnoxFU3jg==, tarball: file:projects/arm-servicenetworking.tgz} + resolution: {integrity: sha512-dlR5VuqP/J1HuILRmFfW2Z9FzlQayg0+ku7VqRJGmMq5GQVdshtjFiFOUucHPMogRTPkJzHMdSg+WxPBFOpNIA==, tarball: file:projects/arm-servicenetworking.tgz} name: '@rush-temp/arm-servicenetworking' version: 0.0.0 dependencies: @@ -18090,7 +18129,7 @@ packages: dev: false file:projects/arm-signalr.tgz: - resolution: {integrity: sha512-zakMrJF9g3yCy3QOzDKRN8e9SjCwl+u+iQyutMOo3pbCWPWyF8L8QQ/ZexeRUD5X+tIGuiF8Cn491vAIJgS9dw==, tarball: file:projects/arm-signalr.tgz} + resolution: {integrity: sha512-+EyyVlH2g8oooG/WFOmsmzM1K30ls7Alu90snbEX73iQVSWp0w1oSJqVX7Q5gd4T+jX10Lj/RiM+Y3Eh6RiQqw==, tarball: file:projects/arm-signalr.tgz} name: '@rush-temp/arm-signalr' version: 0.0.0 dependencies: @@ -18116,7 +18155,7 @@ packages: dev: false file:projects/arm-sphere.tgz: - resolution: {integrity: sha512-02YxwyI4ij/BT4g6snb62BLv1ZDGbJfq29O7e+ap4VwLxED6xvNk7Nmrnl5lIvIRVE5K8BW+LMEQv0C7DvLhCQ==, tarball: file:projects/arm-sphere.tgz} + resolution: {integrity: sha512-sJ9RXt8qOy57qh3+hOxYV++0XEq97rVqPhR8HJx2ejPOCxO+NX20qe/eE0Od+tuopN2qOC1tqybUrQr/4FlJRA==, tarball: file:projects/arm-sphere.tgz} name: '@rush-temp/arm-sphere' version: 0.0.0 dependencies: @@ -18142,7 +18181,7 @@ packages: dev: false file:projects/arm-springappdiscovery.tgz: - resolution: {integrity: sha512-Xy33Z95ZFjsTSY7MYdLYDyjnVVtTfmd8iaCXL0EvzYmtj/zr5Kf28tP6O+i6k8DCqcuMDeuFUlprYBDHpCl6dQ==, tarball: file:projects/arm-springappdiscovery.tgz} + resolution: {integrity: sha512-V289qDyrO82985yV0sTv7tYbDfTb+Ge3vfj7/OSyfEfm6pU9ssfBflJdvshyIR9zdes0RX/v4PX5WPA0pOXEUg==, tarball: file:projects/arm-springappdiscovery.tgz} name: '@rush-temp/arm-springappdiscovery' version: 0.0.0 dependencies: @@ -18168,7 +18207,7 @@ packages: dev: false file:projects/arm-sql.tgz: - resolution: {integrity: sha512-PQcf+XVMF+Be/95kf2sPfUG6SXRfS1Tx3+mk/KeK2Jqd9xii0OBB8aiPc2K3PN3fQ4/2VimdhYQOLGDFwRQkDw==, tarball: file:projects/arm-sql.tgz} + resolution: {integrity: sha512-se1ZeJlsit25W02uINHCZTa21gS3G/xWMl4acJziviYVkxPEVz3XJvvEbRHIGuBdntyai2Zt8BkuSN5ksA9qKA==, tarball: file:projects/arm-sql.tgz} name: '@rush-temp/arm-sql' version: 0.0.0 dependencies: @@ -18194,7 +18233,7 @@ packages: dev: false file:projects/arm-sqlvirtualmachine.tgz: - resolution: {integrity: sha512-T0/VDYmuHTqLNt/+vIpUfXcW5XXJ5z7PXsoLZikBLK4GTzcTZdtCq3KmuVg1Sto7awhXgCWIxEu1ceeTtILXtw==, tarball: file:projects/arm-sqlvirtualmachine.tgz} + resolution: {integrity: sha512-sFItJqWDgDsKvOkWiYbWfnhYZphqbMUGQs/KfhV9MshG9U5KaioMgMKVIrY2TPeDeXgTzVeH5Ep9POmFQor0Cw==, tarball: file:projects/arm-sqlvirtualmachine.tgz} name: '@rush-temp/arm-sqlvirtualmachine' version: 0.0.0 dependencies: @@ -18220,7 +18259,7 @@ packages: dev: false file:projects/arm-standbypool.tgz: - resolution: {integrity: sha512-0Vt1jIelltknz/Tsd+RLwdf2pG3doc9ybKC0s+qjU5iAhXxGNltLbOmb8/34lVDDLbuvkpRKko286oE81Zbr5g==, tarball: file:projects/arm-standbypool.tgz} + resolution: {integrity: sha512-d2xnd2nJyWATOqT3IDONbjSerCpYzZzzoD96MrMUpOEwjbePLcyjJw8ft9YyO2QHK7OOUG0WuN9rqv6eCQLxIQ==, tarball: file:projects/arm-standbypool.tgz} name: '@rush-temp/arm-standbypool' version: 0.0.0 dependencies: @@ -18257,7 +18296,7 @@ packages: dev: false file:projects/arm-storage-profile-2020-09-01-hybrid.tgz: - resolution: {integrity: sha512-y2KYe01ZM00Kn0//B9nA0LyKqp5QQ24JaYeUL2lGOQlrISnMQdMA2WkDv5xVbDXjOU8kKNFOLC/NaMDzZj972A==, tarball: file:projects/arm-storage-profile-2020-09-01-hybrid.tgz} + resolution: {integrity: sha512-z8Lv8O+VWPvgzkAU2gK6MqjS6jMSMONVVwSBE7nOMJdBKi0CJ4MLxjfWxdF8aC7m8/AmDIuoW/Kn7UwUT1BOjQ==, tarball: file:projects/arm-storage-profile-2020-09-01-hybrid.tgz} name: '@rush-temp/arm-storage-profile-2020-09-01-hybrid' version: 0.0.0 dependencies: @@ -18282,7 +18321,7 @@ packages: dev: false file:projects/arm-storage.tgz: - resolution: {integrity: sha512-2xtuD+P2oF0YYh24woE7Pes1TkLwI2ttkarbZZVEMVsQ64aeLMactfcmwMJ/o6bKDhsgbEUUEMynlnwqS7/Y3Q==, tarball: file:projects/arm-storage.tgz} + resolution: {integrity: sha512-vWmWoibG6ImOO5tVpJ6Q/UNlT9C5ghHiA4qcvBxQ6GVa0vTu2Jbi7Ej4zv3ss3gbeG9Ve7wFUtZxELpD+M9nLA==, tarball: file:projects/arm-storage.tgz} name: '@rush-temp/arm-storage' version: 0.0.0 dependencies: @@ -18308,7 +18347,7 @@ packages: dev: false file:projects/arm-storageactions.tgz: - resolution: {integrity: sha512-RNIrlTNN9dhIJd8Xc7xfYyG1B81aJ5RRTt2WJpUCWL6UPkM03J9yLmRwiboLIbseKhItzcg4hdIOWY4gxLlz8g==, tarball: file:projects/arm-storageactions.tgz} + resolution: {integrity: sha512-uZOaO0V1Tz+/RKKxZ1PCxvNg/5zEwbba4l+IDurwSVQSeJ4UPRo0WgXacJfXqaIX/ahmfGg8WFHF0aUnA1Kqng==, tarball: file:projects/arm-storageactions.tgz} name: '@rush-temp/arm-storageactions' version: 0.0.0 dependencies: @@ -18334,7 +18373,7 @@ packages: dev: false file:projects/arm-storagecache.tgz: - resolution: {integrity: sha512-YfTyfHS4+wiJsg1eZr5BMEaVSsc0xzApI+Gh+G3ACoBy1Kn/2cQpapbMAU8YbvPKy4JZfNU5gpNFqOhR+TCUkw==, tarball: file:projects/arm-storagecache.tgz} + resolution: {integrity: sha512-ML3pmksKCIrD52c1Ihu5VTLx6T3wNYZVnLR4JmuAi7RulNdTwVjuzFHsOtGkySf0bUkIhhPzrl5NLUOXZJHQTA==, tarball: file:projects/arm-storagecache.tgz} name: '@rush-temp/arm-storagecache' version: 0.0.0 dependencies: @@ -18361,7 +18400,7 @@ packages: dev: false file:projects/arm-storageimportexport.tgz: - resolution: {integrity: sha512-fkzlpWEOxN51+BA3vrg8GU97KkBc/f3+0dyumoXU/5uQfMx9CqE80HahU9M5C/ds4wKqDr+7ZO2FKwmJwh+1ew==, tarball: file:projects/arm-storageimportexport.tgz} + resolution: {integrity: sha512-dheD+NOeWSyWf6xmh1RCVBqg+mVHXVRfnYUKW5eBvg+xdkoiAlK7OhrX7ud/XAfuUXc1IiG5PWERDkr0uenKUg==, tarball: file:projects/arm-storageimportexport.tgz} name: '@rush-temp/arm-storageimportexport' version: 0.0.0 dependencies: @@ -18385,7 +18424,7 @@ packages: dev: false file:projects/arm-storagemover.tgz: - resolution: {integrity: sha512-dWhAb6bWRSqSZ3u/ewLVOOWAmNpoO1BtJZkyy0GEnzuP4gD0K37vtxMJO2t24SSNZZ4iTWn9+Glv0dbkrlCiww==, tarball: file:projects/arm-storagemover.tgz} + resolution: {integrity: sha512-W0pYTdeaObMpPw+JnfWB2+2SAxIv9mh/ZS2ojkASrFyIatOl+hv3YrgNeqzN0ZpMmYQ3ojn6brHfX3et+FwFeA==, tarball: file:projects/arm-storagemover.tgz} name: '@rush-temp/arm-storagemover' version: 0.0.0 dependencies: @@ -18412,7 +18451,7 @@ packages: dev: false file:projects/arm-storagesync.tgz: - resolution: {integrity: sha512-Il72MwiqXjTbElT5k6g6Fj/1b0Nh39xxJsleLJPsLvf3x/CBcfa5qopqMcVnLf1tU9TmEA1zQnE6e36F3Hn5Mw==, tarball: file:projects/arm-storagesync.tgz} + resolution: {integrity: sha512-xOdHMsiYEZZKOVYfFO14MAHN+OyaxH8W6dAeS29pseD9gebFZP9It9pRXDeOmHbqh5e/0BYJrJ7S+Kmb+uCCJA==, tarball: file:projects/arm-storagesync.tgz} name: '@rush-temp/arm-storagesync' version: 0.0.0 dependencies: @@ -18437,7 +18476,7 @@ packages: dev: false file:projects/arm-storsimple1200series.tgz: - resolution: {integrity: sha512-cbNTmgZw84B82A0QENDRqZ5dwP7iSUMLt8HRR96c8dU+eoMVF2RL37ZEuMGd4yv68fThHXWVJezZOz7tpuSgWg==, tarball: file:projects/arm-storsimple1200series.tgz} + resolution: {integrity: sha512-hlPPRSxi6hBcWG3pG+ujvQhWm1Gyg48f6but8gjFywnggVklvnjSo9BlSi7HXsAFuo1TTh47/ev0+5lPx/jMlQ==, tarball: file:projects/arm-storsimple1200series.tgz} name: '@rush-temp/arm-storsimple1200series' version: 0.0.0 dependencies: @@ -18462,7 +18501,7 @@ packages: dev: false file:projects/arm-storsimple8000series.tgz: - resolution: {integrity: sha512-KSeB2ezkPGeygIg4eDg+lXisYXowGRLaQhzXjnjKBHUuo+7mRxglC54+ZBOKisImi3Uml7UYuFNH2MF8bfW6cw==, tarball: file:projects/arm-storsimple8000series.tgz} + resolution: {integrity: sha512-zzgeLtSD3nbuxDLv+lyBTqxa7DDU3t+g1hY9oWA4VtO0qv43l1OkBVeFlkqRNqQ8q8g71lyP4W4x0nD7UMD1kg==, tarball: file:projects/arm-storsimple8000series.tgz} name: '@rush-temp/arm-storsimple8000series' version: 0.0.0 dependencies: @@ -18487,7 +18526,7 @@ packages: dev: false file:projects/arm-streamanalytics.tgz: - resolution: {integrity: sha512-s/Xr13Oi1QUflBsPxjgfuGEu+cWERVArOhjnkFM5HBCskwUOxGEUdhqMSTlaKGF1OFp6Va6G2264QihBRaMnQg==, tarball: file:projects/arm-streamanalytics.tgz} + resolution: {integrity: sha512-jVGA4g/NjMBp/+JPPjd5Ya9pZS8aNKzor7hbMDQT67bBEp8zdFKq0jFjh2/ABcbTu6Ee3g8/9pu73x2je/8AOw==, tarball: file:projects/arm-streamanalytics.tgz} name: '@rush-temp/arm-streamanalytics' version: 0.0.0 dependencies: @@ -18513,7 +18552,7 @@ packages: dev: false file:projects/arm-subscriptions-profile-2020-09-01-hybrid.tgz: - resolution: {integrity: sha512-fhV07fHpX+SNEP8aXB4ub7wOZk11pO3iQShGkoB0mP+xQEwbr/WONRaoUnLt9wvOJuUZuoWr1YjOyIrro/I56A==, tarball: file:projects/arm-subscriptions-profile-2020-09-01-hybrid.tgz} + resolution: {integrity: sha512-tp/2vlQ64r0Qft0dYnntMOl+5gjlEp0bYDYnTtipfqQzt+bD/h9k7a+3wUlYg2EFm4NHTwj18X7WMFwudlPpGA==, tarball: file:projects/arm-subscriptions-profile-2020-09-01-hybrid.tgz} name: '@rush-temp/arm-subscriptions-profile-2020-09-01-hybrid' version: 0.0.0 dependencies: @@ -18537,7 +18576,7 @@ packages: dev: false file:projects/arm-subscriptions.tgz: - resolution: {integrity: sha512-mOYbaR2cuZv03zKeX6AygGwOrf3fVLktk8cMOTdNd1pPqouhITDKApvYss1y7TMXMkryhxknrymCuopETZ+Skg==, tarball: file:projects/arm-subscriptions.tgz} + resolution: {integrity: sha512-X4QxnXd8CQSzk2Y8QV0x6F2t6B2T01IUbulm7TLTpf068zTzbaBPVlgdyIuZSeHHGeOgYfDs8omwkrLEcO/f3Q==, tarball: file:projects/arm-subscriptions.tgz} name: '@rush-temp/arm-subscriptions' version: 0.0.0 dependencies: @@ -18562,7 +18601,7 @@ packages: dev: false file:projects/arm-support.tgz: - resolution: {integrity: sha512-7wzRerODj3gRUGCob170Xberw+OKK/2B0NtxJBZ6XW6AVybOqjTGE0/3YsUTfjcqazvNK73unh7IiYzuqPmGLA==, tarball: file:projects/arm-support.tgz} + resolution: {integrity: sha512-ZUxJ2+wlIoI2WbWBLatWmEJFBs2duTUzSHfhBV5gEkJQcErYbe7fJ7tQXHLC2NTIbnZofGTpz+sXaiv0ksAJXQ==, tarball: file:projects/arm-support.tgz} name: '@rush-temp/arm-support' version: 0.0.0 dependencies: @@ -18588,7 +18627,7 @@ packages: dev: false file:projects/arm-synapse.tgz: - resolution: {integrity: sha512-KWRiBMdiDd9XOpYTWJxcojiXG3cDt1AF6rMqfbtmzsPL6uCtpkPBBL8/k/oYuvmD7EjL5hAFQbZLi8ui40CmzA==, tarball: file:projects/arm-synapse.tgz} + resolution: {integrity: sha512-LKw+pvRNIT1RpFrgyue0JbFdNHfxcpt2BE/8rjN/9YVRwqGsHMyMrKf9RiX8eLL3PV124/csgE2ICeFaiPjQNA==, tarball: file:projects/arm-synapse.tgz} name: '@rush-temp/arm-synapse' version: 0.0.0 dependencies: @@ -18614,21 +18653,26 @@ packages: dev: false file:projects/arm-templatespecs.tgz: - resolution: {integrity: sha512-SuJxPW0gwB7yuBEf2pgPcM55cEdkFQ8dblDCdTHf08r/GshHwWb7hM6fweHkxdWvqggsdPvr9yVUrVrGQselJQ==, tarball: file:projects/arm-templatespecs.tgz} + resolution: {integrity: sha512-Hl7AuZ2uPjsh6BoJICC6ojDSrAUyIEDLAxJy8d09mnbdSAI5PU9bbvzFt4eg0qv9fX8pmSvrKr+CJ9C0WErngw==, tarball: file:projects/arm-templatespecs.tgz} name: '@rush-temp/arm-templatespecs' version: 0.0.0 dependencies: '@azure-tools/test-credential': 1.3.1 '@azure-tools/test-recorder': 3.5.2 + '@microsoft/api-extractor': 7.47.11(@types/node@18.19.60) '@types/chai': 4.3.20 '@types/mocha': 10.0.9 '@types/node': 18.19.60 chai: 4.3.10 cross-env: 7.0.3 + dotenv: 16.4.5 + mkdirp: 3.0.1 mocha: 10.7.3 - ts-node: 10.9.2(@types/node@18.19.60)(typescript@5.6.3) + rimraf: 5.0.10 + ts-node: 10.9.2(@types/node@18.19.60)(typescript@5.5.4) tslib: 2.8.0 - typescript: 5.6.3 + tsx: 4.19.2 + typescript: 5.5.4 uglify-js: 3.19.3 transitivePeerDependencies: - '@swc/core' @@ -18637,7 +18681,7 @@ packages: dev: false file:projects/arm-timeseriesinsights.tgz: - resolution: {integrity: sha512-k1nVmWdJm4DgNenVfzATdoOZqIanvg7idA5mk2+78mUM0DVhPRkCbck/vtcZEOKDxA/h0LBXs6RNqr8j8hngDQ==, tarball: file:projects/arm-timeseriesinsights.tgz} + resolution: {integrity: sha512-qQCDGM8v7/+j+b5w9fO24BhynXYoYswVqNPqGO1KN9VreNe85dOY37v3NYoAaDPRiU48j4VIfHMBSPopNx2Nzg==, tarball: file:projects/arm-timeseriesinsights.tgz} name: '@rush-temp/arm-timeseriesinsights' version: 0.0.0 dependencies: @@ -18663,7 +18707,7 @@ packages: dev: false file:projects/arm-trafficmanager.tgz: - resolution: {integrity: sha512-1qFvXTMM3our8wSMI3BqVGRVeW2HoiJmE+R40kWBBgf76hK/FaKfTWSnbkJs1L5P9QI8ShnGgC+7plqbZTXHEg==, tarball: file:projects/arm-trafficmanager.tgz} + resolution: {integrity: sha512-NGRVDDkeeMAe9BFQCGOMLvvrLFNLlPbQldybGTnPHxzjDsjvhJM71X2THGUnr6Vse4Dgv1bNmbZeCMGiFvoChw==, tarball: file:projects/arm-trafficmanager.tgz} name: '@rush-temp/arm-trafficmanager' version: 0.0.0 dependencies: @@ -18687,7 +18731,7 @@ packages: dev: false file:projects/arm-trustedsigning.tgz: - resolution: {integrity: sha512-Uqtlmb9jZLW/j3/5Xk5lNZcw4STcHT3lhWODOQLmJGl+6xM6iKOnxipHdMin2uUxnSJl2K1XOHljOxUBrpF8kg==, tarball: file:projects/arm-trustedsigning.tgz} + resolution: {integrity: sha512-/kLL/gGGZ5j6Yohrwb+FrM2goy4TVtPVZsV9xDfifm+kn0cCdhj40K4YBxD0E7+WaCIMaY1CitATyM+lvW+fag==, tarball: file:projects/arm-trustedsigning.tgz} name: '@rush-temp/arm-trustedsigning' version: 0.0.0 dependencies: @@ -18723,7 +18767,7 @@ packages: dev: false file:projects/arm-visualstudio.tgz: - resolution: {integrity: sha512-g4zjxhG7l0jt4UcdPPson6U0uDIDPqVEY/EwF3h2DSMXSPaxoaTURReWCxEmXr1NAbBx12sVZEnVWlGa6edcnQ==, tarball: file:projects/arm-visualstudio.tgz} + resolution: {integrity: sha512-9XsTNUjTtMM7ATd/Istp6UJ+7nGlRpUb5DbqfxHj+Tlv1qHffG4ENe9xyrlTdXWvfw7pfq38jAkBGpDC/cWn+g==, tarball: file:projects/arm-visualstudio.tgz} name: '@rush-temp/arm-visualstudio' version: 0.0.0 dependencies: @@ -18748,7 +18792,7 @@ packages: dev: false file:projects/arm-vmwarecloudsimple.tgz: - resolution: {integrity: sha512-f/3R5qrDZMILM773Nq1WIeuofAhaj2YaaPD06lhMbXl8C4wz4vYEYKrJMMooj1PCQ2/7a/cMCPhTU7nDU6v8tA==, tarball: file:projects/arm-vmwarecloudsimple.tgz} + resolution: {integrity: sha512-Z7SEduA3xHcTiDHQMJCwfUkWG0749fiCTHHriPps1Yp0RgAK9DRHOYnqAqZiyrXz7r+7ZsD4bfY8QsRlKxFoCg==, tarball: file:projects/arm-vmwarecloudsimple.tgz} name: '@rush-temp/arm-vmwarecloudsimple' version: 0.0.0 dependencies: @@ -18774,7 +18818,7 @@ packages: dev: false file:projects/arm-voiceservices.tgz: - resolution: {integrity: sha512-XkzkVJneev6XU2o7A6XEGbxQoB4oOm5JJd0bz+xPB4SNrEKAbxtOaAFKo/mV1B+pxy1pO/GtSsTDxKtaMHu4BA==, tarball: file:projects/arm-voiceservices.tgz} + resolution: {integrity: sha512-dfHQCqX2ztrUukZejbnuY5CXFSRBsc9P98c7vk2ygmBMKRLHAxgTbaHKNUpsHEomwJ7jE1I25sQ1TqzBRJTqRg==, tarball: file:projects/arm-voiceservices.tgz} name: '@rush-temp/arm-voiceservices' version: 0.0.0 dependencies: @@ -18800,7 +18844,7 @@ packages: dev: false file:projects/arm-webpubsub.tgz: - resolution: {integrity: sha512-IvfWqFTFohod1gGZ1RwbGY8ce7+vPJzG8kGOyTzjdt0snwlwyXesmPIup3zRYfC3Byvn9WMkbplSkORLa9z/zA==, tarball: file:projects/arm-webpubsub.tgz} + resolution: {integrity: sha512-BXhcAUVDPoGHHNqRgPMxjyKK50FSKZuiUKp2/5jbNFcalPAzdwqK1Lj4q7pO/jylGWi0pKlaVzFRae8U6DUD9A==, tarball: file:projects/arm-webpubsub.tgz} name: '@rush-temp/arm-webpubsub' version: 0.0.0 dependencies: @@ -18826,7 +18870,7 @@ packages: dev: false file:projects/arm-webservices.tgz: - resolution: {integrity: sha512-+WU+L/EKczzj+rAOfESbBec7AW+c4iuCvGMcyNAtxL1tbv3S/9AmE310/2WM6s2Gs5DXJ2V3+K8N3ck5VE/y8A==, tarball: file:projects/arm-webservices.tgz} + resolution: {integrity: sha512-fQ1C1Mb1OkfvoqpAslFM66gmA1gBnLj4FHKenpnR0UpC2EiKYJRpYY7VHMC174zA378SuqsvKnLBn6qz/jk0CA==, tarball: file:projects/arm-webservices.tgz} name: '@rush-temp/arm-webservices' version: 0.0.0 dependencies: @@ -18851,7 +18895,7 @@ packages: dev: false file:projects/arm-workloads.tgz: - resolution: {integrity: sha512-DByUoFzNPKlVQEyPqL35wXTfdM0Ls6jbLAiRlWlf2Opb2q/L1DnMh1MhwghNjP9xKG3K6Wuhz9VL5H5dfJxF5A==, tarball: file:projects/arm-workloads.tgz} + resolution: {integrity: sha512-nzUuNIe20mLJ7ccYGuTpQn3Bsu48E92sepo1BWyd8/2m4YEe1LDA99jOeN3GPxpwmRGw2ywGCaUjSwjaMjK1EQ==, tarball: file:projects/arm-workloads.tgz} name: '@rush-temp/arm-workloads' version: 0.0.0 dependencies: @@ -18877,7 +18921,7 @@ packages: dev: false file:projects/arm-workloadssapvirtualinstance.tgz: - resolution: {integrity: sha512-4m+MJ0YgSx5MzXhZpKBn2Rlm4niNzN960UaPKGvDT64vXzTxL+1dtZ0jU4sy6RCjC+QdhIUfiwyxUeZY3UKTiw==, tarball: file:projects/arm-workloadssapvirtualinstance.tgz} + resolution: {integrity: sha512-9n6MFLqWfUoOVAjBoIaatk21Pelrf+uUno5KuqadYAuQX6qn52I2iAvGIi5U+59B1dPP3UklgHHj6Io156KcNw==, tarball: file:projects/arm-workloadssapvirtualinstance.tgz} name: '@rush-temp/arm-workloadssapvirtualinstance' version: 0.0.0 dependencies: @@ -18903,7 +18947,7 @@ packages: dev: false file:projects/arm-workspaces.tgz: - resolution: {integrity: sha512-31B0Z4hfaIPGixfQDzZyk+vp20Z4kumAFG+WBup2dDrI28HcvhB6kEm2pOMdayV1aLLqtFwOaI1PcQPcXK6tjQ==, tarball: file:projects/arm-workspaces.tgz} + resolution: {integrity: sha512-+kRHA+7TnMkQUQ4z4WjM6l6owGYschRooj4SHCL9M+OmaLqDW2q18mFGli2/y2RmsKCL9HEYJXZI8Jxnu1xuUQ==, tarball: file:projects/arm-workspaces.tgz} name: '@rush-temp/arm-workspaces' version: 0.0.0 dependencies: @@ -23472,7 +23516,7 @@ packages: dev: false file:projects/synapse-access-control-1.tgz: - resolution: {integrity: sha512-Gfic50DkRfanG/fDbqZ5lJK2y2RlUo/ZGjWhPfh7+wFyr2tlERiBlTdTFHmAH0Y03mTOsE4N7fT2cILlsSwsfw==, tarball: file:projects/synapse-access-control-1.tgz} + resolution: {integrity: sha512-m3N1xErlj9HhfqNUHajK2+nn3vynK+3jHq4PmgEtJWkV2omwaVIIWQLkcvRonuJwZzoNx/xPJ+Q6r9yhu65EDg==, tarball: file:projects/synapse-access-control-1.tgz} name: '@rush-temp/synapse-access-control-1' version: 0.0.0 dependencies: @@ -23517,7 +23561,7 @@ packages: dev: false file:projects/synapse-access-control.tgz: - resolution: {integrity: sha512-5Lvxc9TxvzUJPSygvTv+jWTZZOO687PY0O0llh7/GeKyyf1ExSmdXgd4uhmGTmJPcTChW7IL+mobIWkCxuGOxg==, tarball: file:projects/synapse-access-control.tgz} + resolution: {integrity: sha512-SoSnPwhOcMKLwBXwh2GdKXb1fkX9NGMVONVwJkXxMp7aaa839w1SjXCGxIjK2BYabSvHk21c1ngZAPt+ZGILyg==, tarball: file:projects/synapse-access-control.tgz} name: '@rush-temp/synapse-access-control' version: 0.0.0 dependencies: @@ -23564,7 +23608,7 @@ packages: dev: false file:projects/synapse-artifacts.tgz: - resolution: {integrity: sha512-9QLFt6d9Gcihaz0JNHzXJEV2N6oA/dDKoKUOWI8YEdlGPDefFs3V6QW/JD1wt9Bg02yfJ/zg5Lo72gLYwsqaqw==, tarball: file:projects/synapse-artifacts.tgz} + resolution: {integrity: sha512-cPuXjLqnzeCwez71iefTUmVuKKvwYHGtzJZHZSYO93o7MzfjiRQ98fVwVyDzdAKxfT8iQ+IXRzhHdgEcXrm23A==, tarball: file:projects/synapse-artifacts.tgz} name: '@rush-temp/synapse-artifacts' version: 0.0.0 dependencies: @@ -23612,7 +23656,7 @@ packages: dev: false file:projects/synapse-managed-private-endpoints.tgz: - resolution: {integrity: sha512-scQ4B9GPdnrcdBpoNjw8G/qUCKck6EkiMILBrVCVp3nYbR4N4EpP9Qx3AdykyANvciHl6xh2eMo4R73jnMOM+Q==, tarball: file:projects/synapse-managed-private-endpoints.tgz} + resolution: {integrity: sha512-mPSzId+nr58eJ8zG06pkG06LJfaf1oygJmwL5ismIDlSIy0pkpMZ+3FbsuDgoUmK56lqmznQJmqrtc1y+UwOPg==, tarball: file:projects/synapse-managed-private-endpoints.tgz} name: '@rush-temp/synapse-managed-private-endpoints' version: 0.0.0 dependencies: @@ -23654,7 +23698,7 @@ packages: dev: false file:projects/synapse-monitoring.tgz: - resolution: {integrity: sha512-0CugypiAoB56SYC2+9u+A9rYHR3ceaG48vNHYPhx3cQLO92bJy0S3JD8wtytKv2TSnr5SIWhBICS5Ui5H6y8lg==, tarball: file:projects/synapse-monitoring.tgz} + resolution: {integrity: sha512-91dOmm1Kb5LinwQIYqcsf9h+zpsd9YhgCa6er7RSfpqG0qiXodPIeEcHsAMI8T8BmyobuZMJwcps588ZLCfiWQ==, tarball: file:projects/synapse-monitoring.tgz} name: '@rush-temp/synapse-monitoring' version: 0.0.0 dependencies: @@ -23690,7 +23734,7 @@ packages: dev: false file:projects/synapse-spark.tgz: - resolution: {integrity: sha512-4ZgEx+tTd2kNZ18vu0Sqs+eqmEZh3njI1j83J32oCs9nkzHU9VBS6Y15c/x9dZvN3HeOqRl0eZthdkjAdKGsKA==, tarball: file:projects/synapse-spark.tgz} + resolution: {integrity: sha512-dbTn8oGToq0IpLMUyE3dkTj1wtBSIcCTP5JS40x1jhjLmDEwMYbuBudZRIwE46IUJBKEVG+gyIZk3KX7ASKcSw==, tarball: file:projects/synapse-spark.tgz} name: '@rush-temp/synapse-spark' version: 0.0.0 dependencies: diff --git a/sdk/changes/arm-changes/CHANGELOG.md b/sdk/changes/arm-changes/CHANGELOG.md index 60ff25a11e58..af46fba93f5b 100644 --- a/sdk/changes/arm-changes/CHANGELOG.md +++ b/sdk/changes/arm-changes/CHANGELOG.md @@ -1,15 +1,13 @@ # Release History - -## 1.1.1 (Unreleased) - -### Features Added - + +## 2.0.0 (2024-11-01) + ### Breaking Changes -### Bugs Fixed - -### Other Changes - + - Interface ChangesListNextOptionalParams no longer has parameter skipToken + - Interface ChangesListNextOptionalParams no longer has parameter top + + ## 1.1.0 (2022-11-17) ### Features Added @@ -19,4 +17,4 @@ ## 1.0.0 (2022-05-09) -The package of @azure/arm-changes is using our next generation design principles. To learn more, please refer to our documentation [Quick Start](https://aka.ms/azsdk/js/mgmt/quickstart ). +The package of @azure/arm-changes is using our next generation design principles. To learn more, please refer to our documentation [Quick Start](https://aka.ms/azsdk/js/mgmt/quickstart). diff --git a/sdk/changes/arm-changes/LICENSE b/sdk/changes/arm-changes/LICENSE index 5d1d36e0af80..7d5934740965 100644 --- a/sdk/changes/arm-changes/LICENSE +++ b/sdk/changes/arm-changes/LICENSE @@ -1,6 +1,6 @@ The MIT License (MIT) -Copyright (c) 2022 Microsoft +Copyright (c) 2024 Microsoft Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal diff --git a/sdk/changes/arm-changes/_meta.json b/sdk/changes/arm-changes/_meta.json index 1bf4df740730..28591836c37e 100644 --- a/sdk/changes/arm-changes/_meta.json +++ b/sdk/changes/arm-changes/_meta.json @@ -1,8 +1,8 @@ { - "commit": "20df2424a278ca19437e437a7dbf3a7857a0dd9d", + "commit": "5342edb61d78cec6e07b17a6cd8f7749c6697272", "readme": "specification/resources/resource-manager/readme.md", - "autorest_command": "autorest --version=3.8.4 --typescript --modelerfour.lenient-model-deduplication --azure-arm --head-as-boolean=true --license-header=MICROSOFT_MIT_NO_VERSION --generate-test --typescript-sdks-folder=D:\\Git\\azure-sdk-for-js ..\\azure-rest-api-specs\\specification\\resources\\resource-manager\\readme.md --use=@autorest/typescript@6.0.0-rc.3.20221108.1 --generate-sample=true", + "autorest_command": "autorest --version=3.9.7 --typescript --modelerfour.lenient-model-deduplication --azure-arm --head-as-boolean=true --license-header=MICROSOFT_MIT_NO_VERSION --generate-test --typescript-sdks-folder=/mnt/vss/_work/1/s/azure-sdk-for-js ../azure-rest-api-specs/specification/resources/resource-manager/readme.md --use=@autorest/typescript@^6.0.12", "repository_url": "https://github.com/Azure/azure-rest-api-specs.git", - "release_tool": "@azure-tools/js-sdk-release-tools@2.4.2", - "use": "@autorest/typescript@6.0.0-rc.3.20221108.1" + "release_tool": "@azure-tools/js-sdk-release-tools@2.7.14", + "use": "@autorest/typescript@^6.0.12" } \ No newline at end of file diff --git a/sdk/changes/arm-changes/package.json b/sdk/changes/arm-changes/package.json index 9d3013bbc7f6..6e7a8c517a53 100644 --- a/sdk/changes/arm-changes/package.json +++ b/sdk/changes/arm-changes/package.json @@ -3,15 +3,15 @@ "sdk-type": "mgmt", "author": "Microsoft Corporation", "description": "A generated SDK for ChangesClient.", - "version": "1.1.1", + "version": "2.0.0", "engines": { "node": ">=18.0.0" }, "dependencies": { - "@azure/core-auth": "^1.3.0", - "@azure/core-client": "^1.6.1", "@azure/core-paging": "^1.2.0", - "@azure/core-rest-pipeline": "^1.8.0", + "@azure/core-client": "^1.7.0", + "@azure/core-auth": "^1.6.0", + "@azure/core-rest-pipeline": "^1.14.0", "tslib": "^2.2.0" }, "keywords": [ @@ -26,20 +26,25 @@ "module": "./dist-esm/src/index.js", "types": "./types/arm-changes.d.ts", "devDependencies": { - "@azure-tools/test-credential": "^1.0.0", - "@azure-tools/test-recorder": "^3.0.0", + "@microsoft/api-extractor": "^7.31.1", + "mkdirp": "^3.0.1", + "typescript": "~5.5.3", + "uglify-js": "^3.4.9", + "rimraf": "^5.0.0", + "dotenv": "^16.0.0", "@azure/dev-tool": "^1.0.0", - "@azure/identity": "^4.0.1", - "@types/chai": "^4.2.8", + "@azure/identity": "^4.2.1", + "@azure-tools/test-recorder": "^3.0.0", + "@azure-tools/test-credential": "^1.1.0", + "mocha": "^10.0.0", "@types/mocha": "^10.0.0", - "@types/node": "^18.0.0", + "tsx": "^4.7.1", + "@types/chai": "^4.2.8", "chai": "^4.2.0", "cross-env": "^7.0.2", - "mocha": "^10.0.0", - "ts-node": "^10.0.0", - "typescript": "~5.6.2" + "@types/node": "^18.0.0", + "ts-node": "^10.0.0" }, - "homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/changes/arm-changes", "repository": { "type": "git", "url": "https://github.com/Azure/azure-sdk-for-js.git" @@ -65,30 +70,29 @@ "types/*" ], "scripts": { - "build": "npm run clean && tsc && dev-tool run bundle && npm run minify && dev-tool run vendored mkdirp ./review && npm run extract-api", - "build:browser": "echo skipped", + "build": "npm run clean && tsc && dev-tool run bundle && npm run minify && mkdirp ./review && npm run extract-api", + "minify": "uglifyjs -c -m --comments --source-map \"content='./dist/index.js.map'\" -o ./dist/index.min.js ./dist/index.js", + "prepack": "npm run build", + "pack": "npm pack 2>&1", + "extract-api": "dev-tool run extract-api", + "lint": "echo skipped", + "clean": "rimraf --glob dist dist-browser dist-esm test-dist temp types *.tgz *.log", "build:node": "echo skipped", - "build:samples": "echo skipped.", + "build:browser": "echo skipped", "build:test": "echo skipped", + "build:samples": "echo skipped.", "check-format": "echo skipped", - "clean": "dev-tool run vendored rimraf --glob dist dist-browser dist-esm test-dist temp types *.tgz *.log", "execute:samples": "echo skipped", - "extract-api": "dev-tool run extract-api", "format": "echo skipped", - "integration-test": "npm run integration-test:node && npm run integration-test:browser", - "integration-test:browser": "echo skipped", - "integration-test:node": "dev-tool run test:node-ts-input -- --timeout 1200000 'test/*.ts'", - "lint": "echo skipped", - "minify": "dev-tool run vendored uglifyjs -c -m --comments --source-map \"content='./dist/index.js.map'\" -o ./dist/index.min.js ./dist/index.js", - "pack": "npm pack 2>&1", - "prepack": "npm run build", "test": "npm run integration-test", - "test:browser": "echo skipped", "test:node": "echo skipped", + "test:browser": "echo skipped", "unit-test": "npm run unit-test:node && npm run unit-test:browser", - "unit-test:browser": "echo skipped", "unit-test:node": "cross-env TEST_MODE=playback npm run integration-test:node", - "update-snippets": "echo skipped" + "unit-test:browser": "echo skipped", + "integration-test": "npm run integration-test:node && npm run integration-test:browser", + "integration-test:node": "dev-tool run test:node-ts-input -- --timeout 1200000 'test/*.ts'", + "integration-test:browser": "echo skipped" }, "sideEffects": false, "//metadata": { @@ -100,12 +104,5 @@ ] }, "autoPublish": true, - "//sampleConfiguration": { - "productName": "", - "productSlugs": [ - "azure" - ], - "disableDocsMs": true, - "apiRefLink": "https://docs.microsoft.com/javascript/api/@azure/arm-changes?view=azure-node-preview" - } -} + "homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/changes/arm-changes" +} \ No newline at end of file diff --git a/sdk/changes/arm-changes/review/arm-changes.api.md b/sdk/changes/arm-changes/review/arm-changes.api.md index d28e3c8b3d3c..7f23d1894d55 100644 --- a/sdk/changes/arm-changes/review/arm-changes.api.md +++ b/sdk/changes/arm-changes/review/arm-changes.api.md @@ -85,8 +85,6 @@ export type ChangesGetResponse = ChangeResourceResult; // @public export interface ChangesListNextOptionalParams extends coreClient.OperationOptions { - skipToken?: string; - top?: number; } // @public diff --git a/sdk/changes/arm-changes/src/changesClient.ts b/sdk/changes/arm-changes/src/changesClient.ts index 446f9a2b2c66..8f1fb8337fe6 100644 --- a/sdk/changes/arm-changes/src/changesClient.ts +++ b/sdk/changes/arm-changes/src/changesClient.ts @@ -11,7 +11,7 @@ import * as coreRestPipeline from "@azure/core-rest-pipeline"; import { PipelineRequest, PipelineResponse, - SendRequest + SendRequest, } from "@azure/core-rest-pipeline"; import * as coreAuth from "@azure/core-auth"; import { ChangesImpl } from "./operations"; @@ -33,7 +33,7 @@ export class ChangesClient extends coreClient.ServiceClient { constructor( credentials: coreAuth.TokenCredential, subscriptionId: string, - options?: ChangesClientOptionalParams + options?: ChangesClientOptionalParams, ) { if (credentials === undefined) { throw new Error("'credentials' cannot be null"); @@ -48,10 +48,10 @@ export class ChangesClient extends coreClient.ServiceClient { } const defaults: ChangesClientOptionalParams = { requestContentType: "application/json; charset=utf-8", - credential: credentials + credential: credentials, }; - const packageDetails = `azsdk-js-arm-changes/1.1.1`; + const packageDetails = `azsdk-js-arm-changes/2.0.0`; const userAgentPrefix = options.userAgentOptions && options.userAgentOptions.userAgentPrefix ? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}` @@ -61,20 +61,21 @@ export class ChangesClient extends coreClient.ServiceClient { ...defaults, ...options, userAgentOptions: { - userAgentPrefix + userAgentPrefix, }, endpoint: - options.endpoint ?? options.baseUri ?? "https://management.azure.com" + options.endpoint ?? options.baseUri ?? "https://management.azure.com", }; super(optionsWithDefaults); let bearerTokenAuthenticationPolicyFound: boolean = false; if (options?.pipeline && options.pipeline.getOrderedPolicies().length > 0) { - const pipelinePolicies: coreRestPipeline.PipelinePolicy[] = options.pipeline.getOrderedPolicies(); + const pipelinePolicies: coreRestPipeline.PipelinePolicy[] = + options.pipeline.getOrderedPolicies(); bearerTokenAuthenticationPolicyFound = pipelinePolicies.some( (pipelinePolicy) => pipelinePolicy.name === - coreRestPipeline.bearerTokenAuthenticationPolicyName + coreRestPipeline.bearerTokenAuthenticationPolicyName, ); } if ( @@ -84,7 +85,7 @@ export class ChangesClient extends coreClient.ServiceClient { !bearerTokenAuthenticationPolicyFound ) { this.pipeline.removePolicy({ - name: coreRestPipeline.bearerTokenAuthenticationPolicyName + name: coreRestPipeline.bearerTokenAuthenticationPolicyName, }); this.pipeline.addPolicy( coreRestPipeline.bearerTokenAuthenticationPolicy({ @@ -94,9 +95,9 @@ export class ChangesClient extends coreClient.ServiceClient { `${optionsWithDefaults.endpoint}/.default`, challengeCallbacks: { authorizeRequestOnChallenge: - coreClient.authorizeRequestOnClaimChallenge - } - }) + coreClient.authorizeRequestOnClaimChallenge, + }, + }), ); } // Parameter assignments @@ -118,7 +119,7 @@ export class ChangesClient extends coreClient.ServiceClient { name: "CustomApiVersionPolicy", async sendRequest( request: PipelineRequest, - next: SendRequest + next: SendRequest, ): Promise { const param = request.url.split("?"); if (param.length > 1) { @@ -132,7 +133,7 @@ export class ChangesClient extends coreClient.ServiceClient { request.url = param[0] + "?" + newParams.join("&"); } return next(request); - } + }, }; this.pipeline.addPolicy(apiVersionPolicy); } diff --git a/sdk/changes/arm-changes/src/models/index.ts b/sdk/changes/arm-changes/src/models/index.ts index ad228aaa3b0b..ee8b8a223556 100644 --- a/sdk/changes/arm-changes/src/models/index.ts +++ b/sdk/changes/arm-changes/src/models/index.ts @@ -192,12 +192,7 @@ export type ChangesGetResponse = ChangeResourceResult; /** Optional parameters. */ export interface ChangesListNextOptionalParams - extends coreClient.OperationOptions { - /** (Optional) Set the maximum number of results per response. */ - top?: number; - /** (Optional) The page-continuation token */ - skipToken?: string; -} + extends coreClient.OperationOptions {} /** Contains response data for the listNext operation. */ export type ChangesListNextResponse = ChangeResourceListResult; diff --git a/sdk/changes/arm-changes/src/models/mappers.ts b/sdk/changes/arm-changes/src/models/mappers.ts index 440d71224353..576f47c739df 100644 --- a/sdk/changes/arm-changes/src/models/mappers.ts +++ b/sdk/changes/arm-changes/src/models/mappers.ts @@ -16,8 +16,8 @@ export const ChangeResourceListResult: coreClient.CompositeMapper = { nextLink: { serializedName: "nextLink", type: { - name: "String" - } + name: "String", + }, }, value: { serializedName: "value", @@ -26,13 +26,13 @@ export const ChangeResourceListResult: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "ChangeResourceResult" - } - } - } - } - } - } + className: "ChangeResourceResult", + }, + }, + }, + }, + }, + }, }; export const ChangeProperties: coreClient.CompositeMapper = { @@ -44,40 +44,40 @@ export const ChangeProperties: coreClient.CompositeMapper = { serializedName: "targetResourceId", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, targetResourceType: { serializedName: "targetResourceType", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, changeType: { serializedName: "changeType", readOnly: true, type: { name: "Enum", - allowedValues: ["Update", "Delete", "Create"] - } + allowedValues: ["Update", "Delete", "Create"], + }, }, changeAttributes: { serializedName: "changeAttributes", type: { name: "Composite", - className: "ChangeAttributes" - } + className: "ChangeAttributes", + }, }, changes: { serializedName: "changes", type: { name: "Dictionary", - value: { type: { name: "Composite", className: "ChangeBase" } } - } - } - } - } + value: { type: { name: "Composite", className: "ChangeBase" } }, + }, + }, + }, + }, }; export const ChangeAttributes: coreClient.CompositeMapper = { @@ -89,39 +89,39 @@ export const ChangeAttributes: coreClient.CompositeMapper = { serializedName: "correlationId", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, timestamp: { serializedName: "timestamp", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, changesCount: { serializedName: "changesCount", readOnly: true, type: { - name: "Number" - } + name: "Number", + }, }, previousResourceSnapshotId: { serializedName: "previousResourceSnapshotId", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, newResourceSnapshotId: { serializedName: "newResourceSnapshotId", readOnly: true, type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const ChangeBase: coreClient.CompositeMapper = { @@ -134,33 +134,33 @@ export const ChangeBase: coreClient.CompositeMapper = { readOnly: true, type: { name: "Enum", - allowedValues: ["Update", "Insert", "Remove"] - } + allowedValues: ["Update", "Insert", "Remove"], + }, }, changeCategory: { serializedName: "changeCategory", readOnly: true, type: { name: "Enum", - allowedValues: ["User", "System"] - } + allowedValues: ["User", "System"], + }, }, previousValue: { serializedName: "previousValue", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, newValue: { serializedName: "newValue", readOnly: true, type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const Resource: coreClient.CompositeMapper = { @@ -172,25 +172,25 @@ export const Resource: coreClient.CompositeMapper = { serializedName: "id", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, name: { serializedName: "name", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, type: { serializedName: "type", readOnly: true, type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const ErrorResponse: coreClient.CompositeMapper = { @@ -202,11 +202,11 @@ export const ErrorResponse: coreClient.CompositeMapper = { serializedName: "error", type: { name: "Composite", - className: "ErrorDetail" - } - } - } - } + className: "ErrorDetail", + }, + }, + }, + }, }; export const ErrorDetail: coreClient.CompositeMapper = { @@ -218,22 +218,22 @@ export const ErrorDetail: coreClient.CompositeMapper = { serializedName: "code", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, message: { serializedName: "message", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, target: { serializedName: "target", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, details: { serializedName: "details", @@ -243,10 +243,10 @@ export const ErrorDetail: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "ErrorDetail" - } - } - } + className: "ErrorDetail", + }, + }, + }, }, additionalInfo: { serializedName: "additionalInfo", @@ -256,13 +256,13 @@ export const ErrorDetail: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "ErrorAdditionalInfo" - } - } - } - } - } - } + className: "ErrorAdditionalInfo", + }, + }, + }, + }, + }, + }, }; export const ErrorAdditionalInfo: coreClient.CompositeMapper = { @@ -274,19 +274,19 @@ export const ErrorAdditionalInfo: coreClient.CompositeMapper = { serializedName: "type", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, info: { serializedName: "info", readOnly: true, type: { name: "Dictionary", - value: { type: { name: "any" } } - } - } - } - } + value: { type: { name: "any" } }, + }, + }, + }, + }, }; export const ChangeResourceResult: coreClient.CompositeMapper = { @@ -299,9 +299,9 @@ export const ChangeResourceResult: coreClient.CompositeMapper = { serializedName: "properties", type: { name: "Composite", - className: "ChangeProperties" - } - } - } - } + className: "ChangeProperties", + }, + }, + }, + }, }; diff --git a/sdk/changes/arm-changes/src/models/parameters.ts b/sdk/changes/arm-changes/src/models/parameters.ts index 8d270640fffc..993d6cabbfeb 100644 --- a/sdk/changes/arm-changes/src/models/parameters.ts +++ b/sdk/changes/arm-changes/src/models/parameters.ts @@ -9,7 +9,7 @@ import { OperationParameter, OperationURLParameter, - OperationQueryParameter + OperationQueryParameter, } from "@azure/core-client"; export const accept: OperationParameter = { @@ -19,9 +19,9 @@ export const accept: OperationParameter = { isConstant: true, serializedName: "Accept", type: { - name: "String" - } - } + name: "String", + }, + }, }; export const $host: OperationURLParameter = { @@ -30,10 +30,10 @@ export const $host: OperationURLParameter = { serializedName: "$host", required: true, type: { - name: "String" - } + name: "String", + }, }, - skipEncoding: true + skipEncoding: true, }; export const subscriptionId: OperationURLParameter = { @@ -42,9 +42,9 @@ export const subscriptionId: OperationURLParameter = { serializedName: "subscriptionId", required: true, type: { - name: "String" - } - } + name: "String", + }, + }, }; export const resourceGroupName: OperationURLParameter = { @@ -53,9 +53,9 @@ export const resourceGroupName: OperationURLParameter = { serializedName: "resourceGroupName", required: true, type: { - name: "String" - } - } + name: "String", + }, + }, }; export const resourceProviderNamespace: OperationURLParameter = { @@ -64,9 +64,9 @@ export const resourceProviderNamespace: OperationURLParameter = { serializedName: "resourceProviderNamespace", required: true, type: { - name: "String" - } - } + name: "String", + }, + }, }; export const resourceType: OperationURLParameter = { @@ -75,9 +75,9 @@ export const resourceType: OperationURLParameter = { serializedName: "resourceType", required: true, type: { - name: "String" - } - } + name: "String", + }, + }, }; export const resourceName: OperationURLParameter = { @@ -86,9 +86,9 @@ export const resourceName: OperationURLParameter = { serializedName: "resourceName", required: true, type: { - name: "String" - } - } + name: "String", + }, + }, }; export const apiVersion: OperationQueryParameter = { @@ -98,9 +98,9 @@ export const apiVersion: OperationQueryParameter = { isConstant: true, serializedName: "api-version", type: { - name: "String" - } - } + name: "String", + }, + }, }; export const top: OperationQueryParameter = { @@ -109,13 +109,13 @@ export const top: OperationQueryParameter = { defaultValue: 100, constraints: { InclusiveMaximum: 100, - InclusiveMinimum: 1 + InclusiveMinimum: 1, }, serializedName: "$top", type: { - name: "Number" - } - } + name: "Number", + }, + }, }; export const skipToken: OperationQueryParameter = { @@ -123,9 +123,9 @@ export const skipToken: OperationQueryParameter = { mapper: { serializedName: "$skipToken", type: { - name: "String" - } - } + name: "String", + }, + }, }; export const changeResourceId: OperationURLParameter = { @@ -134,9 +134,9 @@ export const changeResourceId: OperationURLParameter = { serializedName: "changeResourceId", required: true, type: { - name: "String" - } - } + name: "String", + }, + }, }; export const nextLink: OperationURLParameter = { @@ -145,8 +145,8 @@ export const nextLink: OperationURLParameter = { serializedName: "nextLink", required: true, type: { - name: "String" - } + name: "String", + }, }, - skipEncoding: true + skipEncoding: true, }; diff --git a/sdk/changes/arm-changes/src/operations/changes.ts b/sdk/changes/arm-changes/src/operations/changes.ts index 7c5e470c5ae0..d3dd32c9fbd6 100644 --- a/sdk/changes/arm-changes/src/operations/changes.ts +++ b/sdk/changes/arm-changes/src/operations/changes.ts @@ -20,7 +20,7 @@ import { ChangesListResponse, ChangesGetOptionalParams, ChangesGetResponse, - ChangesListNextResponse + ChangesListNextResponse, } from "../models"; /// @@ -49,14 +49,14 @@ export class ChangesImpl implements Changes { resourceProviderNamespace: string, resourceType: string, resourceName: string, - options?: ChangesListOptionalParams + options?: ChangesListOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listPagingAll( resourceGroupName, resourceProviderNamespace, resourceType, resourceName, - options + options, ); return { next() { @@ -75,9 +75,9 @@ export class ChangesImpl implements Changes { resourceType, resourceName, options, - settings + settings, ); - } + }, }; } @@ -87,7 +87,7 @@ export class ChangesImpl implements Changes { resourceType: string, resourceName: string, options?: ChangesListOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: ChangesListResponse; let continuationToken = settings?.continuationToken; @@ -97,7 +97,7 @@ export class ChangesImpl implements Changes { resourceProviderNamespace, resourceType, resourceName, - options + options, ); let page = result.value || []; continuationToken = result.nextLink; @@ -111,7 +111,7 @@ export class ChangesImpl implements Changes { resourceType, resourceName, continuationToken, - options + options, ); continuationToken = result.nextLink; let page = result.value || []; @@ -125,14 +125,14 @@ export class ChangesImpl implements Changes { resourceProviderNamespace: string, resourceType: string, resourceName: string, - options?: ChangesListOptionalParams + options?: ChangesListOptionalParams, ): AsyncIterableIterator { for await (const page of this.listPagingPage( resourceGroupName, resourceProviderNamespace, resourceType, resourceName, - options + options, )) { yield* page; } @@ -151,7 +151,7 @@ export class ChangesImpl implements Changes { resourceProviderNamespace: string, resourceType: string, resourceName: string, - options?: ChangesListOptionalParams + options?: ChangesListOptionalParams, ): Promise { return this.client.sendOperationRequest( { @@ -159,9 +159,9 @@ export class ChangesImpl implements Changes { resourceProviderNamespace, resourceType, resourceName, - options + options, }, - listOperationSpec + listOperationSpec, ); } @@ -180,7 +180,7 @@ export class ChangesImpl implements Changes { resourceType: string, resourceName: string, changeResourceId: string, - options?: ChangesGetOptionalParams + options?: ChangesGetOptionalParams, ): Promise { return this.client.sendOperationRequest( { @@ -189,9 +189,9 @@ export class ChangesImpl implements Changes { resourceType, resourceName, changeResourceId, - options + options, }, - getOperationSpec + getOperationSpec, ); } @@ -210,7 +210,7 @@ export class ChangesImpl implements Changes { resourceType: string, resourceName: string, nextLink: string, - options?: ChangesListNextOptionalParams + options?: ChangesListNextOptionalParams, ): Promise { return this.client.sendOperationRequest( { @@ -219,9 +219,9 @@ export class ChangesImpl implements Changes { resourceType, resourceName, nextLink, - options + options, }, - listNextOperationSpec + listNextOperationSpec, ); } } @@ -229,21 +229,20 @@ export class ChangesImpl implements Changes { const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); const listOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}/providers/Microsoft.Resources/changes", + path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}/providers/Microsoft.Resources/changes", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.ChangeResourceListResult + bodyMapper: Mappers.ChangeResourceListResult, }, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, queryParameters: [ Parameters.apiVersion, Parameters.top, - Parameters.skipToken + Parameters.skipToken, ], urlParameters: [ Parameters.$host, @@ -251,22 +250,21 @@ const listOperationSpec: coreClient.OperationSpec = { Parameters.resourceGroupName, Parameters.resourceProviderNamespace, Parameters.resourceType, - Parameters.resourceName + Parameters.resourceName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const getOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}/providers/Microsoft.Resources/changes/{changeResourceId}", + path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}/providers/Microsoft.Resources/changes/{changeResourceId}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.ChangeResourceResult + bodyMapper: Mappers.ChangeResourceResult, }, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ @@ -276,27 +274,22 @@ const getOperationSpec: coreClient.OperationSpec = { Parameters.resourceProviderNamespace, Parameters.resourceType, Parameters.resourceName, - Parameters.changeResourceId + Parameters.changeResourceId, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const listNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.ChangeResourceListResult + bodyMapper: Mappers.ChangeResourceListResult, }, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, - queryParameters: [ - Parameters.apiVersion, - Parameters.top, - Parameters.skipToken - ], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -304,8 +297,8 @@ const listNextOperationSpec: coreClient.OperationSpec = { Parameters.resourceProviderNamespace, Parameters.resourceType, Parameters.resourceName, - Parameters.nextLink + Parameters.nextLink, ], headerParameters: [Parameters.accept], - serializer + serializer, }; diff --git a/sdk/changes/arm-changes/src/operationsInterfaces/changes.ts b/sdk/changes/arm-changes/src/operationsInterfaces/changes.ts index b873985b4b21..d862c902ff43 100644 --- a/sdk/changes/arm-changes/src/operationsInterfaces/changes.ts +++ b/sdk/changes/arm-changes/src/operationsInterfaces/changes.ts @@ -11,7 +11,7 @@ import { ChangeResourceResult, ChangesListOptionalParams, ChangesGetOptionalParams, - ChangesGetResponse + ChangesGetResponse, } from "../models"; /// @@ -30,7 +30,7 @@ export interface Changes { resourceProviderNamespace: string, resourceType: string, resourceName: string, - options?: ChangesListOptionalParams + options?: ChangesListOptionalParams, ): PagedAsyncIterableIterator; /** * Obtains the specified change resource for the target resource @@ -47,6 +47,6 @@ export interface Changes { resourceType: string, resourceName: string, changeResourceId: string, - options?: ChangesGetOptionalParams + options?: ChangesGetOptionalParams, ): Promise; } diff --git a/sdk/changes/arm-changes/src/pagingHelper.ts b/sdk/changes/arm-changes/src/pagingHelper.ts index d85fc13bce1e..205cccc26592 100644 --- a/sdk/changes/arm-changes/src/pagingHelper.ts +++ b/sdk/changes/arm-changes/src/pagingHelper.ts @@ -13,11 +13,11 @@ export interface PageInfo { const pageMap = new WeakMap(); /** - * Given a result page from a pageable operation, returns a - * continuation token that can be used to begin paging from + * Given the last `.value` produced by the `byPage` iterator, + * returns a continuation token that can be used to begin paging from * that point later. - * @param page A result object from calling .byPage() on a paged operation. - * @returns The continuation token that can be passed into byPage(). + * @param page An object from accessing `value` on the IteratorResult from a `byPage` iterator. + * @returns The continuation token that can be passed into byPage() during future calls. */ export function getContinuationToken(page: unknown): string | undefined { if (typeof page !== "object" || page === null) { @@ -28,7 +28,7 @@ export function getContinuationToken(page: unknown): string | undefined { export function setContinuationToken( page: unknown, - continuationToken: string | undefined + continuationToken: string | undefined, ): void { if (typeof page !== "object" || page === null || !continuationToken) { return; diff --git a/sdk/changes/arm-changes/test/sampleTest.ts b/sdk/changes/arm-changes/test/sampleTest.ts index 8ff7deb0acbe..d64be981b694 100644 --- a/sdk/changes/arm-changes/test/sampleTest.ts +++ b/sdk/changes/arm-changes/test/sampleTest.ts @@ -9,7 +9,7 @@ import { Recorder, RecorderStartOptions, - env + env, } from "@azure-tools/test-recorder"; import { assert } from "chai"; import { Context } from "mocha"; @@ -18,15 +18,11 @@ const replaceableVariables: Record = { AZURE_CLIENT_ID: "azure_client_id", AZURE_CLIENT_SECRET: "azure_client_secret", AZURE_TENANT_ID: "88888888-8888-8888-8888-888888888888", - SUBSCRIPTION_ID: "azure_subscription_id" + SUBSCRIPTION_ID: "azure_subscription_id", }; const recorderOptions: RecorderStartOptions = { envSetupForPlayback: replaceableVariables, - removeCentralSanitizers: [ - "AZSDK3493", // .name in the body is not a secret and is listed below in the beforeEach section - "AZSDK3430", // .id in the body is not a secret and is listed below in the beforeEach section - ], }; describe("My test", () => { diff --git a/sdk/changes/arm-changes/tsconfig.json b/sdk/changes/arm-changes/tsconfig.json index 017e8571316c..1d8c9012bfbd 100644 --- a/sdk/changes/arm-changes/tsconfig.json +++ b/sdk/changes/arm-changes/tsconfig.json @@ -15,17 +15,19 @@ ], "declaration": true, "outDir": "./dist-esm", - "importHelpers": true, - "paths": { - "@azure/arm-changes": [ - "./src/index" - ] - } + "importHelpers": true }, "include": [ "./src/**/*.ts", "./test/**/*.ts", - "samples-dev/**/*.ts" + "./test/**/*.ts", + "./test/**/*.ts", + "./test/**/*.ts", + "./test/**/*.ts", + "./test/**/*.ts", + "./test/**/*.ts", + "./test/**/*.ts", + "./test/**/*.ts" ], "exclude": [ "node_modules" diff --git a/sdk/databoundaries/arm-databoundaries/CHANGELOG.md b/sdk/databoundaries/arm-databoundaries/CHANGELOG.md index 3dc43897b64a..aaa3a75f50e1 100644 --- a/sdk/databoundaries/arm-databoundaries/CHANGELOG.md +++ b/sdk/databoundaries/arm-databoundaries/CHANGELOG.md @@ -1,16 +1,6 @@ # Release History - -## 1.0.0-beta.2 (Unreleased) - -### Features Added - -### Breaking Changes - -### Bugs Fixed - -### Other Changes - -## 1.0.0-beta.1 (2024-10-25) + +## 1.0.0 (2024-11-01) ### Features Added diff --git a/sdk/databoundaries/arm-databoundaries/README.md b/sdk/databoundaries/arm-databoundaries/README.md index a6bcdb00a61f..75100b75a161 100644 --- a/sdk/databoundaries/arm-databoundaries/README.md +++ b/sdk/databoundaries/arm-databoundaries/README.md @@ -1,12 +1,12 @@ -# Azure DataboundariesManegement client library for JavaScript +# Azure ArmDataboundaries client library for JavaScript -This package contains an isomorphic SDK (runs both in Node.js and in browsers) for Azure DataboundariesManegement client. +This package contains an isomorphic SDK (runs both in Node.js and in browsers) for Azure ArmDataboundaries client. Provides APIs for data boundary operations. [Source code](https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/databoundaries/arm-databoundaries) | [Package (NPM)](https://www.npmjs.com/package/@azure/arm-databoundaries) | -[API reference documentation](https://docs.microsoft.com/javascript/api/@azure/arm-databoundaries?view=azure-node-preview) | +[API reference documentation](https://docs.microsoft.com/javascript/api/@azure/arm-databoundaries) | [Samples](https://github.com/Azure-Samples/azure-samples-js-management) ## Getting started @@ -24,16 +24,16 @@ See our [support policy](https://github.com/Azure/azure-sdk-for-js/blob/main/SUP ### Install the `@azure/arm-databoundaries` package -Install the Azure DataboundariesManegement client library for JavaScript with `npm`: +Install the Azure ArmDataboundaries client library for JavaScript with `npm`: ```bash npm install @azure/arm-databoundaries ``` -### Create and authenticate a `DataboundariesManegementClient` +### Create and authenticate a `DataBoundary` -To create a client object to access the Azure DataboundariesManegement API, you will need the `endpoint` of your Azure DataboundariesManegement resource and a `credential`. The Azure DataboundariesManegement client can use Azure Active Directory credentials to authenticate. -You can find the endpoint for your Azure DataboundariesManegement resource in the [Azure Portal][azure_portal]. +To create a client object to access the Azure ArmDataboundaries API, you will need the `endpoint` of your Azure ArmDataboundaries resource and a `credential`. The Azure ArmDataboundaries client can use Azure Active Directory credentials to authenticate. +You can find the endpoint for your Azure ArmDataboundaries resource in the [Azure Portal][azure_portal]. You can authenticate with Azure Active Directory using a credential from the [@azure/identity][azure_identity] library or [an existing AAD Token](https://github.com/Azure/azure-sdk-for-js/blob/master/sdk/identity/identity/samples/AzureIdentityExamples.md#authenticating-with-a-pre-fetched-access-token). @@ -43,24 +43,25 @@ To use the [DefaultAzureCredential][defaultazurecredential] provider shown below npm install @azure/identity ``` -You will also need to **register a new AAD application and grant access to Azure DataboundariesManegement** by assigning the suitable role to your service principal (note: roles such as `"Owner"` will not grant the necessary permissions). +You will also need to **register a new AAD application and grant access to Azure ArmDataboundaries** by assigning the suitable role to your service principal (note: roles such as `"Owner"` will not grant the necessary permissions). Set the values of the client ID, tenant ID, and client secret of the AAD application as environment variables: `AZURE_CLIENT_ID`, `AZURE_TENANT_ID`, `AZURE_CLIENT_SECRET`. For more information about how to create an Azure AD Application check out [this guide](https://docs.microsoft.com/azure/active-directory/develop/howto-create-service-principal-portal). ```javascript -const { DataboundariesManegementClient } = require("@azure/arm-databoundaries"); +const { DataBoundary } = require("@azure/arm-databoundaries"); const { DefaultAzureCredential } = require("@azure/identity"); // For client-side applications running in the browser, use InteractiveBrowserCredential instead of DefaultAzureCredential. See https://aka.ms/azsdk/js/identity/examples for more details. -const client = new DataboundariesManegementClient(new DefaultAzureCredential()); +const subscriptionId = "00000000-0000-0000-0000-000000000000"; +const client = new DataBoundary(new DefaultAzureCredential(), subscriptionId); // For client-side applications running in the browser, use this code instead: // const credential = new InteractiveBrowserCredential({ // tenantId: "", // clientId: "" // }); -// const client = new DataboundariesManegementClient(credential); +// const client = new DataBoundary(credential, subscriptionId); ``` @@ -69,9 +70,9 @@ To use this client library in the browser, first you need to use a bundler. For ## Key concepts -### DataboundariesManegementClient +### DataBoundary -`DataboundariesManegementClient` is the primary interface for developers using the Azure DataboundariesManegement client library. Explore the methods on this client object to understand the different features of the Azure DataboundariesManegement service that you can access. +`DataBoundary` is the primary interface for developers using the Azure ArmDataboundaries client library. Explore the methods on this client object to understand the different features of the Azure ArmDataboundaries service that you can access. ## Troubleshooting diff --git a/sdk/databoundaries/arm-databoundaries/_meta.json b/sdk/databoundaries/arm-databoundaries/_meta.json index c6304d2b7664..28591836c37e 100644 --- a/sdk/databoundaries/arm-databoundaries/_meta.json +++ b/sdk/databoundaries/arm-databoundaries/_meta.json @@ -1,8 +1,8 @@ { - "commit": "bc3aa2bbc4494553649019585c3bc8a4229a25d0", + "commit": "5342edb61d78cec6e07b17a6cd8f7749c6697272", "readme": "specification/resources/resource-manager/readme.md", - "autorest_command": "autorest --version=3.9.7 --typescript --modelerfour.lenient-model-deduplication --azure-arm --head-as-boolean=true --license-header=MICROSOFT_MIT_NO_VERSION --generate-test --typescript-sdks-folder=D:\\Git\\azure-sdk-for-js ..\\azure-rest-api-specs\\specification\\resources\\resource-manager\\readme.md --use=@autorest/typescript@6.0.27 --generate-sample=true", + "autorest_command": "autorest --version=3.9.7 --typescript --modelerfour.lenient-model-deduplication --azure-arm --head-as-boolean=true --license-header=MICROSOFT_MIT_NO_VERSION --generate-test --typescript-sdks-folder=/mnt/vss/_work/1/s/azure-sdk-for-js ../azure-rest-api-specs/specification/resources/resource-manager/readme.md --use=@autorest/typescript@^6.0.12", "repository_url": "https://github.com/Azure/azure-rest-api-specs.git", - "release_tool": "@azure-tools/js-sdk-release-tools@2.7.15", - "use": "@autorest/typescript@6.0.27" + "release_tool": "@azure-tools/js-sdk-release-tools@2.7.14", + "use": "@autorest/typescript@^6.0.12" } \ No newline at end of file diff --git a/sdk/databoundaries/arm-databoundaries/package.json b/sdk/databoundaries/arm-databoundaries/package.json index 1b864947e348..99f8dac322ca 100644 --- a/sdk/databoundaries/arm-databoundaries/package.json +++ b/sdk/databoundaries/arm-databoundaries/package.json @@ -2,12 +2,13 @@ "name": "@azure/arm-databoundaries", "sdk-type": "mgmt", "author": "Microsoft Corporation", - "description": "A generated SDK for DataboundariesManegementClient.", - "version": "1.0.0-beta.2", + "description": "A generated SDK for DataBoundary.", + "version": "1.0.0", "engines": { "node": ">=18.0.0" }, "dependencies": { + "@azure/core-paging": "^1.2.0", "@azure/core-client": "^1.7.0", "@azure/core-auth": "^1.6.0", "@azure/core-rest-pipeline": "^1.14.0", @@ -28,6 +29,7 @@ "@microsoft/api-extractor": "^7.31.1", "mkdirp": "^3.0.1", "typescript": "~5.5.3", + "uglify-js": "^3.4.9", "rimraf": "^5.0.0", "dotenv": "^16.0.0", "@azure/dev-tool": "^1.0.0", @@ -69,7 +71,7 @@ ], "scripts": { "build": "npm run clean && tsc && dev-tool run bundle && npm run minify && mkdirp ./review && npm run extract-api", - "minify": "dev-tool run vendored uglifyjs -c -m --comments --source-map \"content='./dist/index.js.map'\" -o ./dist/index.min.js ./dist/index.js", + "minify": "uglifyjs -c -m --comments --source-map \"content='./dist/index.js.map'\" -o ./dist/index.min.js ./dist/index.js", "prepack": "npm run build", "pack": "npm pack 2>&1", "extract-api": "dev-tool run extract-api", @@ -96,19 +98,11 @@ "//metadata": { "constantPaths": [ { - "path": "src/databoundariesManegementClient.ts", + "path": "src/dataBoundary.ts", "prefix": "packageDetails" } ] }, "autoPublish": true, - "homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/databoundaries/arm-databoundaries", - "//sampleConfiguration": { - "productName": "", - "productSlugs": [ - "azure" - ], - "disableDocsMs": true, - "apiRefLink": "https://docs.microsoft.com/javascript/api/@azure/arm-databoundaries?view=azure-node-preview" - } -} + "homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/databoundaries/arm-databoundaries" +} \ No newline at end of file diff --git a/sdk/databoundaries/arm-databoundaries/review/arm-databoundaries.api.md b/sdk/databoundaries/arm-databoundaries/review/arm-databoundaries.api.md index d23a5c8294e3..96daff7aad33 100644 --- a/sdk/databoundaries/arm-databoundaries/review/arm-databoundaries.api.md +++ b/sdk/databoundaries/arm-databoundaries/review/arm-databoundaries.api.md @@ -6,6 +6,10 @@ import * as coreAuth from '@azure/core-auth'; import * as coreClient from '@azure/core-client'; +import { PagedAsyncIterableIterator } from '@azure/core-paging'; + +// @public +export type ActionType = string; // @public export type CreatedByType = string; @@ -31,42 +35,42 @@ export interface DataBoundariesGetTenantOptionalParams extends coreClient.Operat // @public export type DataBoundariesGetTenantResponse = DataBoundaryDefinition; +// @public +export interface DataBoundariesPutOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type DataBoundariesPutResponse = DataBoundaryDefinition; + // @public (undocumented) -export class DataboundariesManegementClient extends coreClient.ServiceClient { +export class DataBoundary extends coreClient.ServiceClient { // (undocumented) $host: string; - constructor(credentials: coreAuth.TokenCredential, options?: DataboundariesManegementClientOptionalParams); + constructor(credentials: coreAuth.TokenCredential, options?: DataBoundaryOptionalParams); // (undocumented) apiVersion: string; // (undocumented) dataBoundaries: DataBoundaries; + // (undocumented) + operations: Operations; } // @public -export interface DataboundariesManegementClientOptionalParams extends coreClient.ServiceClientOptions { - $host?: string; - apiVersion?: string; - endpoint?: string; -} - -// @public -export interface DataBoundariesPutOptionalParams extends coreClient.OperationOptions { +export interface DataBoundaryDefinition extends ProxyResource { + properties?: DataBoundaryProperties; } // @public -export type DataBoundariesPutResponse = DataBoundaryDefinition; - -// @public -export type DataBoundary = string; - -// @public -export interface DataBoundaryDefinition extends ProxyResource { - properties?: DataBoundaryProperties; +export interface DataBoundaryOptionalParams extends coreClient.ServiceClientOptions { + $host?: string; + apiVersion?: string; + endpoint?: string; } // @public export interface DataBoundaryProperties { - dataBoundary?: DataBoundary; + // Warning: (ae-forgotten-export) The symbol "DataBoundary_2" needs to be exported by the entry point index.d.ts + dataBoundary?: DataBoundary_2; readonly provisioningState?: ProvisioningState; } @@ -93,6 +97,14 @@ export interface ErrorResponse { error?: ErrorDetail; } +// @public +export function getContinuationToken(page: unknown): string | undefined; + +// @public +export enum KnownActionType { + Internal = "Internal" +} + // @public export enum KnownCreatedByType { Application = "Application", @@ -113,6 +125,13 @@ export enum KnownDefaultName { Default = "default" } +// @public +export enum KnownOrigin { + System = "system", + User = "user", + UserSystem = "user,system" +} + // @public export enum KnownProvisioningState { Accepted = "Accepted", @@ -124,6 +143,51 @@ export enum KnownProvisioningState { Updating = "Updating" } +// @public +export interface Operation { + readonly actionType?: ActionType; + display?: OperationDisplay; + readonly isDataAction?: boolean; + readonly name?: string; + readonly origin?: Origin; +} + +// @public +export interface OperationDisplay { + readonly description?: string; + readonly operation?: string; + readonly provider?: string; + readonly resource?: string; +} + +// @public +export interface OperationListResult { + readonly nextLink?: string; + readonly value?: Operation[]; +} + +// @public +export interface Operations { + list(options?: OperationsListOptionalParams): PagedAsyncIterableIterator; +} + +// @public +export interface OperationsListNextOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type OperationsListNextResponse = OperationListResult; + +// @public +export interface OperationsListOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type OperationsListResponse = OperationListResult; + +// @public +export type Origin = string; + // @public export type ProvisioningState = string; diff --git a/sdk/databoundaries/arm-databoundaries/sample.env b/sdk/databoundaries/arm-databoundaries/sample.env index efbc7787bd3b..672847a3fea0 100644 --- a/sdk/databoundaries/arm-databoundaries/sample.env +++ b/sdk/databoundaries/arm-databoundaries/sample.env @@ -1 +1,4 @@ -# Feel free to add your own environment variables. +# App registration secret for AAD authentication +AZURE_CLIENT_SECRET= +AZURE_CLIENT_ID= +AZURE_TENANT_ID= \ No newline at end of file diff --git a/sdk/databoundaries/arm-databoundaries/src/databoundariesManegementClient.ts b/sdk/databoundaries/arm-databoundaries/src/dataBoundary.ts similarity index 87% rename from sdk/databoundaries/arm-databoundaries/src/databoundariesManegementClient.ts rename to sdk/databoundaries/arm-databoundaries/src/dataBoundary.ts index 2a052d25d938..ce7bf17d3e20 100644 --- a/sdk/databoundaries/arm-databoundaries/src/databoundariesManegementClient.ts +++ b/sdk/databoundaries/arm-databoundaries/src/dataBoundary.ts @@ -14,22 +14,22 @@ import { SendRequest, } from "@azure/core-rest-pipeline"; import * as coreAuth from "@azure/core-auth"; -import { DataBoundariesImpl } from "./operations"; -import { DataBoundaries } from "./operationsInterfaces"; -import { DataboundariesManegementClientOptionalParams } from "./models"; +import { OperationsImpl, DataBoundariesImpl } from "./operations"; +import { Operations, DataBoundaries } from "./operationsInterfaces"; +import { DataBoundaryOptionalParams } from "./models"; -export class DataboundariesManegementClient extends coreClient.ServiceClient { +export class DataBoundary extends coreClient.ServiceClient { $host: string; apiVersion: string; /** - * Initializes a new instance of the DataboundariesManegementClient class. + * Initializes a new instance of the DataBoundary class. * @param credentials Subscription credentials which uniquely identify client subscription. * @param options The parameter options */ constructor( credentials: coreAuth.TokenCredential, - options?: DataboundariesManegementClientOptionalParams, + options?: DataBoundaryOptionalParams, ) { if (credentials === undefined) { throw new Error("'credentials' cannot be null"); @@ -39,12 +39,12 @@ export class DataboundariesManegementClient extends coreClient.ServiceClient { if (!options) { options = {}; } - const defaults: DataboundariesManegementClientOptionalParams = { + const defaults: DataBoundaryOptionalParams = { requestContentType: "application/json; charset=utf-8", credential: credentials, }; - const packageDetails = `azsdk-js-arm-databoundaries/1.0.0-beta.2`; + const packageDetails = `azsdk-js-arm-databoundaries/1.0.0`; const userAgentPrefix = options.userAgentOptions && options.userAgentOptions.userAgentPrefix ? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}` @@ -97,6 +97,7 @@ export class DataboundariesManegementClient extends coreClient.ServiceClient { // Assigning values to Constant parameters this.$host = options.$host || "https://management.azure.com"; this.apiVersion = options.apiVersion || "2024-08-01"; + this.operations = new OperationsImpl(this); this.dataBoundaries = new DataBoundariesImpl(this); this.addCustomApiVersionPolicy(options.apiVersion); } @@ -129,5 +130,6 @@ export class DataboundariesManegementClient extends coreClient.ServiceClient { this.pipeline.addPolicy(apiVersionPolicy); } + operations: Operations; dataBoundaries: DataBoundaries; } diff --git a/sdk/databoundaries/arm-databoundaries/src/index.ts b/sdk/databoundaries/arm-databoundaries/src/index.ts index 024565c271d8..cc24c4a8e275 100644 --- a/sdk/databoundaries/arm-databoundaries/src/index.ts +++ b/sdk/databoundaries/arm-databoundaries/src/index.ts @@ -6,6 +6,8 @@ * Changes may cause incorrect behavior and will be lost if the code is regenerated. */ +/// +export { getContinuationToken } from "./pagingHelper"; export * from "./models"; -export { DataboundariesManegementClient } from "./databoundariesManegementClient"; +export { DataBoundary } from "./dataBoundary"; export * from "./operationsInterfaces"; diff --git a/sdk/databoundaries/arm-databoundaries/src/models/index.ts b/sdk/databoundaries/arm-databoundaries/src/models/index.ts index f2a0c67411cb..233e8cc4435f 100644 --- a/sdk/databoundaries/arm-databoundaries/src/models/index.ts +++ b/sdk/databoundaries/arm-databoundaries/src/models/index.ts @@ -8,55 +8,68 @@ import * as coreClient from "@azure/core-client"; -/** Data boundary properties */ -export interface DataBoundaryProperties { - /** The data boundary definition. */ - dataBoundary?: DataBoundary; +/** A list of REST API operations supported by an Azure Resource Provider. It contains an URL link to get the next set of results. */ +export interface OperationListResult { /** - * Denotes the state of provisioning. + * List of operations supported by the resource provider * NOTE: This property will not be serialized. It can only be populated by the server. */ - readonly provisioningState?: ProvisioningState; + readonly value?: Operation[]; + /** + * URL to get the next set of operation list results (if there are any). + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly nextLink?: string; } -/** Common fields that are returned in the response for all Azure Resource Manager resources */ -export interface Resource { +/** Details of a REST API operation, returned from the Resource Provider Operations API */ +export interface Operation { /** - * Fully qualified resource ID for the resource. E.g. "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}" + * The name of the operation, as per Resource-Based Access Control (RBAC). Examples: "Microsoft.Compute/virtualMachines/write", "Microsoft.Compute/virtualMachines/capture/action" * NOTE: This property will not be serialized. It can only be populated by the server. */ - readonly id?: string; + readonly name?: string; /** - * The name of the resource + * Whether the operation applies to data-plane. This is "true" for data-plane operations and "false" for ARM/control-plane operations. * NOTE: This property will not be serialized. It can only be populated by the server. */ - readonly name?: string; + readonly isDataAction?: boolean; + /** Localized display information for this particular operation. */ + display?: OperationDisplay; /** - * The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" + * The intended executor of the operation; as in Resource Based Access Control (RBAC) and audit logs UX. Default value is "user,system" * NOTE: This property will not be serialized. It can only be populated by the server. */ - readonly type?: string; + readonly origin?: Origin; /** - * Azure Resource Manager metadata containing createdBy and modifiedBy information. + * Enum. Indicates the action type. "Internal" refers to actions that are for internal only APIs. * NOTE: This property will not be serialized. It can only be populated by the server. */ - readonly systemData?: SystemData; + readonly actionType?: ActionType; } -/** Metadata pertaining to creation and last modification of the resource. */ -export interface SystemData { - /** The identity that created the resource. */ - createdBy?: string; - /** The type of identity that created the resource. */ - createdByType?: CreatedByType; - /** The timestamp of resource creation (UTC). */ - createdAt?: Date; - /** The identity that last modified the resource. */ - lastModifiedBy?: string; - /** The type of identity that last modified the resource. */ - lastModifiedByType?: CreatedByType; - /** The timestamp of resource last modification (UTC) */ - lastModifiedAt?: Date; +/** Localized display information for this particular operation. */ +export interface OperationDisplay { + /** + * The localized friendly form of the resource provider name, e.g. "Microsoft Monitoring Insights" or "Microsoft Compute". + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly provider?: string; + /** + * The localized friendly name of the resource type related to this operation. E.g. "Virtual Machines" or "Job Schedule Collections". + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly resource?: string; + /** + * The concise, localized friendly name for the operation; suitable for dropdowns. E.g. "Create or Update Virtual Machine", "Restart Virtual Machine". + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly operation?: string; + /** + * The short, localized friendly description of the operation; suitable for tool tips and detailed views. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly description?: string; } /** Common error response for all Azure Resource Manager APIs to return error details for failed operations. (This also follows the OData error response format.). */ @@ -108,6 +121,57 @@ export interface ErrorAdditionalInfo { readonly info?: Record; } +/** Data boundary properties */ +export interface DataBoundaryProperties { + /** The data boundary definition. */ + dataBoundary?: DataBoundary; + /** + * Denotes the state of provisioning. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly provisioningState?: ProvisioningState; +} + +/** Common fields that are returned in the response for all Azure Resource Manager resources */ +export interface Resource { + /** + * Fully qualified resource ID for the resource. E.g. "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}" + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly id?: string; + /** + * The name of the resource + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly name?: string; + /** + * The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly type?: string; + /** + * Azure Resource Manager metadata containing createdBy and modifiedBy information. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly systemData?: SystemData; +} + +/** Metadata pertaining to creation and last modification of the resource. */ +export interface SystemData { + /** The identity that created the resource. */ + createdBy?: string; + /** The type of identity that created the resource. */ + createdByType?: CreatedByType; + /** The timestamp of resource creation (UTC). */ + createdAt?: Date; + /** The identity that last modified the resource. */ + lastModifiedBy?: string; + /** The type of identity that last modified the resource. */ + lastModifiedByType?: CreatedByType; + /** The timestamp of resource last modification (UTC) */ + lastModifiedAt?: Date; +} + /** The resource model definition for a Azure Resource Manager proxy resource. It will not have tags and a location */ export interface ProxyResource extends Resource {} @@ -117,6 +181,42 @@ export interface DataBoundaryDefinition extends ProxyResource { properties?: DataBoundaryProperties; } +/** Known values of {@link Origin} that the service accepts. */ +export enum KnownOrigin { + /** User */ + User = "user", + /** System */ + System = "system", + /** UserSystem */ + UserSystem = "user,system", +} + +/** + * Defines values for Origin. \ + * {@link KnownOrigin} can be used interchangeably with Origin, + * this enum contains the known values that the service supports. + * ### Known values supported by the service + * **user** \ + * **system** \ + * **user,system** + */ +export type Origin = string; + +/** Known values of {@link ActionType} that the service accepts. */ +export enum KnownActionType { + /** Internal */ + Internal = "Internal", +} + +/** + * Defines values for ActionType. \ + * {@link KnownActionType} can be used interchangeably with ActionType, + * this enum contains the known values that the service supports. + * ### Known values supported by the service + * **Internal** + */ +export type ActionType = string; + /** Known values of {@link DefaultName} that the service accepts. */ export enum KnownDefaultName { /** Default */ @@ -210,6 +310,20 @@ export enum KnownCreatedByType { */ export type CreatedByType = string; +/** Optional parameters. */ +export interface OperationsListOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the list operation. */ +export type OperationsListResponse = OperationListResult; + +/** Optional parameters. */ +export interface OperationsListNextOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the listNext operation. */ +export type OperationsListNextResponse = OperationListResult; + /** Optional parameters. */ export interface DataBoundariesPutOptionalParams extends coreClient.OperationOptions {} @@ -232,7 +346,7 @@ export interface DataBoundariesGetScopeOptionalParams export type DataBoundariesGetScopeResponse = DataBoundaryDefinition; /** Optional parameters. */ -export interface DataboundariesManegementClientOptionalParams +export interface DataBoundaryOptionalParams extends coreClient.ServiceClientOptions { /** server parameter */ $host?: string; diff --git a/sdk/databoundaries/arm-databoundaries/src/models/mappers.ts b/sdk/databoundaries/arm-databoundaries/src/models/mappers.ts index 9c5363c70d88..c3737b18b0c7 100644 --- a/sdk/databoundaries/arm-databoundaries/src/models/mappers.ts +++ b/sdk/databoundaries/arm-databoundaries/src/models/mappers.ts @@ -8,19 +8,26 @@ import * as coreClient from "@azure/core-client"; -export const DataBoundaryProperties: coreClient.CompositeMapper = { +export const OperationListResult: coreClient.CompositeMapper = { type: { name: "Composite", - className: "DataBoundaryProperties", + className: "OperationListResult", modelProperties: { - dataBoundary: { - serializedName: "dataBoundary", + value: { + serializedName: "value", + readOnly: true, type: { - name: "String", + name: "Sequence", + element: { + type: { + name: "Composite", + className: "Operation", + }, + }, }, }, - provisioningState: { - serializedName: "provisioningState", + nextLink: { + serializedName: "nextLink", readOnly: true, type: { name: "String", @@ -30,84 +37,83 @@ export const DataBoundaryProperties: coreClient.CompositeMapper = { }, }; -export const Resource: coreClient.CompositeMapper = { +export const Operation: coreClient.CompositeMapper = { type: { name: "Composite", - className: "Resource", + className: "Operation", modelProperties: { - id: { - serializedName: "id", + name: { + serializedName: "name", readOnly: true, type: { name: "String", }, }, - name: { - serializedName: "name", + isDataAction: { + serializedName: "isDataAction", readOnly: true, type: { - name: "String", + name: "Boolean", }, }, - type: { - serializedName: "type", + display: { + serializedName: "display", + type: { + name: "Composite", + className: "OperationDisplay", + }, + }, + origin: { + serializedName: "origin", readOnly: true, type: { name: "String", }, }, - systemData: { - serializedName: "systemData", + actionType: { + serializedName: "actionType", + readOnly: true, type: { - name: "Composite", - className: "SystemData", + name: "String", }, }, }, }, }; -export const SystemData: coreClient.CompositeMapper = { +export const OperationDisplay: coreClient.CompositeMapper = { type: { name: "Composite", - className: "SystemData", + className: "OperationDisplay", modelProperties: { - createdBy: { - serializedName: "createdBy", + provider: { + serializedName: "provider", + readOnly: true, type: { name: "String", }, }, - createdByType: { - serializedName: "createdByType", + resource: { + serializedName: "resource", + readOnly: true, type: { name: "String", }, }, - createdAt: { - serializedName: "createdAt", - type: { - name: "DateTime", - }, - }, - lastModifiedBy: { - serializedName: "lastModifiedBy", + operation: { + serializedName: "operation", + readOnly: true, type: { name: "String", }, }, - lastModifiedByType: { - serializedName: "lastModifiedByType", + description: { + serializedName: "description", + readOnly: true, type: { name: "String", }, }, - lastModifiedAt: { - serializedName: "lastModifiedAt", - type: { - name: "DateTime", - }, - }, }, }, }; @@ -208,6 +214,110 @@ export const ErrorAdditionalInfo: coreClient.CompositeMapper = { }, }; +export const DataBoundaryProperties: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "DataBoundaryProperties", + modelProperties: { + dataBoundary: { + serializedName: "dataBoundary", + type: { + name: "String", + }, + }, + provisioningState: { + serializedName: "provisioningState", + readOnly: true, + type: { + name: "String", + }, + }, + }, + }, +}; + +export const Resource: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "Resource", + modelProperties: { + id: { + serializedName: "id", + readOnly: true, + type: { + name: "String", + }, + }, + name: { + serializedName: "name", + readOnly: true, + type: { + name: "String", + }, + }, + type: { + serializedName: "type", + readOnly: true, + type: { + name: "String", + }, + }, + systemData: { + serializedName: "systemData", + type: { + name: "Composite", + className: "SystemData", + }, + }, + }, + }, +}; + +export const SystemData: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "SystemData", + modelProperties: { + createdBy: { + serializedName: "createdBy", + type: { + name: "String", + }, + }, + createdByType: { + serializedName: "createdByType", + type: { + name: "String", + }, + }, + createdAt: { + serializedName: "createdAt", + type: { + name: "DateTime", + }, + }, + lastModifiedBy: { + serializedName: "lastModifiedBy", + type: { + name: "String", + }, + }, + lastModifiedByType: { + serializedName: "lastModifiedByType", + type: { + name: "String", + }, + }, + lastModifiedAt: { + serializedName: "lastModifiedAt", + type: { + name: "DateTime", + }, + }, + }, + }, +}; + export const ProxyResource: coreClient.CompositeMapper = { type: { name: "Composite", diff --git a/sdk/databoundaries/arm-databoundaries/src/models/parameters.ts b/sdk/databoundaries/arm-databoundaries/src/models/parameters.ts index 5eb93554b395..194bf1d5f44d 100644 --- a/sdk/databoundaries/arm-databoundaries/src/models/parameters.ts +++ b/sdk/databoundaries/arm-databoundaries/src/models/parameters.ts @@ -13,23 +13,6 @@ import { } from "@azure/core-client"; import { DataBoundaryDefinition as DataBoundaryDefinitionMapper } from "../models/mappers"; -export const contentType: OperationParameter = { - parameterPath: ["options", "contentType"], - mapper: { - defaultValue: "application/json", - isConstant: true, - serializedName: "Content-Type", - type: { - name: "String", - }, - }, -}; - -export const dataBoundaryDefinition: OperationParameter = { - parameterPath: "dataBoundaryDefinition", - mapper: DataBoundaryDefinitionMapper, -}; - export const accept: OperationParameter = { parameterPath: "accept", mapper: { @@ -66,6 +49,35 @@ export const apiVersion: OperationQueryParameter = { }, }; +export const nextLink: OperationURLParameter = { + parameterPath: "nextLink", + mapper: { + serializedName: "nextLink", + required: true, + type: { + name: "String", + }, + }, + skipEncoding: true, +}; + +export const contentType: OperationParameter = { + parameterPath: ["options", "contentType"], + mapper: { + defaultValue: "application/json", + isConstant: true, + serializedName: "Content-Type", + type: { + name: "String", + }, + }, +}; + +export const dataBoundaryDefinition: OperationParameter = { + parameterPath: "dataBoundaryDefinition", + mapper: DataBoundaryDefinitionMapper, +}; + export const defaultParam: OperationURLParameter = { parameterPath: "defaultParam", mapper: { diff --git a/sdk/databoundaries/arm-databoundaries/src/operations/dataBoundaries.ts b/sdk/databoundaries/arm-databoundaries/src/operations/dataBoundaries.ts index a47a8729cdd3..5a1739d353a9 100644 --- a/sdk/databoundaries/arm-databoundaries/src/operations/dataBoundaries.ts +++ b/sdk/databoundaries/arm-databoundaries/src/operations/dataBoundaries.ts @@ -10,7 +10,7 @@ import { DataBoundaries } from "../operationsInterfaces"; import * as coreClient from "@azure/core-client"; import * as Mappers from "../models/mappers"; import * as Parameters from "../models/parameters"; -import { DataboundariesManegementClient } from "../databoundariesManegementClient"; +import { DataBoundary } from "../dataBoundary"; import { DataBoundaryDefinition, DefaultName, @@ -24,13 +24,13 @@ import { /** Class containing DataBoundaries operations. */ export class DataBoundariesImpl implements DataBoundaries { - private readonly client: DataboundariesManegementClient; + private readonly client: DataBoundary; /** * Initialize a new instance of the class DataBoundaries class. * @param client Reference to the service client */ - constructor(client: DataboundariesManegementClient) { + constructor(client: DataBoundary) { this.client = client; } @@ -103,7 +103,7 @@ const putOperationSpec: coreClient.OperationSpec = { requestBody: Parameters.dataBoundaryDefinition, queryParameters: [Parameters.apiVersion], urlParameters: [Parameters.$host, Parameters.defaultParam], - headerParameters: [Parameters.contentType, Parameters.accept], + headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", serializer, }; diff --git a/sdk/databoundaries/arm-databoundaries/src/operations/index.ts b/sdk/databoundaries/arm-databoundaries/src/operations/index.ts index 70eb1ee0f14f..9cb82d3966d7 100644 --- a/sdk/databoundaries/arm-databoundaries/src/operations/index.ts +++ b/sdk/databoundaries/arm-databoundaries/src/operations/index.ts @@ -6,4 +6,5 @@ * Changes may cause incorrect behavior and will be lost if the code is regenerated. */ +export * from "./operations"; export * from "./dataBoundaries"; diff --git a/sdk/databoundaries/arm-databoundaries/src/operations/operations.ts b/sdk/databoundaries/arm-databoundaries/src/operations/operations.ts new file mode 100644 index 000000000000..a19d34690846 --- /dev/null +++ b/sdk/databoundaries/arm-databoundaries/src/operations/operations.ts @@ -0,0 +1,149 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +import { PagedAsyncIterableIterator, PageSettings } from "@azure/core-paging"; +import { setContinuationToken } from "../pagingHelper"; +import { Operations } from "../operationsInterfaces"; +import * as coreClient from "@azure/core-client"; +import * as Mappers from "../models/mappers"; +import * as Parameters from "../models/parameters"; +import { DataBoundary } from "../dataBoundary"; +import { + Operation, + OperationsListNextOptionalParams, + OperationsListOptionalParams, + OperationsListResponse, + OperationsListNextResponse, +} from "../models"; + +/// +/** Class containing Operations operations. */ +export class OperationsImpl implements Operations { + private readonly client: DataBoundary; + + /** + * Initialize a new instance of the class Operations class. + * @param client Reference to the service client + */ + constructor(client: DataBoundary) { + this.client = client; + } + + /** + * Lists all of the available Microsoft.Resources REST API operations. + * @param options The options parameters. + */ + public list( + options?: OperationsListOptionalParams, + ): PagedAsyncIterableIterator { + const iter = this.listPagingAll(options); + return { + next() { + return iter.next(); + }, + [Symbol.asyncIterator]() { + return this; + }, + byPage: (settings?: PageSettings) => { + if (settings?.maxPageSize) { + throw new Error("maxPageSize is not supported by this operation."); + } + return this.listPagingPage(options, settings); + }, + }; + } + + private async *listPagingPage( + options?: OperationsListOptionalParams, + settings?: PageSettings, + ): AsyncIterableIterator { + let result: OperationsListResponse; + let continuationToken = settings?.continuationToken; + if (!continuationToken) { + result = await this._list(options); + let page = result.value || []; + continuationToken = result.nextLink; + setContinuationToken(page, continuationToken); + yield page; + } + while (continuationToken) { + result = await this._listNext(continuationToken, options); + continuationToken = result.nextLink; + let page = result.value || []; + setContinuationToken(page, continuationToken); + yield page; + } + } + + private async *listPagingAll( + options?: OperationsListOptionalParams, + ): AsyncIterableIterator { + for await (const page of this.listPagingPage(options)) { + yield* page; + } + } + + /** + * Lists all of the available Microsoft.Resources REST API operations. + * @param options The options parameters. + */ + private _list( + options?: OperationsListOptionalParams, + ): Promise { + return this.client.sendOperationRequest({ options }, listOperationSpec); + } + + /** + * ListNext + * @param nextLink The nextLink from the previous successful call to the List method. + * @param options The options parameters. + */ + private _listNext( + nextLink: string, + options?: OperationsListNextOptionalParams, + ): Promise { + return this.client.sendOperationRequest( + { nextLink, options }, + listNextOperationSpec, + ); + } +} +// Operation Specifications +const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); + +const listOperationSpec: coreClient.OperationSpec = { + path: "/providers/Microsoft.Resources/operations", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.OperationListResult, + }, + default: { + bodyMapper: Mappers.ErrorResponse, + }, + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [Parameters.$host], + headerParameters: [Parameters.accept], + serializer, +}; +const listNextOperationSpec: coreClient.OperationSpec = { + path: "{nextLink}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.OperationListResult, + }, + default: { + bodyMapper: Mappers.ErrorResponse, + }, + }, + urlParameters: [Parameters.$host, Parameters.nextLink], + headerParameters: [Parameters.accept], + serializer, +}; diff --git a/sdk/databoundaries/arm-databoundaries/src/operationsInterfaces/index.ts b/sdk/databoundaries/arm-databoundaries/src/operationsInterfaces/index.ts index 70eb1ee0f14f..9cb82d3966d7 100644 --- a/sdk/databoundaries/arm-databoundaries/src/operationsInterfaces/index.ts +++ b/sdk/databoundaries/arm-databoundaries/src/operationsInterfaces/index.ts @@ -6,4 +6,5 @@ * Changes may cause incorrect behavior and will be lost if the code is regenerated. */ +export * from "./operations"; export * from "./dataBoundaries"; diff --git a/sdk/databoundaries/arm-databoundaries/src/operationsInterfaces/operations.ts b/sdk/databoundaries/arm-databoundaries/src/operationsInterfaces/operations.ts new file mode 100644 index 000000000000..65cdf8035ab0 --- /dev/null +++ b/sdk/databoundaries/arm-databoundaries/src/operationsInterfaces/operations.ts @@ -0,0 +1,22 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +import { PagedAsyncIterableIterator } from "@azure/core-paging"; +import { Operation, OperationsListOptionalParams } from "../models"; + +/// +/** Interface representing a Operations. */ +export interface Operations { + /** + * Lists all of the available Microsoft.Resources REST API operations. + * @param options The options parameters. + */ + list( + options?: OperationsListOptionalParams, + ): PagedAsyncIterableIterator; +} diff --git a/sdk/databoundaries/arm-databoundaries/src/pagingHelper.ts b/sdk/databoundaries/arm-databoundaries/src/pagingHelper.ts new file mode 100644 index 000000000000..205cccc26592 --- /dev/null +++ b/sdk/databoundaries/arm-databoundaries/src/pagingHelper.ts @@ -0,0 +1,39 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +export interface PageInfo { + continuationToken?: string; +} + +const pageMap = new WeakMap(); + +/** + * Given the last `.value` produced by the `byPage` iterator, + * returns a continuation token that can be used to begin paging from + * that point later. + * @param page An object from accessing `value` on the IteratorResult from a `byPage` iterator. + * @returns The continuation token that can be passed into byPage() during future calls. + */ +export function getContinuationToken(page: unknown): string | undefined { + if (typeof page !== "object" || page === null) { + return undefined; + } + return pageMap.get(page)?.continuationToken; +} + +export function setContinuationToken( + page: unknown, + continuationToken: string | undefined, +): void { + if (typeof page !== "object" || page === null || !continuationToken) { + return; + } + const pageInfo = pageMap.get(page) ?? {}; + pageInfo.continuationToken = continuationToken; + pageMap.set(page, pageInfo); +} diff --git a/sdk/databoundaries/arm-databoundaries/test/sampleTest.ts b/sdk/databoundaries/arm-databoundaries/test/sampleTest.ts new file mode 100644 index 000000000000..d64be981b694 --- /dev/null +++ b/sdk/databoundaries/arm-databoundaries/test/sampleTest.ts @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +import { + Recorder, + RecorderStartOptions, + env, +} from "@azure-tools/test-recorder"; +import { assert } from "chai"; +import { Context } from "mocha"; + +const replaceableVariables: Record = { + AZURE_CLIENT_ID: "azure_client_id", + AZURE_CLIENT_SECRET: "azure_client_secret", + AZURE_TENANT_ID: "88888888-8888-8888-8888-888888888888", + SUBSCRIPTION_ID: "azure_subscription_id", +}; + +const recorderOptions: RecorderStartOptions = { + envSetupForPlayback: replaceableVariables, +}; + +describe("My test", () => { + let recorder: Recorder; + + beforeEach(async function (this: Context) { + recorder = new Recorder(this.currentTest); + await recorder.start(recorderOptions); + }); + + afterEach(async function () { + await recorder.stop(); + }); + + it("sample test", async function () { + console.log("Hi, I'm a test!"); + }); +}); diff --git a/sdk/databoundaries/arm-databoundaries/tsconfig.json b/sdk/databoundaries/arm-databoundaries/tsconfig.json index 701c0e733749..146f504c20d4 100644 --- a/sdk/databoundaries/arm-databoundaries/tsconfig.json +++ b/sdk/databoundaries/arm-databoundaries/tsconfig.json @@ -15,17 +15,21 @@ ], "declaration": true, "outDir": "./dist-esm", - "importHelpers": true, - "paths": { - "@azure/arm-databoundaries": [ - "./src/index" - ] - } + "importHelpers": true }, "include": [ "./src/**/*.ts", "./test/**/*.ts", - "samples-dev/**/*.ts" + "./test/**/*.ts", + "./test/**/*.ts", + "./test/**/*.ts", + "./test/**/*.ts", + "./test/**/*.ts", + "./test/**/*.ts", + "./test/**/*.ts", + "./test/**/*.ts", + "./test/**/*.ts", + "./test/**/*.ts" ], "exclude": [ "node_modules" diff --git a/sdk/features/arm-features/CHANGELOG.md b/sdk/features/arm-features/CHANGELOG.md index ed01550a1e65..5aac72409331 100644 --- a/sdk/features/arm-features/CHANGELOG.md +++ b/sdk/features/arm-features/CHANGELOG.md @@ -1,15 +1,12 @@ # Release History - -## 3.1.1 (Unreleased) - -### Features Added - + +## 4.0.0 (2024-11-01) + ### Breaking Changes -### Bugs Fixed - -### Other Changes - + - Class FeatureClient has a new signature + + ## 3.1.0 (2022-11-22) ### Features Added @@ -18,7 +15,7 @@ ## 3.0.1 (2022-04-18) -### Features Added +**features** - Bug fix @@ -30,4 +27,4 @@ To understand the detail of the change, please refer to [Changelog](https://aka. To migrate the existing applications to the latest version, please refer to [Migration Guide](https://aka.ms/js-track2-migration-guide). -To learn more, please refer to our documentation [Quick Start](https://aka.ms/azsdk/js/mgmt/quickstart ). +To learn more, please refer to our documentation [Quick Start](https://aka.ms/azsdk/js/mgmt/quickstart). diff --git a/sdk/features/arm-features/LICENSE b/sdk/features/arm-features/LICENSE index 5d1d36e0af80..7d5934740965 100644 --- a/sdk/features/arm-features/LICENSE +++ b/sdk/features/arm-features/LICENSE @@ -1,6 +1,6 @@ The MIT License (MIT) -Copyright (c) 2022 Microsoft +Copyright (c) 2024 Microsoft Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal diff --git a/sdk/features/arm-features/_meta.json b/sdk/features/arm-features/_meta.json index 4b98b8203a1f..28591836c37e 100644 --- a/sdk/features/arm-features/_meta.json +++ b/sdk/features/arm-features/_meta.json @@ -1,8 +1,8 @@ { - "commit": "a42f1b58607091c4f255ead152a8ef323fa0b280", - "readme": "specification\\resources\\resource-manager\\readme.md", - "autorest_command": "autorest --version=3.8.4 --typescript --modelerfour.lenient-model-deduplication --azure-arm --head-as-boolean=true --license-header=MICROSOFT_MIT_NO_VERSION --generate-test --typescript-sdks-folder=D:\\Git\\azure-sdk-for-js ..\\azure-rest-api-specs\\specification\\resources\\resource-manager\\readme.md --use=@autorest/typescript@6.0.0-rc.3.20221108.1 --generate-sample=true", + "commit": "5342edb61d78cec6e07b17a6cd8f7749c6697272", + "readme": "specification/resources/resource-manager/readme.md", + "autorest_command": "autorest --version=3.9.7 --typescript --modelerfour.lenient-model-deduplication --azure-arm --head-as-boolean=true --license-header=MICROSOFT_MIT_NO_VERSION --generate-test --typescript-sdks-folder=/mnt/vss/_work/1/s/azure-sdk-for-js ../azure-rest-api-specs/specification/resources/resource-manager/readme.md --use=@autorest/typescript@^6.0.12", "repository_url": "https://github.com/Azure/azure-rest-api-specs.git", - "release_tool": "@azure-tools/js-sdk-release-tools@2.4.2", - "use": "@autorest/typescript@6.0.0-rc.3.20221108.1" + "release_tool": "@azure-tools/js-sdk-release-tools@2.7.14", + "use": "@autorest/typescript@^6.0.12" } \ No newline at end of file diff --git a/sdk/features/arm-features/package.json b/sdk/features/arm-features/package.json index 638b7eec30b3..3f5793f78254 100644 --- a/sdk/features/arm-features/package.json +++ b/sdk/features/arm-features/package.json @@ -3,15 +3,15 @@ "sdk-type": "mgmt", "author": "Microsoft Corporation", "description": "A generated SDK for FeatureClient.", - "version": "3.1.1", + "version": "4.0.0", "engines": { "node": ">=18.0.0" }, "dependencies": { - "@azure/core-auth": "^1.3.0", - "@azure/core-client": "^1.6.1", "@azure/core-paging": "^1.2.0", - "@azure/core-rest-pipeline": "^1.8.0", + "@azure/core-client": "^1.7.0", + "@azure/core-auth": "^1.6.0", + "@azure/core-rest-pipeline": "^1.14.0", "tslib": "^2.2.0" }, "keywords": [ @@ -26,20 +26,25 @@ "module": "./dist-esm/src/index.js", "types": "./types/arm-features.d.ts", "devDependencies": { - "@azure-tools/test-credential": "^1.0.0", - "@azure-tools/test-recorder": "^3.0.0", + "@microsoft/api-extractor": "^7.31.1", + "mkdirp": "^3.0.1", + "typescript": "~5.5.3", + "uglify-js": "^3.4.9", + "rimraf": "^5.0.0", + "dotenv": "^16.0.0", "@azure/dev-tool": "^1.0.0", - "@azure/identity": "^4.0.1", - "@types/chai": "^4.2.8", + "@azure/identity": "^4.2.1", + "@azure-tools/test-recorder": "^3.0.0", + "@azure-tools/test-credential": "^1.1.0", + "mocha": "^10.0.0", "@types/mocha": "^10.0.0", - "@types/node": "^18.0.0", + "tsx": "^4.7.1", + "@types/chai": "^4.2.8", "chai": "^4.2.0", "cross-env": "^7.0.2", - "mocha": "^10.0.0", - "ts-node": "^10.0.0", - "typescript": "~5.6.2" + "@types/node": "^18.0.0", + "ts-node": "^10.0.0" }, - "homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/features/arm-features", "repository": { "type": "git", "url": "https://github.com/Azure/azure-sdk-for-js.git" @@ -65,30 +70,29 @@ "types/*" ], "scripts": { - "build": "npm run clean && tsc && dev-tool run bundle && npm run minify && dev-tool run vendored mkdirp ./review && npm run extract-api", - "build:browser": "echo skipped", + "build": "npm run clean && tsc && dev-tool run bundle && npm run minify && mkdirp ./review && npm run extract-api", + "minify": "uglifyjs -c -m --comments --source-map \"content='./dist/index.js.map'\" -o ./dist/index.min.js ./dist/index.js", + "prepack": "npm run build", + "pack": "npm pack 2>&1", + "extract-api": "dev-tool run extract-api", + "lint": "echo skipped", + "clean": "rimraf --glob dist dist-browser dist-esm test-dist temp types *.tgz *.log", "build:node": "echo skipped", - "build:samples": "echo skipped.", + "build:browser": "echo skipped", "build:test": "echo skipped", + "build:samples": "echo skipped.", "check-format": "echo skipped", - "clean": "dev-tool run vendored rimraf --glob dist dist-browser dist-esm test-dist temp types *.tgz *.log", "execute:samples": "echo skipped", - "extract-api": "dev-tool run extract-api", "format": "echo skipped", - "integration-test": "npm run integration-test:node && npm run integration-test:browser", - "integration-test:browser": "echo skipped", - "integration-test:node": "dev-tool run test:node-ts-input -- --timeout 1200000 'test/*.ts'", - "lint": "echo skipped", - "minify": "dev-tool run vendored uglifyjs -c -m --comments --source-map \"content='./dist/index.js.map'\" -o ./dist/index.min.js ./dist/index.js", - "pack": "npm pack 2>&1", - "prepack": "npm run build", "test": "npm run integration-test", - "test:browser": "echo skipped", "test:node": "echo skipped", + "test:browser": "echo skipped", "unit-test": "npm run unit-test:node && npm run unit-test:browser", - "unit-test:browser": "echo skipped", "unit-test:node": "cross-env TEST_MODE=playback npm run integration-test:node", - "update-snippets": "echo skipped" + "unit-test:browser": "echo skipped", + "integration-test": "npm run integration-test:node && npm run integration-test:browser", + "integration-test:node": "dev-tool run test:node-ts-input -- --timeout 1200000 'test/*.ts'", + "integration-test:browser": "echo skipped" }, "sideEffects": false, "//metadata": { @@ -100,12 +104,5 @@ ] }, "autoPublish": true, - "//sampleConfiguration": { - "productName": "", - "productSlugs": [ - "azure" - ], - "disableDocsMs": true, - "apiRefLink": "https://docs.microsoft.com/javascript/api/@azure/arm-features?view=azure-node-preview" - } -} + "homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/features/arm-features" +} \ No newline at end of file diff --git a/sdk/features/arm-features/review/arm-features.api.md b/sdk/features/arm-features/review/arm-features.api.md index 89f95f572452..b011cb9640a5 100644 --- a/sdk/features/arm-features/review/arm-features.api.md +++ b/sdk/features/arm-features/review/arm-features.api.md @@ -34,6 +34,7 @@ export class FeatureClient extends coreClient.ServiceClient { // (undocumented) $host: string; constructor(credentials: coreAuth.TokenCredential, subscriptionId: string, options?: FeatureClientOptionalParams); + constructor(credentials: coreAuth.TokenCredential, options?: FeatureClientOptionalParams); // (undocumented) apiVersion: string; // (undocumented) @@ -42,7 +43,7 @@ export class FeatureClient extends coreClient.ServiceClient { // (undocumented) subscriptionFeatureRegistrations: SubscriptionFeatureRegistrations; // (undocumented) - subscriptionId: string; + subscriptionId?: string; } // @public diff --git a/sdk/features/arm-features/src/featureClient.ts b/sdk/features/arm-features/src/featureClient.ts index 895c1fb0c8ef..290786081c17 100644 --- a/sdk/features/arm-features/src/featureClient.ts +++ b/sdk/features/arm-features/src/featureClient.ts @@ -11,18 +11,18 @@ import * as coreRestPipeline from "@azure/core-rest-pipeline"; import { PipelineRequest, PipelineResponse, - SendRequest + SendRequest, } from "@azure/core-rest-pipeline"; import * as coreAuth from "@azure/core-auth"; import { PagedAsyncIterableIterator, PageSettings } from "@azure/core-paging"; import { setContinuationToken } from "./pagingHelper"; import { FeaturesImpl, - SubscriptionFeatureRegistrationsImpl + SubscriptionFeatureRegistrationsImpl, } from "./operations"; import { Features, - SubscriptionFeatureRegistrations + SubscriptionFeatureRegistrations, } from "./operationsInterfaces"; import * as Parameters from "./models/parameters"; import * as Mappers from "./models/mappers"; @@ -32,14 +32,14 @@ import { ListOperationsNextOptionalParams, ListOperationsOptionalParams, ListOperationsResponse, - ListOperationsNextResponse + ListOperationsNextResponse, } from "./models"; /// export class FeatureClient extends coreClient.ServiceClient { $host: string; apiVersion: string; - subscriptionId: string; + subscriptionId?: string; /** * Initializes a new instance of the FeatureClient class. @@ -50,13 +50,27 @@ export class FeatureClient extends coreClient.ServiceClient { constructor( credentials: coreAuth.TokenCredential, subscriptionId: string, - options?: FeatureClientOptionalParams + options?: FeatureClientOptionalParams, + ); + constructor( + credentials: coreAuth.TokenCredential, + options?: FeatureClientOptionalParams, + ); + constructor( + credentials: coreAuth.TokenCredential, + subscriptionIdOrOptions?: FeatureClientOptionalParams | string, + options?: FeatureClientOptionalParams, ) { if (credentials === undefined) { throw new Error("'credentials' cannot be null"); } - if (subscriptionId === undefined) { - throw new Error("'subscriptionId' cannot be null"); + + let subscriptionId: string | undefined; + + if (typeof subscriptionIdOrOptions === "string") { + subscriptionId = subscriptionIdOrOptions; + } else if (typeof subscriptionIdOrOptions === "object") { + options = subscriptionIdOrOptions; } // Initializing default values for options @@ -65,10 +79,10 @@ export class FeatureClient extends coreClient.ServiceClient { } const defaults: FeatureClientOptionalParams = { requestContentType: "application/json; charset=utf-8", - credential: credentials + credential: credentials, }; - const packageDetails = `azsdk-js-arm-features/3.1.1`; + const packageDetails = `azsdk-js-arm-features/4.0.0`; const userAgentPrefix = options.userAgentOptions && options.userAgentOptions.userAgentPrefix ? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}` @@ -78,20 +92,21 @@ export class FeatureClient extends coreClient.ServiceClient { ...defaults, ...options, userAgentOptions: { - userAgentPrefix + userAgentPrefix, }, endpoint: - options.endpoint ?? options.baseUri ?? "https://management.azure.com" + options.endpoint ?? options.baseUri ?? "https://management.azure.com", }; super(optionsWithDefaults); let bearerTokenAuthenticationPolicyFound: boolean = false; if (options?.pipeline && options.pipeline.getOrderedPolicies().length > 0) { - const pipelinePolicies: coreRestPipeline.PipelinePolicy[] = options.pipeline.getOrderedPolicies(); + const pipelinePolicies: coreRestPipeline.PipelinePolicy[] = + options.pipeline.getOrderedPolicies(); bearerTokenAuthenticationPolicyFound = pipelinePolicies.some( (pipelinePolicy) => pipelinePolicy.name === - coreRestPipeline.bearerTokenAuthenticationPolicyName + coreRestPipeline.bearerTokenAuthenticationPolicyName, ); } if ( @@ -101,7 +116,7 @@ export class FeatureClient extends coreClient.ServiceClient { !bearerTokenAuthenticationPolicyFound ) { this.pipeline.removePolicy({ - name: coreRestPipeline.bearerTokenAuthenticationPolicyName + name: coreRestPipeline.bearerTokenAuthenticationPolicyName, }); this.pipeline.addPolicy( coreRestPipeline.bearerTokenAuthenticationPolicy({ @@ -111,9 +126,9 @@ export class FeatureClient extends coreClient.ServiceClient { `${optionsWithDefaults.endpoint}/.default`, challengeCallbacks: { authorizeRequestOnChallenge: - coreClient.authorizeRequestOnClaimChallenge - } - }) + coreClient.authorizeRequestOnClaimChallenge, + }, + }), ); } // Parameter assignments @@ -123,9 +138,8 @@ export class FeatureClient extends coreClient.ServiceClient { this.$host = options.$host || "https://management.azure.com"; this.apiVersion = options.apiVersion || "2021-07-01"; this.features = new FeaturesImpl(this); - this.subscriptionFeatureRegistrations = new SubscriptionFeatureRegistrationsImpl( - this - ); + this.subscriptionFeatureRegistrations = + new SubscriptionFeatureRegistrationsImpl(this); this.addCustomApiVersionPolicy(options.apiVersion); } @@ -138,7 +152,7 @@ export class FeatureClient extends coreClient.ServiceClient { name: "CustomApiVersionPolicy", async sendRequest( request: PipelineRequest, - next: SendRequest + next: SendRequest, ): Promise { const param = request.url.split("?"); if (param.length > 1) { @@ -152,7 +166,7 @@ export class FeatureClient extends coreClient.ServiceClient { request.url = param[0] + "?" + newParams.join("&"); } return next(request); - } + }, }; this.pipeline.addPolicy(apiVersionPolicy); } @@ -162,7 +176,7 @@ export class FeatureClient extends coreClient.ServiceClient { * @param options The options parameters. */ public listOperations( - options?: ListOperationsOptionalParams + options?: ListOperationsOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listOperationsPagingAll(options); return { @@ -177,13 +191,13 @@ export class FeatureClient extends coreClient.ServiceClient { throw new Error("maxPageSize is not supported by this operation."); } return this.listOperationsPagingPage(options, settings); - } + }, }; } private async *listOperationsPagingPage( options?: ListOperationsOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: ListOperationsResponse; let continuationToken = settings?.continuationToken; @@ -204,7 +218,7 @@ export class FeatureClient extends coreClient.ServiceClient { } private async *listOperationsPagingAll( - options?: ListOperationsOptionalParams + options?: ListOperationsOptionalParams, ): AsyncIterableIterator { for await (const page of this.listOperationsPagingPage(options)) { yield* page; @@ -216,7 +230,7 @@ export class FeatureClient extends coreClient.ServiceClient { * @param options The options parameters. */ private _listOperations( - options?: ListOperationsOptionalParams + options?: ListOperationsOptionalParams, ): Promise { return this.sendOperationRequest({ options }, listOperationsOperationSpec); } @@ -228,11 +242,11 @@ export class FeatureClient extends coreClient.ServiceClient { */ private _listOperationsNext( nextLink: string, - options?: ListOperationsNextOptionalParams + options?: ListOperationsNextOptionalParams, ): Promise { return this.sendOperationRequest( { nextLink, options }, - listOperationsNextOperationSpec + listOperationsNextOperationSpec, ); } @@ -247,30 +261,29 @@ const listOperationsOperationSpec: coreClient.OperationSpec = { httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.OperationListResult + bodyMapper: Mappers.OperationListResult, }, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [Parameters.$host], headerParameters: [Parameters.accept], - serializer + serializer, }; const listOperationsNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.OperationListResult + bodyMapper: Mappers.OperationListResult, }, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, - queryParameters: [Parameters.apiVersion], urlParameters: [Parameters.$host, Parameters.nextLink], headerParameters: [Parameters.accept], - serializer + serializer, }; diff --git a/sdk/features/arm-features/src/models/index.ts b/sdk/features/arm-features/src/models/index.ts index 860adc9f14fa..ffc973d8b47d 100644 --- a/sdk/features/arm-features/src/models/index.ts +++ b/sdk/features/arm-features/src/models/index.ts @@ -216,7 +216,7 @@ export enum KnownSubscriptionFeatureRegistrationState { /** Unregistering */ Unregistering = "Unregistering", /** Unregistered */ - Unregistered = "Unregistered" + Unregistered = "Unregistered", } /** @@ -241,7 +241,7 @@ export enum KnownSubscriptionFeatureRegistrationApprovalType { /** ApprovalRequired */ ApprovalRequired = "ApprovalRequired", /** AutoApproval */ - AutoApproval = "AutoApproval" + AutoApproval = "AutoApproval", } /** @@ -323,7 +323,8 @@ export interface SubscriptionFeatureRegistrationsGetOptionalParams extends coreClient.OperationOptions {} /** Contains response data for the get operation. */ -export type SubscriptionFeatureRegistrationsGetResponse = SubscriptionFeatureRegistration; +export type SubscriptionFeatureRegistrationsGetResponse = + SubscriptionFeatureRegistration; /** Optional parameters. */ export interface SubscriptionFeatureRegistrationsCreateOrUpdateOptionalParams @@ -333,7 +334,8 @@ export interface SubscriptionFeatureRegistrationsCreateOrUpdateOptionalParams } /** Contains response data for the createOrUpdate operation. */ -export type SubscriptionFeatureRegistrationsCreateOrUpdateResponse = SubscriptionFeatureRegistration; +export type SubscriptionFeatureRegistrationsCreateOrUpdateResponse = + SubscriptionFeatureRegistration; /** Optional parameters. */ export interface SubscriptionFeatureRegistrationsDeleteOptionalParams @@ -344,28 +346,32 @@ export interface SubscriptionFeatureRegistrationsListBySubscriptionOptionalParam extends coreClient.OperationOptions {} /** Contains response data for the listBySubscription operation. */ -export type SubscriptionFeatureRegistrationsListBySubscriptionResponse = SubscriptionFeatureRegistrationList; +export type SubscriptionFeatureRegistrationsListBySubscriptionResponse = + SubscriptionFeatureRegistrationList; /** Optional parameters. */ export interface SubscriptionFeatureRegistrationsListAllBySubscriptionOptionalParams extends coreClient.OperationOptions {} /** Contains response data for the listAllBySubscription operation. */ -export type SubscriptionFeatureRegistrationsListAllBySubscriptionResponse = SubscriptionFeatureRegistrationList; +export type SubscriptionFeatureRegistrationsListAllBySubscriptionResponse = + SubscriptionFeatureRegistrationList; /** Optional parameters. */ export interface SubscriptionFeatureRegistrationsListBySubscriptionNextOptionalParams extends coreClient.OperationOptions {} /** Contains response data for the listBySubscriptionNext operation. */ -export type SubscriptionFeatureRegistrationsListBySubscriptionNextResponse = SubscriptionFeatureRegistrationList; +export type SubscriptionFeatureRegistrationsListBySubscriptionNextResponse = + SubscriptionFeatureRegistrationList; /** Optional parameters. */ export interface SubscriptionFeatureRegistrationsListAllBySubscriptionNextOptionalParams extends coreClient.OperationOptions {} /** Contains response data for the listAllBySubscriptionNext operation. */ -export type SubscriptionFeatureRegistrationsListAllBySubscriptionNextResponse = SubscriptionFeatureRegistrationList; +export type SubscriptionFeatureRegistrationsListAllBySubscriptionNextResponse = + SubscriptionFeatureRegistrationList; /** Optional parameters. */ export interface FeatureClientOptionalParams diff --git a/sdk/features/arm-features/src/models/mappers.ts b/sdk/features/arm-features/src/models/mappers.ts index 3c1185f9501a..d94745c23183 100644 --- a/sdk/features/arm-features/src/models/mappers.ts +++ b/sdk/features/arm-features/src/models/mappers.ts @@ -20,19 +20,19 @@ export const OperationListResult: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "Operation" - } - } - } + className: "Operation", + }, + }, + }, }, nextLink: { serializedName: "nextLink", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const Operation: coreClient.CompositeMapper = { @@ -43,18 +43,18 @@ export const Operation: coreClient.CompositeMapper = { name: { serializedName: "name", type: { - name: "String" - } + name: "String", + }, }, display: { serializedName: "display", type: { name: "Composite", - className: "OperationDisplay" - } - } - } - } + className: "OperationDisplay", + }, + }, + }, + }, }; export const OperationDisplay: coreClient.CompositeMapper = { @@ -65,23 +65,23 @@ export const OperationDisplay: coreClient.CompositeMapper = { provider: { serializedName: "provider", type: { - name: "String" - } + name: "String", + }, }, resource: { serializedName: "resource", type: { - name: "String" - } + name: "String", + }, }, operation: { serializedName: "operation", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const ErrorResponse: coreClient.CompositeMapper = { @@ -93,11 +93,11 @@ export const ErrorResponse: coreClient.CompositeMapper = { serializedName: "error", type: { name: "Composite", - className: "ErrorDefinition" - } - } - } - } + className: "ErrorDefinition", + }, + }, + }, + }, }; export const ErrorDefinition: coreClient.CompositeMapper = { @@ -109,15 +109,15 @@ export const ErrorDefinition: coreClient.CompositeMapper = { serializedName: "code", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, message: { serializedName: "message", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, details: { serializedName: "details", @@ -126,13 +126,13 @@ export const ErrorDefinition: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "ErrorDefinition" - } - } - } - } - } - } + className: "ErrorDefinition", + }, + }, + }, + }, + }, + }, }; export const FeatureOperationsListResult: coreClient.CompositeMapper = { @@ -147,19 +147,19 @@ export const FeatureOperationsListResult: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "FeatureResult" - } - } - } + className: "FeatureResult", + }, + }, + }, }, nextLink: { serializedName: "nextLink", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const FeatureResult: coreClient.CompositeMapper = { @@ -170,30 +170,30 @@ export const FeatureResult: coreClient.CompositeMapper = { name: { serializedName: "name", type: { - name: "String" - } + name: "String", + }, }, properties: { serializedName: "properties", type: { name: "Composite", - className: "FeatureProperties" - } + className: "FeatureProperties", + }, }, id: { serializedName: "id", type: { - name: "String" - } + name: "String", + }, }, type: { serializedName: "type", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const FeatureProperties: coreClient.CompositeMapper = { @@ -204,123 +204,127 @@ export const FeatureProperties: coreClient.CompositeMapper = { state: { serializedName: "state", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; -export const SubscriptionFeatureRegistrationProperties: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "SubscriptionFeatureRegistrationProperties", - modelProperties: { - tenantId: { - serializedName: "tenantId", - readOnly: true, - type: { - name: "String" - } - }, - subscriptionId: { - serializedName: "subscriptionId", - readOnly: true, - type: { - name: "String" - } - }, - featureName: { - serializedName: "featureName", - readOnly: true, - type: { - name: "String" - } - }, - displayName: { - serializedName: "displayName", - readOnly: true, - type: { - name: "String" - } - }, - providerNamespace: { - serializedName: "providerNamespace", - readOnly: true, - type: { - name: "String" - } - }, - state: { - serializedName: "state", - type: { - name: "String" - } - }, - authorizationProfile: { - serializedName: "authorizationProfile", - type: { - name: "Composite", - className: "AuthorizationProfile" - } - }, - metadata: { - serializedName: "metadata", - type: { - name: "Dictionary", - value: { type: { name: "String" }, constraints: { MaxLength: 1000 } } - } - }, - releaseDate: { - serializedName: "releaseDate", - readOnly: true, - type: { - name: "DateTime" - } - }, - registrationDate: { - serializedName: "registrationDate", - readOnly: true, - type: { - name: "DateTime" - } - }, - documentationLink: { - constraints: { - MaxLength: 1000 +export const SubscriptionFeatureRegistrationProperties: coreClient.CompositeMapper = + { + type: { + name: "Composite", + className: "SubscriptionFeatureRegistrationProperties", + modelProperties: { + tenantId: { + serializedName: "tenantId", + readOnly: true, + type: { + name: "String", + }, }, - serializedName: "documentationLink", - readOnly: true, - type: { - name: "String" - } - }, - approvalType: { - serializedName: "approvalType", - readOnly: true, - type: { - name: "String" - } - }, - shouldFeatureDisplayInPortal: { - defaultValue: false, - serializedName: "shouldFeatureDisplayInPortal", - type: { - name: "Boolean" - } - }, - description: { - constraints: { - MaxLength: 1000 + subscriptionId: { + serializedName: "subscriptionId", + readOnly: true, + type: { + name: "String", + }, }, - serializedName: "description", - type: { - name: "String" - } - } - } - } -}; + featureName: { + serializedName: "featureName", + readOnly: true, + type: { + name: "String", + }, + }, + displayName: { + serializedName: "displayName", + readOnly: true, + type: { + name: "String", + }, + }, + providerNamespace: { + serializedName: "providerNamespace", + readOnly: true, + type: { + name: "String", + }, + }, + state: { + serializedName: "state", + type: { + name: "String", + }, + }, + authorizationProfile: { + serializedName: "authorizationProfile", + type: { + name: "Composite", + className: "AuthorizationProfile", + }, + }, + metadata: { + serializedName: "metadata", + type: { + name: "Dictionary", + value: { + type: { name: "String" }, + constraints: { MaxLength: 1000 }, + }, + }, + }, + releaseDate: { + serializedName: "releaseDate", + readOnly: true, + type: { + name: "DateTime", + }, + }, + registrationDate: { + serializedName: "registrationDate", + readOnly: true, + type: { + name: "DateTime", + }, + }, + documentationLink: { + constraints: { + MaxLength: 1000, + }, + serializedName: "documentationLink", + readOnly: true, + type: { + name: "String", + }, + }, + approvalType: { + serializedName: "approvalType", + readOnly: true, + type: { + name: "String", + }, + }, + shouldFeatureDisplayInPortal: { + defaultValue: false, + serializedName: "shouldFeatureDisplayInPortal", + type: { + name: "Boolean", + }, + }, + description: { + constraints: { + MaxLength: 1000, + }, + serializedName: "description", + type: { + name: "String", + }, + }, + }, + }, + }; export const AuthorizationProfile: coreClient.CompositeMapper = { type: { @@ -331,39 +335,39 @@ export const AuthorizationProfile: coreClient.CompositeMapper = { serializedName: "requestedTime", readOnly: true, type: { - name: "DateTime" - } + name: "DateTime", + }, }, requester: { serializedName: "requester", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, requesterObjectId: { serializedName: "requesterObjectId", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, approvedTime: { serializedName: "approvedTime", readOnly: true, type: { - name: "DateTime" - } + name: "DateTime", + }, }, approver: { serializedName: "approver", readOnly: true, type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const ProxyResource: coreClient.CompositeMapper = { @@ -375,25 +379,25 @@ export const ProxyResource: coreClient.CompositeMapper = { serializedName: "id", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, name: { serializedName: "name", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, type: { serializedName: "type", readOnly: true, type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const SubscriptionFeatureRegistrationList: coreClient.CompositeMapper = { @@ -404,8 +408,8 @@ export const SubscriptionFeatureRegistrationList: coreClient.CompositeMapper = { nextLink: { serializedName: "nextLink", type: { - name: "String" - } + name: "String", + }, }, value: { serializedName: "value", @@ -414,13 +418,13 @@ export const SubscriptionFeatureRegistrationList: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "SubscriptionFeatureRegistration" - } - } - } - } - } - } + className: "SubscriptionFeatureRegistration", + }, + }, + }, + }, + }, + }, }; export const SubscriptionFeatureRegistration: coreClient.CompositeMapper = { @@ -433,9 +437,9 @@ export const SubscriptionFeatureRegistration: coreClient.CompositeMapper = { serializedName: "properties", type: { name: "Composite", - className: "SubscriptionFeatureRegistrationProperties" - } - } - } - } + className: "SubscriptionFeatureRegistrationProperties", + }, + }, + }, + }, }; diff --git a/sdk/features/arm-features/src/models/parameters.ts b/sdk/features/arm-features/src/models/parameters.ts index 66885213a589..ca6e7083189a 100644 --- a/sdk/features/arm-features/src/models/parameters.ts +++ b/sdk/features/arm-features/src/models/parameters.ts @@ -9,7 +9,7 @@ import { OperationParameter, OperationURLParameter, - OperationQueryParameter + OperationQueryParameter, } from "@azure/core-client"; import { SubscriptionFeatureRegistration as SubscriptionFeatureRegistrationMapper } from "../models/mappers"; @@ -20,9 +20,9 @@ export const accept: OperationParameter = { isConstant: true, serializedName: "Accept", type: { - name: "String" - } - } + name: "String", + }, + }, }; export const $host: OperationURLParameter = { @@ -31,10 +31,10 @@ export const $host: OperationURLParameter = { serializedName: "$host", required: true, type: { - name: "String" - } + name: "String", + }, }, - skipEncoding: true + skipEncoding: true, }; export const apiVersion: OperationQueryParameter = { @@ -44,9 +44,9 @@ export const apiVersion: OperationQueryParameter = { isConstant: true, serializedName: "api-version", type: { - name: "String" - } - } + name: "String", + }, + }, }; export const nextLink: OperationURLParameter = { @@ -55,10 +55,10 @@ export const nextLink: OperationURLParameter = { serializedName: "nextLink", required: true, type: { - name: "String" - } + name: "String", + }, }, - skipEncoding: true + skipEncoding: true, }; export const subscriptionId: OperationURLParameter = { @@ -67,9 +67,9 @@ export const subscriptionId: OperationURLParameter = { serializedName: "subscriptionId", required: true, type: { - name: "String" - } - } + name: "String", + }, + }, }; export const resourceProviderNamespace: OperationURLParameter = { @@ -78,9 +78,9 @@ export const resourceProviderNamespace: OperationURLParameter = { serializedName: "resourceProviderNamespace", required: true, type: { - name: "String" - } - } + name: "String", + }, + }, }; export const featureName: OperationURLParameter = { @@ -89,9 +89,9 @@ export const featureName: OperationURLParameter = { serializedName: "featureName", required: true, type: { - name: "String" - } - } + name: "String", + }, + }, }; export const accept1: OperationParameter = { @@ -101,9 +101,9 @@ export const accept1: OperationParameter = { isConstant: true, serializedName: "Accept", type: { - name: "String" - } - } + name: "String", + }, + }, }; export const providerNamespace: OperationURLParameter = { @@ -112,9 +112,9 @@ export const providerNamespace: OperationURLParameter = { serializedName: "providerNamespace", required: true, type: { - name: "String" - } - } + name: "String", + }, + }, }; export const contentType: OperationParameter = { @@ -124,12 +124,12 @@ export const contentType: OperationParameter = { isConstant: true, serializedName: "Content-Type", type: { - name: "String" - } - } + name: "String", + }, + }, }; export const subscriptionFeatureRegistrationType: OperationParameter = { parameterPath: ["options", "subscriptionFeatureRegistrationType"], - mapper: SubscriptionFeatureRegistrationMapper + mapper: SubscriptionFeatureRegistrationMapper, }; diff --git a/sdk/features/arm-features/src/operations/features.ts b/sdk/features/arm-features/src/operations/features.ts index 10868cc7160d..4b7c42a472c3 100644 --- a/sdk/features/arm-features/src/operations/features.ts +++ b/sdk/features/arm-features/src/operations/features.ts @@ -28,7 +28,7 @@ import { FeaturesUnregisterOptionalParams, FeaturesUnregisterResponse, FeaturesListAllNextResponse, - FeaturesListNextResponse + FeaturesListNextResponse, } from "../models"; /// @@ -49,7 +49,7 @@ export class FeaturesImpl implements Features { * @param options The options parameters. */ public listAll( - options?: FeaturesListAllOptionalParams + options?: FeaturesListAllOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listAllPagingAll(options); return { @@ -64,13 +64,13 @@ export class FeaturesImpl implements Features { throw new Error("maxPageSize is not supported by this operation."); } return this.listAllPagingPage(options, settings); - } + }, }; } private async *listAllPagingPage( options?: FeaturesListAllOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: FeaturesListAllResponse; let continuationToken = settings?.continuationToken; @@ -91,7 +91,7 @@ export class FeaturesImpl implements Features { } private async *listAllPagingAll( - options?: FeaturesListAllOptionalParams + options?: FeaturesListAllOptionalParams, ): AsyncIterableIterator { for await (const page of this.listAllPagingPage(options)) { yield* page; @@ -106,7 +106,7 @@ export class FeaturesImpl implements Features { */ public list( resourceProviderNamespace: string, - options?: FeaturesListOptionalParams + options?: FeaturesListOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listPagingAll(resourceProviderNamespace, options); return { @@ -123,16 +123,16 @@ export class FeaturesImpl implements Features { return this.listPagingPage( resourceProviderNamespace, options, - settings + settings, ); - } + }, }; } private async *listPagingPage( resourceProviderNamespace: string, options?: FeaturesListOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: FeaturesListResponse; let continuationToken = settings?.continuationToken; @@ -147,7 +147,7 @@ export class FeaturesImpl implements Features { result = await this._listNext( resourceProviderNamespace, continuationToken, - options + options, ); continuationToken = result.nextLink; let page = result.value || []; @@ -158,11 +158,11 @@ export class FeaturesImpl implements Features { private async *listPagingAll( resourceProviderNamespace: string, - options?: FeaturesListOptionalParams + options?: FeaturesListOptionalParams, ): AsyncIterableIterator { for await (const page of this.listPagingPage( resourceProviderNamespace, - options + options, )) { yield* page; } @@ -173,7 +173,7 @@ export class FeaturesImpl implements Features { * @param options The options parameters. */ private _listAll( - options?: FeaturesListAllOptionalParams + options?: FeaturesListAllOptionalParams, ): Promise { return this.client.sendOperationRequest({ options }, listAllOperationSpec); } @@ -186,11 +186,11 @@ export class FeaturesImpl implements Features { */ private _list( resourceProviderNamespace: string, - options?: FeaturesListOptionalParams + options?: FeaturesListOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceProviderNamespace, options }, - listOperationSpec + listOperationSpec, ); } @@ -203,11 +203,11 @@ export class FeaturesImpl implements Features { get( resourceProviderNamespace: string, featureName: string, - options?: FeaturesGetOptionalParams + options?: FeaturesGetOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceProviderNamespace, featureName, options }, - getOperationSpec + getOperationSpec, ); } @@ -220,11 +220,11 @@ export class FeaturesImpl implements Features { register( resourceProviderNamespace: string, featureName: string, - options?: FeaturesRegisterOptionalParams + options?: FeaturesRegisterOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceProviderNamespace, featureName, options }, - registerOperationSpec + registerOperationSpec, ); } @@ -237,11 +237,11 @@ export class FeaturesImpl implements Features { unregister( resourceProviderNamespace: string, featureName: string, - options?: FeaturesUnregisterOptionalParams + options?: FeaturesUnregisterOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceProviderNamespace, featureName, options }, - unregisterOperationSpec + unregisterOperationSpec, ); } @@ -252,11 +252,11 @@ export class FeaturesImpl implements Features { */ private _listAllNext( nextLink: string, - options?: FeaturesListAllNextOptionalParams + options?: FeaturesListAllNextOptionalParams, ): Promise { return this.client.sendOperationRequest( { nextLink, options }, - listAllNextOperationSpec + listAllNextOperationSpec, ); } @@ -269,11 +269,11 @@ export class FeaturesImpl implements Features { private _listNext( resourceProviderNamespace: string, nextLink: string, - options?: FeaturesListNextOptionalParams + options?: FeaturesListNextOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceProviderNamespace, nextLink, options }, - listNextOperationSpec + listNextOperationSpec, ); } } @@ -285,142 +285,136 @@ const listAllOperationSpec: coreClient.OperationSpec = { httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.FeatureOperationsListResult + bodyMapper: Mappers.FeatureOperationsListResult, }, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [Parameters.$host, Parameters.subscriptionId], headerParameters: [Parameters.accept], - serializer + serializer, }; const listOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/providers/Microsoft.Features/providers/{resourceProviderNamespace}/features", + path: "/subscriptions/{subscriptionId}/providers/Microsoft.Features/providers/{resourceProviderNamespace}/features", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.FeatureOperationsListResult + bodyMapper: Mappers.FeatureOperationsListResult, }, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, - Parameters.resourceProviderNamespace + Parameters.resourceProviderNamespace, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const getOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/providers/Microsoft.Features/providers/{resourceProviderNamespace}/features/{featureName}", + path: "/subscriptions/{subscriptionId}/providers/Microsoft.Features/providers/{resourceProviderNamespace}/features/{featureName}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.FeatureResult + bodyMapper: Mappers.FeatureResult, }, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, Parameters.resourceProviderNamespace, - Parameters.featureName + Parameters.featureName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const registerOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/providers/Microsoft.Features/providers/{resourceProviderNamespace}/features/{featureName}/register", + path: "/subscriptions/{subscriptionId}/providers/Microsoft.Features/providers/{resourceProviderNamespace}/features/{featureName}/register", httpMethod: "POST", responses: { 200: { - bodyMapper: Mappers.FeatureResult + bodyMapper: Mappers.FeatureResult, }, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, Parameters.resourceProviderNamespace, - Parameters.featureName + Parameters.featureName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const unregisterOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/providers/Microsoft.Features/providers/{resourceProviderNamespace}/features/{featureName}/unregister", + path: "/subscriptions/{subscriptionId}/providers/Microsoft.Features/providers/{resourceProviderNamespace}/features/{featureName}/unregister", httpMethod: "POST", responses: { 200: { - bodyMapper: Mappers.FeatureResult + bodyMapper: Mappers.FeatureResult, }, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, Parameters.resourceProviderNamespace, - Parameters.featureName + Parameters.featureName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const listAllNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.FeatureOperationsListResult + bodyMapper: Mappers.FeatureOperationsListResult, }, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.nextLink, - Parameters.subscriptionId + Parameters.subscriptionId, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const listNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.FeatureOperationsListResult + bodyMapper: Mappers.FeatureOperationsListResult, }, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.nextLink, Parameters.subscriptionId, - Parameters.resourceProviderNamespace + Parameters.resourceProviderNamespace, ], headerParameters: [Parameters.accept], - serializer + serializer, }; diff --git a/sdk/features/arm-features/src/operations/subscriptionFeatureRegistrations.ts b/sdk/features/arm-features/src/operations/subscriptionFeatureRegistrations.ts index 134cc5bdc4d7..b759ac7b5f44 100644 --- a/sdk/features/arm-features/src/operations/subscriptionFeatureRegistrations.ts +++ b/sdk/features/arm-features/src/operations/subscriptionFeatureRegistrations.ts @@ -27,13 +27,14 @@ import { SubscriptionFeatureRegistrationsCreateOrUpdateResponse, SubscriptionFeatureRegistrationsDeleteOptionalParams, SubscriptionFeatureRegistrationsListBySubscriptionNextResponse, - SubscriptionFeatureRegistrationsListAllBySubscriptionNextResponse + SubscriptionFeatureRegistrationsListAllBySubscriptionNextResponse, } from "../models"; /// /** Class containing SubscriptionFeatureRegistrations operations. */ export class SubscriptionFeatureRegistrationsImpl - implements SubscriptionFeatureRegistrations { + implements SubscriptionFeatureRegistrations +{ private readonly client: FeatureClient; /** @@ -51,7 +52,7 @@ export class SubscriptionFeatureRegistrationsImpl */ public listBySubscription( providerNamespace: string, - options?: SubscriptionFeatureRegistrationsListBySubscriptionOptionalParams + options?: SubscriptionFeatureRegistrationsListBySubscriptionOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listBySubscriptionPagingAll(providerNamespace, options); return { @@ -68,16 +69,16 @@ export class SubscriptionFeatureRegistrationsImpl return this.listBySubscriptionPagingPage( providerNamespace, options, - settings + settings, ); - } + }, }; } private async *listBySubscriptionPagingPage( providerNamespace: string, options?: SubscriptionFeatureRegistrationsListBySubscriptionOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: SubscriptionFeatureRegistrationsListBySubscriptionResponse; let continuationToken = settings?.continuationToken; @@ -92,7 +93,7 @@ export class SubscriptionFeatureRegistrationsImpl result = await this._listBySubscriptionNext( providerNamespace, continuationToken, - options + options, ); continuationToken = result.nextLink; let page = result.value || []; @@ -103,11 +104,11 @@ export class SubscriptionFeatureRegistrationsImpl private async *listBySubscriptionPagingAll( providerNamespace: string, - options?: SubscriptionFeatureRegistrationsListBySubscriptionOptionalParams + options?: SubscriptionFeatureRegistrationsListBySubscriptionOptionalParams, ): AsyncIterableIterator { for await (const page of this.listBySubscriptionPagingPage( providerNamespace, - options + options, )) { yield* page; } @@ -118,7 +119,7 @@ export class SubscriptionFeatureRegistrationsImpl * @param options The options parameters. */ public listAllBySubscription( - options?: SubscriptionFeatureRegistrationsListAllBySubscriptionOptionalParams + options?: SubscriptionFeatureRegistrationsListAllBySubscriptionOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listAllBySubscriptionPagingAll(options); return { @@ -133,13 +134,13 @@ export class SubscriptionFeatureRegistrationsImpl throw new Error("maxPageSize is not supported by this operation."); } return this.listAllBySubscriptionPagingPage(options, settings); - } + }, }; } private async *listAllBySubscriptionPagingPage( options?: SubscriptionFeatureRegistrationsListAllBySubscriptionOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: SubscriptionFeatureRegistrationsListAllBySubscriptionResponse; let continuationToken = settings?.continuationToken; @@ -153,7 +154,7 @@ export class SubscriptionFeatureRegistrationsImpl while (continuationToken) { result = await this._listAllBySubscriptionNext( continuationToken, - options + options, ); continuationToken = result.nextLink; let page = result.value || []; @@ -163,7 +164,7 @@ export class SubscriptionFeatureRegistrationsImpl } private async *listAllBySubscriptionPagingAll( - options?: SubscriptionFeatureRegistrationsListAllBySubscriptionOptionalParams + options?: SubscriptionFeatureRegistrationsListAllBySubscriptionOptionalParams, ): AsyncIterableIterator { for await (const page of this.listAllBySubscriptionPagingPage(options)) { yield* page; @@ -179,11 +180,11 @@ export class SubscriptionFeatureRegistrationsImpl get( providerNamespace: string, featureName: string, - options?: SubscriptionFeatureRegistrationsGetOptionalParams + options?: SubscriptionFeatureRegistrationsGetOptionalParams, ): Promise { return this.client.sendOperationRequest( { providerNamespace, featureName, options }, - getOperationSpec + getOperationSpec, ); } @@ -196,11 +197,11 @@ export class SubscriptionFeatureRegistrationsImpl createOrUpdate( providerNamespace: string, featureName: string, - options?: SubscriptionFeatureRegistrationsCreateOrUpdateOptionalParams + options?: SubscriptionFeatureRegistrationsCreateOrUpdateOptionalParams, ): Promise { return this.client.sendOperationRequest( { providerNamespace, featureName, options }, - createOrUpdateOperationSpec + createOrUpdateOperationSpec, ); } @@ -213,11 +214,11 @@ export class SubscriptionFeatureRegistrationsImpl delete( providerNamespace: string, featureName: string, - options?: SubscriptionFeatureRegistrationsDeleteOptionalParams + options?: SubscriptionFeatureRegistrationsDeleteOptionalParams, ): Promise { return this.client.sendOperationRequest( { providerNamespace, featureName, options }, - deleteOperationSpec + deleteOperationSpec, ); } @@ -228,11 +229,11 @@ export class SubscriptionFeatureRegistrationsImpl */ private _listBySubscription( providerNamespace: string, - options?: SubscriptionFeatureRegistrationsListBySubscriptionOptionalParams + options?: SubscriptionFeatureRegistrationsListBySubscriptionOptionalParams, ): Promise { return this.client.sendOperationRequest( { providerNamespace, options }, - listBySubscriptionOperationSpec + listBySubscriptionOperationSpec, ); } @@ -241,11 +242,11 @@ export class SubscriptionFeatureRegistrationsImpl * @param options The options parameters. */ private _listAllBySubscription( - options?: SubscriptionFeatureRegistrationsListAllBySubscriptionOptionalParams + options?: SubscriptionFeatureRegistrationsListAllBySubscriptionOptionalParams, ): Promise { return this.client.sendOperationRequest( { options }, - listAllBySubscriptionOperationSpec + listAllBySubscriptionOperationSpec, ); } @@ -258,11 +259,11 @@ export class SubscriptionFeatureRegistrationsImpl private _listBySubscriptionNext( providerNamespace: string, nextLink: string, - options?: SubscriptionFeatureRegistrationsListBySubscriptionNextOptionalParams + options?: SubscriptionFeatureRegistrationsListBySubscriptionNextOptionalParams, ): Promise { return this.client.sendOperationRequest( { providerNamespace, nextLink, options }, - listBySubscriptionNextOperationSpec + listBySubscriptionNextOperationSpec, ); } @@ -273,13 +274,11 @@ export class SubscriptionFeatureRegistrationsImpl */ private _listAllBySubscriptionNext( nextLink: string, - options?: SubscriptionFeatureRegistrationsListAllBySubscriptionNextOptionalParams - ): Promise< - SubscriptionFeatureRegistrationsListAllBySubscriptionNextResponse - > { + options?: SubscriptionFeatureRegistrationsListAllBySubscriptionNextOptionalParams, + ): Promise { return this.client.sendOperationRequest( { nextLink, options }, - listAllBySubscriptionNextOperationSpec + listAllBySubscriptionNextOperationSpec, ); } } @@ -287,38 +286,36 @@ export class SubscriptionFeatureRegistrationsImpl const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); const getOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/providers/Microsoft.Features/featureProviders/{providerNamespace}/subscriptionFeatureRegistrations/{featureName}", + path: "/subscriptions/{subscriptionId}/providers/Microsoft.Features/featureProviders/{providerNamespace}/subscriptionFeatureRegistrations/{featureName}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.SubscriptionFeatureRegistration + bodyMapper: Mappers.SubscriptionFeatureRegistration, }, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, Parameters.featureName, - Parameters.providerNamespace + Parameters.providerNamespace, ], headerParameters: [Parameters.accept1], - serializer + serializer, }; const createOrUpdateOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/providers/Microsoft.Features/featureProviders/{providerNamespace}/subscriptionFeatureRegistrations/{featureName}", + path: "/subscriptions/{subscriptionId}/providers/Microsoft.Features/featureProviders/{providerNamespace}/subscriptionFeatureRegistrations/{featureName}", httpMethod: "PUT", responses: { 200: { - bodyMapper: Mappers.SubscriptionFeatureRegistration + bodyMapper: Mappers.SubscriptionFeatureRegistration, }, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, requestBody: Parameters.subscriptionFeatureRegistrationType, queryParameters: [Parameters.apiVersion], @@ -326,109 +323,104 @@ const createOrUpdateOperationSpec: coreClient.OperationSpec = { Parameters.$host, Parameters.subscriptionId, Parameters.featureName, - Parameters.providerNamespace + Parameters.providerNamespace, ], headerParameters: [Parameters.accept1, Parameters.contentType], mediaType: "json", - serializer + serializer, }; const deleteOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/providers/Microsoft.Features/featureProviders/{providerNamespace}/subscriptionFeatureRegistrations/{featureName}", + path: "/subscriptions/{subscriptionId}/providers/Microsoft.Features/featureProviders/{providerNamespace}/subscriptionFeatureRegistrations/{featureName}", httpMethod: "DELETE", responses: { 200: {}, 204: {}, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, Parameters.featureName, - Parameters.providerNamespace + Parameters.providerNamespace, ], headerParameters: [Parameters.accept1], - serializer + serializer, }; const listBySubscriptionOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/providers/Microsoft.Features/featureProviders/{providerNamespace}/subscriptionFeatureRegistrations", + path: "/subscriptions/{subscriptionId}/providers/Microsoft.Features/featureProviders/{providerNamespace}/subscriptionFeatureRegistrations", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.SubscriptionFeatureRegistrationList + bodyMapper: Mappers.SubscriptionFeatureRegistrationList, }, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, - Parameters.providerNamespace + Parameters.providerNamespace, ], headerParameters: [Parameters.accept1], - serializer + serializer, }; const listAllBySubscriptionOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/providers/Microsoft.Features/subscriptionFeatureRegistrations", + path: "/subscriptions/{subscriptionId}/providers/Microsoft.Features/subscriptionFeatureRegistrations", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.SubscriptionFeatureRegistrationList + bodyMapper: Mappers.SubscriptionFeatureRegistrationList, }, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [Parameters.$host, Parameters.subscriptionId], headerParameters: [Parameters.accept1], - serializer + serializer, }; const listBySubscriptionNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.SubscriptionFeatureRegistrationList + bodyMapper: Mappers.SubscriptionFeatureRegistrationList, }, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.nextLink, Parameters.subscriptionId, - Parameters.providerNamespace + Parameters.providerNamespace, ], headerParameters: [Parameters.accept1], - serializer + serializer, }; const listAllBySubscriptionNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.SubscriptionFeatureRegistrationList + bodyMapper: Mappers.SubscriptionFeatureRegistrationList, }, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.nextLink, - Parameters.subscriptionId + Parameters.subscriptionId, ], headerParameters: [Parameters.accept1], - serializer + serializer, }; diff --git a/sdk/features/arm-features/src/operationsInterfaces/features.ts b/sdk/features/arm-features/src/operationsInterfaces/features.ts index 7a3cc838021e..178c08aa76b2 100644 --- a/sdk/features/arm-features/src/operationsInterfaces/features.ts +++ b/sdk/features/arm-features/src/operationsInterfaces/features.ts @@ -16,7 +16,7 @@ import { FeaturesRegisterOptionalParams, FeaturesRegisterResponse, FeaturesUnregisterOptionalParams, - FeaturesUnregisterResponse + FeaturesUnregisterResponse, } from "../models"; /// @@ -27,7 +27,7 @@ export interface Features { * @param options The options parameters. */ listAll( - options?: FeaturesListAllOptionalParams + options?: FeaturesListAllOptionalParams, ): PagedAsyncIterableIterator; /** * Gets all the preview features in a provider namespace that are available through AFEC for the @@ -37,7 +37,7 @@ export interface Features { */ list( resourceProviderNamespace: string, - options?: FeaturesListOptionalParams + options?: FeaturesListOptionalParams, ): PagedAsyncIterableIterator; /** * Gets the preview feature with the specified name. @@ -48,7 +48,7 @@ export interface Features { get( resourceProviderNamespace: string, featureName: string, - options?: FeaturesGetOptionalParams + options?: FeaturesGetOptionalParams, ): Promise; /** * Registers the preview feature for the subscription. @@ -59,7 +59,7 @@ export interface Features { register( resourceProviderNamespace: string, featureName: string, - options?: FeaturesRegisterOptionalParams + options?: FeaturesRegisterOptionalParams, ): Promise; /** * Unregisters the preview feature for the subscription. @@ -70,6 +70,6 @@ export interface Features { unregister( resourceProviderNamespace: string, featureName: string, - options?: FeaturesUnregisterOptionalParams + options?: FeaturesUnregisterOptionalParams, ): Promise; } diff --git a/sdk/features/arm-features/src/operationsInterfaces/subscriptionFeatureRegistrations.ts b/sdk/features/arm-features/src/operationsInterfaces/subscriptionFeatureRegistrations.ts index ec8a9085f923..456a5e0a4b5d 100644 --- a/sdk/features/arm-features/src/operationsInterfaces/subscriptionFeatureRegistrations.ts +++ b/sdk/features/arm-features/src/operationsInterfaces/subscriptionFeatureRegistrations.ts @@ -15,7 +15,7 @@ import { SubscriptionFeatureRegistrationsGetResponse, SubscriptionFeatureRegistrationsCreateOrUpdateOptionalParams, SubscriptionFeatureRegistrationsCreateOrUpdateResponse, - SubscriptionFeatureRegistrationsDeleteOptionalParams + SubscriptionFeatureRegistrationsDeleteOptionalParams, } from "../models"; /// @@ -28,14 +28,14 @@ export interface SubscriptionFeatureRegistrations { */ listBySubscription( providerNamespace: string, - options?: SubscriptionFeatureRegistrationsListBySubscriptionOptionalParams + options?: SubscriptionFeatureRegistrationsListBySubscriptionOptionalParams, ): PagedAsyncIterableIterator; /** * Returns subscription feature registrations for given subscription. * @param options The options parameters. */ listAllBySubscription( - options?: SubscriptionFeatureRegistrationsListAllBySubscriptionOptionalParams + options?: SubscriptionFeatureRegistrationsListAllBySubscriptionOptionalParams, ): PagedAsyncIterableIterator; /** * Returns a feature registration @@ -46,7 +46,7 @@ export interface SubscriptionFeatureRegistrations { get( providerNamespace: string, featureName: string, - options?: SubscriptionFeatureRegistrationsGetOptionalParams + options?: SubscriptionFeatureRegistrationsGetOptionalParams, ): Promise; /** * Create or update a feature registration. @@ -57,7 +57,7 @@ export interface SubscriptionFeatureRegistrations { createOrUpdate( providerNamespace: string, featureName: string, - options?: SubscriptionFeatureRegistrationsCreateOrUpdateOptionalParams + options?: SubscriptionFeatureRegistrationsCreateOrUpdateOptionalParams, ): Promise; /** * Deletes a feature registration @@ -68,6 +68,6 @@ export interface SubscriptionFeatureRegistrations { delete( providerNamespace: string, featureName: string, - options?: SubscriptionFeatureRegistrationsDeleteOptionalParams + options?: SubscriptionFeatureRegistrationsDeleteOptionalParams, ): Promise; } diff --git a/sdk/features/arm-features/src/pagingHelper.ts b/sdk/features/arm-features/src/pagingHelper.ts index d85fc13bce1e..205cccc26592 100644 --- a/sdk/features/arm-features/src/pagingHelper.ts +++ b/sdk/features/arm-features/src/pagingHelper.ts @@ -13,11 +13,11 @@ export interface PageInfo { const pageMap = new WeakMap(); /** - * Given a result page from a pageable operation, returns a - * continuation token that can be used to begin paging from + * Given the last `.value` produced by the `byPage` iterator, + * returns a continuation token that can be used to begin paging from * that point later. - * @param page A result object from calling .byPage() on a paged operation. - * @returns The continuation token that can be passed into byPage(). + * @param page An object from accessing `value` on the IteratorResult from a `byPage` iterator. + * @returns The continuation token that can be passed into byPage() during future calls. */ export function getContinuationToken(page: unknown): string | undefined { if (typeof page !== "object" || page === null) { @@ -28,7 +28,7 @@ export function getContinuationToken(page: unknown): string | undefined { export function setContinuationToken( page: unknown, - continuationToken: string | undefined + continuationToken: string | undefined, ): void { if (typeof page !== "object" || page === null || !continuationToken) { return; diff --git a/sdk/features/arm-features/test/sampleTest.ts b/sdk/features/arm-features/test/sampleTest.ts new file mode 100644 index 000000000000..d64be981b694 --- /dev/null +++ b/sdk/features/arm-features/test/sampleTest.ts @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +import { + Recorder, + RecorderStartOptions, + env, +} from "@azure-tools/test-recorder"; +import { assert } from "chai"; +import { Context } from "mocha"; + +const replaceableVariables: Record = { + AZURE_CLIENT_ID: "azure_client_id", + AZURE_CLIENT_SECRET: "azure_client_secret", + AZURE_TENANT_ID: "88888888-8888-8888-8888-888888888888", + SUBSCRIPTION_ID: "azure_subscription_id", +}; + +const recorderOptions: RecorderStartOptions = { + envSetupForPlayback: replaceableVariables, +}; + +describe("My test", () => { + let recorder: Recorder; + + beforeEach(async function (this: Context) { + recorder = new Recorder(this.currentTest); + await recorder.start(recorderOptions); + }); + + afterEach(async function () { + await recorder.stop(); + }); + + it("sample test", async function () { + console.log("Hi, I'm a test!"); + }); +}); diff --git a/sdk/features/arm-features/tsconfig.json b/sdk/features/arm-features/tsconfig.json index 7acef300dd3d..69cd824d326e 100644 --- a/sdk/features/arm-features/tsconfig.json +++ b/sdk/features/arm-features/tsconfig.json @@ -15,17 +15,12 @@ ], "declaration": true, "outDir": "./dist-esm", - "importHelpers": true, - "paths": { - "@azure/arm-features": [ - "./src/index" - ] - } + "importHelpers": true }, "include": [ "./src/**/*.ts", "./test/**/*.ts", - "samples-dev/**/*.ts" + "./test/**/*.ts" ], "exclude": [ "node_modules" diff --git a/sdk/links/arm-links/CHANGELOG.md b/sdk/links/arm-links/CHANGELOG.md index e72b11f65d31..fb15d79a0cf5 100644 --- a/sdk/links/arm-links/CHANGELOG.md +++ b/sdk/links/arm-links/CHANGELOG.md @@ -1,18 +1,15 @@ # Release History - -## 2.0.2 (2022-11-22) - -### Features Added - --  Exposes `getContinuationToken` helper function to extract continuation token - -### Bugs Fixed -  -- A series of small bug fixs relevant to authentication and apiVersion policy - + +## 3.0.0 (2024-11-01) + +### Breaking Changes + + - Class ManagementLinkClient has a new signature + - Interface ResourceLinksListAtSubscriptionNextOptionalParams no longer has parameter filter + ## 2.0.1 (2022-04-18) -### Features Added +**features** - Bug fix @@ -24,4 +21,4 @@ To understand the detail of the change, please refer to [Changelog](https://aka. To migrate the existing applications to the latest version, please refer to [Migration Guide](https://aka.ms/js-track2-migration-guide). -To learn more, please refer to our documentation [Quick Start](https://aka.ms/azsdk/js/mgmt/quickstart ). +To learn more, please refer to our documentation [Quick Start](https://aka.ms/azsdk/js/mgmt/quickstart). diff --git a/sdk/links/arm-links/LICENSE b/sdk/links/arm-links/LICENSE index 5d1d36e0af80..7d5934740965 100644 --- a/sdk/links/arm-links/LICENSE +++ b/sdk/links/arm-links/LICENSE @@ -1,6 +1,6 @@ The MIT License (MIT) -Copyright (c) 2022 Microsoft +Copyright (c) 2024 Microsoft Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal diff --git a/sdk/links/arm-links/_meta.json b/sdk/links/arm-links/_meta.json index 4b98b8203a1f..28591836c37e 100644 --- a/sdk/links/arm-links/_meta.json +++ b/sdk/links/arm-links/_meta.json @@ -1,8 +1,8 @@ { - "commit": "a42f1b58607091c4f255ead152a8ef323fa0b280", - "readme": "specification\\resources\\resource-manager\\readme.md", - "autorest_command": "autorest --version=3.8.4 --typescript --modelerfour.lenient-model-deduplication --azure-arm --head-as-boolean=true --license-header=MICROSOFT_MIT_NO_VERSION --generate-test --typescript-sdks-folder=D:\\Git\\azure-sdk-for-js ..\\azure-rest-api-specs\\specification\\resources\\resource-manager\\readme.md --use=@autorest/typescript@6.0.0-rc.3.20221108.1 --generate-sample=true", + "commit": "5342edb61d78cec6e07b17a6cd8f7749c6697272", + "readme": "specification/resources/resource-manager/readme.md", + "autorest_command": "autorest --version=3.9.7 --typescript --modelerfour.lenient-model-deduplication --azure-arm --head-as-boolean=true --license-header=MICROSOFT_MIT_NO_VERSION --generate-test --typescript-sdks-folder=/mnt/vss/_work/1/s/azure-sdk-for-js ../azure-rest-api-specs/specification/resources/resource-manager/readme.md --use=@autorest/typescript@^6.0.12", "repository_url": "https://github.com/Azure/azure-rest-api-specs.git", - "release_tool": "@azure-tools/js-sdk-release-tools@2.4.2", - "use": "@autorest/typescript@6.0.0-rc.3.20221108.1" + "release_tool": "@azure-tools/js-sdk-release-tools@2.7.14", + "use": "@autorest/typescript@^6.0.12" } \ No newline at end of file diff --git a/sdk/links/arm-links/package.json b/sdk/links/arm-links/package.json index b8d4b3b708ad..4184cae69c70 100644 --- a/sdk/links/arm-links/package.json +++ b/sdk/links/arm-links/package.json @@ -3,15 +3,15 @@ "sdk-type": "mgmt", "author": "Microsoft Corporation", "description": "A generated SDK for ManagementLinkClient.", - "version": "2.0.2", + "version": "3.0.0", "engines": { "node": ">=18.0.0" }, "dependencies": { - "@azure/core-auth": "^1.3.0", - "@azure/core-client": "^1.6.1", "@azure/core-paging": "^1.2.0", - "@azure/core-rest-pipeline": "^1.8.0", + "@azure/core-client": "^1.7.0", + "@azure/core-auth": "^1.6.0", + "@azure/core-rest-pipeline": "^1.14.0", "tslib": "^2.2.0" }, "keywords": [ @@ -26,21 +26,25 @@ "module": "./dist-esm/src/index.js", "types": "./types/arm-links.d.ts", "devDependencies": { - "@azure-tools/test-credential": "^1.0.0", - "@azure-tools/test-recorder": "^3.0.0", - "@azure/arm-resources": "^5.0.0", + "@microsoft/api-extractor": "^7.31.1", + "mkdirp": "^3.0.1", + "typescript": "~5.5.3", + "uglify-js": "^3.4.9", + "rimraf": "^5.0.0", + "dotenv": "^16.0.0", "@azure/dev-tool": "^1.0.0", - "@azure/identity": "^4.0.1", - "@types/chai": "^4.2.8", + "@azure/identity": "^4.2.1", + "@azure-tools/test-recorder": "^3.0.0", + "@azure-tools/test-credential": "^1.1.0", + "mocha": "^10.0.0", "@types/mocha": "^10.0.0", - "@types/node": "^18.0.0", + "tsx": "^4.7.1", + "@types/chai": "^4.2.8", "chai": "^4.2.0", "cross-env": "^7.0.2", - "mocha": "^10.0.0", - "ts-node": "^10.0.0", - "typescript": "~5.6.2" + "@types/node": "^18.0.0", + "ts-node": "^10.0.0" }, - "homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/links/arm-links", "repository": { "type": "git", "url": "https://github.com/Azure/azure-sdk-for-js.git" @@ -66,30 +70,29 @@ "types/*" ], "scripts": { - "build": "npm run clean && tsc && dev-tool run bundle && npm run minify && dev-tool run vendored mkdirp ./review && npm run extract-api", - "build:browser": "echo skipped", + "build": "npm run clean && tsc && dev-tool run bundle && npm run minify && mkdirp ./review && npm run extract-api", + "minify": "uglifyjs -c -m --comments --source-map \"content='./dist/index.js.map'\" -o ./dist/index.min.js ./dist/index.js", + "prepack": "npm run build", + "pack": "npm pack 2>&1", + "extract-api": "dev-tool run extract-api", + "lint": "echo skipped", + "clean": "rimraf --glob dist dist-browser dist-esm test-dist temp types *.tgz *.log", "build:node": "echo skipped", - "build:samples": "echo skipped.", + "build:browser": "echo skipped", "build:test": "echo skipped", + "build:samples": "echo skipped.", "check-format": "echo skipped", - "clean": "dev-tool run vendored rimraf --glob dist dist-browser dist-esm test-dist temp types *.tgz *.log", "execute:samples": "echo skipped", - "extract-api": "dev-tool run extract-api", "format": "echo skipped", - "integration-test": "npm run integration-test:node && npm run integration-test:browser", - "integration-test:browser": "echo skipped", - "integration-test:node": "dev-tool run test:node-ts-input -- --timeout 1200000 'test/*.ts'", - "lint": "echo skipped", - "minify": "dev-tool run vendored uglifyjs -c -m --comments --source-map \"content='./dist/index.js.map'\" -o ./dist/index.min.js ./dist/index.js", - "pack": "npm pack 2>&1", - "prepack": "npm run build", "test": "npm run integration-test", - "test:browser": "echo skipped", "test:node": "echo skipped", + "test:browser": "echo skipped", "unit-test": "npm run unit-test:node && npm run unit-test:browser", - "unit-test:browser": "echo skipped", "unit-test:node": "cross-env TEST_MODE=playback npm run integration-test:node", - "update-snippets": "echo skipped" + "unit-test:browser": "echo skipped", + "integration-test": "npm run integration-test:node && npm run integration-test:browser", + "integration-test:node": "dev-tool run test:node-ts-input -- --timeout 1200000 'test/*.ts'", + "integration-test:browser": "echo skipped" }, "sideEffects": false, "//metadata": { @@ -100,5 +103,6 @@ } ] }, - "autoPublish": true -} + "autoPublish": true, + "homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/links/arm-links" +} \ No newline at end of file diff --git a/sdk/links/arm-links/review/arm-links.api.md b/sdk/links/arm-links/review/arm-links.api.md index 0bbbaff74a79..a021f89e39ad 100644 --- a/sdk/links/arm-links/review/arm-links.api.md +++ b/sdk/links/arm-links/review/arm-links.api.md @@ -16,6 +16,7 @@ export class ManagementLinkClient extends coreClient.ServiceClient { // (undocumented) $host: string; constructor(credentials: coreAuth.TokenCredential, subscriptionId: string, options?: ManagementLinkClientOptionalParams); + constructor(credentials: coreAuth.TokenCredential, options?: ManagementLinkClientOptionalParams); // (undocumented) apiVersion: string; // (undocumented) @@ -23,7 +24,7 @@ export class ManagementLinkClient extends coreClient.ServiceClient { // (undocumented) resourceLinks: ResourceLinks; // (undocumented) - subscriptionId: string; + subscriptionId?: string; } // @public @@ -141,7 +142,6 @@ export type ResourceLinksListAtSourceScopeResponse = ResourceLinkResult; // @public export interface ResourceLinksListAtSubscriptionNextOptionalParams extends coreClient.OperationOptions { - filter?: string; } // @public diff --git a/sdk/links/arm-links/src/managementLinkClient.ts b/sdk/links/arm-links/src/managementLinkClient.ts index ba642926cc86..f590a11f9014 100644 --- a/sdk/links/arm-links/src/managementLinkClient.ts +++ b/sdk/links/arm-links/src/managementLinkClient.ts @@ -11,7 +11,7 @@ import * as coreRestPipeline from "@azure/core-rest-pipeline"; import { PipelineRequest, PipelineResponse, - SendRequest + SendRequest, } from "@azure/core-rest-pipeline"; import * as coreAuth from "@azure/core-auth"; import { OperationsImpl, ResourceLinksImpl } from "./operations"; @@ -21,7 +21,7 @@ import { ManagementLinkClientOptionalParams } from "./models"; export class ManagementLinkClient extends coreClient.ServiceClient { $host: string; apiVersion: string; - subscriptionId: string; + subscriptionId?: string; /** * Initializes a new instance of the ManagementLinkClient class. @@ -32,13 +32,27 @@ export class ManagementLinkClient extends coreClient.ServiceClient { constructor( credentials: coreAuth.TokenCredential, subscriptionId: string, - options?: ManagementLinkClientOptionalParams + options?: ManagementLinkClientOptionalParams, + ); + constructor( + credentials: coreAuth.TokenCredential, + options?: ManagementLinkClientOptionalParams, + ); + constructor( + credentials: coreAuth.TokenCredential, + subscriptionIdOrOptions?: ManagementLinkClientOptionalParams | string, + options?: ManagementLinkClientOptionalParams, ) { if (credentials === undefined) { throw new Error("'credentials' cannot be null"); } - if (subscriptionId === undefined) { - throw new Error("'subscriptionId' cannot be null"); + + let subscriptionId: string | undefined; + + if (typeof subscriptionIdOrOptions === "string") { + subscriptionId = subscriptionIdOrOptions; + } else if (typeof subscriptionIdOrOptions === "object") { + options = subscriptionIdOrOptions; } // Initializing default values for options @@ -47,10 +61,10 @@ export class ManagementLinkClient extends coreClient.ServiceClient { } const defaults: ManagementLinkClientOptionalParams = { requestContentType: "application/json; charset=utf-8", - credential: credentials + credential: credentials, }; - const packageDetails = `azsdk-js-arm-links/2.0.2`; + const packageDetails = `azsdk-js-arm-links/3.0.0`; const userAgentPrefix = options.userAgentOptions && options.userAgentOptions.userAgentPrefix ? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}` @@ -60,20 +74,21 @@ export class ManagementLinkClient extends coreClient.ServiceClient { ...defaults, ...options, userAgentOptions: { - userAgentPrefix + userAgentPrefix, }, endpoint: - options.endpoint ?? options.baseUri ?? "https://management.azure.com" + options.endpoint ?? options.baseUri ?? "https://management.azure.com", }; super(optionsWithDefaults); let bearerTokenAuthenticationPolicyFound: boolean = false; if (options?.pipeline && options.pipeline.getOrderedPolicies().length > 0) { - const pipelinePolicies: coreRestPipeline.PipelinePolicy[] = options.pipeline.getOrderedPolicies(); + const pipelinePolicies: coreRestPipeline.PipelinePolicy[] = + options.pipeline.getOrderedPolicies(); bearerTokenAuthenticationPolicyFound = pipelinePolicies.some( (pipelinePolicy) => pipelinePolicy.name === - coreRestPipeline.bearerTokenAuthenticationPolicyName + coreRestPipeline.bearerTokenAuthenticationPolicyName, ); } if ( @@ -83,7 +98,7 @@ export class ManagementLinkClient extends coreClient.ServiceClient { !bearerTokenAuthenticationPolicyFound ) { this.pipeline.removePolicy({ - name: coreRestPipeline.bearerTokenAuthenticationPolicyName + name: coreRestPipeline.bearerTokenAuthenticationPolicyName, }); this.pipeline.addPolicy( coreRestPipeline.bearerTokenAuthenticationPolicy({ @@ -93,9 +108,9 @@ export class ManagementLinkClient extends coreClient.ServiceClient { `${optionsWithDefaults.endpoint}/.default`, challengeCallbacks: { authorizeRequestOnChallenge: - coreClient.authorizeRequestOnClaimChallenge - } - }) + coreClient.authorizeRequestOnClaimChallenge, + }, + }), ); } // Parameter assignments @@ -118,7 +133,7 @@ export class ManagementLinkClient extends coreClient.ServiceClient { name: "CustomApiVersionPolicy", async sendRequest( request: PipelineRequest, - next: SendRequest + next: SendRequest, ): Promise { const param = request.url.split("?"); if (param.length > 1) { @@ -132,7 +147,7 @@ export class ManagementLinkClient extends coreClient.ServiceClient { request.url = param[0] + "?" + newParams.join("&"); } return next(request); - } + }, }; this.pipeline.addPolicy(apiVersionPolicy); } diff --git a/sdk/links/arm-links/src/models/index.ts b/sdk/links/arm-links/src/models/index.ts index 1a730f96d3e2..1788384b5787 100644 --- a/sdk/links/arm-links/src/models/index.ts +++ b/sdk/links/arm-links/src/models/index.ts @@ -138,10 +138,7 @@ export type ResourceLinksListAtSourceScopeResponse = ResourceLinkResult; /** Optional parameters. */ export interface ResourceLinksListAtSubscriptionNextOptionalParams - extends coreClient.OperationOptions { - /** The filter to apply on the list resource links operation. The supported filter for list resource links is targetId. For example, $filter=targetId eq {value} */ - filter?: string; -} + extends coreClient.OperationOptions {} /** Contains response data for the listAtSubscriptionNext operation. */ export type ResourceLinksListAtSubscriptionNextResponse = ResourceLinkResult; diff --git a/sdk/links/arm-links/src/models/mappers.ts b/sdk/links/arm-links/src/models/mappers.ts index 6dc8e79de789..36b97b7c05e8 100644 --- a/sdk/links/arm-links/src/models/mappers.ts +++ b/sdk/links/arm-links/src/models/mappers.ts @@ -20,19 +20,19 @@ export const OperationListResult: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "Operation" - } - } - } + className: "Operation", + }, + }, + }, }, nextLink: { serializedName: "nextLink", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const Operation: coreClient.CompositeMapper = { @@ -43,18 +43,18 @@ export const Operation: coreClient.CompositeMapper = { name: { serializedName: "name", type: { - name: "String" - } + name: "String", + }, }, display: { serializedName: "display", type: { name: "Composite", - className: "OperationDisplay" - } - } - } - } + className: "OperationDisplay", + }, + }, + }, + }, }; export const OperationDisplay: coreClient.CompositeMapper = { @@ -65,29 +65,29 @@ export const OperationDisplay: coreClient.CompositeMapper = { provider: { serializedName: "provider", type: { - name: "String" - } + name: "String", + }, }, resource: { serializedName: "resource", type: { - name: "String" - } + name: "String", + }, }, operation: { serializedName: "operation", type: { - name: "String" - } + name: "String", + }, }, description: { serializedName: "description", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const ResourceLink: coreClient.CompositeMapper = { @@ -99,33 +99,33 @@ export const ResourceLink: coreClient.CompositeMapper = { serializedName: "id", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, name: { serializedName: "name", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, type: { serializedName: "type", readOnly: true, type: { name: "Dictionary", - value: { type: { name: "any" } } - } + value: { type: { name: "any" } }, + }, }, properties: { serializedName: "properties", type: { name: "Composite", - className: "ResourceLinkProperties" - } - } - } - } + className: "ResourceLinkProperties", + }, + }, + }, + }, }; export const ResourceLinkProperties: coreClient.CompositeMapper = { @@ -137,24 +137,24 @@ export const ResourceLinkProperties: coreClient.CompositeMapper = { serializedName: "sourceId", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, targetId: { serializedName: "targetId", required: true, type: { - name: "String" - } + name: "String", + }, }, notes: { serializedName: "notes", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const ResourceLinkResult: coreClient.CompositeMapper = { @@ -170,20 +170,20 @@ export const ResourceLinkResult: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "ResourceLink" - } - } - } + className: "ResourceLink", + }, + }, + }, }, nextLink: { serializedName: "nextLink", readOnly: true, type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const ResourceLinkFilter: coreClient.CompositeMapper = { @@ -195,9 +195,9 @@ export const ResourceLinkFilter: coreClient.CompositeMapper = { serializedName: "targetId", required: true, type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; diff --git a/sdk/links/arm-links/src/models/parameters.ts b/sdk/links/arm-links/src/models/parameters.ts index 20df95fc66e0..44c21908922b 100644 --- a/sdk/links/arm-links/src/models/parameters.ts +++ b/sdk/links/arm-links/src/models/parameters.ts @@ -9,7 +9,7 @@ import { OperationParameter, OperationURLParameter, - OperationQueryParameter + OperationQueryParameter, } from "@azure/core-client"; import { ResourceLink as ResourceLinkMapper } from "../models/mappers"; @@ -20,9 +20,9 @@ export const accept: OperationParameter = { isConstant: true, serializedName: "Accept", type: { - name: "String" - } - } + name: "String", + }, + }, }; export const $host: OperationURLParameter = { @@ -31,10 +31,10 @@ export const $host: OperationURLParameter = { serializedName: "$host", required: true, type: { - name: "String" - } + name: "String", + }, }, - skipEncoding: true + skipEncoding: true, }; export const apiVersion: OperationQueryParameter = { @@ -44,9 +44,9 @@ export const apiVersion: OperationQueryParameter = { isConstant: true, serializedName: "api-version", type: { - name: "String" - } - } + name: "String", + }, + }, }; export const nextLink: OperationURLParameter = { @@ -55,10 +55,10 @@ export const nextLink: OperationURLParameter = { serializedName: "nextLink", required: true, type: { - name: "String" - } + name: "String", + }, }, - skipEncoding: true + skipEncoding: true, }; export const linkId: OperationURLParameter = { @@ -67,10 +67,10 @@ export const linkId: OperationURLParameter = { serializedName: "linkId", required: true, type: { - name: "String" - } + name: "String", + }, }, - skipEncoding: true + skipEncoding: true, }; export const contentType: OperationParameter = { @@ -80,14 +80,14 @@ export const contentType: OperationParameter = { isConstant: true, serializedName: "Content-Type", type: { - name: "String" - } - } + name: "String", + }, + }, }; export const parameters: OperationParameter = { parameterPath: "parameters", - mapper: ResourceLinkMapper + mapper: ResourceLinkMapper, }; export const filter: OperationQueryParameter = { @@ -95,9 +95,9 @@ export const filter: OperationQueryParameter = { mapper: { serializedName: "$filter", type: { - name: "String" - } - } + name: "String", + }, + }, }; export const subscriptionId: OperationURLParameter = { @@ -106,9 +106,9 @@ export const subscriptionId: OperationURLParameter = { serializedName: "subscriptionId", required: true, type: { - name: "String" - } - } + name: "String", + }, + }, }; export const scope: OperationURLParameter = { @@ -117,10 +117,10 @@ export const scope: OperationURLParameter = { serializedName: "scope", required: true, type: { - name: "String" - } + name: "String", + }, }, - skipEncoding: true + skipEncoding: true, }; export const filter1: OperationQueryParameter = { @@ -130,7 +130,7 @@ export const filter1: OperationQueryParameter = { isConstant: true, serializedName: "$filter", type: { - name: "String" - } - } + name: "String", + }, + }, }; diff --git a/sdk/links/arm-links/src/operations/operations.ts b/sdk/links/arm-links/src/operations/operations.ts index 26969f581fd6..6598589debb1 100644 --- a/sdk/links/arm-links/src/operations/operations.ts +++ b/sdk/links/arm-links/src/operations/operations.ts @@ -18,7 +18,7 @@ import { OperationsListNextOptionalParams, OperationsListOptionalParams, OperationsListResponse, - OperationsListNextResponse + OperationsListNextResponse, } from "../models"; /// @@ -39,7 +39,7 @@ export class OperationsImpl implements Operations { * @param options The options parameters. */ public list( - options?: OperationsListOptionalParams + options?: OperationsListOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listPagingAll(options); return { @@ -54,13 +54,13 @@ export class OperationsImpl implements Operations { throw new Error("maxPageSize is not supported by this operation."); } return this.listPagingPage(options, settings); - } + }, }; } private async *listPagingPage( options?: OperationsListOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: OperationsListResponse; let continuationToken = settings?.continuationToken; @@ -81,7 +81,7 @@ export class OperationsImpl implements Operations { } private async *listPagingAll( - options?: OperationsListOptionalParams + options?: OperationsListOptionalParams, ): AsyncIterableIterator { for await (const page of this.listPagingPage(options)) { yield* page; @@ -93,7 +93,7 @@ export class OperationsImpl implements Operations { * @param options The options parameters. */ private _list( - options?: OperationsListOptionalParams + options?: OperationsListOptionalParams, ): Promise { return this.client.sendOperationRequest({ options }, listOperationSpec); } @@ -105,11 +105,11 @@ export class OperationsImpl implements Operations { */ private _listNext( nextLink: string, - options?: OperationsListNextOptionalParams + options?: OperationsListNextOptionalParams, ): Promise { return this.client.sendOperationRequest( { nextLink, options }, - listNextOperationSpec + listNextOperationSpec, ); } } @@ -121,24 +121,23 @@ const listOperationSpec: coreClient.OperationSpec = { httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.OperationListResult - } + bodyMapper: Mappers.OperationListResult, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [Parameters.$host], headerParameters: [Parameters.accept], - serializer + serializer, }; const listNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.OperationListResult - } + bodyMapper: Mappers.OperationListResult, + }, }, - queryParameters: [Parameters.apiVersion], urlParameters: [Parameters.$host, Parameters.nextLink], headerParameters: [Parameters.accept], - serializer + serializer, }; diff --git a/sdk/links/arm-links/src/operations/resourceLinks.ts b/sdk/links/arm-links/src/operations/resourceLinks.ts index 4585f8d526f0..431fe5f9303a 100644 --- a/sdk/links/arm-links/src/operations/resourceLinks.ts +++ b/sdk/links/arm-links/src/operations/resourceLinks.ts @@ -27,7 +27,7 @@ import { ResourceLinksGetOptionalParams, ResourceLinksGetResponse, ResourceLinksListAtSubscriptionNextResponse, - ResourceLinksListAtSourceScopeNextResponse + ResourceLinksListAtSourceScopeNextResponse, } from "../models"; /// @@ -48,7 +48,7 @@ export class ResourceLinksImpl implements ResourceLinks { * @param options The options parameters. */ public listAtSubscription( - options?: ResourceLinksListAtSubscriptionOptionalParams + options?: ResourceLinksListAtSubscriptionOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listAtSubscriptionPagingAll(options); return { @@ -63,13 +63,13 @@ export class ResourceLinksImpl implements ResourceLinks { throw new Error("maxPageSize is not supported by this operation."); } return this.listAtSubscriptionPagingPage(options, settings); - } + }, }; } private async *listAtSubscriptionPagingPage( options?: ResourceLinksListAtSubscriptionOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: ResourceLinksListAtSubscriptionResponse; let continuationToken = settings?.continuationToken; @@ -90,7 +90,7 @@ export class ResourceLinksImpl implements ResourceLinks { } private async *listAtSubscriptionPagingAll( - options?: ResourceLinksListAtSubscriptionOptionalParams + options?: ResourceLinksListAtSubscriptionOptionalParams, ): AsyncIterableIterator { for await (const page of this.listAtSubscriptionPagingPage(options)) { yield* page; @@ -106,7 +106,7 @@ export class ResourceLinksImpl implements ResourceLinks { */ public listAtSourceScope( scope: string, - options?: ResourceLinksListAtSourceScopeOptionalParams + options?: ResourceLinksListAtSourceScopeOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listAtSourceScopePagingAll(scope, options); return { @@ -121,14 +121,14 @@ export class ResourceLinksImpl implements ResourceLinks { throw new Error("maxPageSize is not supported by this operation."); } return this.listAtSourceScopePagingPage(scope, options, settings); - } + }, }; } private async *listAtSourceScopePagingPage( scope: string, options?: ResourceLinksListAtSourceScopeOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: ResourceLinksListAtSourceScopeResponse; let continuationToken = settings?.continuationToken; @@ -143,7 +143,7 @@ export class ResourceLinksImpl implements ResourceLinks { result = await this._listAtSourceScopeNext( scope, continuationToken, - options + options, ); continuationToken = result.nextLink; let page = result.value || []; @@ -154,7 +154,7 @@ export class ResourceLinksImpl implements ResourceLinks { private async *listAtSourceScopePagingAll( scope: string, - options?: ResourceLinksListAtSourceScopeOptionalParams + options?: ResourceLinksListAtSourceScopeOptionalParams, ): AsyncIterableIterator { for await (const page of this.listAtSourceScopePagingPage(scope, options)) { yield* page; @@ -171,11 +171,11 @@ export class ResourceLinksImpl implements ResourceLinks { */ delete( linkId: string, - options?: ResourceLinksDeleteOptionalParams + options?: ResourceLinksDeleteOptionalParams, ): Promise { return this.client.sendOperationRequest( { linkId, options }, - deleteOperationSpec + deleteOperationSpec, ); } @@ -191,11 +191,11 @@ export class ResourceLinksImpl implements ResourceLinks { createOrUpdate( linkId: string, parameters: ResourceLink, - options?: ResourceLinksCreateOrUpdateOptionalParams + options?: ResourceLinksCreateOrUpdateOptionalParams, ): Promise { return this.client.sendOperationRequest( { linkId, parameters, options }, - createOrUpdateOperationSpec + createOrUpdateOperationSpec, ); } @@ -207,11 +207,11 @@ export class ResourceLinksImpl implements ResourceLinks { */ get( linkId: string, - options?: ResourceLinksGetOptionalParams + options?: ResourceLinksGetOptionalParams, ): Promise { return this.client.sendOperationRequest( { linkId, options }, - getOperationSpec + getOperationSpec, ); } @@ -220,11 +220,11 @@ export class ResourceLinksImpl implements ResourceLinks { * @param options The options parameters. */ private _listAtSubscription( - options?: ResourceLinksListAtSubscriptionOptionalParams + options?: ResourceLinksListAtSubscriptionOptionalParams, ): Promise { return this.client.sendOperationRequest( { options }, - listAtSubscriptionOperationSpec + listAtSubscriptionOperationSpec, ); } @@ -237,11 +237,11 @@ export class ResourceLinksImpl implements ResourceLinks { */ private _listAtSourceScope( scope: string, - options?: ResourceLinksListAtSourceScopeOptionalParams + options?: ResourceLinksListAtSourceScopeOptionalParams, ): Promise { return this.client.sendOperationRequest( { scope, options }, - listAtSourceScopeOperationSpec + listAtSourceScopeOperationSpec, ); } @@ -252,11 +252,11 @@ export class ResourceLinksImpl implements ResourceLinks { */ private _listAtSubscriptionNext( nextLink: string, - options?: ResourceLinksListAtSubscriptionNextOptionalParams + options?: ResourceLinksListAtSubscriptionNextOptionalParams, ): Promise { return this.client.sendOperationRequest( { nextLink, options }, - listAtSubscriptionNextOperationSpec + listAtSubscriptionNextOperationSpec, ); } @@ -271,11 +271,11 @@ export class ResourceLinksImpl implements ResourceLinks { private _listAtSourceScopeNext( scope: string, nextLink: string, - options?: ResourceLinksListAtSourceScopeNextOptionalParams + options?: ResourceLinksListAtSourceScopeNextOptionalParams, ): Promise { return this.client.sendOperationRequest( { scope, nextLink, options }, - listAtSourceScopeNextOperationSpec + listAtSourceScopeNextOperationSpec, ); } } @@ -288,92 +288,90 @@ const deleteOperationSpec: coreClient.OperationSpec = { responses: { 200: {}, 204: {} }, queryParameters: [Parameters.apiVersion], urlParameters: [Parameters.$host, Parameters.linkId], - serializer + serializer, }; const createOrUpdateOperationSpec: coreClient.OperationSpec = { path: "/{linkId}", httpMethod: "PUT", responses: { 200: { - bodyMapper: Mappers.ResourceLink + bodyMapper: Mappers.ResourceLink, }, 201: { - bodyMapper: Mappers.ResourceLink - } + bodyMapper: Mappers.ResourceLink, + }, }, requestBody: Parameters.parameters, queryParameters: [Parameters.apiVersion], urlParameters: [Parameters.$host, Parameters.linkId], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", - serializer + serializer, }; const getOperationSpec: coreClient.OperationSpec = { path: "/{linkId}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.ResourceLink - } + bodyMapper: Mappers.ResourceLink, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [Parameters.$host, Parameters.linkId], headerParameters: [Parameters.accept], - serializer + serializer, }; const listAtSubscriptionOperationSpec: coreClient.OperationSpec = { path: "/subscriptions/{subscriptionId}/providers/Microsoft.Resources/links", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.ResourceLinkResult - } + bodyMapper: Mappers.ResourceLinkResult, + }, }, queryParameters: [Parameters.apiVersion, Parameters.filter], urlParameters: [Parameters.$host, Parameters.subscriptionId], headerParameters: [Parameters.accept], - serializer + serializer, }; const listAtSourceScopeOperationSpec: coreClient.OperationSpec = { path: "/{scope}/providers/Microsoft.Resources/links", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.ResourceLinkResult - } + bodyMapper: Mappers.ResourceLinkResult, + }, }, queryParameters: [Parameters.apiVersion, Parameters.filter1], urlParameters: [Parameters.$host, Parameters.scope], headerParameters: [Parameters.accept], - serializer + serializer, }; const listAtSubscriptionNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.ResourceLinkResult - } + bodyMapper: Mappers.ResourceLinkResult, + }, }, - queryParameters: [Parameters.apiVersion, Parameters.filter], urlParameters: [ Parameters.$host, Parameters.nextLink, - Parameters.subscriptionId + Parameters.subscriptionId, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const listAtSourceScopeNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.ResourceLinkResult - } + bodyMapper: Mappers.ResourceLinkResult, + }, }, - queryParameters: [Parameters.apiVersion, Parameters.filter1], urlParameters: [Parameters.$host, Parameters.nextLink, Parameters.scope], headerParameters: [Parameters.accept], - serializer + serializer, }; diff --git a/sdk/links/arm-links/src/operationsInterfaces/operations.ts b/sdk/links/arm-links/src/operationsInterfaces/operations.ts index ac34435954c0..65cdf8035ab0 100644 --- a/sdk/links/arm-links/src/operationsInterfaces/operations.ts +++ b/sdk/links/arm-links/src/operationsInterfaces/operations.ts @@ -17,6 +17,6 @@ export interface Operations { * @param options The options parameters. */ list( - options?: OperationsListOptionalParams + options?: OperationsListOptionalParams, ): PagedAsyncIterableIterator; } diff --git a/sdk/links/arm-links/src/operationsInterfaces/resourceLinks.ts b/sdk/links/arm-links/src/operationsInterfaces/resourceLinks.ts index cbfea5e366a8..05080a73183b 100644 --- a/sdk/links/arm-links/src/operationsInterfaces/resourceLinks.ts +++ b/sdk/links/arm-links/src/operationsInterfaces/resourceLinks.ts @@ -15,7 +15,7 @@ import { ResourceLinksCreateOrUpdateOptionalParams, ResourceLinksCreateOrUpdateResponse, ResourceLinksGetOptionalParams, - ResourceLinksGetResponse + ResourceLinksGetResponse, } from "../models"; /// @@ -26,7 +26,7 @@ export interface ResourceLinks { * @param options The options parameters. */ listAtSubscription( - options?: ResourceLinksListAtSubscriptionOptionalParams + options?: ResourceLinksListAtSubscriptionOptionalParams, ): PagedAsyncIterableIterator; /** * Gets a list of resource links at and below the specified source scope. @@ -37,7 +37,7 @@ export interface ResourceLinks { */ listAtSourceScope( scope: string, - options?: ResourceLinksListAtSourceScopeOptionalParams + options?: ResourceLinksListAtSourceScopeOptionalParams, ): PagedAsyncIterableIterator; /** * Deletes a resource link with the specified ID. @@ -49,7 +49,7 @@ export interface ResourceLinks { */ delete( linkId: string, - options?: ResourceLinksDeleteOptionalParams + options?: ResourceLinksDeleteOptionalParams, ): Promise; /** * Creates or updates a resource link between the specified resources. @@ -63,7 +63,7 @@ export interface ResourceLinks { createOrUpdate( linkId: string, parameters: ResourceLink, - options?: ResourceLinksCreateOrUpdateOptionalParams + options?: ResourceLinksCreateOrUpdateOptionalParams, ): Promise; /** * Gets a resource link with the specified ID. @@ -73,6 +73,6 @@ export interface ResourceLinks { */ get( linkId: string, - options?: ResourceLinksGetOptionalParams + options?: ResourceLinksGetOptionalParams, ): Promise; } diff --git a/sdk/links/arm-links/src/pagingHelper.ts b/sdk/links/arm-links/src/pagingHelper.ts index d85fc13bce1e..205cccc26592 100644 --- a/sdk/links/arm-links/src/pagingHelper.ts +++ b/sdk/links/arm-links/src/pagingHelper.ts @@ -13,11 +13,11 @@ export interface PageInfo { const pageMap = new WeakMap(); /** - * Given a result page from a pageable operation, returns a - * continuation token that can be used to begin paging from + * Given the last `.value` produced by the `byPage` iterator, + * returns a continuation token that can be used to begin paging from * that point later. - * @param page A result object from calling .byPage() on a paged operation. - * @returns The continuation token that can be passed into byPage(). + * @param page An object from accessing `value` on the IteratorResult from a `byPage` iterator. + * @returns The continuation token that can be passed into byPage() during future calls. */ export function getContinuationToken(page: unknown): string | undefined { if (typeof page !== "object" || page === null) { @@ -28,7 +28,7 @@ export function getContinuationToken(page: unknown): string | undefined { export function setContinuationToken( page: unknown, - continuationToken: string | undefined + continuationToken: string | undefined, ): void { if (typeof page !== "object" || page === null || !continuationToken) { return; diff --git a/sdk/links/arm-links/test/sampleTest.ts b/sdk/links/arm-links/test/sampleTest.ts new file mode 100644 index 000000000000..d64be981b694 --- /dev/null +++ b/sdk/links/arm-links/test/sampleTest.ts @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +import { + Recorder, + RecorderStartOptions, + env, +} from "@azure-tools/test-recorder"; +import { assert } from "chai"; +import { Context } from "mocha"; + +const replaceableVariables: Record = { + AZURE_CLIENT_ID: "azure_client_id", + AZURE_CLIENT_SECRET: "azure_client_secret", + AZURE_TENANT_ID: "88888888-8888-8888-8888-888888888888", + SUBSCRIPTION_ID: "azure_subscription_id", +}; + +const recorderOptions: RecorderStartOptions = { + envSetupForPlayback: replaceableVariables, +}; + +describe("My test", () => { + let recorder: Recorder; + + beforeEach(async function (this: Context) { + recorder = new Recorder(this.currentTest); + await recorder.start(recorderOptions); + }); + + afterEach(async function () { + await recorder.stop(); + }); + + it("sample test", async function () { + console.log("Hi, I'm a test!"); + }); +}); diff --git a/sdk/links/arm-links/tsconfig.json b/sdk/links/arm-links/tsconfig.json index 433cb8777ded..24ca8ae4e47e 100644 --- a/sdk/links/arm-links/tsconfig.json +++ b/sdk/links/arm-links/tsconfig.json @@ -15,23 +15,15 @@ ], "declaration": true, "outDir": "./dist-esm", - "importHelpers": true, - "paths": { - "@azure/arm-links": [ - "./src/index" - ] - } + "importHelpers": true }, "include": [ "./src/**/*.ts", "./test/**/*.ts", - "samples-dev/**/*.ts", "./test/**/*.ts", - "samples-dev/**/*.ts", "./test/**/*.ts", - "samples-dev/**/*.ts", "./test/**/*.ts", - "samples-dev/**/*.ts" + "./test/**/*.ts" ], "exclude": [ "node_modules" diff --git a/sdk/locks/arm-locks/CHANGELOG.md b/sdk/locks/arm-locks/CHANGELOG.md index fa91121a0ecd..f080c38b4b6a 100644 --- a/sdk/locks/arm-locks/CHANGELOG.md +++ b/sdk/locks/arm-locks/CHANGELOG.md @@ -1,15 +1,16 @@ # Release History - -## 2.1.1 (Unreleased) - -### Features Added - + +## 3.0.0 (2024-11-01) + ### Breaking Changes -### Bugs Fixed - -### Other Changes - + - Class ManagementLockClient has a new signature + - Interface ManagementLocksListAtResourceGroupLevelNextOptionalParams no longer has parameter filter + - Interface ManagementLocksListAtResourceLevelNextOptionalParams no longer has parameter filter + - Interface ManagementLocksListAtSubscriptionLevelNextOptionalParams no longer has parameter filter + - Interface ManagementLocksListByScopeNextOptionalParams no longer has parameter filter + + ## 2.1.0 (2022-11-22) ### Features Added @@ -31,4 +32,4 @@ To understand the detail of the change, please refer to [Changelog](https://aka. To migrate the existing applications to the latest version, please refer to [Migration Guide](https://aka.ms/js-track2-migration-guide). -To learn more, please refer to our documentation [Quick Start](https://aka.ms/azsdk/js/mgmt/quickstart ). +To learn more, please refer to our documentation [Quick Start](https://aka.ms/azsdk/js/mgmt/quickstart). diff --git a/sdk/locks/arm-locks/LICENSE b/sdk/locks/arm-locks/LICENSE index 5d1d36e0af80..7d5934740965 100644 --- a/sdk/locks/arm-locks/LICENSE +++ b/sdk/locks/arm-locks/LICENSE @@ -1,6 +1,6 @@ The MIT License (MIT) -Copyright (c) 2022 Microsoft +Copyright (c) 2024 Microsoft Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal diff --git a/sdk/locks/arm-locks/_meta.json b/sdk/locks/arm-locks/_meta.json index c7ad3e56f301..28591836c37e 100644 --- a/sdk/locks/arm-locks/_meta.json +++ b/sdk/locks/arm-locks/_meta.json @@ -1,8 +1,8 @@ { - "commit": "a42f1b58607091c4f255ead152a8ef323fa0b280", + "commit": "5342edb61d78cec6e07b17a6cd8f7749c6697272", "readme": "specification/resources/resource-manager/readme.md", - "autorest_command": "autorest --version=3.8.4 --typescript --modelerfour.lenient-model-deduplication --azure-arm --head-as-boolean=true --license-header=MICROSOFT_MIT_NO_VERSION --generate-test --typescript-sdks-folder=D:\\Git\\azure-sdk-for-js ..\\azure-rest-api-specs\\specification\\resources\\resource-manager\\readme.md --use=@autorest/typescript@6.0.0-rc.3.20221108.1 --generate-sample=true", + "autorest_command": "autorest --version=3.9.7 --typescript --modelerfour.lenient-model-deduplication --azure-arm --head-as-boolean=true --license-header=MICROSOFT_MIT_NO_VERSION --generate-test --typescript-sdks-folder=/mnt/vss/_work/1/s/azure-sdk-for-js ../azure-rest-api-specs/specification/resources/resource-manager/readme.md --use=@autorest/typescript@^6.0.12", "repository_url": "https://github.com/Azure/azure-rest-api-specs.git", - "release_tool": "@azure-tools/js-sdk-release-tools@2.4.2", - "use": "@autorest/typescript@6.0.0-rc.3.20221108.1" + "release_tool": "@azure-tools/js-sdk-release-tools@2.7.14", + "use": "@autorest/typescript@^6.0.12" } \ No newline at end of file diff --git a/sdk/locks/arm-locks/package.json b/sdk/locks/arm-locks/package.json index 46bd17b6229e..cb7d376a9338 100644 --- a/sdk/locks/arm-locks/package.json +++ b/sdk/locks/arm-locks/package.json @@ -3,15 +3,15 @@ "sdk-type": "mgmt", "author": "Microsoft Corporation", "description": "A generated SDK for ManagementLockClient.", - "version": "2.1.1", + "version": "3.0.0", "engines": { "node": ">=18.0.0" }, "dependencies": { - "@azure/core-auth": "^1.3.0", - "@azure/core-client": "^1.6.1", "@azure/core-paging": "^1.2.0", - "@azure/core-rest-pipeline": "^1.8.0", + "@azure/core-client": "^1.7.0", + "@azure/core-auth": "^1.6.0", + "@azure/core-rest-pipeline": "^1.14.0", "tslib": "^2.2.0" }, "keywords": [ @@ -26,20 +26,25 @@ "module": "./dist-esm/src/index.js", "types": "./types/arm-locks.d.ts", "devDependencies": { - "@azure-tools/test-credential": "^1.0.0", - "@azure-tools/test-recorder": "^3.0.0", + "@microsoft/api-extractor": "^7.31.1", + "mkdirp": "^3.0.1", + "typescript": "~5.5.3", + "uglify-js": "^3.4.9", + "rimraf": "^5.0.0", + "dotenv": "^16.0.0", "@azure/dev-tool": "^1.0.0", - "@azure/identity": "^4.0.1", - "@types/chai": "^4.2.8", + "@azure/identity": "^4.2.1", + "@azure-tools/test-recorder": "^3.0.0", + "@azure-tools/test-credential": "^1.1.0", + "mocha": "^10.0.0", "@types/mocha": "^10.0.0", - "@types/node": "^18.0.0", + "tsx": "^4.7.1", + "@types/chai": "^4.2.8", "chai": "^4.2.0", "cross-env": "^7.0.2", - "mocha": "^10.0.0", - "ts-node": "^10.0.0", - "typescript": "~5.6.2" + "@types/node": "^18.0.0", + "ts-node": "^10.0.0" }, - "homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/locks/arm-locks", "repository": { "type": "git", "url": "https://github.com/Azure/azure-sdk-for-js.git" @@ -65,30 +70,29 @@ "types/*" ], "scripts": { - "build": "npm run clean && tsc && dev-tool run bundle && npm run minify && dev-tool run vendored mkdirp ./review && npm run extract-api", - "build:browser": "echo skipped", + "build": "npm run clean && tsc && dev-tool run bundle && npm run minify && mkdirp ./review && npm run extract-api", + "minify": "uglifyjs -c -m --comments --source-map \"content='./dist/index.js.map'\" -o ./dist/index.min.js ./dist/index.js", + "prepack": "npm run build", + "pack": "npm pack 2>&1", + "extract-api": "dev-tool run extract-api", + "lint": "echo skipped", + "clean": "rimraf --glob dist dist-browser dist-esm test-dist temp types *.tgz *.log", "build:node": "echo skipped", - "build:samples": "echo skipped.", + "build:browser": "echo skipped", "build:test": "echo skipped", + "build:samples": "echo skipped.", "check-format": "echo skipped", - "clean": "dev-tool run vendored rimraf --glob dist dist-browser dist-esm test-dist temp types *.tgz *.log", "execute:samples": "echo skipped", - "extract-api": "dev-tool run extract-api", "format": "echo skipped", - "integration-test": "npm run integration-test:node && npm run integration-test:browser", - "integration-test:browser": "echo skipped", - "integration-test:node": "dev-tool run test:node-ts-input -- --timeout 1200000 'test/*.ts'", - "lint": "echo skipped", - "minify": "dev-tool run vendored uglifyjs -c -m --comments --source-map \"content='./dist/index.js.map'\" -o ./dist/index.min.js ./dist/index.js", - "pack": "npm pack 2>&1", - "prepack": "npm run build", "test": "npm run integration-test", - "test:browser": "echo skipped", "test:node": "echo skipped", + "test:browser": "echo skipped", "unit-test": "npm run unit-test:node && npm run unit-test:browser", - "unit-test:browser": "echo skipped", "unit-test:node": "cross-env TEST_MODE=playback npm run integration-test:node", - "update-snippets": "echo skipped" + "unit-test:browser": "echo skipped", + "integration-test": "npm run integration-test:node && npm run integration-test:browser", + "integration-test:node": "dev-tool run test:node-ts-input -- --timeout 1200000 'test/*.ts'", + "integration-test:browser": "echo skipped" }, "sideEffects": false, "//metadata": { @@ -100,12 +104,5 @@ ] }, "autoPublish": true, - "//sampleConfiguration": { - "productName": "", - "productSlugs": [ - "azure" - ], - "disableDocsMs": true, - "apiRefLink": "https://docs.microsoft.com/javascript/api/@azure/arm-locks?view=azure-node-preview" - } -} + "homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/locks/arm-locks" +} \ No newline at end of file diff --git a/sdk/locks/arm-locks/review/arm-locks.api.md b/sdk/locks/arm-locks/review/arm-locks.api.md index f0af237b239b..6e803bc7ceaf 100644 --- a/sdk/locks/arm-locks/review/arm-locks.api.md +++ b/sdk/locks/arm-locks/review/arm-locks.api.md @@ -76,6 +76,7 @@ export class ManagementLockClient extends coreClient.ServiceClient { // (undocumented) $host: string; constructor(credentials: coreAuth.TokenCredential, subscriptionId: string, options?: ManagementLockClientOptionalParams); + constructor(credentials: coreAuth.TokenCredential, options?: ManagementLockClientOptionalParams); // (undocumented) apiVersion: string; // (undocumented) @@ -83,7 +84,7 @@ export class ManagementLockClient extends coreClient.ServiceClient { // (undocumented) managementLocks: ManagementLocks; // (undocumented) - subscriptionId: string; + subscriptionId?: string; } // @public @@ -209,7 +210,6 @@ export type ManagementLocksGetByScopeResponse = ManagementLockObject; // @public export interface ManagementLocksListAtResourceGroupLevelNextOptionalParams extends coreClient.OperationOptions { - filter?: string; } // @public @@ -225,7 +225,6 @@ export type ManagementLocksListAtResourceGroupLevelResponse = ManagementLockList // @public export interface ManagementLocksListAtResourceLevelNextOptionalParams extends coreClient.OperationOptions { - filter?: string; } // @public @@ -241,7 +240,6 @@ export type ManagementLocksListAtResourceLevelResponse = ManagementLockListResul // @public export interface ManagementLocksListAtSubscriptionLevelNextOptionalParams extends coreClient.OperationOptions { - filter?: string; } // @public @@ -257,7 +255,6 @@ export type ManagementLocksListAtSubscriptionLevelResponse = ManagementLockListR // @public export interface ManagementLocksListByScopeNextOptionalParams extends coreClient.OperationOptions { - filter?: string; } // @public diff --git a/sdk/locks/arm-locks/src/managementLockClient.ts b/sdk/locks/arm-locks/src/managementLockClient.ts index 1f0594596368..7c4d1d2b4632 100644 --- a/sdk/locks/arm-locks/src/managementLockClient.ts +++ b/sdk/locks/arm-locks/src/managementLockClient.ts @@ -11,20 +11,20 @@ import * as coreRestPipeline from "@azure/core-rest-pipeline"; import { PipelineRequest, PipelineResponse, - SendRequest + SendRequest, } from "@azure/core-rest-pipeline"; import * as coreAuth from "@azure/core-auth"; import { AuthorizationOperationsImpl, ManagementLocksImpl } from "./operations"; import { AuthorizationOperations, - ManagementLocks + ManagementLocks, } from "./operationsInterfaces"; import { ManagementLockClientOptionalParams } from "./models"; export class ManagementLockClient extends coreClient.ServiceClient { $host: string; apiVersion: string; - subscriptionId: string; + subscriptionId?: string; /** * Initializes a new instance of the ManagementLockClient class. @@ -35,13 +35,27 @@ export class ManagementLockClient extends coreClient.ServiceClient { constructor( credentials: coreAuth.TokenCredential, subscriptionId: string, - options?: ManagementLockClientOptionalParams + options?: ManagementLockClientOptionalParams, + ); + constructor( + credentials: coreAuth.TokenCredential, + options?: ManagementLockClientOptionalParams, + ); + constructor( + credentials: coreAuth.TokenCredential, + subscriptionIdOrOptions?: ManagementLockClientOptionalParams | string, + options?: ManagementLockClientOptionalParams, ) { if (credentials === undefined) { throw new Error("'credentials' cannot be null"); } - if (subscriptionId === undefined) { - throw new Error("'subscriptionId' cannot be null"); + + let subscriptionId: string | undefined; + + if (typeof subscriptionIdOrOptions === "string") { + subscriptionId = subscriptionIdOrOptions; + } else if (typeof subscriptionIdOrOptions === "object") { + options = subscriptionIdOrOptions; } // Initializing default values for options @@ -50,10 +64,10 @@ export class ManagementLockClient extends coreClient.ServiceClient { } const defaults: ManagementLockClientOptionalParams = { requestContentType: "application/json; charset=utf-8", - credential: credentials + credential: credentials, }; - const packageDetails = `azsdk-js-arm-locks/2.1.1`; + const packageDetails = `azsdk-js-arm-locks/3.0.0`; const userAgentPrefix = options.userAgentOptions && options.userAgentOptions.userAgentPrefix ? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}` @@ -63,20 +77,21 @@ export class ManagementLockClient extends coreClient.ServiceClient { ...defaults, ...options, userAgentOptions: { - userAgentPrefix + userAgentPrefix, }, endpoint: - options.endpoint ?? options.baseUri ?? "https://management.azure.com" + options.endpoint ?? options.baseUri ?? "https://management.azure.com", }; super(optionsWithDefaults); let bearerTokenAuthenticationPolicyFound: boolean = false; if (options?.pipeline && options.pipeline.getOrderedPolicies().length > 0) { - const pipelinePolicies: coreRestPipeline.PipelinePolicy[] = options.pipeline.getOrderedPolicies(); + const pipelinePolicies: coreRestPipeline.PipelinePolicy[] = + options.pipeline.getOrderedPolicies(); bearerTokenAuthenticationPolicyFound = pipelinePolicies.some( (pipelinePolicy) => pipelinePolicy.name === - coreRestPipeline.bearerTokenAuthenticationPolicyName + coreRestPipeline.bearerTokenAuthenticationPolicyName, ); } if ( @@ -86,7 +101,7 @@ export class ManagementLockClient extends coreClient.ServiceClient { !bearerTokenAuthenticationPolicyFound ) { this.pipeline.removePolicy({ - name: coreRestPipeline.bearerTokenAuthenticationPolicyName + name: coreRestPipeline.bearerTokenAuthenticationPolicyName, }); this.pipeline.addPolicy( coreRestPipeline.bearerTokenAuthenticationPolicy({ @@ -96,9 +111,9 @@ export class ManagementLockClient extends coreClient.ServiceClient { `${optionsWithDefaults.endpoint}/.default`, challengeCallbacks: { authorizeRequestOnChallenge: - coreClient.authorizeRequestOnClaimChallenge - } - }) + coreClient.authorizeRequestOnClaimChallenge, + }, + }), ); } // Parameter assignments @@ -121,7 +136,7 @@ export class ManagementLockClient extends coreClient.ServiceClient { name: "CustomApiVersionPolicy", async sendRequest( request: PipelineRequest, - next: SendRequest + next: SendRequest, ): Promise { const param = request.url.split("?"); if (param.length > 1) { @@ -135,7 +150,7 @@ export class ManagementLockClient extends coreClient.ServiceClient { request.url = param[0] + "?" + newParams.join("&"); } return next(request); - } + }, }; this.pipeline.addPolicy(apiVersionPolicy); } diff --git a/sdk/locks/arm-locks/src/models/index.ts b/sdk/locks/arm-locks/src/models/index.ts index c95cb1af614b..4354ad8880fb 100644 --- a/sdk/locks/arm-locks/src/models/index.ts +++ b/sdk/locks/arm-locks/src/models/index.ts @@ -150,7 +150,7 @@ export enum KnownLockLevel { /** CanNotDelete */ CanNotDelete = "CanNotDelete", /** ReadOnly */ - ReadOnly = "ReadOnly" + ReadOnly = "ReadOnly", } /** @@ -173,7 +173,7 @@ export enum KnownCreatedByType { /** ManagedIdentity */ ManagedIdentity = "ManagedIdentity", /** Key */ - Key = "Key" + Key = "Key", } /** @@ -207,7 +207,8 @@ export interface ManagementLocksCreateOrUpdateAtResourceGroupLevelOptionalParams extends coreClient.OperationOptions {} /** Contains response data for the createOrUpdateAtResourceGroupLevel operation. */ -export type ManagementLocksCreateOrUpdateAtResourceGroupLevelResponse = ManagementLockObject; +export type ManagementLocksCreateOrUpdateAtResourceGroupLevelResponse = + ManagementLockObject; /** Optional parameters. */ export interface ManagementLocksDeleteAtResourceGroupLevelOptionalParams @@ -218,7 +219,8 @@ export interface ManagementLocksGetAtResourceGroupLevelOptionalParams extends coreClient.OperationOptions {} /** Contains response data for the getAtResourceGroupLevel operation. */ -export type ManagementLocksGetAtResourceGroupLevelResponse = ManagementLockObject; +export type ManagementLocksGetAtResourceGroupLevelResponse = + ManagementLockObject; /** Optional parameters. */ export interface ManagementLocksCreateOrUpdateByScopeOptionalParams @@ -243,7 +245,8 @@ export interface ManagementLocksCreateOrUpdateAtResourceLevelOptionalParams extends coreClient.OperationOptions {} /** Contains response data for the createOrUpdateAtResourceLevel operation. */ -export type ManagementLocksCreateOrUpdateAtResourceLevelResponse = ManagementLockObject; +export type ManagementLocksCreateOrUpdateAtResourceLevelResponse = + ManagementLockObject; /** Optional parameters. */ export interface ManagementLocksDeleteAtResourceLevelOptionalParams @@ -261,7 +264,8 @@ export interface ManagementLocksCreateOrUpdateAtSubscriptionLevelOptionalParams extends coreClient.OperationOptions {} /** Contains response data for the createOrUpdateAtSubscriptionLevel operation. */ -export type ManagementLocksCreateOrUpdateAtSubscriptionLevelResponse = ManagementLockObject; +export type ManagementLocksCreateOrUpdateAtSubscriptionLevelResponse = + ManagementLockObject; /** Optional parameters. */ export interface ManagementLocksDeleteAtSubscriptionLevelOptionalParams @@ -272,7 +276,8 @@ export interface ManagementLocksGetAtSubscriptionLevelOptionalParams extends coreClient.OperationOptions {} /** Contains response data for the getAtSubscriptionLevel operation. */ -export type ManagementLocksGetAtSubscriptionLevelResponse = ManagementLockObject; +export type ManagementLocksGetAtSubscriptionLevelResponse = + ManagementLockObject; /** Optional parameters. */ export interface ManagementLocksListAtResourceGroupLevelOptionalParams @@ -282,7 +287,8 @@ export interface ManagementLocksListAtResourceGroupLevelOptionalParams } /** Contains response data for the listAtResourceGroupLevel operation. */ -export type ManagementLocksListAtResourceGroupLevelResponse = ManagementLockListResult; +export type ManagementLocksListAtResourceGroupLevelResponse = + ManagementLockListResult; /** Optional parameters. */ export interface ManagementLocksListAtResourceLevelOptionalParams @@ -292,7 +298,8 @@ export interface ManagementLocksListAtResourceLevelOptionalParams } /** Contains response data for the listAtResourceLevel operation. */ -export type ManagementLocksListAtResourceLevelResponse = ManagementLockListResult; +export type ManagementLocksListAtResourceLevelResponse = + ManagementLockListResult; /** Optional parameters. */ export interface ManagementLocksListAtSubscriptionLevelOptionalParams @@ -302,7 +309,8 @@ export interface ManagementLocksListAtSubscriptionLevelOptionalParams } /** Contains response data for the listAtSubscriptionLevel operation. */ -export type ManagementLocksListAtSubscriptionLevelResponse = ManagementLockListResult; +export type ManagementLocksListAtSubscriptionLevelResponse = + ManagementLockListResult; /** Optional parameters. */ export interface ManagementLocksListByScopeOptionalParams @@ -316,40 +324,31 @@ export type ManagementLocksListByScopeResponse = ManagementLockListResult; /** Optional parameters. */ export interface ManagementLocksListAtResourceGroupLevelNextOptionalParams - extends coreClient.OperationOptions { - /** The filter to apply on the operation. */ - filter?: string; -} + extends coreClient.OperationOptions {} /** Contains response data for the listAtResourceGroupLevelNext operation. */ -export type ManagementLocksListAtResourceGroupLevelNextResponse = ManagementLockListResult; +export type ManagementLocksListAtResourceGroupLevelNextResponse = + ManagementLockListResult; /** Optional parameters. */ export interface ManagementLocksListAtResourceLevelNextOptionalParams - extends coreClient.OperationOptions { - /** The filter to apply on the operation. */ - filter?: string; -} + extends coreClient.OperationOptions {} /** Contains response data for the listAtResourceLevelNext operation. */ -export type ManagementLocksListAtResourceLevelNextResponse = ManagementLockListResult; +export type ManagementLocksListAtResourceLevelNextResponse = + ManagementLockListResult; /** Optional parameters. */ export interface ManagementLocksListAtSubscriptionLevelNextOptionalParams - extends coreClient.OperationOptions { - /** The filter to apply on the operation. */ - filter?: string; -} + extends coreClient.OperationOptions {} /** Contains response data for the listAtSubscriptionLevelNext operation. */ -export type ManagementLocksListAtSubscriptionLevelNextResponse = ManagementLockListResult; +export type ManagementLocksListAtSubscriptionLevelNextResponse = + ManagementLockListResult; /** Optional parameters. */ export interface ManagementLocksListByScopeNextOptionalParams - extends coreClient.OperationOptions { - /** The filter to apply on the operation. */ - filter?: string; -} + extends coreClient.OperationOptions {} /** Contains response data for the listByScopeNext operation. */ export type ManagementLocksListByScopeNextResponse = ManagementLockListResult; diff --git a/sdk/locks/arm-locks/src/models/mappers.ts b/sdk/locks/arm-locks/src/models/mappers.ts index f165718080fd..989b7a561236 100644 --- a/sdk/locks/arm-locks/src/models/mappers.ts +++ b/sdk/locks/arm-locks/src/models/mappers.ts @@ -20,19 +20,19 @@ export const OperationListResult: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "Operation" - } - } - } + className: "Operation", + }, + }, + }, }, nextLink: { serializedName: "nextLink", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const Operation: coreClient.CompositeMapper = { @@ -43,18 +43,18 @@ export const Operation: coreClient.CompositeMapper = { name: { serializedName: "name", type: { - name: "String" - } + name: "String", + }, }, display: { serializedName: "display", type: { name: "Composite", - className: "OperationDisplay" - } - } - } - } + className: "OperationDisplay", + }, + }, + }, + }, }; export const OperationDisplay: coreClient.CompositeMapper = { @@ -65,23 +65,23 @@ export const OperationDisplay: coreClient.CompositeMapper = { provider: { serializedName: "provider", type: { - name: "String" - } + name: "String", + }, }, resource: { serializedName: "resource", type: { - name: "String" - } + name: "String", + }, }, operation: { serializedName: "operation", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const ErrorResponse: coreClient.CompositeMapper = { @@ -93,11 +93,11 @@ export const ErrorResponse: coreClient.CompositeMapper = { serializedName: "error", type: { name: "Composite", - className: "ErrorDetail" - } - } - } - } + className: "ErrorDetail", + }, + }, + }, + }, }; export const ErrorDetail: coreClient.CompositeMapper = { @@ -109,22 +109,22 @@ export const ErrorDetail: coreClient.CompositeMapper = { serializedName: "code", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, message: { serializedName: "message", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, target: { serializedName: "target", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, details: { serializedName: "details", @@ -134,10 +134,10 @@ export const ErrorDetail: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "ErrorDetail" - } - } - } + className: "ErrorDetail", + }, + }, + }, }, additionalInfo: { serializedName: "additionalInfo", @@ -147,13 +147,13 @@ export const ErrorDetail: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "ErrorAdditionalInfo" - } - } - } - } - } - } + className: "ErrorAdditionalInfo", + }, + }, + }, + }, + }, + }, }; export const ErrorAdditionalInfo: coreClient.CompositeMapper = { @@ -165,19 +165,19 @@ export const ErrorAdditionalInfo: coreClient.CompositeMapper = { serializedName: "type", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, info: { serializedName: "info", readOnly: true, type: { name: "Dictionary", - value: { type: { name: "any" } } - } - } - } - } + value: { type: { name: "any" } }, + }, + }, + }, + }, }; export const ManagementLockObject: coreClient.CompositeMapper = { @@ -189,42 +189,42 @@ export const ManagementLockObject: coreClient.CompositeMapper = { serializedName: "id", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, type: { serializedName: "type", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, name: { serializedName: "name", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, systemData: { serializedName: "systemData", type: { name: "Composite", - className: "SystemData" - } + className: "SystemData", + }, }, level: { serializedName: "properties.level", required: true, type: { - name: "String" - } + name: "String", + }, }, notes: { serializedName: "properties.notes", type: { - name: "String" - } + name: "String", + }, }, owners: { serializedName: "properties.owners", @@ -233,13 +233,13 @@ export const ManagementLockObject: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "ManagementLockOwner" - } - } - } - } - } - } + className: "ManagementLockOwner", + }, + }, + }, + }, + }, + }, }; export const ManagementLockOwner: coreClient.CompositeMapper = { @@ -250,11 +250,11 @@ export const ManagementLockOwner: coreClient.CompositeMapper = { applicationId: { serializedName: "applicationId", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const SystemData: coreClient.CompositeMapper = { @@ -265,41 +265,41 @@ export const SystemData: coreClient.CompositeMapper = { createdBy: { serializedName: "createdBy", type: { - name: "String" - } + name: "String", + }, }, createdByType: { serializedName: "createdByType", type: { - name: "String" - } + name: "String", + }, }, createdAt: { serializedName: "createdAt", type: { - name: "DateTime" - } + name: "DateTime", + }, }, lastModifiedBy: { serializedName: "lastModifiedBy", type: { - name: "String" - } + name: "String", + }, }, lastModifiedByType: { serializedName: "lastModifiedByType", type: { - name: "String" - } + name: "String", + }, }, lastModifiedAt: { serializedName: "lastModifiedAt", type: { - name: "DateTime" - } - } - } - } + name: "DateTime", + }, + }, + }, + }, }; export const ManagementLockListResult: coreClient.CompositeMapper = { @@ -314,17 +314,17 @@ export const ManagementLockListResult: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "ManagementLockObject" - } - } - } + className: "ManagementLockObject", + }, + }, + }, }, nextLink: { serializedName: "nextLink", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; diff --git a/sdk/locks/arm-locks/src/models/parameters.ts b/sdk/locks/arm-locks/src/models/parameters.ts index 6df49f707d76..ad894173542d 100644 --- a/sdk/locks/arm-locks/src/models/parameters.ts +++ b/sdk/locks/arm-locks/src/models/parameters.ts @@ -9,7 +9,7 @@ import { OperationParameter, OperationURLParameter, - OperationQueryParameter + OperationQueryParameter, } from "@azure/core-client"; import { ManagementLockObject as ManagementLockObjectMapper } from "../models/mappers"; @@ -20,9 +20,9 @@ export const accept: OperationParameter = { isConstant: true, serializedName: "Accept", type: { - name: "String" - } - } + name: "String", + }, + }, }; export const $host: OperationURLParameter = { @@ -31,10 +31,10 @@ export const $host: OperationURLParameter = { serializedName: "$host", required: true, type: { - name: "String" - } + name: "String", + }, }, - skipEncoding: true + skipEncoding: true, }; export const apiVersion: OperationQueryParameter = { @@ -44,9 +44,9 @@ export const apiVersion: OperationQueryParameter = { isConstant: true, serializedName: "api-version", type: { - name: "String" - } - } + name: "String", + }, + }, }; export const nextLink: OperationURLParameter = { @@ -55,10 +55,10 @@ export const nextLink: OperationURLParameter = { serializedName: "nextLink", required: true, type: { - name: "String" - } + name: "String", + }, }, - skipEncoding: true + skipEncoding: true, }; export const contentType: OperationParameter = { @@ -68,14 +68,14 @@ export const contentType: OperationParameter = { isConstant: true, serializedName: "Content-Type", type: { - name: "String" - } - } + name: "String", + }, + }, }; export const parameters: OperationParameter = { parameterPath: "parameters", - mapper: ManagementLockObjectMapper + mapper: ManagementLockObjectMapper, }; export const resourceGroupName: OperationURLParameter = { @@ -84,14 +84,14 @@ export const resourceGroupName: OperationURLParameter = { constraints: { Pattern: new RegExp("^[-\\w\\._\\(\\)]+$"), MaxLength: 90, - MinLength: 1 + MinLength: 1, }, serializedName: "resourceGroupName", required: true, type: { - name: "String" - } - } + name: "String", + }, + }, }; export const lockName: OperationURLParameter = { @@ -100,9 +100,9 @@ export const lockName: OperationURLParameter = { serializedName: "lockName", required: true, type: { - name: "String" - } - } + name: "String", + }, + }, }; export const subscriptionId: OperationURLParameter = { @@ -111,9 +111,9 @@ export const subscriptionId: OperationURLParameter = { serializedName: "subscriptionId", required: true, type: { - name: "String" - } - } + name: "String", + }, + }, }; export const scope: OperationURLParameter = { @@ -122,9 +122,9 @@ export const scope: OperationURLParameter = { serializedName: "scope", required: true, type: { - name: "String" - } - } + name: "String", + }, + }, }; export const resourceProviderNamespace: OperationURLParameter = { @@ -133,9 +133,9 @@ export const resourceProviderNamespace: OperationURLParameter = { serializedName: "resourceProviderNamespace", required: true, type: { - name: "String" - } - } + name: "String", + }, + }, }; export const parentResourcePath: OperationURLParameter = { @@ -144,10 +144,10 @@ export const parentResourcePath: OperationURLParameter = { serializedName: "parentResourcePath", required: true, type: { - name: "String" - } + name: "String", + }, }, - skipEncoding: true + skipEncoding: true, }; export const resourceType: OperationURLParameter = { @@ -156,10 +156,10 @@ export const resourceType: OperationURLParameter = { serializedName: "resourceType", required: true, type: { - name: "String" - } + name: "String", + }, }, - skipEncoding: true + skipEncoding: true, }; export const resourceName: OperationURLParameter = { @@ -168,9 +168,9 @@ export const resourceName: OperationURLParameter = { serializedName: "resourceName", required: true, type: { - name: "String" - } - } + name: "String", + }, + }, }; export const filter: OperationQueryParameter = { @@ -178,7 +178,7 @@ export const filter: OperationQueryParameter = { mapper: { serializedName: "$filter", type: { - name: "String" - } - } + name: "String", + }, + }, }; diff --git a/sdk/locks/arm-locks/src/operations/authorizationOperations.ts b/sdk/locks/arm-locks/src/operations/authorizationOperations.ts index 7a5256074de5..b796f4a56d4e 100644 --- a/sdk/locks/arm-locks/src/operations/authorizationOperations.ts +++ b/sdk/locks/arm-locks/src/operations/authorizationOperations.ts @@ -18,7 +18,7 @@ import { AuthorizationOperationsListNextOptionalParams, AuthorizationOperationsListOptionalParams, AuthorizationOperationsListResponse, - AuthorizationOperationsListNextResponse + AuthorizationOperationsListNextResponse, } from "../models"; /// @@ -39,7 +39,7 @@ export class AuthorizationOperationsImpl implements AuthorizationOperations { * @param options The options parameters. */ public list( - options?: AuthorizationOperationsListOptionalParams + options?: AuthorizationOperationsListOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listPagingAll(options); return { @@ -54,13 +54,13 @@ export class AuthorizationOperationsImpl implements AuthorizationOperations { throw new Error("maxPageSize is not supported by this operation."); } return this.listPagingPage(options, settings); - } + }, }; } private async *listPagingPage( options?: AuthorizationOperationsListOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: AuthorizationOperationsListResponse; let continuationToken = settings?.continuationToken; @@ -81,7 +81,7 @@ export class AuthorizationOperationsImpl implements AuthorizationOperations { } private async *listPagingAll( - options?: AuthorizationOperationsListOptionalParams + options?: AuthorizationOperationsListOptionalParams, ): AsyncIterableIterator { for await (const page of this.listPagingPage(options)) { yield* page; @@ -93,7 +93,7 @@ export class AuthorizationOperationsImpl implements AuthorizationOperations { * @param options The options parameters. */ private _list( - options?: AuthorizationOperationsListOptionalParams + options?: AuthorizationOperationsListOptionalParams, ): Promise { return this.client.sendOperationRequest({ options }, listOperationSpec); } @@ -105,11 +105,11 @@ export class AuthorizationOperationsImpl implements AuthorizationOperations { */ private _listNext( nextLink: string, - options?: AuthorizationOperationsListNextOptionalParams + options?: AuthorizationOperationsListNextOptionalParams, ): Promise { return this.client.sendOperationRequest( { nextLink, options }, - listNextOperationSpec + listNextOperationSpec, ); } } @@ -121,30 +121,29 @@ const listOperationSpec: coreClient.OperationSpec = { httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.OperationListResult + bodyMapper: Mappers.OperationListResult, }, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [Parameters.$host], headerParameters: [Parameters.accept], - serializer + serializer, }; const listNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.OperationListResult + bodyMapper: Mappers.OperationListResult, }, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, - queryParameters: [Parameters.apiVersion], urlParameters: [Parameters.$host, Parameters.nextLink], headerParameters: [Parameters.accept], - serializer + serializer, }; diff --git a/sdk/locks/arm-locks/src/operations/managementLocks.ts b/sdk/locks/arm-locks/src/operations/managementLocks.ts index 3669b5d87ac0..303e858788a5 100644 --- a/sdk/locks/arm-locks/src/operations/managementLocks.ts +++ b/sdk/locks/arm-locks/src/operations/managementLocks.ts @@ -50,7 +50,7 @@ import { ManagementLocksListAtResourceGroupLevelNextResponse, ManagementLocksListAtResourceLevelNextResponse, ManagementLocksListAtSubscriptionLevelNextResponse, - ManagementLocksListByScopeNextResponse + ManagementLocksListByScopeNextResponse, } from "../models"; /// @@ -73,11 +73,11 @@ export class ManagementLocksImpl implements ManagementLocks { */ public listAtResourceGroupLevel( resourceGroupName: string, - options?: ManagementLocksListAtResourceGroupLevelOptionalParams + options?: ManagementLocksListAtResourceGroupLevelOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listAtResourceGroupLevelPagingAll( resourceGroupName, - options + options, ); return { next() { @@ -93,16 +93,16 @@ export class ManagementLocksImpl implements ManagementLocks { return this.listAtResourceGroupLevelPagingPage( resourceGroupName, options, - settings + settings, ); - } + }, }; } private async *listAtResourceGroupLevelPagingPage( resourceGroupName: string, options?: ManagementLocksListAtResourceGroupLevelOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: ManagementLocksListAtResourceGroupLevelResponse; let continuationToken = settings?.continuationToken; @@ -117,7 +117,7 @@ export class ManagementLocksImpl implements ManagementLocks { result = await this._listAtResourceGroupLevelNext( resourceGroupName, continuationToken, - options + options, ); continuationToken = result.nextLink; let page = result.value || []; @@ -128,11 +128,11 @@ export class ManagementLocksImpl implements ManagementLocks { private async *listAtResourceGroupLevelPagingAll( resourceGroupName: string, - options?: ManagementLocksListAtResourceGroupLevelOptionalParams + options?: ManagementLocksListAtResourceGroupLevelOptionalParams, ): AsyncIterableIterator { for await (const page of this.listAtResourceGroupLevelPagingPage( resourceGroupName, - options + options, )) { yield* page; } @@ -154,7 +154,7 @@ export class ManagementLocksImpl implements ManagementLocks { parentResourcePath: string, resourceType: string, resourceName: string, - options?: ManagementLocksListAtResourceLevelOptionalParams + options?: ManagementLocksListAtResourceLevelOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listAtResourceLevelPagingAll( resourceGroupName, @@ -162,7 +162,7 @@ export class ManagementLocksImpl implements ManagementLocks { parentResourcePath, resourceType, resourceName, - options + options, ); return { next() { @@ -182,9 +182,9 @@ export class ManagementLocksImpl implements ManagementLocks { resourceType, resourceName, options, - settings + settings, ); - } + }, }; } @@ -195,7 +195,7 @@ export class ManagementLocksImpl implements ManagementLocks { resourceType: string, resourceName: string, options?: ManagementLocksListAtResourceLevelOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: ManagementLocksListAtResourceLevelResponse; let continuationToken = settings?.continuationToken; @@ -206,7 +206,7 @@ export class ManagementLocksImpl implements ManagementLocks { parentResourcePath, resourceType, resourceName, - options + options, ); let page = result.value || []; continuationToken = result.nextLink; @@ -221,7 +221,7 @@ export class ManagementLocksImpl implements ManagementLocks { resourceType, resourceName, continuationToken, - options + options, ); continuationToken = result.nextLink; let page = result.value || []; @@ -236,7 +236,7 @@ export class ManagementLocksImpl implements ManagementLocks { parentResourcePath: string, resourceType: string, resourceName: string, - options?: ManagementLocksListAtResourceLevelOptionalParams + options?: ManagementLocksListAtResourceLevelOptionalParams, ): AsyncIterableIterator { for await (const page of this.listAtResourceLevelPagingPage( resourceGroupName, @@ -244,7 +244,7 @@ export class ManagementLocksImpl implements ManagementLocks { parentResourcePath, resourceType, resourceName, - options + options, )) { yield* page; } @@ -255,7 +255,7 @@ export class ManagementLocksImpl implements ManagementLocks { * @param options The options parameters. */ public listAtSubscriptionLevel( - options?: ManagementLocksListAtSubscriptionLevelOptionalParams + options?: ManagementLocksListAtSubscriptionLevelOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listAtSubscriptionLevelPagingAll(options); return { @@ -270,13 +270,13 @@ export class ManagementLocksImpl implements ManagementLocks { throw new Error("maxPageSize is not supported by this operation."); } return this.listAtSubscriptionLevelPagingPage(options, settings); - } + }, }; } private async *listAtSubscriptionLevelPagingPage( options?: ManagementLocksListAtSubscriptionLevelOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: ManagementLocksListAtSubscriptionLevelResponse; let continuationToken = settings?.continuationToken; @@ -290,7 +290,7 @@ export class ManagementLocksImpl implements ManagementLocks { while (continuationToken) { result = await this._listAtSubscriptionLevelNext( continuationToken, - options + options, ); continuationToken = result.nextLink; let page = result.value || []; @@ -300,7 +300,7 @@ export class ManagementLocksImpl implements ManagementLocks { } private async *listAtSubscriptionLevelPagingAll( - options?: ManagementLocksListAtSubscriptionLevelOptionalParams + options?: ManagementLocksListAtSubscriptionLevelOptionalParams, ): AsyncIterableIterator { for await (const page of this.listAtSubscriptionLevelPagingPage(options)) { yield* page; @@ -318,7 +318,7 @@ export class ManagementLocksImpl implements ManagementLocks { */ public listByScope( scope: string, - options?: ManagementLocksListByScopeOptionalParams + options?: ManagementLocksListByScopeOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listByScopePagingAll(scope, options); return { @@ -333,14 +333,14 @@ export class ManagementLocksImpl implements ManagementLocks { throw new Error("maxPageSize is not supported by this operation."); } return this.listByScopePagingPage(scope, options, settings); - } + }, }; } private async *listByScopePagingPage( scope: string, options?: ManagementLocksListByScopeOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: ManagementLocksListByScopeResponse; let continuationToken = settings?.continuationToken; @@ -362,7 +362,7 @@ export class ManagementLocksImpl implements ManagementLocks { private async *listByScopePagingAll( scope: string, - options?: ManagementLocksListByScopeOptionalParams + options?: ManagementLocksListByScopeOptionalParams, ): AsyncIterableIterator { for await (const page of this.listByScopePagingPage(scope, options)) { yield* page; @@ -384,11 +384,11 @@ export class ManagementLocksImpl implements ManagementLocks { resourceGroupName: string, lockName: string, parameters: ManagementLockObject, - options?: ManagementLocksCreateOrUpdateAtResourceGroupLevelOptionalParams + options?: ManagementLocksCreateOrUpdateAtResourceGroupLevelOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceGroupName, lockName, parameters, options }, - createOrUpdateAtResourceGroupLevelOperationSpec + createOrUpdateAtResourceGroupLevelOperationSpec, ); } @@ -403,11 +403,11 @@ export class ManagementLocksImpl implements ManagementLocks { deleteAtResourceGroupLevel( resourceGroupName: string, lockName: string, - options?: ManagementLocksDeleteAtResourceGroupLevelOptionalParams + options?: ManagementLocksDeleteAtResourceGroupLevelOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceGroupName, lockName, options }, - deleteAtResourceGroupLevelOperationSpec + deleteAtResourceGroupLevelOperationSpec, ); } @@ -420,11 +420,11 @@ export class ManagementLocksImpl implements ManagementLocks { getAtResourceGroupLevel( resourceGroupName: string, lockName: string, - options?: ManagementLocksGetAtResourceGroupLevelOptionalParams + options?: ManagementLocksGetAtResourceGroupLevelOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceGroupName, lockName, options }, - getAtResourceGroupLevelOperationSpec + getAtResourceGroupLevelOperationSpec, ); } @@ -443,11 +443,11 @@ export class ManagementLocksImpl implements ManagementLocks { scope: string, lockName: string, parameters: ManagementLockObject, - options?: ManagementLocksCreateOrUpdateByScopeOptionalParams + options?: ManagementLocksCreateOrUpdateByScopeOptionalParams, ): Promise { return this.client.sendOperationRequest( { scope, lockName, parameters, options }, - createOrUpdateByScopeOperationSpec + createOrUpdateByScopeOperationSpec, ); } @@ -460,11 +460,11 @@ export class ManagementLocksImpl implements ManagementLocks { deleteByScope( scope: string, lockName: string, - options?: ManagementLocksDeleteByScopeOptionalParams + options?: ManagementLocksDeleteByScopeOptionalParams, ): Promise { return this.client.sendOperationRequest( { scope, lockName, options }, - deleteByScopeOperationSpec + deleteByScopeOperationSpec, ); } @@ -477,11 +477,11 @@ export class ManagementLocksImpl implements ManagementLocks { getByScope( scope: string, lockName: string, - options?: ManagementLocksGetByScopeOptionalParams + options?: ManagementLocksGetByScopeOptionalParams, ): Promise { return this.client.sendOperationRequest( { scope, lockName, options }, - getByScopeOperationSpec + getByScopeOperationSpec, ); } @@ -508,7 +508,7 @@ export class ManagementLocksImpl implements ManagementLocks { resourceName: string, lockName: string, parameters: ManagementLockObject, - options?: ManagementLocksCreateOrUpdateAtResourceLevelOptionalParams + options?: ManagementLocksCreateOrUpdateAtResourceLevelOptionalParams, ): Promise { return this.client.sendOperationRequest( { @@ -519,9 +519,9 @@ export class ManagementLocksImpl implements ManagementLocks { resourceName, lockName, parameters, - options + options, }, - createOrUpdateAtResourceLevelOperationSpec + createOrUpdateAtResourceLevelOperationSpec, ); } @@ -546,7 +546,7 @@ export class ManagementLocksImpl implements ManagementLocks { resourceType: string, resourceName: string, lockName: string, - options?: ManagementLocksDeleteAtResourceLevelOptionalParams + options?: ManagementLocksDeleteAtResourceLevelOptionalParams, ): Promise { return this.client.sendOperationRequest( { @@ -556,9 +556,9 @@ export class ManagementLocksImpl implements ManagementLocks { resourceType, resourceName, lockName, - options + options, }, - deleteAtResourceLevelOperationSpec + deleteAtResourceLevelOperationSpec, ); } @@ -579,7 +579,7 @@ export class ManagementLocksImpl implements ManagementLocks { resourceType: string, resourceName: string, lockName: string, - options?: ManagementLocksGetAtResourceLevelOptionalParams + options?: ManagementLocksGetAtResourceLevelOptionalParams, ): Promise { return this.client.sendOperationRequest( { @@ -589,9 +589,9 @@ export class ManagementLocksImpl implements ManagementLocks { resourceType, resourceName, lockName, - options + options, }, - getAtResourceLevelOperationSpec + getAtResourceLevelOperationSpec, ); } @@ -608,11 +608,11 @@ export class ManagementLocksImpl implements ManagementLocks { createOrUpdateAtSubscriptionLevel( lockName: string, parameters: ManagementLockObject, - options?: ManagementLocksCreateOrUpdateAtSubscriptionLevelOptionalParams + options?: ManagementLocksCreateOrUpdateAtSubscriptionLevelOptionalParams, ): Promise { return this.client.sendOperationRequest( { lockName, parameters, options }, - createOrUpdateAtSubscriptionLevelOperationSpec + createOrUpdateAtSubscriptionLevelOperationSpec, ); } @@ -625,11 +625,11 @@ export class ManagementLocksImpl implements ManagementLocks { */ deleteAtSubscriptionLevel( lockName: string, - options?: ManagementLocksDeleteAtSubscriptionLevelOptionalParams + options?: ManagementLocksDeleteAtSubscriptionLevelOptionalParams, ): Promise { return this.client.sendOperationRequest( { lockName, options }, - deleteAtSubscriptionLevelOperationSpec + deleteAtSubscriptionLevelOperationSpec, ); } @@ -640,11 +640,11 @@ export class ManagementLocksImpl implements ManagementLocks { */ getAtSubscriptionLevel( lockName: string, - options?: ManagementLocksGetAtSubscriptionLevelOptionalParams + options?: ManagementLocksGetAtSubscriptionLevelOptionalParams, ): Promise { return this.client.sendOperationRequest( { lockName, options }, - getAtSubscriptionLevelOperationSpec + getAtSubscriptionLevelOperationSpec, ); } @@ -655,11 +655,11 @@ export class ManagementLocksImpl implements ManagementLocks { */ private _listAtResourceGroupLevel( resourceGroupName: string, - options?: ManagementLocksListAtResourceGroupLevelOptionalParams + options?: ManagementLocksListAtResourceGroupLevelOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceGroupName, options }, - listAtResourceGroupLevelOperationSpec + listAtResourceGroupLevelOperationSpec, ); } @@ -679,7 +679,7 @@ export class ManagementLocksImpl implements ManagementLocks { parentResourcePath: string, resourceType: string, resourceName: string, - options?: ManagementLocksListAtResourceLevelOptionalParams + options?: ManagementLocksListAtResourceLevelOptionalParams, ): Promise { return this.client.sendOperationRequest( { @@ -688,9 +688,9 @@ export class ManagementLocksImpl implements ManagementLocks { parentResourcePath, resourceType, resourceName, - options + options, }, - listAtResourceLevelOperationSpec + listAtResourceLevelOperationSpec, ); } @@ -699,11 +699,11 @@ export class ManagementLocksImpl implements ManagementLocks { * @param options The options parameters. */ private _listAtSubscriptionLevel( - options?: ManagementLocksListAtSubscriptionLevelOptionalParams + options?: ManagementLocksListAtSubscriptionLevelOptionalParams, ): Promise { return this.client.sendOperationRequest( { options }, - listAtSubscriptionLevelOperationSpec + listAtSubscriptionLevelOperationSpec, ); } @@ -718,11 +718,11 @@ export class ManagementLocksImpl implements ManagementLocks { */ private _listByScope( scope: string, - options?: ManagementLocksListByScopeOptionalParams + options?: ManagementLocksListByScopeOptionalParams, ): Promise { return this.client.sendOperationRequest( { scope, options }, - listByScopeOperationSpec + listByScopeOperationSpec, ); } @@ -736,11 +736,11 @@ export class ManagementLocksImpl implements ManagementLocks { private _listAtResourceGroupLevelNext( resourceGroupName: string, nextLink: string, - options?: ManagementLocksListAtResourceGroupLevelNextOptionalParams + options?: ManagementLocksListAtResourceGroupLevelNextOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceGroupName, nextLink, options }, - listAtResourceGroupLevelNextOperationSpec + listAtResourceGroupLevelNextOperationSpec, ); } @@ -762,7 +762,7 @@ export class ManagementLocksImpl implements ManagementLocks { resourceType: string, resourceName: string, nextLink: string, - options?: ManagementLocksListAtResourceLevelNextOptionalParams + options?: ManagementLocksListAtResourceLevelNextOptionalParams, ): Promise { return this.client.sendOperationRequest( { @@ -772,9 +772,9 @@ export class ManagementLocksImpl implements ManagementLocks { resourceType, resourceName, nextLink, - options + options, }, - listAtResourceLevelNextOperationSpec + listAtResourceLevelNextOperationSpec, ); } @@ -786,11 +786,11 @@ export class ManagementLocksImpl implements ManagementLocks { */ private _listAtSubscriptionLevelNext( nextLink: string, - options?: ManagementLocksListAtSubscriptionLevelNextOptionalParams + options?: ManagementLocksListAtSubscriptionLevelNextOptionalParams, ): Promise { return this.client.sendOperationRequest( { nextLink, options }, - listAtSubscriptionLevelNextOperationSpec + listAtSubscriptionLevelNextOperationSpec, ); } @@ -807,107 +807,105 @@ export class ManagementLocksImpl implements ManagementLocks { private _listByScopeNext( scope: string, nextLink: string, - options?: ManagementLocksListByScopeNextOptionalParams + options?: ManagementLocksListByScopeNextOptionalParams, ): Promise { return this.client.sendOperationRequest( { scope, nextLink, options }, - listByScopeNextOperationSpec + listByScopeNextOperationSpec, ); } } // Operation Specifications const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); -const createOrUpdateAtResourceGroupLevelOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Authorization/locks/{lockName}", - httpMethod: "PUT", - responses: { - 200: { - bodyMapper: Mappers.ManagementLockObject - }, - 201: { - bodyMapper: Mappers.ManagementLockObject +const createOrUpdateAtResourceGroupLevelOperationSpec: coreClient.OperationSpec = + { + path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Authorization/locks/{lockName}", + httpMethod: "PUT", + responses: { + 200: { + bodyMapper: Mappers.ManagementLockObject, + }, + 201: { + bodyMapper: Mappers.ManagementLockObject, + }, + default: { + bodyMapper: Mappers.ErrorResponse, + }, }, - default: { - bodyMapper: Mappers.ErrorResponse - } - }, - requestBody: Parameters.parameters, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.resourceGroupName, - Parameters.lockName, - Parameters.subscriptionId - ], - headerParameters: [Parameters.accept, Parameters.contentType], - mediaType: "json", - serializer -}; + requestBody: Parameters.parameters, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.resourceGroupName, + Parameters.lockName, + Parameters.subscriptionId, + ], + headerParameters: [Parameters.accept, Parameters.contentType], + mediaType: "json", + serializer, + }; const deleteAtResourceGroupLevelOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Authorization/locks/{lockName}", + path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Authorization/locks/{lockName}", httpMethod: "DELETE", responses: { 200: {}, 204: {}, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.resourceGroupName, Parameters.lockName, - Parameters.subscriptionId + Parameters.subscriptionId, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const getAtResourceGroupLevelOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Authorization/locks/{lockName}", + path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Authorization/locks/{lockName}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.ManagementLockObject + bodyMapper: Mappers.ManagementLockObject, }, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.resourceGroupName, Parameters.lockName, - Parameters.subscriptionId + Parameters.subscriptionId, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const createOrUpdateByScopeOperationSpec: coreClient.OperationSpec = { path: "/{scope}/providers/Microsoft.Authorization/locks/{lockName}", httpMethod: "PUT", responses: { 200: { - bodyMapper: Mappers.ManagementLockObject + bodyMapper: Mappers.ManagementLockObject, }, 201: { - bodyMapper: Mappers.ManagementLockObject + bodyMapper: Mappers.ManagementLockObject, }, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, requestBody: Parameters.parameters, queryParameters: [Parameters.apiVersion], urlParameters: [Parameters.$host, Parameters.lockName, Parameters.scope], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", - serializer + serializer, }; const deleteByScopeOperationSpec: coreClient.OperationSpec = { path: "/{scope}/providers/Microsoft.Authorization/locks/{lockName}", @@ -916,44 +914,43 @@ const deleteByScopeOperationSpec: coreClient.OperationSpec = { 200: {}, 204: {}, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [Parameters.$host, Parameters.lockName, Parameters.scope], headerParameters: [Parameters.accept], - serializer + serializer, }; const getByScopeOperationSpec: coreClient.OperationSpec = { path: "/{scope}/providers/Microsoft.Authorization/locks/{lockName}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.ManagementLockObject + bodyMapper: Mappers.ManagementLockObject, }, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [Parameters.$host, Parameters.lockName, Parameters.scope], headerParameters: [Parameters.accept], - serializer + serializer, }; const createOrUpdateAtResourceLevelOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{parentResourcePath}/{resourceType}/{resourceName}/providers/Microsoft.Authorization/locks/{lockName}", + path: "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{parentResourcePath}/{resourceType}/{resourceName}/providers/Microsoft.Authorization/locks/{lockName}", httpMethod: "PUT", responses: { 200: { - bodyMapper: Mappers.ManagementLockObject + bodyMapper: Mappers.ManagementLockObject, }, 201: { - bodyMapper: Mappers.ManagementLockObject + bodyMapper: Mappers.ManagementLockObject, }, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, requestBody: Parameters.parameters, queryParameters: [Parameters.apiVersion], @@ -965,22 +962,21 @@ const createOrUpdateAtResourceLevelOperationSpec: coreClient.OperationSpec = { Parameters.resourceProviderNamespace, Parameters.parentResourcePath, Parameters.resourceType, - Parameters.resourceName + Parameters.resourceName, ], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", - serializer + serializer, }; const deleteAtResourceLevelOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{parentResourcePath}/{resourceType}/{resourceName}/providers/Microsoft.Authorization/locks/{lockName}", + path: "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{parentResourcePath}/{resourceType}/{resourceName}/providers/Microsoft.Authorization/locks/{lockName}", httpMethod: "DELETE", responses: { 200: {}, 204: {}, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ @@ -991,22 +987,21 @@ const deleteAtResourceLevelOperationSpec: coreClient.OperationSpec = { Parameters.resourceProviderNamespace, Parameters.parentResourcePath, Parameters.resourceType, - Parameters.resourceName + Parameters.resourceName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const getAtResourceLevelOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{parentResourcePath}/{resourceType}/{resourceName}/providers/Microsoft.Authorization/locks/{lockName}", + path: "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{parentResourcePath}/{resourceType}/{resourceName}/providers/Microsoft.Authorization/locks/{lockName}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.ManagementLockObject + bodyMapper: Mappers.ManagementLockObject, }, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ @@ -1017,110 +1012,106 @@ const getAtResourceLevelOperationSpec: coreClient.OperationSpec = { Parameters.resourceProviderNamespace, Parameters.parentResourcePath, Parameters.resourceType, - Parameters.resourceName + Parameters.resourceName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; -const createOrUpdateAtSubscriptionLevelOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/providers/Microsoft.Authorization/locks/{lockName}", - httpMethod: "PUT", - responses: { - 200: { - bodyMapper: Mappers.ManagementLockObject - }, - 201: { - bodyMapper: Mappers.ManagementLockObject +const createOrUpdateAtSubscriptionLevelOperationSpec: coreClient.OperationSpec = + { + path: "/subscriptions/{subscriptionId}/providers/Microsoft.Authorization/locks/{lockName}", + httpMethod: "PUT", + responses: { + 200: { + bodyMapper: Mappers.ManagementLockObject, + }, + 201: { + bodyMapper: Mappers.ManagementLockObject, + }, + default: { + bodyMapper: Mappers.ErrorResponse, + }, }, - default: { - bodyMapper: Mappers.ErrorResponse - } - }, - requestBody: Parameters.parameters, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.lockName, - Parameters.subscriptionId - ], - headerParameters: [Parameters.accept, Parameters.contentType], - mediaType: "json", - serializer -}; + requestBody: Parameters.parameters, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.lockName, + Parameters.subscriptionId, + ], + headerParameters: [Parameters.accept, Parameters.contentType], + mediaType: "json", + serializer, + }; const deleteAtSubscriptionLevelOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/providers/Microsoft.Authorization/locks/{lockName}", + path: "/subscriptions/{subscriptionId}/providers/Microsoft.Authorization/locks/{lockName}", httpMethod: "DELETE", responses: { 200: {}, 204: {}, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.lockName, - Parameters.subscriptionId + Parameters.subscriptionId, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const getAtSubscriptionLevelOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/providers/Microsoft.Authorization/locks/{lockName}", + path: "/subscriptions/{subscriptionId}/providers/Microsoft.Authorization/locks/{lockName}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.ManagementLockObject + bodyMapper: Mappers.ManagementLockObject, }, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.lockName, - Parameters.subscriptionId + Parameters.subscriptionId, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const listAtResourceGroupLevelOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Authorization/locks", + path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Authorization/locks", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.ManagementLockListResult + bodyMapper: Mappers.ManagementLockListResult, }, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, queryParameters: [Parameters.apiVersion, Parameters.filter], urlParameters: [ Parameters.$host, Parameters.resourceGroupName, - Parameters.subscriptionId + Parameters.subscriptionId, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const listAtResourceLevelOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{parentResourcePath}/{resourceType}/{resourceName}/providers/Microsoft.Authorization/locks", + path: "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{parentResourcePath}/{resourceType}/{resourceName}/providers/Microsoft.Authorization/locks", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.ManagementLockListResult + bodyMapper: Mappers.ManagementLockListResult, }, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, queryParameters: [Parameters.apiVersion, Parameters.filter], urlParameters: [ @@ -1130,77 +1121,74 @@ const listAtResourceLevelOperationSpec: coreClient.OperationSpec = { Parameters.resourceProviderNamespace, Parameters.parentResourcePath, Parameters.resourceType, - Parameters.resourceName + Parameters.resourceName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const listAtSubscriptionLevelOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/providers/Microsoft.Authorization/locks", + path: "/subscriptions/{subscriptionId}/providers/Microsoft.Authorization/locks", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.ManagementLockListResult + bodyMapper: Mappers.ManagementLockListResult, }, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, queryParameters: [Parameters.apiVersion, Parameters.filter], urlParameters: [Parameters.$host, Parameters.subscriptionId], headerParameters: [Parameters.accept], - serializer + serializer, }; const listByScopeOperationSpec: coreClient.OperationSpec = { path: "/{scope}/providers/Microsoft.Authorization/locks", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.ManagementLockListResult + bodyMapper: Mappers.ManagementLockListResult, }, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, queryParameters: [Parameters.apiVersion, Parameters.filter], urlParameters: [Parameters.$host, Parameters.scope], headerParameters: [Parameters.accept], - serializer + serializer, }; const listAtResourceGroupLevelNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.ManagementLockListResult + bodyMapper: Mappers.ManagementLockListResult, }, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, - queryParameters: [Parameters.apiVersion, Parameters.filter], urlParameters: [ Parameters.$host, Parameters.nextLink, Parameters.resourceGroupName, - Parameters.subscriptionId + Parameters.subscriptionId, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const listAtResourceLevelNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.ManagementLockListResult + bodyMapper: Mappers.ManagementLockListResult, }, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, - queryParameters: [Parameters.apiVersion, Parameters.filter], urlParameters: [ Parameters.$host, Parameters.nextLink, @@ -1209,44 +1197,42 @@ const listAtResourceLevelNextOperationSpec: coreClient.OperationSpec = { Parameters.resourceProviderNamespace, Parameters.parentResourcePath, Parameters.resourceType, - Parameters.resourceName + Parameters.resourceName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const listAtSubscriptionLevelNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.ManagementLockListResult + bodyMapper: Mappers.ManagementLockListResult, }, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, - queryParameters: [Parameters.apiVersion, Parameters.filter], urlParameters: [ Parameters.$host, Parameters.nextLink, - Parameters.subscriptionId + Parameters.subscriptionId, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const listByScopeNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.ManagementLockListResult + bodyMapper: Mappers.ManagementLockListResult, }, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, - queryParameters: [Parameters.apiVersion, Parameters.filter], urlParameters: [Parameters.$host, Parameters.nextLink, Parameters.scope], headerParameters: [Parameters.accept], - serializer + serializer, }; diff --git a/sdk/locks/arm-locks/src/operationsInterfaces/authorizationOperations.ts b/sdk/locks/arm-locks/src/operationsInterfaces/authorizationOperations.ts index 9e806d13345f..3e59bef63ca8 100644 --- a/sdk/locks/arm-locks/src/operationsInterfaces/authorizationOperations.ts +++ b/sdk/locks/arm-locks/src/operationsInterfaces/authorizationOperations.ts @@ -9,7 +9,7 @@ import { PagedAsyncIterableIterator } from "@azure/core-paging"; import { Operation, - AuthorizationOperationsListOptionalParams + AuthorizationOperationsListOptionalParams, } from "../models"; /// @@ -20,6 +20,6 @@ export interface AuthorizationOperations { * @param options The options parameters. */ list( - options?: AuthorizationOperationsListOptionalParams + options?: AuthorizationOperationsListOptionalParams, ): PagedAsyncIterableIterator; } diff --git a/sdk/locks/arm-locks/src/operationsInterfaces/managementLocks.ts b/sdk/locks/arm-locks/src/operationsInterfaces/managementLocks.ts index 7ffff412119f..91f5d56bacf3 100644 --- a/sdk/locks/arm-locks/src/operationsInterfaces/managementLocks.ts +++ b/sdk/locks/arm-locks/src/operationsInterfaces/managementLocks.ts @@ -32,7 +32,7 @@ import { ManagementLocksCreateOrUpdateAtSubscriptionLevelResponse, ManagementLocksDeleteAtSubscriptionLevelOptionalParams, ManagementLocksGetAtSubscriptionLevelOptionalParams, - ManagementLocksGetAtSubscriptionLevelResponse + ManagementLocksGetAtSubscriptionLevelResponse, } from "../models"; /// @@ -45,7 +45,7 @@ export interface ManagementLocks { */ listAtResourceGroupLevel( resourceGroupName: string, - options?: ManagementLocksListAtResourceGroupLevelOptionalParams + options?: ManagementLocksListAtResourceGroupLevelOptionalParams, ): PagedAsyncIterableIterator; /** * Gets all the management locks for a resource or any level below resource. @@ -63,14 +63,14 @@ export interface ManagementLocks { parentResourcePath: string, resourceType: string, resourceName: string, - options?: ManagementLocksListAtResourceLevelOptionalParams + options?: ManagementLocksListAtResourceLevelOptionalParams, ): PagedAsyncIterableIterator; /** * Gets all the management locks for a subscription. * @param options The options parameters. */ listAtSubscriptionLevel( - options?: ManagementLocksListAtSubscriptionLevelOptionalParams + options?: ManagementLocksListAtSubscriptionLevelOptionalParams, ): PagedAsyncIterableIterator; /** * Gets all the management locks for a scope. @@ -83,7 +83,7 @@ export interface ManagementLocks { */ listByScope( scope: string, - options?: ManagementLocksListByScopeOptionalParams + options?: ManagementLocksListByScopeOptionalParams, ): PagedAsyncIterableIterator; /** * When you apply a lock at a parent scope, all child resources inherit the same lock. To create @@ -100,7 +100,7 @@ export interface ManagementLocks { resourceGroupName: string, lockName: string, parameters: ManagementLockObject, - options?: ManagementLocksCreateOrUpdateAtResourceGroupLevelOptionalParams + options?: ManagementLocksCreateOrUpdateAtResourceGroupLevelOptionalParams, ): Promise; /** * To delete management locks, you must have access to Microsoft.Authorization/* or @@ -113,7 +113,7 @@ export interface ManagementLocks { deleteAtResourceGroupLevel( resourceGroupName: string, lockName: string, - options?: ManagementLocksDeleteAtResourceGroupLevelOptionalParams + options?: ManagementLocksDeleteAtResourceGroupLevelOptionalParams, ): Promise; /** * Gets a management lock at the resource group level. @@ -124,7 +124,7 @@ export interface ManagementLocks { getAtResourceGroupLevel( resourceGroupName: string, lockName: string, - options?: ManagementLocksGetAtResourceGroupLevelOptionalParams + options?: ManagementLocksGetAtResourceGroupLevelOptionalParams, ): Promise; /** * Create or update a management lock by scope. @@ -141,7 +141,7 @@ export interface ManagementLocks { scope: string, lockName: string, parameters: ManagementLockObject, - options?: ManagementLocksCreateOrUpdateByScopeOptionalParams + options?: ManagementLocksCreateOrUpdateByScopeOptionalParams, ): Promise; /** * Delete a management lock by scope. @@ -152,7 +152,7 @@ export interface ManagementLocks { deleteByScope( scope: string, lockName: string, - options?: ManagementLocksDeleteByScopeOptionalParams + options?: ManagementLocksDeleteByScopeOptionalParams, ): Promise; /** * Get a management lock by scope. @@ -163,7 +163,7 @@ export interface ManagementLocks { getByScope( scope: string, lockName: string, - options?: ManagementLocksGetByScopeOptionalParams + options?: ManagementLocksGetByScopeOptionalParams, ): Promise; /** * When you apply a lock at a parent scope, all child resources inherit the same lock. To create @@ -188,7 +188,7 @@ export interface ManagementLocks { resourceName: string, lockName: string, parameters: ManagementLockObject, - options?: ManagementLocksCreateOrUpdateAtResourceLevelOptionalParams + options?: ManagementLocksCreateOrUpdateAtResourceLevelOptionalParams, ): Promise; /** * To delete management locks, you must have access to Microsoft.Authorization/* or @@ -211,7 +211,7 @@ export interface ManagementLocks { resourceType: string, resourceName: string, lockName: string, - options?: ManagementLocksDeleteAtResourceLevelOptionalParams + options?: ManagementLocksDeleteAtResourceLevelOptionalParams, ): Promise; /** * Get the management lock of a resource or any level below resource. @@ -230,7 +230,7 @@ export interface ManagementLocks { resourceType: string, resourceName: string, lockName: string, - options?: ManagementLocksGetAtResourceLevelOptionalParams + options?: ManagementLocksGetAtResourceLevelOptionalParams, ): Promise; /** * When you apply a lock at a parent scope, all child resources inherit the same lock. To create @@ -245,7 +245,7 @@ export interface ManagementLocks { createOrUpdateAtSubscriptionLevel( lockName: string, parameters: ManagementLockObject, - options?: ManagementLocksCreateOrUpdateAtSubscriptionLevelOptionalParams + options?: ManagementLocksCreateOrUpdateAtSubscriptionLevelOptionalParams, ): Promise; /** * To delete management locks, you must have access to Microsoft.Authorization/* or @@ -256,7 +256,7 @@ export interface ManagementLocks { */ deleteAtSubscriptionLevel( lockName: string, - options?: ManagementLocksDeleteAtSubscriptionLevelOptionalParams + options?: ManagementLocksDeleteAtSubscriptionLevelOptionalParams, ): Promise; /** * Gets a management lock at the subscription level. @@ -265,6 +265,6 @@ export interface ManagementLocks { */ getAtSubscriptionLevel( lockName: string, - options?: ManagementLocksGetAtSubscriptionLevelOptionalParams + options?: ManagementLocksGetAtSubscriptionLevelOptionalParams, ): Promise; } diff --git a/sdk/locks/arm-locks/src/pagingHelper.ts b/sdk/locks/arm-locks/src/pagingHelper.ts index d85fc13bce1e..205cccc26592 100644 --- a/sdk/locks/arm-locks/src/pagingHelper.ts +++ b/sdk/locks/arm-locks/src/pagingHelper.ts @@ -13,11 +13,11 @@ export interface PageInfo { const pageMap = new WeakMap(); /** - * Given a result page from a pageable operation, returns a - * continuation token that can be used to begin paging from + * Given the last `.value` produced by the `byPage` iterator, + * returns a continuation token that can be used to begin paging from * that point later. - * @param page A result object from calling .byPage() on a paged operation. - * @returns The continuation token that can be passed into byPage(). + * @param page An object from accessing `value` on the IteratorResult from a `byPage` iterator. + * @returns The continuation token that can be passed into byPage() during future calls. */ export function getContinuationToken(page: unknown): string | undefined { if (typeof page !== "object" || page === null) { @@ -28,7 +28,7 @@ export function getContinuationToken(page: unknown): string | undefined { export function setContinuationToken( page: unknown, - continuationToken: string | undefined + continuationToken: string | undefined, ): void { if (typeof page !== "object" || page === null || !continuationToken) { return; diff --git a/sdk/locks/arm-locks/test/sampleTest.ts b/sdk/locks/arm-locks/test/sampleTest.ts new file mode 100644 index 000000000000..d64be981b694 --- /dev/null +++ b/sdk/locks/arm-locks/test/sampleTest.ts @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +import { + Recorder, + RecorderStartOptions, + env, +} from "@azure-tools/test-recorder"; +import { assert } from "chai"; +import { Context } from "mocha"; + +const replaceableVariables: Record = { + AZURE_CLIENT_ID: "azure_client_id", + AZURE_CLIENT_SECRET: "azure_client_secret", + AZURE_TENANT_ID: "88888888-8888-8888-8888-888888888888", + SUBSCRIPTION_ID: "azure_subscription_id", +}; + +const recorderOptions: RecorderStartOptions = { + envSetupForPlayback: replaceableVariables, +}; + +describe("My test", () => { + let recorder: Recorder; + + beforeEach(async function (this: Context) { + recorder = new Recorder(this.currentTest); + await recorder.start(recorderOptions); + }); + + afterEach(async function () { + await recorder.stop(); + }); + + it("sample test", async function () { + console.log("Hi, I'm a test!"); + }); +}); diff --git a/sdk/locks/arm-locks/tsconfig.json b/sdk/locks/arm-locks/tsconfig.json index 6b255a60b747..8292b80f5b3f 100644 --- a/sdk/locks/arm-locks/tsconfig.json +++ b/sdk/locks/arm-locks/tsconfig.json @@ -15,19 +15,13 @@ ], "declaration": true, "outDir": "./dist-esm", - "importHelpers": true, - "paths": { - "@azure/arm-locks": [ - "./src/index" - ] - } + "importHelpers": true }, "include": [ "./src/**/*.ts", "./test/**/*.ts", - "samples-dev/**/*.ts", "./test/**/*.ts", - "samples-dev/**/*.ts" + "./test/**/*.ts" ], "exclude": [ "node_modules" diff --git a/sdk/managedapplications/arm-managedapplications/CHANGELOG.md b/sdk/managedapplications/arm-managedapplications/CHANGELOG.md index 9d1f1444e5c3..e51241a56977 100644 --- a/sdk/managedapplications/arm-managedapplications/CHANGELOG.md +++ b/sdk/managedapplications/arm-managedapplications/CHANGELOG.md @@ -1,5 +1,118 @@ # Release History +## 4.0.0 (2024-11-01) + +### Features Added + + - Added operation ApplicationDefinitions.beginCreateOrUpdate + - Added operation ApplicationDefinitions.beginCreateOrUpdateAndWait + - Added operation ApplicationDefinitions.beginCreateOrUpdateById + - Added operation ApplicationDefinitions.beginCreateOrUpdateByIdAndWait + - Added operation ApplicationDefinitions.beginDelete + - Added operation ApplicationDefinitions.beginDeleteAndWait + - Added operation ApplicationDefinitions.beginDeleteById + - Added operation ApplicationDefinitions.beginDeleteByIdAndWait + - Added operation Applications.update + - Added operation Applications.updateById + - Added Interface ApplicationProviderAuthorization + - Interface ApplicationDefinitionsCreateOrUpdateByIdOptionalParams has a new optional parameter resumeFrom + - Interface ApplicationDefinitionsCreateOrUpdateByIdOptionalParams has a new optional parameter updateIntervalInMs + - Interface ApplicationDefinitionsCreateOrUpdateOptionalParams has a new optional parameter resumeFrom + - Interface ApplicationDefinitionsCreateOrUpdateOptionalParams has a new optional parameter updateIntervalInMs + - Interface ApplicationDefinitionsDeleteByIdOptionalParams has a new optional parameter resumeFrom + - Interface ApplicationDefinitionsDeleteByIdOptionalParams has a new optional parameter updateIntervalInMs + - Interface ApplicationDefinitionsDeleteOptionalParams has a new optional parameter resumeFrom + - Interface ApplicationDefinitionsDeleteOptionalParams has a new optional parameter updateIntervalInMs + - Interface ErrorResponse has a new optional parameter errorCode + - Interface ErrorResponse has a new optional parameter errorMessage + - Interface ErrorResponse has a new optional parameter httpStatus + - Interface GenericResource has a new optional parameter identity + - Enum KnownProvisioningState has a new value Created + - Enum KnownProvisioningState has a new value Creating + - Enum KnownProvisioningState has a new value Ready + +### Breaking Changes + + - Removed operation group JitRequests + - Removed operation ApplicationDefinitions.createOrUpdate + - Removed operation ApplicationDefinitions.createOrUpdateById + - Removed operation ApplicationDefinitions.delete + - Removed operation ApplicationDefinitions.deleteById + - Removed operation ApplicationDefinitions.listBySubscription + - Removed operation ApplicationDefinitions.update + - Removed operation ApplicationDefinitions.updateById + - Removed operation Applications.beginRefreshPermissions + - Removed operation Applications.beginRefreshPermissionsAndWait + - Removed operation Applications.beginUpdate + - Removed operation Applications.beginUpdateAccess + - Removed operation Applications.beginUpdateAccessAndWait + - Removed operation Applications.beginUpdateAndWait + - Removed operation Applications.beginUpdateById + - Removed operation Applications.beginUpdateByIdAndWait + - Removed operation Applications.listAllowedUpgradePlans + - Removed operation Applications.listTokens + - Interface Application no longer has parameter artifacts + - Interface Application no longer has parameter authorizations + - Interface Application no longer has parameter billingDetails + - Interface Application no longer has parameter createdBy + - Interface Application no longer has parameter customerSupport + - Interface Application no longer has parameter jitAccessPolicy + - Interface Application no longer has parameter managementMode + - Interface Application no longer has parameter publisherTenantId + - Interface Application no longer has parameter supportUrls + - Interface Application no longer has parameter updatedBy + - Interface ApplicationDefinition no longer has parameter deploymentPolicy + - Interface ApplicationDefinition no longer has parameter lockingPolicy + - Interface ApplicationDefinition no longer has parameter managementPolicy + - Interface ApplicationDefinition no longer has parameter notificationPolicy + - Interface ApplicationDefinition no longer has parameter policies + - Interface ApplicationDefinition no longer has parameter storageAccountId + - Interface ApplicationPatchable no longer has parameter artifacts + - Interface ApplicationPatchable no longer has parameter authorizations + - Interface ApplicationPatchable no longer has parameter billingDetails + - Interface ApplicationPatchable no longer has parameter createdBy + - Interface ApplicationPatchable no longer has parameter customerSupport + - Interface ApplicationPatchable no longer has parameter jitAccessPolicy + - Interface ApplicationPatchable no longer has parameter managementMode + - Interface ApplicationPatchable no longer has parameter publisherTenantId + - Interface ApplicationPatchable no longer has parameter supportUrls + - Interface ApplicationPatchable no longer has parameter updatedBy + - Interface ApplicationsUpdateByIdOptionalParams no longer has parameter resumeFrom + - Interface ApplicationsUpdateByIdOptionalParams no longer has parameter updateIntervalInMs + - Interface ApplicationsUpdateOptionalParams no longer has parameter resumeFrom + - Interface ApplicationsUpdateOptionalParams no longer has parameter updateIntervalInMs + - Interface ErrorResponse no longer has parameter error + - Interface Identity no longer has parameter userAssignedIdentities + - Interface Operation no longer has parameter actionType + - Interface Operation no longer has parameter isDataAction + - Interface Operation no longer has parameter origin + - Interface OperationDisplay no longer has parameter description + - Interface Resource no longer has parameter systemData + - Parameter managedResourceGroupId of interface Application is now required + - Parameter authorizations of interface ApplicationDefinition is now required + - Type of parameter name of interface ApplicationArtifact is changed from ApplicationArtifactName to string + - Type of parameter artifacts of interface ApplicationDefinition is changed from ApplicationDefinitionArtifact[] to ApplicationArtifact[] + - Type of parameter authorizations of interface ApplicationDefinition is changed from ApplicationAuthorization[] to ApplicationProviderAuthorization[] + - Type of parameter isEnabled of interface ApplicationDefinition is changed from boolean to string + - Type of parameter parameters of interface ApplicationsUpdateByIdOptionalParams is changed from ApplicationPatchable to Application + - Type of parameter type of interface Identity is changed from ResourceIdentityType to "SystemAssigned" + - Class ApplicationClient no longer has parameter jitRequests + - Removed Enum KnownActionType + - Removed Enum KnownApplicationArtifactName + - Removed Enum KnownApplicationDefinitionArtifactName + - Removed Enum KnownApplicationManagementMode + - Removed Enum KnownCreatedByType + - Removed Enum KnownDeploymentMode + - Removed Enum KnownJitApprovalMode + - Removed Enum KnownJitApproverType + - Removed Enum KnownJitRequestState + - Removed Enum KnownJitSchedulingType + - Removed Enum KnownOrigin + - Removed Enum KnownStatus + - Removed Enum KnownSubstatus + - Enum KnownProvisioningState no longer has value NotSpecified + + ## 3.0.0 (2023-09-06) ### Features Added @@ -195,7 +308,7 @@ ## 2.0.1 (2022-04-18) -### Features Added +**features** - Bug fix @@ -207,4 +320,4 @@ To understand the detail of the change, please refer to [Changelog](https://aka. To migrate the existing applications to the latest version, please refer to [Migration Guide](https://aka.ms/js-track2-migration-guide). -To learn more, please refer to our documentation [Quick Start](https://aka.ms/azsdk/js/mgmt/quickstart ). +To learn more, please refer to our documentation [Quick Start](https://aka.ms/azsdk/js/mgmt/quickstart). diff --git a/sdk/managedapplications/arm-managedapplications/LICENSE b/sdk/managedapplications/arm-managedapplications/LICENSE index 3a1d9b6f24f7..7d5934740965 100644 --- a/sdk/managedapplications/arm-managedapplications/LICENSE +++ b/sdk/managedapplications/arm-managedapplications/LICENSE @@ -1,6 +1,6 @@ The MIT License (MIT) -Copyright (c) 2023 Microsoft +Copyright (c) 2024 Microsoft Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal diff --git a/sdk/managedapplications/arm-managedapplications/_meta.json b/sdk/managedapplications/arm-managedapplications/_meta.json index 91d39c38b229..28591836c37e 100644 --- a/sdk/managedapplications/arm-managedapplications/_meta.json +++ b/sdk/managedapplications/arm-managedapplications/_meta.json @@ -1,8 +1,8 @@ { - "commit": "baa82396a21dcc1c79a6aeea185589749515012d", - "readme": "specification/solutions/resource-manager/readme.md", - "autorest_command": "autorest --version=3.9.7 --typescript --modelerfour.lenient-model-deduplication --azure-arm --head-as-boolean=true --license-header=MICROSOFT_MIT_NO_VERSION --generate-test --typescript-sdks-folder=D:\\Git\\azure-sdk-for-js ..\\azure-rest-api-specs\\specification\\solutions\\resource-manager\\readme.md --use=@autorest/typescript@6.0.8 --generate-sample=true", + "commit": "5342edb61d78cec6e07b17a6cd8f7749c6697272", + "readme": "specification/resources/resource-manager/readme.md", + "autorest_command": "autorest --version=3.9.7 --typescript --modelerfour.lenient-model-deduplication --azure-arm --head-as-boolean=true --license-header=MICROSOFT_MIT_NO_VERSION --generate-test --typescript-sdks-folder=/mnt/vss/_work/1/s/azure-sdk-for-js ../azure-rest-api-specs/specification/resources/resource-manager/readme.md --use=@autorest/typescript@^6.0.12", "repository_url": "https://github.com/Azure/azure-rest-api-specs.git", - "release_tool": "@azure-tools/js-sdk-release-tools@2.7.2", - "use": "@autorest/typescript@6.0.8" + "release_tool": "@azure-tools/js-sdk-release-tools@2.7.14", + "use": "@autorest/typescript@^6.0.12" } \ No newline at end of file diff --git a/sdk/managedapplications/arm-managedapplications/package.json b/sdk/managedapplications/arm-managedapplications/package.json index 61807126ac62..532925c7ac35 100644 --- a/sdk/managedapplications/arm-managedapplications/package.json +++ b/sdk/managedapplications/arm-managedapplications/package.json @@ -3,17 +3,17 @@ "sdk-type": "mgmt", "author": "Microsoft Corporation", "description": "A generated SDK for ApplicationClient.", - "version": "3.0.0", + "version": "4.0.0", "engines": { "node": ">=18.0.0" }, "dependencies": { - "@azure/abort-controller": "^1.0.0", - "@azure/core-auth": "^1.3.0", - "@azure/core-client": "^1.7.0", "@azure/core-lro": "^2.5.4", + "@azure/abort-controller": "^2.1.2", "@azure/core-paging": "^1.2.0", - "@azure/core-rest-pipeline": "^1.12.0", + "@azure/core-client": "^1.7.0", + "@azure/core-auth": "^1.6.0", + "@azure/core-rest-pipeline": "^1.14.0", "tslib": "^2.2.0" }, "keywords": [ @@ -28,19 +28,24 @@ "module": "./dist-esm/src/index.js", "types": "./types/arm-managedapplications.d.ts", "devDependencies": { - "@azure-tools/test-credential": "^1.0.0", - "@azure-tools/test-recorder": "^3.0.0", + "@microsoft/api-extractor": "^7.31.1", + "mkdirp": "^3.0.1", + "typescript": "~5.5.3", + "uglify-js": "^3.4.9", + "rimraf": "^5.0.0", + "dotenv": "^16.0.0", "@azure/dev-tool": "^1.0.0", - "@azure/identity": "^4.0.1", - "@types/chai": "^4.2.8", + "@azure/identity": "^4.2.1", + "@azure-tools/test-recorder": "^3.0.0", + "@azure-tools/test-credential": "^1.1.0", + "mocha": "^10.0.0", "@types/mocha": "^10.0.0", - "@types/node": "^18.0.0", + "tsx": "^4.7.1", + "@types/chai": "^4.2.8", "chai": "^4.2.0", "cross-env": "^7.0.2", - "dotenv": "^16.0.0", - "mocha": "^10.0.0", - "ts-node": "^10.0.0", - "typescript": "~5.6.2" + "@types/node": "^18.0.0", + "ts-node": "^10.0.0" }, "repository": { "type": "git", @@ -67,30 +72,29 @@ "types/*" ], "scripts": { - "build": "npm run clean && tsc && dev-tool run bundle && npm run minify && dev-tool run vendored mkdirp ./review && npm run extract-api", - "build:browser": "echo skipped", + "build": "npm run clean && tsc && dev-tool run bundle && npm run minify && mkdirp ./review && npm run extract-api", + "minify": "uglifyjs -c -m --comments --source-map \"content='./dist/index.js.map'\" -o ./dist/index.min.js ./dist/index.js", + "prepack": "npm run build", + "pack": "npm pack 2>&1", + "extract-api": "dev-tool run extract-api", + "lint": "echo skipped", + "clean": "rimraf --glob dist dist-browser dist-esm test-dist temp types *.tgz *.log", "build:node": "echo skipped", - "build:samples": "echo skipped.", + "build:browser": "echo skipped", "build:test": "echo skipped", + "build:samples": "echo skipped.", "check-format": "echo skipped", - "clean": "dev-tool run vendored rimraf --glob dist dist-browser dist-esm test-dist temp types *.tgz *.log", "execute:samples": "echo skipped", - "extract-api": "dev-tool run extract-api", "format": "echo skipped", - "integration-test": "npm run integration-test:node && npm run integration-test:browser", - "integration-test:browser": "echo skipped", - "integration-test:node": "dev-tool run test:node-ts-input -- --timeout 1200000 'test/*.ts'", - "lint": "echo skipped", - "minify": "dev-tool run vendored uglifyjs -c -m --comments --source-map \"content='./dist/index.js.map'\" -o ./dist/index.min.js ./dist/index.js", - "pack": "npm pack 2>&1", - "prepack": "npm run build", "test": "npm run integration-test", - "test:browser": "echo skipped", "test:node": "echo skipped", + "test:browser": "echo skipped", "unit-test": "npm run unit-test:node && npm run unit-test:browser", - "unit-test:browser": "echo skipped", "unit-test:node": "cross-env TEST_MODE=playback npm run integration-test:node", - "update-snippets": "echo skipped" + "unit-test:browser": "echo skipped", + "integration-test": "npm run integration-test:node && npm run integration-test:browser", + "integration-test:node": "dev-tool run test:node-ts-input -- --timeout 1200000 'test/*.ts'", + "integration-test:browser": "echo skipped" }, "sideEffects": false, "//metadata": { @@ -102,13 +106,5 @@ ] }, "autoPublish": true, - "homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/managedapplications/arm-managedapplications", - "//sampleConfiguration": { - "productName": "", - "productSlugs": [ - "azure" - ], - "disableDocsMs": true, - "apiRefLink": "https://docs.microsoft.com/javascript/api/@azure/arm-managedapplications?view=azure-node-preview" - } -} + "homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/managedapplications/arm-managedapplications" +} \ No newline at end of file diff --git a/sdk/managedapplications/arm-managedapplications/review/arm-managedapplications.api.md b/sdk/managedapplications/arm-managedapplications/review/arm-managedapplications.api.md index 1d237eded796..5e482eb6142f 100644 --- a/sdk/managedapplications/arm-managedapplications/review/arm-managedapplications.api.md +++ b/sdk/managedapplications/arm-managedapplications/review/arm-managedapplications.api.md @@ -10,59 +10,26 @@ import { OperationState } from '@azure/core-lro'; import { PagedAsyncIterableIterator } from '@azure/core-paging'; import { SimplePollerLike } from '@azure/core-lro'; -// @public -export type ActionType = string; - -// @public -export interface AllowedUpgradePlansResult { - value?: Plan[]; -} - // @public export interface Application extends GenericResource { applicationDefinitionId?: string; - readonly artifacts?: ApplicationArtifact[]; - readonly authorizations?: ApplicationAuthorization[]; - readonly billingDetails?: ApplicationBillingDetailsDefinition; - readonly createdBy?: ApplicationClientDetails; - readonly customerSupport?: ApplicationPackageContact; - identity?: Identity; - jitAccessPolicy?: ApplicationJitAccessPolicy; kind: string; - managedResourceGroupId?: string; - readonly managementMode?: ApplicationManagementMode; + managedResourceGroupId: string; readonly outputs?: Record; parameters?: Record; plan?: Plan; readonly provisioningState?: ProvisioningState; - readonly publisherTenantId?: string; - readonly supportUrls?: ApplicationPackageSupportUrls; - readonly updatedBy?: ApplicationClientDetails; } // @public export interface ApplicationArtifact { - name: ApplicationArtifactName; - type: ApplicationArtifactType; - uri: string; -} - -// @public -export type ApplicationArtifactName = string; - -// @public -export type ApplicationArtifactType = "NotSpecified" | "Template" | "Custom"; - -// @public -export interface ApplicationAuthorization { - principalId: string; - roleDefinitionId: string; + name?: string; + type?: ApplicationArtifactType; + uri?: string; } // @public -export interface ApplicationBillingDetailsDefinition { - resourceUsageId?: string; -} +export type ApplicationArtifactType = "Template" | "Custom"; // @public (undocumented) export class ApplicationClient extends coreClient.ServiceClient { @@ -76,20 +43,11 @@ export class ApplicationClient extends coreClient.ServiceClient { applicationDefinitions: ApplicationDefinitions; // (undocumented) applications: Applications; - // (undocumented) - jitRequests: JitRequests; listOperations(options?: ListOperationsOptionalParams): PagedAsyncIterableIterator; // (undocumented) subscriptionId?: string; } -// @public -export interface ApplicationClientDetails { - applicationId?: string; - oid?: string; - puid?: string; -} - // @public export interface ApplicationClientOptionalParams extends coreClient.ServiceClientOptions { $host?: string; @@ -99,62 +57,42 @@ export interface ApplicationClientOptionalParams extends coreClient.ServiceClien // @public export interface ApplicationDefinition extends GenericResource { - artifacts?: ApplicationDefinitionArtifact[]; - authorizations?: ApplicationAuthorization[]; + artifacts?: ApplicationArtifact[]; + authorizations: ApplicationProviderAuthorization[]; createUiDefinition?: Record; - deploymentPolicy?: ApplicationDeploymentPolicy; description?: string; displayName?: string; - isEnabled?: boolean; - lockingPolicy?: ApplicationPackageLockingPolicyDefinition; + isEnabled?: string; lockLevel: ApplicationLockLevel; mainTemplate?: Record; - managementPolicy?: ApplicationManagementPolicy; - notificationPolicy?: ApplicationNotificationPolicy; packageFileUri?: string; - policies?: ApplicationPolicy[]; - storageAccountId?: string; } -// @public -export interface ApplicationDefinitionArtifact { - name: ApplicationDefinitionArtifactName; - type: ApplicationArtifactType; - uri: string; -} - -// @public -export type ApplicationDefinitionArtifactName = string; - // @public export interface ApplicationDefinitionListResult { nextLink?: string; value?: ApplicationDefinition[]; } -// @public -export interface ApplicationDefinitionPatchable { - tags?: { - [propertyName: string]: string; - }; -} - // @public export interface ApplicationDefinitions { - createOrUpdate(resourceGroupName: string, applicationDefinitionName: string, parameters: ApplicationDefinition, options?: ApplicationDefinitionsCreateOrUpdateOptionalParams): Promise; - createOrUpdateById(resourceGroupName: string, applicationDefinitionName: string, parameters: ApplicationDefinition, options?: ApplicationDefinitionsCreateOrUpdateByIdOptionalParams): Promise; - delete(resourceGroupName: string, applicationDefinitionName: string, options?: ApplicationDefinitionsDeleteOptionalParams): Promise; - deleteById(resourceGroupName: string, applicationDefinitionName: string, options?: ApplicationDefinitionsDeleteByIdOptionalParams): Promise; + beginCreateOrUpdate(resourceGroupName: string, applicationDefinitionName: string, parameters: ApplicationDefinition, options?: ApplicationDefinitionsCreateOrUpdateOptionalParams): Promise, ApplicationDefinitionsCreateOrUpdateResponse>>; + beginCreateOrUpdateAndWait(resourceGroupName: string, applicationDefinitionName: string, parameters: ApplicationDefinition, options?: ApplicationDefinitionsCreateOrUpdateOptionalParams): Promise; + beginCreateOrUpdateById(resourceGroupName: string, applicationDefinitionName: string, parameters: ApplicationDefinition, options?: ApplicationDefinitionsCreateOrUpdateByIdOptionalParams): Promise, ApplicationDefinitionsCreateOrUpdateByIdResponse>>; + beginCreateOrUpdateByIdAndWait(resourceGroupName: string, applicationDefinitionName: string, parameters: ApplicationDefinition, options?: ApplicationDefinitionsCreateOrUpdateByIdOptionalParams): Promise; + beginDelete(resourceGroupName: string, applicationDefinitionName: string, options?: ApplicationDefinitionsDeleteOptionalParams): Promise, void>>; + beginDeleteAndWait(resourceGroupName: string, applicationDefinitionName: string, options?: ApplicationDefinitionsDeleteOptionalParams): Promise; + beginDeleteById(resourceGroupName: string, applicationDefinitionName: string, options?: ApplicationDefinitionsDeleteByIdOptionalParams): Promise, void>>; + beginDeleteByIdAndWait(resourceGroupName: string, applicationDefinitionName: string, options?: ApplicationDefinitionsDeleteByIdOptionalParams): Promise; get(resourceGroupName: string, applicationDefinitionName: string, options?: ApplicationDefinitionsGetOptionalParams): Promise; getById(resourceGroupName: string, applicationDefinitionName: string, options?: ApplicationDefinitionsGetByIdOptionalParams): Promise; listByResourceGroup(resourceGroupName: string, options?: ApplicationDefinitionsListByResourceGroupOptionalParams): PagedAsyncIterableIterator; - listBySubscription(options?: ApplicationDefinitionsListBySubscriptionOptionalParams): PagedAsyncIterableIterator; - update(resourceGroupName: string, applicationDefinitionName: string, parameters: ApplicationDefinitionPatchable, options?: ApplicationDefinitionsUpdateOptionalParams): Promise; - updateById(resourceGroupName: string, applicationDefinitionName: string, parameters: ApplicationDefinitionPatchable, options?: ApplicationDefinitionsUpdateByIdOptionalParams): Promise; } // @public export interface ApplicationDefinitionsCreateOrUpdateByIdOptionalParams extends coreClient.OperationOptions { + resumeFrom?: string; + updateIntervalInMs?: number; } // @public @@ -162,6 +100,8 @@ export type ApplicationDefinitionsCreateOrUpdateByIdResponse = ApplicationDefini // @public export interface ApplicationDefinitionsCreateOrUpdateOptionalParams extends coreClient.OperationOptions { + resumeFrom?: string; + updateIntervalInMs?: number; } // @public @@ -169,10 +109,14 @@ export type ApplicationDefinitionsCreateOrUpdateResponse = ApplicationDefinition // @public export interface ApplicationDefinitionsDeleteByIdOptionalParams extends coreClient.OperationOptions { + resumeFrom?: string; + updateIntervalInMs?: number; } // @public export interface ApplicationDefinitionsDeleteOptionalParams extends coreClient.OperationOptions { + resumeFrom?: string; + updateIntervalInMs?: number; } // @public @@ -203,47 +147,6 @@ export interface ApplicationDefinitionsListByResourceGroupOptionalParams extends // @public export type ApplicationDefinitionsListByResourceGroupResponse = ApplicationDefinitionListResult; -// @public -export interface ApplicationDefinitionsListBySubscriptionNextOptionalParams extends coreClient.OperationOptions { -} - -// @public -export type ApplicationDefinitionsListBySubscriptionNextResponse = ApplicationDefinitionListResult; - -// @public -export interface ApplicationDefinitionsListBySubscriptionOptionalParams extends coreClient.OperationOptions { -} - -// @public -export type ApplicationDefinitionsListBySubscriptionResponse = ApplicationDefinitionListResult; - -// @public -export interface ApplicationDefinitionsUpdateByIdOptionalParams extends coreClient.OperationOptions { -} - -// @public -export type ApplicationDefinitionsUpdateByIdResponse = ApplicationDefinition; - -// @public -export interface ApplicationDefinitionsUpdateOptionalParams extends coreClient.OperationOptions { -} - -// @public -export type ApplicationDefinitionsUpdateResponse = ApplicationDefinition; - -// @public -export interface ApplicationDeploymentPolicy { - deploymentMode: DeploymentMode; -} - -// @public -export interface ApplicationJitAccessPolicy { - jitAccessEnabled: boolean; - jitApprovalMode?: JitApprovalMode; - jitApprovers?: JitApproverDefinition[]; - maximumJitAccessDuration?: string; -} - // @public export interface ApplicationListResult { nextLink?: string; @@ -253,70 +156,21 @@ export interface ApplicationListResult { // @public export type ApplicationLockLevel = "CanNotDelete" | "ReadOnly" | "None"; -// @public -export type ApplicationManagementMode = string; - -// @public -export interface ApplicationManagementPolicy { - mode?: ApplicationManagementMode; -} - -// @public -export interface ApplicationNotificationEndpoint { - uri: string; -} - -// @public -export interface ApplicationNotificationPolicy { - notificationEndpoints: ApplicationNotificationEndpoint[]; -} - -// @public -export interface ApplicationPackageContact { - contactName?: string; - email: string; - phone: string; -} - -// @public -export interface ApplicationPackageLockingPolicyDefinition { - allowedActions?: string[]; - allowedDataActions?: string[]; -} - -// @public -export interface ApplicationPackageSupportUrls { - governmentCloud?: string; - publicAzure?: string; -} - // @public export interface ApplicationPatchable extends GenericResource { applicationDefinitionId?: string; - readonly artifacts?: ApplicationArtifact[]; - readonly authorizations?: ApplicationAuthorization[]; - readonly billingDetails?: ApplicationBillingDetailsDefinition; - readonly createdBy?: ApplicationClientDetails; - readonly customerSupport?: ApplicationPackageContact; - identity?: Identity; - jitAccessPolicy?: ApplicationJitAccessPolicy; kind?: string; managedResourceGroupId?: string; - readonly managementMode?: ApplicationManagementMode; readonly outputs?: Record; parameters?: Record; plan?: PlanPatchable; readonly provisioningState?: ProvisioningState; - readonly publisherTenantId?: string; - readonly supportUrls?: ApplicationPackageSupportUrls; - readonly updatedBy?: ApplicationClientDetails; } // @public -export interface ApplicationPolicy { - name?: string; - parameters?: string; - policyDefinitionId?: string; +export interface ApplicationProviderAuthorization { + principalId: string; + roleDefinitionId: string; } // @public @@ -329,20 +183,12 @@ export interface Applications { beginDeleteAndWait(resourceGroupName: string, applicationName: string, options?: ApplicationsDeleteOptionalParams): Promise; beginDeleteById(applicationId: string, options?: ApplicationsDeleteByIdOptionalParams): Promise, void>>; beginDeleteByIdAndWait(applicationId: string, options?: ApplicationsDeleteByIdOptionalParams): Promise; - beginRefreshPermissions(resourceGroupName: string, applicationName: string, options?: ApplicationsRefreshPermissionsOptionalParams): Promise, void>>; - beginRefreshPermissionsAndWait(resourceGroupName: string, applicationName: string, options?: ApplicationsRefreshPermissionsOptionalParams): Promise; - beginUpdate(resourceGroupName: string, applicationName: string, options?: ApplicationsUpdateOptionalParams): Promise, ApplicationsUpdateResponse>>; - beginUpdateAccess(resourceGroupName: string, applicationName: string, parameters: UpdateAccessDefinition, options?: ApplicationsUpdateAccessOptionalParams): Promise, void>>; - beginUpdateAccessAndWait(resourceGroupName: string, applicationName: string, parameters: UpdateAccessDefinition, options?: ApplicationsUpdateAccessOptionalParams): Promise; - beginUpdateAndWait(resourceGroupName: string, applicationName: string, options?: ApplicationsUpdateOptionalParams): Promise; - beginUpdateById(applicationId: string, options?: ApplicationsUpdateByIdOptionalParams): Promise, ApplicationsUpdateByIdResponse>>; - beginUpdateByIdAndWait(applicationId: string, options?: ApplicationsUpdateByIdOptionalParams): Promise; get(resourceGroupName: string, applicationName: string, options?: ApplicationsGetOptionalParams): Promise; getById(applicationId: string, options?: ApplicationsGetByIdOptionalParams): Promise; - listAllowedUpgradePlans(resourceGroupName: string, applicationName: string, options?: ApplicationsListAllowedUpgradePlansOptionalParams): Promise; listByResourceGroup(resourceGroupName: string, options?: ApplicationsListByResourceGroupOptionalParams): PagedAsyncIterableIterator; listBySubscription(options?: ApplicationsListBySubscriptionOptionalParams): PagedAsyncIterableIterator; - listTokens(resourceGroupName: string, applicationName: string, parameters: ListTokenRequest, options?: ApplicationsListTokensOptionalParams): Promise; + update(resourceGroupName: string, applicationName: string, options?: ApplicationsUpdateOptionalParams): Promise; + updateById(applicationId: string, options?: ApplicationsUpdateByIdOptionalParams): Promise; } // @public @@ -389,13 +235,6 @@ export interface ApplicationsGetOptionalParams extends coreClient.OperationOptio // @public export type ApplicationsGetResponse = Application; -// @public -export interface ApplicationsListAllowedUpgradePlansOptionalParams extends coreClient.OperationOptions { -} - -// @public -export type ApplicationsListAllowedUpgradePlansResponse = AllowedUpgradePlansResult; - // @public export interface ApplicationsListByResourceGroupNextOptionalParams extends coreClient.OperationOptions { } @@ -424,73 +263,32 @@ export interface ApplicationsListBySubscriptionOptionalParams extends coreClient // @public export type ApplicationsListBySubscriptionResponse = ApplicationListResult; -// @public -export interface ApplicationsListTokensOptionalParams extends coreClient.OperationOptions { -} - -// @public -export type ApplicationsListTokensResponse = ManagedIdentityTokenResult; - -// @public -export interface ApplicationsRefreshPermissionsOptionalParams extends coreClient.OperationOptions { - resumeFrom?: string; - updateIntervalInMs?: number; -} - -// @public -export interface ApplicationsUpdateAccessOptionalParams extends coreClient.OperationOptions { - resumeFrom?: string; - updateIntervalInMs?: number; -} - // @public export interface ApplicationsUpdateByIdOptionalParams extends coreClient.OperationOptions { - parameters?: ApplicationPatchable; - resumeFrom?: string; - updateIntervalInMs?: number; + parameters?: Application; } // @public -export type ApplicationsUpdateByIdResponse = ApplicationPatchable; +export type ApplicationsUpdateByIdResponse = Application; // @public export interface ApplicationsUpdateOptionalParams extends coreClient.OperationOptions { parameters?: ApplicationPatchable; - resumeFrom?: string; - updateIntervalInMs?: number; -} - -// @public -export type ApplicationsUpdateResponse = ApplicationPatchable; - -// @public -export type CreatedByType = string; - -// @public -export type DeploymentMode = string; - -// @public -export interface ErrorAdditionalInfo { - readonly info?: Record; - readonly type?: string; } // @public -export interface ErrorDetail { - readonly additionalInfo?: ErrorAdditionalInfo[]; - readonly code?: string; - readonly details?: ErrorDetail[]; - readonly message?: string; - readonly target?: string; -} +export type ApplicationsUpdateResponse = Application; // @public export interface ErrorResponse { - error?: ErrorDetail; + errorCode?: string; + errorMessage?: string; + httpStatus?: string; } // @public export interface GenericResource extends Resource { + identity?: Identity; managedBy?: string; sku?: Sku; } @@ -502,241 +300,24 @@ export function getContinuationToken(page: unknown): string | undefined; export interface Identity { readonly principalId?: string; readonly tenantId?: string; - type?: ResourceIdentityType; - userAssignedIdentities?: { - [propertyName: string]: UserAssignedResourceIdentity; - }; -} - -// @public -export type JitApprovalMode = string; - -// @public -export interface JitApproverDefinition { - displayName?: string; - id: string; - type?: JitApproverType; -} - -// @public -export type JitApproverType = string; - -// @public -export interface JitAuthorizationPolicies { - principalId: string; - roleDefinitionId: string; -} - -// @public -export interface JitRequestDefinition extends Resource { - applicationResourceId?: string; - readonly createdBy?: ApplicationClientDetails; - jitAuthorizationPolicies?: JitAuthorizationPolicies[]; - readonly jitRequestState?: JitRequestState; - jitSchedulingPolicy?: JitSchedulingPolicy; - readonly provisioningState?: ProvisioningState; - readonly publisherTenantId?: string; - readonly updatedBy?: ApplicationClientDetails; -} - -// @public -export interface JitRequestDefinitionListResult { - nextLink?: string; - value?: JitRequestDefinition[]; -} - -// @public -export interface JitRequestMetadata { - originRequestId?: string; - requestorId?: string; - subjectDisplayName?: string; - tenantDisplayName?: string; -} - -// @public -export interface JitRequestPatchable { - tags?: { - [propertyName: string]: string; - }; -} - -// @public -export interface JitRequests { - beginCreateOrUpdate(resourceGroupName: string, jitRequestName: string, parameters: JitRequestDefinition, options?: JitRequestsCreateOrUpdateOptionalParams): Promise, JitRequestsCreateOrUpdateResponse>>; - beginCreateOrUpdateAndWait(resourceGroupName: string, jitRequestName: string, parameters: JitRequestDefinition, options?: JitRequestsCreateOrUpdateOptionalParams): Promise; - delete(resourceGroupName: string, jitRequestName: string, options?: JitRequestsDeleteOptionalParams): Promise; - get(resourceGroupName: string, jitRequestName: string, options?: JitRequestsGetOptionalParams): Promise; - listByResourceGroup(resourceGroupName: string, options?: JitRequestsListByResourceGroupOptionalParams): Promise; - listBySubscription(options?: JitRequestsListBySubscriptionOptionalParams): Promise; - update(resourceGroupName: string, jitRequestName: string, parameters: JitRequestPatchable, options?: JitRequestsUpdateOptionalParams): Promise; -} - -// @public -export interface JitRequestsCreateOrUpdateOptionalParams extends coreClient.OperationOptions { - resumeFrom?: string; - updateIntervalInMs?: number; -} - -// @public -export type JitRequestsCreateOrUpdateResponse = JitRequestDefinition; - -// @public -export interface JitRequestsDeleteOptionalParams extends coreClient.OperationOptions { -} - -// @public -export interface JitRequestsGetOptionalParams extends coreClient.OperationOptions { -} - -// @public -export type JitRequestsGetResponse = JitRequestDefinition; - -// @public -export interface JitRequestsListByResourceGroupOptionalParams extends coreClient.OperationOptions { -} - -// @public -export type JitRequestsListByResourceGroupResponse = JitRequestDefinitionListResult; - -// @public -export interface JitRequestsListBySubscriptionOptionalParams extends coreClient.OperationOptions { -} - -// @public -export type JitRequestsListBySubscriptionResponse = JitRequestDefinitionListResult; - -// @public -export type JitRequestState = string; - -// @public -export interface JitRequestsUpdateOptionalParams extends coreClient.OperationOptions { -} - -// @public -export type JitRequestsUpdateResponse = JitRequestDefinition; - -// @public -export interface JitSchedulingPolicy { - duration: string; - startTime: Date; - type: JitSchedulingType; -} - -// @public -export type JitSchedulingType = string; - -// @public -export enum KnownActionType { - Internal = "Internal" -} - -// @public -export enum KnownApplicationArtifactName { - Authorizations = "Authorizations", - CustomRoleDefinition = "CustomRoleDefinition", - NotSpecified = "NotSpecified", - ViewDefinition = "ViewDefinition" -} - -// @public -export enum KnownApplicationDefinitionArtifactName { - ApplicationResourceTemplate = "ApplicationResourceTemplate", - CreateUiDefinition = "CreateUiDefinition", - MainTemplateParameters = "MainTemplateParameters", - NotSpecified = "NotSpecified" -} - -// @public -export enum KnownApplicationManagementMode { - Managed = "Managed", - NotSpecified = "NotSpecified", - Unmanaged = "Unmanaged" -} - -// @public -export enum KnownCreatedByType { - Application = "Application", - Key = "Key", - ManagedIdentity = "ManagedIdentity", - User = "User" -} - -// @public -export enum KnownDeploymentMode { - Complete = "Complete", - Incremental = "Incremental", - NotSpecified = "NotSpecified" -} - -// @public -export enum KnownJitApprovalMode { - AutoApprove = "AutoApprove", - ManualApprove = "ManualApprove", - NotSpecified = "NotSpecified" -} - -// @public -export enum KnownJitApproverType { - Group = "group", - User = "user" -} - -// @public -export enum KnownJitRequestState { - Approved = "Approved", - Canceled = "Canceled", - Denied = "Denied", - Expired = "Expired", - Failed = "Failed", - NotSpecified = "NotSpecified", - Pending = "Pending", - Timeout = "Timeout" -} - -// @public -export enum KnownJitSchedulingType { - NotSpecified = "NotSpecified", - Once = "Once", - Recurring = "Recurring" -} - -// @public -export enum KnownOrigin { - System = "system", - User = "user", - UserSystem = "user,system" + type?: "SystemAssigned"; } // @public export enum KnownProvisioningState { Accepted = "Accepted", Canceled = "Canceled", + Created = "Created", + Creating = "Creating", Deleted = "Deleted", Deleting = "Deleting", Failed = "Failed", - NotSpecified = "NotSpecified", + Ready = "Ready", Running = "Running", Succeeded = "Succeeded", Updating = "Updating" } -// @public -export enum KnownStatus { - Elevate = "Elevate", - NotSpecified = "NotSpecified", - Remove = "Remove" -} - -// @public -export enum KnownSubstatus { - Approved = "Approved", - Denied = "Denied", - Expired = "Expired", - Failed = "Failed", - NotSpecified = "NotSpecified", - Timeout = "Timeout" -} - // @public export interface ListOperationsNextOptionalParams extends coreClient.OperationOptions { } @@ -751,54 +332,25 @@ export interface ListOperationsOptionalParams extends coreClient.OperationOption // @public export type ListOperationsResponse = OperationListResult; -// @public -export interface ListTokenRequest { - authorizationAudience?: string; - userAssignedIdentities?: string[]; -} - -// @public -export interface ManagedIdentityToken { - accessToken?: string; - authorizationAudience?: string; - expiresIn?: string; - expiresOn?: string; - notBefore?: string; - resourceId?: string; - tokenType?: string; -} - -// @public -export interface ManagedIdentityTokenResult { - value?: ManagedIdentityToken[]; -} - // @public export interface Operation { - readonly actionType?: ActionType; display?: OperationDisplay; - readonly isDataAction?: boolean; - readonly name?: string; - readonly origin?: Origin; + name?: string; } // @public export interface OperationDisplay { - readonly description?: string; - readonly operation?: string; - readonly provider?: string; - readonly resource?: string; + operation?: string; + provider?: string; + resource?: string; } // @public export interface OperationListResult { - readonly nextLink?: string; - readonly value?: Operation[]; + nextLink?: string; + value?: Operation[]; } -// @public -export type Origin = string; - // @public export interface Plan { name: string; @@ -825,16 +377,12 @@ export interface Resource { readonly id?: string; location?: string; readonly name?: string; - readonly systemData?: SystemData; tags?: { [propertyName: string]: string; }; readonly type?: string; } -// @public -export type ResourceIdentityType = "SystemAssigned" | "UserAssigned" | "SystemAssigned, UserAssigned" | "None"; - // @public export interface Sku { capacity?: number; @@ -845,36 +393,6 @@ export interface Sku { tier?: string; } -// @public -export type Status = string; - -// @public -export type Substatus = string; - -// @public -export interface SystemData { - createdAt?: Date; - createdBy?: string; - createdByType?: CreatedByType; - lastModifiedAt?: Date; - lastModifiedBy?: string; - lastModifiedByType?: CreatedByType; -} - -// @public -export interface UpdateAccessDefinition { - approver?: string; - metadata: JitRequestMetadata; - status: Status; - subStatus: Substatus; -} - -// @public -export interface UserAssignedResourceIdentity { - readonly principalId?: string; - readonly tenantId?: string; -} - // (No @packageDocumentation comment for this package) ``` diff --git a/sdk/managedapplications/arm-managedapplications/src/applicationClient.ts b/sdk/managedapplications/arm-managedapplications/src/applicationClient.ts index 1f70f932a088..f19fb0c0accf 100644 --- a/sdk/managedapplications/arm-managedapplications/src/applicationClient.ts +++ b/sdk/managedapplications/arm-managedapplications/src/applicationClient.ts @@ -11,21 +11,13 @@ import * as coreRestPipeline from "@azure/core-rest-pipeline"; import { PipelineRequest, PipelineResponse, - SendRequest + SendRequest, } from "@azure/core-rest-pipeline"; import * as coreAuth from "@azure/core-auth"; import { PagedAsyncIterableIterator, PageSettings } from "@azure/core-paging"; import { setContinuationToken } from "./pagingHelper"; -import { - ApplicationsImpl, - ApplicationDefinitionsImpl, - JitRequestsImpl -} from "./operations"; -import { - Applications, - ApplicationDefinitions, - JitRequests -} from "./operationsInterfaces"; +import { ApplicationsImpl, ApplicationDefinitionsImpl } from "./operations"; +import { Applications, ApplicationDefinitions } from "./operationsInterfaces"; import * as Parameters from "./models/parameters"; import * as Mappers from "./models/mappers"; import { @@ -34,7 +26,7 @@ import { ListOperationsNextOptionalParams, ListOperationsOptionalParams, ListOperationsResponse, - ListOperationsNextResponse + ListOperationsNextResponse, } from "./models"; /// @@ -52,16 +44,16 @@ export class ApplicationClient extends coreClient.ServiceClient { constructor( credentials: coreAuth.TokenCredential, subscriptionId: string, - options?: ApplicationClientOptionalParams + options?: ApplicationClientOptionalParams, ); constructor( credentials: coreAuth.TokenCredential, - options?: ApplicationClientOptionalParams + options?: ApplicationClientOptionalParams, ); constructor( credentials: coreAuth.TokenCredential, subscriptionIdOrOptions?: ApplicationClientOptionalParams | string, - options?: ApplicationClientOptionalParams + options?: ApplicationClientOptionalParams, ) { if (credentials === undefined) { throw new Error("'credentials' cannot be null"); @@ -81,10 +73,10 @@ export class ApplicationClient extends coreClient.ServiceClient { } const defaults: ApplicationClientOptionalParams = { requestContentType: "application/json; charset=utf-8", - credential: credentials + credential: credentials, }; - const packageDetails = `azsdk-js-arm-managedapplications/3.0.0`; + const packageDetails = `azsdk-js-arm-managedapplications/4.0.0`; const userAgentPrefix = options.userAgentOptions && options.userAgentOptions.userAgentPrefix ? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}` @@ -94,20 +86,21 @@ export class ApplicationClient extends coreClient.ServiceClient { ...defaults, ...options, userAgentOptions: { - userAgentPrefix + userAgentPrefix, }, endpoint: - options.endpoint ?? options.baseUri ?? "https://management.azure.com" + options.endpoint ?? options.baseUri ?? "https://management.azure.com", }; super(optionsWithDefaults); let bearerTokenAuthenticationPolicyFound: boolean = false; if (options?.pipeline && options.pipeline.getOrderedPolicies().length > 0) { - const pipelinePolicies: coreRestPipeline.PipelinePolicy[] = options.pipeline.getOrderedPolicies(); + const pipelinePolicies: coreRestPipeline.PipelinePolicy[] = + options.pipeline.getOrderedPolicies(); bearerTokenAuthenticationPolicyFound = pipelinePolicies.some( (pipelinePolicy) => pipelinePolicy.name === - coreRestPipeline.bearerTokenAuthenticationPolicyName + coreRestPipeline.bearerTokenAuthenticationPolicyName, ); } if ( @@ -117,7 +110,7 @@ export class ApplicationClient extends coreClient.ServiceClient { !bearerTokenAuthenticationPolicyFound ) { this.pipeline.removePolicy({ - name: coreRestPipeline.bearerTokenAuthenticationPolicyName + name: coreRestPipeline.bearerTokenAuthenticationPolicyName, }); this.pipeline.addPolicy( coreRestPipeline.bearerTokenAuthenticationPolicy({ @@ -127,9 +120,9 @@ export class ApplicationClient extends coreClient.ServiceClient { `${optionsWithDefaults.endpoint}/.default`, challengeCallbacks: { authorizeRequestOnChallenge: - coreClient.authorizeRequestOnClaimChallenge - } - }) + coreClient.authorizeRequestOnClaimChallenge, + }, + }), ); } // Parameter assignments @@ -137,10 +130,9 @@ export class ApplicationClient extends coreClient.ServiceClient { // Assigning values to Constant parameters this.$host = options.$host || "https://management.azure.com"; - this.apiVersion = options.apiVersion || "2021-07-01"; + this.apiVersion = options.apiVersion || "2018-06-01"; this.applications = new ApplicationsImpl(this); this.applicationDefinitions = new ApplicationDefinitionsImpl(this); - this.jitRequests = new JitRequestsImpl(this); this.addCustomApiVersionPolicy(options.apiVersion); } @@ -153,7 +145,7 @@ export class ApplicationClient extends coreClient.ServiceClient { name: "CustomApiVersionPolicy", async sendRequest( request: PipelineRequest, - next: SendRequest + next: SendRequest, ): Promise { const param = request.url.split("?"); if (param.length > 1) { @@ -167,7 +159,7 @@ export class ApplicationClient extends coreClient.ServiceClient { request.url = param[0] + "?" + newParams.join("&"); } return next(request); - } + }, }; this.pipeline.addPolicy(apiVersionPolicy); } @@ -177,7 +169,7 @@ export class ApplicationClient extends coreClient.ServiceClient { * @param options The options parameters. */ public listOperations( - options?: ListOperationsOptionalParams + options?: ListOperationsOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listOperationsPagingAll(options); return { @@ -192,13 +184,13 @@ export class ApplicationClient extends coreClient.ServiceClient { throw new Error("maxPageSize is not supported by this operation."); } return this.listOperationsPagingPage(options, settings); - } + }, }; } private async *listOperationsPagingPage( options?: ListOperationsOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: ListOperationsResponse; let continuationToken = settings?.continuationToken; @@ -219,7 +211,7 @@ export class ApplicationClient extends coreClient.ServiceClient { } private async *listOperationsPagingAll( - options?: ListOperationsOptionalParams + options?: ListOperationsOptionalParams, ): AsyncIterableIterator { for await (const page of this.listOperationsPagingPage(options)) { yield* page; @@ -231,7 +223,7 @@ export class ApplicationClient extends coreClient.ServiceClient { * @param options The options parameters. */ private _listOperations( - options?: ListOperationsOptionalParams + options?: ListOperationsOptionalParams, ): Promise { return this.sendOperationRequest({ options }, listOperationsOperationSpec); } @@ -243,17 +235,16 @@ export class ApplicationClient extends coreClient.ServiceClient { */ private _listOperationsNext( nextLink: string, - options?: ListOperationsNextOptionalParams + options?: ListOperationsNextOptionalParams, ): Promise { return this.sendOperationRequest( { nextLink, options }, - listOperationsNextOperationSpec + listOperationsNextOperationSpec, ); } applications: Applications; applicationDefinitions: ApplicationDefinitions; - jitRequests: JitRequests; } // Operation Specifications const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); @@ -263,29 +254,23 @@ const listOperationsOperationSpec: coreClient.OperationSpec = { httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.OperationListResult + bodyMapper: Mappers.OperationListResult, }, - default: { - bodyMapper: Mappers.ErrorResponse - } }, queryParameters: [Parameters.apiVersion], urlParameters: [Parameters.$host], headerParameters: [Parameters.accept], - serializer + serializer, }; const listOperationsNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.OperationListResult + bodyMapper: Mappers.OperationListResult, }, - default: { - bodyMapper: Mappers.ErrorResponse - } }, urlParameters: [Parameters.$host, Parameters.nextLink], headerParameters: [Parameters.accept], - serializer + serializer, }; diff --git a/sdk/managedapplications/arm-managedapplications/src/lroImpl.ts b/sdk/managedapplications/arm-managedapplications/src/lroImpl.ts index 52f6eaacfb83..5f88efab981b 100644 --- a/sdk/managedapplications/arm-managedapplications/src/lroImpl.ts +++ b/sdk/managedapplications/arm-managedapplications/src/lroImpl.ts @@ -28,15 +28,15 @@ export function createLroSpec(inputs: { sendInitialRequest: () => sendOperationFn(args, spec), sendPollRequest: ( path: string, - options?: { abortSignal?: AbortSignalLike } + options?: { abortSignal?: AbortSignalLike }, ) => { const { requestBody, ...restSpec } = spec; return sendOperationFn(args, { ...restSpec, httpMethod: "GET", path, - abortSignal: options?.abortSignal + abortSignal: options?.abortSignal, }); - } + }, }; } diff --git a/sdk/managedapplications/arm-managedapplications/src/models/index.ts b/sdk/managedapplications/arm-managedapplications/src/models/index.ts index 0882498520ef..c0cd856834c9 100644 --- a/sdk/managedapplications/arm-managedapplications/src/models/index.ts +++ b/sdk/managedapplications/arm-managedapplications/src/models/index.ts @@ -8,191 +8,30 @@ import * as coreClient from "@azure/core-client"; -/** A list of REST API operations supported by an Azure Resource Provider. It contains an URL link to get the next set of results. */ +/** Result of the request to list Microsoft.Solutions operations. It contains a list of operations and a URL link to get the next set of results. */ export interface OperationListResult { - /** - * List of operations supported by the resource provider - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly value?: Operation[]; - /** - * URL to get the next set of operation list results (if there are any). - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly nextLink?: string; + /** List of Microsoft.Solutions operations. */ + value?: Operation[]; + /** URL to get the next set of operation list results if there are any. */ + nextLink?: string; } -/** Details of a REST API operation, returned from the Resource Provider Operations API */ +/** Microsoft.Solutions operation */ export interface Operation { - /** - * The name of the operation, as per Resource-Based Access Control (RBAC). Examples: "Microsoft.Compute/virtualMachines/write", "Microsoft.Compute/virtualMachines/capture/action" - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly name?: string; - /** - * Whether the operation applies to data-plane. This is "true" for data-plane operations and "false" for ARM/control-plane operations. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly isDataAction?: boolean; - /** Localized display information for this particular operation. */ + /** Operation name: {provider}/{resource}/{operation} */ + name?: string; + /** The object that represents the operation. */ display?: OperationDisplay; - /** - * The intended executor of the operation; as in Resource Based Access Control (RBAC) and audit logs UX. Default value is "user,system" - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly origin?: Origin; - /** - * Enum. Indicates the action type. "Internal" refers to actions that are for internal only APIs. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly actionType?: ActionType; } -/** Localized display information for this particular operation. */ +/** The object that represents the operation. */ export interface OperationDisplay { - /** - * The localized friendly form of the resource provider name, e.g. "Microsoft Monitoring Insights" or "Microsoft Compute". - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly provider?: string; - /** - * The localized friendly name of the resource type related to this operation. E.g. "Virtual Machines" or "Job Schedule Collections". - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly resource?: string; - /** - * The concise, localized friendly name for the operation; suitable for dropdowns. E.g. "Create or Update Virtual Machine", "Restart Virtual Machine". - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly operation?: string; - /** - * The short, localized friendly description of the operation; suitable for tool tips and detailed views. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly description?: string; -} - -/** Common error response for all Azure Resource Manager APIs to return error details for failed operations. (This also follows the OData error response format.). */ -export interface ErrorResponse { - /** The error object. */ - error?: ErrorDetail; -} - -/** The error detail. */ -export interface ErrorDetail { - /** - * The error code. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly code?: string; - /** - * The error message. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly message?: string; - /** - * The error target. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly target?: string; - /** - * The error details. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly details?: ErrorDetail[]; - /** - * The error additional info. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly additionalInfo?: ErrorAdditionalInfo[]; -} - -/** The resource management error additional info. */ -export interface ErrorAdditionalInfo { - /** - * The additional info type. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly type?: string; - /** - * The additional info. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly info?: Record; -} - -/** Managed application billing details definition. */ -export interface ApplicationBillingDetailsDefinition { - /** The managed application resource usage Id. */ - resourceUsageId?: string; -} - -/** Managed application Jit access policy. */ -export interface ApplicationJitAccessPolicy { - /** Whether the JIT access is enabled. */ - jitAccessEnabled: boolean; - /** JIT approval mode. */ - jitApprovalMode?: JitApprovalMode; - /** The JIT approvers */ - jitApprovers?: JitApproverDefinition[]; - /** The maximum duration JIT access is granted. This is an ISO8601 time period value. */ - maximumJitAccessDuration?: string; -} - -/** JIT approver definition. */ -export interface JitApproverDefinition { - /** The approver service principal Id. */ - id: string; - /** The approver type. */ - type?: JitApproverType; - /** The approver display name. */ - displayName?: string; -} - -/** The managed application provider authorization. */ -export interface ApplicationAuthorization { - /** The provider's principal identifier. This is the identity that the provider will use to call ARM to manage the managed application resources. */ - principalId: string; - /** The provider's role definition identifier. This role will define all the permissions that the provider must have on the managed application's container resource group. This role definition cannot have permission to delete the resource group. */ - roleDefinitionId: string; -} - -/** The application package contact information. */ -export interface ApplicationPackageContact { - /** The contact name. */ - contactName?: string; - /** The contact email. */ - email: string; - /** The contact phone number. */ - phone: string; -} - -/** The appliance package support URLs. */ -export interface ApplicationPackageSupportUrls { - /** The public azure support URL. */ - publicAzure?: string; - /** The government cloud support URL. */ - governmentCloud?: string; -} - -/** Managed application artifact. */ -export interface ApplicationArtifact { - /** The managed application artifact name. */ - name: ApplicationArtifactName; - /** The managed application artifact blob uri. */ - uri: string; - /** The managed application artifact type. */ - type: ApplicationArtifactType; -} - -/** The application client details to track the entity creating/updating the managed app resource. */ -export interface ApplicationClientDetails { - /** The client Oid. */ - oid?: string; - /** The client Puid */ - puid?: string; - /** The client application Id. */ - applicationId?: string; + /** Service provider: Microsoft.Solutions */ + provider?: string; + /** Resource on which the operation is performed: Application, JitRequest, etc. */ + resource?: string; + /** Operation type: Read, write, delete, etc. */ + operation?: string; } /** Plan for the managed application. */ @@ -209,40 +48,6 @@ export interface Plan { version: string; } -/** Identity for the resource. */ -export interface Identity { - /** - * The principal ID of resource identity. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly principalId?: string; - /** - * The tenant ID of resource. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly tenantId?: string; - /** The identity type. */ - type?: ResourceIdentityType; - /** The list of user identities associated with the resource. The user identity dictionary key references will be resource ids in the form: '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{identityName}'. */ - userAssignedIdentities?: { - [propertyName: string]: UserAssignedResourceIdentity; - }; -} - -/** Represents the user assigned identity that is contained within the UserAssignedIdentities dictionary on ResourceIdentity */ -export interface UserAssignedResourceIdentity { - /** - * The principal id of user assigned identity. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly principalId?: string; - /** - * The tenant id of user assigned identity. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly tenantId?: string; -} - /** SKU for the resource. */ export interface Sku { /** The SKU name. */ @@ -259,6 +64,22 @@ export interface Sku { capacity?: number; } +/** Identity for the resource. */ +export interface Identity { + /** + * The principal ID of resource identity. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly principalId?: string; + /** + * The tenant ID of resource. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly tenantId?: string; + /** The identity type. */ + type?: "SystemAssigned"; +} + /** Resource information. */ export interface Resource { /** @@ -280,27 +101,16 @@ export interface Resource { location?: string; /** Resource tags */ tags?: { [propertyName: string]: string }; - /** - * Metadata pertaining to creation and last modification of the resource. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly systemData?: SystemData; } -/** Metadata pertaining to creation and last modification of the resource. */ -export interface SystemData { - /** The identity that created the resource. */ - createdBy?: string; - /** The type of identity that created the resource. */ - createdByType?: CreatedByType; - /** The timestamp of resource creation (UTC). */ - createdAt?: Date; - /** The identity that last modified the resource. */ - lastModifiedBy?: string; - /** The type of identity that last modified the resource. */ - lastModifiedByType?: CreatedByType; - /** The timestamp of resource last modification (UTC) */ - lastModifiedAt?: Date; +/** Error response indicates managed application is not able to process the incoming request. The reason is provided in the error message. */ +export interface ErrorResponse { + /** Http status code. */ + httpStatus?: string; + /** Error code. */ + errorCode?: string; + /** Error message indicating why the operation failed. */ + errorMessage?: string; } /** Plan for the managed application. */ @@ -317,62 +127,22 @@ export interface PlanPatchable { version?: string; } -/** Application definition artifact. */ -export interface ApplicationDefinitionArtifact { - /** The managed application definition artifact name. */ - name: ApplicationDefinitionArtifactName; - /** The managed application definition artifact blob uri. */ - uri: string; - /** The managed application definition artifact type. */ - type: ApplicationArtifactType; -} - -/** Managed application notification policy. */ -export interface ApplicationNotificationPolicy { - /** The managed application notification endpoint. */ - notificationEndpoints: ApplicationNotificationEndpoint[]; -} - -/** Managed application notification endpoint. */ -export interface ApplicationNotificationEndpoint { - /** The managed application notification endpoint uri. */ - uri: string; -} - -/** Managed application locking policy. */ -export interface ApplicationPackageLockingPolicyDefinition { - /** The deny assignment excluded actions. */ - allowedActions?: string[]; - /** The deny assignment excluded data actions. */ - allowedDataActions?: string[]; -} - -/** Managed application deployment policy. */ -export interface ApplicationDeploymentPolicy { - /** The managed application deployment mode. */ - deploymentMode: DeploymentMode; -} - -/** Managed application management policy. */ -export interface ApplicationManagementPolicy { - /** The managed application management mode. */ - mode?: ApplicationManagementMode; +/** The managed application provider authorization. */ +export interface ApplicationProviderAuthorization { + /** The provider's principal identifier. This is the identity that the provider will use to call ARM to manage the managed application resources. */ + principalId: string; + /** The provider's role definition identifier. This role will define all the permissions that the provider must have on the managed application's container resource group. This role definition cannot have permission to delete the resource group. */ + roleDefinitionId: string; } -/** Managed application policy. */ -export interface ApplicationPolicy { - /** The policy name */ +/** Managed application artifact. */ +export interface ApplicationArtifact { + /** The managed application artifact name. */ name?: string; - /** The policy definition Id. */ - policyDefinitionId?: string; - /** The policy parameters. */ - parameters?: string; -} - -/** Information about an application definition request. */ -export interface ApplicationDefinitionPatchable { - /** Application definition tags */ - tags?: { [propertyName: string]: string }; + /** The managed application artifact blob uri. */ + uri?: string; + /** The managed application artifact type. */ + type?: ApplicationArtifactType; } /** List of managed application definitions. */ @@ -391,141 +161,14 @@ export interface ApplicationListResult { nextLink?: string; } -/** The JIT authorization policies. */ -export interface JitAuthorizationPolicies { - /** The the principal id that will be granted JIT access. */ - principalId: string; - /** The role definition id that will be granted to the Principal. */ - roleDefinitionId: string; -} - -/** The JIT scheduling policies. */ -export interface JitSchedulingPolicy { - /** The type of JIT schedule. */ - type: JitSchedulingType; - /** The required duration of the JIT request. */ - duration: string; - /** The start time of the request. */ - startTime: Date; -} - -/** Information about JIT request. */ -export interface JitRequestPatchable { - /** Jit request tags */ - tags?: { [propertyName: string]: string }; -} - -/** List of JIT requests. */ -export interface JitRequestDefinitionListResult { - /** The array of Jit request definition. */ - value?: JitRequestDefinition[]; - /** The URL to use for getting the next set of results. */ - nextLink?: string; -} - -/** The array of plan. */ -export interface AllowedUpgradePlansResult { - /** The array of plans. */ - value?: Plan[]; -} - -/** Update access request definition. */ -export interface UpdateAccessDefinition { - /** The approver name. */ - approver?: string; - /** The JIT request metadata. */ - metadata: JitRequestMetadata; - /** The JIT status. */ - status: Status; - /** The JIT status. */ - subStatus: Substatus; -} - -/** The JIT request metadata. */ -export interface JitRequestMetadata { - /** The origin request id. */ - originRequestId?: string; - /** The requestor id. */ - requestorId?: string; - /** The publisher's tenant name. */ - tenantDisplayName?: string; - /** The subject display name. */ - subjectDisplayName?: string; -} - -/** List token request body. */ -export interface ListTokenRequest { - /** The authorization audience. */ - authorizationAudience?: string; - /** The user assigned identities. */ - userAssignedIdentities?: string[]; -} - -/** The array of managed identity tokens. */ -export interface ManagedIdentityTokenResult { - /** The array of managed identity tokens. */ - value?: ManagedIdentityToken[]; -} - -/** The managed identity token for the managed app resource. */ -export interface ManagedIdentityToken { - /** The requested access token. */ - accessToken?: string; - /** The number of seconds the access token will be valid. */ - expiresIn?: string; - /** The timespan when the access token expires. This is represented as the number of seconds from epoch. */ - expiresOn?: string; - /** The timespan when the access token takes effect. This is represented as the number of seconds from epoch. */ - notBefore?: string; - /** The aud (audience) the access token was request for. This is the same as what was provided in the listTokens request. */ - authorizationAudience?: string; - /** The Azure resource ID for the issued token. This is either the managed application ID or the user-assigned identity ID. */ - resourceId?: string; - /** The type of the token. */ - tokenType?: string; -} - /** Resource information. */ export interface GenericResource extends Resource { /** ID of the resource that manages this resource. */ managedBy?: string; /** The SKU of the resource. */ sku?: Sku; -} - -/** Information about JIT request definition. */ -export interface JitRequestDefinition extends Resource { - /** The parent application id. */ - applicationResourceId?: string; - /** - * The publisher tenant id. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly publisherTenantId?: string; - /** The JIT authorization policies. */ - jitAuthorizationPolicies?: JitAuthorizationPolicies[]; - /** The JIT request properties. */ - jitSchedulingPolicy?: JitSchedulingPolicy; - /** - * The JIT request provisioning state. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly provisioningState?: ProvisioningState; - /** - * The JIT request state. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly jitRequestState?: JitRequestState; - /** - * The client entity that created the JIT request. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly createdBy?: ApplicationClientDetails; - /** - * The client entity that last updated the JIT request. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly updatedBy?: ApplicationClientDetails; + /** The identity of the resource. */ + identity?: Identity; } /** Information about managed application. */ @@ -534,10 +177,8 @@ export interface Application extends GenericResource { plan?: Plan; /** The kind of the managed application. Allowed values are MarketPlace and ServiceCatalog. */ kind: string; - /** The identity of the resource. */ - identity?: Identity; /** The managed resource group Id. */ - managedResourceGroupId?: string; + managedResourceGroupId: string; /** The fully qualified path of managed application definition Id. */ applicationDefinitionId?: string; /** Name and value pairs that define the managed application parameters. It can be a JObject or a well formed JSON string. */ @@ -552,53 +193,6 @@ export interface Application extends GenericResource { * NOTE: This property will not be serialized. It can only be populated by the server. */ readonly provisioningState?: ProvisioningState; - /** - * The managed application billing details. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly billingDetails?: ApplicationBillingDetailsDefinition; - /** The managed application Jit access policy. */ - jitAccessPolicy?: ApplicationJitAccessPolicy; - /** - * The publisher tenant Id. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly publisherTenantId?: string; - /** - * The read-only authorizations property that is retrieved from the application package. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly authorizations?: ApplicationAuthorization[]; - /** - * The managed application management mode. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly managementMode?: ApplicationManagementMode; - /** - * The read-only customer support property that is retrieved from the application package. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly customerSupport?: ApplicationPackageContact; - /** - * The read-only support URLs property that is retrieved from the application package. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly supportUrls?: ApplicationPackageSupportUrls; - /** - * The collection of managed application artifacts. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly artifacts?: ApplicationArtifact[]; - /** - * The client entity that created the JIT request. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly createdBy?: ApplicationClientDetails; - /** - * The client entity that last updated the JIT request. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly updatedBy?: ApplicationClientDetails; } /** Information about managed application. */ @@ -607,8 +201,6 @@ export interface ApplicationPatchable extends GenericResource { plan?: PlanPatchable; /** The kind of the managed application. Allowed values are MarketPlace and ServiceCatalog. */ kind?: string; - /** The identity of the resource. */ - identity?: Identity; /** The managed resource group Id. */ managedResourceGroupId?: string; /** The fully qualified path of managed application definition Id. */ @@ -625,53 +217,6 @@ export interface ApplicationPatchable extends GenericResource { * NOTE: This property will not be serialized. It can only be populated by the server. */ readonly provisioningState?: ProvisioningState; - /** - * The managed application billing details. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly billingDetails?: ApplicationBillingDetailsDefinition; - /** The managed application Jit access policy. */ - jitAccessPolicy?: ApplicationJitAccessPolicy; - /** - * The publisher tenant Id. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly publisherTenantId?: string; - /** - * The read-only authorizations property that is retrieved from the application package. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly authorizations?: ApplicationAuthorization[]; - /** - * The managed application management mode. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly managementMode?: ApplicationManagementMode; - /** - * The read-only customer support property that is retrieved from the application package. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly customerSupport?: ApplicationPackageContact; - /** - * The read-only support URLs property that is retrieved from the application package. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly supportUrls?: ApplicationPackageSupportUrls; - /** - * The collection of managed application artifacts. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly artifacts?: ApplicationArtifact[]; - /** - * The client entity that created the JIT request. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly createdBy?: ApplicationClientDetails; - /** - * The client entity that last updated the JIT request. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly updatedBy?: ApplicationClientDetails; } /** Information about managed application definition. */ @@ -681,77 +226,33 @@ export interface ApplicationDefinition extends GenericResource { /** The managed application definition display name. */ displayName?: string; /** A value indicating whether the package is enabled or not. */ - isEnabled?: boolean; + isEnabled?: string; /** The managed application provider authorizations. */ - authorizations?: ApplicationAuthorization[]; + authorizations: ApplicationProviderAuthorization[]; /** The collection of managed application artifacts. The portal will use the files specified as artifacts to construct the user experience of creating a managed application from a managed application definition. */ - artifacts?: ApplicationDefinitionArtifact[]; + artifacts?: ApplicationArtifact[]; /** The managed application definition description. */ description?: string; /** The managed application definition package file Uri. Use this element */ packageFileUri?: string; - /** The storage account id for bring your own storage scenario. */ - storageAccountId?: string; /** The inline main template json which has resources to be provisioned. It can be a JObject or well-formed JSON string. */ mainTemplate?: Record; /** The createUiDefinition json for the backing template with Microsoft.Solutions/applications resource. It can be a JObject or well-formed JSON string. */ createUiDefinition?: Record; - /** The managed application notification policy. */ - notificationPolicy?: ApplicationNotificationPolicy; - /** The managed application locking policy. */ - lockingPolicy?: ApplicationPackageLockingPolicyDefinition; - /** The managed application deployment policy. */ - deploymentPolicy?: ApplicationDeploymentPolicy; - /** The managed application management policy that determines publisher's access to the managed resource group. */ - managementPolicy?: ApplicationManagementPolicy; - /** The managed application provider policies. */ - policies?: ApplicationPolicy[]; -} - -/** Known values of {@link Origin} that the service accepts. */ -export enum KnownOrigin { - /** User */ - User = "user", - /** System */ - System = "system", - /** UserSystem */ - UserSystem = "user,system" } -/** - * Defines values for Origin. \ - * {@link KnownOrigin} can be used interchangeably with Origin, - * this enum contains the known values that the service supports. - * ### Known values supported by the service - * **user** \ - * **system** \ - * **user,system** - */ -export type Origin = string; - -/** Known values of {@link ActionType} that the service accepts. */ -export enum KnownActionType { - /** Internal */ - Internal = "Internal" -} - -/** - * Defines values for ActionType. \ - * {@link KnownActionType} can be used interchangeably with ActionType, - * this enum contains the known values that the service supports. - * ### Known values supported by the service - * **Internal** - */ -export type ActionType = string; - /** Known values of {@link ProvisioningState} that the service accepts. */ export enum KnownProvisioningState { - /** NotSpecified */ - NotSpecified = "NotSpecified", /** Accepted */ Accepted = "Accepted", /** Running */ Running = "Running", + /** Ready */ + Ready = "Ready", + /** Creating */ + Creating = "Creating", + /** Created */ + Created = "Created", /** Deleting */ Deleting = "Deleting", /** Deleted */ @@ -763,7 +264,7 @@ export enum KnownProvisioningState { /** Succeeded */ Succeeded = "Succeeded", /** Updating */ - Updating = "Updating" + Updating = "Updating", } /** @@ -771,9 +272,11 @@ export enum KnownProvisioningState { * {@link KnownProvisioningState} can be used interchangeably with ProvisioningState, * this enum contains the known values that the service supports. * ### Known values supported by the service - * **NotSpecified** \ * **Accepted** \ * **Running** \ + * **Ready** \ + * **Creating** \ + * **Created** \ * **Deleting** \ * **Deleted** \ * **Canceled** \ @@ -782,277 +285,10 @@ export enum KnownProvisioningState { * **Updating** */ export type ProvisioningState = string; - -/** Known values of {@link JitApprovalMode} that the service accepts. */ -export enum KnownJitApprovalMode { - /** NotSpecified */ - NotSpecified = "NotSpecified", - /** AutoApprove */ - AutoApprove = "AutoApprove", - /** ManualApprove */ - ManualApprove = "ManualApprove" -} - -/** - * Defines values for JitApprovalMode. \ - * {@link KnownJitApprovalMode} can be used interchangeably with JitApprovalMode, - * this enum contains the known values that the service supports. - * ### Known values supported by the service - * **NotSpecified** \ - * **AutoApprove** \ - * **ManualApprove** - */ -export type JitApprovalMode = string; - -/** Known values of {@link JitApproverType} that the service accepts. */ -export enum KnownJitApproverType { - /** User */ - User = "user", - /** Group */ - Group = "group" -} - -/** - * Defines values for JitApproverType. \ - * {@link KnownJitApproverType} can be used interchangeably with JitApproverType, - * this enum contains the known values that the service supports. - * ### Known values supported by the service - * **user** \ - * **group** - */ -export type JitApproverType = string; - -/** Known values of {@link ApplicationManagementMode} that the service accepts. */ -export enum KnownApplicationManagementMode { - /** NotSpecified */ - NotSpecified = "NotSpecified", - /** Unmanaged */ - Unmanaged = "Unmanaged", - /** Managed */ - Managed = "Managed" -} - -/** - * Defines values for ApplicationManagementMode. \ - * {@link KnownApplicationManagementMode} can be used interchangeably with ApplicationManagementMode, - * this enum contains the known values that the service supports. - * ### Known values supported by the service - * **NotSpecified** \ - * **Unmanaged** \ - * **Managed** - */ -export type ApplicationManagementMode = string; - -/** Known values of {@link ApplicationArtifactName} that the service accepts. */ -export enum KnownApplicationArtifactName { - /** NotSpecified */ - NotSpecified = "NotSpecified", - /** ViewDefinition */ - ViewDefinition = "ViewDefinition", - /** Authorizations */ - Authorizations = "Authorizations", - /** CustomRoleDefinition */ - CustomRoleDefinition = "CustomRoleDefinition" -} - -/** - * Defines values for ApplicationArtifactName. \ - * {@link KnownApplicationArtifactName} can be used interchangeably with ApplicationArtifactName, - * this enum contains the known values that the service supports. - * ### Known values supported by the service - * **NotSpecified** \ - * **ViewDefinition** \ - * **Authorizations** \ - * **CustomRoleDefinition** - */ -export type ApplicationArtifactName = string; - -/** Known values of {@link CreatedByType} that the service accepts. */ -export enum KnownCreatedByType { - /** User */ - User = "User", - /** Application */ - Application = "Application", - /** ManagedIdentity */ - ManagedIdentity = "ManagedIdentity", - /** Key */ - Key = "Key" -} - -/** - * Defines values for CreatedByType. \ - * {@link KnownCreatedByType} can be used interchangeably with CreatedByType, - * this enum contains the known values that the service supports. - * ### Known values supported by the service - * **User** \ - * **Application** \ - * **ManagedIdentity** \ - * **Key** - */ -export type CreatedByType = string; - -/** Known values of {@link ApplicationDefinitionArtifactName} that the service accepts. */ -export enum KnownApplicationDefinitionArtifactName { - /** NotSpecified */ - NotSpecified = "NotSpecified", - /** ApplicationResourceTemplate */ - ApplicationResourceTemplate = "ApplicationResourceTemplate", - /** CreateUiDefinition */ - CreateUiDefinition = "CreateUiDefinition", - /** MainTemplateParameters */ - MainTemplateParameters = "MainTemplateParameters" -} - -/** - * Defines values for ApplicationDefinitionArtifactName. \ - * {@link KnownApplicationDefinitionArtifactName} can be used interchangeably with ApplicationDefinitionArtifactName, - * this enum contains the known values that the service supports. - * ### Known values supported by the service - * **NotSpecified** \ - * **ApplicationResourceTemplate** \ - * **CreateUiDefinition** \ - * **MainTemplateParameters** - */ -export type ApplicationDefinitionArtifactName = string; - -/** Known values of {@link DeploymentMode} that the service accepts. */ -export enum KnownDeploymentMode { - /** NotSpecified */ - NotSpecified = "NotSpecified", - /** Incremental */ - Incremental = "Incremental", - /** Complete */ - Complete = "Complete" -} - -/** - * Defines values for DeploymentMode. \ - * {@link KnownDeploymentMode} can be used interchangeably with DeploymentMode, - * this enum contains the known values that the service supports. - * ### Known values supported by the service - * **NotSpecified** \ - * **Incremental** \ - * **Complete** - */ -export type DeploymentMode = string; - -/** Known values of {@link JitSchedulingType} that the service accepts. */ -export enum KnownJitSchedulingType { - /** NotSpecified */ - NotSpecified = "NotSpecified", - /** Once */ - Once = "Once", - /** Recurring */ - Recurring = "Recurring" -} - -/** - * Defines values for JitSchedulingType. \ - * {@link KnownJitSchedulingType} can be used interchangeably with JitSchedulingType, - * this enum contains the known values that the service supports. - * ### Known values supported by the service - * **NotSpecified** \ - * **Once** \ - * **Recurring** - */ -export type JitSchedulingType = string; - -/** Known values of {@link JitRequestState} that the service accepts. */ -export enum KnownJitRequestState { - /** NotSpecified */ - NotSpecified = "NotSpecified", - /** Pending */ - Pending = "Pending", - /** Approved */ - Approved = "Approved", - /** Denied */ - Denied = "Denied", - /** Failed */ - Failed = "Failed", - /** Canceled */ - Canceled = "Canceled", - /** Expired */ - Expired = "Expired", - /** Timeout */ - Timeout = "Timeout" -} - -/** - * Defines values for JitRequestState. \ - * {@link KnownJitRequestState} can be used interchangeably with JitRequestState, - * this enum contains the known values that the service supports. - * ### Known values supported by the service - * **NotSpecified** \ - * **Pending** \ - * **Approved** \ - * **Denied** \ - * **Failed** \ - * **Canceled** \ - * **Expired** \ - * **Timeout** - */ -export type JitRequestState = string; - -/** Known values of {@link Status} that the service accepts. */ -export enum KnownStatus { - /** NotSpecified */ - NotSpecified = "NotSpecified", - /** Elevate */ - Elevate = "Elevate", - /** Remove */ - Remove = "Remove" -} - -/** - * Defines values for Status. \ - * {@link KnownStatus} can be used interchangeably with Status, - * this enum contains the known values that the service supports. - * ### Known values supported by the service - * **NotSpecified** \ - * **Elevate** \ - * **Remove** - */ -export type Status = string; - -/** Known values of {@link Substatus} that the service accepts. */ -export enum KnownSubstatus { - /** NotSpecified */ - NotSpecified = "NotSpecified", - /** Approved */ - Approved = "Approved", - /** Denied */ - Denied = "Denied", - /** Failed */ - Failed = "Failed", - /** Expired */ - Expired = "Expired", - /** Timeout */ - Timeout = "Timeout" -} - -/** - * Defines values for Substatus. \ - * {@link KnownSubstatus} can be used interchangeably with Substatus, - * this enum contains the known values that the service supports. - * ### Known values supported by the service - * **NotSpecified** \ - * **Approved** \ - * **Denied** \ - * **Failed** \ - * **Expired** \ - * **Timeout** - */ -export type Substatus = string; -/** Defines values for ApplicationArtifactType. */ -export type ApplicationArtifactType = "NotSpecified" | "Template" | "Custom"; -/** Defines values for ResourceIdentityType. */ -export type ResourceIdentityType = - | "SystemAssigned" - | "UserAssigned" - | "SystemAssigned, UserAssigned" - | "None"; /** Defines values for ApplicationLockLevel. */ export type ApplicationLockLevel = "CanNotDelete" | "ReadOnly" | "None"; +/** Defines values for ApplicationArtifactType. */ +export type ApplicationArtifactType = "Template" | "Custom"; /** Optional parameters. */ export interface ListOperationsOptionalParams @@ -1101,14 +337,10 @@ export interface ApplicationsUpdateOptionalParams extends coreClient.OperationOptions { /** Parameters supplied to update an existing managed application. */ parameters?: ApplicationPatchable; - /** Delay to wait until next poll, in milliseconds. */ - updateIntervalInMs?: number; - /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ - resumeFrom?: string; } /** Contains response data for the update operation. */ -export type ApplicationsUpdateResponse = ApplicationPatchable; +export type ApplicationsUpdateResponse = Application; /** Optional parameters. */ export interface ApplicationsListByResourceGroupOptionalParams @@ -1156,47 +388,11 @@ export type ApplicationsCreateOrUpdateByIdResponse = Application; export interface ApplicationsUpdateByIdOptionalParams extends coreClient.OperationOptions { /** Parameters supplied to update an existing managed application. */ - parameters?: ApplicationPatchable; - /** Delay to wait until next poll, in milliseconds. */ - updateIntervalInMs?: number; - /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ - resumeFrom?: string; + parameters?: Application; } /** Contains response data for the updateById operation. */ -export type ApplicationsUpdateByIdResponse = ApplicationPatchable; - -/** Optional parameters. */ -export interface ApplicationsRefreshPermissionsOptionalParams - extends coreClient.OperationOptions { - /** Delay to wait until next poll, in milliseconds. */ - updateIntervalInMs?: number; - /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ - resumeFrom?: string; -} - -/** Optional parameters. */ -export interface ApplicationsListAllowedUpgradePlansOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the listAllowedUpgradePlans operation. */ -export type ApplicationsListAllowedUpgradePlansResponse = AllowedUpgradePlansResult; - -/** Optional parameters. */ -export interface ApplicationsUpdateAccessOptionalParams - extends coreClient.OperationOptions { - /** Delay to wait until next poll, in milliseconds. */ - updateIntervalInMs?: number; - /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ - resumeFrom?: string; -} - -/** Optional parameters. */ -export interface ApplicationsListTokensOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the listTokens operation. */ -export type ApplicationsListTokensResponse = ManagedIdentityTokenResult; +export type ApplicationsUpdateByIdResponse = Application; /** Optional parameters. */ export interface ApplicationsListByResourceGroupNextOptionalParams @@ -1221,35 +417,33 @@ export type ApplicationDefinitionsGetResponse = ApplicationDefinition; /** Optional parameters. */ export interface ApplicationDefinitionsDeleteOptionalParams - extends coreClient.OperationOptions {} + extends coreClient.OperationOptions { + /** Delay to wait until next poll, in milliseconds. */ + updateIntervalInMs?: number; + /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ + resumeFrom?: string; +} /** Optional parameters. */ export interface ApplicationDefinitionsCreateOrUpdateOptionalParams - extends coreClient.OperationOptions {} + extends coreClient.OperationOptions { + /** Delay to wait until next poll, in milliseconds. */ + updateIntervalInMs?: number; + /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ + resumeFrom?: string; +} /** Contains response data for the createOrUpdate operation. */ -export type ApplicationDefinitionsCreateOrUpdateResponse = ApplicationDefinition; - -/** Optional parameters. */ -export interface ApplicationDefinitionsUpdateOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the update operation. */ -export type ApplicationDefinitionsUpdateResponse = ApplicationDefinition; +export type ApplicationDefinitionsCreateOrUpdateResponse = + ApplicationDefinition; /** Optional parameters. */ export interface ApplicationDefinitionsListByResourceGroupOptionalParams extends coreClient.OperationOptions {} /** Contains response data for the listByResourceGroup operation. */ -export type ApplicationDefinitionsListByResourceGroupResponse = ApplicationDefinitionListResult; - -/** Optional parameters. */ -export interface ApplicationDefinitionsListBySubscriptionOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the listBySubscription operation. */ -export type ApplicationDefinitionsListBySubscriptionResponse = ApplicationDefinitionListResult; +export type ApplicationDefinitionsListByResourceGroupResponse = + ApplicationDefinitionListResult; /** Optional parameters. */ export interface ApplicationDefinitionsGetByIdOptionalParams @@ -1260,45 +454,15 @@ export type ApplicationDefinitionsGetByIdResponse = ApplicationDefinition; /** Optional parameters. */ export interface ApplicationDefinitionsDeleteByIdOptionalParams - extends coreClient.OperationOptions {} + extends coreClient.OperationOptions { + /** Delay to wait until next poll, in milliseconds. */ + updateIntervalInMs?: number; + /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ + resumeFrom?: string; +} /** Optional parameters. */ export interface ApplicationDefinitionsCreateOrUpdateByIdOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the createOrUpdateById operation. */ -export type ApplicationDefinitionsCreateOrUpdateByIdResponse = ApplicationDefinition; - -/** Optional parameters. */ -export interface ApplicationDefinitionsUpdateByIdOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the updateById operation. */ -export type ApplicationDefinitionsUpdateByIdResponse = ApplicationDefinition; - -/** Optional parameters. */ -export interface ApplicationDefinitionsListByResourceGroupNextOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the listByResourceGroupNext operation. */ -export type ApplicationDefinitionsListByResourceGroupNextResponse = ApplicationDefinitionListResult; - -/** Optional parameters. */ -export interface ApplicationDefinitionsListBySubscriptionNextOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the listBySubscriptionNext operation. */ -export type ApplicationDefinitionsListBySubscriptionNextResponse = ApplicationDefinitionListResult; - -/** Optional parameters. */ -export interface JitRequestsGetOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the get operation. */ -export type JitRequestsGetResponse = JitRequestDefinition; - -/** Optional parameters. */ -export interface JitRequestsCreateOrUpdateOptionalParams extends coreClient.OperationOptions { /** Delay to wait until next poll, in milliseconds. */ updateIntervalInMs?: number; @@ -1306,33 +470,17 @@ export interface JitRequestsCreateOrUpdateOptionalParams resumeFrom?: string; } -/** Contains response data for the createOrUpdate operation. */ -export type JitRequestsCreateOrUpdateResponse = JitRequestDefinition; - -/** Optional parameters. */ -export interface JitRequestsUpdateOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the update operation. */ -export type JitRequestsUpdateResponse = JitRequestDefinition; - -/** Optional parameters. */ -export interface JitRequestsDeleteOptionalParams - extends coreClient.OperationOptions {} - -/** Optional parameters. */ -export interface JitRequestsListBySubscriptionOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the listBySubscription operation. */ -export type JitRequestsListBySubscriptionResponse = JitRequestDefinitionListResult; +/** Contains response data for the createOrUpdateById operation. */ +export type ApplicationDefinitionsCreateOrUpdateByIdResponse = + ApplicationDefinition; /** Optional parameters. */ -export interface JitRequestsListByResourceGroupOptionalParams +export interface ApplicationDefinitionsListByResourceGroupNextOptionalParams extends coreClient.OperationOptions {} -/** Contains response data for the listByResourceGroup operation. */ -export type JitRequestsListByResourceGroupResponse = JitRequestDefinitionListResult; +/** Contains response data for the listByResourceGroupNext operation. */ +export type ApplicationDefinitionsListByResourceGroupNextResponse = + ApplicationDefinitionListResult; /** Optional parameters. */ export interface ApplicationClientOptionalParams diff --git a/sdk/managedapplications/arm-managedapplications/src/models/mappers.ts b/sdk/managedapplications/arm-managedapplications/src/models/mappers.ts index 1e96dd7defa8..0eab0d3cac20 100644 --- a/sdk/managedapplications/arm-managedapplications/src/models/mappers.ts +++ b/sdk/managedapplications/arm-managedapplications/src/models/mappers.ts @@ -15,26 +15,24 @@ export const OperationListResult: coreClient.CompositeMapper = { modelProperties: { value: { serializedName: "value", - readOnly: true, type: { name: "Sequence", element: { type: { name: "Composite", - className: "Operation" - } - } - } + className: "Operation", + }, + }, + }, }, nextLink: { serializedName: "nextLink", - readOnly: true, type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const Operation: coreClient.CompositeMapper = { @@ -44,41 +42,19 @@ export const Operation: coreClient.CompositeMapper = { modelProperties: { name: { serializedName: "name", - readOnly: true, type: { - name: "String" - } - }, - isDataAction: { - serializedName: "isDataAction", - readOnly: true, - type: { - name: "Boolean" - } + name: "String", + }, }, display: { serializedName: "display", type: { name: "Composite", - className: "OperationDisplay" - } - }, - origin: { - serializedName: "origin", - readOnly: true, - type: { - name: "String" - } + className: "OperationDisplay", + }, }, - actionType: { - serializedName: "actionType", - readOnly: true, - type: { - name: "String" - } - } - } - } + }, + }, }; export const OperationDisplay: coreClient.CompositeMapper = { @@ -88,344 +64,24 @@ export const OperationDisplay: coreClient.CompositeMapper = { modelProperties: { provider: { serializedName: "provider", - readOnly: true, type: { - name: "String" - } + name: "String", + }, }, resource: { serializedName: "resource", - readOnly: true, type: { - name: "String" - } + name: "String", + }, }, operation: { serializedName: "operation", - readOnly: true, - type: { - name: "String" - } - }, - description: { - serializedName: "description", - readOnly: true, - type: { - name: "String" - } - } - } - } -}; - -export const ErrorResponse: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ErrorResponse", - modelProperties: { - error: { - serializedName: "error", - type: { - name: "Composite", - className: "ErrorDetail" - } - } - } - } -}; - -export const ErrorDetail: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ErrorDetail", - modelProperties: { - code: { - serializedName: "code", - readOnly: true, - type: { - name: "String" - } - }, - message: { - serializedName: "message", - readOnly: true, - type: { - name: "String" - } - }, - target: { - serializedName: "target", - readOnly: true, - type: { - name: "String" - } - }, - details: { - serializedName: "details", - readOnly: true, - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "ErrorDetail" - } - } - } - }, - additionalInfo: { - serializedName: "additionalInfo", - readOnly: true, - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "ErrorAdditionalInfo" - } - } - } - } - } - } -}; - -export const ErrorAdditionalInfo: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ErrorAdditionalInfo", - modelProperties: { - type: { - serializedName: "type", - readOnly: true, - type: { - name: "String" - } - }, - info: { - serializedName: "info", - readOnly: true, - type: { - name: "Dictionary", - value: { type: { name: "any" } } - } - } - } - } -}; - -export const ApplicationBillingDetailsDefinition: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ApplicationBillingDetailsDefinition", - modelProperties: { - resourceUsageId: { - serializedName: "resourceUsageId", - type: { - name: "String" - } - } - } - } -}; - -export const ApplicationJitAccessPolicy: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ApplicationJitAccessPolicy", - modelProperties: { - jitAccessEnabled: { - serializedName: "jitAccessEnabled", - required: true, - type: { - name: "Boolean" - } - }, - jitApprovalMode: { - serializedName: "jitApprovalMode", - type: { - name: "String" - } - }, - jitApprovers: { - serializedName: "jitApprovers", - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "JitApproverDefinition" - } - } - } - }, - maximumJitAccessDuration: { - serializedName: "maximumJitAccessDuration", - type: { - name: "String" - } - } - } - } -}; - -export const JitApproverDefinition: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "JitApproverDefinition", - modelProperties: { - id: { - serializedName: "id", - required: true, - type: { - name: "String" - } - }, - type: { - serializedName: "type", - type: { - name: "String" - } - }, - displayName: { - serializedName: "displayName", - type: { - name: "String" - } - } - } - } -}; - -export const ApplicationAuthorization: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ApplicationAuthorization", - modelProperties: { - principalId: { - serializedName: "principalId", - required: true, type: { - name: "String" - } - }, - roleDefinitionId: { - serializedName: "roleDefinitionId", - required: true, - type: { - name: "String" - } - } - } - } -}; - -export const ApplicationPackageContact: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ApplicationPackageContact", - modelProperties: { - contactName: { - serializedName: "contactName", - type: { - name: "String" - } - }, - email: { - serializedName: "email", - required: true, - type: { - name: "String" - } - }, - phone: { - serializedName: "phone", - required: true, - type: { - name: "String" - } - } - } - } -}; - -export const ApplicationPackageSupportUrls: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ApplicationPackageSupportUrls", - modelProperties: { - publicAzure: { - serializedName: "publicAzure", - type: { - name: "String" - } - }, - governmentCloud: { - serializedName: "governmentCloud", - type: { - name: "String" - } - } - } - } -}; - -export const ApplicationArtifact: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ApplicationArtifact", - modelProperties: { - name: { - serializedName: "name", - required: true, - type: { - name: "String" - } - }, - uri: { - serializedName: "uri", - required: true, - type: { - name: "String" - } - }, - type: { - serializedName: "type", - required: true, - type: { - name: "Enum", - allowedValues: ["NotSpecified", "Template", "Custom"] - } - } - } - } -}; - -export const ApplicationClientDetails: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ApplicationClientDetails", - modelProperties: { - oid: { - serializedName: "oid", - type: { - name: "String" - } - }, - puid: { - serializedName: "puid", - type: { - name: "String" - } + name: "String", + }, }, - applicationId: { - serializedName: "applicationId", - type: { - name: "String" - } - } - } - } + }, + }, }; export const Plan: coreClient.CompositeMapper = { @@ -437,108 +93,38 @@ export const Plan: coreClient.CompositeMapper = { serializedName: "name", required: true, type: { - name: "String" - } + name: "String", + }, }, publisher: { serializedName: "publisher", required: true, type: { - name: "String" - } + name: "String", + }, }, product: { serializedName: "product", required: true, type: { - name: "String" - } + name: "String", + }, }, promotionCode: { serializedName: "promotionCode", type: { - name: "String" - } + name: "String", + }, }, version: { serializedName: "version", required: true, type: { - name: "String" - } - } - } - } -}; - -export const Identity: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "Identity", - modelProperties: { - principalId: { - serializedName: "principalId", - readOnly: true, - type: { - name: "String" - } - }, - tenantId: { - serializedName: "tenantId", - readOnly: true, - type: { - name: "String" - } - }, - type: { - serializedName: "type", - type: { - name: "Enum", - allowedValues: [ - "SystemAssigned", - "UserAssigned", - "SystemAssigned, UserAssigned", - "None" - ] - } - }, - userAssignedIdentities: { - serializedName: "userAssignedIdentities", - type: { - name: "Dictionary", - value: { - type: { - name: "Composite", - className: "UserAssignedResourceIdentity" - } - } - } - } - } - } -}; - -export const UserAssignedResourceIdentity: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "UserAssignedResourceIdentity", - modelProperties: { - principalId: { - serializedName: "principalId", - readOnly: true, - type: { - name: "String" - } + name: "String", + }, }, - tenantId: { - serializedName: "tenantId", - readOnly: true, - type: { - name: "String" - } - } - } - } + }, + }, }; export const Sku: coreClient.CompositeMapper = { @@ -550,621 +136,238 @@ export const Sku: coreClient.CompositeMapper = { serializedName: "name", required: true, type: { - name: "String" - } + name: "String", + }, }, tier: { serializedName: "tier", type: { - name: "String" - } + name: "String", + }, }, size: { serializedName: "size", type: { - name: "String" - } + name: "String", + }, }, family: { serializedName: "family", type: { - name: "String" - } + name: "String", + }, }, model: { serializedName: "model", type: { - name: "String" - } + name: "String", + }, }, capacity: { serializedName: "capacity", type: { - name: "Number" - } - } - } - } + name: "Number", + }, + }, + }, + }, }; -export const Resource: coreClient.CompositeMapper = { +export const Identity: coreClient.CompositeMapper = { type: { name: "Composite", - className: "Resource", + className: "Identity", modelProperties: { - id: { - serializedName: "id", + principalId: { + serializedName: "principalId", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, - name: { - serializedName: "name", + tenantId: { + serializedName: "tenantId", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, type: { + defaultValue: "SystemAssigned", + isConstant: true, serializedName: "type", - readOnly: true, type: { - name: "String" - } - }, - location: { - serializedName: "location", - type: { - name: "String" - } - }, - tags: { - serializedName: "tags", - type: { - name: "Dictionary", - value: { type: { name: "String" } } - } + name: "String", + }, }, - systemData: { - serializedName: "systemData", - type: { - name: "Composite", - className: "SystemData" - } - } - } - } + }, + }, }; -export const SystemData: coreClient.CompositeMapper = { +export const Resource: coreClient.CompositeMapper = { type: { name: "Composite", - className: "SystemData", + className: "Resource", modelProperties: { - createdBy: { - serializedName: "createdBy", - type: { - name: "String" - } - }, - createdByType: { - serializedName: "createdByType", - type: { - name: "String" - } - }, - createdAt: { - serializedName: "createdAt", - type: { - name: "DateTime" - } - }, - lastModifiedBy: { - serializedName: "lastModifiedBy", - type: { - name: "String" - } - }, - lastModifiedByType: { - serializedName: "lastModifiedByType", + id: { + serializedName: "id", + readOnly: true, type: { - name: "String" - } + name: "String", + }, }, - lastModifiedAt: { - serializedName: "lastModifiedAt", - type: { - name: "DateTime" - } - } - } - } -}; - -export const PlanPatchable: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "PlanPatchable", - modelProperties: { name: { serializedName: "name", + readOnly: true, type: { - name: "String" - } - }, - publisher: { - serializedName: "publisher", - type: { - name: "String" - } - }, - product: { - serializedName: "product", - type: { - name: "String" - } - }, - promotionCode: { - serializedName: "promotionCode", - type: { - name: "String" - } - }, - version: { - serializedName: "version", - type: { - name: "String" - } - } - } - } -}; - -export const ApplicationDefinitionArtifact: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ApplicationDefinitionArtifact", - modelProperties: { - name: { - serializedName: "name", - required: true, - type: { - name: "String" - } - }, - uri: { - serializedName: "uri", - required: true, - type: { - name: "String" - } + name: "String", + }, }, type: { serializedName: "type", - required: true, - type: { - name: "Enum", - allowedValues: ["NotSpecified", "Template", "Custom"] - } - } - } - } -}; - -export const ApplicationNotificationPolicy: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ApplicationNotificationPolicy", - modelProperties: { - notificationEndpoints: { - serializedName: "notificationEndpoints", - required: true, - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "ApplicationNotificationEndpoint" - } - } - } - } - } - } -}; - -export const ApplicationNotificationEndpoint: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ApplicationNotificationEndpoint", - modelProperties: { - uri: { - serializedName: "uri", - required: true, - type: { - name: "String" - } - } - } - } -}; - -export const ApplicationPackageLockingPolicyDefinition: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ApplicationPackageLockingPolicyDefinition", - modelProperties: { - allowedActions: { - serializedName: "allowedActions", - type: { - name: "Sequence", - element: { - type: { - name: "String" - } - } - } - }, - allowedDataActions: { - serializedName: "allowedDataActions", - type: { - name: "Sequence", - element: { - type: { - name: "String" - } - } - } - } - } - } -}; - -export const ApplicationDeploymentPolicy: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ApplicationDeploymentPolicy", - modelProperties: { - deploymentMode: { - serializedName: "deploymentMode", - required: true, - type: { - name: "String" - } - } - } - } -}; - -export const ApplicationManagementPolicy: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ApplicationManagementPolicy", - modelProperties: { - mode: { - serializedName: "mode", - type: { - name: "String" - } - } - } - } -}; - -export const ApplicationPolicy: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ApplicationPolicy", - modelProperties: { - name: { - serializedName: "name", + readOnly: true, type: { - name: "String" - } + name: "String", + }, }, - policyDefinitionId: { - serializedName: "policyDefinitionId", + location: { + serializedName: "location", type: { - name: "String" - } + name: "String", + }, }, - parameters: { - serializedName: "parameters", - type: { - name: "String" - } - } - } - } -}; - -export const ApplicationDefinitionPatchable: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ApplicationDefinitionPatchable", - modelProperties: { tags: { serializedName: "tags", type: { name: "Dictionary", - value: { type: { name: "String" } } - } - } - } - } -}; - -export const ApplicationDefinitionListResult: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ApplicationDefinitionListResult", - modelProperties: { - value: { - serializedName: "value", - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "ApplicationDefinition" - } - } - } - }, - nextLink: { - serializedName: "nextLink", - type: { - name: "String" - } - } - } - } -}; - -export const ApplicationListResult: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ApplicationListResult", - modelProperties: { - value: { - serializedName: "value", - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "Application" - } - } - } - }, - nextLink: { - serializedName: "nextLink", - type: { - name: "String" - } - } - } - } -}; - -export const JitAuthorizationPolicies: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "JitAuthorizationPolicies", - modelProperties: { - principalId: { - serializedName: "principalId", - required: true, - type: { - name: "String" - } - }, - roleDefinitionId: { - serializedName: "roleDefinitionId", - required: true, - type: { - name: "String" - } - } - } - } -}; - -export const JitSchedulingPolicy: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "JitSchedulingPolicy", - modelProperties: { - type: { - serializedName: "type", - required: true, - type: { - name: "String" - } - }, - duration: { - serializedName: "duration", - required: true, - type: { - name: "TimeSpan" - } + value: { type: { name: "String" } }, + }, }, - startTime: { - serializedName: "startTime", - required: true, - type: { - name: "DateTime" - } - } - } - } + }, + }, }; -export const JitRequestPatchable: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "JitRequestPatchable", - modelProperties: { - tags: { - serializedName: "tags", - type: { - name: "Dictionary", - value: { type: { name: "String" } } - } - } - } - } -}; - -export const JitRequestDefinitionListResult: coreClient.CompositeMapper = { +export const ErrorResponse: coreClient.CompositeMapper = { type: { name: "Composite", - className: "JitRequestDefinitionListResult", + className: "ErrorResponse", modelProperties: { - value: { - serializedName: "value", + httpStatus: { + serializedName: "httpStatus", type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "JitRequestDefinition" - } - } - } + name: "String", + }, }, - nextLink: { - serializedName: "nextLink", - type: { - name: "String" - } - } - } - } -}; - -export const AllowedUpgradePlansResult: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "AllowedUpgradePlansResult", - modelProperties: { - value: { - serializedName: "value", + errorCode: { + serializedName: "errorCode", type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "Plan" - } - } - } - } - } - } + name: "String", + }, + }, + errorMessage: { + serializedName: "errorMessage", + type: { + name: "String", + }, + }, + }, + }, }; -export const UpdateAccessDefinition: coreClient.CompositeMapper = { +export const PlanPatchable: coreClient.CompositeMapper = { type: { name: "Composite", - className: "UpdateAccessDefinition", + className: "PlanPatchable", modelProperties: { - approver: { - serializedName: "approver", + name: { + serializedName: "name", type: { - name: "String" - } + name: "String", + }, }, - metadata: { - serializedName: "metadata", + publisher: { + serializedName: "publisher", type: { - name: "Composite", - className: "JitRequestMetadata" - } + name: "String", + }, }, - status: { - serializedName: "status", - required: true, + product: { + serializedName: "product", type: { - name: "String" - } + name: "String", + }, }, - subStatus: { - serializedName: "subStatus", - required: true, + promotionCode: { + serializedName: "promotionCode", + type: { + name: "String", + }, + }, + version: { + serializedName: "version", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; -export const JitRequestMetadata: coreClient.CompositeMapper = { +export const ApplicationProviderAuthorization: coreClient.CompositeMapper = { type: { name: "Composite", - className: "JitRequestMetadata", + className: "ApplicationProviderAuthorization", modelProperties: { - originRequestId: { - serializedName: "originRequestId", - type: { - name: "String" - } - }, - requestorId: { - serializedName: "requestorId", + principalId: { + serializedName: "principalId", + required: true, type: { - name: "String" - } + name: "String", + }, }, - tenantDisplayName: { - serializedName: "tenantDisplayName", + roleDefinitionId: { + serializedName: "roleDefinitionId", + required: true, type: { - name: "String" - } + name: "String", + }, }, - subjectDisplayName: { - serializedName: "subjectDisplayName", - type: { - name: "String" - } - } - } - } + }, + }, }; -export const ListTokenRequest: coreClient.CompositeMapper = { +export const ApplicationArtifact: coreClient.CompositeMapper = { type: { name: "Composite", - className: "ListTokenRequest", + className: "ApplicationArtifact", modelProperties: { - authorizationAudience: { - serializedName: "authorizationAudience", + name: { + serializedName: "name", type: { - name: "String" - } + name: "String", + }, }, - userAssignedIdentities: { - serializedName: "userAssignedIdentities", + uri: { + serializedName: "uri", type: { - name: "Sequence", - element: { - type: { - name: "String" - } - } - } - } - } - } + name: "String", + }, + }, + type: { + serializedName: "type", + type: { + name: "Enum", + allowedValues: ["Template", "Custom"], + }, + }, + }, + }, }; -export const ManagedIdentityTokenResult: coreClient.CompositeMapper = { +export const ApplicationDefinitionListResult: coreClient.CompositeMapper = { type: { name: "Composite", - className: "ManagedIdentityTokenResult", + className: "ApplicationDefinitionListResult", modelProperties: { value: { serializedName: "value", @@ -1173,64 +376,46 @@ export const ManagedIdentityTokenResult: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "ManagedIdentityToken" - } - } - } - } - } - } + className: "ApplicationDefinition", + }, + }, + }, + }, + nextLink: { + serializedName: "nextLink", + type: { + name: "String", + }, + }, + }, + }, }; -export const ManagedIdentityToken: coreClient.CompositeMapper = { +export const ApplicationListResult: coreClient.CompositeMapper = { type: { name: "Composite", - className: "ManagedIdentityToken", + className: "ApplicationListResult", modelProperties: { - accessToken: { - serializedName: "accessToken", - type: { - name: "String" - } - }, - expiresIn: { - serializedName: "expiresIn", - type: { - name: "String" - } - }, - expiresOn: { - serializedName: "expiresOn", - type: { - name: "String" - } - }, - notBefore: { - serializedName: "notBefore", - type: { - name: "String" - } - }, - authorizationAudience: { - serializedName: "authorizationAudience", + value: { + serializedName: "value", type: { - name: "String" - } + name: "Sequence", + element: { + type: { + name: "Composite", + className: "Application", + }, + }, + }, }, - resourceId: { - serializedName: "resourceId", + nextLink: { + serializedName: "nextLink", type: { - name: "String" - } + name: "String", + }, }, - tokenType: { - serializedName: "tokenType", - type: { - name: "String" - } - } - } - } + }, + }, }; export const GenericResource: coreClient.CompositeMapper = { @@ -1242,88 +427,25 @@ export const GenericResource: coreClient.CompositeMapper = { managedBy: { serializedName: "managedBy", type: { - name: "String" - } + name: "String", + }, }, sku: { serializedName: "sku", type: { name: "Composite", - className: "Sku" - } - } - } - } -}; - -export const JitRequestDefinition: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "JitRequestDefinition", - modelProperties: { - ...Resource.type.modelProperties, - applicationResourceId: { - serializedName: "properties.applicationResourceId", - type: { - name: "String" - } - }, - publisherTenantId: { - serializedName: "properties.publisherTenantId", - readOnly: true, - type: { - name: "String" - } - }, - jitAuthorizationPolicies: { - serializedName: "properties.jitAuthorizationPolicies", - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "JitAuthorizationPolicies" - } - } - } - }, - jitSchedulingPolicy: { - serializedName: "properties.jitSchedulingPolicy", - type: { - name: "Composite", - className: "JitSchedulingPolicy" - } - }, - provisioningState: { - serializedName: "properties.provisioningState", - readOnly: true, - type: { - name: "String" - } - }, - jitRequestState: { - serializedName: "properties.jitRequestState", - readOnly: true, - type: { - name: "String" - } + className: "Sku", + }, }, - createdBy: { - serializedName: "properties.createdBy", + identity: { + serializedName: "identity", type: { name: "Composite", - className: "ApplicationClientDetails" - } + className: "Identity", + }, }, - updatedBy: { - serializedName: "properties.updatedBy", - type: { - name: "Composite", - className: "ApplicationClientDetails" - } - } - } - } + }, + }, }; export const Application: coreClient.CompositeMapper = { @@ -1336,144 +458,56 @@ export const Application: coreClient.CompositeMapper = { serializedName: "plan", type: { name: "Composite", - className: "Plan" - } + className: "Plan", + }, }, kind: { constraints: { - Pattern: new RegExp("^[-\\w\\._,\\(\\)]+$") + Pattern: new RegExp("^[-\\w\\._,\\(\\)]+$"), }, serializedName: "kind", required: true, type: { - name: "String" - } - }, - identity: { - serializedName: "identity", - type: { - name: "Composite", - className: "Identity" - } + name: "String", + }, }, managedResourceGroupId: { serializedName: "properties.managedResourceGroupId", + required: true, type: { - name: "String" - } + name: "String", + }, }, applicationDefinitionId: { serializedName: "properties.applicationDefinitionId", type: { - name: "String" - } + name: "String", + }, }, parameters: { serializedName: "properties.parameters", type: { name: "Dictionary", - value: { type: { name: "any" } } - } + value: { type: { name: "any" } }, + }, }, outputs: { serializedName: "properties.outputs", readOnly: true, type: { name: "Dictionary", - value: { type: { name: "any" } } - } + value: { type: { name: "any" } }, + }, }, provisioningState: { serializedName: "properties.provisioningState", readOnly: true, type: { - name: "String" - } - }, - billingDetails: { - serializedName: "properties.billingDetails", - type: { - name: "Composite", - className: "ApplicationBillingDetailsDefinition" - } - }, - jitAccessPolicy: { - serializedName: "properties.jitAccessPolicy", - type: { - name: "Composite", - className: "ApplicationJitAccessPolicy" - } - }, - publisherTenantId: { - serializedName: "properties.publisherTenantId", - readOnly: true, - type: { - name: "String" - } - }, - authorizations: { - serializedName: "properties.authorizations", - readOnly: true, - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "ApplicationAuthorization" - } - } - } - }, - managementMode: { - serializedName: "properties.managementMode", - readOnly: true, - type: { - name: "String" - } - }, - customerSupport: { - serializedName: "properties.customerSupport", - type: { - name: "Composite", - className: "ApplicationPackageContact" - } - }, - supportUrls: { - serializedName: "properties.supportUrls", - type: { - name: "Composite", - className: "ApplicationPackageSupportUrls" - } - }, - artifacts: { - serializedName: "properties.artifacts", - readOnly: true, - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "ApplicationArtifact" - } - } - } - }, - createdBy: { - serializedName: "properties.createdBy", - type: { - name: "Composite", - className: "ApplicationClientDetails" - } + name: "String", + }, }, - updatedBy: { - serializedName: "properties.updatedBy", - type: { - name: "Composite", - className: "ApplicationClientDetails" - } - } - } - } + }, + }, }; export const ApplicationPatchable: coreClient.CompositeMapper = { @@ -1486,143 +520,54 @@ export const ApplicationPatchable: coreClient.CompositeMapper = { serializedName: "plan", type: { name: "Composite", - className: "PlanPatchable" - } + className: "PlanPatchable", + }, }, kind: { constraints: { - Pattern: new RegExp("^[-\\w\\._,\\(\\)]+$") + Pattern: new RegExp("^[-\\w\\._,\\(\\)]+$"), }, serializedName: "kind", type: { - name: "String" - } - }, - identity: { - serializedName: "identity", - type: { - name: "Composite", - className: "Identity" - } + name: "String", + }, }, managedResourceGroupId: { serializedName: "properties.managedResourceGroupId", type: { - name: "String" - } + name: "String", + }, }, applicationDefinitionId: { serializedName: "properties.applicationDefinitionId", type: { - name: "String" - } + name: "String", + }, }, parameters: { serializedName: "properties.parameters", type: { name: "Dictionary", - value: { type: { name: "any" } } - } + value: { type: { name: "any" } }, + }, }, outputs: { serializedName: "properties.outputs", readOnly: true, type: { name: "Dictionary", - value: { type: { name: "any" } } - } + value: { type: { name: "any" } }, + }, }, provisioningState: { serializedName: "properties.provisioningState", readOnly: true, type: { - name: "String" - } - }, - billingDetails: { - serializedName: "properties.billingDetails", - type: { - name: "Composite", - className: "ApplicationBillingDetailsDefinition" - } - }, - jitAccessPolicy: { - serializedName: "properties.jitAccessPolicy", - type: { - name: "Composite", - className: "ApplicationJitAccessPolicy" - } - }, - publisherTenantId: { - serializedName: "properties.publisherTenantId", - readOnly: true, - type: { - name: "String" - } - }, - authorizations: { - serializedName: "properties.authorizations", - readOnly: true, - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "ApplicationAuthorization" - } - } - } - }, - managementMode: { - serializedName: "properties.managementMode", - readOnly: true, - type: { - name: "String" - } - }, - customerSupport: { - serializedName: "properties.customerSupport", - type: { - name: "Composite", - className: "ApplicationPackageContact" - } - }, - supportUrls: { - serializedName: "properties.supportUrls", - type: { - name: "Composite", - className: "ApplicationPackageSupportUrls" - } - }, - artifacts: { - serializedName: "properties.artifacts", - readOnly: true, - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "ApplicationArtifact" - } - } - } - }, - createdBy: { - serializedName: "properties.createdBy", - type: { - name: "Composite", - className: "ApplicationClientDetails" - } + name: "String", + }, }, - updatedBy: { - serializedName: "properties.updatedBy", - type: { - name: "Composite", - className: "ApplicationClientDetails" - } - } - } - } + }, + }, }; export const ApplicationDefinition: coreClient.CompositeMapper = { @@ -1636,32 +581,33 @@ export const ApplicationDefinition: coreClient.CompositeMapper = { required: true, type: { name: "Enum", - allowedValues: ["CanNotDelete", "ReadOnly", "None"] - } + allowedValues: ["CanNotDelete", "ReadOnly", "None"], + }, }, displayName: { serializedName: "properties.displayName", type: { - name: "String" - } + name: "String", + }, }, isEnabled: { serializedName: "properties.isEnabled", type: { - name: "Boolean" - } + name: "String", + }, }, authorizations: { serializedName: "properties.authorizations", + required: true, type: { name: "Sequence", element: { type: { name: "Composite", - className: "ApplicationAuthorization" - } - } - } + className: "ApplicationProviderAuthorization", + }, + }, + }, }, artifacts: { serializedName: "properties.artifacts", @@ -1670,83 +616,37 @@ export const ApplicationDefinition: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "ApplicationDefinitionArtifact" - } - } - } + className: "ApplicationArtifact", + }, + }, + }, }, description: { serializedName: "properties.description", type: { - name: "String" - } + name: "String", + }, }, packageFileUri: { serializedName: "properties.packageFileUri", type: { - name: "String" - } - }, - storageAccountId: { - serializedName: "properties.storageAccountId", - type: { - name: "String" - } + name: "String", + }, }, mainTemplate: { serializedName: "properties.mainTemplate", type: { name: "Dictionary", - value: { type: { name: "any" } } - } + value: { type: { name: "any" } }, + }, }, createUiDefinition: { serializedName: "properties.createUiDefinition", type: { name: "Dictionary", - value: { type: { name: "any" } } - } - }, - notificationPolicy: { - serializedName: "properties.notificationPolicy", - type: { - name: "Composite", - className: "ApplicationNotificationPolicy" - } - }, - lockingPolicy: { - serializedName: "properties.lockingPolicy", - type: { - name: "Composite", - className: "ApplicationPackageLockingPolicyDefinition" - } - }, - deploymentPolicy: { - serializedName: "properties.deploymentPolicy", - type: { - name: "Composite", - className: "ApplicationDeploymentPolicy" - } - }, - managementPolicy: { - serializedName: "properties.managementPolicy", - type: { - name: "Composite", - className: "ApplicationManagementPolicy" - } + value: { type: { name: "any" } }, + }, }, - policies: { - serializedName: "properties.policies", - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "ApplicationPolicy" - } - } - } - } - } - } + }, + }, }; diff --git a/sdk/managedapplications/arm-managedapplications/src/models/parameters.ts b/sdk/managedapplications/arm-managedapplications/src/models/parameters.ts index 86f119d130c6..4f221152bf0f 100644 --- a/sdk/managedapplications/arm-managedapplications/src/models/parameters.ts +++ b/sdk/managedapplications/arm-managedapplications/src/models/parameters.ts @@ -9,17 +9,12 @@ import { OperationParameter, OperationURLParameter, - OperationQueryParameter + OperationQueryParameter, } from "@azure/core-client"; import { Application as ApplicationMapper, ApplicationPatchable as ApplicationPatchableMapper, - UpdateAccessDefinition as UpdateAccessDefinitionMapper, - ListTokenRequest as ListTokenRequestMapper, ApplicationDefinition as ApplicationDefinitionMapper, - ApplicationDefinitionPatchable as ApplicationDefinitionPatchableMapper, - JitRequestDefinition as JitRequestDefinitionMapper, - JitRequestPatchable as JitRequestPatchableMapper } from "../models/mappers"; export const accept: OperationParameter = { @@ -29,9 +24,9 @@ export const accept: OperationParameter = { isConstant: true, serializedName: "Accept", type: { - name: "String" - } - } + name: "String", + }, + }, }; export const $host: OperationURLParameter = { @@ -40,22 +35,22 @@ export const $host: OperationURLParameter = { serializedName: "$host", required: true, type: { - name: "String" - } + name: "String", + }, }, - skipEncoding: true + skipEncoding: true, }; export const apiVersion: OperationQueryParameter = { parameterPath: "apiVersion", mapper: { - defaultValue: "2021-07-01", + defaultValue: "2018-06-01", isConstant: true, serializedName: "api-version", type: { - name: "String" - } - } + name: "String", + }, + }, }; export const nextLink: OperationURLParameter = { @@ -64,39 +59,26 @@ export const nextLink: OperationURLParameter = { serializedName: "nextLink", required: true, type: { - name: "String" - } - }, - skipEncoding: true -}; - -export const subscriptionId: OperationURLParameter = { - parameterPath: "subscriptionId", - mapper: { - constraints: { - MinLength: 1 + name: "String", }, - serializedName: "subscriptionId", - required: true, - type: { - name: "String" - } - } + }, + skipEncoding: true, }; export const resourceGroupName: OperationURLParameter = { parameterPath: "resourceGroupName", mapper: { constraints: { + Pattern: new RegExp("^[-\\w\\._\\(\\)]+$"), MaxLength: 90, - MinLength: 1 + MinLength: 1, }, serializedName: "resourceGroupName", required: true, type: { - name: "String" - } - } + name: "String", + }, + }, }; export const applicationName: OperationURLParameter = { @@ -104,14 +86,25 @@ export const applicationName: OperationURLParameter = { mapper: { constraints: { MaxLength: 64, - MinLength: 3 + MinLength: 3, }, serializedName: "applicationName", required: true, type: { - name: "String" - } - } + name: "String", + }, + }, +}; + +export const subscriptionId: OperationURLParameter = { + parameterPath: "subscriptionId", + mapper: { + serializedName: "subscriptionId", + required: true, + type: { + name: "String", + }, + }, }; export const contentType: OperationParameter = { @@ -121,19 +114,19 @@ export const contentType: OperationParameter = { isConstant: true, serializedName: "Content-Type", type: { - name: "String" - } - } + name: "String", + }, + }, }; export const parameters: OperationParameter = { parameterPath: "parameters", - mapper: ApplicationMapper + mapper: ApplicationMapper, }; export const parameters1: OperationParameter = { parameterPath: ["options", "parameters"], - mapper: ApplicationPatchableMapper + mapper: ApplicationPatchableMapper, }; export const applicationId: OperationURLParameter = { @@ -142,20 +135,15 @@ export const applicationId: OperationURLParameter = { serializedName: "applicationId", required: true, type: { - name: "String" - } + name: "String", + }, }, - skipEncoding: true + skipEncoding: true, }; export const parameters2: OperationParameter = { - parameterPath: "parameters", - mapper: UpdateAccessDefinitionMapper -}; - -export const parameters3: OperationParameter = { - parameterPath: "parameters", - mapper: ListTokenRequestMapper + parameterPath: ["options", "parameters"], + mapper: ApplicationMapper, }; export const applicationDefinitionName: OperationURLParameter = { @@ -163,59 +151,17 @@ export const applicationDefinitionName: OperationURLParameter = { mapper: { constraints: { MaxLength: 64, - MinLength: 3 + MinLength: 3, }, serializedName: "applicationDefinitionName", required: true, type: { - name: "String" - } - } -}; - -export const parameters4: OperationParameter = { - parameterPath: "parameters", - mapper: ApplicationDefinitionMapper -}; - -export const parameters5: OperationParameter = { - parameterPath: "parameters", - mapper: ApplicationDefinitionPatchableMapper -}; - -export const resourceGroupName1: OperationURLParameter = { - parameterPath: "resourceGroupName", - mapper: { - constraints: { - Pattern: new RegExp("^[-\\w\\._\\(\\)]+$"), - MaxLength: 90, - MinLength: 1 + name: "String", }, - serializedName: "resourceGroupName", - required: true, - type: { - name: "String" - } - } -}; - -export const jitRequestName: OperationURLParameter = { - parameterPath: "jitRequestName", - mapper: { - serializedName: "jitRequestName", - required: true, - type: { - name: "String" - } - } -}; - -export const parameters6: OperationParameter = { - parameterPath: "parameters", - mapper: JitRequestDefinitionMapper + }, }; -export const parameters7: OperationParameter = { +export const parameters3: OperationParameter = { parameterPath: "parameters", - mapper: JitRequestPatchableMapper + mapper: ApplicationDefinitionMapper, }; diff --git a/sdk/managedapplications/arm-managedapplications/src/operations/applicationDefinitions.ts b/sdk/managedapplications/arm-managedapplications/src/operations/applicationDefinitions.ts index 079ec224a111..65449d00f205 100644 --- a/sdk/managedapplications/arm-managedapplications/src/operations/applicationDefinitions.ts +++ b/sdk/managedapplications/arm-managedapplications/src/operations/applicationDefinitions.ts @@ -13,31 +13,28 @@ import * as coreClient from "@azure/core-client"; import * as Mappers from "../models/mappers"; import * as Parameters from "../models/parameters"; import { ApplicationClient } from "../applicationClient"; +import { + SimplePollerLike, + OperationState, + createHttpPoller, +} from "@azure/core-lro"; +import { createLroSpec } from "../lroImpl"; import { ApplicationDefinition, ApplicationDefinitionsListByResourceGroupNextOptionalParams, ApplicationDefinitionsListByResourceGroupOptionalParams, ApplicationDefinitionsListByResourceGroupResponse, - ApplicationDefinitionsListBySubscriptionNextOptionalParams, - ApplicationDefinitionsListBySubscriptionOptionalParams, - ApplicationDefinitionsListBySubscriptionResponse, ApplicationDefinitionsGetOptionalParams, ApplicationDefinitionsGetResponse, ApplicationDefinitionsDeleteOptionalParams, ApplicationDefinitionsCreateOrUpdateOptionalParams, ApplicationDefinitionsCreateOrUpdateResponse, - ApplicationDefinitionPatchable, - ApplicationDefinitionsUpdateOptionalParams, - ApplicationDefinitionsUpdateResponse, ApplicationDefinitionsGetByIdOptionalParams, ApplicationDefinitionsGetByIdResponse, ApplicationDefinitionsDeleteByIdOptionalParams, ApplicationDefinitionsCreateOrUpdateByIdOptionalParams, ApplicationDefinitionsCreateOrUpdateByIdResponse, - ApplicationDefinitionsUpdateByIdOptionalParams, - ApplicationDefinitionsUpdateByIdResponse, ApplicationDefinitionsListByResourceGroupNextResponse, - ApplicationDefinitionsListBySubscriptionNextResponse } from "../models"; /// @@ -60,7 +57,7 @@ export class ApplicationDefinitionsImpl implements ApplicationDefinitions { */ public listByResourceGroup( resourceGroupName: string, - options?: ApplicationDefinitionsListByResourceGroupOptionalParams + options?: ApplicationDefinitionsListByResourceGroupOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listByResourceGroupPagingAll(resourceGroupName, options); return { @@ -77,16 +74,16 @@ export class ApplicationDefinitionsImpl implements ApplicationDefinitions { return this.listByResourceGroupPagingPage( resourceGroupName, options, - settings + settings, ); - } + }, }; } private async *listByResourceGroupPagingPage( resourceGroupName: string, options?: ApplicationDefinitionsListByResourceGroupOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: ApplicationDefinitionsListByResourceGroupResponse; let continuationToken = settings?.continuationToken; @@ -101,7 +98,7 @@ export class ApplicationDefinitionsImpl implements ApplicationDefinitions { result = await this._listByResourceGroupNext( resourceGroupName, continuationToken, - options + options, ); continuationToken = result.nextLink; let page = result.value || []; @@ -112,70 +109,16 @@ export class ApplicationDefinitionsImpl implements ApplicationDefinitions { private async *listByResourceGroupPagingAll( resourceGroupName: string, - options?: ApplicationDefinitionsListByResourceGroupOptionalParams + options?: ApplicationDefinitionsListByResourceGroupOptionalParams, ): AsyncIterableIterator { for await (const page of this.listByResourceGroupPagingPage( resourceGroupName, - options + options, )) { yield* page; } } - /** - * Lists all the application definitions within a subscription. - * @param options The options parameters. - */ - public listBySubscription( - options?: ApplicationDefinitionsListBySubscriptionOptionalParams - ): PagedAsyncIterableIterator { - const iter = this.listBySubscriptionPagingAll(options); - return { - next() { - return iter.next(); - }, - [Symbol.asyncIterator]() { - return this; - }, - byPage: (settings?: PageSettings) => { - if (settings?.maxPageSize) { - throw new Error("maxPageSize is not supported by this operation."); - } - return this.listBySubscriptionPagingPage(options, settings); - } - }; - } - - private async *listBySubscriptionPagingPage( - options?: ApplicationDefinitionsListBySubscriptionOptionalParams, - settings?: PageSettings - ): AsyncIterableIterator { - let result: ApplicationDefinitionsListBySubscriptionResponse; - let continuationToken = settings?.continuationToken; - if (!continuationToken) { - result = await this._listBySubscription(options); - let page = result.value || []; - continuationToken = result.nextLink; - setContinuationToken(page, continuationToken); - yield page; - } - while (continuationToken) { - result = await this._listBySubscriptionNext(continuationToken, options); - continuationToken = result.nextLink; - let page = result.value || []; - setContinuationToken(page, continuationToken); - yield page; - } - } - - private async *listBySubscriptionPagingAll( - options?: ApplicationDefinitionsListBySubscriptionOptionalParams - ): AsyncIterableIterator { - for await (const page of this.listBySubscriptionPagingPage(options)) { - yield* page; - } - } - /** * Gets the managed application definition. * @param resourceGroupName The name of the resource group. The name is case insensitive. @@ -185,67 +128,192 @@ export class ApplicationDefinitionsImpl implements ApplicationDefinitions { get( resourceGroupName: string, applicationDefinitionName: string, - options?: ApplicationDefinitionsGetOptionalParams + options?: ApplicationDefinitionsGetOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceGroupName, applicationDefinitionName, options }, - getOperationSpec + getOperationSpec, ); } /** * Deletes the managed application definition. * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param applicationDefinitionName The name of the managed application definition. + * @param applicationDefinitionName The name of the managed application definition to delete. * @param options The options parameters. */ - delete( + async beginDelete( resourceGroupName: string, applicationDefinitionName: string, - options?: ApplicationDefinitionsDeleteOptionalParams + options?: ApplicationDefinitionsDeleteOptionalParams, + ): Promise, void>> { + const directSendOperation = async ( + args: coreClient.OperationArguments, + spec: coreClient.OperationSpec, + ): Promise => { + return this.client.sendOperationRequest(args, spec); + }; + const sendOperationFn = async ( + args: coreClient.OperationArguments, + spec: coreClient.OperationSpec, + ) => { + let currentRawResponse: coreClient.FullOperationResponse | undefined = + undefined; + const providedCallback = args.options?.onResponse; + const callback: coreClient.RawResponseCallback = ( + rawResponse: coreClient.FullOperationResponse, + flatResponse: unknown, + ) => { + currentRawResponse = rawResponse; + providedCallback?.(rawResponse, flatResponse); + }; + const updatedArgs = { + ...args, + options: { + ...args.options, + onResponse: callback, + }, + }; + const flatResponse = await directSendOperation(updatedArgs, spec); + return { + flatResponse, + rawResponse: { + statusCode: currentRawResponse!.status, + body: currentRawResponse!.parsedBody, + headers: currentRawResponse!.headers.toJSON(), + }, + }; + }; + + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, applicationDefinitionName, options }, + spec: deleteOperationSpec, + }); + const poller = await createHttpPoller>(lro, { + restoreFrom: options?.resumeFrom, + intervalInMs: options?.updateIntervalInMs, + }); + await poller.poll(); + return poller; + } + + /** + * Deletes the managed application definition. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param applicationDefinitionName The name of the managed application definition to delete. + * @param options The options parameters. + */ + async beginDeleteAndWait( + resourceGroupName: string, + applicationDefinitionName: string, + options?: ApplicationDefinitionsDeleteOptionalParams, ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, applicationDefinitionName, options }, - deleteOperationSpec + const poller = await this.beginDelete( + resourceGroupName, + applicationDefinitionName, + options, ); + return poller.pollUntilDone(); } /** - * Creates or updates a managed application definition. + * Creates a new managed application definition. * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param applicationDefinitionName The name of the managed application definition. * @param parameters Parameters supplied to the create or update an managed application definition. * @param options The options parameters. */ - createOrUpdate( + async beginCreateOrUpdate( resourceGroupName: string, applicationDefinitionName: string, parameters: ApplicationDefinition, - options?: ApplicationDefinitionsCreateOrUpdateOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, applicationDefinitionName, parameters, options }, - createOrUpdateOperationSpec - ); + options?: ApplicationDefinitionsCreateOrUpdateOptionalParams, + ): Promise< + SimplePollerLike< + OperationState, + ApplicationDefinitionsCreateOrUpdateResponse + > + > { + const directSendOperation = async ( + args: coreClient.OperationArguments, + spec: coreClient.OperationSpec, + ): Promise => { + return this.client.sendOperationRequest(args, spec); + }; + const sendOperationFn = async ( + args: coreClient.OperationArguments, + spec: coreClient.OperationSpec, + ) => { + let currentRawResponse: coreClient.FullOperationResponse | undefined = + undefined; + const providedCallback = args.options?.onResponse; + const callback: coreClient.RawResponseCallback = ( + rawResponse: coreClient.FullOperationResponse, + flatResponse: unknown, + ) => { + currentRawResponse = rawResponse; + providedCallback?.(rawResponse, flatResponse); + }; + const updatedArgs = { + ...args, + options: { + ...args.options, + onResponse: callback, + }, + }; + const flatResponse = await directSendOperation(updatedArgs, spec); + return { + flatResponse, + rawResponse: { + statusCode: currentRawResponse!.status, + body: currentRawResponse!.parsedBody, + headers: currentRawResponse!.headers.toJSON(), + }, + }; + }; + + const lro = createLroSpec({ + sendOperationFn, + args: { + resourceGroupName, + applicationDefinitionName, + parameters, + options, + }, + spec: createOrUpdateOperationSpec, + }); + const poller = await createHttpPoller< + ApplicationDefinitionsCreateOrUpdateResponse, + OperationState + >(lro, { + restoreFrom: options?.resumeFrom, + intervalInMs: options?.updateIntervalInMs, + }); + await poller.poll(); + return poller; } /** - * Updates the managed application definition. + * Creates a new managed application definition. * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param applicationDefinitionName The name of the managed application definition. - * @param parameters Parameters supplied to the update a managed application definition. + * @param parameters Parameters supplied to the create or update an managed application definition. * @param options The options parameters. */ - update( + async beginCreateOrUpdateAndWait( resourceGroupName: string, applicationDefinitionName: string, - parameters: ApplicationDefinitionPatchable, - options?: ApplicationDefinitionsUpdateOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, applicationDefinitionName, parameters, options }, - updateOperationSpec + parameters: ApplicationDefinition, + options?: ApplicationDefinitionsCreateOrUpdateOptionalParams, + ): Promise { + const poller = await this.beginCreateOrUpdate( + resourceGroupName, + applicationDefinitionName, + parameters, + options, ); + return poller.pollUntilDone(); } /** @@ -255,42 +323,91 @@ export class ApplicationDefinitionsImpl implements ApplicationDefinitions { */ private _listByResourceGroup( resourceGroupName: string, - options?: ApplicationDefinitionsListByResourceGroupOptionalParams + options?: ApplicationDefinitionsListByResourceGroupOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceGroupName, options }, - listByResourceGroupOperationSpec + listByResourceGroupOperationSpec, ); } /** - * Lists all the application definitions within a subscription. + * Gets the managed application definition. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param applicationDefinitionName The name of the managed application definition. * @param options The options parameters. */ - private _listBySubscription( - options?: ApplicationDefinitionsListBySubscriptionOptionalParams - ): Promise { + getById( + resourceGroupName: string, + applicationDefinitionName: string, + options?: ApplicationDefinitionsGetByIdOptionalParams, + ): Promise { return this.client.sendOperationRequest( - { options }, - listBySubscriptionOperationSpec + { resourceGroupName, applicationDefinitionName, options }, + getByIdOperationSpec, ); } /** - * Gets the managed application definition. + * Deletes the managed application definition. * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param applicationDefinitionName The name of the managed application definition. * @param options The options parameters. */ - getById( + async beginDeleteById( resourceGroupName: string, applicationDefinitionName: string, - options?: ApplicationDefinitionsGetByIdOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, applicationDefinitionName, options }, - getByIdOperationSpec - ); + options?: ApplicationDefinitionsDeleteByIdOptionalParams, + ): Promise, void>> { + const directSendOperation = async ( + args: coreClient.OperationArguments, + spec: coreClient.OperationSpec, + ): Promise => { + return this.client.sendOperationRequest(args, spec); + }; + const sendOperationFn = async ( + args: coreClient.OperationArguments, + spec: coreClient.OperationSpec, + ) => { + let currentRawResponse: coreClient.FullOperationResponse | undefined = + undefined; + const providedCallback = args.options?.onResponse; + const callback: coreClient.RawResponseCallback = ( + rawResponse: coreClient.FullOperationResponse, + flatResponse: unknown, + ) => { + currentRawResponse = rawResponse; + providedCallback?.(rawResponse, flatResponse); + }; + const updatedArgs = { + ...args, + options: { + ...args.options, + onResponse: callback, + }, + }; + const flatResponse = await directSendOperation(updatedArgs, spec); + return { + flatResponse, + rawResponse: { + statusCode: currentRawResponse!.status, + body: currentRawResponse!.parsedBody, + headers: currentRawResponse!.headers.toJSON(), + }, + }; + }; + + const lro = createLroSpec({ + sendOperationFn, + args: { resourceGroupName, applicationDefinitionName, options }, + spec: deleteByIdOperationSpec, + }); + const poller = await createHttpPoller>(lro, { + restoreFrom: options?.resumeFrom, + intervalInMs: options?.updateIntervalInMs, + }); + await poller.poll(); + return poller; } /** @@ -299,53 +416,116 @@ export class ApplicationDefinitionsImpl implements ApplicationDefinitions { * @param applicationDefinitionName The name of the managed application definition. * @param options The options parameters. */ - deleteById( + async beginDeleteByIdAndWait( resourceGroupName: string, applicationDefinitionName: string, - options?: ApplicationDefinitionsDeleteByIdOptionalParams + options?: ApplicationDefinitionsDeleteByIdOptionalParams, ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, applicationDefinitionName, options }, - deleteByIdOperationSpec + const poller = await this.beginDeleteById( + resourceGroupName, + applicationDefinitionName, + options, ); + return poller.pollUntilDone(); } /** - * Creates or updates a managed application definition. + * Creates a new managed application definition. * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param applicationDefinitionName The name of the managed application definition. * @param parameters Parameters supplied to the create or update a managed application definition. * @param options The options parameters. */ - createOrUpdateById( + async beginCreateOrUpdateById( resourceGroupName: string, applicationDefinitionName: string, parameters: ApplicationDefinition, - options?: ApplicationDefinitionsCreateOrUpdateByIdOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, applicationDefinitionName, parameters, options }, - createOrUpdateByIdOperationSpec - ); + options?: ApplicationDefinitionsCreateOrUpdateByIdOptionalParams, + ): Promise< + SimplePollerLike< + OperationState, + ApplicationDefinitionsCreateOrUpdateByIdResponse + > + > { + const directSendOperation = async ( + args: coreClient.OperationArguments, + spec: coreClient.OperationSpec, + ): Promise => { + return this.client.sendOperationRequest(args, spec); + }; + const sendOperationFn = async ( + args: coreClient.OperationArguments, + spec: coreClient.OperationSpec, + ) => { + let currentRawResponse: coreClient.FullOperationResponse | undefined = + undefined; + const providedCallback = args.options?.onResponse; + const callback: coreClient.RawResponseCallback = ( + rawResponse: coreClient.FullOperationResponse, + flatResponse: unknown, + ) => { + currentRawResponse = rawResponse; + providedCallback?.(rawResponse, flatResponse); + }; + const updatedArgs = { + ...args, + options: { + ...args.options, + onResponse: callback, + }, + }; + const flatResponse = await directSendOperation(updatedArgs, spec); + return { + flatResponse, + rawResponse: { + statusCode: currentRawResponse!.status, + body: currentRawResponse!.parsedBody, + headers: currentRawResponse!.headers.toJSON(), + }, + }; + }; + + const lro = createLroSpec({ + sendOperationFn, + args: { + resourceGroupName, + applicationDefinitionName, + parameters, + options, + }, + spec: createOrUpdateByIdOperationSpec, + }); + const poller = await createHttpPoller< + ApplicationDefinitionsCreateOrUpdateByIdResponse, + OperationState + >(lro, { + restoreFrom: options?.resumeFrom, + intervalInMs: options?.updateIntervalInMs, + }); + await poller.poll(); + return poller; } /** - * Updates the managed application definition. + * Creates a new managed application definition. * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param applicationDefinitionName The name of the managed application definition. - * @param parameters Parameters supplied to the update a managed application definition. + * @param parameters Parameters supplied to the create or update a managed application definition. * @param options The options parameters. */ - updateById( + async beginCreateOrUpdateByIdAndWait( resourceGroupName: string, applicationDefinitionName: string, - parameters: ApplicationDefinitionPatchable, - options?: ApplicationDefinitionsUpdateByIdOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, applicationDefinitionName, parameters, options }, - updateByIdOperationSpec + parameters: ApplicationDefinition, + options?: ApplicationDefinitionsCreateOrUpdateByIdOptionalParams, + ): Promise { + const poller = await this.beginCreateOrUpdateById( + resourceGroupName, + applicationDefinitionName, + parameters, + options, ); + return poller.pollUntilDone(); } /** @@ -357,26 +537,11 @@ export class ApplicationDefinitionsImpl implements ApplicationDefinitions { private _listByResourceGroupNext( resourceGroupName: string, nextLink: string, - options?: ApplicationDefinitionsListByResourceGroupNextOptionalParams + options?: ApplicationDefinitionsListByResourceGroupNextOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceGroupName, nextLink, options }, - listByResourceGroupNextOperationSpec - ); - } - - /** - * ListBySubscriptionNext - * @param nextLink The nextLink from the previous successful call to the ListBySubscription method. - * @param options The options parameters. - */ - private _listBySubscriptionNext( - nextLink: string, - options?: ApplicationDefinitionsListBySubscriptionNextOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { nextLink, options }, - listBySubscriptionNextOperationSpec + listByResourceGroupNextOperationSpec, ); } } @@ -384,269 +549,194 @@ export class ApplicationDefinitionsImpl implements ApplicationDefinitions { const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); const getOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Solutions/applicationDefinitions/{applicationDefinitionName}", + path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Solutions/applicationDefinitions/{applicationDefinitionName}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.ApplicationDefinition + bodyMapper: Mappers.ApplicationDefinition, }, 404: {}, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, - Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.applicationDefinitionName + Parameters.subscriptionId, + Parameters.applicationDefinitionName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const deleteOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Solutions/applicationDefinitions/{applicationDefinitionName}", + path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Solutions/applicationDefinitions/{applicationDefinitionName}", httpMethod: "DELETE", responses: { 200: {}, + 201: {}, + 202: {}, 204: {}, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, - Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.applicationDefinitionName + Parameters.subscriptionId, + Parameters.applicationDefinitionName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const createOrUpdateOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Solutions/applicationDefinitions/{applicationDefinitionName}", + path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Solutions/applicationDefinitions/{applicationDefinitionName}", httpMethod: "PUT", responses: { 200: { - bodyMapper: Mappers.ApplicationDefinition + bodyMapper: Mappers.ApplicationDefinition, }, 201: { - bodyMapper: Mappers.ApplicationDefinition + bodyMapper: Mappers.ApplicationDefinition, }, - default: { - bodyMapper: Mappers.ErrorResponse - } - }, - requestBody: Parameters.parameters4, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.applicationDefinitionName - ], - headerParameters: [Parameters.accept, Parameters.contentType], - mediaType: "json", - serializer -}; -const updateOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Solutions/applicationDefinitions/{applicationDefinitionName}", - httpMethod: "PATCH", - responses: { - 200: { - bodyMapper: Mappers.ApplicationDefinition + 202: { + bodyMapper: Mappers.ApplicationDefinition, + }, + 204: { + bodyMapper: Mappers.ApplicationDefinition, }, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, - requestBody: Parameters.parameters5, + requestBody: Parameters.parameters3, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, - Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.applicationDefinitionName + Parameters.subscriptionId, + Parameters.applicationDefinitionName, ], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", - serializer + serializer, }; const listByResourceGroupOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Solutions/applicationDefinitions", + path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Solutions/applicationDefinitions", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.ApplicationDefinitionListResult + bodyMapper: Mappers.ApplicationDefinitionListResult, }, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, + Parameters.resourceGroupName, Parameters.subscriptionId, - Parameters.resourceGroupName ], headerParameters: [Parameters.accept], - serializer -}; -const listBySubscriptionOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/providers/Microsoft.Solutions/applicationDefinitions", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.ApplicationDefinitionListResult - }, - default: { - bodyMapper: Mappers.ErrorResponse - } - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [Parameters.$host, Parameters.subscriptionId], - headerParameters: [Parameters.accept], - serializer + serializer, }; const getByIdOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Solutions/applicationDefinitions/{applicationDefinitionName}", + path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Solutions/applicationDefinitions/{applicationDefinitionName}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.ApplicationDefinition + bodyMapper: Mappers.ApplicationDefinition, }, 404: {}, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, + Parameters.resourceGroupName, Parameters.subscriptionId, Parameters.applicationDefinitionName, - Parameters.resourceGroupName1 ], headerParameters: [Parameters.accept], - serializer + serializer, }; const deleteByIdOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Solutions/applicationDefinitions/{applicationDefinitionName}", + path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Solutions/applicationDefinitions/{applicationDefinitionName}", httpMethod: "DELETE", responses: { 200: {}, + 201: {}, + 202: {}, 204: {}, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, + Parameters.resourceGroupName, Parameters.subscriptionId, Parameters.applicationDefinitionName, - Parameters.resourceGroupName1 ], headerParameters: [Parameters.accept], - serializer + serializer, }; const createOrUpdateByIdOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Solutions/applicationDefinitions/{applicationDefinitionName}", + path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Solutions/applicationDefinitions/{applicationDefinitionName}", httpMethod: "PUT", responses: { 200: { - bodyMapper: Mappers.ApplicationDefinition + bodyMapper: Mappers.ApplicationDefinition, }, 201: { - bodyMapper: Mappers.ApplicationDefinition + bodyMapper: Mappers.ApplicationDefinition, }, - default: { - bodyMapper: Mappers.ErrorResponse - } - }, - requestBody: Parameters.parameters4, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.applicationDefinitionName, - Parameters.resourceGroupName1 - ], - headerParameters: [Parameters.accept, Parameters.contentType], - mediaType: "json", - serializer -}; -const updateByIdOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Solutions/applicationDefinitions/{applicationDefinitionName}", - httpMethod: "PATCH", - responses: { - 200: { - bodyMapper: Mappers.ApplicationDefinition + 202: { + bodyMapper: Mappers.ApplicationDefinition, + }, + 204: { + bodyMapper: Mappers.ApplicationDefinition, }, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, - requestBody: Parameters.parameters5, + requestBody: Parameters.parameters3, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, - Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.applicationDefinitionName + Parameters.subscriptionId, + Parameters.applicationDefinitionName, ], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", - serializer + serializer, }; const listByResourceGroupNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.ApplicationDefinitionListResult + bodyMapper: Mappers.ApplicationDefinitionListResult, }, default: { - bodyMapper: Mappers.ErrorResponse - } - }, - urlParameters: [ - Parameters.$host, - Parameters.nextLink, - Parameters.subscriptionId, - Parameters.resourceGroupName - ], - headerParameters: [Parameters.accept], - serializer -}; -const listBySubscriptionNextOperationSpec: coreClient.OperationSpec = { - path: "{nextLink}", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.ApplicationDefinitionListResult + bodyMapper: Mappers.ErrorResponse, }, - default: { - bodyMapper: Mappers.ErrorResponse - } }, urlParameters: [ Parameters.$host, Parameters.nextLink, - Parameters.subscriptionId + Parameters.resourceGroupName, + Parameters.subscriptionId, ], headerParameters: [Parameters.accept], - serializer + serializer, }; diff --git a/sdk/managedapplications/arm-managedapplications/src/operations/applications.ts b/sdk/managedapplications/arm-managedapplications/src/operations/applications.ts index 7b4ccff523fa..fc81599db921 100644 --- a/sdk/managedapplications/arm-managedapplications/src/operations/applications.ts +++ b/sdk/managedapplications/arm-managedapplications/src/operations/applications.ts @@ -16,7 +16,7 @@ import { ApplicationClient } from "../applicationClient"; import { SimplePollerLike, OperationState, - createHttpPoller + createHttpPoller, } from "@azure/core-lro"; import { createLroSpec } from "../lroImpl"; import { @@ -41,16 +41,8 @@ import { ApplicationsCreateOrUpdateByIdResponse, ApplicationsUpdateByIdOptionalParams, ApplicationsUpdateByIdResponse, - ApplicationsRefreshPermissionsOptionalParams, - ApplicationsListAllowedUpgradePlansOptionalParams, - ApplicationsListAllowedUpgradePlansResponse, - UpdateAccessDefinition, - ApplicationsUpdateAccessOptionalParams, - ListTokenRequest, - ApplicationsListTokensOptionalParams, - ApplicationsListTokensResponse, ApplicationsListByResourceGroupNextResponse, - ApplicationsListBySubscriptionNextResponse + ApplicationsListBySubscriptionNextResponse, } from "../models"; /// @@ -67,13 +59,13 @@ export class ApplicationsImpl implements Applications { } /** - * Lists all the applications within a resource group. + * Gets all the applications within a resource group. * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param options The options parameters. */ public listByResourceGroup( resourceGroupName: string, - options?: ApplicationsListByResourceGroupOptionalParams + options?: ApplicationsListByResourceGroupOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listByResourceGroupPagingAll(resourceGroupName, options); return { @@ -90,16 +82,16 @@ export class ApplicationsImpl implements Applications { return this.listByResourceGroupPagingPage( resourceGroupName, options, - settings + settings, ); - } + }, }; } private async *listByResourceGroupPagingPage( resourceGroupName: string, options?: ApplicationsListByResourceGroupOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: ApplicationsListByResourceGroupResponse; let continuationToken = settings?.continuationToken; @@ -114,7 +106,7 @@ export class ApplicationsImpl implements Applications { result = await this._listByResourceGroupNext( resourceGroupName, continuationToken, - options + options, ); continuationToken = result.nextLink; let page = result.value || []; @@ -125,22 +117,22 @@ export class ApplicationsImpl implements Applications { private async *listByResourceGroupPagingAll( resourceGroupName: string, - options?: ApplicationsListByResourceGroupOptionalParams + options?: ApplicationsListByResourceGroupOptionalParams, ): AsyncIterableIterator { for await (const page of this.listByResourceGroupPagingPage( resourceGroupName, - options + options, )) { yield* page; } } /** - * Lists all the applications within a subscription. + * Gets all the applications within a subscription. * @param options The options parameters. */ public listBySubscription( - options?: ApplicationsListBySubscriptionOptionalParams + options?: ApplicationsListBySubscriptionOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listBySubscriptionPagingAll(options); return { @@ -155,13 +147,13 @@ export class ApplicationsImpl implements Applications { throw new Error("maxPageSize is not supported by this operation."); } return this.listBySubscriptionPagingPage(options, settings); - } + }, }; } private async *listBySubscriptionPagingPage( options?: ApplicationsListBySubscriptionOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: ApplicationsListBySubscriptionResponse; let continuationToken = settings?.continuationToken; @@ -182,7 +174,7 @@ export class ApplicationsImpl implements Applications { } private async *listBySubscriptionPagingAll( - options?: ApplicationsListBySubscriptionOptionalParams + options?: ApplicationsListBySubscriptionOptionalParams, ): AsyncIterableIterator { for await (const page of this.listBySubscriptionPagingPage(options)) { yield* page; @@ -198,11 +190,11 @@ export class ApplicationsImpl implements Applications { get( resourceGroupName: string, applicationName: string, - options?: ApplicationsGetOptionalParams + options?: ApplicationsGetOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceGroupName, applicationName, options }, - getOperationSpec + getOperationSpec, ); } @@ -215,25 +207,24 @@ export class ApplicationsImpl implements Applications { async beginDelete( resourceGroupName: string, applicationName: string, - options?: ApplicationsDeleteOptionalParams + options?: ApplicationsDeleteOptionalParams, ): Promise, void>> { const directSendOperation = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ): Promise => { return this.client.sendOperationRequest(args, spec); }; const sendOperationFn = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; + let currentRawResponse: coreClient.FullOperationResponse | undefined = + undefined; const providedCallback = args.options?.onResponse; const callback: coreClient.RawResponseCallback = ( rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown + flatResponse: unknown, ) => { currentRawResponse = rawResponse; providedCallback?.(rawResponse, flatResponse); @@ -242,8 +233,8 @@ export class ApplicationsImpl implements Applications { ...args, options: { ...args.options, - onResponse: callback - } + onResponse: callback, + }, }; const flatResponse = await directSendOperation(updatedArgs, spec); return { @@ -251,20 +242,19 @@ export class ApplicationsImpl implements Applications { rawResponse: { statusCode: currentRawResponse!.status, body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } + headers: currentRawResponse!.headers.toJSON(), + }, }; }; const lro = createLroSpec({ sendOperationFn, args: { resourceGroupName, applicationName, options }, - spec: deleteOperationSpec + spec: deleteOperationSpec, }); const poller = await createHttpPoller>(lro, { restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs, - resourceLocationConfig: "azure-async-operation" }); await poller.poll(); return poller; @@ -279,18 +269,18 @@ export class ApplicationsImpl implements Applications { async beginDeleteAndWait( resourceGroupName: string, applicationName: string, - options?: ApplicationsDeleteOptionalParams + options?: ApplicationsDeleteOptionalParams, ): Promise { const poller = await this.beginDelete( resourceGroupName, applicationName, - options + options, ); return poller.pollUntilDone(); } /** - * Creates or updates a managed application. + * Creates a new managed application. * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param applicationName The name of the managed application. * @param parameters Parameters supplied to the create or update a managed application. @@ -300,7 +290,7 @@ export class ApplicationsImpl implements Applications { resourceGroupName: string, applicationName: string, parameters: Application, - options?: ApplicationsCreateOrUpdateOptionalParams + options?: ApplicationsCreateOrUpdateOptionalParams, ): Promise< SimplePollerLike< OperationState, @@ -309,21 +299,20 @@ export class ApplicationsImpl implements Applications { > { const directSendOperation = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ): Promise => { return this.client.sendOperationRequest(args, spec); }; const sendOperationFn = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; + let currentRawResponse: coreClient.FullOperationResponse | undefined = + undefined; const providedCallback = args.options?.onResponse; const callback: coreClient.RawResponseCallback = ( rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown + flatResponse: unknown, ) => { currentRawResponse = rawResponse; providedCallback?.(rawResponse, flatResponse); @@ -332,8 +321,8 @@ export class ApplicationsImpl implements Applications { ...args, options: { ...args.options, - onResponse: callback - } + onResponse: callback, + }, }; const flatResponse = await directSendOperation(updatedArgs, spec); return { @@ -341,15 +330,15 @@ export class ApplicationsImpl implements Applications { rawResponse: { statusCode: currentRawResponse!.status, body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } + headers: currentRawResponse!.headers.toJSON(), + }, }; }; const lro = createLroSpec({ sendOperationFn, args: { resourceGroupName, applicationName, parameters, options }, - spec: createOrUpdateOperationSpec + spec: createOrUpdateOperationSpec, }); const poller = await createHttpPoller< ApplicationsCreateOrUpdateResponse, @@ -357,14 +346,13 @@ export class ApplicationsImpl implements Applications { >(lro, { restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs, - resourceLocationConfig: "azure-async-operation" }); await poller.poll(); return poller; } /** - * Creates or updates a managed application. + * Creates a new managed application. * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param applicationName The name of the managed application. * @param parameters Parameters supplied to the create or update a managed application. @@ -374,133 +362,60 @@ export class ApplicationsImpl implements Applications { resourceGroupName: string, applicationName: string, parameters: Application, - options?: ApplicationsCreateOrUpdateOptionalParams + options?: ApplicationsCreateOrUpdateOptionalParams, ): Promise { const poller = await this.beginCreateOrUpdate( resourceGroupName, applicationName, parameters, - options + options, ); return poller.pollUntilDone(); } /** - * Updates an existing managed application. + * Updates an existing managed application. The only value that can be updated via PATCH currently is + * the tags. * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param applicationName The name of the managed application. * @param options The options parameters. */ - async beginUpdate( + update( resourceGroupName: string, applicationName: string, - options?: ApplicationsUpdateOptionalParams - ): Promise< - SimplePollerLike< - OperationState, - ApplicationsUpdateResponse - > - > { - const directSendOperation = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ): Promise => { - return this.client.sendOperationRequest(args, spec); - }; - const sendOperationFn = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; - const providedCallback = args.options?.onResponse; - const callback: coreClient.RawResponseCallback = ( - rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown - ) => { - currentRawResponse = rawResponse; - providedCallback?.(rawResponse, flatResponse); - }; - const updatedArgs = { - ...args, - options: { - ...args.options, - onResponse: callback - } - }; - const flatResponse = await directSendOperation(updatedArgs, spec); - return { - flatResponse, - rawResponse: { - statusCode: currentRawResponse!.status, - body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } - }; - }; - - const lro = createLroSpec({ - sendOperationFn, - args: { resourceGroupName, applicationName, options }, - spec: updateOperationSpec - }); - const poller = await createHttpPoller< - ApplicationsUpdateResponse, - OperationState - >(lro, { - restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs, - resourceLocationConfig: "azure-async-operation" - }); - await poller.poll(); - return poller; - } - - /** - * Updates an existing managed application. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param applicationName The name of the managed application. - * @param options The options parameters. - */ - async beginUpdateAndWait( - resourceGroupName: string, - applicationName: string, - options?: ApplicationsUpdateOptionalParams + options?: ApplicationsUpdateOptionalParams, ): Promise { - const poller = await this.beginUpdate( - resourceGroupName, - applicationName, - options + return this.client.sendOperationRequest( + { resourceGroupName, applicationName, options }, + updateOperationSpec, ); - return poller.pollUntilDone(); } /** - * Lists all the applications within a resource group. + * Gets all the applications within a resource group. * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param options The options parameters. */ private _listByResourceGroup( resourceGroupName: string, - options?: ApplicationsListByResourceGroupOptionalParams + options?: ApplicationsListByResourceGroupOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceGroupName, options }, - listByResourceGroupOperationSpec + listByResourceGroupOperationSpec, ); } /** - * Lists all the applications within a subscription. + * Gets all the applications within a subscription. * @param options The options parameters. */ private _listBySubscription( - options?: ApplicationsListBySubscriptionOptionalParams + options?: ApplicationsListBySubscriptionOptionalParams, ): Promise { return this.client.sendOperationRequest( { options }, - listBySubscriptionOperationSpec + listBySubscriptionOperationSpec, ); } @@ -513,11 +428,11 @@ export class ApplicationsImpl implements Applications { */ getById( applicationId: string, - options?: ApplicationsGetByIdOptionalParams + options?: ApplicationsGetByIdOptionalParams, ): Promise { return this.client.sendOperationRequest( { applicationId, options }, - getByIdOperationSpec + getByIdOperationSpec, ); } @@ -530,25 +445,24 @@ export class ApplicationsImpl implements Applications { */ async beginDeleteById( applicationId: string, - options?: ApplicationsDeleteByIdOptionalParams + options?: ApplicationsDeleteByIdOptionalParams, ): Promise, void>> { const directSendOperation = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ): Promise => { return this.client.sendOperationRequest(args, spec); }; const sendOperationFn = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; + let currentRawResponse: coreClient.FullOperationResponse | undefined = + undefined; const providedCallback = args.options?.onResponse; const callback: coreClient.RawResponseCallback = ( rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown + flatResponse: unknown, ) => { currentRawResponse = rawResponse; providedCallback?.(rawResponse, flatResponse); @@ -557,8 +471,8 @@ export class ApplicationsImpl implements Applications { ...args, options: { ...args.options, - onResponse: callback - } + onResponse: callback, + }, }; const flatResponse = await directSendOperation(updatedArgs, spec); return { @@ -566,20 +480,19 @@ export class ApplicationsImpl implements Applications { rawResponse: { statusCode: currentRawResponse!.status, body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } + headers: currentRawResponse!.headers.toJSON(), + }, }; }; const lro = createLroSpec({ sendOperationFn, args: { applicationId, options }, - spec: deleteByIdOperationSpec + spec: deleteByIdOperationSpec, }); const poller = await createHttpPoller>(lro, { restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs, - resourceLocationConfig: "azure-async-operation" }); await poller.poll(); return poller; @@ -594,14 +507,14 @@ export class ApplicationsImpl implements Applications { */ async beginDeleteByIdAndWait( applicationId: string, - options?: ApplicationsDeleteByIdOptionalParams + options?: ApplicationsDeleteByIdOptionalParams, ): Promise { const poller = await this.beginDeleteById(applicationId, options); return poller.pollUntilDone(); } /** - * Creates or updates a managed application. + * Creates a new managed application. * @param applicationId The fully qualified ID of the managed application, including the managed * application name and the managed application resource type. Use the format, * /subscriptions/{guid}/resourceGroups/{resource-group-name}/Microsoft.Solutions/applications/{application-name} @@ -611,7 +524,7 @@ export class ApplicationsImpl implements Applications { async beginCreateOrUpdateById( applicationId: string, parameters: Application, - options?: ApplicationsCreateOrUpdateByIdOptionalParams + options?: ApplicationsCreateOrUpdateByIdOptionalParams, ): Promise< SimplePollerLike< OperationState, @@ -620,21 +533,20 @@ export class ApplicationsImpl implements Applications { > { const directSendOperation = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ): Promise => { return this.client.sendOperationRequest(args, spec); }; const sendOperationFn = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; + let currentRawResponse: coreClient.FullOperationResponse | undefined = + undefined; const providedCallback = args.options?.onResponse; const callback: coreClient.RawResponseCallback = ( rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown + flatResponse: unknown, ) => { currentRawResponse = rawResponse; providedCallback?.(rawResponse, flatResponse); @@ -643,8 +555,8 @@ export class ApplicationsImpl implements Applications { ...args, options: { ...args.options, - onResponse: callback - } + onResponse: callback, + }, }; const flatResponse = await directSendOperation(updatedArgs, spec); return { @@ -652,15 +564,15 @@ export class ApplicationsImpl implements Applications { rawResponse: { statusCode: currentRawResponse!.status, body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } + headers: currentRawResponse!.headers.toJSON(), + }, }; }; const lro = createLroSpec({ sendOperationFn, args: { applicationId, parameters, options }, - spec: createOrUpdateByIdOperationSpec + spec: createOrUpdateByIdOperationSpec, }); const poller = await createHttpPoller< ApplicationsCreateOrUpdateByIdResponse, @@ -668,14 +580,13 @@ export class ApplicationsImpl implements Applications { >(lro, { restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs, - resourceLocationConfig: "azure-async-operation" }); await poller.poll(); return poller; } /** - * Creates or updates a managed application. + * Creates a new managed application. * @param applicationId The fully qualified ID of the managed application, including the managed * application name and the managed application resource type. Use the format, * /subscriptions/{guid}/resourceGroups/{resource-group-name}/Microsoft.Solutions/applications/{application-name} @@ -685,307 +596,31 @@ export class ApplicationsImpl implements Applications { async beginCreateOrUpdateByIdAndWait( applicationId: string, parameters: Application, - options?: ApplicationsCreateOrUpdateByIdOptionalParams + options?: ApplicationsCreateOrUpdateByIdOptionalParams, ): Promise { const poller = await this.beginCreateOrUpdateById( applicationId, parameters, - options + options, ); return poller.pollUntilDone(); } /** - * Updates an existing managed application. + * Updates an existing managed application. The only value that can be updated via PATCH currently is + * the tags. * @param applicationId The fully qualified ID of the managed application, including the managed * application name and the managed application resource type. Use the format, * /subscriptions/{guid}/resourceGroups/{resource-group-name}/Microsoft.Solutions/applications/{application-name} * @param options The options parameters. */ - async beginUpdateById( + updateById( applicationId: string, - options?: ApplicationsUpdateByIdOptionalParams - ): Promise< - SimplePollerLike< - OperationState, - ApplicationsUpdateByIdResponse - > - > { - const directSendOperation = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ): Promise => { - return this.client.sendOperationRequest(args, spec); - }; - const sendOperationFn = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; - const providedCallback = args.options?.onResponse; - const callback: coreClient.RawResponseCallback = ( - rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown - ) => { - currentRawResponse = rawResponse; - providedCallback?.(rawResponse, flatResponse); - }; - const updatedArgs = { - ...args, - options: { - ...args.options, - onResponse: callback - } - }; - const flatResponse = await directSendOperation(updatedArgs, spec); - return { - flatResponse, - rawResponse: { - statusCode: currentRawResponse!.status, - body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } - }; - }; - - const lro = createLroSpec({ - sendOperationFn, - args: { applicationId, options }, - spec: updateByIdOperationSpec - }); - const poller = await createHttpPoller< - ApplicationsUpdateByIdResponse, - OperationState - >(lro, { - restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs, - resourceLocationConfig: "azure-async-operation" - }); - await poller.poll(); - return poller; - } - - /** - * Updates an existing managed application. - * @param applicationId The fully qualified ID of the managed application, including the managed - * application name and the managed application resource type. Use the format, - * /subscriptions/{guid}/resourceGroups/{resource-group-name}/Microsoft.Solutions/applications/{application-name} - * @param options The options parameters. - */ - async beginUpdateByIdAndWait( - applicationId: string, - options?: ApplicationsUpdateByIdOptionalParams + options?: ApplicationsUpdateByIdOptionalParams, ): Promise { - const poller = await this.beginUpdateById(applicationId, options); - return poller.pollUntilDone(); - } - - /** - * Refresh Permissions for application. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param applicationName The name of the managed application. - * @param options The options parameters. - */ - async beginRefreshPermissions( - resourceGroupName: string, - applicationName: string, - options?: ApplicationsRefreshPermissionsOptionalParams - ): Promise, void>> { - const directSendOperation = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ): Promise => { - return this.client.sendOperationRequest(args, spec); - }; - const sendOperationFn = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; - const providedCallback = args.options?.onResponse; - const callback: coreClient.RawResponseCallback = ( - rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown - ) => { - currentRawResponse = rawResponse; - providedCallback?.(rawResponse, flatResponse); - }; - const updatedArgs = { - ...args, - options: { - ...args.options, - onResponse: callback - } - }; - const flatResponse = await directSendOperation(updatedArgs, spec); - return { - flatResponse, - rawResponse: { - statusCode: currentRawResponse!.status, - body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } - }; - }; - - const lro = createLroSpec({ - sendOperationFn, - args: { resourceGroupName, applicationName, options }, - spec: refreshPermissionsOperationSpec - }); - const poller = await createHttpPoller>(lro, { - restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs, - resourceLocationConfig: "location" - }); - await poller.poll(); - return poller; - } - - /** - * Refresh Permissions for application. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param applicationName The name of the managed application. - * @param options The options parameters. - */ - async beginRefreshPermissionsAndWait( - resourceGroupName: string, - applicationName: string, - options?: ApplicationsRefreshPermissionsOptionalParams - ): Promise { - const poller = await this.beginRefreshPermissions( - resourceGroupName, - applicationName, - options - ); - return poller.pollUntilDone(); - } - - /** - * List allowed upgrade plans for application. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param applicationName The name of the managed application. - * @param options The options parameters. - */ - listAllowedUpgradePlans( - resourceGroupName: string, - applicationName: string, - options?: ApplicationsListAllowedUpgradePlansOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, applicationName, options }, - listAllowedUpgradePlansOperationSpec - ); - } - - /** - * Update access for application. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param applicationName The name of the managed application. - * @param parameters Request body parameters to list tokens. - * @param options The options parameters. - */ - async beginUpdateAccess( - resourceGroupName: string, - applicationName: string, - parameters: UpdateAccessDefinition, - options?: ApplicationsUpdateAccessOptionalParams - ): Promise, void>> { - const directSendOperation = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ): Promise => { - return this.client.sendOperationRequest(args, spec); - }; - const sendOperationFn = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; - const providedCallback = args.options?.onResponse; - const callback: coreClient.RawResponseCallback = ( - rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown - ) => { - currentRawResponse = rawResponse; - providedCallback?.(rawResponse, flatResponse); - }; - const updatedArgs = { - ...args, - options: { - ...args.options, - onResponse: callback - } - }; - const flatResponse = await directSendOperation(updatedArgs, spec); - return { - flatResponse, - rawResponse: { - statusCode: currentRawResponse!.status, - body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } - }; - }; - - const lro = createLroSpec({ - sendOperationFn, - args: { resourceGroupName, applicationName, parameters, options }, - spec: updateAccessOperationSpec - }); - const poller = await createHttpPoller>(lro, { - restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs, - resourceLocationConfig: "location" - }); - await poller.poll(); - return poller; - } - - /** - * Update access for application. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param applicationName The name of the managed application. - * @param parameters Request body parameters to list tokens. - * @param options The options parameters. - */ - async beginUpdateAccessAndWait( - resourceGroupName: string, - applicationName: string, - parameters: UpdateAccessDefinition, - options?: ApplicationsUpdateAccessOptionalParams - ): Promise { - const poller = await this.beginUpdateAccess( - resourceGroupName, - applicationName, - parameters, - options - ); - return poller.pollUntilDone(); - } - - /** - * List tokens for application. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param applicationName The name of the managed application. - * @param parameters Request body parameters to list tokens. - * @param options The options parameters. - */ - listTokens( - resourceGroupName: string, - applicationName: string, - parameters: ListTokenRequest, - options?: ApplicationsListTokensOptionalParams - ): Promise { return this.client.sendOperationRequest( - { resourceGroupName, applicationName, parameters, options }, - listTokensOperationSpec + { applicationId, options }, + updateByIdOperationSpec, ); } @@ -998,11 +633,11 @@ export class ApplicationsImpl implements Applications { private _listByResourceGroupNext( resourceGroupName: string, nextLink: string, - options?: ApplicationsListByResourceGroupNextOptionalParams + options?: ApplicationsListByResourceGroupNextOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceGroupName, nextLink, options }, - listByResourceGroupNextOperationSpec + listByResourceGroupNextOperationSpec, ); } @@ -1013,11 +648,11 @@ export class ApplicationsImpl implements Applications { */ private _listBySubscriptionNext( nextLink: string, - options?: ApplicationsListBySubscriptionNextOptionalParams + options?: ApplicationsListBySubscriptionNextOptionalParams, ): Promise { return this.client.sendOperationRequest( { nextLink, options }, - listBySubscriptionNextOperationSpec + listBySubscriptionNextOperationSpec, ); } } @@ -1025,31 +660,29 @@ export class ApplicationsImpl implements Applications { const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); const getOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Solutions/applications/{applicationName}", + path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Solutions/applications/{applicationName}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.Application + bodyMapper: Mappers.Application, }, 404: {}, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, - Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.applicationName + Parameters.applicationName, + Parameters.subscriptionId, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const deleteOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Solutions/applications/{applicationName}", + path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Solutions/applications/{applicationName}", httpMethod: "DELETE", responses: { 200: {}, @@ -1057,139 +690,126 @@ const deleteOperationSpec: coreClient.OperationSpec = { 202: {}, 204: {}, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, - Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.applicationName + Parameters.applicationName, + Parameters.subscriptionId, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const createOrUpdateOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Solutions/applications/{applicationName}", + path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Solutions/applications/{applicationName}", httpMethod: "PUT", responses: { 200: { - bodyMapper: Mappers.Application + bodyMapper: Mappers.Application, }, 201: { - bodyMapper: Mappers.Application + bodyMapper: Mappers.Application, }, 202: { - bodyMapper: Mappers.Application + bodyMapper: Mappers.Application, }, 204: { - bodyMapper: Mappers.Application + bodyMapper: Mappers.Application, }, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, requestBody: Parameters.parameters, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, - Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.applicationName + Parameters.applicationName, + Parameters.subscriptionId, ], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", - serializer + serializer, }; const updateOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Solutions/applications/{applicationName}", + path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Solutions/applications/{applicationName}", httpMethod: "PATCH", responses: { 200: { - bodyMapper: Mappers.ApplicationPatchable - }, - 201: { - bodyMapper: Mappers.ApplicationPatchable - }, - 202: { - bodyMapper: Mappers.ApplicationPatchable - }, - 204: { - bodyMapper: Mappers.ApplicationPatchable + bodyMapper: Mappers.Application, }, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, requestBody: Parameters.parameters1, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, - Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.applicationName + Parameters.applicationName, + Parameters.subscriptionId, ], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", - serializer + serializer, }; const listByResourceGroupOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Solutions/applications", + path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Solutions/applications", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.ApplicationListResult + bodyMapper: Mappers.ApplicationListResult, }, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, + Parameters.resourceGroupName, Parameters.subscriptionId, - Parameters.resourceGroupName ], headerParameters: [Parameters.accept], - serializer + serializer, }; const listBySubscriptionOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/providers/Microsoft.Solutions/applications", + path: "/subscriptions/{subscriptionId}/providers/Microsoft.Solutions/applications", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.ApplicationListResult + bodyMapper: Mappers.ApplicationListResult, }, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [Parameters.$host, Parameters.subscriptionId], headerParameters: [Parameters.accept], - serializer + serializer, }; const getByIdOperationSpec: coreClient.OperationSpec = { path: "/{applicationId}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.Application + bodyMapper: Mappers.Application, }, 404: {}, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [Parameters.$host, Parameters.applicationId], headerParameters: [Parameters.accept], - serializer + serializer, }; const deleteByIdOperationSpec: coreClient.OperationSpec = { path: "/{applicationId}", @@ -1200,198 +820,95 @@ const deleteByIdOperationSpec: coreClient.OperationSpec = { 202: {}, 204: {}, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [Parameters.$host, Parameters.applicationId], headerParameters: [Parameters.accept], - serializer + serializer, }; const createOrUpdateByIdOperationSpec: coreClient.OperationSpec = { path: "/{applicationId}", httpMethod: "PUT", responses: { 200: { - bodyMapper: Mappers.Application + bodyMapper: Mappers.Application, }, 201: { - bodyMapper: Mappers.Application + bodyMapper: Mappers.Application, }, 202: { - bodyMapper: Mappers.Application + bodyMapper: Mappers.Application, }, 204: { - bodyMapper: Mappers.Application + bodyMapper: Mappers.Application, }, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, requestBody: Parameters.parameters, queryParameters: [Parameters.apiVersion], urlParameters: [Parameters.$host, Parameters.applicationId], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", - serializer + serializer, }; const updateByIdOperationSpec: coreClient.OperationSpec = { path: "/{applicationId}", httpMethod: "PATCH", responses: { 200: { - bodyMapper: Mappers.ApplicationPatchable - }, - 201: { - bodyMapper: Mappers.ApplicationPatchable - }, - 202: { - bodyMapper: Mappers.ApplicationPatchable + bodyMapper: Mappers.Application, }, - 204: { - bodyMapper: Mappers.ApplicationPatchable - }, - default: { - bodyMapper: Mappers.ErrorResponse - } - }, - requestBody: Parameters.parameters1, - queryParameters: [Parameters.apiVersion], - urlParameters: [Parameters.$host, Parameters.applicationId], - headerParameters: [Parameters.accept, Parameters.contentType], - mediaType: "json", - serializer -}; -const refreshPermissionsOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Solutions/applications/{applicationName}/refreshPermissions", - httpMethod: "POST", - responses: { - 200: {}, - 201: {}, - 202: {}, - 204: {}, default: { - bodyMapper: Mappers.ErrorResponse - } - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.applicationName - ], - headerParameters: [Parameters.accept], - serializer -}; -const listAllowedUpgradePlansOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Solutions/applications/{applicationName}/listAllowedUpgradePlans", - httpMethod: "POST", - responses: { - 200: { - bodyMapper: Mappers.AllowedUpgradePlansResult + bodyMapper: Mappers.ErrorResponse, }, - default: { - bodyMapper: Mappers.ErrorResponse - } - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.applicationName - ], - headerParameters: [Parameters.accept], - serializer -}; -const updateAccessOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Solutions/applications/{applicationName}/updateAccess", - httpMethod: "POST", - responses: { - 200: {}, - 201: {}, - 202: {}, - 204: {}, - default: { - bodyMapper: Mappers.ErrorResponse - } }, requestBody: Parameters.parameters2, queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.applicationName - ], - headerParameters: [Parameters.accept, Parameters.contentType], - mediaType: "json", - serializer -}; -const listTokensOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Solutions/applications/{applicationName}/listTokens", - httpMethod: "POST", - responses: { - 200: { - bodyMapper: Mappers.ManagedIdentityTokenResult - }, - default: { - bodyMapper: Mappers.ErrorResponse - } - }, - requestBody: Parameters.parameters3, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.applicationName - ], + urlParameters: [Parameters.$host, Parameters.applicationId], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", - serializer + serializer, }; const listByResourceGroupNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.ApplicationListResult + bodyMapper: Mappers.ApplicationListResult, }, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, urlParameters: [ Parameters.$host, Parameters.nextLink, + Parameters.resourceGroupName, Parameters.subscriptionId, - Parameters.resourceGroupName ], headerParameters: [Parameters.accept], - serializer + serializer, }; const listBySubscriptionNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.ApplicationListResult + bodyMapper: Mappers.ApplicationListResult, }, default: { - bodyMapper: Mappers.ErrorResponse - } + bodyMapper: Mappers.ErrorResponse, + }, }, urlParameters: [ Parameters.$host, Parameters.nextLink, - Parameters.subscriptionId + Parameters.subscriptionId, ], headerParameters: [Parameters.accept], - serializer + serializer, }; diff --git a/sdk/managedapplications/arm-managedapplications/src/operations/index.ts b/sdk/managedapplications/arm-managedapplications/src/operations/index.ts index 63259e0e45c4..6ca98c210b1c 100644 --- a/sdk/managedapplications/arm-managedapplications/src/operations/index.ts +++ b/sdk/managedapplications/arm-managedapplications/src/operations/index.ts @@ -8,4 +8,3 @@ export * from "./applications"; export * from "./applicationDefinitions"; -export * from "./jitRequests"; diff --git a/sdk/managedapplications/arm-managedapplications/src/operations/jitRequests.ts b/sdk/managedapplications/arm-managedapplications/src/operations/jitRequests.ts deleted file mode 100644 index 1005d0e2b145..000000000000 --- a/sdk/managedapplications/arm-managedapplications/src/operations/jitRequests.ts +++ /dev/null @@ -1,366 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -import { JitRequests } from "../operationsInterfaces"; -import * as coreClient from "@azure/core-client"; -import * as Mappers from "../models/mappers"; -import * as Parameters from "../models/parameters"; -import { ApplicationClient } from "../applicationClient"; -import { - SimplePollerLike, - OperationState, - createHttpPoller -} from "@azure/core-lro"; -import { createLroSpec } from "../lroImpl"; -import { - JitRequestsGetOptionalParams, - JitRequestsGetResponse, - JitRequestDefinition, - JitRequestsCreateOrUpdateOptionalParams, - JitRequestsCreateOrUpdateResponse, - JitRequestPatchable, - JitRequestsUpdateOptionalParams, - JitRequestsUpdateResponse, - JitRequestsDeleteOptionalParams, - JitRequestsListBySubscriptionOptionalParams, - JitRequestsListBySubscriptionResponse, - JitRequestsListByResourceGroupOptionalParams, - JitRequestsListByResourceGroupResponse -} from "../models"; - -/** Class containing JitRequests operations. */ -export class JitRequestsImpl implements JitRequests { - private readonly client: ApplicationClient; - - /** - * Initialize a new instance of the class JitRequests class. - * @param client Reference to the service client - */ - constructor(client: ApplicationClient) { - this.client = client; - } - - /** - * Gets the JIT request. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param jitRequestName The name of the JIT request. - * @param options The options parameters. - */ - get( - resourceGroupName: string, - jitRequestName: string, - options?: JitRequestsGetOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, jitRequestName, options }, - getOperationSpec - ); - } - - /** - * Creates or updates the JIT request. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param jitRequestName The name of the JIT request. - * @param parameters Parameters supplied to the update JIT request. - * @param options The options parameters. - */ - async beginCreateOrUpdate( - resourceGroupName: string, - jitRequestName: string, - parameters: JitRequestDefinition, - options?: JitRequestsCreateOrUpdateOptionalParams - ): Promise< - SimplePollerLike< - OperationState, - JitRequestsCreateOrUpdateResponse - > - > { - const directSendOperation = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ): Promise => { - return this.client.sendOperationRequest(args, spec); - }; - const sendOperationFn = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; - const providedCallback = args.options?.onResponse; - const callback: coreClient.RawResponseCallback = ( - rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown - ) => { - currentRawResponse = rawResponse; - providedCallback?.(rawResponse, flatResponse); - }; - const updatedArgs = { - ...args, - options: { - ...args.options, - onResponse: callback - } - }; - const flatResponse = await directSendOperation(updatedArgs, spec); - return { - flatResponse, - rawResponse: { - statusCode: currentRawResponse!.status, - body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } - }; - }; - - const lro = createLroSpec({ - sendOperationFn, - args: { resourceGroupName, jitRequestName, parameters, options }, - spec: createOrUpdateOperationSpec - }); - const poller = await createHttpPoller< - JitRequestsCreateOrUpdateResponse, - OperationState - >(lro, { - restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs, - resourceLocationConfig: "azure-async-operation" - }); - await poller.poll(); - return poller; - } - - /** - * Creates or updates the JIT request. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param jitRequestName The name of the JIT request. - * @param parameters Parameters supplied to the update JIT request. - * @param options The options parameters. - */ - async beginCreateOrUpdateAndWait( - resourceGroupName: string, - jitRequestName: string, - parameters: JitRequestDefinition, - options?: JitRequestsCreateOrUpdateOptionalParams - ): Promise { - const poller = await this.beginCreateOrUpdate( - resourceGroupName, - jitRequestName, - parameters, - options - ); - return poller.pollUntilDone(); - } - - /** - * Updates the JIT request. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param jitRequestName The name of the JIT request. - * @param parameters Parameters supplied to the update JIT request. - * @param options The options parameters. - */ - update( - resourceGroupName: string, - jitRequestName: string, - parameters: JitRequestPatchable, - options?: JitRequestsUpdateOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, jitRequestName, parameters, options }, - updateOperationSpec - ); - } - - /** - * Deletes the JIT request. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param jitRequestName The name of the JIT request. - * @param options The options parameters. - */ - delete( - resourceGroupName: string, - jitRequestName: string, - options?: JitRequestsDeleteOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, jitRequestName, options }, - deleteOperationSpec - ); - } - - /** - * Lists all JIT requests within the subscription. - * @param options The options parameters. - */ - listBySubscription( - options?: JitRequestsListBySubscriptionOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { options }, - listBySubscriptionOperationSpec - ); - } - - /** - * Lists all JIT requests within the resource group. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param options The options parameters. - */ - listByResourceGroup( - resourceGroupName: string, - options?: JitRequestsListByResourceGroupOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, options }, - listByResourceGroupOperationSpec - ); - } -} -// Operation Specifications -const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); - -const getOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Solutions/jitRequests/{jitRequestName}", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.JitRequestDefinition - }, - 404: {}, - default: { - bodyMapper: Mappers.ErrorResponse - } - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.jitRequestName - ], - headerParameters: [Parameters.accept], - serializer -}; -const createOrUpdateOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Solutions/jitRequests/{jitRequestName}", - httpMethod: "PUT", - responses: { - 200: { - bodyMapper: Mappers.JitRequestDefinition - }, - 201: { - bodyMapper: Mappers.JitRequestDefinition - }, - 202: { - bodyMapper: Mappers.JitRequestDefinition - }, - 204: { - bodyMapper: Mappers.JitRequestDefinition - }, - default: { - bodyMapper: Mappers.ErrorResponse - } - }, - requestBody: Parameters.parameters6, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.jitRequestName - ], - headerParameters: [Parameters.accept, Parameters.contentType], - mediaType: "json", - serializer -}; -const updateOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Solutions/jitRequests/{jitRequestName}", - httpMethod: "PATCH", - responses: { - 200: { - bodyMapper: Mappers.JitRequestDefinition - }, - default: { - bodyMapper: Mappers.ErrorResponse - } - }, - requestBody: Parameters.parameters7, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.jitRequestName - ], - headerParameters: [Parameters.accept, Parameters.contentType], - mediaType: "json", - serializer -}; -const deleteOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Solutions/jitRequests/{jitRequestName}", - httpMethod: "DELETE", - responses: { - 200: {}, - 204: {}, - default: { - bodyMapper: Mappers.ErrorResponse - } - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.jitRequestName - ], - headerParameters: [Parameters.accept], - serializer -}; -const listBySubscriptionOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/providers/Microsoft.Solutions/jitRequests", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.JitRequestDefinitionListResult - }, - default: { - bodyMapper: Mappers.ErrorResponse - } - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [Parameters.$host, Parameters.subscriptionId], - headerParameters: [Parameters.accept], - serializer -}; -const listByResourceGroupOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Solutions/jitRequests", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.JitRequestDefinitionListResult - }, - default: { - bodyMapper: Mappers.ErrorResponse - } - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName - ], - headerParameters: [Parameters.accept], - serializer -}; diff --git a/sdk/managedapplications/arm-managedapplications/src/operationsInterfaces/applicationDefinitions.ts b/sdk/managedapplications/arm-managedapplications/src/operationsInterfaces/applicationDefinitions.ts index f170bdb34088..c02623e9b660 100644 --- a/sdk/managedapplications/arm-managedapplications/src/operationsInterfaces/applicationDefinitions.ts +++ b/sdk/managedapplications/arm-managedapplications/src/operationsInterfaces/applicationDefinitions.ts @@ -7,25 +7,20 @@ */ import { PagedAsyncIterableIterator } from "@azure/core-paging"; +import { SimplePollerLike, OperationState } from "@azure/core-lro"; import { ApplicationDefinition, ApplicationDefinitionsListByResourceGroupOptionalParams, - ApplicationDefinitionsListBySubscriptionOptionalParams, ApplicationDefinitionsGetOptionalParams, ApplicationDefinitionsGetResponse, ApplicationDefinitionsDeleteOptionalParams, ApplicationDefinitionsCreateOrUpdateOptionalParams, ApplicationDefinitionsCreateOrUpdateResponse, - ApplicationDefinitionPatchable, - ApplicationDefinitionsUpdateOptionalParams, - ApplicationDefinitionsUpdateResponse, ApplicationDefinitionsGetByIdOptionalParams, ApplicationDefinitionsGetByIdResponse, ApplicationDefinitionsDeleteByIdOptionalParams, ApplicationDefinitionsCreateOrUpdateByIdOptionalParams, ApplicationDefinitionsCreateOrUpdateByIdResponse, - ApplicationDefinitionsUpdateByIdOptionalParams, - ApplicationDefinitionsUpdateByIdResponse } from "../models"; /// @@ -38,14 +33,7 @@ export interface ApplicationDefinitions { */ listByResourceGroup( resourceGroupName: string, - options?: ApplicationDefinitionsListByResourceGroupOptionalParams - ): PagedAsyncIterableIterator; - /** - * Lists all the application definitions within a subscription. - * @param options The options parameters. - */ - listBySubscription( - options?: ApplicationDefinitionsListBySubscriptionOptionalParams + options?: ApplicationDefinitionsListByResourceGroupOptionalParams, ): PagedAsyncIterableIterator; /** * Gets the managed application definition. @@ -56,45 +44,61 @@ export interface ApplicationDefinitions { get( resourceGroupName: string, applicationDefinitionName: string, - options?: ApplicationDefinitionsGetOptionalParams + options?: ApplicationDefinitionsGetOptionalParams, ): Promise; /** * Deletes the managed application definition. * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param applicationDefinitionName The name of the managed application definition. + * @param applicationDefinitionName The name of the managed application definition to delete. + * @param options The options parameters. + */ + beginDelete( + resourceGroupName: string, + applicationDefinitionName: string, + options?: ApplicationDefinitionsDeleteOptionalParams, + ): Promise, void>>; + /** + * Deletes the managed application definition. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param applicationDefinitionName The name of the managed application definition to delete. * @param options The options parameters. */ - delete( + beginDeleteAndWait( resourceGroupName: string, applicationDefinitionName: string, - options?: ApplicationDefinitionsDeleteOptionalParams + options?: ApplicationDefinitionsDeleteOptionalParams, ): Promise; /** - * Creates or updates a managed application definition. + * Creates a new managed application definition. * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param applicationDefinitionName The name of the managed application definition. * @param parameters Parameters supplied to the create or update an managed application definition. * @param options The options parameters. */ - createOrUpdate( + beginCreateOrUpdate( resourceGroupName: string, applicationDefinitionName: string, parameters: ApplicationDefinition, - options?: ApplicationDefinitionsCreateOrUpdateOptionalParams - ): Promise; + options?: ApplicationDefinitionsCreateOrUpdateOptionalParams, + ): Promise< + SimplePollerLike< + OperationState, + ApplicationDefinitionsCreateOrUpdateResponse + > + >; /** - * Updates the managed application definition. + * Creates a new managed application definition. * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param applicationDefinitionName The name of the managed application definition. - * @param parameters Parameters supplied to the update a managed application definition. + * @param parameters Parameters supplied to the create or update an managed application definition. * @param options The options parameters. */ - update( + beginCreateOrUpdateAndWait( resourceGroupName: string, applicationDefinitionName: string, - parameters: ApplicationDefinitionPatchable, - options?: ApplicationDefinitionsUpdateOptionalParams - ): Promise; + parameters: ApplicationDefinition, + options?: ApplicationDefinitionsCreateOrUpdateOptionalParams, + ): Promise; /** * Gets the managed application definition. * @param resourceGroupName The name of the resource group. The name is case insensitive. @@ -104,7 +108,7 @@ export interface ApplicationDefinitions { getById( resourceGroupName: string, applicationDefinitionName: string, - options?: ApplicationDefinitionsGetByIdOptionalParams + options?: ApplicationDefinitionsGetByIdOptionalParams, ): Promise; /** * Deletes the managed application definition. @@ -112,35 +116,51 @@ export interface ApplicationDefinitions { * @param applicationDefinitionName The name of the managed application definition. * @param options The options parameters. */ - deleteById( + beginDeleteById( + resourceGroupName: string, + applicationDefinitionName: string, + options?: ApplicationDefinitionsDeleteByIdOptionalParams, + ): Promise, void>>; + /** + * Deletes the managed application definition. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param applicationDefinitionName The name of the managed application definition. + * @param options The options parameters. + */ + beginDeleteByIdAndWait( resourceGroupName: string, applicationDefinitionName: string, - options?: ApplicationDefinitionsDeleteByIdOptionalParams + options?: ApplicationDefinitionsDeleteByIdOptionalParams, ): Promise; /** - * Creates or updates a managed application definition. + * Creates a new managed application definition. * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param applicationDefinitionName The name of the managed application definition. * @param parameters Parameters supplied to the create or update a managed application definition. * @param options The options parameters. */ - createOrUpdateById( + beginCreateOrUpdateById( resourceGroupName: string, applicationDefinitionName: string, parameters: ApplicationDefinition, - options?: ApplicationDefinitionsCreateOrUpdateByIdOptionalParams - ): Promise; + options?: ApplicationDefinitionsCreateOrUpdateByIdOptionalParams, + ): Promise< + SimplePollerLike< + OperationState, + ApplicationDefinitionsCreateOrUpdateByIdResponse + > + >; /** - * Updates the managed application definition. + * Creates a new managed application definition. * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param applicationDefinitionName The name of the managed application definition. - * @param parameters Parameters supplied to the update a managed application definition. + * @param parameters Parameters supplied to the create or update a managed application definition. * @param options The options parameters. */ - updateById( + beginCreateOrUpdateByIdAndWait( resourceGroupName: string, applicationDefinitionName: string, - parameters: ApplicationDefinitionPatchable, - options?: ApplicationDefinitionsUpdateByIdOptionalParams - ): Promise; + parameters: ApplicationDefinition, + options?: ApplicationDefinitionsCreateOrUpdateByIdOptionalParams, + ): Promise; } diff --git a/sdk/managedapplications/arm-managedapplications/src/operationsInterfaces/applications.ts b/sdk/managedapplications/arm-managedapplications/src/operationsInterfaces/applications.ts index 7a1527981881..1bb8d4321782 100644 --- a/sdk/managedapplications/arm-managedapplications/src/operationsInterfaces/applications.ts +++ b/sdk/managedapplications/arm-managedapplications/src/operationsInterfaces/applications.ts @@ -26,34 +26,26 @@ import { ApplicationsCreateOrUpdateByIdResponse, ApplicationsUpdateByIdOptionalParams, ApplicationsUpdateByIdResponse, - ApplicationsRefreshPermissionsOptionalParams, - ApplicationsListAllowedUpgradePlansOptionalParams, - ApplicationsListAllowedUpgradePlansResponse, - UpdateAccessDefinition, - ApplicationsUpdateAccessOptionalParams, - ListTokenRequest, - ApplicationsListTokensOptionalParams, - ApplicationsListTokensResponse } from "../models"; /// /** Interface representing a Applications. */ export interface Applications { /** - * Lists all the applications within a resource group. + * Gets all the applications within a resource group. * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param options The options parameters. */ listByResourceGroup( resourceGroupName: string, - options?: ApplicationsListByResourceGroupOptionalParams + options?: ApplicationsListByResourceGroupOptionalParams, ): PagedAsyncIterableIterator; /** - * Lists all the applications within a subscription. + * Gets all the applications within a subscription. * @param options The options parameters. */ listBySubscription( - options?: ApplicationsListBySubscriptionOptionalParams + options?: ApplicationsListBySubscriptionOptionalParams, ): PagedAsyncIterableIterator; /** * Gets the managed application. @@ -64,7 +56,7 @@ export interface Applications { get( resourceGroupName: string, applicationName: string, - options?: ApplicationsGetOptionalParams + options?: ApplicationsGetOptionalParams, ): Promise; /** * Deletes the managed application. @@ -75,7 +67,7 @@ export interface Applications { beginDelete( resourceGroupName: string, applicationName: string, - options?: ApplicationsDeleteOptionalParams + options?: ApplicationsDeleteOptionalParams, ): Promise, void>>; /** * Deletes the managed application. @@ -86,10 +78,10 @@ export interface Applications { beginDeleteAndWait( resourceGroupName: string, applicationName: string, - options?: ApplicationsDeleteOptionalParams + options?: ApplicationsDeleteOptionalParams, ): Promise; /** - * Creates or updates a managed application. + * Creates a new managed application. * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param applicationName The name of the managed application. * @param parameters Parameters supplied to the create or update a managed application. @@ -99,7 +91,7 @@ export interface Applications { resourceGroupName: string, applicationName: string, parameters: Application, - options?: ApplicationsCreateOrUpdateOptionalParams + options?: ApplicationsCreateOrUpdateOptionalParams, ): Promise< SimplePollerLike< OperationState, @@ -107,7 +99,7 @@ export interface Applications { > >; /** - * Creates or updates a managed application. + * Creates a new managed application. * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param applicationName The name of the managed application. * @param parameters Parameters supplied to the create or update a managed application. @@ -117,34 +109,19 @@ export interface Applications { resourceGroupName: string, applicationName: string, parameters: Application, - options?: ApplicationsCreateOrUpdateOptionalParams + options?: ApplicationsCreateOrUpdateOptionalParams, ): Promise; /** - * Updates an existing managed application. + * Updates an existing managed application. The only value that can be updated via PATCH currently is + * the tags. * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param applicationName The name of the managed application. * @param options The options parameters. */ - beginUpdate( + update( resourceGroupName: string, applicationName: string, - options?: ApplicationsUpdateOptionalParams - ): Promise< - SimplePollerLike< - OperationState, - ApplicationsUpdateResponse - > - >; - /** - * Updates an existing managed application. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param applicationName The name of the managed application. - * @param options The options parameters. - */ - beginUpdateAndWait( - resourceGroupName: string, - applicationName: string, - options?: ApplicationsUpdateOptionalParams + options?: ApplicationsUpdateOptionalParams, ): Promise; /** * Gets the managed application. @@ -155,7 +132,7 @@ export interface Applications { */ getById( applicationId: string, - options?: ApplicationsGetByIdOptionalParams + options?: ApplicationsGetByIdOptionalParams, ): Promise; /** * Deletes the managed application. @@ -166,7 +143,7 @@ export interface Applications { */ beginDeleteById( applicationId: string, - options?: ApplicationsDeleteByIdOptionalParams + options?: ApplicationsDeleteByIdOptionalParams, ): Promise, void>>; /** * Deletes the managed application. @@ -177,10 +154,10 @@ export interface Applications { */ beginDeleteByIdAndWait( applicationId: string, - options?: ApplicationsDeleteByIdOptionalParams + options?: ApplicationsDeleteByIdOptionalParams, ): Promise; /** - * Creates or updates a managed application. + * Creates a new managed application. * @param applicationId The fully qualified ID of the managed application, including the managed * application name and the managed application resource type. Use the format, * /subscriptions/{guid}/resourceGroups/{resource-group-name}/Microsoft.Solutions/applications/{application-name} @@ -190,7 +167,7 @@ export interface Applications { beginCreateOrUpdateById( applicationId: string, parameters: Application, - options?: ApplicationsCreateOrUpdateByIdOptionalParams + options?: ApplicationsCreateOrUpdateByIdOptionalParams, ): Promise< SimplePollerLike< OperationState, @@ -198,7 +175,7 @@ export interface Applications { > >; /** - * Creates or updates a managed application. + * Creates a new managed application. * @param applicationId The fully qualified ID of the managed application, including the managed * application name and the managed application resource type. Use the format, * /subscriptions/{guid}/resourceGroups/{resource-group-name}/Microsoft.Solutions/applications/{application-name} @@ -208,105 +185,18 @@ export interface Applications { beginCreateOrUpdateByIdAndWait( applicationId: string, parameters: Application, - options?: ApplicationsCreateOrUpdateByIdOptionalParams + options?: ApplicationsCreateOrUpdateByIdOptionalParams, ): Promise; /** - * Updates an existing managed application. - * @param applicationId The fully qualified ID of the managed application, including the managed - * application name and the managed application resource type. Use the format, - * /subscriptions/{guid}/resourceGroups/{resource-group-name}/Microsoft.Solutions/applications/{application-name} - * @param options The options parameters. - */ - beginUpdateById( - applicationId: string, - options?: ApplicationsUpdateByIdOptionalParams - ): Promise< - SimplePollerLike< - OperationState, - ApplicationsUpdateByIdResponse - > - >; - /** - * Updates an existing managed application. + * Updates an existing managed application. The only value that can be updated via PATCH currently is + * the tags. * @param applicationId The fully qualified ID of the managed application, including the managed * application name and the managed application resource type. Use the format, * /subscriptions/{guid}/resourceGroups/{resource-group-name}/Microsoft.Solutions/applications/{application-name} * @param options The options parameters. */ - beginUpdateByIdAndWait( + updateById( applicationId: string, - options?: ApplicationsUpdateByIdOptionalParams + options?: ApplicationsUpdateByIdOptionalParams, ): Promise; - /** - * Refresh Permissions for application. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param applicationName The name of the managed application. - * @param options The options parameters. - */ - beginRefreshPermissions( - resourceGroupName: string, - applicationName: string, - options?: ApplicationsRefreshPermissionsOptionalParams - ): Promise, void>>; - /** - * Refresh Permissions for application. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param applicationName The name of the managed application. - * @param options The options parameters. - */ - beginRefreshPermissionsAndWait( - resourceGroupName: string, - applicationName: string, - options?: ApplicationsRefreshPermissionsOptionalParams - ): Promise; - /** - * List allowed upgrade plans for application. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param applicationName The name of the managed application. - * @param options The options parameters. - */ - listAllowedUpgradePlans( - resourceGroupName: string, - applicationName: string, - options?: ApplicationsListAllowedUpgradePlansOptionalParams - ): Promise; - /** - * Update access for application. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param applicationName The name of the managed application. - * @param parameters Request body parameters to list tokens. - * @param options The options parameters. - */ - beginUpdateAccess( - resourceGroupName: string, - applicationName: string, - parameters: UpdateAccessDefinition, - options?: ApplicationsUpdateAccessOptionalParams - ): Promise, void>>; - /** - * Update access for application. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param applicationName The name of the managed application. - * @param parameters Request body parameters to list tokens. - * @param options The options parameters. - */ - beginUpdateAccessAndWait( - resourceGroupName: string, - applicationName: string, - parameters: UpdateAccessDefinition, - options?: ApplicationsUpdateAccessOptionalParams - ): Promise; - /** - * List tokens for application. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param applicationName The name of the managed application. - * @param parameters Request body parameters to list tokens. - * @param options The options parameters. - */ - listTokens( - resourceGroupName: string, - applicationName: string, - parameters: ListTokenRequest, - options?: ApplicationsListTokensOptionalParams - ): Promise; } diff --git a/sdk/managedapplications/arm-managedapplications/src/operationsInterfaces/index.ts b/sdk/managedapplications/arm-managedapplications/src/operationsInterfaces/index.ts index 63259e0e45c4..6ca98c210b1c 100644 --- a/sdk/managedapplications/arm-managedapplications/src/operationsInterfaces/index.ts +++ b/sdk/managedapplications/arm-managedapplications/src/operationsInterfaces/index.ts @@ -8,4 +8,3 @@ export * from "./applications"; export * from "./applicationDefinitions"; -export * from "./jitRequests"; diff --git a/sdk/managedapplications/arm-managedapplications/src/operationsInterfaces/jitRequests.ts b/sdk/managedapplications/arm-managedapplications/src/operationsInterfaces/jitRequests.ts deleted file mode 100644 index 980b0f074b76..000000000000 --- a/sdk/managedapplications/arm-managedapplications/src/operationsInterfaces/jitRequests.ts +++ /dev/null @@ -1,110 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -import { SimplePollerLike, OperationState } from "@azure/core-lro"; -import { - JitRequestsGetOptionalParams, - JitRequestsGetResponse, - JitRequestDefinition, - JitRequestsCreateOrUpdateOptionalParams, - JitRequestsCreateOrUpdateResponse, - JitRequestPatchable, - JitRequestsUpdateOptionalParams, - JitRequestsUpdateResponse, - JitRequestsDeleteOptionalParams, - JitRequestsListBySubscriptionOptionalParams, - JitRequestsListBySubscriptionResponse, - JitRequestsListByResourceGroupOptionalParams, - JitRequestsListByResourceGroupResponse -} from "../models"; - -/** Interface representing a JitRequests. */ -export interface JitRequests { - /** - * Gets the JIT request. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param jitRequestName The name of the JIT request. - * @param options The options parameters. - */ - get( - resourceGroupName: string, - jitRequestName: string, - options?: JitRequestsGetOptionalParams - ): Promise; - /** - * Creates or updates the JIT request. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param jitRequestName The name of the JIT request. - * @param parameters Parameters supplied to the update JIT request. - * @param options The options parameters. - */ - beginCreateOrUpdate( - resourceGroupName: string, - jitRequestName: string, - parameters: JitRequestDefinition, - options?: JitRequestsCreateOrUpdateOptionalParams - ): Promise< - SimplePollerLike< - OperationState, - JitRequestsCreateOrUpdateResponse - > - >; - /** - * Creates or updates the JIT request. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param jitRequestName The name of the JIT request. - * @param parameters Parameters supplied to the update JIT request. - * @param options The options parameters. - */ - beginCreateOrUpdateAndWait( - resourceGroupName: string, - jitRequestName: string, - parameters: JitRequestDefinition, - options?: JitRequestsCreateOrUpdateOptionalParams - ): Promise; - /** - * Updates the JIT request. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param jitRequestName The name of the JIT request. - * @param parameters Parameters supplied to the update JIT request. - * @param options The options parameters. - */ - update( - resourceGroupName: string, - jitRequestName: string, - parameters: JitRequestPatchable, - options?: JitRequestsUpdateOptionalParams - ): Promise; - /** - * Deletes the JIT request. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param jitRequestName The name of the JIT request. - * @param options The options parameters. - */ - delete( - resourceGroupName: string, - jitRequestName: string, - options?: JitRequestsDeleteOptionalParams - ): Promise; - /** - * Lists all JIT requests within the subscription. - * @param options The options parameters. - */ - listBySubscription( - options?: JitRequestsListBySubscriptionOptionalParams - ): Promise; - /** - * Lists all JIT requests within the resource group. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param options The options parameters. - */ - listByResourceGroup( - resourceGroupName: string, - options?: JitRequestsListByResourceGroupOptionalParams - ): Promise; -} diff --git a/sdk/managedapplications/arm-managedapplications/src/pagingHelper.ts b/sdk/managedapplications/arm-managedapplications/src/pagingHelper.ts index 269a2b9814b5..205cccc26592 100644 --- a/sdk/managedapplications/arm-managedapplications/src/pagingHelper.ts +++ b/sdk/managedapplications/arm-managedapplications/src/pagingHelper.ts @@ -28,7 +28,7 @@ export function getContinuationToken(page: unknown): string | undefined { export function setContinuationToken( page: unknown, - continuationToken: string | undefined + continuationToken: string | undefined, ): void { if (typeof page !== "object" || page === null || !continuationToken) { return; diff --git a/sdk/managedapplications/arm-managedapplications/test/sampleTest.ts b/sdk/managedapplications/arm-managedapplications/test/sampleTest.ts new file mode 100644 index 000000000000..d64be981b694 --- /dev/null +++ b/sdk/managedapplications/arm-managedapplications/test/sampleTest.ts @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +import { + Recorder, + RecorderStartOptions, + env, +} from "@azure-tools/test-recorder"; +import { assert } from "chai"; +import { Context } from "mocha"; + +const replaceableVariables: Record = { + AZURE_CLIENT_ID: "azure_client_id", + AZURE_CLIENT_SECRET: "azure_client_secret", + AZURE_TENANT_ID: "88888888-8888-8888-8888-888888888888", + SUBSCRIPTION_ID: "azure_subscription_id", +}; + +const recorderOptions: RecorderStartOptions = { + envSetupForPlayback: replaceableVariables, +}; + +describe("My test", () => { + let recorder: Recorder; + + beforeEach(async function (this: Context) { + recorder = new Recorder(this.currentTest); + await recorder.start(recorderOptions); + }); + + afterEach(async function () { + await recorder.stop(); + }); + + it("sample test", async function () { + console.log("Hi, I'm a test!"); + }); +}); diff --git a/sdk/managedapplications/arm-managedapplications/tsconfig.json b/sdk/managedapplications/arm-managedapplications/tsconfig.json index 8c28d0f9be7e..5e2d9266f916 100644 --- a/sdk/managedapplications/arm-managedapplications/tsconfig.json +++ b/sdk/managedapplications/arm-managedapplications/tsconfig.json @@ -15,17 +15,16 @@ ], "declaration": true, "outDir": "./dist-esm", - "importHelpers": true, - "paths": { - "@azure/arm-managedapplications": [ - "./src/index" - ] - } + "importHelpers": true }, "include": [ "./src/**/*.ts", "./test/**/*.ts", - "samples-dev/**/*.ts" + "./test/**/*.ts", + "./test/**/*.ts", + "./test/**/*.ts", + "./test/**/*.ts", + "./test/**/*.ts" ], "exclude": [ "node_modules" diff --git a/sdk/policy/arm-policy/CHANGELOG.md b/sdk/policy/arm-policy/CHANGELOG.md index 3a6f70113127..8feb86ce6f85 100644 --- a/sdk/policy/arm-policy/CHANGELOG.md +++ b/sdk/policy/arm-policy/CHANGELOG.md @@ -1,15 +1,109 @@ # Release History - -## 5.1.1 (Unreleased) - + +## 6.0.0 (2024-11-01) + ### Features Added -### Breaking Changes - -### Bugs Fixed + - Added operation group PolicyDefinitionVersions + - Added operation group PolicySetDefinitionVersions + - Added Interface Override + - Added Interface PolicyDefinitionVersion + - Added Interface PolicyDefinitionVersionListResult + - Added Interface PolicyDefinitionVersionsCreateOrUpdateAtManagementGroupOptionalParams + - Added Interface PolicyDefinitionVersionsCreateOrUpdateOptionalParams + - Added Interface PolicyDefinitionVersionsDeleteAtManagementGroupOptionalParams + - Added Interface PolicyDefinitionVersionsDeleteOptionalParams + - Added Interface PolicyDefinitionVersionsGetAtManagementGroupOptionalParams + - Added Interface PolicyDefinitionVersionsGetBuiltInOptionalParams + - Added Interface PolicyDefinitionVersionsGetOptionalParams + - Added Interface PolicyDefinitionVersionsListAllAtManagementGroupOptionalParams + - Added Interface PolicyDefinitionVersionsListAllBuiltinsOptionalParams + - Added Interface PolicyDefinitionVersionsListAllOptionalParams + - Added Interface PolicyDefinitionVersionsListBuiltInNextOptionalParams + - Added Interface PolicyDefinitionVersionsListBuiltInOptionalParams + - Added Interface PolicyDefinitionVersionsListByManagementGroupNextOptionalParams + - Added Interface PolicyDefinitionVersionsListByManagementGroupOptionalParams + - Added Interface PolicyDefinitionVersionsListNextOptionalParams + - Added Interface PolicyDefinitionVersionsListOptionalParams + - Added Interface PolicySetDefinitionVersion + - Added Interface PolicySetDefinitionVersionListResult + - Added Interface PolicySetDefinitionVersionsCreateOrUpdateAtManagementGroupOptionalParams + - Added Interface PolicySetDefinitionVersionsCreateOrUpdateOptionalParams + - Added Interface PolicySetDefinitionVersionsDeleteAtManagementGroupOptionalParams + - Added Interface PolicySetDefinitionVersionsDeleteOptionalParams + - Added Interface PolicySetDefinitionVersionsGetAtManagementGroupOptionalParams + - Added Interface PolicySetDefinitionVersionsGetBuiltInOptionalParams + - Added Interface PolicySetDefinitionVersionsGetOptionalParams + - Added Interface PolicySetDefinitionVersionsListAllAtManagementGroupOptionalParams + - Added Interface PolicySetDefinitionVersionsListAllBuiltinsOptionalParams + - Added Interface PolicySetDefinitionVersionsListAllOptionalParams + - Added Interface PolicySetDefinitionVersionsListBuiltInNextOptionalParams + - Added Interface PolicySetDefinitionVersionsListBuiltInOptionalParams + - Added Interface PolicySetDefinitionVersionsListByManagementGroupNextOptionalParams + - Added Interface PolicySetDefinitionVersionsListByManagementGroupOptionalParams + - Added Interface PolicySetDefinitionVersionsListNextOptionalParams + - Added Interface PolicySetDefinitionVersionsListOptionalParams + - Added Interface ResourceSelector + - Added Interface Selector + - Added Type Alias AssignmentType + - Added Type Alias OverrideKind + - Added Type Alias PolicyDefinitionVersionsCreateOrUpdateAtManagementGroupResponse + - Added Type Alias PolicyDefinitionVersionsCreateOrUpdateResponse + - Added Type Alias PolicyDefinitionVersionsGetAtManagementGroupResponse + - Added Type Alias PolicyDefinitionVersionsGetBuiltInResponse + - Added Type Alias PolicyDefinitionVersionsGetResponse + - Added Type Alias PolicyDefinitionVersionsListAllAtManagementGroupResponse + - Added Type Alias PolicyDefinitionVersionsListAllBuiltinsResponse + - Added Type Alias PolicyDefinitionVersionsListAllResponse + - Added Type Alias PolicyDefinitionVersionsListBuiltInNextResponse + - Added Type Alias PolicyDefinitionVersionsListBuiltInResponse + - Added Type Alias PolicyDefinitionVersionsListByManagementGroupNextResponse + - Added Type Alias PolicyDefinitionVersionsListByManagementGroupResponse + - Added Type Alias PolicyDefinitionVersionsListNextResponse + - Added Type Alias PolicyDefinitionVersionsListResponse + - Added Type Alias PolicySetDefinitionVersionsCreateOrUpdateAtManagementGroupResponse + - Added Type Alias PolicySetDefinitionVersionsCreateOrUpdateResponse + - Added Type Alias PolicySetDefinitionVersionsGetAtManagementGroupResponse + - Added Type Alias PolicySetDefinitionVersionsGetBuiltInResponse + - Added Type Alias PolicySetDefinitionVersionsGetResponse + - Added Type Alias PolicySetDefinitionVersionsListAllAtManagementGroupResponse + - Added Type Alias PolicySetDefinitionVersionsListAllBuiltinsResponse + - Added Type Alias PolicySetDefinitionVersionsListAllResponse + - Added Type Alias PolicySetDefinitionVersionsListBuiltInNextResponse + - Added Type Alias PolicySetDefinitionVersionsListBuiltInResponse + - Added Type Alias PolicySetDefinitionVersionsListByManagementGroupNextResponse + - Added Type Alias PolicySetDefinitionVersionsListByManagementGroupResponse + - Added Type Alias PolicySetDefinitionVersionsListNextResponse + - Added Type Alias PolicySetDefinitionVersionsListResponse + - Added Type Alias SelectorKind + - Interface ParameterDefinitionsValue has a new optional parameter schema + - Interface PolicyAssignment has a new optional parameter assignmentType + - Interface PolicyAssignment has a new optional parameter definitionVersion + - Interface PolicyAssignment has a new optional parameter overrides + - Interface PolicyAssignment has a new optional parameter resourceSelectors + - Interface PolicyAssignmentUpdate has a new optional parameter overrides + - Interface PolicyAssignmentUpdate has a new optional parameter resourceSelectors + - Interface PolicyClientOptionalParams has a new optional parameter apiVersion + - Interface PolicyDefinition has a new optional parameter version + - Interface PolicyDefinition has a new optional parameter versions + - Interface PolicyDefinitionReference has a new optional parameter definitionVersion + - Interface PolicySetDefinition has a new optional parameter version + - Interface PolicySetDefinition has a new optional parameter versions + - Added Enum KnownAssignmentType + - Added Enum KnownOverrideKind + - Added Enum KnownSelectorKind -### Other Changes +### Breaking Changes + - Removed operation group DataPolicyManifests + - Removed operation group PolicyExemptions + - Class PolicyClient no longer has parameter dataPolicyManifests + - Class PolicyClient no longer has parameter policyExemptions + - Removed Enum KnownAliasPathAttributes + - Removed Enum KnownAliasPathTokenType + - Removed Enum KnownExemptionCategory + + ## 5.1.0 (2023-05-18) ### Features Added @@ -52,13 +146,13 @@ ## 5.0.2 (2022-07-04) -### Features Added +**features** - Bug fix ## 5.0.1 (2022-04-18) -### Features Added +**features** - Bug fix @@ -70,4 +164,4 @@ To understand the detail of the change, please refer to [Changelog](https://aka. To migrate the existing applications to the latest version, please refer to [Migration Guide](https://aka.ms/js-track2-migration-guide). -To learn more, please refer to our documentation [Quick Start](https://aka.ms/azsdk/js/mgmt/quickstart ). +To learn more, please refer to our documentation [Quick Start](https://aka.ms/azsdk/js/mgmt/quickstart). diff --git a/sdk/policy/arm-policy/LICENSE b/sdk/policy/arm-policy/LICENSE index 3a1d9b6f24f7..7d5934740965 100644 --- a/sdk/policy/arm-policy/LICENSE +++ b/sdk/policy/arm-policy/LICENSE @@ -1,6 +1,6 @@ The MIT License (MIT) -Copyright (c) 2023 Microsoft +Copyright (c) 2024 Microsoft Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal diff --git a/sdk/policy/arm-policy/_meta.json b/sdk/policy/arm-policy/_meta.json index 6878746ca206..28591836c37e 100644 --- a/sdk/policy/arm-policy/_meta.json +++ b/sdk/policy/arm-policy/_meta.json @@ -1,8 +1,8 @@ { - "commit": "a42f1b58607091c4f255ead152a8ef323fa0b280", - "readme": "specification\\resources\\resource-manager\\readme.md", - "autorest_command": "autorest --version=3.9.3 --typescript --modelerfour.lenient-model-deduplication --azure-arm --head-as-boolean=true --license-header=MICROSOFT_MIT_NO_VERSION --generate-test --typescript-sdks-folder=D:\\Git\\azure-sdk-for-js ..\\azure-rest-api-specs\\specification\\resources\\resource-manager\\readme.md --use=@autorest/typescript@6.0.2 --generate-sample=true", + "commit": "5342edb61d78cec6e07b17a6cd8f7749c6697272", + "readme": "specification/resources/resource-manager/readme.md", + "autorest_command": "autorest --version=3.9.7 --typescript --modelerfour.lenient-model-deduplication --azure-arm --head-as-boolean=true --license-header=MICROSOFT_MIT_NO_VERSION --generate-test --typescript-sdks-folder=/mnt/vss/_work/1/s/azure-sdk-for-js ../azure-rest-api-specs/specification/resources/resource-manager/readme.md --use=@autorest/typescript@^6.0.12", "repository_url": "https://github.com/Azure/azure-rest-api-specs.git", - "release_tool": "@azure-tools/js-sdk-release-tools@2.6.2", - "use": "@autorest/typescript@6.0.2" + "release_tool": "@azure-tools/js-sdk-release-tools@2.7.14", + "use": "@autorest/typescript@^6.0.12" } \ No newline at end of file diff --git a/sdk/policy/arm-policy/package.json b/sdk/policy/arm-policy/package.json index cf454334ec63..13db87926cd8 100644 --- a/sdk/policy/arm-policy/package.json +++ b/sdk/policy/arm-policy/package.json @@ -3,15 +3,15 @@ "sdk-type": "mgmt", "author": "Microsoft Corporation", "description": "A generated SDK for PolicyClient.", - "version": "5.1.1", + "version": "6.0.0", "engines": { "node": ">=18.0.0" }, "dependencies": { - "@azure/core-auth": "^1.3.0", - "@azure/core-client": "^1.7.0", "@azure/core-paging": "^1.2.0", - "@azure/core-rest-pipeline": "^1.8.0", + "@azure/core-client": "^1.7.0", + "@azure/core-auth": "^1.6.0", + "@azure/core-rest-pipeline": "^1.14.0", "tslib": "^2.2.0" }, "keywords": [ @@ -26,20 +26,24 @@ "module": "./dist-esm/src/index.js", "types": "./types/arm-policy.d.ts", "devDependencies": { - "@azure-tools/test-credential": "^1.0.0", - "@azure-tools/test-recorder": "^3.0.0", - "@azure/arm-managementgroups": "^2.0.1", + "@microsoft/api-extractor": "^7.31.1", + "mkdirp": "^3.0.1", + "typescript": "~5.5.3", + "uglify-js": "^3.4.9", + "rimraf": "^5.0.0", + "dotenv": "^16.0.0", "@azure/dev-tool": "^1.0.0", - "@azure/identity": "^4.0.1", - "@types/chai": "^4.2.8", + "@azure/identity": "^4.2.1", + "@azure-tools/test-recorder": "^3.0.0", + "@azure-tools/test-credential": "^1.1.0", + "mocha": "^10.0.0", "@types/mocha": "^10.0.0", - "@types/node": "^18.0.0", + "tsx": "^4.7.1", + "@types/chai": "^4.2.8", "chai": "^4.2.0", "cross-env": "^7.0.2", - "dotenv": "^16.0.0", - "mocha": "^10.0.0", - "ts-node": "^10.0.0", - "typescript": "~5.6.2" + "@types/node": "^18.0.0", + "ts-node": "^10.0.0" }, "repository": { "type": "git", @@ -66,30 +70,29 @@ "types/*" ], "scripts": { - "build": "npm run clean && tsc && dev-tool run bundle && npm run minify && dev-tool run vendored mkdirp ./review && npm run extract-api", - "build:browser": "echo skipped", + "build": "npm run clean && tsc && dev-tool run bundle && npm run minify && mkdirp ./review && npm run extract-api", + "minify": "uglifyjs -c -m --comments --source-map \"content='./dist/index.js.map'\" -o ./dist/index.min.js ./dist/index.js", + "prepack": "npm run build", + "pack": "npm pack 2>&1", + "extract-api": "dev-tool run extract-api", + "lint": "echo skipped", + "clean": "rimraf --glob dist dist-browser dist-esm test-dist temp types *.tgz *.log", "build:node": "echo skipped", - "build:samples": "echo skipped.", + "build:browser": "echo skipped", "build:test": "echo skipped", + "build:samples": "echo skipped.", "check-format": "echo skipped", - "clean": "dev-tool run vendored rimraf --glob dist dist-browser dist-esm test-dist temp types *.tgz *.log", "execute:samples": "echo skipped", - "extract-api": "dev-tool run extract-api", "format": "echo skipped", - "integration-test": "npm run integration-test:node && npm run integration-test:browser", - "integration-test:browser": "echo skipped", - "integration-test:node": "dev-tool run test:node-ts-input -- --timeout 1200000 'test/*.ts'", - "lint": "echo skipped", - "minify": "dev-tool run vendored uglifyjs -c -m --comments --source-map \"content='./dist/index.js.map'\" -o ./dist/index.min.js ./dist/index.js", - "pack": "npm pack 2>&1", - "prepack": "npm run build", "test": "npm run integration-test", - "test:browser": "echo skipped", "test:node": "echo skipped", + "test:browser": "echo skipped", "unit-test": "npm run unit-test:node && npm run unit-test:browser", - "unit-test:browser": "echo skipped", "unit-test:node": "cross-env TEST_MODE=playback npm run integration-test:node", - "update-snippets": "echo skipped" + "unit-test:browser": "echo skipped", + "integration-test": "npm run integration-test:node && npm run integration-test:browser", + "integration-test:node": "dev-tool run test:node-ts-input -- --timeout 1200000 'test/*.ts'", + "integration-test:browser": "echo skipped" }, "sideEffects": false, "//metadata": { @@ -101,13 +104,5 @@ ] }, "autoPublish": true, - "homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/policy/arm-policy", - "//sampleConfiguration": { - "productName": "", - "productSlugs": [ - "azure" - ], - "disableDocsMs": true, - "apiRefLink": "https://docs.microsoft.com/javascript/api/@azure/arm-policy?view=azure-node-preview" - } -} + "homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/policy/arm-policy" +} \ No newline at end of file diff --git a/sdk/policy/arm-policy/review/arm-policy.api.md b/sdk/policy/arm-policy/review/arm-policy.api.md index 906abdb54c43..f5ed2ad54d5e 100644 --- a/sdk/policy/arm-policy/review/arm-policy.api.md +++ b/sdk/policy/arm-policy/review/arm-policy.api.md @@ -9,47 +9,7 @@ import * as coreClient from '@azure/core-client'; import { PagedAsyncIterableIterator } from '@azure/core-paging'; // @public -export interface Alias { - readonly defaultMetadata?: AliasPathMetadata; - defaultPath?: string; - defaultPattern?: AliasPattern; - name?: string; - paths?: AliasPath[]; - type?: AliasType; -} - -// @public -export interface AliasPath { - apiVersions?: string[]; - readonly metadata?: AliasPathMetadata; - path?: string; - pattern?: AliasPattern; -} - -// @public -export type AliasPathAttributes = string; - -// @public (undocumented) -export interface AliasPathMetadata { - readonly attributes?: AliasPathAttributes; - readonly type?: AliasPathTokenType; -} - -// @public -export type AliasPathTokenType = string; - -// @public -export interface AliasPattern { - phrase?: string; - type?: AliasPatternType; - variable?: string; -} - -// @public -export type AliasPatternType = "NotSpecified" | "Extract"; - -// @public -export type AliasType = "NotSpecified" | "PlainText" | "Mask"; +export type AssignmentType = string; // @public export interface CloudError { @@ -59,69 +19,6 @@ export interface CloudError { // @public export type CreatedByType = string; -// @public -export interface DataEffect { - detailsSchema?: any; - name?: string; -} - -// @public -export interface DataManifestCustomResourceFunctionDefinition { - allowCustomProperties?: boolean; - defaultProperties?: string[]; - fullyQualifiedResourceType?: string; - name?: string; -} - -// @public -export interface DataPolicyManifest { - custom?: DataManifestCustomResourceFunctionDefinition[]; - effects?: DataEffect[]; - fieldValues?: string[]; - readonly id?: string; - isBuiltInOnly?: boolean; - readonly name?: string; - namespaces?: string[]; - policyMode?: string; - resourceTypeAliases?: ResourceTypeAliases[]; - standard?: string[]; - readonly type?: string; -} - -// @public -export interface DataPolicyManifestListResult { - nextLink?: string; - value?: DataPolicyManifest[]; -} - -// @public -export interface DataPolicyManifests { - getByPolicyMode(policyMode: string, options?: DataPolicyManifestsGetByPolicyModeOptionalParams): Promise; - list(options?: DataPolicyManifestsListOptionalParams): PagedAsyncIterableIterator; -} - -// @public -export interface DataPolicyManifestsGetByPolicyModeOptionalParams extends coreClient.OperationOptions { -} - -// @public -export type DataPolicyManifestsGetByPolicyModeResponse = DataPolicyManifest; - -// @public -export interface DataPolicyManifestsListNextOptionalParams extends coreClient.OperationOptions { -} - -// @public -export type DataPolicyManifestsListNextResponse = DataPolicyManifestListResult; - -// @public -export interface DataPolicyManifestsListOptionalParams extends coreClient.OperationOptions { - filter?: string; -} - -// @public -export type DataPolicyManifestsListResponse = DataPolicyManifestListResult; - // @public export type EnforcementMode = string; @@ -140,9 +37,6 @@ export interface ErrorResponse { readonly target?: string; } -// @public -export type ExemptionCategory = string; - // @public export function getContinuationToken(page: unknown): string | undefined; @@ -157,21 +51,11 @@ export interface Identity { } // @public -export enum KnownAliasPathAttributes { - Modifiable = "Modifiable", - None = "None" -} - -// @public -export enum KnownAliasPathTokenType { - Any = "Any", - Array = "Array", - Boolean = "Boolean", - Integer = "Integer", +export enum KnownAssignmentType { + Custom = "Custom", NotSpecified = "NotSpecified", - Number = "Number", - Object = "Object", - String = "String" + System = "System", + SystemHidden = "SystemHidden" } // @public @@ -189,9 +73,9 @@ export enum KnownEnforcementMode { } // @public -export enum KnownExemptionCategory { - Mitigated = "Mitigated", - Waiver = "Waiver" +export enum KnownOverrideKind { + DefinitionVersion = "definitionVersion", + PolicyEffect = "policyEffect" } // @public @@ -213,17 +97,36 @@ export enum KnownPolicyType { Static = "Static" } +// @public +export enum KnownSelectorKind { + PolicyDefinitionReferenceId = "policyDefinitionReferenceId", + ResourceLocation = "resourceLocation", + ResourceType = "resourceType", + ResourceWithoutLocation = "resourceWithoutLocation" +} + // @public export interface NonComplianceMessage { message: string; policyDefinitionReferenceId?: string; } +// @public +export interface Override { + kind?: OverrideKind; + selectors?: Selector[]; + value?: string; +} + +// @public +export type OverrideKind = string; + // @public export interface ParameterDefinitionsValue { allowedValues?: any[]; defaultValue?: any; metadata?: ParameterDefinitionsValueMetadata; + schema?: any; type?: ParameterType; } @@ -246,6 +149,8 @@ export interface ParameterValuesValue { // @public export interface PolicyAssignment { + assignmentType?: AssignmentType; + definitionVersion?: string; description?: string; displayName?: string; enforcementMode?: EnforcementMode; @@ -256,10 +161,12 @@ export interface PolicyAssignment { readonly name?: string; nonComplianceMessages?: NonComplianceMessage[]; notScopes?: string[]; + overrides?: Override[]; parameters?: { [propertyName: string]: ParameterValuesValue; }; policyDefinitionId?: string; + resourceSelectors?: ResourceSelector[]; readonly scope?: string; readonly systemData?: SystemData; readonly type?: string; @@ -407,10 +314,12 @@ export interface PolicyAssignmentsUpdateOptionalParams extends coreClient.Operat // @public export type PolicyAssignmentsUpdateResponse = PolicyAssignment; -// @public (undocumented) +// @public export interface PolicyAssignmentUpdate { identity?: Identity; location?: string; + overrides?: Override[]; + resourceSelectors?: ResourceSelector[]; } // @public (undocumented) @@ -420,22 +329,25 @@ export class PolicyClient extends coreClient.ServiceClient { constructor(credentials: coreAuth.TokenCredential, subscriptionId: string, options?: PolicyClientOptionalParams); constructor(credentials: coreAuth.TokenCredential, options?: PolicyClientOptionalParams); // (undocumented) - dataPolicyManifests: DataPolicyManifests; + apiVersion: string; // (undocumented) policyAssignments: PolicyAssignments; // (undocumented) policyDefinitions: PolicyDefinitions; // (undocumented) - policyExemptions: PolicyExemptions; + policyDefinitionVersions: PolicyDefinitionVersions; // (undocumented) policySetDefinitions: PolicySetDefinitions; // (undocumented) + policySetDefinitionVersions: PolicySetDefinitionVersions; + // (undocumented) subscriptionId?: string; } // @public export interface PolicyClientOptionalParams extends coreClient.ServiceClientOptions { $host?: string; + apiVersion?: string; endpoint?: string; } @@ -454,6 +366,8 @@ export interface PolicyDefinition { policyType?: PolicyType; readonly systemData?: SystemData; readonly type?: string; + version?: string; + versions?: string[]; } // @public @@ -473,6 +387,7 @@ export interface PolicyDefinitionListResult { // @public export interface PolicyDefinitionReference { + definitionVersion?: string; groupNames?: string[]; parameters?: { [propertyName: string]: ParameterValuesValue; @@ -484,11 +399,11 @@ export interface PolicyDefinitionReference { // @public export interface PolicyDefinitions { createOrUpdate(policyDefinitionName: string, parameters: PolicyDefinition, options?: PolicyDefinitionsCreateOrUpdateOptionalParams): Promise; - createOrUpdateAtManagementGroup(policyDefinitionName: string, managementGroupId: string, parameters: PolicyDefinition, options?: PolicyDefinitionsCreateOrUpdateAtManagementGroupOptionalParams): Promise; + createOrUpdateAtManagementGroup(managementGroupId: string, policyDefinitionName: string, parameters: PolicyDefinition, options?: PolicyDefinitionsCreateOrUpdateAtManagementGroupOptionalParams): Promise; delete(policyDefinitionName: string, options?: PolicyDefinitionsDeleteOptionalParams): Promise; - deleteAtManagementGroup(policyDefinitionName: string, managementGroupId: string, options?: PolicyDefinitionsDeleteAtManagementGroupOptionalParams): Promise; + deleteAtManagementGroup(managementGroupId: string, policyDefinitionName: string, options?: PolicyDefinitionsDeleteAtManagementGroupOptionalParams): Promise; get(policyDefinitionName: string, options?: PolicyDefinitionsGetOptionalParams): Promise; - getAtManagementGroup(policyDefinitionName: string, managementGroupId: string, options?: PolicyDefinitionsGetAtManagementGroupOptionalParams): Promise; + getAtManagementGroup(managementGroupId: string, policyDefinitionName: string, options?: PolicyDefinitionsGetAtManagementGroupOptionalParams): Promise; getBuiltIn(policyDefinitionName: string, options?: PolicyDefinitionsGetBuiltInOptionalParams): Promise; list(options?: PolicyDefinitionsListOptionalParams): PagedAsyncIterableIterator; listBuiltIn(options?: PolicyDefinitionsListBuiltInOptionalParams): PagedAsyncIterableIterator; @@ -587,114 +502,154 @@ export interface PolicyDefinitionsListOptionalParams extends coreClient.Operatio export type PolicyDefinitionsListResponse = PolicyDefinitionListResult; // @public -export interface PolicyExemption { +export interface PolicyDefinitionVersion { description?: string; displayName?: string; - exemptionCategory: ExemptionCategory; - expiresOn?: Date; readonly id?: string; metadata?: any; + mode?: string; readonly name?: string; - policyAssignmentId: string; - policyDefinitionReferenceIds?: string[]; + parameters?: { + [propertyName: string]: ParameterDefinitionsValue; + }; + policyRule?: any; + policyType?: PolicyType; readonly systemData?: SystemData; readonly type?: string; + version?: string; } // @public -export interface PolicyExemptionListResult { - readonly nextLink?: string; - value?: PolicyExemption[]; +export interface PolicyDefinitionVersionListResult { + nextLink?: string; + value?: PolicyDefinitionVersion[]; } // @public -export interface PolicyExemptions { - createOrUpdate(scope: string, policyExemptionName: string, parameters: PolicyExemption, options?: PolicyExemptionsCreateOrUpdateOptionalParams): Promise; - delete(scope: string, policyExemptionName: string, options?: PolicyExemptionsDeleteOptionalParams): Promise; - get(scope: string, policyExemptionName: string, options?: PolicyExemptionsGetOptionalParams): Promise; - list(options?: PolicyExemptionsListOptionalParams): PagedAsyncIterableIterator; - listForManagementGroup(managementGroupId: string, options?: PolicyExemptionsListForManagementGroupOptionalParams): PagedAsyncIterableIterator; - listForResource(resourceGroupName: string, resourceProviderNamespace: string, parentResourcePath: string, resourceType: string, resourceName: string, options?: PolicyExemptionsListForResourceOptionalParams): PagedAsyncIterableIterator; - listForResourceGroup(resourceGroupName: string, options?: PolicyExemptionsListForResourceGroupOptionalParams): PagedAsyncIterableIterator; +export interface PolicyDefinitionVersions { + createOrUpdate(policyDefinitionName: string, policyDefinitionVersion: string, parameters: PolicyDefinitionVersion, options?: PolicyDefinitionVersionsCreateOrUpdateOptionalParams): Promise; + createOrUpdateAtManagementGroup(managementGroupName: string, policyDefinitionName: string, policyDefinitionVersion: string, parameters: PolicyDefinitionVersion, options?: PolicyDefinitionVersionsCreateOrUpdateAtManagementGroupOptionalParams): Promise; + delete(policyDefinitionName: string, policyDefinitionVersion: string, options?: PolicyDefinitionVersionsDeleteOptionalParams): Promise; + deleteAtManagementGroup(managementGroupName: string, policyDefinitionName: string, policyDefinitionVersion: string, options?: PolicyDefinitionVersionsDeleteAtManagementGroupOptionalParams): Promise; + get(policyDefinitionName: string, policyDefinitionVersion: string, options?: PolicyDefinitionVersionsGetOptionalParams): Promise; + getAtManagementGroup(managementGroupName: string, policyDefinitionName: string, policyDefinitionVersion: string, options?: PolicyDefinitionVersionsGetAtManagementGroupOptionalParams): Promise; + getBuiltIn(policyDefinitionName: string, policyDefinitionVersion: string, options?: PolicyDefinitionVersionsGetBuiltInOptionalParams): Promise; + list(policyDefinitionName: string, options?: PolicyDefinitionVersionsListOptionalParams): PagedAsyncIterableIterator; + listAll(options?: PolicyDefinitionVersionsListAllOptionalParams): Promise; + listAllAtManagementGroup(managementGroupName: string, options?: PolicyDefinitionVersionsListAllAtManagementGroupOptionalParams): Promise; + listAllBuiltins(options?: PolicyDefinitionVersionsListAllBuiltinsOptionalParams): Promise; + listBuiltIn(policyDefinitionName: string, options?: PolicyDefinitionVersionsListBuiltInOptionalParams): PagedAsyncIterableIterator; + listByManagementGroup(managementGroupName: string, policyDefinitionName: string, options?: PolicyDefinitionVersionsListByManagementGroupOptionalParams): PagedAsyncIterableIterator; } // @public -export interface PolicyExemptionsCreateOrUpdateOptionalParams extends coreClient.OperationOptions { +export interface PolicyDefinitionVersionsCreateOrUpdateAtManagementGroupOptionalParams extends coreClient.OperationOptions { } // @public -export type PolicyExemptionsCreateOrUpdateResponse = PolicyExemption; +export type PolicyDefinitionVersionsCreateOrUpdateAtManagementGroupResponse = PolicyDefinitionVersion; // @public -export interface PolicyExemptionsDeleteOptionalParams extends coreClient.OperationOptions { +export interface PolicyDefinitionVersionsCreateOrUpdateOptionalParams extends coreClient.OperationOptions { } // @public -export interface PolicyExemptionsGetOptionalParams extends coreClient.OperationOptions { +export type PolicyDefinitionVersionsCreateOrUpdateResponse = PolicyDefinitionVersion; + +// @public +export interface PolicyDefinitionVersionsDeleteAtManagementGroupOptionalParams extends coreClient.OperationOptions { } // @public -export type PolicyExemptionsGetResponse = PolicyExemption; +export interface PolicyDefinitionVersionsDeleteOptionalParams extends coreClient.OperationOptions { +} // @public -export interface PolicyExemptionsListForManagementGroupNextOptionalParams extends coreClient.OperationOptions { +export interface PolicyDefinitionVersionsGetAtManagementGroupOptionalParams extends coreClient.OperationOptions { } // @public -export type PolicyExemptionsListForManagementGroupNextResponse = PolicyExemptionListResult; +export type PolicyDefinitionVersionsGetAtManagementGroupResponse = PolicyDefinitionVersion; // @public -export interface PolicyExemptionsListForManagementGroupOptionalParams extends coreClient.OperationOptions { - filter?: string; +export interface PolicyDefinitionVersionsGetBuiltInOptionalParams extends coreClient.OperationOptions { } // @public -export type PolicyExemptionsListForManagementGroupResponse = PolicyExemptionListResult; +export type PolicyDefinitionVersionsGetBuiltInResponse = PolicyDefinitionVersion; // @public -export interface PolicyExemptionsListForResourceGroupNextOptionalParams extends coreClient.OperationOptions { +export interface PolicyDefinitionVersionsGetOptionalParams extends coreClient.OperationOptions { } // @public -export type PolicyExemptionsListForResourceGroupNextResponse = PolicyExemptionListResult; +export type PolicyDefinitionVersionsGetResponse = PolicyDefinitionVersion; // @public -export interface PolicyExemptionsListForResourceGroupOptionalParams extends coreClient.OperationOptions { - filter?: string; +export interface PolicyDefinitionVersionsListAllAtManagementGroupOptionalParams extends coreClient.OperationOptions { } // @public -export type PolicyExemptionsListForResourceGroupResponse = PolicyExemptionListResult; +export type PolicyDefinitionVersionsListAllAtManagementGroupResponse = PolicyDefinitionVersionListResult; // @public -export interface PolicyExemptionsListForResourceNextOptionalParams extends coreClient.OperationOptions { +export interface PolicyDefinitionVersionsListAllBuiltinsOptionalParams extends coreClient.OperationOptions { } // @public -export type PolicyExemptionsListForResourceNextResponse = PolicyExemptionListResult; +export type PolicyDefinitionVersionsListAllBuiltinsResponse = PolicyDefinitionVersionListResult; // @public -export interface PolicyExemptionsListForResourceOptionalParams extends coreClient.OperationOptions { - filter?: string; +export interface PolicyDefinitionVersionsListAllOptionalParams extends coreClient.OperationOptions { } // @public -export type PolicyExemptionsListForResourceResponse = PolicyExemptionListResult; +export type PolicyDefinitionVersionsListAllResponse = PolicyDefinitionVersionListResult; // @public -export interface PolicyExemptionsListNextOptionalParams extends coreClient.OperationOptions { +export interface PolicyDefinitionVersionsListBuiltInNextOptionalParams extends coreClient.OperationOptions { } // @public -export type PolicyExemptionsListNextResponse = PolicyExemptionListResult; +export type PolicyDefinitionVersionsListBuiltInNextResponse = PolicyDefinitionVersionListResult; // @public -export interface PolicyExemptionsListOptionalParams extends coreClient.OperationOptions { - filter?: string; +export interface PolicyDefinitionVersionsListBuiltInOptionalParams extends coreClient.OperationOptions { + top?: number; +} + +// @public +export type PolicyDefinitionVersionsListBuiltInResponse = PolicyDefinitionVersionListResult; + +// @public +export interface PolicyDefinitionVersionsListByManagementGroupNextOptionalParams extends coreClient.OperationOptions { } // @public -export type PolicyExemptionsListResponse = PolicyExemptionListResult; +export type PolicyDefinitionVersionsListByManagementGroupNextResponse = PolicyDefinitionVersionListResult; + +// @public +export interface PolicyDefinitionVersionsListByManagementGroupOptionalParams extends coreClient.OperationOptions { + top?: number; +} + +// @public +export type PolicyDefinitionVersionsListByManagementGroupResponse = PolicyDefinitionVersionListResult; + +// @public +export interface PolicyDefinitionVersionsListNextOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type PolicyDefinitionVersionsListNextResponse = PolicyDefinitionVersionListResult; + +// @public +export interface PolicyDefinitionVersionsListOptionalParams extends coreClient.OperationOptions { + top?: number; +} + +// @public +export type PolicyDefinitionVersionsListResponse = PolicyDefinitionVersionListResult; // @public export interface PolicySetDefinition { @@ -711,6 +666,8 @@ export interface PolicySetDefinition { policyType?: PolicyType; readonly systemData?: SystemData; readonly type?: string; + version?: string; + versions?: string[]; } // @public @@ -722,11 +679,11 @@ export interface PolicySetDefinitionListResult { // @public export interface PolicySetDefinitions { createOrUpdate(policySetDefinitionName: string, parameters: PolicySetDefinition, options?: PolicySetDefinitionsCreateOrUpdateOptionalParams): Promise; - createOrUpdateAtManagementGroup(policySetDefinitionName: string, managementGroupId: string, parameters: PolicySetDefinition, options?: PolicySetDefinitionsCreateOrUpdateAtManagementGroupOptionalParams): Promise; + createOrUpdateAtManagementGroup(managementGroupId: string, policySetDefinitionName: string, parameters: PolicySetDefinition, options?: PolicySetDefinitionsCreateOrUpdateAtManagementGroupOptionalParams): Promise; delete(policySetDefinitionName: string, options?: PolicySetDefinitionsDeleteOptionalParams): Promise; - deleteAtManagementGroup(policySetDefinitionName: string, managementGroupId: string, options?: PolicySetDefinitionsDeleteAtManagementGroupOptionalParams): Promise; + deleteAtManagementGroup(managementGroupId: string, policySetDefinitionName: string, options?: PolicySetDefinitionsDeleteAtManagementGroupOptionalParams): Promise; get(policySetDefinitionName: string, options?: PolicySetDefinitionsGetOptionalParams): Promise; - getAtManagementGroup(policySetDefinitionName: string, managementGroupId: string, options?: PolicySetDefinitionsGetAtManagementGroupOptionalParams): Promise; + getAtManagementGroup(managementGroupId: string, policySetDefinitionName: string, options?: PolicySetDefinitionsGetAtManagementGroupOptionalParams): Promise; getBuiltIn(policySetDefinitionName: string, options?: PolicySetDefinitionsGetBuiltInOptionalParams): Promise; list(options?: PolicySetDefinitionsListOptionalParams): PagedAsyncIterableIterator; listBuiltIn(options?: PolicySetDefinitionsListBuiltInOptionalParams): PagedAsyncIterableIterator; @@ -824,6 +781,156 @@ export interface PolicySetDefinitionsListOptionalParams extends coreClient.Opera // @public export type PolicySetDefinitionsListResponse = PolicySetDefinitionListResult; +// @public +export interface PolicySetDefinitionVersion { + description?: string; + displayName?: string; + readonly id?: string; + metadata?: any; + readonly name?: string; + parameters?: { + [propertyName: string]: ParameterDefinitionsValue; + }; + policyDefinitionGroups?: PolicyDefinitionGroup[]; + policyDefinitions?: PolicyDefinitionReference[]; + policyType?: PolicyType; + readonly systemData?: SystemData; + readonly type?: string; + version?: string; +} + +// @public +export interface PolicySetDefinitionVersionListResult { + nextLink?: string; + value?: PolicySetDefinitionVersion[]; +} + +// @public +export interface PolicySetDefinitionVersions { + createOrUpdate(policySetDefinitionName: string, policyDefinitionVersion: string, parameters: PolicySetDefinitionVersion, options?: PolicySetDefinitionVersionsCreateOrUpdateOptionalParams): Promise; + createOrUpdateAtManagementGroup(managementGroupName: string, policySetDefinitionName: string, policyDefinitionVersion: string, parameters: PolicySetDefinitionVersion, options?: PolicySetDefinitionVersionsCreateOrUpdateAtManagementGroupOptionalParams): Promise; + delete(policySetDefinitionName: string, policyDefinitionVersion: string, options?: PolicySetDefinitionVersionsDeleteOptionalParams): Promise; + deleteAtManagementGroup(managementGroupName: string, policySetDefinitionName: string, policyDefinitionVersion: string, options?: PolicySetDefinitionVersionsDeleteAtManagementGroupOptionalParams): Promise; + get(policySetDefinitionName: string, policyDefinitionVersion: string, options?: PolicySetDefinitionVersionsGetOptionalParams): Promise; + getAtManagementGroup(managementGroupName: string, policySetDefinitionName: string, policyDefinitionVersion: string, options?: PolicySetDefinitionVersionsGetAtManagementGroupOptionalParams): Promise; + getBuiltIn(policySetDefinitionName: string, policyDefinitionVersion: string, options?: PolicySetDefinitionVersionsGetBuiltInOptionalParams): Promise; + list(policySetDefinitionName: string, options?: PolicySetDefinitionVersionsListOptionalParams): PagedAsyncIterableIterator; + listAll(options?: PolicySetDefinitionVersionsListAllOptionalParams): Promise; + listAllAtManagementGroup(managementGroupName: string, options?: PolicySetDefinitionVersionsListAllAtManagementGroupOptionalParams): Promise; + listAllBuiltins(options?: PolicySetDefinitionVersionsListAllBuiltinsOptionalParams): Promise; + listBuiltIn(policySetDefinitionName: string, options?: PolicySetDefinitionVersionsListBuiltInOptionalParams): PagedAsyncIterableIterator; + listByManagementGroup(managementGroupName: string, policySetDefinitionName: string, options?: PolicySetDefinitionVersionsListByManagementGroupOptionalParams): PagedAsyncIterableIterator; +} + +// @public +export interface PolicySetDefinitionVersionsCreateOrUpdateAtManagementGroupOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type PolicySetDefinitionVersionsCreateOrUpdateAtManagementGroupResponse = PolicySetDefinitionVersion; + +// @public +export interface PolicySetDefinitionVersionsCreateOrUpdateOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type PolicySetDefinitionVersionsCreateOrUpdateResponse = PolicySetDefinitionVersion; + +// @public +export interface PolicySetDefinitionVersionsDeleteAtManagementGroupOptionalParams extends coreClient.OperationOptions { +} + +// @public +export interface PolicySetDefinitionVersionsDeleteOptionalParams extends coreClient.OperationOptions { +} + +// @public +export interface PolicySetDefinitionVersionsGetAtManagementGroupOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type PolicySetDefinitionVersionsGetAtManagementGroupResponse = PolicySetDefinitionVersion; + +// @public +export interface PolicySetDefinitionVersionsGetBuiltInOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type PolicySetDefinitionVersionsGetBuiltInResponse = PolicySetDefinitionVersion; + +// @public +export interface PolicySetDefinitionVersionsGetOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type PolicySetDefinitionVersionsGetResponse = PolicySetDefinitionVersion; + +// @public +export interface PolicySetDefinitionVersionsListAllAtManagementGroupOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type PolicySetDefinitionVersionsListAllAtManagementGroupResponse = PolicySetDefinitionVersionListResult; + +// @public +export interface PolicySetDefinitionVersionsListAllBuiltinsOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type PolicySetDefinitionVersionsListAllBuiltinsResponse = PolicySetDefinitionVersionListResult; + +// @public +export interface PolicySetDefinitionVersionsListAllOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type PolicySetDefinitionVersionsListAllResponse = PolicySetDefinitionVersionListResult; + +// @public +export interface PolicySetDefinitionVersionsListBuiltInNextOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type PolicySetDefinitionVersionsListBuiltInNextResponse = PolicySetDefinitionVersionListResult; + +// @public +export interface PolicySetDefinitionVersionsListBuiltInOptionalParams extends coreClient.OperationOptions { + top?: number; +} + +// @public +export type PolicySetDefinitionVersionsListBuiltInResponse = PolicySetDefinitionVersionListResult; + +// @public +export interface PolicySetDefinitionVersionsListByManagementGroupNextOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type PolicySetDefinitionVersionsListByManagementGroupNextResponse = PolicySetDefinitionVersionListResult; + +// @public +export interface PolicySetDefinitionVersionsListByManagementGroupOptionalParams extends coreClient.OperationOptions { + top?: number; +} + +// @public +export type PolicySetDefinitionVersionsListByManagementGroupResponse = PolicySetDefinitionVersionListResult; + +// @public +export interface PolicySetDefinitionVersionsListNextOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type PolicySetDefinitionVersionsListNextResponse = PolicySetDefinitionVersionListResult; + +// @public +export interface PolicySetDefinitionVersionsListOptionalParams extends coreClient.OperationOptions { + top?: number; +} + +// @public +export type PolicySetDefinitionVersionsListResponse = PolicySetDefinitionVersionListResult; + // @public export type PolicyType = string; @@ -831,11 +938,21 @@ export type PolicyType = string; export type ResourceIdentityType = "SystemAssigned" | "UserAssigned" | "None"; // @public -export interface ResourceTypeAliases { - aliases?: Alias[]; - resourceType?: string; +export interface ResourceSelector { + name?: string; + selectors?: Selector[]; +} + +// @public +export interface Selector { + in?: string[]; + kind?: SelectorKind; + notIn?: string[]; } +// @public +export type SelectorKind = string; + // @public export interface SystemData { createdAt?: Date; diff --git a/sdk/policy/arm-policy/src/models/index.ts b/sdk/policy/arm-policy/src/models/index.ts index 43f12f588453..45dec0bb10ae 100644 --- a/sdk/policy/arm-policy/src/models/index.ts +++ b/sdk/policy/arm-policy/src/models/index.ts @@ -8,124 +8,90 @@ import * as coreClient from "@azure/core-client"; -/** The data policy manifest. */ -export interface DataPolicyManifest { +/** The policy definition. */ +export interface PolicyDefinition { /** - * The ID of the data policy manifest. + * The ID of the policy definition. * NOTE: This property will not be serialized. It can only be populated by the server. */ readonly id?: string; /** - * The name of the data policy manifest (it's the same as the Policy Mode). + * The name of the policy definition. * NOTE: This property will not be serialized. It can only be populated by the server. */ readonly name?: string; /** - * The type of the resource (Microsoft.Authorization/dataPolicyManifests). + * The type of the resource (Microsoft.Authorization/policyDefinitions). * NOTE: This property will not be serialized. It can only be populated by the server. */ readonly type?: string; - /** The list of namespaces for the data policy manifest. */ - namespaces?: string[]; - /** The policy mode of the data policy manifest. */ - policyMode?: string; - /** A value indicating whether policy mode is allowed only in built-in definitions. */ - isBuiltInOnly?: boolean; - /** An array of resource type aliases. */ - resourceTypeAliases?: ResourceTypeAliases[]; - /** The effect definition. */ - effects?: DataEffect[]; - /** The non-alias field accessor values that can be used in the policy rule. */ - fieldValues?: string[]; - /** The standard resource functions (subscription and/or resourceGroup). */ - standard?: string[]; - /** An array of data manifest custom resource definition. */ - custom?: DataManifestCustomResourceFunctionDefinition[]; -} - -/** The resource type aliases definition. */ -export interface ResourceTypeAliases { - /** The resource type name. */ - resourceType?: string; - /** The aliases for property names. */ - aliases?: Alias[]; -} - -/** The alias type. */ -export interface Alias { - /** The alias name. */ - name?: string; - /** The paths for an alias. */ - paths?: AliasPath[]; - /** The type of the alias. */ - type?: AliasType; - /** The default path for an alias. */ - defaultPath?: string; - /** The default pattern for an alias. */ - defaultPattern?: AliasPattern; - /** - * The default alias path metadata. Applies to the default path and to any alias path that doesn't have metadata - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly defaultMetadata?: AliasPathMetadata; -} - -/** The type of the paths for alias. */ -export interface AliasPath { - /** The path of an alias. */ - path?: string; - /** The API versions. */ - apiVersions?: string[]; - /** The pattern for an alias path. */ - pattern?: AliasPattern; /** - * The metadata of the alias path. If missing, fall back to the default metadata of the alias. + * The system metadata relating to this resource. * NOTE: This property will not be serialized. It can only be populated by the server. */ - readonly metadata?: AliasPathMetadata; -} - -/** The type of the pattern for an alias path. */ -export interface AliasPattern { - /** The alias pattern phrase. */ - phrase?: string; - /** The alias pattern variable. */ - variable?: string; - /** The type of alias pattern */ - type?: AliasPatternType; + readonly systemData?: SystemData; + /** The type of policy definition. Possible values are NotSpecified, BuiltIn, Custom, and Static. */ + policyType?: PolicyType; + /** The policy definition mode. Some examples are All, Indexed, Microsoft.KeyVault.Data. */ + mode?: string; + /** The display name of the policy definition. */ + displayName?: string; + /** The policy definition description. */ + description?: string; + /** The policy rule. */ + policyRule?: any; + /** The policy definition metadata. Metadata is an open ended object and is typically a collection of key value pairs. */ + metadata?: any; + /** The parameter definitions for parameters used in the policy rule. The keys are the parameter names. */ + parameters?: { [propertyName: string]: ParameterDefinitionsValue }; + /** The policy definition version in #.#.# format. */ + version?: string; + /** A list of available versions for this policy definition. */ + versions?: string[]; } -export interface AliasPathMetadata { - /** - * The type of the token that the alias path is referring to. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly type?: AliasPathTokenType; - /** - * The attributes of the token that the alias path is referring to. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly attributes?: AliasPathAttributes; +/** The definition of a parameter that can be provided to the policy. */ +export interface ParameterDefinitionsValue { + /** The data type of the parameter. */ + type?: ParameterType; + /** The allowed values for the parameter. */ + allowedValues?: any[]; + /** The default value for the parameter if no value is provided. */ + defaultValue?: any; + /** Provides validation of parameter inputs during assignment using a self-defined JSON schema. This property is only supported for object-type parameters and follows the Json.NET Schema 2019-09 implementation. You can learn more about using schemas at https://json-schema.org/ and test draft schemas at https://www.jsonschemavalidator.net/. */ + schema?: any; + /** General metadata for the parameter. */ + metadata?: ParameterDefinitionsValueMetadata; } -/** The data effect definition. */ -export interface DataEffect { - /** The data effect name. */ - name?: string; - /** The data effect details schema. */ - detailsSchema?: any; +/** General metadata for the parameter. */ +export interface ParameterDefinitionsValueMetadata { + /** Describes unknown properties. The value of an unknown property can be of "any" type. */ + [property: string]: any; + /** The display name for the parameter. */ + displayName?: string; + /** The description of the parameter. */ + description?: string; + /** Used when assigning the policy definition through the portal. Provides a context aware list of values for the user to choose from. */ + strongType?: string; + /** Set to true to have Azure portal create role assignments on the resource ID or resource scope value of this parameter during policy assignment. This property is useful in case you wish to assign permissions outside the assignment scope. */ + assignPermissions?: boolean; } -/** The custom resource function definition. */ -export interface DataManifestCustomResourceFunctionDefinition { - /** The function name as it will appear in the policy rule. eg - 'vault'. */ - name?: string; - /** The fully qualified control plane resource type that this function represents. eg - 'Microsoft.KeyVault/vaults'. */ - fullyQualifiedResourceType?: string; - /** The top-level properties that can be selected on the function's output. eg - [ "name", "location" ] if vault().name and vault().location are supported */ - defaultProperties?: string[]; - /** A value indicating whether the custom properties within the property bag are allowed. Needs api-version to be specified in the policy rule eg - vault('2019-06-01'). */ - allowCustomProperties?: boolean; +/** Metadata pertaining to creation and last modification of the resource. */ +export interface SystemData { + /** The identity that created the resource. */ + createdBy?: string; + /** The type of identity that created the resource. */ + createdByType?: CreatedByType; + /** The timestamp of resource creation (UTC). */ + createdAt?: Date; + /** The identity that last modified the resource. */ + lastModifiedBy?: string; + /** The type of identity that last modified the resource. */ + lastModifiedByType?: CreatedByType; + /** The timestamp of resource last modification (UTC) */ + lastModifiedAt?: Date; } /** An error response from a policy operation. */ @@ -177,155 +143,36 @@ export interface ErrorAdditionalInfo { readonly info?: any; } -/** List of data policy manifests. */ -export interface DataPolicyManifestListResult { - /** An array of data policy manifests. */ - value?: DataPolicyManifest[]; +/** List of policy definitions. */ +export interface PolicyDefinitionListResult { + /** An array of policy definitions. */ + value?: PolicyDefinition[]; /** The URL to use for getting the next set of results. */ nextLink?: string; } -/** The policy assignment. */ -export interface PolicyAssignment { - /** - * The ID of the policy assignment. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly id?: string; - /** - * The type of the policy assignment. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly type?: string; - /** - * The name of the policy assignment. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly name?: string; - /** The location of the policy assignment. Only required when utilizing managed identity. */ - location?: string; - /** The managed identity associated with the policy assignment. */ - identity?: Identity; - /** - * The system metadata relating to this resource. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly systemData?: SystemData; - /** The display name of the policy assignment. */ - displayName?: string; - /** The ID of the policy definition or policy set definition being assigned. */ - policyDefinitionId?: string; - /** - * The scope for the policy assignment. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly scope?: string; - /** The policy's excluded scopes. */ - notScopes?: string[]; - /** The parameter values for the assigned policy rule. The keys are the parameter names. */ - parameters?: { [propertyName: string]: ParameterValuesValue }; - /** This message will be part of response in case of policy violation. */ - description?: string; - /** The policy assignment metadata. Metadata is an open ended object and is typically a collection of key value pairs. */ - metadata?: any; - /** The policy assignment enforcement mode. Possible values are Default and DoNotEnforce. */ - enforcementMode?: EnforcementMode; - /** The messages that describe why a resource is non-compliant with the policy. */ - nonComplianceMessages?: NonComplianceMessage[]; -} - -/** The value of a parameter. */ -export interface ParameterValuesValue { - /** The value of the parameter. */ - value?: any; -} - -/** A message that describes why a resource is non-compliant with the policy. This is shown in 'deny' error messages and on resource's non-compliant compliance results. */ -export interface NonComplianceMessage { - /** A message that describes why a resource is non-compliant with the policy. This is shown in 'deny' error messages and on resource's non-compliant compliance results. */ - message: string; - /** The policy definition reference ID within a policy set definition the message is intended for. This is only applicable if the policy assignment assigns a policy set definition. If this is not provided the message applies to all policies assigned by this policy assignment. */ - policyDefinitionReferenceId?: string; -} - -/** Identity for the resource. Policy assignments support a maximum of one identity. That is either a system assigned identity or a single user assigned identity. */ -export interface Identity { - /** - * The principal ID of the resource identity. This property will only be provided for a system assigned identity - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly principalId?: string; - /** - * The tenant ID of the resource identity. This property will only be provided for a system assigned identity - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly tenantId?: string; - /** The identity type. This is the only required field when adding a system or user assigned identity to a resource. */ - type?: ResourceIdentityType; - /** The user identity associated with the policy. The user identity dictionary key references will be ARM resource ids in the form: '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{identityName}'. */ - userAssignedIdentities?: { - [propertyName: string]: UserAssignedIdentitiesValue; - }; -} - -export interface UserAssignedIdentitiesValue { - /** - * The principal id of user assigned identity. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly principalId?: string; - /** - * The client id of user assigned identity. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly clientId?: string; -} - -/** Metadata pertaining to creation and last modification of the resource. */ -export interface SystemData { - /** The identity that created the resource. */ - createdBy?: string; - /** The type of identity that created the resource. */ - createdByType?: CreatedByType; - /** The timestamp of resource creation (UTC). */ - createdAt?: Date; - /** The identity that last modified the resource. */ - lastModifiedBy?: string; - /** The type of identity that last modified the resource. */ - lastModifiedByType?: CreatedByType; - /** The timestamp of resource last modification (UTC) */ - lastModifiedAt?: Date; -} - -export interface PolicyAssignmentUpdate { - /** The location of the policy assignment. Only required when utilizing managed identity. */ - location?: string; - /** The managed identity associated with the policy assignment. */ - identity?: Identity; -} - -/** List of policy assignments. */ -export interface PolicyAssignmentListResult { - /** An array of policy assignments. */ - value?: PolicyAssignment[]; +/** List of policy definition versions. */ +export interface PolicyDefinitionVersionListResult { + /** An array of policy definitions versions. */ + value?: PolicyDefinitionVersion[]; /** The URL to use for getting the next set of results. */ nextLink?: string; } -/** The policy definition. */ -export interface PolicyDefinition { +/** The ID of the policy definition version. */ +export interface PolicyDefinitionVersion { /** - * The ID of the policy definition. + * The ID of the policy definition version. * NOTE: This property will not be serialized. It can only be populated by the server. */ readonly id?: string; /** - * The name of the policy definition. + * The name of the policy definition version. * NOTE: This property will not be serialized. It can only be populated by the server. */ readonly name?: string; /** - * The type of the resource (Microsoft.Authorization/policyDefinitions). + * The type of the resource (Microsoft.Authorization/policyDefinitions/versions). * NOTE: This property will not be serialized. It can only be populated by the server. */ readonly type?: string; @@ -348,40 +195,8 @@ export interface PolicyDefinition { metadata?: any; /** The parameter definitions for parameters used in the policy rule. The keys are the parameter names. */ parameters?: { [propertyName: string]: ParameterDefinitionsValue }; -} - -/** The definition of a parameter that can be provided to the policy. */ -export interface ParameterDefinitionsValue { - /** The data type of the parameter. */ - type?: ParameterType; - /** The allowed values for the parameter. */ - allowedValues?: any[]; - /** The default value for the parameter if no value is provided. */ - defaultValue?: any; - /** General metadata for the parameter. */ - metadata?: ParameterDefinitionsValueMetadata; -} - -/** General metadata for the parameter. */ -export interface ParameterDefinitionsValueMetadata { - /** Describes unknown properties. The value of an unknown property can be of "any" type. */ - [property: string]: any; - /** The display name for the parameter. */ - displayName?: string; - /** The description of the parameter. */ - description?: string; - /** Used when assigning the policy definition through the portal. Provides a context aware list of values for the user to choose from. */ - strongType?: string; - /** Set to true to have Azure portal create role assignments on the resource ID or resource scope value of this parameter during policy assignment. This property is useful in case you wish to assign permissions outside the assignment scope. */ - assignPermissions?: boolean; -} - -/** List of policy definitions. */ -export interface PolicyDefinitionListResult { - /** An array of policy definitions. */ - value?: PolicyDefinition[]; - /** The URL to use for getting the next set of results. */ - nextLink?: string; + /** The policy definition version in #.#.# format. */ + version?: string; } /** The policy set definition. */ @@ -406,7 +221,7 @@ export interface PolicySetDefinition { * NOTE: This property will not be serialized. It can only be populated by the server. */ readonly systemData?: SystemData; - /** The type of policy definition. Possible values are NotSpecified, BuiltIn, Custom, and Static. */ + /** The type of policy set definition. Possible values are NotSpecified, BuiltIn, Custom, and Static. */ policyType?: PolicyType; /** The display name of the policy set definition. */ displayName?: string; @@ -420,12 +235,18 @@ export interface PolicySetDefinition { policyDefinitions?: PolicyDefinitionReference[]; /** The metadata describing groups of policy definition references within the policy set definition. */ policyDefinitionGroups?: PolicyDefinitionGroup[]; + /** The policy set definition version in #.#.# format. */ + version?: string; + /** A list of available versions for this policy set definition. */ + versions?: string[]; } /** The policy definition reference. */ export interface PolicyDefinitionReference { /** The ID of the policy definition or policy set definition. */ policyDefinitionId: string; + /** The version of the policy definition to use. */ + definitionVersion?: string; /** The parameter values for the referenced policy rule. The keys are the parameter names. */ parameters?: { [propertyName: string]: ParameterValuesValue }; /** A unique id (within the policy set definition) for this policy definition reference. */ @@ -434,6 +255,12 @@ export interface PolicyDefinitionReference { groupNames?: string[]; } +/** The value of a parameter. */ +export interface ParameterValuesValue { + /** The value of the parameter. */ + value?: any; +} + /** The policy definition group. */ export interface PolicyDefinitionGroup { /** The name of the group. */ @@ -456,150 +283,199 @@ export interface PolicySetDefinitionListResult { nextLink?: string; } -/** The policy exemption. */ -export interface PolicyExemption { - /** - * Azure Resource Manager metadata containing createdBy and modifiedBy information. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly systemData?: SystemData; +/** List of policy set definition versions. */ +export interface PolicySetDefinitionVersionListResult { + /** An array of policy set definition versions. */ + value?: PolicySetDefinitionVersion[]; + /** The URL to use for getting the next set of results. */ + nextLink?: string; +} + +/** The policy set definition version. */ +export interface PolicySetDefinitionVersion { /** - * The ID of the policy exemption. + * The ID of the policy set definition version. * NOTE: This property will not be serialized. It can only be populated by the server. */ readonly id?: string; /** - * The name of the policy exemption. + * The name of the policy set definition version. * NOTE: This property will not be serialized. It can only be populated by the server. */ readonly name?: string; /** - * The type of the resource (Microsoft.Authorization/policyExemptions). + * The type of the resource (Microsoft.Authorization/policySetDefinitions/versions). * NOTE: This property will not be serialized. It can only be populated by the server. */ readonly type?: string; - /** The ID of the policy assignment that is being exempted. */ - policyAssignmentId: string; - /** The policy definition reference ID list when the associated policy assignment is an assignment of a policy set definition. */ - policyDefinitionReferenceIds?: string[]; - /** The policy exemption category. Possible values are Waiver and Mitigated. */ - exemptionCategory: ExemptionCategory; - /** The expiration date and time (in UTC ISO 8601 format yyyy-MM-ddTHH:mm:ssZ) of the policy exemption. */ - expiresOn?: Date; - /** The display name of the policy exemption. */ + /** + * The system metadata relating to this resource. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly systemData?: SystemData; + /** The type of policy definition. Possible values are NotSpecified, BuiltIn, Custom, and Static. */ + policyType?: PolicyType; + /** The display name of the policy set definition. */ displayName?: string; - /** The description of the policy exemption. */ + /** The policy set definition description. */ description?: string; - /** The policy exemption metadata. Metadata is an open ended object and is typically a collection of key value pairs. */ + /** The policy set definition metadata. Metadata is an open ended object and is typically a collection of key value pairs. */ metadata?: any; + /** The policy set definition parameters that can be used in policy definition references. */ + parameters?: { [propertyName: string]: ParameterDefinitionsValue }; + /** An array of policy definition references. */ + policyDefinitions?: PolicyDefinitionReference[]; + /** The metadata describing groups of policy definition references within the policy set definition. */ + policyDefinitionGroups?: PolicyDefinitionGroup[]; + /** The policy set definition version in #.#.# format. */ + version?: string; } -/** List of policy exemptions. */ -export interface PolicyExemptionListResult { - /** An array of policy exemptions. */ - value?: PolicyExemption[]; +/** The policy assignment. */ +export interface PolicyAssignment { + /** + * The ID of the policy assignment. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly id?: string; /** - * The URL to use for getting the next set of results. + * The type of the policy assignment. * NOTE: This property will not be serialized. It can only be populated by the server. */ - readonly nextLink?: string; + readonly type?: string; + /** + * The name of the policy assignment. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly name?: string; + /** The location of the policy assignment. Only required when utilizing managed identity. */ + location?: string; + /** The managed identity associated with the policy assignment. */ + identity?: Identity; + /** + * The system metadata relating to this resource. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly systemData?: SystemData; + /** The display name of the policy assignment. */ + displayName?: string; + /** The ID of the policy definition or policy set definition being assigned. */ + policyDefinitionId?: string; + /** The version of the policy definition to use. */ + definitionVersion?: string; + /** + * The scope for the policy assignment. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly scope?: string; + /** The policy's excluded scopes. */ + notScopes?: string[]; + /** The parameter values for the assigned policy rule. The keys are the parameter names. */ + parameters?: { [propertyName: string]: ParameterValuesValue }; + /** This message will be part of response in case of policy violation. */ + description?: string; + /** The policy assignment metadata. Metadata is an open ended object and is typically a collection of key value pairs. */ + metadata?: any; + /** The policy assignment enforcement mode. Possible values are Default and DoNotEnforce. */ + enforcementMode?: EnforcementMode; + /** The messages that describe why a resource is non-compliant with the policy. */ + nonComplianceMessages?: NonComplianceMessage[]; + /** The resource selector list to filter policies by resource properties. */ + resourceSelectors?: ResourceSelector[]; + /** The policy property value override. */ + overrides?: Override[]; + /** The type of policy assignment. Possible values are NotSpecified, System, SystemHidden, and Custom. Immutable. */ + assignmentType?: AssignmentType; } -/** Known values of {@link AliasPathTokenType} that the service accepts. */ -export enum KnownAliasPathTokenType { - /** The token type is not specified. */ - NotSpecified = "NotSpecified", - /** The token type can be anything. */ - Any = "Any", - /** The token type is string. */ - String = "String", - /** The token type is object. */ - Object = "Object", - /** The token type is array. */ - Array = "Array", - /** The token type is integer. */ - Integer = "Integer", - /** The token type is number. */ - Number = "Number", - /** The token type is boolean. */ - Boolean = "Boolean" +/** A message that describes why a resource is non-compliant with the policy. This is shown in 'deny' error messages and on resource's non-compliant compliance results. */ +export interface NonComplianceMessage { + /** A message that describes why a resource is non-compliant with the policy. This is shown in 'deny' error messages and on resource's non-compliant compliance results. */ + message: string; + /** The policy definition reference ID within a policy set definition the message is intended for. This is only applicable if the policy assignment assigns a policy set definition. If this is not provided the message applies to all policies assigned by this policy assignment. */ + policyDefinitionReferenceId?: string; } -/** - * Defines values for AliasPathTokenType. \ - * {@link KnownAliasPathTokenType} can be used interchangeably with AliasPathTokenType, - * this enum contains the known values that the service supports. - * ### Known values supported by the service - * **NotSpecified**: The token type is not specified. \ - * **Any**: The token type can be anything. \ - * **String**: The token type is string. \ - * **Object**: The token type is object. \ - * **Array**: The token type is array. \ - * **Integer**: The token type is integer. \ - * **Number**: The token type is number. \ - * **Boolean**: The token type is boolean. - */ -export type AliasPathTokenType = string; - -/** Known values of {@link AliasPathAttributes} that the service accepts. */ -export enum KnownAliasPathAttributes { - /** The token that the alias path is referring to has no attributes. */ - None = "None", - /** The token that the alias path is referring to is modifiable by policies with 'modify' effect. */ - Modifiable = "Modifiable" +/** The resource selector to filter policies by resource properties. */ +export interface ResourceSelector { + /** The name of the resource selector. */ + name?: string; + /** The list of the selector expressions. */ + selectors?: Selector[]; } -/** - * Defines values for AliasPathAttributes. \ - * {@link KnownAliasPathAttributes} can be used interchangeably with AliasPathAttributes, - * this enum contains the known values that the service supports. - * ### Known values supported by the service - * **None**: The token that the alias path is referring to has no attributes. \ - * **Modifiable**: The token that the alias path is referring to is modifiable by policies with 'modify' effect. - */ -export type AliasPathAttributes = string; +/** The selector expression. */ +export interface Selector { + /** The selector kind. */ + kind?: SelectorKind; + /** The list of values to filter in. */ + in?: string[]; + /** The list of values to filter out. */ + notIn?: string[]; +} -/** Known values of {@link EnforcementMode} that the service accepts. */ -export enum KnownEnforcementMode { - /** The policy effect is enforced during resource creation or update. */ - Default = "Default", - /** The policy effect is not enforced during resource creation or update. */ - DoNotEnforce = "DoNotEnforce" +/** The policy property value override. */ +export interface Override { + /** The override kind. */ + kind?: OverrideKind; + /** The value to override the policy property. */ + value?: string; + /** The list of the selector expressions. */ + selectors?: Selector[]; } -/** - * Defines values for EnforcementMode. \ - * {@link KnownEnforcementMode} can be used interchangeably with EnforcementMode, - * this enum contains the known values that the service supports. - * ### Known values supported by the service - * **Default**: The policy effect is enforced during resource creation or update. \ - * **DoNotEnforce**: The policy effect is not enforced during resource creation or update. - */ -export type EnforcementMode = string; +/** Identity for the resource. Policy assignments support a maximum of one identity. That is either a system assigned identity or a single user assigned identity. */ +export interface Identity { + /** + * The principal ID of the resource identity. This property will only be provided for a system assigned identity + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly principalId?: string; + /** + * The tenant ID of the resource identity. This property will only be provided for a system assigned identity + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly tenantId?: string; + /** The identity type. This is the only required field when adding a system or user assigned identity to a resource. */ + type?: ResourceIdentityType; + /** The user identity associated with the policy. The user identity dictionary key references will be ARM resource ids in the form: '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{identityName}'. */ + userAssignedIdentities?: { + [propertyName: string]: UserAssignedIdentitiesValue; + }; +} -/** Known values of {@link CreatedByType} that the service accepts. */ -export enum KnownCreatedByType { - /** User */ - User = "User", - /** Application */ - Application = "Application", - /** ManagedIdentity */ - ManagedIdentity = "ManagedIdentity", - /** Key */ - Key = "Key" +export interface UserAssignedIdentitiesValue { + /** + * The principal id of user assigned identity. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly principalId?: string; + /** + * The client id of user assigned identity. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly clientId?: string; } -/** - * Defines values for CreatedByType. \ - * {@link KnownCreatedByType} can be used interchangeably with CreatedByType, - * this enum contains the known values that the service supports. - * ### Known values supported by the service - * **User** \ - * **Application** \ - * **ManagedIdentity** \ - * **Key** - */ -export type CreatedByType = string; +/** The policy assignment for Patch request. */ +export interface PolicyAssignmentUpdate { + /** The location of the policy assignment. Only required when utilizing managed identity. */ + location?: string; + /** The managed identity associated with the policy assignment. */ + identity?: Identity; + /** The resource selector list to filter policies by resource properties. */ + resourceSelectors?: ResourceSelector[]; + /** The policy property value override. */ + overrides?: Override[]; +} + +/** List of policy assignments. */ +export interface PolicyAssignmentListResult { + /** An array of policy assignments. */ + value?: PolicyAssignment[]; + /** The URL to use for getting the next set of results. */ + nextLink?: string; +} /** Known values of {@link PolicyType} that the service accepts. */ export enum KnownPolicyType { @@ -610,7 +486,7 @@ export enum KnownPolicyType { /** Custom */ Custom = "Custom", /** Static */ - Static = "Static" + Static = "Static", } /** @@ -640,7 +516,7 @@ export enum KnownParameterType { /** Float */ Float = "Float", /** DateTime */ - DateTime = "DateTime" + DateTime = "DateTime", } /** @@ -658,285 +534,347 @@ export enum KnownParameterType { */ export type ParameterType = string; -/** Known values of {@link ExemptionCategory} that the service accepts. */ -export enum KnownExemptionCategory { - /** This category of exemptions usually means the scope is not applicable for the policy. */ - Waiver = "Waiver", - /** This category of exemptions usually means the mitigation actions have been applied to the scope. */ - Mitigated = "Mitigated" +/** Known values of {@link CreatedByType} that the service accepts. */ +export enum KnownCreatedByType { + /** User */ + User = "User", + /** Application */ + Application = "Application", + /** ManagedIdentity */ + ManagedIdentity = "ManagedIdentity", + /** Key */ + Key = "Key", } /** - * Defines values for ExemptionCategory. \ - * {@link KnownExemptionCategory} can be used interchangeably with ExemptionCategory, + * Defines values for CreatedByType. \ + * {@link KnownCreatedByType} can be used interchangeably with CreatedByType, * this enum contains the known values that the service supports. * ### Known values supported by the service - * **Waiver**: This category of exemptions usually means the scope is not applicable for the policy. \ - * **Mitigated**: This category of exemptions usually means the mitigation actions have been applied to the scope. + * **User** \ + * **Application** \ + * **ManagedIdentity** \ + * **Key** */ -export type ExemptionCategory = string; -/** Defines values for AliasPatternType. */ -export type AliasPatternType = "NotSpecified" | "Extract"; -/** Defines values for AliasType. */ -export type AliasType = "NotSpecified" | "PlainText" | "Mask"; -/** Defines values for ResourceIdentityType. */ -export type ResourceIdentityType = "SystemAssigned" | "UserAssigned" | "None"; +export type CreatedByType = string; -/** Optional parameters. */ -export interface DataPolicyManifestsGetByPolicyModeOptionalParams - extends coreClient.OperationOptions {} +/** Known values of {@link EnforcementMode} that the service accepts. */ +export enum KnownEnforcementMode { + /** The policy effect is enforced during resource creation or update. */ + Default = "Default", + /** The policy effect is not enforced during resource creation or update. */ + DoNotEnforce = "DoNotEnforce", +} -/** Contains response data for the getByPolicyMode operation. */ -export type DataPolicyManifestsGetByPolicyModeResponse = DataPolicyManifest; +/** + * Defines values for EnforcementMode. \ + * {@link KnownEnforcementMode} can be used interchangeably with EnforcementMode, + * this enum contains the known values that the service supports. + * ### Known values supported by the service + * **Default**: The policy effect is enforced during resource creation or update. \ + * **DoNotEnforce**: The policy effect is not enforced during resource creation or update. + */ +export type EnforcementMode = string; -/** Optional parameters. */ -export interface DataPolicyManifestsListOptionalParams - extends coreClient.OperationOptions { - /** The filter to apply on the operation. Valid values for $filter are: "namespace eq '{value}'". If $filter is not provided, no filtering is performed. If $filter=namespace eq '{value}' is provided, the returned list only includes all data policy manifests that have a namespace matching the provided value. */ - filter?: string; +/** Known values of {@link SelectorKind} that the service accepts. */ +export enum KnownSelectorKind { + /** The selector kind to filter policies by the resource location. */ + ResourceLocation = "resourceLocation", + /** The selector kind to filter policies by the resource type. */ + ResourceType = "resourceType", + /** The selector kind to filter policies by the resource without location. */ + ResourceWithoutLocation = "resourceWithoutLocation", + /** The selector kind to filter policies by the policy definition reference ID. */ + PolicyDefinitionReferenceId = "policyDefinitionReferenceId", } -/** Contains response data for the list operation. */ -export type DataPolicyManifestsListResponse = DataPolicyManifestListResult; +/** + * Defines values for SelectorKind. \ + * {@link KnownSelectorKind} can be used interchangeably with SelectorKind, + * this enum contains the known values that the service supports. + * ### Known values supported by the service + * **resourceLocation**: The selector kind to filter policies by the resource location. \ + * **resourceType**: The selector kind to filter policies by the resource type. \ + * **resourceWithoutLocation**: The selector kind to filter policies by the resource without location. \ + * **policyDefinitionReferenceId**: The selector kind to filter policies by the policy definition reference ID. + */ +export type SelectorKind = string; + +/** Known values of {@link OverrideKind} that the service accepts. */ +export enum KnownOverrideKind { + /** It will override the policy effect type. */ + PolicyEffect = "policyEffect", + /** It will override the definition version property value of the policy assignment. */ + DefinitionVersion = "definitionVersion", +} + +/** + * Defines values for OverrideKind. \ + * {@link KnownOverrideKind} can be used interchangeably with OverrideKind, + * this enum contains the known values that the service supports. + * ### Known values supported by the service + * **policyEffect**: It will override the policy effect type. \ + * **definitionVersion**: It will override the definition version property value of the policy assignment. + */ +export type OverrideKind = string; + +/** Known values of {@link AssignmentType} that the service accepts. */ +export enum KnownAssignmentType { + /** NotSpecified */ + NotSpecified = "NotSpecified", + /** System */ + System = "System", + /** SystemHidden */ + SystemHidden = "SystemHidden", + /** Custom */ + Custom = "Custom", +} + +/** + * Defines values for AssignmentType. \ + * {@link KnownAssignmentType} can be used interchangeably with AssignmentType, + * this enum contains the known values that the service supports. + * ### Known values supported by the service + * **NotSpecified** \ + * **System** \ + * **SystemHidden** \ + * **Custom** + */ +export type AssignmentType = string; +/** Defines values for ResourceIdentityType. */ +export type ResourceIdentityType = "SystemAssigned" | "UserAssigned" | "None"; /** Optional parameters. */ -export interface DataPolicyManifestsListNextOptionalParams +export interface PolicyDefinitionsCreateOrUpdateOptionalParams extends coreClient.OperationOptions {} -/** Contains response data for the listNext operation. */ -export type DataPolicyManifestsListNextResponse = DataPolicyManifestListResult; +/** Contains response data for the createOrUpdate operation. */ +export type PolicyDefinitionsCreateOrUpdateResponse = PolicyDefinition; /** Optional parameters. */ -export interface PolicyAssignmentsDeleteOptionalParams +export interface PolicyDefinitionsDeleteOptionalParams extends coreClient.OperationOptions {} -/** Contains response data for the delete operation. */ -export type PolicyAssignmentsDeleteResponse = PolicyAssignment; +/** Optional parameters. */ +export interface PolicyDefinitionsGetOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the get operation. */ +export type PolicyDefinitionsGetResponse = PolicyDefinition; /** Optional parameters. */ -export interface PolicyAssignmentsCreateOptionalParams +export interface PolicyDefinitionsGetBuiltInOptionalParams extends coreClient.OperationOptions {} -/** Contains response data for the create operation. */ -export type PolicyAssignmentsCreateResponse = PolicyAssignment; +/** Contains response data for the getBuiltIn operation. */ +export type PolicyDefinitionsGetBuiltInResponse = PolicyDefinition; /** Optional parameters. */ -export interface PolicyAssignmentsGetOptionalParams +export interface PolicyDefinitionsCreateOrUpdateAtManagementGroupOptionalParams extends coreClient.OperationOptions {} -/** Contains response data for the get operation. */ -export type PolicyAssignmentsGetResponse = PolicyAssignment; +/** Contains response data for the createOrUpdateAtManagementGroup operation. */ +export type PolicyDefinitionsCreateOrUpdateAtManagementGroupResponse = + PolicyDefinition; /** Optional parameters. */ -export interface PolicyAssignmentsUpdateOptionalParams +export interface PolicyDefinitionsDeleteAtManagementGroupOptionalParams extends coreClient.OperationOptions {} -/** Contains response data for the update operation. */ -export type PolicyAssignmentsUpdateResponse = PolicyAssignment; - /** Optional parameters. */ -export interface PolicyAssignmentsListForResourceGroupOptionalParams - extends coreClient.OperationOptions { - /** The filter to apply on the operation. Valid values for $filter are: 'atScope()', 'atExactScope()' or 'policyDefinitionId eq '{value}''. If $filter is not provided, no filtering is performed. If $filter=atScope() is provided, the returned list only includes all policy assignments that apply to the scope, which is everything in the unfiltered list except those applied to sub scopes contained within the given scope. If $filter=atExactScope() is provided, the returned list only includes all policy assignments that at the given scope. If $filter=policyDefinitionId eq '{value}' is provided, the returned list includes all policy assignments of the policy definition whose id is {value}. */ - filter?: string; - /** Maximum number of records to return. When the $top filter is not provided, it will return 500 records. */ - top?: number; -} +export interface PolicyDefinitionsGetAtManagementGroupOptionalParams + extends coreClient.OperationOptions {} -/** Contains response data for the listForResourceGroup operation. */ -export type PolicyAssignmentsListForResourceGroupResponse = PolicyAssignmentListResult; +/** Contains response data for the getAtManagementGroup operation. */ +export type PolicyDefinitionsGetAtManagementGroupResponse = PolicyDefinition; /** Optional parameters. */ -export interface PolicyAssignmentsListForResourceOptionalParams +export interface PolicyDefinitionsListOptionalParams extends coreClient.OperationOptions { - /** The filter to apply on the operation. Valid values for $filter are: 'atScope()', 'atExactScope()' or 'policyDefinitionId eq '{value}''. If $filter is not provided, no filtering is performed. If $filter=atScope() is provided, the returned list only includes all policy assignments that apply to the scope, which is everything in the unfiltered list except those applied to sub scopes contained within the given scope. If $filter=atExactScope() is provided, the returned list only includes all policy assignments that at the given scope. If $filter=policyDefinitionId eq '{value}' is provided, the returned list includes all policy assignments of the policy definition whose id is {value}. */ + /** The filter to apply on the operation. Valid values for $filter are: 'atExactScope()', 'policyType -eq {value}' or 'category eq '{value}''. If $filter is not provided, no filtering is performed. If $filter=atExactScope() is provided, the returned list only includes all policy definitions that at the given scope. If $filter='policyType -eq {value}' is provided, the returned list only includes all policy definitions whose type match the {value}. Possible policyType values are NotSpecified, BuiltIn, Custom, and Static. If $filter='category -eq {value}' is provided, the returned list only includes all policy definitions whose category match the {value}. */ filter?: string; /** Maximum number of records to return. When the $top filter is not provided, it will return 500 records. */ top?: number; } -/** Contains response data for the listForResource operation. */ -export type PolicyAssignmentsListForResourceResponse = PolicyAssignmentListResult; +/** Contains response data for the list operation. */ +export type PolicyDefinitionsListResponse = PolicyDefinitionListResult; /** Optional parameters. */ -export interface PolicyAssignmentsListForManagementGroupOptionalParams +export interface PolicyDefinitionsListBuiltInOptionalParams extends coreClient.OperationOptions { - /** The filter to apply on the operation. Valid values for $filter are: 'atScope()', 'atExactScope()' or 'policyDefinitionId eq '{value}''. If $filter is not provided, no filtering is performed. If $filter=atScope() is provided, the returned list only includes all policy assignments that apply to the scope, which is everything in the unfiltered list except those applied to sub scopes contained within the given scope. If $filter=atExactScope() is provided, the returned list only includes all policy assignments that at the given scope. If $filter=policyDefinitionId eq '{value}' is provided, the returned list includes all policy assignments of the policy definition whose id is {value}. */ + /** The filter to apply on the operation. Valid values for $filter are: 'atExactScope()', 'policyType -eq {value}' or 'category eq '{value}''. If $filter is not provided, no filtering is performed. If $filter=atExactScope() is provided, the returned list only includes all policy definitions that at the given scope. If $filter='policyType -eq {value}' is provided, the returned list only includes all policy definitions whose type match the {value}. Possible policyType values are NotSpecified, BuiltIn, Custom, and Static. If $filter='category -eq {value}' is provided, the returned list only includes all policy definitions whose category match the {value}. */ filter?: string; /** Maximum number of records to return. When the $top filter is not provided, it will return 500 records. */ top?: number; } -/** Contains response data for the listForManagementGroup operation. */ -export type PolicyAssignmentsListForManagementGroupResponse = PolicyAssignmentListResult; +/** Contains response data for the listBuiltIn operation. */ +export type PolicyDefinitionsListBuiltInResponse = PolicyDefinitionListResult; /** Optional parameters. */ -export interface PolicyAssignmentsListOptionalParams +export interface PolicyDefinitionsListByManagementGroupOptionalParams extends coreClient.OperationOptions { - /** The filter to apply on the operation. Valid values for $filter are: 'atScope()', 'atExactScope()' or 'policyDefinitionId eq '{value}''. If $filter is not provided, no filtering is performed. If $filter=atScope() is provided, the returned list only includes all policy assignments that apply to the scope, which is everything in the unfiltered list except those applied to sub scopes contained within the given scope. If $filter=atExactScope() is provided, the returned list only includes all policy assignments that at the given scope. If $filter=policyDefinitionId eq '{value}' is provided, the returned list includes all policy assignments of the policy definition whose id is {value}. */ + /** The filter to apply on the operation. Valid values for $filter are: 'atExactScope()', 'policyType -eq {value}' or 'category eq '{value}''. If $filter is not provided, no filtering is performed. If $filter=atExactScope() is provided, the returned list only includes all policy definitions that at the given scope. If $filter='policyType -eq {value}' is provided, the returned list only includes all policy definitions whose type match the {value}. Possible policyType values are NotSpecified, BuiltIn, Custom, and Static. If $filter='category -eq {value}' is provided, the returned list only includes all policy definitions whose category match the {value}. */ filter?: string; /** Maximum number of records to return. When the $top filter is not provided, it will return 500 records. */ top?: number; } -/** Contains response data for the list operation. */ -export type PolicyAssignmentsListResponse = PolicyAssignmentListResult; - -/** Optional parameters. */ -export interface PolicyAssignmentsDeleteByIdOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the deleteById operation. */ -export type PolicyAssignmentsDeleteByIdResponse = PolicyAssignment; - -/** Optional parameters. */ -export interface PolicyAssignmentsCreateByIdOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the createById operation. */ -export type PolicyAssignmentsCreateByIdResponse = PolicyAssignment; +/** Contains response data for the listByManagementGroup operation. */ +export type PolicyDefinitionsListByManagementGroupResponse = + PolicyDefinitionListResult; /** Optional parameters. */ -export interface PolicyAssignmentsGetByIdOptionalParams +export interface PolicyDefinitionsListNextOptionalParams extends coreClient.OperationOptions {} -/** Contains response data for the getById operation. */ -export type PolicyAssignmentsGetByIdResponse = PolicyAssignment; +/** Contains response data for the listNext operation. */ +export type PolicyDefinitionsListNextResponse = PolicyDefinitionListResult; /** Optional parameters. */ -export interface PolicyAssignmentsUpdateByIdOptionalParams +export interface PolicyDefinitionsListBuiltInNextOptionalParams extends coreClient.OperationOptions {} -/** Contains response data for the updateById operation. */ -export type PolicyAssignmentsUpdateByIdResponse = PolicyAssignment; +/** Contains response data for the listBuiltInNext operation. */ +export type PolicyDefinitionsListBuiltInNextResponse = + PolicyDefinitionListResult; /** Optional parameters. */ -export interface PolicyAssignmentsListForResourceGroupNextOptionalParams +export interface PolicyDefinitionsListByManagementGroupNextOptionalParams extends coreClient.OperationOptions {} -/** Contains response data for the listForResourceGroupNext operation. */ -export type PolicyAssignmentsListForResourceGroupNextResponse = PolicyAssignmentListResult; +/** Contains response data for the listByManagementGroupNext operation. */ +export type PolicyDefinitionsListByManagementGroupNextResponse = + PolicyDefinitionListResult; /** Optional parameters. */ -export interface PolicyAssignmentsListForResourceNextOptionalParams +export interface PolicyDefinitionVersionsListAllBuiltinsOptionalParams extends coreClient.OperationOptions {} -/** Contains response data for the listForResourceNext operation. */ -export type PolicyAssignmentsListForResourceNextResponse = PolicyAssignmentListResult; +/** Contains response data for the listAllBuiltins operation. */ +export type PolicyDefinitionVersionsListAllBuiltinsResponse = + PolicyDefinitionVersionListResult; /** Optional parameters. */ -export interface PolicyAssignmentsListForManagementGroupNextOptionalParams +export interface PolicyDefinitionVersionsListAllAtManagementGroupOptionalParams extends coreClient.OperationOptions {} -/** Contains response data for the listForManagementGroupNext operation. */ -export type PolicyAssignmentsListForManagementGroupNextResponse = PolicyAssignmentListResult; +/** Contains response data for the listAllAtManagementGroup operation. */ +export type PolicyDefinitionVersionsListAllAtManagementGroupResponse = + PolicyDefinitionVersionListResult; /** Optional parameters. */ -export interface PolicyAssignmentsListNextOptionalParams +export interface PolicyDefinitionVersionsListAllOptionalParams extends coreClient.OperationOptions {} -/** Contains response data for the listNext operation. */ -export type PolicyAssignmentsListNextResponse = PolicyAssignmentListResult; +/** Contains response data for the listAll operation. */ +export type PolicyDefinitionVersionsListAllResponse = + PolicyDefinitionVersionListResult; /** Optional parameters. */ -export interface PolicyDefinitionsCreateOrUpdateOptionalParams +export interface PolicyDefinitionVersionsCreateOrUpdateOptionalParams extends coreClient.OperationOptions {} /** Contains response data for the createOrUpdate operation. */ -export type PolicyDefinitionsCreateOrUpdateResponse = PolicyDefinition; +export type PolicyDefinitionVersionsCreateOrUpdateResponse = + PolicyDefinitionVersion; /** Optional parameters. */ -export interface PolicyDefinitionsDeleteOptionalParams +export interface PolicyDefinitionVersionsDeleteOptionalParams extends coreClient.OperationOptions {} /** Optional parameters. */ -export interface PolicyDefinitionsGetOptionalParams +export interface PolicyDefinitionVersionsGetOptionalParams extends coreClient.OperationOptions {} /** Contains response data for the get operation. */ -export type PolicyDefinitionsGetResponse = PolicyDefinition; +export type PolicyDefinitionVersionsGetResponse = PolicyDefinitionVersion; /** Optional parameters. */ -export interface PolicyDefinitionsGetBuiltInOptionalParams +export interface PolicyDefinitionVersionsGetBuiltInOptionalParams extends coreClient.OperationOptions {} /** Contains response data for the getBuiltIn operation. */ -export type PolicyDefinitionsGetBuiltInResponse = PolicyDefinition; +export type PolicyDefinitionVersionsGetBuiltInResponse = + PolicyDefinitionVersion; /** Optional parameters. */ -export interface PolicyDefinitionsCreateOrUpdateAtManagementGroupOptionalParams +export interface PolicyDefinitionVersionsCreateOrUpdateAtManagementGroupOptionalParams extends coreClient.OperationOptions {} /** Contains response data for the createOrUpdateAtManagementGroup operation. */ -export type PolicyDefinitionsCreateOrUpdateAtManagementGroupResponse = PolicyDefinition; +export type PolicyDefinitionVersionsCreateOrUpdateAtManagementGroupResponse = + PolicyDefinitionVersion; /** Optional parameters. */ -export interface PolicyDefinitionsDeleteAtManagementGroupOptionalParams +export interface PolicyDefinitionVersionsDeleteAtManagementGroupOptionalParams extends coreClient.OperationOptions {} /** Optional parameters. */ -export interface PolicyDefinitionsGetAtManagementGroupOptionalParams +export interface PolicyDefinitionVersionsGetAtManagementGroupOptionalParams extends coreClient.OperationOptions {} /** Contains response data for the getAtManagementGroup operation. */ -export type PolicyDefinitionsGetAtManagementGroupResponse = PolicyDefinition; +export type PolicyDefinitionVersionsGetAtManagementGroupResponse = + PolicyDefinitionVersion; /** Optional parameters. */ -export interface PolicyDefinitionsListOptionalParams +export interface PolicyDefinitionVersionsListOptionalParams extends coreClient.OperationOptions { - /** The filter to apply on the operation. Valid values for $filter are: 'atExactScope()', 'policyType -eq {value}' or 'category eq '{value}''. If $filter is not provided, no filtering is performed. If $filter=atExactScope() is provided, the returned list only includes all policy definitions that at the given scope. If $filter='policyType -eq {value}' is provided, the returned list only includes all policy definitions whose type match the {value}. Possible policyType values are NotSpecified, BuiltIn, Custom, and Static. If $filter='category -eq {value}' is provided, the returned list only includes all policy definitions whose category match the {value}. */ - filter?: string; /** Maximum number of records to return. When the $top filter is not provided, it will return 500 records. */ top?: number; } /** Contains response data for the list operation. */ -export type PolicyDefinitionsListResponse = PolicyDefinitionListResult; +export type PolicyDefinitionVersionsListResponse = + PolicyDefinitionVersionListResult; /** Optional parameters. */ -export interface PolicyDefinitionsListBuiltInOptionalParams +export interface PolicyDefinitionVersionsListBuiltInOptionalParams extends coreClient.OperationOptions { - /** The filter to apply on the operation. Valid values for $filter are: 'atExactScope()', 'policyType -eq {value}' or 'category eq '{value}''. If $filter is not provided, no filtering is performed. If $filter=atExactScope() is provided, the returned list only includes all policy definitions that at the given scope. If $filter='policyType -eq {value}' is provided, the returned list only includes all policy definitions whose type match the {value}. Possible policyType values are NotSpecified, BuiltIn, Custom, and Static. If $filter='category -eq {value}' is provided, the returned list only includes all policy definitions whose category match the {value}. */ - filter?: string; /** Maximum number of records to return. When the $top filter is not provided, it will return 500 records. */ top?: number; } /** Contains response data for the listBuiltIn operation. */ -export type PolicyDefinitionsListBuiltInResponse = PolicyDefinitionListResult; +export type PolicyDefinitionVersionsListBuiltInResponse = + PolicyDefinitionVersionListResult; /** Optional parameters. */ -export interface PolicyDefinitionsListByManagementGroupOptionalParams +export interface PolicyDefinitionVersionsListByManagementGroupOptionalParams extends coreClient.OperationOptions { - /** The filter to apply on the operation. Valid values for $filter are: 'atExactScope()', 'policyType -eq {value}' or 'category eq '{value}''. If $filter is not provided, no filtering is performed. If $filter=atExactScope() is provided, the returned list only includes all policy definitions that at the given scope. If $filter='policyType -eq {value}' is provided, the returned list only includes all policy definitions whose type match the {value}. Possible policyType values are NotSpecified, BuiltIn, Custom, and Static. If $filter='category -eq {value}' is provided, the returned list only includes all policy definitions whose category match the {value}. */ - filter?: string; /** Maximum number of records to return. When the $top filter is not provided, it will return 500 records. */ top?: number; } /** Contains response data for the listByManagementGroup operation. */ -export type PolicyDefinitionsListByManagementGroupResponse = PolicyDefinitionListResult; +export type PolicyDefinitionVersionsListByManagementGroupResponse = + PolicyDefinitionVersionListResult; /** Optional parameters. */ -export interface PolicyDefinitionsListNextOptionalParams +export interface PolicyDefinitionVersionsListNextOptionalParams extends coreClient.OperationOptions {} /** Contains response data for the listNext operation. */ -export type PolicyDefinitionsListNextResponse = PolicyDefinitionListResult; +export type PolicyDefinitionVersionsListNextResponse = + PolicyDefinitionVersionListResult; /** Optional parameters. */ -export interface PolicyDefinitionsListBuiltInNextOptionalParams +export interface PolicyDefinitionVersionsListBuiltInNextOptionalParams extends coreClient.OperationOptions {} /** Contains response data for the listBuiltInNext operation. */ -export type PolicyDefinitionsListBuiltInNextResponse = PolicyDefinitionListResult; +export type PolicyDefinitionVersionsListBuiltInNextResponse = + PolicyDefinitionVersionListResult; /** Optional parameters. */ -export interface PolicyDefinitionsListByManagementGroupNextOptionalParams +export interface PolicyDefinitionVersionsListByManagementGroupNextOptionalParams extends coreClient.OperationOptions {} /** Contains response data for the listByManagementGroupNext operation. */ -export type PolicyDefinitionsListByManagementGroupNextResponse = PolicyDefinitionListResult; +export type PolicyDefinitionVersionsListByManagementGroupNextResponse = + PolicyDefinitionVersionListResult; /** Optional parameters. */ export interface PolicySetDefinitionsCreateOrUpdateOptionalParams @@ -985,14 +923,16 @@ export interface PolicySetDefinitionsListBuiltInOptionalParams } /** Contains response data for the listBuiltIn operation. */ -export type PolicySetDefinitionsListBuiltInResponse = PolicySetDefinitionListResult; +export type PolicySetDefinitionsListBuiltInResponse = + PolicySetDefinitionListResult; /** Optional parameters. */ export interface PolicySetDefinitionsCreateOrUpdateAtManagementGroupOptionalParams extends coreClient.OperationOptions {} /** Contains response data for the createOrUpdateAtManagementGroup operation. */ -export type PolicySetDefinitionsCreateOrUpdateAtManagementGroupResponse = PolicySetDefinition; +export type PolicySetDefinitionsCreateOrUpdateAtManagementGroupResponse = + PolicySetDefinition; /** Optional parameters. */ export interface PolicySetDefinitionsDeleteAtManagementGroupOptionalParams @@ -1003,7 +943,8 @@ export interface PolicySetDefinitionsGetAtManagementGroupOptionalParams extends coreClient.OperationOptions {} /** Contains response data for the getAtManagementGroup operation. */ -export type PolicySetDefinitionsGetAtManagementGroupResponse = PolicySetDefinition; +export type PolicySetDefinitionsGetAtManagementGroupResponse = + PolicySetDefinition; /** Optional parameters. */ export interface PolicySetDefinitionsListByManagementGroupOptionalParams @@ -1015,120 +956,306 @@ export interface PolicySetDefinitionsListByManagementGroupOptionalParams } /** Contains response data for the listByManagementGroup operation. */ -export type PolicySetDefinitionsListByManagementGroupResponse = PolicySetDefinitionListResult; +export type PolicySetDefinitionsListByManagementGroupResponse = + PolicySetDefinitionListResult; /** Optional parameters. */ export interface PolicySetDefinitionsListNextOptionalParams extends coreClient.OperationOptions {} /** Contains response data for the listNext operation. */ -export type PolicySetDefinitionsListNextResponse = PolicySetDefinitionListResult; +export type PolicySetDefinitionsListNextResponse = + PolicySetDefinitionListResult; /** Optional parameters. */ export interface PolicySetDefinitionsListBuiltInNextOptionalParams extends coreClient.OperationOptions {} /** Contains response data for the listBuiltInNext operation. */ -export type PolicySetDefinitionsListBuiltInNextResponse = PolicySetDefinitionListResult; +export type PolicySetDefinitionsListBuiltInNextResponse = + PolicySetDefinitionListResult; /** Optional parameters. */ export interface PolicySetDefinitionsListByManagementGroupNextOptionalParams extends coreClient.OperationOptions {} /** Contains response data for the listByManagementGroupNext operation. */ -export type PolicySetDefinitionsListByManagementGroupNextResponse = PolicySetDefinitionListResult; +export type PolicySetDefinitionsListByManagementGroupNextResponse = + PolicySetDefinitionListResult; + +/** Optional parameters. */ +export interface PolicySetDefinitionVersionsListAllBuiltinsOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the listAllBuiltins operation. */ +export type PolicySetDefinitionVersionsListAllBuiltinsResponse = + PolicySetDefinitionVersionListResult; + +/** Optional parameters. */ +export interface PolicySetDefinitionVersionsListAllAtManagementGroupOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the listAllAtManagementGroup operation. */ +export type PolicySetDefinitionVersionsListAllAtManagementGroupResponse = + PolicySetDefinitionVersionListResult; /** Optional parameters. */ -export interface PolicyExemptionsDeleteOptionalParams +export interface PolicySetDefinitionVersionsListAllOptionalParams extends coreClient.OperationOptions {} +/** Contains response data for the listAll operation. */ +export type PolicySetDefinitionVersionsListAllResponse = + PolicySetDefinitionVersionListResult; + /** Optional parameters. */ -export interface PolicyExemptionsCreateOrUpdateOptionalParams +export interface PolicySetDefinitionVersionsCreateOrUpdateOptionalParams extends coreClient.OperationOptions {} /** Contains response data for the createOrUpdate operation. */ -export type PolicyExemptionsCreateOrUpdateResponse = PolicyExemption; +export type PolicySetDefinitionVersionsCreateOrUpdateResponse = + PolicySetDefinitionVersion; + +/** Optional parameters. */ +export interface PolicySetDefinitionVersionsDeleteOptionalParams + extends coreClient.OperationOptions {} /** Optional parameters. */ -export interface PolicyExemptionsGetOptionalParams +export interface PolicySetDefinitionVersionsGetOptionalParams extends coreClient.OperationOptions {} /** Contains response data for the get operation. */ -export type PolicyExemptionsGetResponse = PolicyExemption; +export type PolicySetDefinitionVersionsGetResponse = PolicySetDefinitionVersion; + +/** Optional parameters. */ +export interface PolicySetDefinitionVersionsGetBuiltInOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the getBuiltIn operation. */ +export type PolicySetDefinitionVersionsGetBuiltInResponse = + PolicySetDefinitionVersion; /** Optional parameters. */ -export interface PolicyExemptionsListOptionalParams +export interface PolicySetDefinitionVersionsListOptionalParams extends coreClient.OperationOptions { - /** The filter to apply on the operation. Valid values for $filter are: 'atScope()', 'atExactScope()', 'excludeExpired()' or 'policyAssignmentId eq '{value}''. If $filter is not provided, no filtering is performed. If $filter is not provided, the unfiltered list includes all policy exemptions associated with the scope, including those that apply directly or apply from containing scopes. If $filter=atScope() is provided, the returned list only includes all policy exemptions that apply to the scope, which is everything in the unfiltered list except those applied to sub scopes contained within the given scope. If $filter=atExactScope() is provided, the returned list only includes all policy exemptions that at the given scope. If $filter=excludeExpired() is provided, the returned list only includes all policy exemptions that either haven't expired or didn't set expiration date. If $filter=policyAssignmentId eq '{value}' is provided. the returned list only includes all policy exemptions that are associated with the give policyAssignmentId. */ - filter?: string; + /** Maximum number of records to return. When the $top filter is not provided, it will return 500 records. */ + top?: number; } /** Contains response data for the list operation. */ -export type PolicyExemptionsListResponse = PolicyExemptionListResult; +export type PolicySetDefinitionVersionsListResponse = + PolicySetDefinitionVersionListResult; + +/** Optional parameters. */ +export interface PolicySetDefinitionVersionsListBuiltInOptionalParams + extends coreClient.OperationOptions { + /** Maximum number of records to return. When the $top filter is not provided, it will return 500 records. */ + top?: number; +} + +/** Contains response data for the listBuiltIn operation. */ +export type PolicySetDefinitionVersionsListBuiltInResponse = + PolicySetDefinitionVersionListResult; + +/** Optional parameters. */ +export interface PolicySetDefinitionVersionsCreateOrUpdateAtManagementGroupOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the createOrUpdateAtManagementGroup operation. */ +export type PolicySetDefinitionVersionsCreateOrUpdateAtManagementGroupResponse = + PolicySetDefinitionVersion; + +/** Optional parameters. */ +export interface PolicySetDefinitionVersionsDeleteAtManagementGroupOptionalParams + extends coreClient.OperationOptions {} + +/** Optional parameters. */ +export interface PolicySetDefinitionVersionsGetAtManagementGroupOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the getAtManagementGroup operation. */ +export type PolicySetDefinitionVersionsGetAtManagementGroupResponse = + PolicySetDefinitionVersion; + +/** Optional parameters. */ +export interface PolicySetDefinitionVersionsListByManagementGroupOptionalParams + extends coreClient.OperationOptions { + /** Maximum number of records to return. When the $top filter is not provided, it will return 500 records. */ + top?: number; +} + +/** Contains response data for the listByManagementGroup operation. */ +export type PolicySetDefinitionVersionsListByManagementGroupResponse = + PolicySetDefinitionVersionListResult; + +/** Optional parameters. */ +export interface PolicySetDefinitionVersionsListNextOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the listNext operation. */ +export type PolicySetDefinitionVersionsListNextResponse = + PolicySetDefinitionVersionListResult; + +/** Optional parameters. */ +export interface PolicySetDefinitionVersionsListBuiltInNextOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the listBuiltInNext operation. */ +export type PolicySetDefinitionVersionsListBuiltInNextResponse = + PolicySetDefinitionVersionListResult; + +/** Optional parameters. */ +export interface PolicySetDefinitionVersionsListByManagementGroupNextOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the listByManagementGroupNext operation. */ +export type PolicySetDefinitionVersionsListByManagementGroupNextResponse = + PolicySetDefinitionVersionListResult; + +/** Optional parameters. */ +export interface PolicyAssignmentsDeleteOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the delete operation. */ +export type PolicyAssignmentsDeleteResponse = PolicyAssignment; + +/** Optional parameters. */ +export interface PolicyAssignmentsCreateOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the create operation. */ +export type PolicyAssignmentsCreateResponse = PolicyAssignment; + +/** Optional parameters. */ +export interface PolicyAssignmentsGetOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the get operation. */ +export type PolicyAssignmentsGetResponse = PolicyAssignment; + +/** Optional parameters. */ +export interface PolicyAssignmentsUpdateOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the update operation. */ +export type PolicyAssignmentsUpdateResponse = PolicyAssignment; /** Optional parameters. */ -export interface PolicyExemptionsListForResourceGroupOptionalParams +export interface PolicyAssignmentsListForResourceGroupOptionalParams extends coreClient.OperationOptions { - /** The filter to apply on the operation. Valid values for $filter are: 'atScope()', 'atExactScope()', 'excludeExpired()' or 'policyAssignmentId eq '{value}''. If $filter is not provided, no filtering is performed. If $filter is not provided, the unfiltered list includes all policy exemptions associated with the scope, including those that apply directly or apply from containing scopes. If $filter=atScope() is provided, the returned list only includes all policy exemptions that apply to the scope, which is everything in the unfiltered list except those applied to sub scopes contained within the given scope. If $filter=atExactScope() is provided, the returned list only includes all policy exemptions that at the given scope. If $filter=excludeExpired() is provided, the returned list only includes all policy exemptions that either haven't expired or didn't set expiration date. If $filter=policyAssignmentId eq '{value}' is provided. the returned list only includes all policy exemptions that are associated with the give policyAssignmentId. */ + /** The filter to apply on the operation. Valid values for $filter are: 'atScope()', 'atExactScope()' or 'policyDefinitionId eq '{value}''. If $filter is not provided, no filtering is performed. If $filter=atScope() is provided, the returned list only includes all policy assignments that apply to the scope, which is everything in the unfiltered list except those applied to sub scopes contained within the given scope. If $filter=atExactScope() is provided, the returned list only includes all policy assignments that at the given scope. If $filter=policyDefinitionId eq '{value}' is provided, the returned list includes all policy assignments of the policy definition whose id is {value}. */ filter?: string; + /** Maximum number of records to return. When the $top filter is not provided, it will return 500 records. */ + top?: number; } /** Contains response data for the listForResourceGroup operation. */ -export type PolicyExemptionsListForResourceGroupResponse = PolicyExemptionListResult; +export type PolicyAssignmentsListForResourceGroupResponse = + PolicyAssignmentListResult; /** Optional parameters. */ -export interface PolicyExemptionsListForResourceOptionalParams +export interface PolicyAssignmentsListForResourceOptionalParams extends coreClient.OperationOptions { - /** The filter to apply on the operation. Valid values for $filter are: 'atScope()', 'atExactScope()', 'excludeExpired()' or 'policyAssignmentId eq '{value}''. If $filter is not provided, no filtering is performed. If $filter is not provided, the unfiltered list includes all policy exemptions associated with the scope, including those that apply directly or apply from containing scopes. If $filter=atScope() is provided, the returned list only includes all policy exemptions that apply to the scope, which is everything in the unfiltered list except those applied to sub scopes contained within the given scope. If $filter=atExactScope() is provided, the returned list only includes all policy exemptions that at the given scope. If $filter=excludeExpired() is provided, the returned list only includes all policy exemptions that either haven't expired or didn't set expiration date. If $filter=policyAssignmentId eq '{value}' is provided. the returned list only includes all policy exemptions that are associated with the give policyAssignmentId. */ + /** The filter to apply on the operation. Valid values for $filter are: 'atScope()', 'atExactScope()' or 'policyDefinitionId eq '{value}''. If $filter is not provided, no filtering is performed. If $filter=atScope() is provided, the returned list only includes all policy assignments that apply to the scope, which is everything in the unfiltered list except those applied to sub scopes contained within the given scope. If $filter=atExactScope() is provided, the returned list only includes all policy assignments that at the given scope. If $filter=policyDefinitionId eq '{value}' is provided, the returned list includes all policy assignments of the policy definition whose id is {value}. */ filter?: string; + /** Maximum number of records to return. When the $top filter is not provided, it will return 500 records. */ + top?: number; } /** Contains response data for the listForResource operation. */ -export type PolicyExemptionsListForResourceResponse = PolicyExemptionListResult; +export type PolicyAssignmentsListForResourceResponse = + PolicyAssignmentListResult; /** Optional parameters. */ -export interface PolicyExemptionsListForManagementGroupOptionalParams +export interface PolicyAssignmentsListForManagementGroupOptionalParams extends coreClient.OperationOptions { - /** The filter to apply on the operation. Valid values for $filter are: 'atScope()', 'atExactScope()', 'excludeExpired()' or 'policyAssignmentId eq '{value}''. If $filter is not provided, no filtering is performed. If $filter is not provided, the unfiltered list includes all policy exemptions associated with the scope, including those that apply directly or apply from containing scopes. If $filter=atScope() is provided, the returned list only includes all policy exemptions that apply to the scope, which is everything in the unfiltered list except those applied to sub scopes contained within the given scope. If $filter=atExactScope() is provided, the returned list only includes all policy exemptions that at the given scope. If $filter=excludeExpired() is provided, the returned list only includes all policy exemptions that either haven't expired or didn't set expiration date. If $filter=policyAssignmentId eq '{value}' is provided. the returned list only includes all policy exemptions that are associated with the give policyAssignmentId. */ + /** The filter to apply on the operation. Valid values for $filter are: 'atScope()', 'atExactScope()' or 'policyDefinitionId eq '{value}''. If $filter is not provided, no filtering is performed. If $filter=atScope() is provided, the returned list only includes all policy assignments that apply to the scope, which is everything in the unfiltered list except those applied to sub scopes contained within the given scope. If $filter=atExactScope() is provided, the returned list only includes all policy assignments that at the given scope. If $filter=policyDefinitionId eq '{value}' is provided, the returned list includes all policy assignments of the policy definition whose id is {value}. */ filter?: string; + /** Maximum number of records to return. When the $top filter is not provided, it will return 500 records. */ + top?: number; } /** Contains response data for the listForManagementGroup operation. */ -export type PolicyExemptionsListForManagementGroupResponse = PolicyExemptionListResult; +export type PolicyAssignmentsListForManagementGroupResponse = + PolicyAssignmentListResult; + +/** Optional parameters. */ +export interface PolicyAssignmentsListOptionalParams + extends coreClient.OperationOptions { + /** The filter to apply on the operation. Valid values for $filter are: 'atScope()', 'atExactScope()' or 'policyDefinitionId eq '{value}''. If $filter is not provided, no filtering is performed. If $filter=atScope() is provided, the returned list only includes all policy assignments that apply to the scope, which is everything in the unfiltered list except those applied to sub scopes contained within the given scope. If $filter=atExactScope() is provided, the returned list only includes all policy assignments that at the given scope. If $filter=policyDefinitionId eq '{value}' is provided, the returned list includes all policy assignments of the policy definition whose id is {value}. */ + filter?: string; + /** Maximum number of records to return. When the $top filter is not provided, it will return 500 records. */ + top?: number; +} + +/** Contains response data for the list operation. */ +export type PolicyAssignmentsListResponse = PolicyAssignmentListResult; /** Optional parameters. */ -export interface PolicyExemptionsListNextOptionalParams +export interface PolicyAssignmentsDeleteByIdOptionalParams extends coreClient.OperationOptions {} -/** Contains response data for the listNext operation. */ -export type PolicyExemptionsListNextResponse = PolicyExemptionListResult; +/** Contains response data for the deleteById operation. */ +export type PolicyAssignmentsDeleteByIdResponse = PolicyAssignment; + +/** Optional parameters. */ +export interface PolicyAssignmentsCreateByIdOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the createById operation. */ +export type PolicyAssignmentsCreateByIdResponse = PolicyAssignment; + +/** Optional parameters. */ +export interface PolicyAssignmentsGetByIdOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the getById operation. */ +export type PolicyAssignmentsGetByIdResponse = PolicyAssignment; + +/** Optional parameters. */ +export interface PolicyAssignmentsUpdateByIdOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the updateById operation. */ +export type PolicyAssignmentsUpdateByIdResponse = PolicyAssignment; /** Optional parameters. */ -export interface PolicyExemptionsListForResourceGroupNextOptionalParams +export interface PolicyAssignmentsListForResourceGroupNextOptionalParams extends coreClient.OperationOptions {} /** Contains response data for the listForResourceGroupNext operation. */ -export type PolicyExemptionsListForResourceGroupNextResponse = PolicyExemptionListResult; +export type PolicyAssignmentsListForResourceGroupNextResponse = + PolicyAssignmentListResult; /** Optional parameters. */ -export interface PolicyExemptionsListForResourceNextOptionalParams +export interface PolicyAssignmentsListForResourceNextOptionalParams extends coreClient.OperationOptions {} /** Contains response data for the listForResourceNext operation. */ -export type PolicyExemptionsListForResourceNextResponse = PolicyExemptionListResult; +export type PolicyAssignmentsListForResourceNextResponse = + PolicyAssignmentListResult; /** Optional parameters. */ -export interface PolicyExemptionsListForManagementGroupNextOptionalParams +export interface PolicyAssignmentsListForManagementGroupNextOptionalParams extends coreClient.OperationOptions {} /** Contains response data for the listForManagementGroupNext operation. */ -export type PolicyExemptionsListForManagementGroupNextResponse = PolicyExemptionListResult; +export type PolicyAssignmentsListForManagementGroupNextResponse = + PolicyAssignmentListResult; + +/** Optional parameters. */ +export interface PolicyAssignmentsListNextOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the listNext operation. */ +export type PolicyAssignmentsListNextResponse = PolicyAssignmentListResult; /** Optional parameters. */ export interface PolicyClientOptionalParams extends coreClient.ServiceClientOptions { /** server parameter */ $host?: string; + /** Api Version */ + apiVersion?: string; /** Overrides client endpoint. */ endpoint?: string; } diff --git a/sdk/policy/arm-policy/src/models/mappers.ts b/sdk/policy/arm-policy/src/models/mappers.ts index 118f4863c37e..5be672ba5d27 100644 --- a/sdk/policy/arm-policy/src/models/mappers.ts +++ b/sdk/policy/arm-policy/src/models/mappers.ts @@ -8,346 +8,228 @@ import * as coreClient from "@azure/core-client"; -export const DataPolicyManifest: coreClient.CompositeMapper = { +export const PolicyDefinition: coreClient.CompositeMapper = { type: { name: "Composite", - className: "DataPolicyManifest", + className: "PolicyDefinition", modelProperties: { id: { serializedName: "id", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, name: { serializedName: "name", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, type: { serializedName: "type", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, - namespaces: { - serializedName: "properties.namespaces", + systemData: { + serializedName: "systemData", type: { - name: "Sequence", - element: { - type: { - name: "String" - } - } - } + name: "Composite", + className: "SystemData", + }, }, - policyMode: { - serializedName: "properties.policyMode", + policyType: { + serializedName: "properties.policyType", type: { - name: "String" - } + name: "String", + }, }, - isBuiltInOnly: { - serializedName: "properties.isBuiltInOnly", + mode: { + defaultValue: "Indexed", + serializedName: "properties.mode", type: { - name: "Boolean" - } + name: "String", + }, }, - resourceTypeAliases: { - serializedName: "properties.resourceTypeAliases", + displayName: { + serializedName: "properties.displayName", type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "ResourceTypeAliases" - } - } - } + name: "String", + }, }, - effects: { - serializedName: "properties.effects", + description: { + serializedName: "properties.description", type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "DataEffect" - } - } - } + name: "String", + }, }, - fieldValues: { - serializedName: "properties.fieldValues", + policyRule: { + serializedName: "properties.policyRule", type: { - name: "Sequence", - element: { - type: { - name: "String" - } - } - } + name: "any", + }, }, - standard: { - serializedName: "properties.resourceFunctions.standard", + metadata: { + serializedName: "properties.metadata", type: { - name: "Sequence", - element: { - type: { - name: "String" - } - } - } + name: "any", + }, }, - custom: { - serializedName: "properties.resourceFunctions.custom", + parameters: { + serializedName: "properties.parameters", type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "DataManifestCustomResourceFunctionDefinition" - } - } - } - } - } - } -}; - -export const ResourceTypeAliases: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ResourceTypeAliases", - modelProperties: { - resourceType: { - serializedName: "resourceType", + name: "Dictionary", + value: { + type: { name: "Composite", className: "ParameterDefinitionsValue" }, + }, + }, + }, + version: { + serializedName: "properties.version", type: { - name: "String" - } + name: "String", + }, }, - aliases: { - serializedName: "aliases", + versions: { + serializedName: "properties.versions", type: { name: "Sequence", element: { type: { - name: "Composite", - className: "Alias" - } - } - } - } - } - } + name: "String", + }, + }, + }, + }, + }, + }, }; -export const Alias: coreClient.CompositeMapper = { +export const ParameterDefinitionsValue: coreClient.CompositeMapper = { type: { name: "Composite", - className: "Alias", + className: "ParameterDefinitionsValue", modelProperties: { - name: { - serializedName: "name", + type: { + serializedName: "type", type: { - name: "String" - } + name: "String", + }, }, - paths: { - serializedName: "paths", + allowedValues: { + serializedName: "allowedValues", type: { name: "Sequence", element: { type: { - name: "Composite", - className: "AliasPath" - } - } - } + name: "any", + }, + }, + }, }, - type: { - serializedName: "type", + defaultValue: { + serializedName: "defaultValue", type: { - name: "Enum", - allowedValues: ["NotSpecified", "PlainText", "Mask"] - } + name: "any", + }, }, - defaultPath: { - serializedName: "defaultPath", + schema: { + serializedName: "schema", type: { - name: "String" - } + name: "any", + }, }, - defaultPattern: { - serializedName: "defaultPattern", + metadata: { + serializedName: "metadata", type: { name: "Composite", - className: "AliasPattern" - } + className: "ParameterDefinitionsValueMetadata", + }, }, - defaultMetadata: { - serializedName: "defaultMetadata", - type: { - name: "Composite", - className: "AliasPathMetadata" - } - } - } - } + }, + }, }; -export const AliasPath: coreClient.CompositeMapper = { +export const ParameterDefinitionsValueMetadata: coreClient.CompositeMapper = { type: { name: "Composite", - className: "AliasPath", + className: "ParameterDefinitionsValueMetadata", + additionalProperties: { type: { name: "Object" } }, modelProperties: { - path: { - serializedName: "path", + displayName: { + serializedName: "displayName", type: { - name: "String" - } + name: "String", + }, }, - apiVersions: { - serializedName: "apiVersions", + description: { + serializedName: "description", type: { - name: "Sequence", - element: { - type: { - name: "String" - } - } - } + name: "String", + }, }, - pattern: { - serializedName: "pattern", + strongType: { + serializedName: "strongType", type: { - name: "Composite", - className: "AliasPattern" - } + name: "String", + }, }, - metadata: { - serializedName: "metadata", + assignPermissions: { + serializedName: "assignPermissions", type: { - name: "Composite", - className: "AliasPathMetadata" - } - } - } - } + name: "Boolean", + }, + }, + }, + }, }; -export const AliasPattern: coreClient.CompositeMapper = { +export const SystemData: coreClient.CompositeMapper = { type: { name: "Composite", - className: "AliasPattern", + className: "SystemData", modelProperties: { - phrase: { - serializedName: "phrase", + createdBy: { + serializedName: "createdBy", type: { - name: "String" - } + name: "String", + }, }, - variable: { - serializedName: "variable", + createdByType: { + serializedName: "createdByType", type: { - name: "String" - } + name: "String", + }, }, - type: { - serializedName: "type", - type: { - name: "Enum", - allowedValues: ["NotSpecified", "Extract"] - } - } - } - } -}; - -export const AliasPathMetadata: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "AliasPathMetadata", - modelProperties: { - type: { - serializedName: "type", - readOnly: true, + createdAt: { + serializedName: "createdAt", type: { - name: "String" - } + name: "DateTime", + }, }, - attributes: { - serializedName: "attributes", - readOnly: true, - type: { - name: "String" - } - } - } - } -}; - -export const DataEffect: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "DataEffect", - modelProperties: { - name: { - serializedName: "name", + lastModifiedBy: { + serializedName: "lastModifiedBy", type: { - name: "String" - } + name: "String", + }, }, - detailsSchema: { - serializedName: "detailsSchema", - type: { - name: "any" - } - } - } - } -}; - -export const DataManifestCustomResourceFunctionDefinition: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "DataManifestCustomResourceFunctionDefinition", - modelProperties: { - name: { - serializedName: "name", + lastModifiedByType: { + serializedName: "lastModifiedByType", type: { - name: "String" - } + name: "String", + }, }, - fullyQualifiedResourceType: { - serializedName: "fullyQualifiedResourceType", + lastModifiedAt: { + serializedName: "lastModifiedAt", type: { - name: "String" - } + name: "DateTime", + }, }, - defaultProperties: { - serializedName: "defaultProperties", - type: { - name: "Sequence", - element: { - type: { - name: "String" - } - } - } - }, - allowCustomProperties: { - serializedName: "allowCustomProperties", - type: { - name: "Boolean" - } - } - } - } + }, + }, }; export const CloudError: coreClient.CompositeMapper = { @@ -359,11 +241,11 @@ export const CloudError: coreClient.CompositeMapper = { serializedName: "error", type: { name: "Composite", - className: "ErrorResponse" - } - } - } - } + className: "ErrorResponse", + }, + }, + }, + }, }; export const ErrorResponse: coreClient.CompositeMapper = { @@ -375,22 +257,22 @@ export const ErrorResponse: coreClient.CompositeMapper = { serializedName: "code", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, message: { serializedName: "message", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, target: { serializedName: "target", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, details: { serializedName: "details", @@ -400,10 +282,10 @@ export const ErrorResponse: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "ErrorResponse" - } - } - } + className: "ErrorResponse", + }, + }, + }, }, additionalInfo: { serializedName: "additionalInfo", @@ -413,13 +295,13 @@ export const ErrorResponse: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "ErrorAdditionalInfo" - } - } - } - } - } - } + className: "ErrorAdditionalInfo", + }, + }, + }, + }, + }, + }, }; export const ErrorAdditionalInfo: coreClient.CompositeMapper = { @@ -431,24 +313,24 @@ export const ErrorAdditionalInfo: coreClient.CompositeMapper = { serializedName: "type", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, info: { serializedName: "info", readOnly: true, type: { - name: "any" - } - } - } - } + name: "any", + }, + }, + }, + }, }; -export const DataPolicyManifestListResult: coreClient.CompositeMapper = { +export const PolicyDefinitionListResult: coreClient.CompositeMapper = { type: { name: "Composite", - className: "DataPolicyManifestListResult", + className: "PolicyDefinitionListResult", modelProperties: { value: { serializedName: "value", @@ -457,314 +339,355 @@ export const DataPolicyManifestListResult: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "DataPolicyManifest" - } - } - } + className: "PolicyDefinition", + }, + }, + }, }, nextLink: { serializedName: "nextLink", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; -export const PolicyAssignment: coreClient.CompositeMapper = { +export const PolicyDefinitionVersionListResult: coreClient.CompositeMapper = { type: { name: "Composite", - className: "PolicyAssignment", + className: "PolicyDefinitionVersionListResult", modelProperties: { - id: { - serializedName: "id", - readOnly: true, + value: { + serializedName: "value", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "PolicyDefinitionVersion", + }, + }, + }, + }, + nextLink: { + serializedName: "nextLink", type: { - name: "String" - } + name: "String", + }, }, - type: { - serializedName: "type", + }, + }, +}; + +export const PolicyDefinitionVersion: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "PolicyDefinitionVersion", + modelProperties: { + id: { + serializedName: "id", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, name: { serializedName: "name", readOnly: true, type: { - name: "String" - } - }, - location: { - serializedName: "location", - type: { - name: "String" - } + name: "String", + }, }, - identity: { - serializedName: "identity", + type: { + serializedName: "type", + readOnly: true, type: { - name: "Composite", - className: "Identity" - } + name: "String", + }, }, systemData: { serializedName: "systemData", type: { name: "Composite", - className: "SystemData" - } - }, - displayName: { - serializedName: "properties.displayName", - type: { - name: "String" - } - }, - policyDefinitionId: { - serializedName: "properties.policyDefinitionId", - type: { - name: "String" - } + className: "SystemData", + }, }, - scope: { - serializedName: "properties.scope", - readOnly: true, + policyType: { + serializedName: "properties.policyType", type: { - name: "String" - } + name: "String", + }, }, - notScopes: { - serializedName: "properties.notScopes", + mode: { + defaultValue: "Indexed", + serializedName: "properties.mode", type: { - name: "Sequence", - element: { - type: { - name: "String" - } - } - } + name: "String", + }, }, - parameters: { - serializedName: "properties.parameters", + displayName: { + serializedName: "properties.displayName", type: { - name: "Dictionary", - value: { - type: { name: "Composite", className: "ParameterValuesValue" } - } - } + name: "String", + }, }, description: { serializedName: "properties.description", type: { - name: "String" - } + name: "String", + }, + }, + policyRule: { + serializedName: "properties.policyRule", + type: { + name: "any", + }, }, metadata: { serializedName: "properties.metadata", type: { - name: "any" - } + name: "any", + }, }, - enforcementMode: { - defaultValue: "Default", - serializedName: "properties.enforcementMode", + parameters: { + serializedName: "properties.parameters", type: { - name: "String" - } + name: "Dictionary", + value: { + type: { name: "Composite", className: "ParameterDefinitionsValue" }, + }, + }, }, - nonComplianceMessages: { - serializedName: "properties.nonComplianceMessages", - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "NonComplianceMessage" - } - } - } - } - } - } -}; - -export const ParameterValuesValue: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ParameterValuesValue", - modelProperties: { - value: { - serializedName: "value", - type: { - name: "any" - } - } - } - } -}; - -export const NonComplianceMessage: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "NonComplianceMessage", - modelProperties: { - message: { - serializedName: "message", - required: true, + version: { + serializedName: "properties.version", type: { - name: "String" - } + name: "String", + }, }, - policyDefinitionReferenceId: { - serializedName: "policyDefinitionReferenceId", - type: { - name: "String" - } - } - } - } + }, + }, }; -export const Identity: coreClient.CompositeMapper = { +export const PolicySetDefinition: coreClient.CompositeMapper = { type: { name: "Composite", - className: "Identity", + className: "PolicySetDefinition", modelProperties: { - principalId: { - serializedName: "principalId", + id: { + serializedName: "id", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, - tenantId: { - serializedName: "tenantId", + name: { + serializedName: "name", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, type: { serializedName: "type", + readOnly: true, type: { - name: "Enum", - allowedValues: ["SystemAssigned", "UserAssigned", "None"] - } + name: "String", + }, }, - userAssignedIdentities: { - serializedName: "userAssignedIdentities", + systemData: { + serializedName: "systemData", + type: { + name: "Composite", + className: "SystemData", + }, + }, + policyType: { + serializedName: "properties.policyType", + type: { + name: "String", + }, + }, + displayName: { + serializedName: "properties.displayName", + type: { + name: "String", + }, + }, + description: { + serializedName: "properties.description", + type: { + name: "String", + }, + }, + metadata: { + serializedName: "properties.metadata", + type: { + name: "any", + }, + }, + parameters: { + serializedName: "properties.parameters", type: { name: "Dictionary", value: { + type: { name: "Composite", className: "ParameterDefinitionsValue" }, + }, + }, + }, + policyDefinitions: { + serializedName: "properties.policyDefinitions", + type: { + name: "Sequence", + element: { type: { name: "Composite", - className: "UserAssignedIdentitiesValue" - } - } - } - } - } - } -}; - -export const UserAssignedIdentitiesValue: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "UserAssignedIdentitiesValue", - modelProperties: { - principalId: { - serializedName: "principalId", - readOnly: true, + className: "PolicyDefinitionReference", + }, + }, + }, + }, + policyDefinitionGroups: { + serializedName: "properties.policyDefinitionGroups", type: { - name: "String" - } + name: "Sequence", + element: { + type: { + name: "Composite", + className: "PolicyDefinitionGroup", + }, + }, + }, }, - clientId: { - serializedName: "clientId", - readOnly: true, + version: { + serializedName: "properties.version", + type: { + name: "String", + }, + }, + versions: { + serializedName: "properties.versions", type: { - name: "String" - } - } - } - } + name: "Sequence", + element: { + type: { + name: "String", + }, + }, + }, + }, + }, + }, }; -export const SystemData: coreClient.CompositeMapper = { +export const PolicyDefinitionReference: coreClient.CompositeMapper = { type: { name: "Composite", - className: "SystemData", + className: "PolicyDefinitionReference", modelProperties: { - createdBy: { - serializedName: "createdBy", + policyDefinitionId: { + serializedName: "policyDefinitionId", + required: true, type: { - name: "String" - } + name: "String", + }, }, - createdByType: { - serializedName: "createdByType", + definitionVersion: { + serializedName: "definitionVersion", type: { - name: "String" - } + name: "String", + }, }, - createdAt: { - serializedName: "createdAt", + parameters: { + serializedName: "parameters", type: { - name: "DateTime" - } + name: "Dictionary", + value: { + type: { name: "Composite", className: "ParameterValuesValue" }, + }, + }, }, - lastModifiedBy: { - serializedName: "lastModifiedBy", + policyDefinitionReferenceId: { + serializedName: "policyDefinitionReferenceId", type: { - name: "String" - } + name: "String", + }, }, - lastModifiedByType: { - serializedName: "lastModifiedByType", + groupNames: { + serializedName: "groupNames", type: { - name: "String" - } + name: "Sequence", + element: { + type: { + name: "String", + }, + }, + }, }, - lastModifiedAt: { - serializedName: "lastModifiedAt", + }, + }, +}; + +export const ParameterValuesValue: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "ParameterValuesValue", + modelProperties: { + value: { + serializedName: "value", type: { - name: "DateTime" - } - } - } - } + name: "any", + }, + }, + }, + }, }; -export const PolicyAssignmentUpdate: coreClient.CompositeMapper = { +export const PolicyDefinitionGroup: coreClient.CompositeMapper = { type: { name: "Composite", - className: "PolicyAssignmentUpdate", + className: "PolicyDefinitionGroup", modelProperties: { - location: { - serializedName: "location", + name: { + serializedName: "name", + required: true, type: { - name: "String" - } + name: "String", + }, }, - identity: { - serializedName: "identity", + displayName: { + serializedName: "displayName", type: { - name: "Composite", - className: "Identity" - } - } - } - } + name: "String", + }, + }, + category: { + serializedName: "category", + type: { + name: "String", + }, + }, + description: { + serializedName: "description", + type: { + name: "String", + }, + }, + additionalMetadataId: { + serializedName: "additionalMetadataId", + type: { + name: "String", + }, + }, + }, + }, }; -export const PolicyAssignmentListResult: coreClient.CompositeMapper = { +export const PolicySetDefinitionListResult: coreClient.CompositeMapper = { type: { name: "Composite", - className: "PolicyAssignmentListResult", + className: "PolicySetDefinitionListResult", modelProperties: { value: { serializedName: "value", @@ -773,497 +696,539 @@ export const PolicyAssignmentListResult: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "PolicyAssignment" - } - } - } + className: "PolicySetDefinition", + }, + }, + }, }, nextLink: { serializedName: "nextLink", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; -export const PolicyDefinition: coreClient.CompositeMapper = { +export const PolicySetDefinitionVersionListResult: coreClient.CompositeMapper = + { + type: { + name: "Composite", + className: "PolicySetDefinitionVersionListResult", + modelProperties: { + value: { + serializedName: "value", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "PolicySetDefinitionVersion", + }, + }, + }, + }, + nextLink: { + serializedName: "nextLink", + type: { + name: "String", + }, + }, + }, + }, + }; + +export const PolicySetDefinitionVersion: coreClient.CompositeMapper = { type: { name: "Composite", - className: "PolicyDefinition", + className: "PolicySetDefinitionVersion", modelProperties: { id: { serializedName: "id", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, name: { serializedName: "name", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, type: { serializedName: "type", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, systemData: { serializedName: "systemData", type: { name: "Composite", - className: "SystemData" - } + className: "SystemData", + }, }, policyType: { serializedName: "properties.policyType", type: { - name: "String" - } - }, - mode: { - defaultValue: "Indexed", - serializedName: "properties.mode", - type: { - name: "String" - } + name: "String", + }, }, displayName: { serializedName: "properties.displayName", type: { - name: "String" - } + name: "String", + }, }, description: { serializedName: "properties.description", type: { - name: "String" - } - }, - policyRule: { - serializedName: "properties.policyRule", - type: { - name: "any" - } + name: "String", + }, }, metadata: { serializedName: "properties.metadata", type: { - name: "any" - } + name: "any", + }, }, parameters: { serializedName: "properties.parameters", type: { name: "Dictionary", value: { - type: { name: "Composite", className: "ParameterDefinitionsValue" } - } - } - } - } - } -}; - -export const ParameterDefinitionsValue: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ParameterDefinitionsValue", - modelProperties: { - type: { - serializedName: "type", - type: { - name: "String" - } + type: { name: "Composite", className: "ParameterDefinitionsValue" }, + }, + }, }, - allowedValues: { - serializedName: "allowedValues", + policyDefinitions: { + serializedName: "properties.policyDefinitions", type: { name: "Sequence", element: { type: { - name: "any" - } - } - } - }, - defaultValue: { - serializedName: "defaultValue", - type: { - name: "any" - } - }, - metadata: { - serializedName: "metadata", - type: { - name: "Composite", - className: "ParameterDefinitionsValueMetadata" - } - } - } - } -}; - -export const ParameterDefinitionsValueMetadata: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ParameterDefinitionsValueMetadata", - additionalProperties: { type: { name: "Object" } }, - modelProperties: { - displayName: { - serializedName: "displayName", - type: { - name: "String" - } - }, - description: { - serializedName: "description", - type: { - name: "String" - } - }, - strongType: { - serializedName: "strongType", - type: { - name: "String" - } + name: "Composite", + className: "PolicyDefinitionReference", + }, + }, + }, }, - assignPermissions: { - serializedName: "assignPermissions", - type: { - name: "Boolean" - } - } - } - } -}; - -export const PolicyDefinitionListResult: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "PolicyDefinitionListResult", - modelProperties: { - value: { - serializedName: "value", + policyDefinitionGroups: { + serializedName: "properties.policyDefinitionGroups", type: { name: "Sequence", element: { type: { name: "Composite", - className: "PolicyDefinition" - } - } - } + className: "PolicyDefinitionGroup", + }, + }, + }, }, - nextLink: { - serializedName: "nextLink", + version: { + serializedName: "properties.version", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; -export const PolicySetDefinition: coreClient.CompositeMapper = { +export const PolicyAssignment: coreClient.CompositeMapper = { type: { name: "Composite", - className: "PolicySetDefinition", + className: "PolicyAssignment", modelProperties: { id: { serializedName: "id", readOnly: true, type: { - name: "String" - } + name: "String", + }, + }, + type: { + serializedName: "type", + readOnly: true, + type: { + name: "String", + }, }, name: { serializedName: "name", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, - type: { - serializedName: "type", - readOnly: true, + location: { + serializedName: "location", type: { - name: "String" - } + name: "String", + }, }, - systemData: { - serializedName: "systemData", + identity: { + serializedName: "identity", type: { name: "Composite", - className: "SystemData" - } + className: "Identity", + }, }, - policyType: { - serializedName: "properties.policyType", + systemData: { + serializedName: "systemData", type: { - name: "String" - } + name: "Composite", + className: "SystemData", + }, }, displayName: { serializedName: "properties.displayName", type: { - name: "String" - } + name: "String", + }, }, - description: { - serializedName: "properties.description", + policyDefinitionId: { + serializedName: "properties.policyDefinitionId", type: { - name: "String" - } + name: "String", + }, }, - metadata: { - serializedName: "properties.metadata", + definitionVersion: { + serializedName: "properties.definitionVersion", type: { - name: "any" - } + name: "String", + }, + }, + scope: { + serializedName: "properties.scope", + readOnly: true, + type: { + name: "String", + }, + }, + notScopes: { + serializedName: "properties.notScopes", + type: { + name: "Sequence", + element: { + type: { + name: "String", + }, + }, + }, }, parameters: { serializedName: "properties.parameters", type: { name: "Dictionary", value: { - type: { name: "Composite", className: "ParameterDefinitionsValue" } - } - } + type: { name: "Composite", className: "ParameterValuesValue" }, + }, + }, }, - policyDefinitions: { - serializedName: "properties.policyDefinitions", + description: { + serializedName: "properties.description", + type: { + name: "String", + }, + }, + metadata: { + serializedName: "properties.metadata", + type: { + name: "any", + }, + }, + enforcementMode: { + defaultValue: "Default", + serializedName: "properties.enforcementMode", + type: { + name: "String", + }, + }, + nonComplianceMessages: { + serializedName: "properties.nonComplianceMessages", type: { name: "Sequence", element: { type: { name: "Composite", - className: "PolicyDefinitionReference" - } - } - } + className: "NonComplianceMessage", + }, + }, + }, }, - policyDefinitionGroups: { - serializedName: "properties.policyDefinitionGroups", + resourceSelectors: { + serializedName: "properties.resourceSelectors", type: { name: "Sequence", element: { type: { name: "Composite", - className: "PolicyDefinitionGroup" - } - } - } - } - } - } + className: "ResourceSelector", + }, + }, + }, + }, + overrides: { + serializedName: "properties.overrides", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "Override", + }, + }, + }, + }, + assignmentType: { + serializedName: "properties.assignmentType", + type: { + name: "String", + }, + }, + }, + }, }; -export const PolicyDefinitionReference: coreClient.CompositeMapper = { +export const NonComplianceMessage: coreClient.CompositeMapper = { type: { name: "Composite", - className: "PolicyDefinitionReference", + className: "NonComplianceMessage", modelProperties: { - policyDefinitionId: { - serializedName: "policyDefinitionId", + message: { + serializedName: "message", required: true, type: { - name: "String" - } - }, - parameters: { - serializedName: "parameters", - type: { - name: "Dictionary", - value: { - type: { name: "Composite", className: "ParameterValuesValue" } - } - } + name: "String", + }, }, policyDefinitionReferenceId: { serializedName: "policyDefinitionReferenceId", type: { - name: "String" - } + name: "String", + }, }, - groupNames: { - serializedName: "groupNames", - type: { - name: "Sequence", - element: { - type: { - name: "String" - } - } - } - } - } - } + }, + }, }; -export const PolicyDefinitionGroup: coreClient.CompositeMapper = { +export const ResourceSelector: coreClient.CompositeMapper = { type: { name: "Composite", - className: "PolicyDefinitionGroup", + className: "ResourceSelector", modelProperties: { name: { serializedName: "name", - required: true, type: { - name: "String" - } + name: "String", + }, }, - displayName: { - serializedName: "displayName", + selectors: { + serializedName: "selectors", type: { - name: "String" - } + name: "Sequence", + element: { + type: { + name: "Composite", + className: "Selector", + }, + }, + }, }, - category: { - serializedName: "category", + }, + }, +}; + +export const Selector: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "Selector", + modelProperties: { + kind: { + serializedName: "kind", type: { - name: "String" - } + name: "String", + }, }, - description: { - serializedName: "description", + in: { + serializedName: "in", type: { - name: "String" - } + name: "Sequence", + element: { + type: { + name: "String", + }, + }, + }, }, - additionalMetadataId: { - serializedName: "additionalMetadataId", + notIn: { + serializedName: "notIn", type: { - name: "String" - } - } - } - } + name: "Sequence", + element: { + type: { + name: "String", + }, + }, + }, + }, + }, + }, }; -export const PolicySetDefinitionListResult: coreClient.CompositeMapper = { +export const Override: coreClient.CompositeMapper = { type: { name: "Composite", - className: "PolicySetDefinitionListResult", + className: "Override", modelProperties: { + kind: { + serializedName: "kind", + type: { + name: "String", + }, + }, value: { serializedName: "value", + type: { + name: "String", + }, + }, + selectors: { + serializedName: "selectors", type: { name: "Sequence", element: { type: { name: "Composite", - className: "PolicySetDefinition" - } - } - } + className: "Selector", + }, + }, + }, }, - nextLink: { - serializedName: "nextLink", - type: { - name: "String" - } - } - } - } + }, + }, }; -export const PolicyExemption: coreClient.CompositeMapper = { +export const Identity: coreClient.CompositeMapper = { type: { name: "Composite", - className: "PolicyExemption", + className: "Identity", modelProperties: { - systemData: { - serializedName: "systemData", - type: { - name: "Composite", - className: "SystemData" - } - }, - id: { - serializedName: "id", + principalId: { + serializedName: "principalId", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, - name: { - serializedName: "name", + tenantId: { + serializedName: "tenantId", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, type: { serializedName: "type", - readOnly: true, type: { - name: "String" - } + name: "Enum", + allowedValues: ["SystemAssigned", "UserAssigned", "None"], + }, }, - policyAssignmentId: { - serializedName: "properties.policyAssignmentId", - required: true, + userAssignedIdentities: { + serializedName: "userAssignedIdentities", type: { - name: "String" - } + name: "Dictionary", + value: { + type: { + name: "Composite", + className: "UserAssignedIdentitiesValue", + }, + }, + }, }, - policyDefinitionReferenceIds: { - serializedName: "properties.policyDefinitionReferenceIds", + }, + }, +}; + +export const UserAssignedIdentitiesValue: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "UserAssignedIdentitiesValue", + modelProperties: { + principalId: { + serializedName: "principalId", + readOnly: true, type: { - name: "Sequence", - element: { - type: { - name: "String" - } - } - } + name: "String", + }, }, - exemptionCategory: { - serializedName: "properties.exemptionCategory", - required: true, + clientId: { + serializedName: "clientId", + readOnly: true, type: { - name: "String" - } + name: "String", + }, }, - expiresOn: { - serializedName: "properties.expiresOn", + }, + }, +}; + +export const PolicyAssignmentUpdate: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "PolicyAssignmentUpdate", + modelProperties: { + location: { + serializedName: "location", type: { - name: "DateTime" - } + name: "String", + }, }, - displayName: { - serializedName: "properties.displayName", + identity: { + serializedName: "identity", type: { - name: "String" - } + name: "Composite", + className: "Identity", + }, }, - description: { - serializedName: "properties.description", + resourceSelectors: { + serializedName: "properties.resourceSelectors", type: { - name: "String" - } + name: "Sequence", + element: { + type: { + name: "Composite", + className: "ResourceSelector", + }, + }, + }, }, - metadata: { - serializedName: "properties.metadata", + overrides: { + serializedName: "properties.overrides", type: { - name: "any" - } - } - } - } + name: "Sequence", + element: { + type: { + name: "Composite", + className: "Override", + }, + }, + }, + }, + }, + }, }; -export const PolicyExemptionListResult: coreClient.CompositeMapper = { +export const PolicyAssignmentListResult: coreClient.CompositeMapper = { type: { name: "Composite", - className: "PolicyExemptionListResult", + className: "PolicyAssignmentListResult", modelProperties: { value: { serializedName: "value", @@ -1272,18 +1237,17 @@ export const PolicyExemptionListResult: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "PolicyExemption" - } - } - } + className: "PolicyAssignment", + }, + }, + }, }, nextLink: { serializedName: "nextLink", - readOnly: true, type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; diff --git a/sdk/policy/arm-policy/src/models/parameters.ts b/sdk/policy/arm-policy/src/models/parameters.ts index 89eaa4fbd9a6..564a12b730ca 100644 --- a/sdk/policy/arm-policy/src/models/parameters.ts +++ b/sdk/policy/arm-policy/src/models/parameters.ts @@ -9,16 +9,34 @@ import { OperationParameter, OperationURLParameter, - OperationQueryParameter + OperationQueryParameter, } from "@azure/core-client"; import { - PolicyAssignment as PolicyAssignmentMapper, - PolicyAssignmentUpdate as PolicyAssignmentUpdateMapper, PolicyDefinition as PolicyDefinitionMapper, + PolicyDefinitionVersion as PolicyDefinitionVersionMapper, PolicySetDefinition as PolicySetDefinitionMapper, - PolicyExemption as PolicyExemptionMapper + PolicySetDefinitionVersion as PolicySetDefinitionVersionMapper, + PolicyAssignment as PolicyAssignmentMapper, + PolicyAssignmentUpdate as PolicyAssignmentUpdateMapper, } from "../models/mappers"; +export const contentType: OperationParameter = { + parameterPath: ["options", "contentType"], + mapper: { + defaultValue: "application/json", + isConstant: true, + serializedName: "Content-Type", + type: { + name: "String", + }, + }, +}; + +export const parameters: OperationParameter = { + parameterPath: "parameters", + mapper: PolicyDefinitionMapper, +}; + export const accept: OperationParameter = { parameterPath: "accept", mapper: { @@ -26,9 +44,9 @@ export const accept: OperationParameter = { isConstant: true, serializedName: "Accept", type: { - name: "String" - } - } + name: "String", + }, + }, }; export const $host: OperationURLParameter = { @@ -37,33 +55,58 @@ export const $host: OperationURLParameter = { serializedName: "$host", required: true, type: { - name: "String" - } + name: "String", + }, }, - skipEncoding: true + skipEncoding: true, }; -export const policyMode: OperationURLParameter = { - parameterPath: "policyMode", +export const subscriptionId: OperationURLParameter = { + parameterPath: "subscriptionId", mapper: { - serializedName: "policyMode", + serializedName: "subscriptionId", required: true, type: { - name: "String" - } - } + name: "Uuid", + }, + }, +}; + +export const policyDefinitionName: OperationURLParameter = { + parameterPath: "policyDefinitionName", + mapper: { + constraints: { + Pattern: new RegExp("^[^<>*%&:\\?.+/]*[^<>*%&:\\?.+/ ]+$"), + }, + serializedName: "policyDefinitionName", + required: true, + type: { + name: "String", + }, + }, }; export const apiVersion: OperationQueryParameter = { parameterPath: "apiVersion", mapper: { - defaultValue: "2020-09-01", + defaultValue: "2024-05-01", isConstant: true, serializedName: "api-version", type: { - name: "String" - } - } + name: "String", + }, + }, +}; + +export const managementGroupId: OperationURLParameter = { + parameterPath: "managementGroupId", + mapper: { + serializedName: "managementGroupId", + required: true, + type: { + name: "String", + }, + }, }; export const filter: OperationQueryParameter = { @@ -71,10 +114,24 @@ export const filter: OperationQueryParameter = { mapper: { serializedName: "$filter", type: { - name: "String" - } + name: "String", + }, + }, + skipEncoding: true, +}; + +export const top: OperationQueryParameter = { + parameterPath: ["options", "top"], + mapper: { + constraints: { + InclusiveMaximum: 1000, + InclusiveMinimum: 1, + }, + serializedName: "$top", + type: { + name: "Number", + }, }, - skipEncoding: true }; export const nextLink: OperationURLParameter = { @@ -83,67 +140,104 @@ export const nextLink: OperationURLParameter = { serializedName: "nextLink", required: true, type: { - name: "String" - } + name: "String", + }, }, - skipEncoding: true + skipEncoding: true, }; -export const scope: OperationURLParameter = { - parameterPath: "scope", +export const managementGroupName: OperationURLParameter = { + parameterPath: "managementGroupName", mapper: { - serializedName: "scope", + constraints: { + MaxLength: 90, + MinLength: 1, + }, + serializedName: "managementGroupName", required: true, type: { - name: "String" - } + name: "String", + }, }, - skipEncoding: true }; -export const policyAssignmentName: OperationURLParameter = { - parameterPath: "policyAssignmentName", +export const parameters1: OperationParameter = { + parameterPath: "parameters", + mapper: PolicyDefinitionVersionMapper, +}; + +export const policyDefinitionVersion: OperationURLParameter = { + parameterPath: "policyDefinitionVersion", mapper: { - serializedName: "policyAssignmentName", + constraints: { + Pattern: new RegExp("^\\d+\\.\\d+\\.\\d+$"), + }, + serializedName: "policyDefinitionVersion", required: true, type: { - name: "String" - } - } + name: "String", + }, + }, }; -export const apiVersion1: OperationQueryParameter = { - parameterPath: "apiVersion", +export const parameters2: OperationParameter = { + parameterPath: "parameters", + mapper: PolicySetDefinitionMapper, +}; + +export const policySetDefinitionName: OperationURLParameter = { + parameterPath: "policySetDefinitionName", mapper: { - defaultValue: "2021-06-01", - isConstant: true, - serializedName: "api-version", + constraints: { + Pattern: new RegExp("^[^<>*%&:\\?.+/]*[^<>*%&:\\?.+/ ]+$"), + }, + serializedName: "policySetDefinitionName", + required: true, type: { - name: "String" - } - } + name: "String", + }, + }, }; -export const contentType: OperationParameter = { - parameterPath: ["options", "contentType"], +export const parameters3: OperationParameter = { + parameterPath: "parameters", + mapper: PolicySetDefinitionVersionMapper, +}; + +export const scope: OperationURLParameter = { + parameterPath: "scope", mapper: { - defaultValue: "application/json", - isConstant: true, - serializedName: "Content-Type", + serializedName: "scope", + required: true, type: { - name: "String" - } - } + name: "String", + }, + }, + skipEncoding: true, }; -export const parameters: OperationParameter = { +export const policyAssignmentName: OperationURLParameter = { + parameterPath: "policyAssignmentName", + mapper: { + constraints: { + Pattern: new RegExp("^[^<>*%&:\\?.+/]*[^<>*%&:\\?.+/ ]+$"), + }, + serializedName: "policyAssignmentName", + required: true, + type: { + name: "String", + }, + }, +}; + +export const parameters4: OperationParameter = { parameterPath: "parameters", - mapper: PolicyAssignmentMapper + mapper: PolicyAssignmentMapper, }; -export const parameters1: OperationParameter = { +export const parameters5: OperationParameter = { parameterPath: "parameters", - mapper: PolicyAssignmentUpdateMapper + mapper: PolicyAssignmentUpdateMapper, }; export const resourceGroupName: OperationURLParameter = { @@ -152,39 +246,14 @@ export const resourceGroupName: OperationURLParameter = { constraints: { Pattern: new RegExp("^[-\\w\\._\\(\\)]+$"), MaxLength: 90, - MinLength: 1 + MinLength: 1, }, serializedName: "resourceGroupName", required: true, type: { - name: "String" - } - } -}; - -export const top: OperationQueryParameter = { - parameterPath: ["options", "top"], - mapper: { - constraints: { - InclusiveMaximum: 1000, - InclusiveMinimum: 1 + name: "String", }, - serializedName: "$top", - type: { - name: "Number" - } - } -}; - -export const subscriptionId: OperationURLParameter = { - parameterPath: "subscriptionId", - mapper: { - serializedName: "subscriptionId", - required: true, - type: { - name: "String" - } - } + }, }; export const resourceProviderNamespace: OperationURLParameter = { @@ -193,9 +262,9 @@ export const resourceProviderNamespace: OperationURLParameter = { serializedName: "resourceProviderNamespace", required: true, type: { - name: "String" - } - } + name: "String", + }, + }, }; export const parentResourcePath: OperationURLParameter = { @@ -204,10 +273,10 @@ export const parentResourcePath: OperationURLParameter = { serializedName: "parentResourcePath", required: true, type: { - name: "String" - } + name: "String", + }, }, - skipEncoding: true + skipEncoding: true, }; export const resourceType: OperationURLParameter = { @@ -216,32 +285,24 @@ export const resourceType: OperationURLParameter = { serializedName: "resourceType", required: true, type: { - name: "String" - } + name: "String", + }, }, - skipEncoding: true + skipEncoding: true, }; export const resourceName: OperationURLParameter = { parameterPath: "resourceName", mapper: { + constraints: { + Pattern: new RegExp("^.+$"), + }, serializedName: "resourceName", required: true, type: { - name: "String" - } - } -}; - -export const managementGroupId: OperationURLParameter = { - parameterPath: "managementGroupId", - mapper: { - serializedName: "managementGroupId", - required: true, - type: { - name: "String" - } - } + name: "String", + }, + }, }; export const policyAssignmentId: OperationURLParameter = { @@ -250,68 +311,8 @@ export const policyAssignmentId: OperationURLParameter = { serializedName: "policyAssignmentId", required: true, type: { - name: "String" - } + name: "String", + }, }, - skipEncoding: true -}; - -export const parameters2: OperationParameter = { - parameterPath: "parameters", - mapper: PolicyDefinitionMapper -}; - -export const policyDefinitionName: OperationURLParameter = { - parameterPath: "policyDefinitionName", - mapper: { - serializedName: "policyDefinitionName", - required: true, - type: { - name: "String" - } - } -}; - -export const parameters3: OperationParameter = { - parameterPath: "parameters", - mapper: PolicySetDefinitionMapper -}; - -export const policySetDefinitionName: OperationURLParameter = { - parameterPath: "policySetDefinitionName", - mapper: { - serializedName: "policySetDefinitionName", - required: true, - type: { - name: "String" - } - } -}; - -export const policyExemptionName: OperationURLParameter = { - parameterPath: "policyExemptionName", - mapper: { - serializedName: "policyExemptionName", - required: true, - type: { - name: "String" - } - } -}; - -export const apiVersion2: OperationQueryParameter = { - parameterPath: "apiVersion", - mapper: { - defaultValue: "2020-07-01-preview", - isConstant: true, - serializedName: "api-version", - type: { - name: "String" - } - } -}; - -export const parameters4: OperationParameter = { - parameterPath: "parameters", - mapper: PolicyExemptionMapper + skipEncoding: true, }; diff --git a/sdk/policy/arm-policy/src/operations/dataPolicyManifests.ts b/sdk/policy/arm-policy/src/operations/dataPolicyManifests.ts deleted file mode 100644 index 9f4abd98aba3..000000000000 --- a/sdk/policy/arm-policy/src/operations/dataPolicyManifests.ts +++ /dev/null @@ -1,190 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -import { PagedAsyncIterableIterator, PageSettings } from "@azure/core-paging"; -import { setContinuationToken } from "../pagingHelper"; -import { DataPolicyManifests } from "../operationsInterfaces"; -import * as coreClient from "@azure/core-client"; -import * as Mappers from "../models/mappers"; -import * as Parameters from "../models/parameters"; -import { PolicyClient } from "../policyClient"; -import { - DataPolicyManifest, - DataPolicyManifestsListNextOptionalParams, - DataPolicyManifestsListOptionalParams, - DataPolicyManifestsListResponse, - DataPolicyManifestsGetByPolicyModeOptionalParams, - DataPolicyManifestsGetByPolicyModeResponse, - DataPolicyManifestsListNextResponse -} from "../models"; - -/// -/** Class containing DataPolicyManifests operations. */ -export class DataPolicyManifestsImpl implements DataPolicyManifests { - private readonly client: PolicyClient; - - /** - * Initialize a new instance of the class DataPolicyManifests class. - * @param client Reference to the service client - */ - constructor(client: PolicyClient) { - this.client = client; - } - - /** - * This operation retrieves a list of all the data policy manifests that match the optional given - * $filter. Valid values for $filter are: "$filter=namespace eq '{0}'". If $filter is not provided, the - * unfiltered list includes all data policy manifests for data resource types. If $filter=namespace is - * provided, the returned list only includes all data policy manifests that have a namespace matching - * the provided value. - * @param options The options parameters. - */ - public list( - options?: DataPolicyManifestsListOptionalParams - ): PagedAsyncIterableIterator { - const iter = this.listPagingAll(options); - return { - next() { - return iter.next(); - }, - [Symbol.asyncIterator]() { - return this; - }, - byPage: (settings?: PageSettings) => { - if (settings?.maxPageSize) { - throw new Error("maxPageSize is not supported by this operation."); - } - return this.listPagingPage(options, settings); - } - }; - } - - private async *listPagingPage( - options?: DataPolicyManifestsListOptionalParams, - settings?: PageSettings - ): AsyncIterableIterator { - let result: DataPolicyManifestsListResponse; - let continuationToken = settings?.continuationToken; - if (!continuationToken) { - result = await this._list(options); - let page = result.value || []; - continuationToken = result.nextLink; - setContinuationToken(page, continuationToken); - yield page; - } - while (continuationToken) { - result = await this._listNext(continuationToken, options); - continuationToken = result.nextLink; - let page = result.value || []; - setContinuationToken(page, continuationToken); - yield page; - } - } - - private async *listPagingAll( - options?: DataPolicyManifestsListOptionalParams - ): AsyncIterableIterator { - for await (const page of this.listPagingPage(options)) { - yield* page; - } - } - - /** - * This operation retrieves the data policy manifest with the given policy mode. - * @param policyMode The policy mode of the data policy manifest to get. - * @param options The options parameters. - */ - getByPolicyMode( - policyMode: string, - options?: DataPolicyManifestsGetByPolicyModeOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { policyMode, options }, - getByPolicyModeOperationSpec - ); - } - - /** - * This operation retrieves a list of all the data policy manifests that match the optional given - * $filter. Valid values for $filter are: "$filter=namespace eq '{0}'". If $filter is not provided, the - * unfiltered list includes all data policy manifests for data resource types. If $filter=namespace is - * provided, the returned list only includes all data policy manifests that have a namespace matching - * the provided value. - * @param options The options parameters. - */ - private _list( - options?: DataPolicyManifestsListOptionalParams - ): Promise { - return this.client.sendOperationRequest({ options }, listOperationSpec); - } - - /** - * ListNext - * @param nextLink The nextLink from the previous successful call to the List method. - * @param options The options parameters. - */ - private _listNext( - nextLink: string, - options?: DataPolicyManifestsListNextOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { nextLink, options }, - listNextOperationSpec - ); - } -} -// Operation Specifications -const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); - -const getByPolicyModeOperationSpec: coreClient.OperationSpec = { - path: "/providers/Microsoft.Authorization/dataPolicyManifests/{policyMode}", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.DataPolicyManifest - }, - default: { - bodyMapper: Mappers.CloudError - } - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [Parameters.$host, Parameters.policyMode], - headerParameters: [Parameters.accept], - serializer -}; -const listOperationSpec: coreClient.OperationSpec = { - path: "/providers/Microsoft.Authorization/dataPolicyManifests", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.DataPolicyManifestListResult - }, - default: { - bodyMapper: Mappers.CloudError - } - }, - queryParameters: [Parameters.apiVersion, Parameters.filter], - urlParameters: [Parameters.$host], - headerParameters: [Parameters.accept], - serializer -}; -const listNextOperationSpec: coreClient.OperationSpec = { - path: "{nextLink}", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.DataPolicyManifestListResult - }, - default: { - bodyMapper: Mappers.CloudError - } - }, - urlParameters: [Parameters.$host, Parameters.nextLink], - headerParameters: [Parameters.accept], - serializer -}; diff --git a/sdk/policy/arm-policy/src/operations/index.ts b/sdk/policy/arm-policy/src/operations/index.ts index eff8c4c2a63a..2e5558fc99cc 100644 --- a/sdk/policy/arm-policy/src/operations/index.ts +++ b/sdk/policy/arm-policy/src/operations/index.ts @@ -6,8 +6,8 @@ * Changes may cause incorrect behavior and will be lost if the code is regenerated. */ -export * from "./dataPolicyManifests"; -export * from "./policyAssignments"; export * from "./policyDefinitions"; +export * from "./policyDefinitionVersions"; export * from "./policySetDefinitions"; -export * from "./policyExemptions"; +export * from "./policySetDefinitionVersions"; +export * from "./policyAssignments"; diff --git a/sdk/policy/arm-policy/src/operations/policyAssignments.ts b/sdk/policy/arm-policy/src/operations/policyAssignments.ts index 7711d4d9b20b..e66565b02c64 100644 --- a/sdk/policy/arm-policy/src/operations/policyAssignments.ts +++ b/sdk/policy/arm-policy/src/operations/policyAssignments.ts @@ -47,7 +47,7 @@ import { PolicyAssignmentsListForResourceGroupNextResponse, PolicyAssignmentsListForResourceNextResponse, PolicyAssignmentsListForManagementGroupNextResponse, - PolicyAssignmentsListNextResponse + PolicyAssignmentsListNextResponse, } from "../models"; /// @@ -80,7 +80,7 @@ export class PolicyAssignmentsImpl implements PolicyAssignments { */ public listForResourceGroup( resourceGroupName: string, - options?: PolicyAssignmentsListForResourceGroupOptionalParams + options?: PolicyAssignmentsListForResourceGroupOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listForResourceGroupPagingAll(resourceGroupName, options); return { @@ -97,16 +97,16 @@ export class PolicyAssignmentsImpl implements PolicyAssignments { return this.listForResourceGroupPagingPage( resourceGroupName, options, - settings + settings, ); - } + }, }; } private async *listForResourceGroupPagingPage( resourceGroupName: string, options?: PolicyAssignmentsListForResourceGroupOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: PolicyAssignmentsListForResourceGroupResponse; let continuationToken = settings?.continuationToken; @@ -121,7 +121,7 @@ export class PolicyAssignmentsImpl implements PolicyAssignments { result = await this._listForResourceGroupNext( resourceGroupName, continuationToken, - options + options, ); continuationToken = result.nextLink; let page = result.value || []; @@ -132,11 +132,11 @@ export class PolicyAssignmentsImpl implements PolicyAssignments { private async *listForResourceGroupPagingAll( resourceGroupName: string, - options?: PolicyAssignmentsListForResourceGroupOptionalParams + options?: PolicyAssignmentsListForResourceGroupOptionalParams, ): AsyncIterableIterator { for await (const page of this.listForResourceGroupPagingPage( resourceGroupName, - options + options, )) { yield* page; } @@ -180,7 +180,7 @@ export class PolicyAssignmentsImpl implements PolicyAssignments { parentResourcePath: string, resourceType: string, resourceName: string, - options?: PolicyAssignmentsListForResourceOptionalParams + options?: PolicyAssignmentsListForResourceOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listForResourcePagingAll( resourceGroupName, @@ -188,7 +188,7 @@ export class PolicyAssignmentsImpl implements PolicyAssignments { parentResourcePath, resourceType, resourceName, - options + options, ); return { next() { @@ -208,9 +208,9 @@ export class PolicyAssignmentsImpl implements PolicyAssignments { resourceType, resourceName, options, - settings + settings, ); - } + }, }; } @@ -221,7 +221,7 @@ export class PolicyAssignmentsImpl implements PolicyAssignments { resourceType: string, resourceName: string, options?: PolicyAssignmentsListForResourceOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: PolicyAssignmentsListForResourceResponse; let continuationToken = settings?.continuationToken; @@ -232,7 +232,7 @@ export class PolicyAssignmentsImpl implements PolicyAssignments { parentResourcePath, resourceType, resourceName, - options + options, ); let page = result.value || []; continuationToken = result.nextLink; @@ -247,7 +247,7 @@ export class PolicyAssignmentsImpl implements PolicyAssignments { resourceType, resourceName, continuationToken, - options + options, ); continuationToken = result.nextLink; let page = result.value || []; @@ -262,7 +262,7 @@ export class PolicyAssignmentsImpl implements PolicyAssignments { parentResourcePath: string, resourceType: string, resourceName: string, - options?: PolicyAssignmentsListForResourceOptionalParams + options?: PolicyAssignmentsListForResourceOptionalParams, ): AsyncIterableIterator { for await (const page of this.listForResourcePagingPage( resourceGroupName, @@ -270,7 +270,7 @@ export class PolicyAssignmentsImpl implements PolicyAssignments { parentResourcePath, resourceType, resourceName, - options + options, )) { yield* page; } @@ -290,11 +290,11 @@ export class PolicyAssignmentsImpl implements PolicyAssignments { */ public listForManagementGroup( managementGroupId: string, - options?: PolicyAssignmentsListForManagementGroupOptionalParams + options?: PolicyAssignmentsListForManagementGroupOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listForManagementGroupPagingAll( managementGroupId, - options + options, ); return { next() { @@ -310,16 +310,16 @@ export class PolicyAssignmentsImpl implements PolicyAssignments { return this.listForManagementGroupPagingPage( managementGroupId, options, - settings + settings, ); - } + }, }; } private async *listForManagementGroupPagingPage( managementGroupId: string, options?: PolicyAssignmentsListForManagementGroupOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: PolicyAssignmentsListForManagementGroupResponse; let continuationToken = settings?.continuationToken; @@ -334,7 +334,7 @@ export class PolicyAssignmentsImpl implements PolicyAssignments { result = await this._listForManagementGroupNext( managementGroupId, continuationToken, - options + options, ); continuationToken = result.nextLink; let page = result.value || []; @@ -345,11 +345,11 @@ export class PolicyAssignmentsImpl implements PolicyAssignments { private async *listForManagementGroupPagingAll( managementGroupId: string, - options?: PolicyAssignmentsListForManagementGroupOptionalParams + options?: PolicyAssignmentsListForManagementGroupOptionalParams, ): AsyncIterableIterator { for await (const page of this.listForManagementGroupPagingPage( managementGroupId, - options + options, )) { yield* page; } @@ -370,7 +370,7 @@ export class PolicyAssignmentsImpl implements PolicyAssignments { * @param options The options parameters. */ public list( - options?: PolicyAssignmentsListOptionalParams + options?: PolicyAssignmentsListOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listPagingAll(options); return { @@ -385,13 +385,13 @@ export class PolicyAssignmentsImpl implements PolicyAssignments { throw new Error("maxPageSize is not supported by this operation."); } return this.listPagingPage(options, settings); - } + }, }; } private async *listPagingPage( options?: PolicyAssignmentsListOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: PolicyAssignmentsListResponse; let continuationToken = settings?.continuationToken; @@ -412,7 +412,7 @@ export class PolicyAssignmentsImpl implements PolicyAssignments { } private async *listPagingAll( - options?: PolicyAssignmentsListOptionalParams + options?: PolicyAssignmentsListOptionalParams, ): AsyncIterableIterator { for await (const page of this.listPagingPage(options)) { yield* page; @@ -434,11 +434,11 @@ export class PolicyAssignmentsImpl implements PolicyAssignments { delete( scope: string, policyAssignmentName: string, - options?: PolicyAssignmentsDeleteOptionalParams + options?: PolicyAssignmentsDeleteOptionalParams, ): Promise { return this.client.sendOperationRequest( { scope, policyAssignmentName, options }, - deleteOperationSpec + deleteOperationSpec, ); } @@ -459,11 +459,11 @@ export class PolicyAssignmentsImpl implements PolicyAssignments { scope: string, policyAssignmentName: string, parameters: PolicyAssignment, - options?: PolicyAssignmentsCreateOptionalParams + options?: PolicyAssignmentsCreateOptionalParams, ): Promise { return this.client.sendOperationRequest( { scope, policyAssignmentName, parameters, options }, - createOperationSpec + createOperationSpec, ); } @@ -480,11 +480,11 @@ export class PolicyAssignmentsImpl implements PolicyAssignments { get( scope: string, policyAssignmentName: string, - options?: PolicyAssignmentsGetOptionalParams + options?: PolicyAssignmentsGetOptionalParams, ): Promise { return this.client.sendOperationRequest( { scope, policyAssignmentName, options }, - getOperationSpec + getOperationSpec, ); } @@ -505,11 +505,11 @@ export class PolicyAssignmentsImpl implements PolicyAssignments { scope: string, policyAssignmentName: string, parameters: PolicyAssignmentUpdate, - options?: PolicyAssignmentsUpdateOptionalParams + options?: PolicyAssignmentsUpdateOptionalParams, ): Promise { return this.client.sendOperationRequest( { scope, policyAssignmentName, parameters, options }, - updateOperationSpec + updateOperationSpec, ); } @@ -530,11 +530,11 @@ export class PolicyAssignmentsImpl implements PolicyAssignments { */ private _listForResourceGroup( resourceGroupName: string, - options?: PolicyAssignmentsListForResourceGroupOptionalParams + options?: PolicyAssignmentsListForResourceGroupOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceGroupName, options }, - listForResourceGroupOperationSpec + listForResourceGroupOperationSpec, ); } @@ -576,7 +576,7 @@ export class PolicyAssignmentsImpl implements PolicyAssignments { parentResourcePath: string, resourceType: string, resourceName: string, - options?: PolicyAssignmentsListForResourceOptionalParams + options?: PolicyAssignmentsListForResourceOptionalParams, ): Promise { return this.client.sendOperationRequest( { @@ -585,9 +585,9 @@ export class PolicyAssignmentsImpl implements PolicyAssignments { parentResourcePath, resourceType, resourceName, - options + options, }, - listForResourceOperationSpec + listForResourceOperationSpec, ); } @@ -605,11 +605,11 @@ export class PolicyAssignmentsImpl implements PolicyAssignments { */ private _listForManagementGroup( managementGroupId: string, - options?: PolicyAssignmentsListForManagementGroupOptionalParams + options?: PolicyAssignmentsListForManagementGroupOptionalParams, ): Promise { return this.client.sendOperationRequest( { managementGroupId, options }, - listForManagementGroupOperationSpec + listForManagementGroupOperationSpec, ); } @@ -628,7 +628,7 @@ export class PolicyAssignmentsImpl implements PolicyAssignments { * @param options The options parameters. */ private _list( - options?: PolicyAssignmentsListOptionalParams + options?: PolicyAssignmentsListOptionalParams, ): Promise { return this.client.sendOperationRequest({ options }, listOperationSpec); } @@ -647,11 +647,11 @@ export class PolicyAssignmentsImpl implements PolicyAssignments { */ deleteById( policyAssignmentId: string, - options?: PolicyAssignmentsDeleteByIdOptionalParams + options?: PolicyAssignmentsDeleteByIdOptionalParams, ): Promise { return this.client.sendOperationRequest( { policyAssignmentId, options }, - deleteByIdOperationSpec + deleteByIdOperationSpec, ); } @@ -673,11 +673,11 @@ export class PolicyAssignmentsImpl implements PolicyAssignments { createById( policyAssignmentId: string, parameters: PolicyAssignment, - options?: PolicyAssignmentsCreateByIdOptionalParams + options?: PolicyAssignmentsCreateByIdOptionalParams, ): Promise { return this.client.sendOperationRequest( { policyAssignmentId, parameters, options }, - createByIdOperationSpec + createByIdOperationSpec, ); } @@ -695,11 +695,11 @@ export class PolicyAssignmentsImpl implements PolicyAssignments { */ getById( policyAssignmentId: string, - options?: PolicyAssignmentsGetByIdOptionalParams + options?: PolicyAssignmentsGetByIdOptionalParams, ): Promise { return this.client.sendOperationRequest( { policyAssignmentId, options }, - getByIdOperationSpec + getByIdOperationSpec, ); } @@ -721,11 +721,11 @@ export class PolicyAssignmentsImpl implements PolicyAssignments { updateById( policyAssignmentId: string, parameters: PolicyAssignmentUpdate, - options?: PolicyAssignmentsUpdateByIdOptionalParams + options?: PolicyAssignmentsUpdateByIdOptionalParams, ): Promise { return this.client.sendOperationRequest( { policyAssignmentId, parameters, options }, - updateByIdOperationSpec + updateByIdOperationSpec, ); } @@ -738,11 +738,11 @@ export class PolicyAssignmentsImpl implements PolicyAssignments { private _listForResourceGroupNext( resourceGroupName: string, nextLink: string, - options?: PolicyAssignmentsListForResourceGroupNextOptionalParams + options?: PolicyAssignmentsListForResourceGroupNextOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceGroupName, nextLink, options }, - listForResourceGroupNextOperationSpec + listForResourceGroupNextOperationSpec, ); } @@ -765,7 +765,7 @@ export class PolicyAssignmentsImpl implements PolicyAssignments { resourceType: string, resourceName: string, nextLink: string, - options?: PolicyAssignmentsListForResourceNextOptionalParams + options?: PolicyAssignmentsListForResourceNextOptionalParams, ): Promise { return this.client.sendOperationRequest( { @@ -775,9 +775,9 @@ export class PolicyAssignmentsImpl implements PolicyAssignments { resourceType, resourceName, nextLink, - options + options, }, - listForResourceNextOperationSpec + listForResourceNextOperationSpec, ); } @@ -790,11 +790,11 @@ export class PolicyAssignmentsImpl implements PolicyAssignments { private _listForManagementGroupNext( managementGroupId: string, nextLink: string, - options?: PolicyAssignmentsListForManagementGroupNextOptionalParams + options?: PolicyAssignmentsListForManagementGroupNextOptionalParams, ): Promise { return this.client.sendOperationRequest( { managementGroupId, nextLink, options }, - listForManagementGroupNextOperationSpec + listForManagementGroupNextOperationSpec, ); } @@ -805,11 +805,11 @@ export class PolicyAssignmentsImpl implements PolicyAssignments { */ private _listNext( nextLink: string, - options?: PolicyAssignmentsListNextOptionalParams + options?: PolicyAssignmentsListNextOptionalParams, ): Promise { return this.client.sendOperationRequest( { nextLink, options }, - listNextOperationSpec + listNextOperationSpec, ); } } @@ -817,322 +817,314 @@ export class PolicyAssignmentsImpl implements PolicyAssignments { const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); const deleteOperationSpec: coreClient.OperationSpec = { - path: - "/{scope}/providers/Microsoft.Authorization/policyAssignments/{policyAssignmentName}", + path: "/{scope}/providers/Microsoft.Authorization/policyAssignments/{policyAssignmentName}", httpMethod: "DELETE", responses: { 200: { - bodyMapper: Mappers.PolicyAssignment + bodyMapper: Mappers.PolicyAssignment, }, 204: {}, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, - queryParameters: [Parameters.apiVersion1], + queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.scope, - Parameters.policyAssignmentName + Parameters.policyAssignmentName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const createOperationSpec: coreClient.OperationSpec = { - path: - "/{scope}/providers/Microsoft.Authorization/policyAssignments/{policyAssignmentName}", + path: "/{scope}/providers/Microsoft.Authorization/policyAssignments/{policyAssignmentName}", httpMethod: "PUT", responses: { 201: { - bodyMapper: Mappers.PolicyAssignment + bodyMapper: Mappers.PolicyAssignment, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, - requestBody: Parameters.parameters, - queryParameters: [Parameters.apiVersion1], + requestBody: Parameters.parameters4, + queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.scope, - Parameters.policyAssignmentName + Parameters.policyAssignmentName, ], - headerParameters: [Parameters.accept, Parameters.contentType], + headerParameters: [Parameters.contentType, Parameters.accept], mediaType: "json", - serializer + serializer, }; const getOperationSpec: coreClient.OperationSpec = { - path: - "/{scope}/providers/Microsoft.Authorization/policyAssignments/{policyAssignmentName}", + path: "/{scope}/providers/Microsoft.Authorization/policyAssignments/{policyAssignmentName}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.PolicyAssignment + bodyMapper: Mappers.PolicyAssignment, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, - queryParameters: [Parameters.apiVersion1], + queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.scope, - Parameters.policyAssignmentName + Parameters.policyAssignmentName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const updateOperationSpec: coreClient.OperationSpec = { - path: - "/{scope}/providers/Microsoft.Authorization/policyAssignments/{policyAssignmentName}", + path: "/{scope}/providers/Microsoft.Authorization/policyAssignments/{policyAssignmentName}", httpMethod: "PATCH", responses: { 200: { - bodyMapper: Mappers.PolicyAssignment + bodyMapper: Mappers.PolicyAssignment, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, - requestBody: Parameters.parameters1, - queryParameters: [Parameters.apiVersion1], + requestBody: Parameters.parameters5, + queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.scope, - Parameters.policyAssignmentName + Parameters.policyAssignmentName, ], - headerParameters: [Parameters.accept, Parameters.contentType], + headerParameters: [Parameters.contentType, Parameters.accept], mediaType: "json", - serializer + serializer, }; const listForResourceGroupOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Authorization/policyAssignments", + path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Authorization/policyAssignments", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.PolicyAssignmentListResult + bodyMapper: Mappers.PolicyAssignmentListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, - queryParameters: [Parameters.filter, Parameters.apiVersion1, Parameters.top], + queryParameters: [Parameters.apiVersion, Parameters.filter, Parameters.top], urlParameters: [ Parameters.$host, + Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.subscriptionId ], headerParameters: [Parameters.accept], - serializer + serializer, }; const listForResourceOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{parentResourcePath}/{resourceType}/{resourceName}/providers/Microsoft.Authorization/policyAssignments", + path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{parentResourcePath}/{resourceType}/{resourceName}/providers/Microsoft.Authorization/policyAssignments", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.PolicyAssignmentListResult + bodyMapper: Mappers.PolicyAssignmentListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, - queryParameters: [Parameters.filter, Parameters.apiVersion1, Parameters.top], + queryParameters: [Parameters.apiVersion, Parameters.filter, Parameters.top], urlParameters: [ Parameters.$host, - Parameters.resourceGroupName, Parameters.subscriptionId, + Parameters.resourceGroupName, Parameters.resourceProviderNamespace, Parameters.parentResourcePath, Parameters.resourceType, - Parameters.resourceName + Parameters.resourceName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const listForManagementGroupOperationSpec: coreClient.OperationSpec = { - path: - "/providers/Microsoft.Management/managementGroups/{managementGroupId}/providers/Microsoft.Authorization/policyAssignments", + path: "/providers/Microsoft.Management/managementGroups/{managementGroupId}/providers/Microsoft.Authorization/policyAssignments", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.PolicyAssignmentListResult + bodyMapper: Mappers.PolicyAssignmentListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, - queryParameters: [Parameters.filter, Parameters.apiVersion1, Parameters.top], + queryParameters: [Parameters.apiVersion, Parameters.filter, Parameters.top], urlParameters: [Parameters.$host, Parameters.managementGroupId], headerParameters: [Parameters.accept], - serializer + serializer, }; const listOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/providers/Microsoft.Authorization/policyAssignments", + path: "/subscriptions/{subscriptionId}/providers/Microsoft.Authorization/policyAssignments", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.PolicyAssignmentListResult + bodyMapper: Mappers.PolicyAssignmentListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, - queryParameters: [Parameters.filter, Parameters.apiVersion1, Parameters.top], + queryParameters: [Parameters.apiVersion, Parameters.filter, Parameters.top], urlParameters: [Parameters.$host, Parameters.subscriptionId], headerParameters: [Parameters.accept], - serializer + serializer, }; const deleteByIdOperationSpec: coreClient.OperationSpec = { path: "/{policyAssignmentId}", httpMethod: "DELETE", responses: { 200: { - bodyMapper: Mappers.PolicyAssignment + bodyMapper: Mappers.PolicyAssignment, }, 204: {}, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, - queryParameters: [Parameters.apiVersion1], + queryParameters: [Parameters.apiVersion], urlParameters: [Parameters.$host, Parameters.policyAssignmentId], headerParameters: [Parameters.accept], - serializer + serializer, }; const createByIdOperationSpec: coreClient.OperationSpec = { path: "/{policyAssignmentId}", httpMethod: "PUT", responses: { 201: { - bodyMapper: Mappers.PolicyAssignment + bodyMapper: Mappers.PolicyAssignment, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, - requestBody: Parameters.parameters, - queryParameters: [Parameters.apiVersion1], + requestBody: Parameters.parameters4, + queryParameters: [Parameters.apiVersion], urlParameters: [Parameters.$host, Parameters.policyAssignmentId], - headerParameters: [Parameters.accept, Parameters.contentType], + headerParameters: [Parameters.contentType, Parameters.accept], mediaType: "json", - serializer + serializer, }; const getByIdOperationSpec: coreClient.OperationSpec = { path: "/{policyAssignmentId}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.PolicyAssignment + bodyMapper: Mappers.PolicyAssignment, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, - queryParameters: [Parameters.apiVersion1], + queryParameters: [Parameters.apiVersion], urlParameters: [Parameters.$host, Parameters.policyAssignmentId], headerParameters: [Parameters.accept], - serializer + serializer, }; const updateByIdOperationSpec: coreClient.OperationSpec = { path: "/{policyAssignmentId}", httpMethod: "PATCH", responses: { 200: { - bodyMapper: Mappers.PolicyAssignment + bodyMapper: Mappers.PolicyAssignment, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, - requestBody: Parameters.parameters1, - queryParameters: [Parameters.apiVersion1], + requestBody: Parameters.parameters5, + queryParameters: [Parameters.apiVersion], urlParameters: [Parameters.$host, Parameters.policyAssignmentId], - headerParameters: [Parameters.accept, Parameters.contentType], + headerParameters: [Parameters.contentType, Parameters.accept], mediaType: "json", - serializer + serializer, }; const listForResourceGroupNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.PolicyAssignmentListResult + bodyMapper: Mappers.PolicyAssignmentListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, urlParameters: [ Parameters.$host, + Parameters.subscriptionId, Parameters.nextLink, Parameters.resourceGroupName, - Parameters.subscriptionId ], headerParameters: [Parameters.accept], - serializer + serializer, }; const listForResourceNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.PolicyAssignmentListResult + bodyMapper: Mappers.PolicyAssignmentListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, urlParameters: [ Parameters.$host, + Parameters.subscriptionId, Parameters.nextLink, Parameters.resourceGroupName, - Parameters.subscriptionId, Parameters.resourceProviderNamespace, Parameters.parentResourcePath, Parameters.resourceType, - Parameters.resourceName + Parameters.resourceName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const listForManagementGroupNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.PolicyAssignmentListResult + bodyMapper: Mappers.PolicyAssignmentListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, urlParameters: [ Parameters.$host, + Parameters.managementGroupId, Parameters.nextLink, - Parameters.managementGroupId ], headerParameters: [Parameters.accept], - serializer + serializer, }; const listNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.PolicyAssignmentListResult + bodyMapper: Mappers.PolicyAssignmentListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, urlParameters: [ Parameters.$host, + Parameters.subscriptionId, Parameters.nextLink, - Parameters.subscriptionId ], headerParameters: [Parameters.accept], - serializer + serializer, }; diff --git a/sdk/policy/arm-policy/src/operations/policyDefinitionVersions.ts b/sdk/policy/arm-policy/src/operations/policyDefinitionVersions.ts new file mode 100644 index 000000000000..535047c064ce --- /dev/null +++ b/sdk/policy/arm-policy/src/operations/policyDefinitionVersions.ts @@ -0,0 +1,902 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +import { PagedAsyncIterableIterator, PageSettings } from "@azure/core-paging"; +import { setContinuationToken } from "../pagingHelper"; +import { PolicyDefinitionVersions } from "../operationsInterfaces"; +import * as coreClient from "@azure/core-client"; +import * as Mappers from "../models/mappers"; +import * as Parameters from "../models/parameters"; +import { PolicyClient } from "../policyClient"; +import { + PolicyDefinitionVersion, + PolicyDefinitionVersionsListNextOptionalParams, + PolicyDefinitionVersionsListOptionalParams, + PolicyDefinitionVersionsListResponse, + PolicyDefinitionVersionsListBuiltInNextOptionalParams, + PolicyDefinitionVersionsListBuiltInOptionalParams, + PolicyDefinitionVersionsListBuiltInResponse, + PolicyDefinitionVersionsListByManagementGroupNextOptionalParams, + PolicyDefinitionVersionsListByManagementGroupOptionalParams, + PolicyDefinitionVersionsListByManagementGroupResponse, + PolicyDefinitionVersionsListAllBuiltinsOptionalParams, + PolicyDefinitionVersionsListAllBuiltinsResponse, + PolicyDefinitionVersionsListAllAtManagementGroupOptionalParams, + PolicyDefinitionVersionsListAllAtManagementGroupResponse, + PolicyDefinitionVersionsListAllOptionalParams, + PolicyDefinitionVersionsListAllResponse, + PolicyDefinitionVersionsCreateOrUpdateOptionalParams, + PolicyDefinitionVersionsCreateOrUpdateResponse, + PolicyDefinitionVersionsDeleteOptionalParams, + PolicyDefinitionVersionsGetOptionalParams, + PolicyDefinitionVersionsGetResponse, + PolicyDefinitionVersionsGetBuiltInOptionalParams, + PolicyDefinitionVersionsGetBuiltInResponse, + PolicyDefinitionVersionsCreateOrUpdateAtManagementGroupOptionalParams, + PolicyDefinitionVersionsCreateOrUpdateAtManagementGroupResponse, + PolicyDefinitionVersionsDeleteAtManagementGroupOptionalParams, + PolicyDefinitionVersionsGetAtManagementGroupOptionalParams, + PolicyDefinitionVersionsGetAtManagementGroupResponse, + PolicyDefinitionVersionsListNextResponse, + PolicyDefinitionVersionsListBuiltInNextResponse, + PolicyDefinitionVersionsListByManagementGroupNextResponse, +} from "../models"; + +/// +/** Class containing PolicyDefinitionVersions operations. */ +export class PolicyDefinitionVersionsImpl implements PolicyDefinitionVersions { + private readonly client: PolicyClient; + + /** + * Initialize a new instance of the class PolicyDefinitionVersions class. + * @param client Reference to the service client + */ + constructor(client: PolicyClient) { + this.client = client; + } + + /** + * This operation retrieves a list of all the policy definition versions for the given policy + * definition. + * @param policyDefinitionName The name of the policy definition. + * @param options The options parameters. + */ + public list( + policyDefinitionName: string, + options?: PolicyDefinitionVersionsListOptionalParams, + ): PagedAsyncIterableIterator { + const iter = this.listPagingAll(policyDefinitionName, options); + return { + next() { + return iter.next(); + }, + [Symbol.asyncIterator]() { + return this; + }, + byPage: (settings?: PageSettings) => { + if (settings?.maxPageSize) { + throw new Error("maxPageSize is not supported by this operation."); + } + return this.listPagingPage(policyDefinitionName, options, settings); + }, + }; + } + + private async *listPagingPage( + policyDefinitionName: string, + options?: PolicyDefinitionVersionsListOptionalParams, + settings?: PageSettings, + ): AsyncIterableIterator { + let result: PolicyDefinitionVersionsListResponse; + let continuationToken = settings?.continuationToken; + if (!continuationToken) { + result = await this._list(policyDefinitionName, options); + let page = result.value || []; + continuationToken = result.nextLink; + setContinuationToken(page, continuationToken); + yield page; + } + while (continuationToken) { + result = await this._listNext( + policyDefinitionName, + continuationToken, + options, + ); + continuationToken = result.nextLink; + let page = result.value || []; + setContinuationToken(page, continuationToken); + yield page; + } + } + + private async *listPagingAll( + policyDefinitionName: string, + options?: PolicyDefinitionVersionsListOptionalParams, + ): AsyncIterableIterator { + for await (const page of this.listPagingPage( + policyDefinitionName, + options, + )) { + yield* page; + } + } + + /** + * This operation retrieves a list of all the built-in policy definition versions for the given policy + * definition. + * @param policyDefinitionName The name of the policy definition. + * @param options The options parameters. + */ + public listBuiltIn( + policyDefinitionName: string, + options?: PolicyDefinitionVersionsListBuiltInOptionalParams, + ): PagedAsyncIterableIterator { + const iter = this.listBuiltInPagingAll(policyDefinitionName, options); + return { + next() { + return iter.next(); + }, + [Symbol.asyncIterator]() { + return this; + }, + byPage: (settings?: PageSettings) => { + if (settings?.maxPageSize) { + throw new Error("maxPageSize is not supported by this operation."); + } + return this.listBuiltInPagingPage( + policyDefinitionName, + options, + settings, + ); + }, + }; + } + + private async *listBuiltInPagingPage( + policyDefinitionName: string, + options?: PolicyDefinitionVersionsListBuiltInOptionalParams, + settings?: PageSettings, + ): AsyncIterableIterator { + let result: PolicyDefinitionVersionsListBuiltInResponse; + let continuationToken = settings?.continuationToken; + if (!continuationToken) { + result = await this._listBuiltIn(policyDefinitionName, options); + let page = result.value || []; + continuationToken = result.nextLink; + setContinuationToken(page, continuationToken); + yield page; + } + while (continuationToken) { + result = await this._listBuiltInNext( + policyDefinitionName, + continuationToken, + options, + ); + continuationToken = result.nextLink; + let page = result.value || []; + setContinuationToken(page, continuationToken); + yield page; + } + } + + private async *listBuiltInPagingAll( + policyDefinitionName: string, + options?: PolicyDefinitionVersionsListBuiltInOptionalParams, + ): AsyncIterableIterator { + for await (const page of this.listBuiltInPagingPage( + policyDefinitionName, + options, + )) { + yield* page; + } + } + + /** + * This operation retrieves a list of all the policy definition versions for the given policy + * definition in the given management group. + * @param managementGroupName The name of the management group. The name is case insensitive. + * @param policyDefinitionName The name of the policy definition. + * @param options The options parameters. + */ + public listByManagementGroup( + managementGroupName: string, + policyDefinitionName: string, + options?: PolicyDefinitionVersionsListByManagementGroupOptionalParams, + ): PagedAsyncIterableIterator { + const iter = this.listByManagementGroupPagingAll( + managementGroupName, + policyDefinitionName, + options, + ); + return { + next() { + return iter.next(); + }, + [Symbol.asyncIterator]() { + return this; + }, + byPage: (settings?: PageSettings) => { + if (settings?.maxPageSize) { + throw new Error("maxPageSize is not supported by this operation."); + } + return this.listByManagementGroupPagingPage( + managementGroupName, + policyDefinitionName, + options, + settings, + ); + }, + }; + } + + private async *listByManagementGroupPagingPage( + managementGroupName: string, + policyDefinitionName: string, + options?: PolicyDefinitionVersionsListByManagementGroupOptionalParams, + settings?: PageSettings, + ): AsyncIterableIterator { + let result: PolicyDefinitionVersionsListByManagementGroupResponse; + let continuationToken = settings?.continuationToken; + if (!continuationToken) { + result = await this._listByManagementGroup( + managementGroupName, + policyDefinitionName, + options, + ); + let page = result.value || []; + continuationToken = result.nextLink; + setContinuationToken(page, continuationToken); + yield page; + } + while (continuationToken) { + result = await this._listByManagementGroupNext( + managementGroupName, + policyDefinitionName, + continuationToken, + options, + ); + continuationToken = result.nextLink; + let page = result.value || []; + setContinuationToken(page, continuationToken); + yield page; + } + } + + private async *listByManagementGroupPagingAll( + managementGroupName: string, + policyDefinitionName: string, + options?: PolicyDefinitionVersionsListByManagementGroupOptionalParams, + ): AsyncIterableIterator { + for await (const page of this.listByManagementGroupPagingPage( + managementGroupName, + policyDefinitionName, + options, + )) { + yield* page; + } + } + + /** + * This operation lists all the built-in policy definition versions for all built-in policy + * definitions. + * @param options The options parameters. + */ + listAllBuiltins( + options?: PolicyDefinitionVersionsListAllBuiltinsOptionalParams, + ): Promise { + return this.client.sendOperationRequest( + { options }, + listAllBuiltinsOperationSpec, + ); + } + + /** + * This operation lists all the policy definition versions for all policy definitions at the management + * group scope. + * @param managementGroupName The name of the management group. The name is case insensitive. + * @param options The options parameters. + */ + listAllAtManagementGroup( + managementGroupName: string, + options?: PolicyDefinitionVersionsListAllAtManagementGroupOptionalParams, + ): Promise { + return this.client.sendOperationRequest( + { managementGroupName, options }, + listAllAtManagementGroupOperationSpec, + ); + } + + /** + * This operation lists all the policy definition versions for all policy definitions within a + * subscription. + * @param options The options parameters. + */ + listAll( + options?: PolicyDefinitionVersionsListAllOptionalParams, + ): Promise { + return this.client.sendOperationRequest({ options }, listAllOperationSpec); + } + + /** + * This operation creates or updates a policy definition in the given subscription with the given name. + * @param policyDefinitionName The name of the policy definition. + * @param policyDefinitionVersion The policy definition version. The format is x.y.z where x is the + * major version number, y is the minor version number, and z is the patch number + * @param parameters The policy definition properties. + * @param options The options parameters. + */ + createOrUpdate( + policyDefinitionName: string, + policyDefinitionVersion: string, + parameters: PolicyDefinitionVersion, + options?: PolicyDefinitionVersionsCreateOrUpdateOptionalParams, + ): Promise { + return this.client.sendOperationRequest( + { policyDefinitionName, policyDefinitionVersion, parameters, options }, + createOrUpdateOperationSpec, + ); + } + + /** + * This operation deletes the policy definition version in the given subscription with the given name. + * @param policyDefinitionName The name of the policy definition. + * @param policyDefinitionVersion The policy definition version. The format is x.y.z where x is the + * major version number, y is the minor version number, and z is the patch number + * @param options The options parameters. + */ + delete( + policyDefinitionName: string, + policyDefinitionVersion: string, + options?: PolicyDefinitionVersionsDeleteOptionalParams, + ): Promise { + return this.client.sendOperationRequest( + { policyDefinitionName, policyDefinitionVersion, options }, + deleteOperationSpec, + ); + } + + /** + * This operation retrieves the policy definition version in the given subscription with the given + * name. + * @param policyDefinitionName The name of the policy definition. + * @param policyDefinitionVersion The policy definition version. The format is x.y.z where x is the + * major version number, y is the minor version number, and z is the patch number + * @param options The options parameters. + */ + get( + policyDefinitionName: string, + policyDefinitionVersion: string, + options?: PolicyDefinitionVersionsGetOptionalParams, + ): Promise { + return this.client.sendOperationRequest( + { policyDefinitionName, policyDefinitionVersion, options }, + getOperationSpec, + ); + } + + /** + * This operation retrieves the built-in policy definition version with the given name. + * @param policyDefinitionName The name of the policy definition. + * @param policyDefinitionVersion The policy definition version. The format is x.y.z where x is the + * major version number, y is the minor version number, and z is the patch number + * @param options The options parameters. + */ + getBuiltIn( + policyDefinitionName: string, + policyDefinitionVersion: string, + options?: PolicyDefinitionVersionsGetBuiltInOptionalParams, + ): Promise { + return this.client.sendOperationRequest( + { policyDefinitionName, policyDefinitionVersion, options }, + getBuiltInOperationSpec, + ); + } + + /** + * This operation creates or updates a policy definition version in the given management group with the + * given name. + * @param managementGroupName The name of the management group. The name is case insensitive. + * @param policyDefinitionName The name of the policy definition. + * @param policyDefinitionVersion The policy definition version. The format is x.y.z where x is the + * major version number, y is the minor version number, and z is the patch number + * @param parameters The policy definition properties. + * @param options The options parameters. + */ + createOrUpdateAtManagementGroup( + managementGroupName: string, + policyDefinitionName: string, + policyDefinitionVersion: string, + parameters: PolicyDefinitionVersion, + options?: PolicyDefinitionVersionsCreateOrUpdateAtManagementGroupOptionalParams, + ): Promise { + return this.client.sendOperationRequest( + { + managementGroupName, + policyDefinitionName, + policyDefinitionVersion, + parameters, + options, + }, + createOrUpdateAtManagementGroupOperationSpec, + ); + } + + /** + * This operation deletes the policy definition in the given management group with the given name. + * @param managementGroupName The name of the management group. The name is case insensitive. + * @param policyDefinitionName The name of the policy definition. + * @param policyDefinitionVersion The policy definition version. The format is x.y.z where x is the + * major version number, y is the minor version number, and z is the patch number + * @param options The options parameters. + */ + deleteAtManagementGroup( + managementGroupName: string, + policyDefinitionName: string, + policyDefinitionVersion: string, + options?: PolicyDefinitionVersionsDeleteAtManagementGroupOptionalParams, + ): Promise { + return this.client.sendOperationRequest( + { + managementGroupName, + policyDefinitionName, + policyDefinitionVersion, + options, + }, + deleteAtManagementGroupOperationSpec, + ); + } + + /** + * This operation retrieves the policy definition version in the given management group with the given + * name. + * @param managementGroupName The name of the management group. The name is case insensitive. + * @param policyDefinitionName The name of the policy definition. + * @param policyDefinitionVersion The policy definition version. The format is x.y.z where x is the + * major version number, y is the minor version number, and z is the patch number + * @param options The options parameters. + */ + getAtManagementGroup( + managementGroupName: string, + policyDefinitionName: string, + policyDefinitionVersion: string, + options?: PolicyDefinitionVersionsGetAtManagementGroupOptionalParams, + ): Promise { + return this.client.sendOperationRequest( + { + managementGroupName, + policyDefinitionName, + policyDefinitionVersion, + options, + }, + getAtManagementGroupOperationSpec, + ); + } + + /** + * This operation retrieves a list of all the policy definition versions for the given policy + * definition. + * @param policyDefinitionName The name of the policy definition. + * @param options The options parameters. + */ + private _list( + policyDefinitionName: string, + options?: PolicyDefinitionVersionsListOptionalParams, + ): Promise { + return this.client.sendOperationRequest( + { policyDefinitionName, options }, + listOperationSpec, + ); + } + + /** + * This operation retrieves a list of all the built-in policy definition versions for the given policy + * definition. + * @param policyDefinitionName The name of the policy definition. + * @param options The options parameters. + */ + private _listBuiltIn( + policyDefinitionName: string, + options?: PolicyDefinitionVersionsListBuiltInOptionalParams, + ): Promise { + return this.client.sendOperationRequest( + { policyDefinitionName, options }, + listBuiltInOperationSpec, + ); + } + + /** + * This operation retrieves a list of all the policy definition versions for the given policy + * definition in the given management group. + * @param managementGroupName The name of the management group. The name is case insensitive. + * @param policyDefinitionName The name of the policy definition. + * @param options The options parameters. + */ + private _listByManagementGroup( + managementGroupName: string, + policyDefinitionName: string, + options?: PolicyDefinitionVersionsListByManagementGroupOptionalParams, + ): Promise { + return this.client.sendOperationRequest( + { managementGroupName, policyDefinitionName, options }, + listByManagementGroupOperationSpec, + ); + } + + /** + * ListNext + * @param policyDefinitionName The name of the policy definition. + * @param nextLink The nextLink from the previous successful call to the List method. + * @param options The options parameters. + */ + private _listNext( + policyDefinitionName: string, + nextLink: string, + options?: PolicyDefinitionVersionsListNextOptionalParams, + ): Promise { + return this.client.sendOperationRequest( + { policyDefinitionName, nextLink, options }, + listNextOperationSpec, + ); + } + + /** + * ListBuiltInNext + * @param policyDefinitionName The name of the policy definition. + * @param nextLink The nextLink from the previous successful call to the ListBuiltIn method. + * @param options The options parameters. + */ + private _listBuiltInNext( + policyDefinitionName: string, + nextLink: string, + options?: PolicyDefinitionVersionsListBuiltInNextOptionalParams, + ): Promise { + return this.client.sendOperationRequest( + { policyDefinitionName, nextLink, options }, + listBuiltInNextOperationSpec, + ); + } + + /** + * ListByManagementGroupNext + * @param managementGroupName The name of the management group. The name is case insensitive. + * @param policyDefinitionName The name of the policy definition. + * @param nextLink The nextLink from the previous successful call to the ListByManagementGroup method. + * @param options The options parameters. + */ + private _listByManagementGroupNext( + managementGroupName: string, + policyDefinitionName: string, + nextLink: string, + options?: PolicyDefinitionVersionsListByManagementGroupNextOptionalParams, + ): Promise { + return this.client.sendOperationRequest( + { managementGroupName, policyDefinitionName, nextLink, options }, + listByManagementGroupNextOperationSpec, + ); + } +} +// Operation Specifications +const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); + +const listAllBuiltinsOperationSpec: coreClient.OperationSpec = { + path: "/providers/Microsoft.Authorization/listPolicyDefinitionVersions", + httpMethod: "POST", + responses: { + 200: { + bodyMapper: Mappers.PolicyDefinitionVersionListResult, + }, + default: { + bodyMapper: Mappers.CloudError, + }, + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [Parameters.$host], + headerParameters: [Parameters.accept], + serializer, +}; +const listAllAtManagementGroupOperationSpec: coreClient.OperationSpec = { + path: "/providers/Microsoft.Management/managementGroups/{managementGroupName}/providers/Microsoft.Authorization/listPolicyDefinitionVersions", + httpMethod: "POST", + responses: { + 200: { + bodyMapper: Mappers.PolicyDefinitionVersionListResult, + }, + default: { + bodyMapper: Mappers.CloudError, + }, + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [Parameters.$host, Parameters.managementGroupName], + headerParameters: [Parameters.accept], + serializer, +}; +const listAllOperationSpec: coreClient.OperationSpec = { + path: "/subscriptions/{subscriptionId}/providers/Microsoft.Authorization/listPolicyDefinitionVersions", + httpMethod: "POST", + responses: { + 200: { + bodyMapper: Mappers.PolicyDefinitionVersionListResult, + }, + default: { + bodyMapper: Mappers.CloudError, + }, + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [Parameters.$host, Parameters.subscriptionId], + headerParameters: [Parameters.accept], + serializer, +}; +const createOrUpdateOperationSpec: coreClient.OperationSpec = { + path: "/subscriptions/{subscriptionId}/providers/Microsoft.Authorization/policyDefinitions/{policyDefinitionName}/versions/{policyDefinitionVersion}", + httpMethod: "PUT", + responses: { + 200: { + bodyMapper: Mappers.PolicyDefinitionVersion, + }, + 201: { + bodyMapper: Mappers.PolicyDefinitionVersion, + }, + default: { + bodyMapper: Mappers.CloudError, + }, + }, + requestBody: Parameters.parameters1, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.policyDefinitionName, + Parameters.policyDefinitionVersion, + ], + headerParameters: [Parameters.contentType, Parameters.accept], + mediaType: "json", + serializer, +}; +const deleteOperationSpec: coreClient.OperationSpec = { + path: "/subscriptions/{subscriptionId}/providers/Microsoft.Authorization/policyDefinitions/{policyDefinitionName}/versions/{policyDefinitionVersion}", + httpMethod: "DELETE", + responses: { + 200: {}, + 204: {}, + default: { + bodyMapper: Mappers.CloudError, + }, + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.policyDefinitionName, + Parameters.policyDefinitionVersion, + ], + headerParameters: [Parameters.accept], + serializer, +}; +const getOperationSpec: coreClient.OperationSpec = { + path: "/subscriptions/{subscriptionId}/providers/Microsoft.Authorization/policyDefinitions/{policyDefinitionName}/versions/{policyDefinitionVersion}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.PolicyDefinitionVersion, + }, + default: { + bodyMapper: Mappers.CloudError, + }, + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.policyDefinitionName, + Parameters.policyDefinitionVersion, + ], + headerParameters: [Parameters.accept], + serializer, +}; +const getBuiltInOperationSpec: coreClient.OperationSpec = { + path: "/providers/Microsoft.Authorization/policyDefinitions/{policyDefinitionName}/versions/{policyDefinitionVersion}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.PolicyDefinitionVersion, + }, + default: { + bodyMapper: Mappers.CloudError, + }, + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.policyDefinitionName, + Parameters.policyDefinitionVersion, + ], + headerParameters: [Parameters.accept], + serializer, +}; +const createOrUpdateAtManagementGroupOperationSpec: coreClient.OperationSpec = { + path: "/providers/Microsoft.Management/managementGroups/{managementGroupName}/providers/Microsoft.Authorization/policyDefinitions/{policyDefinitionName}/versions/{policyDefinitionVersion}", + httpMethod: "PUT", + responses: { + 200: { + bodyMapper: Mappers.PolicyDefinitionVersion, + }, + 201: { + bodyMapper: Mappers.PolicyDefinitionVersion, + }, + default: { + bodyMapper: Mappers.CloudError, + }, + }, + requestBody: Parameters.parameters1, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.policyDefinitionName, + Parameters.managementGroupName, + Parameters.policyDefinitionVersion, + ], + headerParameters: [Parameters.contentType, Parameters.accept], + mediaType: "json", + serializer, +}; +const deleteAtManagementGroupOperationSpec: coreClient.OperationSpec = { + path: "/providers/Microsoft.Management/managementGroups/{managementGroupName}/providers/Microsoft.Authorization/policyDefinitions/{policyDefinitionName}/versions/{policyDefinitionVersion}", + httpMethod: "DELETE", + responses: { + 200: {}, + 204: {}, + default: { + bodyMapper: Mappers.CloudError, + }, + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.policyDefinitionName, + Parameters.managementGroupName, + Parameters.policyDefinitionVersion, + ], + headerParameters: [Parameters.accept], + serializer, +}; +const getAtManagementGroupOperationSpec: coreClient.OperationSpec = { + path: "/providers/Microsoft.Management/managementGroups/{managementGroupName}/providers/Microsoft.Authorization/policyDefinitions/{policyDefinitionName}/versions/{policyDefinitionVersion}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.PolicyDefinitionVersion, + }, + default: { + bodyMapper: Mappers.CloudError, + }, + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.policyDefinitionName, + Parameters.managementGroupName, + Parameters.policyDefinitionVersion, + ], + headerParameters: [Parameters.accept], + serializer, +}; +const listOperationSpec: coreClient.OperationSpec = { + path: "/subscriptions/{subscriptionId}/providers/Microsoft.Authorization/policyDefinitions/{policyDefinitionName}/versions", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.PolicyDefinitionVersionListResult, + }, + default: { + bodyMapper: Mappers.CloudError, + }, + }, + queryParameters: [Parameters.apiVersion, Parameters.top], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.policyDefinitionName, + ], + headerParameters: [Parameters.accept], + serializer, +}; +const listBuiltInOperationSpec: coreClient.OperationSpec = { + path: "/providers/Microsoft.Authorization/policyDefinitions/{policyDefinitionName}/versions", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.PolicyDefinitionVersionListResult, + }, + default: { + bodyMapper: Mappers.CloudError, + }, + }, + queryParameters: [Parameters.apiVersion, Parameters.top], + urlParameters: [Parameters.$host, Parameters.policyDefinitionName], + headerParameters: [Parameters.accept], + serializer, +}; +const listByManagementGroupOperationSpec: coreClient.OperationSpec = { + path: "/providers/Microsoft.Management/managementGroups/{managementGroupName}/providers/Microsoft.Authorization/policyDefinitions/{policyDefinitionName}/versions", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.PolicyDefinitionVersionListResult, + }, + default: { + bodyMapper: Mappers.CloudError, + }, + }, + queryParameters: [Parameters.apiVersion, Parameters.top], + urlParameters: [ + Parameters.$host, + Parameters.policyDefinitionName, + Parameters.managementGroupName, + ], + headerParameters: [Parameters.accept], + serializer, +}; +const listNextOperationSpec: coreClient.OperationSpec = { + path: "{nextLink}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.PolicyDefinitionVersionListResult, + }, + default: { + bodyMapper: Mappers.CloudError, + }, + }, + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.policyDefinitionName, + Parameters.nextLink, + ], + headerParameters: [Parameters.accept], + serializer, +}; +const listBuiltInNextOperationSpec: coreClient.OperationSpec = { + path: "{nextLink}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.PolicyDefinitionVersionListResult, + }, + default: { + bodyMapper: Mappers.CloudError, + }, + }, + urlParameters: [ + Parameters.$host, + Parameters.policyDefinitionName, + Parameters.nextLink, + ], + headerParameters: [Parameters.accept], + serializer, +}; +const listByManagementGroupNextOperationSpec: coreClient.OperationSpec = { + path: "{nextLink}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.PolicyDefinitionVersionListResult, + }, + default: { + bodyMapper: Mappers.CloudError, + }, + }, + urlParameters: [ + Parameters.$host, + Parameters.policyDefinitionName, + Parameters.nextLink, + Parameters.managementGroupName, + ], + headerParameters: [Parameters.accept], + serializer, +}; diff --git a/sdk/policy/arm-policy/src/operations/policyDefinitions.ts b/sdk/policy/arm-policy/src/operations/policyDefinitions.ts index 32335b3819ff..0ea8eb091b66 100644 --- a/sdk/policy/arm-policy/src/operations/policyDefinitions.ts +++ b/sdk/policy/arm-policy/src/operations/policyDefinitions.ts @@ -38,7 +38,7 @@ import { PolicyDefinitionsGetAtManagementGroupResponse, PolicyDefinitionsListNextResponse, PolicyDefinitionsListBuiltInNextResponse, - PolicyDefinitionsListByManagementGroupNextResponse + PolicyDefinitionsListByManagementGroupNextResponse, } from "../models"; /// @@ -68,7 +68,7 @@ export class PolicyDefinitionsImpl implements PolicyDefinitions { * @param options The options parameters. */ public list( - options?: PolicyDefinitionsListOptionalParams + options?: PolicyDefinitionsListOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listPagingAll(options); return { @@ -83,13 +83,13 @@ export class PolicyDefinitionsImpl implements PolicyDefinitions { throw new Error("maxPageSize is not supported by this operation."); } return this.listPagingPage(options, settings); - } + }, }; } private async *listPagingPage( options?: PolicyDefinitionsListOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: PolicyDefinitionsListResponse; let continuationToken = settings?.continuationToken; @@ -110,7 +110,7 @@ export class PolicyDefinitionsImpl implements PolicyDefinitions { } private async *listPagingAll( - options?: PolicyDefinitionsListOptionalParams + options?: PolicyDefinitionsListOptionalParams, ): AsyncIterableIterator { for await (const page of this.listPagingPage(options)) { yield* page; @@ -126,7 +126,7 @@ export class PolicyDefinitionsImpl implements PolicyDefinitions { * @param options The options parameters. */ public listBuiltIn( - options?: PolicyDefinitionsListBuiltInOptionalParams + options?: PolicyDefinitionsListBuiltInOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listBuiltInPagingAll(options); return { @@ -141,13 +141,13 @@ export class PolicyDefinitionsImpl implements PolicyDefinitions { throw new Error("maxPageSize is not supported by this operation."); } return this.listBuiltInPagingPage(options, settings); - } + }, }; } private async *listBuiltInPagingPage( options?: PolicyDefinitionsListBuiltInOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: PolicyDefinitionsListBuiltInResponse; let continuationToken = settings?.continuationToken; @@ -168,7 +168,7 @@ export class PolicyDefinitionsImpl implements PolicyDefinitions { } private async *listBuiltInPagingAll( - options?: PolicyDefinitionsListBuiltInOptionalParams + options?: PolicyDefinitionsListBuiltInOptionalParams, ): AsyncIterableIterator { for await (const page of this.listBuiltInPagingPage(options)) { yield* page; @@ -191,11 +191,11 @@ export class PolicyDefinitionsImpl implements PolicyDefinitions { */ public listByManagementGroup( managementGroupId: string, - options?: PolicyDefinitionsListByManagementGroupOptionalParams + options?: PolicyDefinitionsListByManagementGroupOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listByManagementGroupPagingAll( managementGroupId, - options + options, ); return { next() { @@ -211,16 +211,16 @@ export class PolicyDefinitionsImpl implements PolicyDefinitions { return this.listByManagementGroupPagingPage( managementGroupId, options, - settings + settings, ); - } + }, }; } private async *listByManagementGroupPagingPage( managementGroupId: string, options?: PolicyDefinitionsListByManagementGroupOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: PolicyDefinitionsListByManagementGroupResponse; let continuationToken = settings?.continuationToken; @@ -235,7 +235,7 @@ export class PolicyDefinitionsImpl implements PolicyDefinitions { result = await this._listByManagementGroupNext( managementGroupId, continuationToken, - options + options, ); continuationToken = result.nextLink; let page = result.value || []; @@ -246,11 +246,11 @@ export class PolicyDefinitionsImpl implements PolicyDefinitions { private async *listByManagementGroupPagingAll( managementGroupId: string, - options?: PolicyDefinitionsListByManagementGroupOptionalParams + options?: PolicyDefinitionsListByManagementGroupOptionalParams, ): AsyncIterableIterator { for await (const page of this.listByManagementGroupPagingPage( managementGroupId, - options + options, )) { yield* page; } @@ -265,11 +265,11 @@ export class PolicyDefinitionsImpl implements PolicyDefinitions { createOrUpdate( policyDefinitionName: string, parameters: PolicyDefinition, - options?: PolicyDefinitionsCreateOrUpdateOptionalParams + options?: PolicyDefinitionsCreateOrUpdateOptionalParams, ): Promise { return this.client.sendOperationRequest( { policyDefinitionName, parameters, options }, - createOrUpdateOperationSpec + createOrUpdateOperationSpec, ); } @@ -280,11 +280,11 @@ export class PolicyDefinitionsImpl implements PolicyDefinitions { */ delete( policyDefinitionName: string, - options?: PolicyDefinitionsDeleteOptionalParams + options?: PolicyDefinitionsDeleteOptionalParams, ): Promise { return this.client.sendOperationRequest( { policyDefinitionName, options }, - deleteOperationSpec + deleteOperationSpec, ); } @@ -295,11 +295,11 @@ export class PolicyDefinitionsImpl implements PolicyDefinitions { */ get( policyDefinitionName: string, - options?: PolicyDefinitionsGetOptionalParams + options?: PolicyDefinitionsGetOptionalParams, ): Promise { return this.client.sendOperationRequest( { policyDefinitionName, options }, - getOperationSpec + getOperationSpec, ); } @@ -310,65 +310,65 @@ export class PolicyDefinitionsImpl implements PolicyDefinitions { */ getBuiltIn( policyDefinitionName: string, - options?: PolicyDefinitionsGetBuiltInOptionalParams + options?: PolicyDefinitionsGetBuiltInOptionalParams, ): Promise { return this.client.sendOperationRequest( { policyDefinitionName, options }, - getBuiltInOperationSpec + getBuiltInOperationSpec, ); } /** * This operation creates or updates a policy definition in the given management group with the given * name. - * @param policyDefinitionName The name of the policy definition to create. * @param managementGroupId The ID of the management group. + * @param policyDefinitionName The name of the policy definition to create. * @param parameters The policy definition properties. * @param options The options parameters. */ createOrUpdateAtManagementGroup( - policyDefinitionName: string, managementGroupId: string, + policyDefinitionName: string, parameters: PolicyDefinition, - options?: PolicyDefinitionsCreateOrUpdateAtManagementGroupOptionalParams + options?: PolicyDefinitionsCreateOrUpdateAtManagementGroupOptionalParams, ): Promise { return this.client.sendOperationRequest( - { policyDefinitionName, managementGroupId, parameters, options }, - createOrUpdateAtManagementGroupOperationSpec + { managementGroupId, policyDefinitionName, parameters, options }, + createOrUpdateAtManagementGroupOperationSpec, ); } /** * This operation deletes the policy definition in the given management group with the given name. - * @param policyDefinitionName The name of the policy definition to delete. * @param managementGroupId The ID of the management group. + * @param policyDefinitionName The name of the policy definition to delete. * @param options The options parameters. */ deleteAtManagementGroup( - policyDefinitionName: string, managementGroupId: string, - options?: PolicyDefinitionsDeleteAtManagementGroupOptionalParams + policyDefinitionName: string, + options?: PolicyDefinitionsDeleteAtManagementGroupOptionalParams, ): Promise { return this.client.sendOperationRequest( - { policyDefinitionName, managementGroupId, options }, - deleteAtManagementGroupOperationSpec + { managementGroupId, policyDefinitionName, options }, + deleteAtManagementGroupOperationSpec, ); } /** * This operation retrieves the policy definition in the given management group with the given name. - * @param policyDefinitionName The name of the policy definition to get. * @param managementGroupId The ID of the management group. + * @param policyDefinitionName The name of the policy definition to get. * @param options The options parameters. */ getAtManagementGroup( - policyDefinitionName: string, managementGroupId: string, - options?: PolicyDefinitionsGetAtManagementGroupOptionalParams + policyDefinitionName: string, + options?: PolicyDefinitionsGetAtManagementGroupOptionalParams, ): Promise { return this.client.sendOperationRequest( - { policyDefinitionName, managementGroupId, options }, - getAtManagementGroupOperationSpec + { managementGroupId, policyDefinitionName, options }, + getAtManagementGroupOperationSpec, ); } @@ -386,7 +386,7 @@ export class PolicyDefinitionsImpl implements PolicyDefinitions { * @param options The options parameters. */ private _list( - options?: PolicyDefinitionsListOptionalParams + options?: PolicyDefinitionsListOptionalParams, ): Promise { return this.client.sendOperationRequest({ options }, listOperationSpec); } @@ -400,11 +400,11 @@ export class PolicyDefinitionsImpl implements PolicyDefinitions { * @param options The options parameters. */ private _listBuiltIn( - options?: PolicyDefinitionsListBuiltInOptionalParams + options?: PolicyDefinitionsListBuiltInOptionalParams, ): Promise { return this.client.sendOperationRequest( { options }, - listBuiltInOperationSpec + listBuiltInOperationSpec, ); } @@ -424,11 +424,11 @@ export class PolicyDefinitionsImpl implements PolicyDefinitions { */ private _listByManagementGroup( managementGroupId: string, - options?: PolicyDefinitionsListByManagementGroupOptionalParams + options?: PolicyDefinitionsListByManagementGroupOptionalParams, ): Promise { return this.client.sendOperationRequest( { managementGroupId, options }, - listByManagementGroupOperationSpec + listByManagementGroupOperationSpec, ); } @@ -439,11 +439,11 @@ export class PolicyDefinitionsImpl implements PolicyDefinitions { */ private _listNext( nextLink: string, - options?: PolicyDefinitionsListNextOptionalParams + options?: PolicyDefinitionsListNextOptionalParams, ): Promise { return this.client.sendOperationRequest( { nextLink, options }, - listNextOperationSpec + listNextOperationSpec, ); } @@ -454,11 +454,11 @@ export class PolicyDefinitionsImpl implements PolicyDefinitions { */ private _listBuiltInNext( nextLink: string, - options?: PolicyDefinitionsListBuiltInNextOptionalParams + options?: PolicyDefinitionsListBuiltInNextOptionalParams, ): Promise { return this.client.sendOperationRequest( { nextLink, options }, - listBuiltInNextOperationSpec + listBuiltInNextOperationSpec, ); } @@ -471,11 +471,11 @@ export class PolicyDefinitionsImpl implements PolicyDefinitions { private _listByManagementGroupNext( managementGroupId: string, nextLink: string, - options?: PolicyDefinitionsListByManagementGroupNextOptionalParams + options?: PolicyDefinitionsListByManagementGroupNextOptionalParams, ): Promise { return this.client.sendOperationRequest( { managementGroupId, nextLink, options }, - listByManagementGroupNextOperationSpec + listByManagementGroupNextOperationSpec, ); } } @@ -483,250 +483,241 @@ export class PolicyDefinitionsImpl implements PolicyDefinitions { const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); const createOrUpdateOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/providers/Microsoft.Authorization/policyDefinitions/{policyDefinitionName}", + path: "/subscriptions/{subscriptionId}/providers/Microsoft.Authorization/policyDefinitions/{policyDefinitionName}", httpMethod: "PUT", responses: { 201: { - bodyMapper: Mappers.PolicyDefinition + bodyMapper: Mappers.PolicyDefinition, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, - requestBody: Parameters.parameters2, - queryParameters: [Parameters.apiVersion1], + requestBody: Parameters.parameters, + queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, - Parameters.policyDefinitionName + Parameters.policyDefinitionName, ], - headerParameters: [Parameters.accept, Parameters.contentType], + headerParameters: [Parameters.contentType, Parameters.accept], mediaType: "json", - serializer + serializer, }; const deleteOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/providers/Microsoft.Authorization/policyDefinitions/{policyDefinitionName}", + path: "/subscriptions/{subscriptionId}/providers/Microsoft.Authorization/policyDefinitions/{policyDefinitionName}", httpMethod: "DELETE", responses: { 200: {}, 204: {}, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, - queryParameters: [Parameters.apiVersion1], + queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, - Parameters.policyDefinitionName + Parameters.policyDefinitionName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const getOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/providers/Microsoft.Authorization/policyDefinitions/{policyDefinitionName}", + path: "/subscriptions/{subscriptionId}/providers/Microsoft.Authorization/policyDefinitions/{policyDefinitionName}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.PolicyDefinition + bodyMapper: Mappers.PolicyDefinition, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, - queryParameters: [Parameters.apiVersion1], + queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, - Parameters.policyDefinitionName + Parameters.policyDefinitionName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const getBuiltInOperationSpec: coreClient.OperationSpec = { - path: - "/providers/Microsoft.Authorization/policyDefinitions/{policyDefinitionName}", + path: "/providers/Microsoft.Authorization/policyDefinitions/{policyDefinitionName}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.PolicyDefinition + bodyMapper: Mappers.PolicyDefinition, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, - queryParameters: [Parameters.apiVersion1], + queryParameters: [Parameters.apiVersion], urlParameters: [Parameters.$host, Parameters.policyDefinitionName], headerParameters: [Parameters.accept], - serializer + serializer, }; const createOrUpdateAtManagementGroupOperationSpec: coreClient.OperationSpec = { - path: - "/providers/Microsoft.Management/managementGroups/{managementGroupId}/providers/Microsoft.Authorization/policyDefinitions/{policyDefinitionName}", + path: "/providers/Microsoft.Management/managementGroups/{managementGroupId}/providers/Microsoft.Authorization/policyDefinitions/{policyDefinitionName}", httpMethod: "PUT", responses: { 201: { - bodyMapper: Mappers.PolicyDefinition + bodyMapper: Mappers.PolicyDefinition, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, - requestBody: Parameters.parameters2, - queryParameters: [Parameters.apiVersion1], + requestBody: Parameters.parameters, + queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, + Parameters.policyDefinitionName, Parameters.managementGroupId, - Parameters.policyDefinitionName ], - headerParameters: [Parameters.accept, Parameters.contentType], + headerParameters: [Parameters.contentType, Parameters.accept], mediaType: "json", - serializer + serializer, }; const deleteAtManagementGroupOperationSpec: coreClient.OperationSpec = { - path: - "/providers/Microsoft.Management/managementGroups/{managementGroupId}/providers/Microsoft.Authorization/policyDefinitions/{policyDefinitionName}", + path: "/providers/Microsoft.Management/managementGroups/{managementGroupId}/providers/Microsoft.Authorization/policyDefinitions/{policyDefinitionName}", httpMethod: "DELETE", responses: { 200: {}, 204: {}, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, - queryParameters: [Parameters.apiVersion1], + queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, + Parameters.policyDefinitionName, Parameters.managementGroupId, - Parameters.policyDefinitionName ], headerParameters: [Parameters.accept], - serializer + serializer, }; const getAtManagementGroupOperationSpec: coreClient.OperationSpec = { - path: - "/providers/Microsoft.Management/managementGroups/{managementGroupId}/providers/Microsoft.Authorization/policyDefinitions/{policyDefinitionName}", + path: "/providers/Microsoft.Management/managementGroups/{managementGroupId}/providers/Microsoft.Authorization/policyDefinitions/{policyDefinitionName}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.PolicyDefinition + bodyMapper: Mappers.PolicyDefinition, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, - queryParameters: [Parameters.apiVersion1], + queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, + Parameters.policyDefinitionName, Parameters.managementGroupId, - Parameters.policyDefinitionName ], headerParameters: [Parameters.accept], - serializer + serializer, }; const listOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/providers/Microsoft.Authorization/policyDefinitions", + path: "/subscriptions/{subscriptionId}/providers/Microsoft.Authorization/policyDefinitions", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.PolicyDefinitionListResult + bodyMapper: Mappers.PolicyDefinitionListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, - queryParameters: [Parameters.filter, Parameters.apiVersion1, Parameters.top], + queryParameters: [Parameters.apiVersion, Parameters.filter, Parameters.top], urlParameters: [Parameters.$host, Parameters.subscriptionId], headerParameters: [Parameters.accept], - serializer + serializer, }; const listBuiltInOperationSpec: coreClient.OperationSpec = { path: "/providers/Microsoft.Authorization/policyDefinitions", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.PolicyDefinitionListResult + bodyMapper: Mappers.PolicyDefinitionListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, - queryParameters: [Parameters.filter, Parameters.apiVersion1, Parameters.top], + queryParameters: [Parameters.apiVersion, Parameters.filter, Parameters.top], urlParameters: [Parameters.$host], headerParameters: [Parameters.accept], - serializer + serializer, }; const listByManagementGroupOperationSpec: coreClient.OperationSpec = { - path: - "/providers/Microsoft.Management/managementGroups/{managementGroupId}/providers/Microsoft.Authorization/policyDefinitions", + path: "/providers/Microsoft.Management/managementGroups/{managementGroupId}/providers/Microsoft.Authorization/policyDefinitions", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.PolicyDefinitionListResult + bodyMapper: Mappers.PolicyDefinitionListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, - queryParameters: [Parameters.filter, Parameters.apiVersion1, Parameters.top], + queryParameters: [Parameters.apiVersion, Parameters.filter, Parameters.top], urlParameters: [Parameters.$host, Parameters.managementGroupId], headerParameters: [Parameters.accept], - serializer + serializer, }; const listNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.PolicyDefinitionListResult + bodyMapper: Mappers.PolicyDefinitionListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, urlParameters: [ Parameters.$host, + Parameters.subscriptionId, Parameters.nextLink, - Parameters.subscriptionId ], headerParameters: [Parameters.accept], - serializer + serializer, }; const listBuiltInNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.PolicyDefinitionListResult + bodyMapper: Mappers.PolicyDefinitionListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, urlParameters: [Parameters.$host, Parameters.nextLink], headerParameters: [Parameters.accept], - serializer + serializer, }; const listByManagementGroupNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.PolicyDefinitionListResult + bodyMapper: Mappers.PolicyDefinitionListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, urlParameters: [ Parameters.$host, + Parameters.managementGroupId, Parameters.nextLink, - Parameters.managementGroupId ], headerParameters: [Parameters.accept], - serializer + serializer, }; diff --git a/sdk/policy/arm-policy/src/operations/policyExemptions.ts b/sdk/policy/arm-policy/src/operations/policyExemptions.ts deleted file mode 100644 index 917606661363..000000000000 --- a/sdk/policy/arm-policy/src/operations/policyExemptions.ts +++ /dev/null @@ -1,877 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -import { PagedAsyncIterableIterator, PageSettings } from "@azure/core-paging"; -import { setContinuationToken } from "../pagingHelper"; -import { PolicyExemptions } from "../operationsInterfaces"; -import * as coreClient from "@azure/core-client"; -import * as Mappers from "../models/mappers"; -import * as Parameters from "../models/parameters"; -import { PolicyClient } from "../policyClient"; -import { - PolicyExemption, - PolicyExemptionsListNextOptionalParams, - PolicyExemptionsListOptionalParams, - PolicyExemptionsListResponse, - PolicyExemptionsListForResourceGroupNextOptionalParams, - PolicyExemptionsListForResourceGroupOptionalParams, - PolicyExemptionsListForResourceGroupResponse, - PolicyExemptionsListForResourceNextOptionalParams, - PolicyExemptionsListForResourceOptionalParams, - PolicyExemptionsListForResourceResponse, - PolicyExemptionsListForManagementGroupNextOptionalParams, - PolicyExemptionsListForManagementGroupOptionalParams, - PolicyExemptionsListForManagementGroupResponse, - PolicyExemptionsDeleteOptionalParams, - PolicyExemptionsCreateOrUpdateOptionalParams, - PolicyExemptionsCreateOrUpdateResponse, - PolicyExemptionsGetOptionalParams, - PolicyExemptionsGetResponse, - PolicyExemptionsListNextResponse, - PolicyExemptionsListForResourceGroupNextResponse, - PolicyExemptionsListForResourceNextResponse, - PolicyExemptionsListForManagementGroupNextResponse -} from "../models"; - -/// -/** Class containing PolicyExemptions operations. */ -export class PolicyExemptionsImpl implements PolicyExemptions { - private readonly client: PolicyClient; - - /** - * Initialize a new instance of the class PolicyExemptions class. - * @param client Reference to the service client - */ - constructor(client: PolicyClient) { - this.client = client; - } - - /** - * This operation retrieves the list of all policy exemptions associated with the given subscription - * that match the optional given $filter. Valid values for $filter are: 'atScope()', 'atExactScope()', - * 'excludeExpired()' or 'policyAssignmentId eq '{value}''. If $filter is not provided, the unfiltered - * list includes all policy exemptions associated with the subscription, including those that apply - * directly or from management groups that contain the given subscription, as well as any applied to - * objects contained within the subscription. - * @param options The options parameters. - */ - public list( - options?: PolicyExemptionsListOptionalParams - ): PagedAsyncIterableIterator { - const iter = this.listPagingAll(options); - return { - next() { - return iter.next(); - }, - [Symbol.asyncIterator]() { - return this; - }, - byPage: (settings?: PageSettings) => { - if (settings?.maxPageSize) { - throw new Error("maxPageSize is not supported by this operation."); - } - return this.listPagingPage(options, settings); - } - }; - } - - private async *listPagingPage( - options?: PolicyExemptionsListOptionalParams, - settings?: PageSettings - ): AsyncIterableIterator { - let result: PolicyExemptionsListResponse; - let continuationToken = settings?.continuationToken; - if (!continuationToken) { - result = await this._list(options); - let page = result.value || []; - continuationToken = result.nextLink; - setContinuationToken(page, continuationToken); - yield page; - } - while (continuationToken) { - result = await this._listNext(continuationToken, options); - continuationToken = result.nextLink; - let page = result.value || []; - setContinuationToken(page, continuationToken); - yield page; - } - } - - private async *listPagingAll( - options?: PolicyExemptionsListOptionalParams - ): AsyncIterableIterator { - for await (const page of this.listPagingPage(options)) { - yield* page; - } - } - - /** - * This operation retrieves the list of all policy exemptions associated with the given resource group - * in the given subscription that match the optional given $filter. Valid values for $filter are: - * 'atScope()', 'atExactScope()', 'excludeExpired()' or 'policyAssignmentId eq '{value}''. If $filter - * is not provided, the unfiltered list includes all policy exemptions associated with the resource - * group, including those that apply directly or apply from containing scopes, as well as any applied - * to resources contained within the resource group. - * @param resourceGroupName The name of the resource group containing the resource. - * @param options The options parameters. - */ - public listForResourceGroup( - resourceGroupName: string, - options?: PolicyExemptionsListForResourceGroupOptionalParams - ): PagedAsyncIterableIterator { - const iter = this.listForResourceGroupPagingAll(resourceGroupName, options); - return { - next() { - return iter.next(); - }, - [Symbol.asyncIterator]() { - return this; - }, - byPage: (settings?: PageSettings) => { - if (settings?.maxPageSize) { - throw new Error("maxPageSize is not supported by this operation."); - } - return this.listForResourceGroupPagingPage( - resourceGroupName, - options, - settings - ); - } - }; - } - - private async *listForResourceGroupPagingPage( - resourceGroupName: string, - options?: PolicyExemptionsListForResourceGroupOptionalParams, - settings?: PageSettings - ): AsyncIterableIterator { - let result: PolicyExemptionsListForResourceGroupResponse; - let continuationToken = settings?.continuationToken; - if (!continuationToken) { - result = await this._listForResourceGroup(resourceGroupName, options); - let page = result.value || []; - continuationToken = result.nextLink; - setContinuationToken(page, continuationToken); - yield page; - } - while (continuationToken) { - result = await this._listForResourceGroupNext( - resourceGroupName, - continuationToken, - options - ); - continuationToken = result.nextLink; - let page = result.value || []; - setContinuationToken(page, continuationToken); - yield page; - } - } - - private async *listForResourceGroupPagingAll( - resourceGroupName: string, - options?: PolicyExemptionsListForResourceGroupOptionalParams - ): AsyncIterableIterator { - for await (const page of this.listForResourceGroupPagingPage( - resourceGroupName, - options - )) { - yield* page; - } - } - - /** - * This operation retrieves the list of all policy exemptions associated with the specified resource in - * the given resource group and subscription that match the optional given $filter. Valid values for - * $filter are: 'atScope()', 'atExactScope()', 'excludeExpired()' or 'policyAssignmentId eq '{value}''. - * If $filter is not provided, the unfiltered list includes all policy exemptions associated with the - * resource, including those that apply directly or from all containing scopes, as well as any applied - * to resources contained within the resource. Three parameters plus the resource name are used to - * identify a specific resource. If the resource is not part of a parent resource (the more common - * case), the parent resource path should not be provided (or provided as ''). For example a web app - * could be specified as ({resourceProviderNamespace} == 'Microsoft.Web', {parentResourcePath} == '', - * {resourceType} == 'sites', {resourceName} == 'MyWebApp'). If the resource is part of a parent - * resource, then all parameters should be provided. For example a virtual machine DNS name could be - * specified as ({resourceProviderNamespace} == 'Microsoft.Compute', {parentResourcePath} == - * 'virtualMachines/MyVirtualMachine', {resourceType} == 'domainNames', {resourceName} == - * 'MyComputerName'). A convenient alternative to providing the namespace and type name separately is - * to provide both in the {resourceType} parameter, format: ({resourceProviderNamespace} == '', - * {parentResourcePath} == '', {resourceType} == 'Microsoft.Web/sites', {resourceName} == 'MyWebApp'). - * @param resourceGroupName The name of the resource group containing the resource. - * @param resourceProviderNamespace The namespace of the resource provider. For example, the namespace - * of a virtual machine is Microsoft.Compute (from Microsoft.Compute/virtualMachines) - * @param parentResourcePath The parent resource path. Use empty string if there is none. - * @param resourceType The resource type name. For example the type name of a web app is 'sites' (from - * Microsoft.Web/sites). - * @param resourceName The name of the resource. - * @param options The options parameters. - */ - public listForResource( - resourceGroupName: string, - resourceProviderNamespace: string, - parentResourcePath: string, - resourceType: string, - resourceName: string, - options?: PolicyExemptionsListForResourceOptionalParams - ): PagedAsyncIterableIterator { - const iter = this.listForResourcePagingAll( - resourceGroupName, - resourceProviderNamespace, - parentResourcePath, - resourceType, - resourceName, - options - ); - return { - next() { - return iter.next(); - }, - [Symbol.asyncIterator]() { - return this; - }, - byPage: (settings?: PageSettings) => { - if (settings?.maxPageSize) { - throw new Error("maxPageSize is not supported by this operation."); - } - return this.listForResourcePagingPage( - resourceGroupName, - resourceProviderNamespace, - parentResourcePath, - resourceType, - resourceName, - options, - settings - ); - } - }; - } - - private async *listForResourcePagingPage( - resourceGroupName: string, - resourceProviderNamespace: string, - parentResourcePath: string, - resourceType: string, - resourceName: string, - options?: PolicyExemptionsListForResourceOptionalParams, - settings?: PageSettings - ): AsyncIterableIterator { - let result: PolicyExemptionsListForResourceResponse; - let continuationToken = settings?.continuationToken; - if (!continuationToken) { - result = await this._listForResource( - resourceGroupName, - resourceProviderNamespace, - parentResourcePath, - resourceType, - resourceName, - options - ); - let page = result.value || []; - continuationToken = result.nextLink; - setContinuationToken(page, continuationToken); - yield page; - } - while (continuationToken) { - result = await this._listForResourceNext( - resourceGroupName, - resourceProviderNamespace, - parentResourcePath, - resourceType, - resourceName, - continuationToken, - options - ); - continuationToken = result.nextLink; - let page = result.value || []; - setContinuationToken(page, continuationToken); - yield page; - } - } - - private async *listForResourcePagingAll( - resourceGroupName: string, - resourceProviderNamespace: string, - parentResourcePath: string, - resourceType: string, - resourceName: string, - options?: PolicyExemptionsListForResourceOptionalParams - ): AsyncIterableIterator { - for await (const page of this.listForResourcePagingPage( - resourceGroupName, - resourceProviderNamespace, - parentResourcePath, - resourceType, - resourceName, - options - )) { - yield* page; - } - } - - /** - * This operation retrieves the list of all policy exemptions applicable to the management group that - * match the given $filter. Valid values for $filter are: 'atScope()', 'atExactScope()', - * 'excludeExpired()' or 'policyAssignmentId eq '{value}''. If $filter=atScope() is provided, the - * returned list includes all policy exemptions that are assigned to the management group or the - * management group's ancestors. - * @param managementGroupId The ID of the management group. - * @param options The options parameters. - */ - public listForManagementGroup( - managementGroupId: string, - options?: PolicyExemptionsListForManagementGroupOptionalParams - ): PagedAsyncIterableIterator { - const iter = this.listForManagementGroupPagingAll( - managementGroupId, - options - ); - return { - next() { - return iter.next(); - }, - [Symbol.asyncIterator]() { - return this; - }, - byPage: (settings?: PageSettings) => { - if (settings?.maxPageSize) { - throw new Error("maxPageSize is not supported by this operation."); - } - return this.listForManagementGroupPagingPage( - managementGroupId, - options, - settings - ); - } - }; - } - - private async *listForManagementGroupPagingPage( - managementGroupId: string, - options?: PolicyExemptionsListForManagementGroupOptionalParams, - settings?: PageSettings - ): AsyncIterableIterator { - let result: PolicyExemptionsListForManagementGroupResponse; - let continuationToken = settings?.continuationToken; - if (!continuationToken) { - result = await this._listForManagementGroup(managementGroupId, options); - let page = result.value || []; - continuationToken = result.nextLink; - setContinuationToken(page, continuationToken); - yield page; - } - while (continuationToken) { - result = await this._listForManagementGroupNext( - managementGroupId, - continuationToken, - options - ); - continuationToken = result.nextLink; - let page = result.value || []; - setContinuationToken(page, continuationToken); - yield page; - } - } - - private async *listForManagementGroupPagingAll( - managementGroupId: string, - options?: PolicyExemptionsListForManagementGroupOptionalParams - ): AsyncIterableIterator { - for await (const page of this.listForManagementGroupPagingPage( - managementGroupId, - options - )) { - yield* page; - } - } - - /** - * This operation deletes a policy exemption, given its name and the scope it was created in. The scope - * of a policy exemption is the part of its ID preceding - * '/providers/Microsoft.Authorization/policyExemptions/{policyExemptionName}'. - * @param scope The scope of the policy exemption. Valid scopes are: management group (format: - * '/providers/Microsoft.Management/managementGroups/{managementGroup}'), subscription (format: - * '/subscriptions/{subscriptionId}'), resource group (format: - * '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}', or resource (format: - * '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/[{parentResourcePath}/]{resourceType}/{resourceName}' - * @param policyExemptionName The name of the policy exemption to delete. - * @param options The options parameters. - */ - delete( - scope: string, - policyExemptionName: string, - options?: PolicyExemptionsDeleteOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { scope, policyExemptionName, options }, - deleteOperationSpec - ); - } - - /** - * This operation creates or updates a policy exemption with the given scope and name. Policy - * exemptions apply to all resources contained within their scope. For example, when you create a - * policy exemption at resource group scope for a policy assignment at the same or above level, the - * exemption exempts to all applicable resources in the resource group. - * @param scope The scope of the policy exemption. Valid scopes are: management group (format: - * '/providers/Microsoft.Management/managementGroups/{managementGroup}'), subscription (format: - * '/subscriptions/{subscriptionId}'), resource group (format: - * '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}', or resource (format: - * '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/[{parentResourcePath}/]{resourceType}/{resourceName}' - * @param policyExemptionName The name of the policy exemption to delete. - * @param parameters Parameters for the policy exemption. - * @param options The options parameters. - */ - createOrUpdate( - scope: string, - policyExemptionName: string, - parameters: PolicyExemption, - options?: PolicyExemptionsCreateOrUpdateOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { scope, policyExemptionName, parameters, options }, - createOrUpdateOperationSpec - ); - } - - /** - * This operation retrieves a single policy exemption, given its name and the scope it was created at. - * @param scope The scope of the policy exemption. Valid scopes are: management group (format: - * '/providers/Microsoft.Management/managementGroups/{managementGroup}'), subscription (format: - * '/subscriptions/{subscriptionId}'), resource group (format: - * '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}', or resource (format: - * '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/[{parentResourcePath}/]{resourceType}/{resourceName}' - * @param policyExemptionName The name of the policy exemption to delete. - * @param options The options parameters. - */ - get( - scope: string, - policyExemptionName: string, - options?: PolicyExemptionsGetOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { scope, policyExemptionName, options }, - getOperationSpec - ); - } - - /** - * This operation retrieves the list of all policy exemptions associated with the given subscription - * that match the optional given $filter. Valid values for $filter are: 'atScope()', 'atExactScope()', - * 'excludeExpired()' or 'policyAssignmentId eq '{value}''. If $filter is not provided, the unfiltered - * list includes all policy exemptions associated with the subscription, including those that apply - * directly or from management groups that contain the given subscription, as well as any applied to - * objects contained within the subscription. - * @param options The options parameters. - */ - private _list( - options?: PolicyExemptionsListOptionalParams - ): Promise { - return this.client.sendOperationRequest({ options }, listOperationSpec); - } - - /** - * This operation retrieves the list of all policy exemptions associated with the given resource group - * in the given subscription that match the optional given $filter. Valid values for $filter are: - * 'atScope()', 'atExactScope()', 'excludeExpired()' or 'policyAssignmentId eq '{value}''. If $filter - * is not provided, the unfiltered list includes all policy exemptions associated with the resource - * group, including those that apply directly or apply from containing scopes, as well as any applied - * to resources contained within the resource group. - * @param resourceGroupName The name of the resource group containing the resource. - * @param options The options parameters. - */ - private _listForResourceGroup( - resourceGroupName: string, - options?: PolicyExemptionsListForResourceGroupOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, options }, - listForResourceGroupOperationSpec - ); - } - - /** - * This operation retrieves the list of all policy exemptions associated with the specified resource in - * the given resource group and subscription that match the optional given $filter. Valid values for - * $filter are: 'atScope()', 'atExactScope()', 'excludeExpired()' or 'policyAssignmentId eq '{value}''. - * If $filter is not provided, the unfiltered list includes all policy exemptions associated with the - * resource, including those that apply directly or from all containing scopes, as well as any applied - * to resources contained within the resource. Three parameters plus the resource name are used to - * identify a specific resource. If the resource is not part of a parent resource (the more common - * case), the parent resource path should not be provided (or provided as ''). For example a web app - * could be specified as ({resourceProviderNamespace} == 'Microsoft.Web', {parentResourcePath} == '', - * {resourceType} == 'sites', {resourceName} == 'MyWebApp'). If the resource is part of a parent - * resource, then all parameters should be provided. For example a virtual machine DNS name could be - * specified as ({resourceProviderNamespace} == 'Microsoft.Compute', {parentResourcePath} == - * 'virtualMachines/MyVirtualMachine', {resourceType} == 'domainNames', {resourceName} == - * 'MyComputerName'). A convenient alternative to providing the namespace and type name separately is - * to provide both in the {resourceType} parameter, format: ({resourceProviderNamespace} == '', - * {parentResourcePath} == '', {resourceType} == 'Microsoft.Web/sites', {resourceName} == 'MyWebApp'). - * @param resourceGroupName The name of the resource group containing the resource. - * @param resourceProviderNamespace The namespace of the resource provider. For example, the namespace - * of a virtual machine is Microsoft.Compute (from Microsoft.Compute/virtualMachines) - * @param parentResourcePath The parent resource path. Use empty string if there is none. - * @param resourceType The resource type name. For example the type name of a web app is 'sites' (from - * Microsoft.Web/sites). - * @param resourceName The name of the resource. - * @param options The options parameters. - */ - private _listForResource( - resourceGroupName: string, - resourceProviderNamespace: string, - parentResourcePath: string, - resourceType: string, - resourceName: string, - options?: PolicyExemptionsListForResourceOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { - resourceGroupName, - resourceProviderNamespace, - parentResourcePath, - resourceType, - resourceName, - options - }, - listForResourceOperationSpec - ); - } - - /** - * This operation retrieves the list of all policy exemptions applicable to the management group that - * match the given $filter. Valid values for $filter are: 'atScope()', 'atExactScope()', - * 'excludeExpired()' or 'policyAssignmentId eq '{value}''. If $filter=atScope() is provided, the - * returned list includes all policy exemptions that are assigned to the management group or the - * management group's ancestors. - * @param managementGroupId The ID of the management group. - * @param options The options parameters. - */ - private _listForManagementGroup( - managementGroupId: string, - options?: PolicyExemptionsListForManagementGroupOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { managementGroupId, options }, - listForManagementGroupOperationSpec - ); - } - - /** - * ListNext - * @param nextLink The nextLink from the previous successful call to the List method. - * @param options The options parameters. - */ - private _listNext( - nextLink: string, - options?: PolicyExemptionsListNextOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { nextLink, options }, - listNextOperationSpec - ); - } - - /** - * ListForResourceGroupNext - * @param resourceGroupName The name of the resource group containing the resource. - * @param nextLink The nextLink from the previous successful call to the ListForResourceGroup method. - * @param options The options parameters. - */ - private _listForResourceGroupNext( - resourceGroupName: string, - nextLink: string, - options?: PolicyExemptionsListForResourceGroupNextOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, nextLink, options }, - listForResourceGroupNextOperationSpec - ); - } - - /** - * ListForResourceNext - * @param resourceGroupName The name of the resource group containing the resource. - * @param resourceProviderNamespace The namespace of the resource provider. For example, the namespace - * of a virtual machine is Microsoft.Compute (from Microsoft.Compute/virtualMachines) - * @param parentResourcePath The parent resource path. Use empty string if there is none. - * @param resourceType The resource type name. For example the type name of a web app is 'sites' (from - * Microsoft.Web/sites). - * @param resourceName The name of the resource. - * @param nextLink The nextLink from the previous successful call to the ListForResource method. - * @param options The options parameters. - */ - private _listForResourceNext( - resourceGroupName: string, - resourceProviderNamespace: string, - parentResourcePath: string, - resourceType: string, - resourceName: string, - nextLink: string, - options?: PolicyExemptionsListForResourceNextOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { - resourceGroupName, - resourceProviderNamespace, - parentResourcePath, - resourceType, - resourceName, - nextLink, - options - }, - listForResourceNextOperationSpec - ); - } - - /** - * ListForManagementGroupNext - * @param managementGroupId The ID of the management group. - * @param nextLink The nextLink from the previous successful call to the ListForManagementGroup method. - * @param options The options parameters. - */ - private _listForManagementGroupNext( - managementGroupId: string, - nextLink: string, - options?: PolicyExemptionsListForManagementGroupNextOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { managementGroupId, nextLink, options }, - listForManagementGroupNextOperationSpec - ); - } -} -// Operation Specifications -const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); - -const deleteOperationSpec: coreClient.OperationSpec = { - path: - "/{scope}/providers/Microsoft.Authorization/policyExemptions/{policyExemptionName}", - httpMethod: "DELETE", - responses: { - 200: {}, - 204: {}, - default: { - bodyMapper: Mappers.CloudError - } - }, - queryParameters: [Parameters.apiVersion2], - urlParameters: [ - Parameters.$host, - Parameters.scope, - Parameters.policyExemptionName - ], - headerParameters: [Parameters.accept], - serializer -}; -const createOrUpdateOperationSpec: coreClient.OperationSpec = { - path: - "/{scope}/providers/Microsoft.Authorization/policyExemptions/{policyExemptionName}", - httpMethod: "PUT", - responses: { - 200: { - bodyMapper: Mappers.PolicyExemption - }, - 201: { - bodyMapper: Mappers.PolicyExemption - }, - default: { - bodyMapper: Mappers.CloudError - } - }, - requestBody: Parameters.parameters4, - queryParameters: [Parameters.apiVersion2], - urlParameters: [ - Parameters.$host, - Parameters.scope, - Parameters.policyExemptionName - ], - headerParameters: [Parameters.accept, Parameters.contentType], - mediaType: "json", - serializer -}; -const getOperationSpec: coreClient.OperationSpec = { - path: - "/{scope}/providers/Microsoft.Authorization/policyExemptions/{policyExemptionName}", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.PolicyExemption - }, - default: { - bodyMapper: Mappers.CloudError - } - }, - queryParameters: [Parameters.apiVersion2], - urlParameters: [ - Parameters.$host, - Parameters.scope, - Parameters.policyExemptionName - ], - headerParameters: [Parameters.accept], - serializer -}; -const listOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/providers/Microsoft.Authorization/policyExemptions", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.PolicyExemptionListResult - }, - default: { - bodyMapper: Mappers.CloudError - } - }, - queryParameters: [Parameters.filter, Parameters.apiVersion2], - urlParameters: [Parameters.$host, Parameters.subscriptionId], - headerParameters: [Parameters.accept], - serializer -}; -const listForResourceGroupOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Authorization/policyExemptions", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.PolicyExemptionListResult - }, - default: { - bodyMapper: Mappers.CloudError - } - }, - queryParameters: [Parameters.filter, Parameters.apiVersion2], - urlParameters: [ - Parameters.$host, - Parameters.resourceGroupName, - Parameters.subscriptionId - ], - headerParameters: [Parameters.accept], - serializer -}; -const listForResourceOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{parentResourcePath}/{resourceType}/{resourceName}/providers/Microsoft.Authorization/policyExemptions", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.PolicyExemptionListResult - }, - default: { - bodyMapper: Mappers.CloudError - } - }, - queryParameters: [Parameters.filter, Parameters.apiVersion2], - urlParameters: [ - Parameters.$host, - Parameters.resourceGroupName, - Parameters.subscriptionId, - Parameters.resourceProviderNamespace, - Parameters.parentResourcePath, - Parameters.resourceType, - Parameters.resourceName - ], - headerParameters: [Parameters.accept], - serializer -}; -const listForManagementGroupOperationSpec: coreClient.OperationSpec = { - path: - "/providers/Microsoft.Management/managementGroups/{managementGroupId}/providers/Microsoft.Authorization/policyExemptions", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.PolicyExemptionListResult - }, - default: { - bodyMapper: Mappers.CloudError - } - }, - queryParameters: [Parameters.filter, Parameters.apiVersion2], - urlParameters: [Parameters.$host, Parameters.managementGroupId], - headerParameters: [Parameters.accept], - serializer -}; -const listNextOperationSpec: coreClient.OperationSpec = { - path: "{nextLink}", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.PolicyExemptionListResult - }, - default: { - bodyMapper: Mappers.CloudError - } - }, - urlParameters: [ - Parameters.$host, - Parameters.nextLink, - Parameters.subscriptionId - ], - headerParameters: [Parameters.accept], - serializer -}; -const listForResourceGroupNextOperationSpec: coreClient.OperationSpec = { - path: "{nextLink}", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.PolicyExemptionListResult - }, - default: { - bodyMapper: Mappers.CloudError - } - }, - urlParameters: [ - Parameters.$host, - Parameters.nextLink, - Parameters.resourceGroupName, - Parameters.subscriptionId - ], - headerParameters: [Parameters.accept], - serializer -}; -const listForResourceNextOperationSpec: coreClient.OperationSpec = { - path: "{nextLink}", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.PolicyExemptionListResult - }, - default: { - bodyMapper: Mappers.CloudError - } - }, - urlParameters: [ - Parameters.$host, - Parameters.nextLink, - Parameters.resourceGroupName, - Parameters.subscriptionId, - Parameters.resourceProviderNamespace, - Parameters.parentResourcePath, - Parameters.resourceType, - Parameters.resourceName - ], - headerParameters: [Parameters.accept], - serializer -}; -const listForManagementGroupNextOperationSpec: coreClient.OperationSpec = { - path: "{nextLink}", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.PolicyExemptionListResult - }, - default: { - bodyMapper: Mappers.CloudError - } - }, - urlParameters: [ - Parameters.$host, - Parameters.nextLink, - Parameters.managementGroupId - ], - headerParameters: [Parameters.accept], - serializer -}; diff --git a/sdk/policy/arm-policy/src/operations/policySetDefinitionVersions.ts b/sdk/policy/arm-policy/src/operations/policySetDefinitionVersions.ts new file mode 100644 index 000000000000..3140bea9f69d --- /dev/null +++ b/sdk/policy/arm-policy/src/operations/policySetDefinitionVersions.ts @@ -0,0 +1,907 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +import { PagedAsyncIterableIterator, PageSettings } from "@azure/core-paging"; +import { setContinuationToken } from "../pagingHelper"; +import { PolicySetDefinitionVersions } from "../operationsInterfaces"; +import * as coreClient from "@azure/core-client"; +import * as Mappers from "../models/mappers"; +import * as Parameters from "../models/parameters"; +import { PolicyClient } from "../policyClient"; +import { + PolicySetDefinitionVersion, + PolicySetDefinitionVersionsListNextOptionalParams, + PolicySetDefinitionVersionsListOptionalParams, + PolicySetDefinitionVersionsListResponse, + PolicySetDefinitionVersionsListBuiltInNextOptionalParams, + PolicySetDefinitionVersionsListBuiltInOptionalParams, + PolicySetDefinitionVersionsListBuiltInResponse, + PolicySetDefinitionVersionsListByManagementGroupNextOptionalParams, + PolicySetDefinitionVersionsListByManagementGroupOptionalParams, + PolicySetDefinitionVersionsListByManagementGroupResponse, + PolicySetDefinitionVersionsListAllBuiltinsOptionalParams, + PolicySetDefinitionVersionsListAllBuiltinsResponse, + PolicySetDefinitionVersionsListAllAtManagementGroupOptionalParams, + PolicySetDefinitionVersionsListAllAtManagementGroupResponse, + PolicySetDefinitionVersionsListAllOptionalParams, + PolicySetDefinitionVersionsListAllResponse, + PolicySetDefinitionVersionsCreateOrUpdateOptionalParams, + PolicySetDefinitionVersionsCreateOrUpdateResponse, + PolicySetDefinitionVersionsDeleteOptionalParams, + PolicySetDefinitionVersionsGetOptionalParams, + PolicySetDefinitionVersionsGetResponse, + PolicySetDefinitionVersionsGetBuiltInOptionalParams, + PolicySetDefinitionVersionsGetBuiltInResponse, + PolicySetDefinitionVersionsCreateOrUpdateAtManagementGroupOptionalParams, + PolicySetDefinitionVersionsCreateOrUpdateAtManagementGroupResponse, + PolicySetDefinitionVersionsDeleteAtManagementGroupOptionalParams, + PolicySetDefinitionVersionsGetAtManagementGroupOptionalParams, + PolicySetDefinitionVersionsGetAtManagementGroupResponse, + PolicySetDefinitionVersionsListNextResponse, + PolicySetDefinitionVersionsListBuiltInNextResponse, + PolicySetDefinitionVersionsListByManagementGroupNextResponse, +} from "../models"; + +/// +/** Class containing PolicySetDefinitionVersions operations. */ +export class PolicySetDefinitionVersionsImpl + implements PolicySetDefinitionVersions +{ + private readonly client: PolicyClient; + + /** + * Initialize a new instance of the class PolicySetDefinitionVersions class. + * @param client Reference to the service client + */ + constructor(client: PolicyClient) { + this.client = client; + } + + /** + * This operation retrieves a list of all the policy set definition versions for the given policy set + * definition. + * @param policySetDefinitionName The name of the policy set definition. + * @param options The options parameters. + */ + public list( + policySetDefinitionName: string, + options?: PolicySetDefinitionVersionsListOptionalParams, + ): PagedAsyncIterableIterator { + const iter = this.listPagingAll(policySetDefinitionName, options); + return { + next() { + return iter.next(); + }, + [Symbol.asyncIterator]() { + return this; + }, + byPage: (settings?: PageSettings) => { + if (settings?.maxPageSize) { + throw new Error("maxPageSize is not supported by this operation."); + } + return this.listPagingPage(policySetDefinitionName, options, settings); + }, + }; + } + + private async *listPagingPage( + policySetDefinitionName: string, + options?: PolicySetDefinitionVersionsListOptionalParams, + settings?: PageSettings, + ): AsyncIterableIterator { + let result: PolicySetDefinitionVersionsListResponse; + let continuationToken = settings?.continuationToken; + if (!continuationToken) { + result = await this._list(policySetDefinitionName, options); + let page = result.value || []; + continuationToken = result.nextLink; + setContinuationToken(page, continuationToken); + yield page; + } + while (continuationToken) { + result = await this._listNext( + policySetDefinitionName, + continuationToken, + options, + ); + continuationToken = result.nextLink; + let page = result.value || []; + setContinuationToken(page, continuationToken); + yield page; + } + } + + private async *listPagingAll( + policySetDefinitionName: string, + options?: PolicySetDefinitionVersionsListOptionalParams, + ): AsyncIterableIterator { + for await (const page of this.listPagingPage( + policySetDefinitionName, + options, + )) { + yield* page; + } + } + + /** + * This operation retrieves a list of all the built-in policy set definition versions for the given + * built-in policy set definition. + * @param policySetDefinitionName The name of the policy set definition. + * @param options The options parameters. + */ + public listBuiltIn( + policySetDefinitionName: string, + options?: PolicySetDefinitionVersionsListBuiltInOptionalParams, + ): PagedAsyncIterableIterator { + const iter = this.listBuiltInPagingAll(policySetDefinitionName, options); + return { + next() { + return iter.next(); + }, + [Symbol.asyncIterator]() { + return this; + }, + byPage: (settings?: PageSettings) => { + if (settings?.maxPageSize) { + throw new Error("maxPageSize is not supported by this operation."); + } + return this.listBuiltInPagingPage( + policySetDefinitionName, + options, + settings, + ); + }, + }; + } + + private async *listBuiltInPagingPage( + policySetDefinitionName: string, + options?: PolicySetDefinitionVersionsListBuiltInOptionalParams, + settings?: PageSettings, + ): AsyncIterableIterator { + let result: PolicySetDefinitionVersionsListBuiltInResponse; + let continuationToken = settings?.continuationToken; + if (!continuationToken) { + result = await this._listBuiltIn(policySetDefinitionName, options); + let page = result.value || []; + continuationToken = result.nextLink; + setContinuationToken(page, continuationToken); + yield page; + } + while (continuationToken) { + result = await this._listBuiltInNext( + policySetDefinitionName, + continuationToken, + options, + ); + continuationToken = result.nextLink; + let page = result.value || []; + setContinuationToken(page, continuationToken); + yield page; + } + } + + private async *listBuiltInPagingAll( + policySetDefinitionName: string, + options?: PolicySetDefinitionVersionsListBuiltInOptionalParams, + ): AsyncIterableIterator { + for await (const page of this.listBuiltInPagingPage( + policySetDefinitionName, + options, + )) { + yield* page; + } + } + + /** + * This operation retrieves a list of all the policy set definition versions for the given policy set + * definition in a given management group. + * @param managementGroupName The name of the management group. The name is case insensitive. + * @param policySetDefinitionName The name of the policy set definition. + * @param options The options parameters. + */ + public listByManagementGroup( + managementGroupName: string, + policySetDefinitionName: string, + options?: PolicySetDefinitionVersionsListByManagementGroupOptionalParams, + ): PagedAsyncIterableIterator { + const iter = this.listByManagementGroupPagingAll( + managementGroupName, + policySetDefinitionName, + options, + ); + return { + next() { + return iter.next(); + }, + [Symbol.asyncIterator]() { + return this; + }, + byPage: (settings?: PageSettings) => { + if (settings?.maxPageSize) { + throw new Error("maxPageSize is not supported by this operation."); + } + return this.listByManagementGroupPagingPage( + managementGroupName, + policySetDefinitionName, + options, + settings, + ); + }, + }; + } + + private async *listByManagementGroupPagingPage( + managementGroupName: string, + policySetDefinitionName: string, + options?: PolicySetDefinitionVersionsListByManagementGroupOptionalParams, + settings?: PageSettings, + ): AsyncIterableIterator { + let result: PolicySetDefinitionVersionsListByManagementGroupResponse; + let continuationToken = settings?.continuationToken; + if (!continuationToken) { + result = await this._listByManagementGroup( + managementGroupName, + policySetDefinitionName, + options, + ); + let page = result.value || []; + continuationToken = result.nextLink; + setContinuationToken(page, continuationToken); + yield page; + } + while (continuationToken) { + result = await this._listByManagementGroupNext( + managementGroupName, + policySetDefinitionName, + continuationToken, + options, + ); + continuationToken = result.nextLink; + let page = result.value || []; + setContinuationToken(page, continuationToken); + yield page; + } + } + + private async *listByManagementGroupPagingAll( + managementGroupName: string, + policySetDefinitionName: string, + options?: PolicySetDefinitionVersionsListByManagementGroupOptionalParams, + ): AsyncIterableIterator { + for await (const page of this.listByManagementGroupPagingPage( + managementGroupName, + policySetDefinitionName, + options, + )) { + yield* page; + } + } + + /** + * This operation lists all the built-in policy set definition versions for all built-in policy set + * definitions. + * @param options The options parameters. + */ + listAllBuiltins( + options?: PolicySetDefinitionVersionsListAllBuiltinsOptionalParams, + ): Promise { + return this.client.sendOperationRequest( + { options }, + listAllBuiltinsOperationSpec, + ); + } + + /** + * This operation lists all the policy set definition versions for all policy set definitions at the + * management group scope. + * @param managementGroupName The name of the management group. The name is case insensitive. + * @param options The options parameters. + */ + listAllAtManagementGroup( + managementGroupName: string, + options?: PolicySetDefinitionVersionsListAllAtManagementGroupOptionalParams, + ): Promise { + return this.client.sendOperationRequest( + { managementGroupName, options }, + listAllAtManagementGroupOperationSpec, + ); + } + + /** + * This operation lists all the policy set definition versions for all policy set definitions within a + * subscription. + * @param options The options parameters. + */ + listAll( + options?: PolicySetDefinitionVersionsListAllOptionalParams, + ): Promise { + return this.client.sendOperationRequest({ options }, listAllOperationSpec); + } + + /** + * This operation creates or updates a policy set definition version in the given subscription with the + * given name and version. + * @param policySetDefinitionName The name of the policy set definition. + * @param policyDefinitionVersion The policy set definition version. The format is x.y.z where x is + * the major version number, y is the minor version number, and z is the patch number + * @param parameters The policy set definition properties. + * @param options The options parameters. + */ + createOrUpdate( + policySetDefinitionName: string, + policyDefinitionVersion: string, + parameters: PolicySetDefinitionVersion, + options?: PolicySetDefinitionVersionsCreateOrUpdateOptionalParams, + ): Promise { + return this.client.sendOperationRequest( + { policySetDefinitionName, policyDefinitionVersion, parameters, options }, + createOrUpdateOperationSpec, + ); + } + + /** + * This operation deletes the policy set definition version in the given subscription with the given + * name and version. + * @param policySetDefinitionName The name of the policy set definition. + * @param policyDefinitionVersion The policy set definition version. The format is x.y.z where x is + * the major version number, y is the minor version number, and z is the patch number + * @param options The options parameters. + */ + delete( + policySetDefinitionName: string, + policyDefinitionVersion: string, + options?: PolicySetDefinitionVersionsDeleteOptionalParams, + ): Promise { + return this.client.sendOperationRequest( + { policySetDefinitionName, policyDefinitionVersion, options }, + deleteOperationSpec, + ); + } + + /** + * This operation retrieves the policy set definition version in the given subscription with the given + * name and version. + * @param policySetDefinitionName The name of the policy set definition. + * @param policyDefinitionVersion The policy set definition version. The format is x.y.z where x is + * the major version number, y is the minor version number, and z is the patch number + * @param options The options parameters. + */ + get( + policySetDefinitionName: string, + policyDefinitionVersion: string, + options?: PolicySetDefinitionVersionsGetOptionalParams, + ): Promise { + return this.client.sendOperationRequest( + { policySetDefinitionName, policyDefinitionVersion, options }, + getOperationSpec, + ); + } + + /** + * This operation retrieves the built-in policy set definition version with the given name and version. + * @param policySetDefinitionName The name of the policy set definition. + * @param policyDefinitionVersion The policy set definition version. The format is x.y.z where x is + * the major version number, y is the minor version number, and z is the patch number + * @param options The options parameters. + */ + getBuiltIn( + policySetDefinitionName: string, + policyDefinitionVersion: string, + options?: PolicySetDefinitionVersionsGetBuiltInOptionalParams, + ): Promise { + return this.client.sendOperationRequest( + { policySetDefinitionName, policyDefinitionVersion, options }, + getBuiltInOperationSpec, + ); + } + + /** + * This operation retrieves a list of all the policy set definition versions for the given policy set + * definition. + * @param policySetDefinitionName The name of the policy set definition. + * @param options The options parameters. + */ + private _list( + policySetDefinitionName: string, + options?: PolicySetDefinitionVersionsListOptionalParams, + ): Promise { + return this.client.sendOperationRequest( + { policySetDefinitionName, options }, + listOperationSpec, + ); + } + + /** + * This operation retrieves a list of all the built-in policy set definition versions for the given + * built-in policy set definition. + * @param policySetDefinitionName The name of the policy set definition. + * @param options The options parameters. + */ + private _listBuiltIn( + policySetDefinitionName: string, + options?: PolicySetDefinitionVersionsListBuiltInOptionalParams, + ): Promise { + return this.client.sendOperationRequest( + { policySetDefinitionName, options }, + listBuiltInOperationSpec, + ); + } + + /** + * This operation creates or updates a policy set definition version in the given management group with + * the given name and version. + * @param managementGroupName The name of the management group. The name is case insensitive. + * @param policySetDefinitionName The name of the policy set definition. + * @param policyDefinitionVersion The policy set definition version. The format is x.y.z where x is + * the major version number, y is the minor version number, and z is the patch number + * @param parameters The policy set definition version properties. + * @param options The options parameters. + */ + createOrUpdateAtManagementGroup( + managementGroupName: string, + policySetDefinitionName: string, + policyDefinitionVersion: string, + parameters: PolicySetDefinitionVersion, + options?: PolicySetDefinitionVersionsCreateOrUpdateAtManagementGroupOptionalParams, + ): Promise { + return this.client.sendOperationRequest( + { + managementGroupName, + policySetDefinitionName, + policyDefinitionVersion, + parameters, + options, + }, + createOrUpdateAtManagementGroupOperationSpec, + ); + } + + /** + * This operation deletes the policy set definition version in the given management group with the + * given name and version. + * @param managementGroupName The name of the management group. The name is case insensitive. + * @param policySetDefinitionName The name of the policy set definition. + * @param policyDefinitionVersion The policy set definition version. The format is x.y.z where x is + * the major version number, y is the minor version number, and z is the patch number + * @param options The options parameters. + */ + deleteAtManagementGroup( + managementGroupName: string, + policySetDefinitionName: string, + policyDefinitionVersion: string, + options?: PolicySetDefinitionVersionsDeleteAtManagementGroupOptionalParams, + ): Promise { + return this.client.sendOperationRequest( + { + managementGroupName, + policySetDefinitionName, + policyDefinitionVersion, + options, + }, + deleteAtManagementGroupOperationSpec, + ); + } + + /** + * This operation retrieves the policy set definition version in the given management group with the + * given name and version. + * @param managementGroupName The name of the management group. The name is case insensitive. + * @param policySetDefinitionName The name of the policy set definition. + * @param policyDefinitionVersion The policy set definition version. The format is x.y.z where x is + * the major version number, y is the minor version number, and z is the patch number + * @param options The options parameters. + */ + getAtManagementGroup( + managementGroupName: string, + policySetDefinitionName: string, + policyDefinitionVersion: string, + options?: PolicySetDefinitionVersionsGetAtManagementGroupOptionalParams, + ): Promise { + return this.client.sendOperationRequest( + { + managementGroupName, + policySetDefinitionName, + policyDefinitionVersion, + options, + }, + getAtManagementGroupOperationSpec, + ); + } + + /** + * This operation retrieves a list of all the policy set definition versions for the given policy set + * definition in a given management group. + * @param managementGroupName The name of the management group. The name is case insensitive. + * @param policySetDefinitionName The name of the policy set definition. + * @param options The options parameters. + */ + private _listByManagementGroup( + managementGroupName: string, + policySetDefinitionName: string, + options?: PolicySetDefinitionVersionsListByManagementGroupOptionalParams, + ): Promise { + return this.client.sendOperationRequest( + { managementGroupName, policySetDefinitionName, options }, + listByManagementGroupOperationSpec, + ); + } + + /** + * ListNext + * @param policySetDefinitionName The name of the policy set definition. + * @param nextLink The nextLink from the previous successful call to the List method. + * @param options The options parameters. + */ + private _listNext( + policySetDefinitionName: string, + nextLink: string, + options?: PolicySetDefinitionVersionsListNextOptionalParams, + ): Promise { + return this.client.sendOperationRequest( + { policySetDefinitionName, nextLink, options }, + listNextOperationSpec, + ); + } + + /** + * ListBuiltInNext + * @param policySetDefinitionName The name of the policy set definition. + * @param nextLink The nextLink from the previous successful call to the ListBuiltIn method. + * @param options The options parameters. + */ + private _listBuiltInNext( + policySetDefinitionName: string, + nextLink: string, + options?: PolicySetDefinitionVersionsListBuiltInNextOptionalParams, + ): Promise { + return this.client.sendOperationRequest( + { policySetDefinitionName, nextLink, options }, + listBuiltInNextOperationSpec, + ); + } + + /** + * ListByManagementGroupNext + * @param managementGroupName The name of the management group. The name is case insensitive. + * @param policySetDefinitionName The name of the policy set definition. + * @param nextLink The nextLink from the previous successful call to the ListByManagementGroup method. + * @param options The options parameters. + */ + private _listByManagementGroupNext( + managementGroupName: string, + policySetDefinitionName: string, + nextLink: string, + options?: PolicySetDefinitionVersionsListByManagementGroupNextOptionalParams, + ): Promise { + return this.client.sendOperationRequest( + { managementGroupName, policySetDefinitionName, nextLink, options }, + listByManagementGroupNextOperationSpec, + ); + } +} +// Operation Specifications +const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); + +const listAllBuiltinsOperationSpec: coreClient.OperationSpec = { + path: "/providers/Microsoft.Authorization/listPolicySetDefinitionVersions", + httpMethod: "POST", + responses: { + 200: { + bodyMapper: Mappers.PolicySetDefinitionVersionListResult, + }, + default: { + bodyMapper: Mappers.CloudError, + }, + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [Parameters.$host], + headerParameters: [Parameters.accept], + serializer, +}; +const listAllAtManagementGroupOperationSpec: coreClient.OperationSpec = { + path: "/providers/Microsoft.Management/managementGroups/{managementGroupName}/providers/Microsoft.Authorization/listPolicySetDefinitionVersions", + httpMethod: "POST", + responses: { + 200: { + bodyMapper: Mappers.PolicySetDefinitionVersionListResult, + }, + default: { + bodyMapper: Mappers.CloudError, + }, + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [Parameters.$host, Parameters.managementGroupName], + headerParameters: [Parameters.accept], + serializer, +}; +const listAllOperationSpec: coreClient.OperationSpec = { + path: "/subscriptions/{subscriptionId}/providers/Microsoft.Authorization/listPolicySetDefinitionVersions", + httpMethod: "POST", + responses: { + 200: { + bodyMapper: Mappers.PolicySetDefinitionVersionListResult, + }, + default: { + bodyMapper: Mappers.CloudError, + }, + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [Parameters.$host, Parameters.subscriptionId], + headerParameters: [Parameters.accept], + serializer, +}; +const createOrUpdateOperationSpec: coreClient.OperationSpec = { + path: "/subscriptions/{subscriptionId}/providers/Microsoft.Authorization/policySetDefinitions/{policySetDefinitionName}/versions/{policyDefinitionVersion}", + httpMethod: "PUT", + responses: { + 200: { + bodyMapper: Mappers.PolicySetDefinitionVersion, + }, + 201: { + bodyMapper: Mappers.PolicySetDefinitionVersion, + }, + default: { + bodyMapper: Mappers.CloudError, + }, + }, + requestBody: Parameters.parameters3, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.policyDefinitionVersion, + Parameters.policySetDefinitionName, + ], + headerParameters: [Parameters.contentType, Parameters.accept], + mediaType: "json", + serializer, +}; +const deleteOperationSpec: coreClient.OperationSpec = { + path: "/subscriptions/{subscriptionId}/providers/Microsoft.Authorization/policySetDefinitions/{policySetDefinitionName}/versions/{policyDefinitionVersion}", + httpMethod: "DELETE", + responses: { + 200: {}, + 204: {}, + default: { + bodyMapper: Mappers.CloudError, + }, + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.policyDefinitionVersion, + Parameters.policySetDefinitionName, + ], + headerParameters: [Parameters.accept], + serializer, +}; +const getOperationSpec: coreClient.OperationSpec = { + path: "/subscriptions/{subscriptionId}/providers/Microsoft.Authorization/policySetDefinitions/{policySetDefinitionName}/versions/{policyDefinitionVersion}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.PolicySetDefinitionVersion, + }, + default: { + bodyMapper: Mappers.CloudError, + }, + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.policyDefinitionVersion, + Parameters.policySetDefinitionName, + ], + headerParameters: [Parameters.accept], + serializer, +}; +const getBuiltInOperationSpec: coreClient.OperationSpec = { + path: "/providers/Microsoft.Authorization/policySetDefinitions/{policySetDefinitionName}/versions/{policyDefinitionVersion}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.PolicySetDefinitionVersion, + }, + default: { + bodyMapper: Mappers.CloudError, + }, + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.policyDefinitionVersion, + Parameters.policySetDefinitionName, + ], + headerParameters: [Parameters.accept], + serializer, +}; +const listOperationSpec: coreClient.OperationSpec = { + path: "/subscriptions/{subscriptionId}/providers/Microsoft.Authorization/policySetDefinitions/{policySetDefinitionName}/versions", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.PolicySetDefinitionVersionListResult, + }, + default: { + bodyMapper: Mappers.CloudError, + }, + }, + queryParameters: [Parameters.apiVersion, Parameters.top], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.policySetDefinitionName, + ], + headerParameters: [Parameters.accept], + serializer, +}; +const listBuiltInOperationSpec: coreClient.OperationSpec = { + path: "/providers/Microsoft.Authorization/policySetDefinitions/{policySetDefinitionName}/versions", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.PolicySetDefinitionVersionListResult, + }, + default: { + bodyMapper: Mappers.CloudError, + }, + }, + queryParameters: [Parameters.apiVersion, Parameters.top], + urlParameters: [Parameters.$host, Parameters.policySetDefinitionName], + headerParameters: [Parameters.accept], + serializer, +}; +const createOrUpdateAtManagementGroupOperationSpec: coreClient.OperationSpec = { + path: "/providers/Microsoft.Management/managementGroups/{managementGroupName}/providers/Microsoft.Authorization/policySetDefinitions/{policySetDefinitionName}/versions/{policyDefinitionVersion}", + httpMethod: "PUT", + responses: { + 200: { + bodyMapper: Mappers.PolicySetDefinitionVersion, + }, + 201: { + bodyMapper: Mappers.PolicySetDefinitionVersion, + }, + default: { + bodyMapper: Mappers.CloudError, + }, + }, + requestBody: Parameters.parameters3, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.managementGroupName, + Parameters.policyDefinitionVersion, + Parameters.policySetDefinitionName, + ], + headerParameters: [Parameters.contentType, Parameters.accept], + mediaType: "json", + serializer, +}; +const deleteAtManagementGroupOperationSpec: coreClient.OperationSpec = { + path: "/providers/Microsoft.Management/managementGroups/{managementGroupName}/providers/Microsoft.Authorization/policySetDefinitions/{policySetDefinitionName}/versions/{policyDefinitionVersion}", + httpMethod: "DELETE", + responses: { + 200: {}, + 204: {}, + default: { + bodyMapper: Mappers.CloudError, + }, + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.managementGroupName, + Parameters.policyDefinitionVersion, + Parameters.policySetDefinitionName, + ], + headerParameters: [Parameters.accept], + serializer, +}; +const getAtManagementGroupOperationSpec: coreClient.OperationSpec = { + path: "/providers/Microsoft.Management/managementGroups/{managementGroupName}/providers/Microsoft.Authorization/policySetDefinitions/{policySetDefinitionName}/versions/{policyDefinitionVersion}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.PolicySetDefinitionVersion, + }, + default: { + bodyMapper: Mappers.CloudError, + }, + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.managementGroupName, + Parameters.policyDefinitionVersion, + Parameters.policySetDefinitionName, + ], + headerParameters: [Parameters.accept], + serializer, +}; +const listByManagementGroupOperationSpec: coreClient.OperationSpec = { + path: "/providers/Microsoft.Management/managementGroups/{managementGroupName}/providers/Microsoft.Authorization/policySetDefinitions/{policySetDefinitionName}/versions", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.PolicySetDefinitionVersionListResult, + }, + default: { + bodyMapper: Mappers.CloudError, + }, + }, + queryParameters: [Parameters.apiVersion, Parameters.top], + urlParameters: [ + Parameters.$host, + Parameters.managementGroupName, + Parameters.policySetDefinitionName, + ], + headerParameters: [Parameters.accept], + serializer, +}; +const listNextOperationSpec: coreClient.OperationSpec = { + path: "{nextLink}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.PolicySetDefinitionVersionListResult, + }, + default: { + bodyMapper: Mappers.CloudError, + }, + }, + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.nextLink, + Parameters.policySetDefinitionName, + ], + headerParameters: [Parameters.accept], + serializer, +}; +const listBuiltInNextOperationSpec: coreClient.OperationSpec = { + path: "{nextLink}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.PolicySetDefinitionVersionListResult, + }, + default: { + bodyMapper: Mappers.CloudError, + }, + }, + urlParameters: [ + Parameters.$host, + Parameters.nextLink, + Parameters.policySetDefinitionName, + ], + headerParameters: [Parameters.accept], + serializer, +}; +const listByManagementGroupNextOperationSpec: coreClient.OperationSpec = { + path: "{nextLink}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.PolicySetDefinitionVersionListResult, + }, + default: { + bodyMapper: Mappers.CloudError, + }, + }, + urlParameters: [ + Parameters.$host, + Parameters.nextLink, + Parameters.managementGroupName, + Parameters.policySetDefinitionName, + ], + headerParameters: [Parameters.accept], + serializer, +}; diff --git a/sdk/policy/arm-policy/src/operations/policySetDefinitions.ts b/sdk/policy/arm-policy/src/operations/policySetDefinitions.ts index 0a2a26cd3d2d..586452b68748 100644 --- a/sdk/policy/arm-policy/src/operations/policySetDefinitions.ts +++ b/sdk/policy/arm-policy/src/operations/policySetDefinitions.ts @@ -38,7 +38,7 @@ import { PolicySetDefinitionsGetAtManagementGroupResponse, PolicySetDefinitionsListNextResponse, PolicySetDefinitionsListBuiltInNextResponse, - PolicySetDefinitionsListByManagementGroupNextResponse + PolicySetDefinitionsListByManagementGroupNextResponse, } from "../models"; /// @@ -68,7 +68,7 @@ export class PolicySetDefinitionsImpl implements PolicySetDefinitions { * @param options The options parameters. */ public list( - options?: PolicySetDefinitionsListOptionalParams + options?: PolicySetDefinitionsListOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listPagingAll(options); return { @@ -83,13 +83,13 @@ export class PolicySetDefinitionsImpl implements PolicySetDefinitions { throw new Error("maxPageSize is not supported by this operation."); } return this.listPagingPage(options, settings); - } + }, }; } private async *listPagingPage( options?: PolicySetDefinitionsListOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: PolicySetDefinitionsListResponse; let continuationToken = settings?.continuationToken; @@ -110,7 +110,7 @@ export class PolicySetDefinitionsImpl implements PolicySetDefinitions { } private async *listPagingAll( - options?: PolicySetDefinitionsListOptionalParams + options?: PolicySetDefinitionsListOptionalParams, ): AsyncIterableIterator { for await (const page of this.listPagingPage(options)) { yield* page; @@ -124,7 +124,7 @@ export class PolicySetDefinitionsImpl implements PolicySetDefinitions { * @param options The options parameters. */ public listBuiltIn( - options?: PolicySetDefinitionsListBuiltInOptionalParams + options?: PolicySetDefinitionsListBuiltInOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listBuiltInPagingAll(options); return { @@ -139,13 +139,13 @@ export class PolicySetDefinitionsImpl implements PolicySetDefinitions { throw new Error("maxPageSize is not supported by this operation."); } return this.listBuiltInPagingPage(options, settings); - } + }, }; } private async *listBuiltInPagingPage( options?: PolicySetDefinitionsListBuiltInOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: PolicySetDefinitionsListBuiltInResponse; let continuationToken = settings?.continuationToken; @@ -166,7 +166,7 @@ export class PolicySetDefinitionsImpl implements PolicySetDefinitions { } private async *listBuiltInPagingAll( - options?: PolicySetDefinitionsListBuiltInOptionalParams + options?: PolicySetDefinitionsListBuiltInOptionalParams, ): AsyncIterableIterator { for await (const page of this.listBuiltInPagingPage(options)) { yield* page; @@ -189,11 +189,11 @@ export class PolicySetDefinitionsImpl implements PolicySetDefinitions { */ public listByManagementGroup( managementGroupId: string, - options?: PolicySetDefinitionsListByManagementGroupOptionalParams + options?: PolicySetDefinitionsListByManagementGroupOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listByManagementGroupPagingAll( managementGroupId, - options + options, ); return { next() { @@ -209,16 +209,16 @@ export class PolicySetDefinitionsImpl implements PolicySetDefinitions { return this.listByManagementGroupPagingPage( managementGroupId, options, - settings + settings, ); - } + }, }; } private async *listByManagementGroupPagingPage( managementGroupId: string, options?: PolicySetDefinitionsListByManagementGroupOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: PolicySetDefinitionsListByManagementGroupResponse; let continuationToken = settings?.continuationToken; @@ -233,7 +233,7 @@ export class PolicySetDefinitionsImpl implements PolicySetDefinitions { result = await this._listByManagementGroupNext( managementGroupId, continuationToken, - options + options, ); continuationToken = result.nextLink; let page = result.value || []; @@ -244,11 +244,11 @@ export class PolicySetDefinitionsImpl implements PolicySetDefinitions { private async *listByManagementGroupPagingAll( managementGroupId: string, - options?: PolicySetDefinitionsListByManagementGroupOptionalParams + options?: PolicySetDefinitionsListByManagementGroupOptionalParams, ): AsyncIterableIterator { for await (const page of this.listByManagementGroupPagingPage( managementGroupId, - options + options, )) { yield* page; } @@ -264,11 +264,11 @@ export class PolicySetDefinitionsImpl implements PolicySetDefinitions { createOrUpdate( policySetDefinitionName: string, parameters: PolicySetDefinition, - options?: PolicySetDefinitionsCreateOrUpdateOptionalParams + options?: PolicySetDefinitionsCreateOrUpdateOptionalParams, ): Promise { return this.client.sendOperationRequest( { policySetDefinitionName, parameters, options }, - createOrUpdateOperationSpec + createOrUpdateOperationSpec, ); } @@ -279,11 +279,11 @@ export class PolicySetDefinitionsImpl implements PolicySetDefinitions { */ delete( policySetDefinitionName: string, - options?: PolicySetDefinitionsDeleteOptionalParams + options?: PolicySetDefinitionsDeleteOptionalParams, ): Promise { return this.client.sendOperationRequest( { policySetDefinitionName, options }, - deleteOperationSpec + deleteOperationSpec, ); } @@ -294,11 +294,11 @@ export class PolicySetDefinitionsImpl implements PolicySetDefinitions { */ get( policySetDefinitionName: string, - options?: PolicySetDefinitionsGetOptionalParams + options?: PolicySetDefinitionsGetOptionalParams, ): Promise { return this.client.sendOperationRequest( { policySetDefinitionName, options }, - getOperationSpec + getOperationSpec, ); } @@ -309,11 +309,11 @@ export class PolicySetDefinitionsImpl implements PolicySetDefinitions { */ getBuiltIn( policySetDefinitionName: string, - options?: PolicySetDefinitionsGetBuiltInOptionalParams + options?: PolicySetDefinitionsGetBuiltInOptionalParams, ): Promise { return this.client.sendOperationRequest( { policySetDefinitionName, options }, - getBuiltInOperationSpec + getBuiltInOperationSpec, ); } @@ -331,7 +331,7 @@ export class PolicySetDefinitionsImpl implements PolicySetDefinitions { * @param options The options parameters. */ private _list( - options?: PolicySetDefinitionsListOptionalParams + options?: PolicySetDefinitionsListOptionalParams, ): Promise { return this.client.sendOperationRequest({ options }, listOperationSpec); } @@ -343,66 +343,66 @@ export class PolicySetDefinitionsImpl implements PolicySetDefinitions { * @param options The options parameters. */ private _listBuiltIn( - options?: PolicySetDefinitionsListBuiltInOptionalParams + options?: PolicySetDefinitionsListBuiltInOptionalParams, ): Promise { return this.client.sendOperationRequest( { options }, - listBuiltInOperationSpec + listBuiltInOperationSpec, ); } /** * This operation creates or updates a policy set definition in the given management group with the * given name. - * @param policySetDefinitionName The name of the policy set definition to create. * @param managementGroupId The ID of the management group. + * @param policySetDefinitionName The name of the policy set definition to create. * @param parameters The policy set definition properties. * @param options The options parameters. */ createOrUpdateAtManagementGroup( - policySetDefinitionName: string, managementGroupId: string, + policySetDefinitionName: string, parameters: PolicySetDefinition, - options?: PolicySetDefinitionsCreateOrUpdateAtManagementGroupOptionalParams + options?: PolicySetDefinitionsCreateOrUpdateAtManagementGroupOptionalParams, ): Promise { return this.client.sendOperationRequest( - { policySetDefinitionName, managementGroupId, parameters, options }, - createOrUpdateAtManagementGroupOperationSpec + { managementGroupId, policySetDefinitionName, parameters, options }, + createOrUpdateAtManagementGroupOperationSpec, ); } /** * This operation deletes the policy set definition in the given management group with the given name. - * @param policySetDefinitionName The name of the policy set definition to delete. * @param managementGroupId The ID of the management group. + * @param policySetDefinitionName The name of the policy set definition to delete. * @param options The options parameters. */ deleteAtManagementGroup( - policySetDefinitionName: string, managementGroupId: string, - options?: PolicySetDefinitionsDeleteAtManagementGroupOptionalParams + policySetDefinitionName: string, + options?: PolicySetDefinitionsDeleteAtManagementGroupOptionalParams, ): Promise { return this.client.sendOperationRequest( - { policySetDefinitionName, managementGroupId, options }, - deleteAtManagementGroupOperationSpec + { managementGroupId, policySetDefinitionName, options }, + deleteAtManagementGroupOperationSpec, ); } /** * This operation retrieves the policy set definition in the given management group with the given * name. - * @param policySetDefinitionName The name of the policy set definition to get. * @param managementGroupId The ID of the management group. + * @param policySetDefinitionName The name of the policy set definition to get. * @param options The options parameters. */ getAtManagementGroup( - policySetDefinitionName: string, managementGroupId: string, - options?: PolicySetDefinitionsGetAtManagementGroupOptionalParams + policySetDefinitionName: string, + options?: PolicySetDefinitionsGetAtManagementGroupOptionalParams, ): Promise { return this.client.sendOperationRequest( - { policySetDefinitionName, managementGroupId, options }, - getAtManagementGroupOperationSpec + { managementGroupId, policySetDefinitionName, options }, + getAtManagementGroupOperationSpec, ); } @@ -422,11 +422,11 @@ export class PolicySetDefinitionsImpl implements PolicySetDefinitions { */ private _listByManagementGroup( managementGroupId: string, - options?: PolicySetDefinitionsListByManagementGroupOptionalParams + options?: PolicySetDefinitionsListByManagementGroupOptionalParams, ): Promise { return this.client.sendOperationRequest( { managementGroupId, options }, - listByManagementGroupOperationSpec + listByManagementGroupOperationSpec, ); } @@ -437,11 +437,11 @@ export class PolicySetDefinitionsImpl implements PolicySetDefinitions { */ private _listNext( nextLink: string, - options?: PolicySetDefinitionsListNextOptionalParams + options?: PolicySetDefinitionsListNextOptionalParams, ): Promise { return this.client.sendOperationRequest( { nextLink, options }, - listNextOperationSpec + listNextOperationSpec, ); } @@ -452,11 +452,11 @@ export class PolicySetDefinitionsImpl implements PolicySetDefinitions { */ private _listBuiltInNext( nextLink: string, - options?: PolicySetDefinitionsListBuiltInNextOptionalParams + options?: PolicySetDefinitionsListBuiltInNextOptionalParams, ): Promise { return this.client.sendOperationRequest( { nextLink, options }, - listBuiltInNextOperationSpec + listBuiltInNextOperationSpec, ); } @@ -469,11 +469,11 @@ export class PolicySetDefinitionsImpl implements PolicySetDefinitions { private _listByManagementGroupNext( managementGroupId: string, nextLink: string, - options?: PolicySetDefinitionsListByManagementGroupNextOptionalParams + options?: PolicySetDefinitionsListByManagementGroupNextOptionalParams, ): Promise { return this.client.sendOperationRequest( { managementGroupId, nextLink, options }, - listByManagementGroupNextOperationSpec + listByManagementGroupNextOperationSpec, ); } } @@ -481,256 +481,247 @@ export class PolicySetDefinitionsImpl implements PolicySetDefinitions { const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); const createOrUpdateOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/providers/Microsoft.Authorization/policySetDefinitions/{policySetDefinitionName}", + path: "/subscriptions/{subscriptionId}/providers/Microsoft.Authorization/policySetDefinitions/{policySetDefinitionName}", httpMethod: "PUT", responses: { 200: { - bodyMapper: Mappers.PolicySetDefinition + bodyMapper: Mappers.PolicySetDefinition, }, 201: { - bodyMapper: Mappers.PolicySetDefinition + bodyMapper: Mappers.PolicySetDefinition, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, - requestBody: Parameters.parameters3, - queryParameters: [Parameters.apiVersion1], + requestBody: Parameters.parameters2, + queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, - Parameters.policySetDefinitionName + Parameters.policySetDefinitionName, ], - headerParameters: [Parameters.accept, Parameters.contentType], + headerParameters: [Parameters.contentType, Parameters.accept], mediaType: "json", - serializer + serializer, }; const deleteOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/providers/Microsoft.Authorization/policySetDefinitions/{policySetDefinitionName}", + path: "/subscriptions/{subscriptionId}/providers/Microsoft.Authorization/policySetDefinitions/{policySetDefinitionName}", httpMethod: "DELETE", responses: { 200: {}, 204: {}, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, - queryParameters: [Parameters.apiVersion1], + queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, - Parameters.policySetDefinitionName + Parameters.policySetDefinitionName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const getOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/providers/Microsoft.Authorization/policySetDefinitions/{policySetDefinitionName}", + path: "/subscriptions/{subscriptionId}/providers/Microsoft.Authorization/policySetDefinitions/{policySetDefinitionName}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.PolicySetDefinition + bodyMapper: Mappers.PolicySetDefinition, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, - queryParameters: [Parameters.apiVersion1], + queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, - Parameters.policySetDefinitionName + Parameters.policySetDefinitionName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const getBuiltInOperationSpec: coreClient.OperationSpec = { - path: - "/providers/Microsoft.Authorization/policySetDefinitions/{policySetDefinitionName}", + path: "/providers/Microsoft.Authorization/policySetDefinitions/{policySetDefinitionName}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.PolicySetDefinition + bodyMapper: Mappers.PolicySetDefinition, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, - queryParameters: [Parameters.apiVersion1], + queryParameters: [Parameters.apiVersion], urlParameters: [Parameters.$host, Parameters.policySetDefinitionName], headerParameters: [Parameters.accept], - serializer + serializer, }; const listOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/providers/Microsoft.Authorization/policySetDefinitions", + path: "/subscriptions/{subscriptionId}/providers/Microsoft.Authorization/policySetDefinitions", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.PolicySetDefinitionListResult + bodyMapper: Mappers.PolicySetDefinitionListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, - queryParameters: [Parameters.filter, Parameters.apiVersion1, Parameters.top], + queryParameters: [Parameters.apiVersion, Parameters.filter, Parameters.top], urlParameters: [Parameters.$host, Parameters.subscriptionId], headerParameters: [Parameters.accept], - serializer + serializer, }; const listBuiltInOperationSpec: coreClient.OperationSpec = { path: "/providers/Microsoft.Authorization/policySetDefinitions", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.PolicySetDefinitionListResult + bodyMapper: Mappers.PolicySetDefinitionListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, - queryParameters: [Parameters.filter, Parameters.apiVersion1, Parameters.top], + queryParameters: [Parameters.apiVersion, Parameters.filter, Parameters.top], urlParameters: [Parameters.$host], headerParameters: [Parameters.accept], - serializer + serializer, }; const createOrUpdateAtManagementGroupOperationSpec: coreClient.OperationSpec = { - path: - "/providers/Microsoft.Management/managementGroups/{managementGroupId}/providers/Microsoft.Authorization/policySetDefinitions/{policySetDefinitionName}", + path: "/providers/Microsoft.Management/managementGroups/{managementGroupId}/providers/Microsoft.Authorization/policySetDefinitions/{policySetDefinitionName}", httpMethod: "PUT", responses: { 200: { - bodyMapper: Mappers.PolicySetDefinition + bodyMapper: Mappers.PolicySetDefinition, }, 201: { - bodyMapper: Mappers.PolicySetDefinition + bodyMapper: Mappers.PolicySetDefinition, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, - requestBody: Parameters.parameters3, - queryParameters: [Parameters.apiVersion1], + requestBody: Parameters.parameters2, + queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.managementGroupId, - Parameters.policySetDefinitionName + Parameters.policySetDefinitionName, ], - headerParameters: [Parameters.accept, Parameters.contentType], + headerParameters: [Parameters.contentType, Parameters.accept], mediaType: "json", - serializer + serializer, }; const deleteAtManagementGroupOperationSpec: coreClient.OperationSpec = { - path: - "/providers/Microsoft.Management/managementGroups/{managementGroupId}/providers/Microsoft.Authorization/policySetDefinitions/{policySetDefinitionName}", + path: "/providers/Microsoft.Management/managementGroups/{managementGroupId}/providers/Microsoft.Authorization/policySetDefinitions/{policySetDefinitionName}", httpMethod: "DELETE", responses: { 200: {}, 204: {}, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, - queryParameters: [Parameters.apiVersion1], + queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.managementGroupId, - Parameters.policySetDefinitionName + Parameters.policySetDefinitionName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const getAtManagementGroupOperationSpec: coreClient.OperationSpec = { - path: - "/providers/Microsoft.Management/managementGroups/{managementGroupId}/providers/Microsoft.Authorization/policySetDefinitions/{policySetDefinitionName}", + path: "/providers/Microsoft.Management/managementGroups/{managementGroupId}/providers/Microsoft.Authorization/policySetDefinitions/{policySetDefinitionName}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.PolicySetDefinition + bodyMapper: Mappers.PolicySetDefinition, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, - queryParameters: [Parameters.apiVersion1], + queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.managementGroupId, - Parameters.policySetDefinitionName + Parameters.policySetDefinitionName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const listByManagementGroupOperationSpec: coreClient.OperationSpec = { - path: - "/providers/Microsoft.Management/managementGroups/{managementGroupId}/providers/Microsoft.Authorization/policySetDefinitions", + path: "/providers/Microsoft.Management/managementGroups/{managementGroupId}/providers/Microsoft.Authorization/policySetDefinitions", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.PolicySetDefinitionListResult + bodyMapper: Mappers.PolicySetDefinitionListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, - queryParameters: [Parameters.filter, Parameters.apiVersion1, Parameters.top], + queryParameters: [Parameters.apiVersion, Parameters.filter, Parameters.top], urlParameters: [Parameters.$host, Parameters.managementGroupId], headerParameters: [Parameters.accept], - serializer + serializer, }; const listNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.PolicySetDefinitionListResult + bodyMapper: Mappers.PolicySetDefinitionListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, urlParameters: [ Parameters.$host, + Parameters.subscriptionId, Parameters.nextLink, - Parameters.subscriptionId ], headerParameters: [Parameters.accept], - serializer + serializer, }; const listBuiltInNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.PolicySetDefinitionListResult + bodyMapper: Mappers.PolicySetDefinitionListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, urlParameters: [Parameters.$host, Parameters.nextLink], headerParameters: [Parameters.accept], - serializer + serializer, }; const listByManagementGroupNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.PolicySetDefinitionListResult + bodyMapper: Mappers.PolicySetDefinitionListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, urlParameters: [ Parameters.$host, + Parameters.managementGroupId, Parameters.nextLink, - Parameters.managementGroupId ], headerParameters: [Parameters.accept], - serializer + serializer, }; diff --git a/sdk/policy/arm-policy/src/operationsInterfaces/dataPolicyManifests.ts b/sdk/policy/arm-policy/src/operationsInterfaces/dataPolicyManifests.ts deleted file mode 100644 index f6c486278f94..000000000000 --- a/sdk/policy/arm-policy/src/operationsInterfaces/dataPolicyManifests.ts +++ /dev/null @@ -1,40 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -import { PagedAsyncIterableIterator } from "@azure/core-paging"; -import { - DataPolicyManifest, - DataPolicyManifestsListOptionalParams, - DataPolicyManifestsGetByPolicyModeOptionalParams, - DataPolicyManifestsGetByPolicyModeResponse -} from "../models"; - -/// -/** Interface representing a DataPolicyManifests. */ -export interface DataPolicyManifests { - /** - * This operation retrieves a list of all the data policy manifests that match the optional given - * $filter. Valid values for $filter are: "$filter=namespace eq '{0}'". If $filter is not provided, the - * unfiltered list includes all data policy manifests for data resource types. If $filter=namespace is - * provided, the returned list only includes all data policy manifests that have a namespace matching - * the provided value. - * @param options The options parameters. - */ - list( - options?: DataPolicyManifestsListOptionalParams - ): PagedAsyncIterableIterator; - /** - * This operation retrieves the data policy manifest with the given policy mode. - * @param policyMode The policy mode of the data policy manifest to get. - * @param options The options parameters. - */ - getByPolicyMode( - policyMode: string, - options?: DataPolicyManifestsGetByPolicyModeOptionalParams - ): Promise; -} diff --git a/sdk/policy/arm-policy/src/operationsInterfaces/index.ts b/sdk/policy/arm-policy/src/operationsInterfaces/index.ts index eff8c4c2a63a..2e5558fc99cc 100644 --- a/sdk/policy/arm-policy/src/operationsInterfaces/index.ts +++ b/sdk/policy/arm-policy/src/operationsInterfaces/index.ts @@ -6,8 +6,8 @@ * Changes may cause incorrect behavior and will be lost if the code is regenerated. */ -export * from "./dataPolicyManifests"; -export * from "./policyAssignments"; export * from "./policyDefinitions"; +export * from "./policyDefinitionVersions"; export * from "./policySetDefinitions"; -export * from "./policyExemptions"; +export * from "./policySetDefinitionVersions"; +export * from "./policyAssignments"; diff --git a/sdk/policy/arm-policy/src/operationsInterfaces/policyAssignments.ts b/sdk/policy/arm-policy/src/operationsInterfaces/policyAssignments.ts index 88b1af30048a..f3faa8ecc08b 100644 --- a/sdk/policy/arm-policy/src/operationsInterfaces/policyAssignments.ts +++ b/sdk/policy/arm-policy/src/operationsInterfaces/policyAssignments.ts @@ -29,7 +29,7 @@ import { PolicyAssignmentsGetByIdOptionalParams, PolicyAssignmentsGetByIdResponse, PolicyAssignmentsUpdateByIdOptionalParams, - PolicyAssignmentsUpdateByIdResponse + PolicyAssignmentsUpdateByIdResponse, } from "../models"; /// @@ -52,7 +52,7 @@ export interface PolicyAssignments { */ listForResourceGroup( resourceGroupName: string, - options?: PolicyAssignmentsListForResourceGroupOptionalParams + options?: PolicyAssignmentsListForResourceGroupOptionalParams, ): PagedAsyncIterableIterator; /** * This operation retrieves the list of all policy assignments associated with the specified resource @@ -92,7 +92,7 @@ export interface PolicyAssignments { parentResourcePath: string, resourceType: string, resourceName: string, - options?: PolicyAssignmentsListForResourceOptionalParams + options?: PolicyAssignmentsListForResourceOptionalParams, ): PagedAsyncIterableIterator; /** * This operation retrieves the list of all policy assignments applicable to the management group that @@ -108,7 +108,7 @@ export interface PolicyAssignments { */ listForManagementGroup( managementGroupId: string, - options?: PolicyAssignmentsListForManagementGroupOptionalParams + options?: PolicyAssignmentsListForManagementGroupOptionalParams, ): PagedAsyncIterableIterator; /** * This operation retrieves the list of all policy assignments associated with the given subscription @@ -125,7 +125,7 @@ export interface PolicyAssignments { * @param options The options parameters. */ list( - options?: PolicyAssignmentsListOptionalParams + options?: PolicyAssignmentsListOptionalParams, ): PagedAsyncIterableIterator; /** * This operation deletes a policy assignment, given its name and the scope it was created in. The @@ -142,7 +142,7 @@ export interface PolicyAssignments { delete( scope: string, policyAssignmentName: string, - options?: PolicyAssignmentsDeleteOptionalParams + options?: PolicyAssignmentsDeleteOptionalParams, ): Promise; /** * This operation creates or updates a policy assignment with the given scope and name. Policy @@ -161,7 +161,7 @@ export interface PolicyAssignments { scope: string, policyAssignmentName: string, parameters: PolicyAssignment, - options?: PolicyAssignmentsCreateOptionalParams + options?: PolicyAssignmentsCreateOptionalParams, ): Promise; /** * This operation retrieves a single policy assignment, given its name and the scope it was created at. @@ -176,7 +176,7 @@ export interface PolicyAssignments { get( scope: string, policyAssignmentName: string, - options?: PolicyAssignmentsGetOptionalParams + options?: PolicyAssignmentsGetOptionalParams, ): Promise; /** * This operation updates a policy assignment with the given scope and name. Policy assignments apply @@ -195,7 +195,7 @@ export interface PolicyAssignments { scope: string, policyAssignmentName: string, parameters: PolicyAssignmentUpdate, - options?: PolicyAssignmentsUpdateOptionalParams + options?: PolicyAssignmentsUpdateOptionalParams, ): Promise; /** * This operation deletes the policy with the given ID. Policy assignment IDs have this format: @@ -211,7 +211,7 @@ export interface PolicyAssignments { */ deleteById( policyAssignmentId: string, - options?: PolicyAssignmentsDeleteByIdOptionalParams + options?: PolicyAssignmentsDeleteByIdOptionalParams, ): Promise; /** * This operation creates or updates the policy assignment with the given ID. Policy assignments made @@ -231,7 +231,7 @@ export interface PolicyAssignments { createById( policyAssignmentId: string, parameters: PolicyAssignment, - options?: PolicyAssignmentsCreateByIdOptionalParams + options?: PolicyAssignmentsCreateByIdOptionalParams, ): Promise; /** * The operation retrieves the policy assignment with the given ID. Policy assignment IDs have this @@ -247,7 +247,7 @@ export interface PolicyAssignments { */ getById( policyAssignmentId: string, - options?: PolicyAssignmentsGetByIdOptionalParams + options?: PolicyAssignmentsGetByIdOptionalParams, ): Promise; /** * This operation updates the policy assignment with the given ID. Policy assignments made on a scope @@ -267,6 +267,6 @@ export interface PolicyAssignments { updateById( policyAssignmentId: string, parameters: PolicyAssignmentUpdate, - options?: PolicyAssignmentsUpdateByIdOptionalParams + options?: PolicyAssignmentsUpdateByIdOptionalParams, ): Promise; } diff --git a/sdk/policy/arm-policy/src/operationsInterfaces/policyDefinitionVersions.ts b/sdk/policy/arm-policy/src/operationsInterfaces/policyDefinitionVersions.ts new file mode 100644 index 000000000000..52a8bd6b7058 --- /dev/null +++ b/sdk/policy/arm-policy/src/operationsInterfaces/policyDefinitionVersions.ts @@ -0,0 +1,193 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +import { PagedAsyncIterableIterator } from "@azure/core-paging"; +import { + PolicyDefinitionVersion, + PolicyDefinitionVersionsListOptionalParams, + PolicyDefinitionVersionsListBuiltInOptionalParams, + PolicyDefinitionVersionsListByManagementGroupOptionalParams, + PolicyDefinitionVersionsListAllBuiltinsOptionalParams, + PolicyDefinitionVersionsListAllBuiltinsResponse, + PolicyDefinitionVersionsListAllAtManagementGroupOptionalParams, + PolicyDefinitionVersionsListAllAtManagementGroupResponse, + PolicyDefinitionVersionsListAllOptionalParams, + PolicyDefinitionVersionsListAllResponse, + PolicyDefinitionVersionsCreateOrUpdateOptionalParams, + PolicyDefinitionVersionsCreateOrUpdateResponse, + PolicyDefinitionVersionsDeleteOptionalParams, + PolicyDefinitionVersionsGetOptionalParams, + PolicyDefinitionVersionsGetResponse, + PolicyDefinitionVersionsGetBuiltInOptionalParams, + PolicyDefinitionVersionsGetBuiltInResponse, + PolicyDefinitionVersionsCreateOrUpdateAtManagementGroupOptionalParams, + PolicyDefinitionVersionsCreateOrUpdateAtManagementGroupResponse, + PolicyDefinitionVersionsDeleteAtManagementGroupOptionalParams, + PolicyDefinitionVersionsGetAtManagementGroupOptionalParams, + PolicyDefinitionVersionsGetAtManagementGroupResponse, +} from "../models"; + +/// +/** Interface representing a PolicyDefinitionVersions. */ +export interface PolicyDefinitionVersions { + /** + * This operation retrieves a list of all the policy definition versions for the given policy + * definition. + * @param policyDefinitionName The name of the policy definition. + * @param options The options parameters. + */ + list( + policyDefinitionName: string, + options?: PolicyDefinitionVersionsListOptionalParams, + ): PagedAsyncIterableIterator; + /** + * This operation retrieves a list of all the built-in policy definition versions for the given policy + * definition. + * @param policyDefinitionName The name of the policy definition. + * @param options The options parameters. + */ + listBuiltIn( + policyDefinitionName: string, + options?: PolicyDefinitionVersionsListBuiltInOptionalParams, + ): PagedAsyncIterableIterator; + /** + * This operation retrieves a list of all the policy definition versions for the given policy + * definition in the given management group. + * @param managementGroupName The name of the management group. The name is case insensitive. + * @param policyDefinitionName The name of the policy definition. + * @param options The options parameters. + */ + listByManagementGroup( + managementGroupName: string, + policyDefinitionName: string, + options?: PolicyDefinitionVersionsListByManagementGroupOptionalParams, + ): PagedAsyncIterableIterator; + /** + * This operation lists all the built-in policy definition versions for all built-in policy + * definitions. + * @param options The options parameters. + */ + listAllBuiltins( + options?: PolicyDefinitionVersionsListAllBuiltinsOptionalParams, + ): Promise; + /** + * This operation lists all the policy definition versions for all policy definitions at the management + * group scope. + * @param managementGroupName The name of the management group. The name is case insensitive. + * @param options The options parameters. + */ + listAllAtManagementGroup( + managementGroupName: string, + options?: PolicyDefinitionVersionsListAllAtManagementGroupOptionalParams, + ): Promise; + /** + * This operation lists all the policy definition versions for all policy definitions within a + * subscription. + * @param options The options parameters. + */ + listAll( + options?: PolicyDefinitionVersionsListAllOptionalParams, + ): Promise; + /** + * This operation creates or updates a policy definition in the given subscription with the given name. + * @param policyDefinitionName The name of the policy definition. + * @param policyDefinitionVersion The policy definition version. The format is x.y.z where x is the + * major version number, y is the minor version number, and z is the patch number + * @param parameters The policy definition properties. + * @param options The options parameters. + */ + createOrUpdate( + policyDefinitionName: string, + policyDefinitionVersion: string, + parameters: PolicyDefinitionVersion, + options?: PolicyDefinitionVersionsCreateOrUpdateOptionalParams, + ): Promise; + /** + * This operation deletes the policy definition version in the given subscription with the given name. + * @param policyDefinitionName The name of the policy definition. + * @param policyDefinitionVersion The policy definition version. The format is x.y.z where x is the + * major version number, y is the minor version number, and z is the patch number + * @param options The options parameters. + */ + delete( + policyDefinitionName: string, + policyDefinitionVersion: string, + options?: PolicyDefinitionVersionsDeleteOptionalParams, + ): Promise; + /** + * This operation retrieves the policy definition version in the given subscription with the given + * name. + * @param policyDefinitionName The name of the policy definition. + * @param policyDefinitionVersion The policy definition version. The format is x.y.z where x is the + * major version number, y is the minor version number, and z is the patch number + * @param options The options parameters. + */ + get( + policyDefinitionName: string, + policyDefinitionVersion: string, + options?: PolicyDefinitionVersionsGetOptionalParams, + ): Promise; + /** + * This operation retrieves the built-in policy definition version with the given name. + * @param policyDefinitionName The name of the policy definition. + * @param policyDefinitionVersion The policy definition version. The format is x.y.z where x is the + * major version number, y is the minor version number, and z is the patch number + * @param options The options parameters. + */ + getBuiltIn( + policyDefinitionName: string, + policyDefinitionVersion: string, + options?: PolicyDefinitionVersionsGetBuiltInOptionalParams, + ): Promise; + /** + * This operation creates or updates a policy definition version in the given management group with the + * given name. + * @param managementGroupName The name of the management group. The name is case insensitive. + * @param policyDefinitionName The name of the policy definition. + * @param policyDefinitionVersion The policy definition version. The format is x.y.z where x is the + * major version number, y is the minor version number, and z is the patch number + * @param parameters The policy definition properties. + * @param options The options parameters. + */ + createOrUpdateAtManagementGroup( + managementGroupName: string, + policyDefinitionName: string, + policyDefinitionVersion: string, + parameters: PolicyDefinitionVersion, + options?: PolicyDefinitionVersionsCreateOrUpdateAtManagementGroupOptionalParams, + ): Promise; + /** + * This operation deletes the policy definition in the given management group with the given name. + * @param managementGroupName The name of the management group. The name is case insensitive. + * @param policyDefinitionName The name of the policy definition. + * @param policyDefinitionVersion The policy definition version. The format is x.y.z where x is the + * major version number, y is the minor version number, and z is the patch number + * @param options The options parameters. + */ + deleteAtManagementGroup( + managementGroupName: string, + policyDefinitionName: string, + policyDefinitionVersion: string, + options?: PolicyDefinitionVersionsDeleteAtManagementGroupOptionalParams, + ): Promise; + /** + * This operation retrieves the policy definition version in the given management group with the given + * name. + * @param managementGroupName The name of the management group. The name is case insensitive. + * @param policyDefinitionName The name of the policy definition. + * @param policyDefinitionVersion The policy definition version. The format is x.y.z where x is the + * major version number, y is the minor version number, and z is the patch number + * @param options The options parameters. + */ + getAtManagementGroup( + managementGroupName: string, + policyDefinitionName: string, + policyDefinitionVersion: string, + options?: PolicyDefinitionVersionsGetAtManagementGroupOptionalParams, + ): Promise; +} diff --git a/sdk/policy/arm-policy/src/operationsInterfaces/policyDefinitions.ts b/sdk/policy/arm-policy/src/operationsInterfaces/policyDefinitions.ts index 3a2ca8d77fd1..d9091718ecd8 100644 --- a/sdk/policy/arm-policy/src/operationsInterfaces/policyDefinitions.ts +++ b/sdk/policy/arm-policy/src/operationsInterfaces/policyDefinitions.ts @@ -23,7 +23,7 @@ import { PolicyDefinitionsCreateOrUpdateAtManagementGroupResponse, PolicyDefinitionsDeleteAtManagementGroupOptionalParams, PolicyDefinitionsGetAtManagementGroupOptionalParams, - PolicyDefinitionsGetAtManagementGroupResponse + PolicyDefinitionsGetAtManagementGroupResponse, } from "../models"; /// @@ -43,7 +43,7 @@ export interface PolicyDefinitions { * @param options The options parameters. */ list( - options?: PolicyDefinitionsListOptionalParams + options?: PolicyDefinitionsListOptionalParams, ): PagedAsyncIterableIterator; /** * This operation retrieves a list of all the built-in policy definitions that match the optional given @@ -54,7 +54,7 @@ export interface PolicyDefinitions { * @param options The options parameters. */ listBuiltIn( - options?: PolicyDefinitionsListBuiltInOptionalParams + options?: PolicyDefinitionsListBuiltInOptionalParams, ): PagedAsyncIterableIterator; /** * This operation retrieves a list of all the policy definitions in a given management group that match @@ -72,7 +72,7 @@ export interface PolicyDefinitions { */ listByManagementGroup( managementGroupId: string, - options?: PolicyDefinitionsListByManagementGroupOptionalParams + options?: PolicyDefinitionsListByManagementGroupOptionalParams, ): PagedAsyncIterableIterator; /** * This operation creates or updates a policy definition in the given subscription with the given name. @@ -83,7 +83,7 @@ export interface PolicyDefinitions { createOrUpdate( policyDefinitionName: string, parameters: PolicyDefinition, - options?: PolicyDefinitionsCreateOrUpdateOptionalParams + options?: PolicyDefinitionsCreateOrUpdateOptionalParams, ): Promise; /** * This operation deletes the policy definition in the given subscription with the given name. @@ -92,7 +92,7 @@ export interface PolicyDefinitions { */ delete( policyDefinitionName: string, - options?: PolicyDefinitionsDeleteOptionalParams + options?: PolicyDefinitionsDeleteOptionalParams, ): Promise; /** * This operation retrieves the policy definition in the given subscription with the given name. @@ -101,7 +101,7 @@ export interface PolicyDefinitions { */ get( policyDefinitionName: string, - options?: PolicyDefinitionsGetOptionalParams + options?: PolicyDefinitionsGetOptionalParams, ): Promise; /** * This operation retrieves the built-in policy definition with the given name. @@ -110,42 +110,42 @@ export interface PolicyDefinitions { */ getBuiltIn( policyDefinitionName: string, - options?: PolicyDefinitionsGetBuiltInOptionalParams + options?: PolicyDefinitionsGetBuiltInOptionalParams, ): Promise; /** * This operation creates or updates a policy definition in the given management group with the given * name. - * @param policyDefinitionName The name of the policy definition to create. * @param managementGroupId The ID of the management group. + * @param policyDefinitionName The name of the policy definition to create. * @param parameters The policy definition properties. * @param options The options parameters. */ createOrUpdateAtManagementGroup( - policyDefinitionName: string, managementGroupId: string, + policyDefinitionName: string, parameters: PolicyDefinition, - options?: PolicyDefinitionsCreateOrUpdateAtManagementGroupOptionalParams + options?: PolicyDefinitionsCreateOrUpdateAtManagementGroupOptionalParams, ): Promise; /** * This operation deletes the policy definition in the given management group with the given name. - * @param policyDefinitionName The name of the policy definition to delete. * @param managementGroupId The ID of the management group. + * @param policyDefinitionName The name of the policy definition to delete. * @param options The options parameters. */ deleteAtManagementGroup( - policyDefinitionName: string, managementGroupId: string, - options?: PolicyDefinitionsDeleteAtManagementGroupOptionalParams + policyDefinitionName: string, + options?: PolicyDefinitionsDeleteAtManagementGroupOptionalParams, ): Promise; /** * This operation retrieves the policy definition in the given management group with the given name. - * @param policyDefinitionName The name of the policy definition to get. * @param managementGroupId The ID of the management group. + * @param policyDefinitionName The name of the policy definition to get. * @param options The options parameters. */ getAtManagementGroup( - policyDefinitionName: string, managementGroupId: string, - options?: PolicyDefinitionsGetAtManagementGroupOptionalParams + policyDefinitionName: string, + options?: PolicyDefinitionsGetAtManagementGroupOptionalParams, ): Promise; } diff --git a/sdk/policy/arm-policy/src/operationsInterfaces/policyExemptions.ts b/sdk/policy/arm-policy/src/operationsInterfaces/policyExemptions.ts deleted file mode 100644 index 7fdc61601594..000000000000 --- a/sdk/policy/arm-policy/src/operationsInterfaces/policyExemptions.ts +++ /dev/null @@ -1,151 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -import { PagedAsyncIterableIterator } from "@azure/core-paging"; -import { - PolicyExemption, - PolicyExemptionsListOptionalParams, - PolicyExemptionsListForResourceGroupOptionalParams, - PolicyExemptionsListForResourceOptionalParams, - PolicyExemptionsListForManagementGroupOptionalParams, - PolicyExemptionsDeleteOptionalParams, - PolicyExemptionsCreateOrUpdateOptionalParams, - PolicyExemptionsCreateOrUpdateResponse, - PolicyExemptionsGetOptionalParams, - PolicyExemptionsGetResponse -} from "../models"; - -/// -/** Interface representing a PolicyExemptions. */ -export interface PolicyExemptions { - /** - * This operation retrieves the list of all policy exemptions associated with the given subscription - * that match the optional given $filter. Valid values for $filter are: 'atScope()', 'atExactScope()', - * 'excludeExpired()' or 'policyAssignmentId eq '{value}''. If $filter is not provided, the unfiltered - * list includes all policy exemptions associated with the subscription, including those that apply - * directly or from management groups that contain the given subscription, as well as any applied to - * objects contained within the subscription. - * @param options The options parameters. - */ - list( - options?: PolicyExemptionsListOptionalParams - ): PagedAsyncIterableIterator; - /** - * This operation retrieves the list of all policy exemptions associated with the given resource group - * in the given subscription that match the optional given $filter. Valid values for $filter are: - * 'atScope()', 'atExactScope()', 'excludeExpired()' or 'policyAssignmentId eq '{value}''. If $filter - * is not provided, the unfiltered list includes all policy exemptions associated with the resource - * group, including those that apply directly or apply from containing scopes, as well as any applied - * to resources contained within the resource group. - * @param resourceGroupName The name of the resource group containing the resource. - * @param options The options parameters. - */ - listForResourceGroup( - resourceGroupName: string, - options?: PolicyExemptionsListForResourceGroupOptionalParams - ): PagedAsyncIterableIterator; - /** - * This operation retrieves the list of all policy exemptions associated with the specified resource in - * the given resource group and subscription that match the optional given $filter. Valid values for - * $filter are: 'atScope()', 'atExactScope()', 'excludeExpired()' or 'policyAssignmentId eq '{value}''. - * If $filter is not provided, the unfiltered list includes all policy exemptions associated with the - * resource, including those that apply directly or from all containing scopes, as well as any applied - * to resources contained within the resource. Three parameters plus the resource name are used to - * identify a specific resource. If the resource is not part of a parent resource (the more common - * case), the parent resource path should not be provided (or provided as ''). For example a web app - * could be specified as ({resourceProviderNamespace} == 'Microsoft.Web', {parentResourcePath} == '', - * {resourceType} == 'sites', {resourceName} == 'MyWebApp'). If the resource is part of a parent - * resource, then all parameters should be provided. For example a virtual machine DNS name could be - * specified as ({resourceProviderNamespace} == 'Microsoft.Compute', {parentResourcePath} == - * 'virtualMachines/MyVirtualMachine', {resourceType} == 'domainNames', {resourceName} == - * 'MyComputerName'). A convenient alternative to providing the namespace and type name separately is - * to provide both in the {resourceType} parameter, format: ({resourceProviderNamespace} == '', - * {parentResourcePath} == '', {resourceType} == 'Microsoft.Web/sites', {resourceName} == 'MyWebApp'). - * @param resourceGroupName The name of the resource group containing the resource. - * @param resourceProviderNamespace The namespace of the resource provider. For example, the namespace - * of a virtual machine is Microsoft.Compute (from Microsoft.Compute/virtualMachines) - * @param parentResourcePath The parent resource path. Use empty string if there is none. - * @param resourceType The resource type name. For example the type name of a web app is 'sites' (from - * Microsoft.Web/sites). - * @param resourceName The name of the resource. - * @param options The options parameters. - */ - listForResource( - resourceGroupName: string, - resourceProviderNamespace: string, - parentResourcePath: string, - resourceType: string, - resourceName: string, - options?: PolicyExemptionsListForResourceOptionalParams - ): PagedAsyncIterableIterator; - /** - * This operation retrieves the list of all policy exemptions applicable to the management group that - * match the given $filter. Valid values for $filter are: 'atScope()', 'atExactScope()', - * 'excludeExpired()' or 'policyAssignmentId eq '{value}''. If $filter=atScope() is provided, the - * returned list includes all policy exemptions that are assigned to the management group or the - * management group's ancestors. - * @param managementGroupId The ID of the management group. - * @param options The options parameters. - */ - listForManagementGroup( - managementGroupId: string, - options?: PolicyExemptionsListForManagementGroupOptionalParams - ): PagedAsyncIterableIterator; - /** - * This operation deletes a policy exemption, given its name and the scope it was created in. The scope - * of a policy exemption is the part of its ID preceding - * '/providers/Microsoft.Authorization/policyExemptions/{policyExemptionName}'. - * @param scope The scope of the policy exemption. Valid scopes are: management group (format: - * '/providers/Microsoft.Management/managementGroups/{managementGroup}'), subscription (format: - * '/subscriptions/{subscriptionId}'), resource group (format: - * '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}', or resource (format: - * '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/[{parentResourcePath}/]{resourceType}/{resourceName}' - * @param policyExemptionName The name of the policy exemption to delete. - * @param options The options parameters. - */ - delete( - scope: string, - policyExemptionName: string, - options?: PolicyExemptionsDeleteOptionalParams - ): Promise; - /** - * This operation creates or updates a policy exemption with the given scope and name. Policy - * exemptions apply to all resources contained within their scope. For example, when you create a - * policy exemption at resource group scope for a policy assignment at the same or above level, the - * exemption exempts to all applicable resources in the resource group. - * @param scope The scope of the policy exemption. Valid scopes are: management group (format: - * '/providers/Microsoft.Management/managementGroups/{managementGroup}'), subscription (format: - * '/subscriptions/{subscriptionId}'), resource group (format: - * '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}', or resource (format: - * '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/[{parentResourcePath}/]{resourceType}/{resourceName}' - * @param policyExemptionName The name of the policy exemption to delete. - * @param parameters Parameters for the policy exemption. - * @param options The options parameters. - */ - createOrUpdate( - scope: string, - policyExemptionName: string, - parameters: PolicyExemption, - options?: PolicyExemptionsCreateOrUpdateOptionalParams - ): Promise; - /** - * This operation retrieves a single policy exemption, given its name and the scope it was created at. - * @param scope The scope of the policy exemption. Valid scopes are: management group (format: - * '/providers/Microsoft.Management/managementGroups/{managementGroup}'), subscription (format: - * '/subscriptions/{subscriptionId}'), resource group (format: - * '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}', or resource (format: - * '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/[{parentResourcePath}/]{resourceType}/{resourceName}' - * @param policyExemptionName The name of the policy exemption to delete. - * @param options The options parameters. - */ - get( - scope: string, - policyExemptionName: string, - options?: PolicyExemptionsGetOptionalParams - ): Promise; -} diff --git a/sdk/policy/arm-policy/src/operationsInterfaces/policySetDefinitionVersions.ts b/sdk/policy/arm-policy/src/operationsInterfaces/policySetDefinitionVersions.ts new file mode 100644 index 000000000000..7220ef6aebca --- /dev/null +++ b/sdk/policy/arm-policy/src/operationsInterfaces/policySetDefinitionVersions.ts @@ -0,0 +1,196 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +import { PagedAsyncIterableIterator } from "@azure/core-paging"; +import { + PolicySetDefinitionVersion, + PolicySetDefinitionVersionsListOptionalParams, + PolicySetDefinitionVersionsListBuiltInOptionalParams, + PolicySetDefinitionVersionsListByManagementGroupOptionalParams, + PolicySetDefinitionVersionsListAllBuiltinsOptionalParams, + PolicySetDefinitionVersionsListAllBuiltinsResponse, + PolicySetDefinitionVersionsListAllAtManagementGroupOptionalParams, + PolicySetDefinitionVersionsListAllAtManagementGroupResponse, + PolicySetDefinitionVersionsListAllOptionalParams, + PolicySetDefinitionVersionsListAllResponse, + PolicySetDefinitionVersionsCreateOrUpdateOptionalParams, + PolicySetDefinitionVersionsCreateOrUpdateResponse, + PolicySetDefinitionVersionsDeleteOptionalParams, + PolicySetDefinitionVersionsGetOptionalParams, + PolicySetDefinitionVersionsGetResponse, + PolicySetDefinitionVersionsGetBuiltInOptionalParams, + PolicySetDefinitionVersionsGetBuiltInResponse, + PolicySetDefinitionVersionsCreateOrUpdateAtManagementGroupOptionalParams, + PolicySetDefinitionVersionsCreateOrUpdateAtManagementGroupResponse, + PolicySetDefinitionVersionsDeleteAtManagementGroupOptionalParams, + PolicySetDefinitionVersionsGetAtManagementGroupOptionalParams, + PolicySetDefinitionVersionsGetAtManagementGroupResponse, +} from "../models"; + +/// +/** Interface representing a PolicySetDefinitionVersions. */ +export interface PolicySetDefinitionVersions { + /** + * This operation retrieves a list of all the policy set definition versions for the given policy set + * definition. + * @param policySetDefinitionName The name of the policy set definition. + * @param options The options parameters. + */ + list( + policySetDefinitionName: string, + options?: PolicySetDefinitionVersionsListOptionalParams, + ): PagedAsyncIterableIterator; + /** + * This operation retrieves a list of all the built-in policy set definition versions for the given + * built-in policy set definition. + * @param policySetDefinitionName The name of the policy set definition. + * @param options The options parameters. + */ + listBuiltIn( + policySetDefinitionName: string, + options?: PolicySetDefinitionVersionsListBuiltInOptionalParams, + ): PagedAsyncIterableIterator; + /** + * This operation retrieves a list of all the policy set definition versions for the given policy set + * definition in a given management group. + * @param managementGroupName The name of the management group. The name is case insensitive. + * @param policySetDefinitionName The name of the policy set definition. + * @param options The options parameters. + */ + listByManagementGroup( + managementGroupName: string, + policySetDefinitionName: string, + options?: PolicySetDefinitionVersionsListByManagementGroupOptionalParams, + ): PagedAsyncIterableIterator; + /** + * This operation lists all the built-in policy set definition versions for all built-in policy set + * definitions. + * @param options The options parameters. + */ + listAllBuiltins( + options?: PolicySetDefinitionVersionsListAllBuiltinsOptionalParams, + ): Promise; + /** + * This operation lists all the policy set definition versions for all policy set definitions at the + * management group scope. + * @param managementGroupName The name of the management group. The name is case insensitive. + * @param options The options parameters. + */ + listAllAtManagementGroup( + managementGroupName: string, + options?: PolicySetDefinitionVersionsListAllAtManagementGroupOptionalParams, + ): Promise; + /** + * This operation lists all the policy set definition versions for all policy set definitions within a + * subscription. + * @param options The options parameters. + */ + listAll( + options?: PolicySetDefinitionVersionsListAllOptionalParams, + ): Promise; + /** + * This operation creates or updates a policy set definition version in the given subscription with the + * given name and version. + * @param policySetDefinitionName The name of the policy set definition. + * @param policyDefinitionVersion The policy set definition version. The format is x.y.z where x is + * the major version number, y is the minor version number, and z is the patch number + * @param parameters The policy set definition properties. + * @param options The options parameters. + */ + createOrUpdate( + policySetDefinitionName: string, + policyDefinitionVersion: string, + parameters: PolicySetDefinitionVersion, + options?: PolicySetDefinitionVersionsCreateOrUpdateOptionalParams, + ): Promise; + /** + * This operation deletes the policy set definition version in the given subscription with the given + * name and version. + * @param policySetDefinitionName The name of the policy set definition. + * @param policyDefinitionVersion The policy set definition version. The format is x.y.z where x is + * the major version number, y is the minor version number, and z is the patch number + * @param options The options parameters. + */ + delete( + policySetDefinitionName: string, + policyDefinitionVersion: string, + options?: PolicySetDefinitionVersionsDeleteOptionalParams, + ): Promise; + /** + * This operation retrieves the policy set definition version in the given subscription with the given + * name and version. + * @param policySetDefinitionName The name of the policy set definition. + * @param policyDefinitionVersion The policy set definition version. The format is x.y.z where x is + * the major version number, y is the minor version number, and z is the patch number + * @param options The options parameters. + */ + get( + policySetDefinitionName: string, + policyDefinitionVersion: string, + options?: PolicySetDefinitionVersionsGetOptionalParams, + ): Promise; + /** + * This operation retrieves the built-in policy set definition version with the given name and version. + * @param policySetDefinitionName The name of the policy set definition. + * @param policyDefinitionVersion The policy set definition version. The format is x.y.z where x is + * the major version number, y is the minor version number, and z is the patch number + * @param options The options parameters. + */ + getBuiltIn( + policySetDefinitionName: string, + policyDefinitionVersion: string, + options?: PolicySetDefinitionVersionsGetBuiltInOptionalParams, + ): Promise; + /** + * This operation creates or updates a policy set definition version in the given management group with + * the given name and version. + * @param managementGroupName The name of the management group. The name is case insensitive. + * @param policySetDefinitionName The name of the policy set definition. + * @param policyDefinitionVersion The policy set definition version. The format is x.y.z where x is + * the major version number, y is the minor version number, and z is the patch number + * @param parameters The policy set definition version properties. + * @param options The options parameters. + */ + createOrUpdateAtManagementGroup( + managementGroupName: string, + policySetDefinitionName: string, + policyDefinitionVersion: string, + parameters: PolicySetDefinitionVersion, + options?: PolicySetDefinitionVersionsCreateOrUpdateAtManagementGroupOptionalParams, + ): Promise; + /** + * This operation deletes the policy set definition version in the given management group with the + * given name and version. + * @param managementGroupName The name of the management group. The name is case insensitive. + * @param policySetDefinitionName The name of the policy set definition. + * @param policyDefinitionVersion The policy set definition version. The format is x.y.z where x is + * the major version number, y is the minor version number, and z is the patch number + * @param options The options parameters. + */ + deleteAtManagementGroup( + managementGroupName: string, + policySetDefinitionName: string, + policyDefinitionVersion: string, + options?: PolicySetDefinitionVersionsDeleteAtManagementGroupOptionalParams, + ): Promise; + /** + * This operation retrieves the policy set definition version in the given management group with the + * given name and version. + * @param managementGroupName The name of the management group. The name is case insensitive. + * @param policySetDefinitionName The name of the policy set definition. + * @param policyDefinitionVersion The policy set definition version. The format is x.y.z where x is + * the major version number, y is the minor version number, and z is the patch number + * @param options The options parameters. + */ + getAtManagementGroup( + managementGroupName: string, + policySetDefinitionName: string, + policyDefinitionVersion: string, + options?: PolicySetDefinitionVersionsGetAtManagementGroupOptionalParams, + ): Promise; +} diff --git a/sdk/policy/arm-policy/src/operationsInterfaces/policySetDefinitions.ts b/sdk/policy/arm-policy/src/operationsInterfaces/policySetDefinitions.ts index cec9ce211322..a56c84a6b8bd 100644 --- a/sdk/policy/arm-policy/src/operationsInterfaces/policySetDefinitions.ts +++ b/sdk/policy/arm-policy/src/operationsInterfaces/policySetDefinitions.ts @@ -23,7 +23,7 @@ import { PolicySetDefinitionsCreateOrUpdateAtManagementGroupResponse, PolicySetDefinitionsDeleteAtManagementGroupOptionalParams, PolicySetDefinitionsGetAtManagementGroupOptionalParams, - PolicySetDefinitionsGetAtManagementGroupResponse + PolicySetDefinitionsGetAtManagementGroupResponse, } from "../models"; /// @@ -43,7 +43,7 @@ export interface PolicySetDefinitions { * @param options The options parameters. */ list( - options?: PolicySetDefinitionsListOptionalParams + options?: PolicySetDefinitionsListOptionalParams, ): PagedAsyncIterableIterator; /** * This operation retrieves a list of all the built-in policy set definitions that match the optional @@ -52,7 +52,7 @@ export interface PolicySetDefinitions { * @param options The options parameters. */ listBuiltIn( - options?: PolicySetDefinitionsListBuiltInOptionalParams + options?: PolicySetDefinitionsListBuiltInOptionalParams, ): PagedAsyncIterableIterator; /** * This operation retrieves a list of all the policy set definitions in a given management group that @@ -70,7 +70,7 @@ export interface PolicySetDefinitions { */ listByManagementGroup( managementGroupId: string, - options?: PolicySetDefinitionsListByManagementGroupOptionalParams + options?: PolicySetDefinitionsListByManagementGroupOptionalParams, ): PagedAsyncIterableIterator; /** * This operation creates or updates a policy set definition in the given subscription with the given @@ -82,7 +82,7 @@ export interface PolicySetDefinitions { createOrUpdate( policySetDefinitionName: string, parameters: PolicySetDefinition, - options?: PolicySetDefinitionsCreateOrUpdateOptionalParams + options?: PolicySetDefinitionsCreateOrUpdateOptionalParams, ): Promise; /** * This operation deletes the policy set definition in the given subscription with the given name. @@ -91,7 +91,7 @@ export interface PolicySetDefinitions { */ delete( policySetDefinitionName: string, - options?: PolicySetDefinitionsDeleteOptionalParams + options?: PolicySetDefinitionsDeleteOptionalParams, ): Promise; /** * This operation retrieves the policy set definition in the given subscription with the given name. @@ -100,7 +100,7 @@ export interface PolicySetDefinitions { */ get( policySetDefinitionName: string, - options?: PolicySetDefinitionsGetOptionalParams + options?: PolicySetDefinitionsGetOptionalParams, ): Promise; /** * This operation retrieves the built-in policy set definition with the given name. @@ -109,43 +109,43 @@ export interface PolicySetDefinitions { */ getBuiltIn( policySetDefinitionName: string, - options?: PolicySetDefinitionsGetBuiltInOptionalParams + options?: PolicySetDefinitionsGetBuiltInOptionalParams, ): Promise; /** * This operation creates or updates a policy set definition in the given management group with the * given name. - * @param policySetDefinitionName The name of the policy set definition to create. * @param managementGroupId The ID of the management group. + * @param policySetDefinitionName The name of the policy set definition to create. * @param parameters The policy set definition properties. * @param options The options parameters. */ createOrUpdateAtManagementGroup( - policySetDefinitionName: string, managementGroupId: string, + policySetDefinitionName: string, parameters: PolicySetDefinition, - options?: PolicySetDefinitionsCreateOrUpdateAtManagementGroupOptionalParams + options?: PolicySetDefinitionsCreateOrUpdateAtManagementGroupOptionalParams, ): Promise; /** * This operation deletes the policy set definition in the given management group with the given name. - * @param policySetDefinitionName The name of the policy set definition to delete. * @param managementGroupId The ID of the management group. + * @param policySetDefinitionName The name of the policy set definition to delete. * @param options The options parameters. */ deleteAtManagementGroup( - policySetDefinitionName: string, managementGroupId: string, - options?: PolicySetDefinitionsDeleteAtManagementGroupOptionalParams + policySetDefinitionName: string, + options?: PolicySetDefinitionsDeleteAtManagementGroupOptionalParams, ): Promise; /** * This operation retrieves the policy set definition in the given management group with the given * name. - * @param policySetDefinitionName The name of the policy set definition to get. * @param managementGroupId The ID of the management group. + * @param policySetDefinitionName The name of the policy set definition to get. * @param options The options parameters. */ getAtManagementGroup( - policySetDefinitionName: string, managementGroupId: string, - options?: PolicySetDefinitionsGetAtManagementGroupOptionalParams + policySetDefinitionName: string, + options?: PolicySetDefinitionsGetAtManagementGroupOptionalParams, ): Promise; } diff --git a/sdk/policy/arm-policy/src/pagingHelper.ts b/sdk/policy/arm-policy/src/pagingHelper.ts index 269a2b9814b5..205cccc26592 100644 --- a/sdk/policy/arm-policy/src/pagingHelper.ts +++ b/sdk/policy/arm-policy/src/pagingHelper.ts @@ -28,7 +28,7 @@ export function getContinuationToken(page: unknown): string | undefined { export function setContinuationToken( page: unknown, - continuationToken: string | undefined + continuationToken: string | undefined, ): void { if (typeof page !== "object" || page === null || !continuationToken) { return; diff --git a/sdk/policy/arm-policy/src/policyClient.ts b/sdk/policy/arm-policy/src/policyClient.ts index 9188174e25d4..d4943b7c40ee 100644 --- a/sdk/policy/arm-policy/src/policyClient.ts +++ b/sdk/policy/arm-policy/src/policyClient.ts @@ -8,58 +8,63 @@ import * as coreClient from "@azure/core-client"; import * as coreRestPipeline from "@azure/core-rest-pipeline"; +import { + PipelineRequest, + PipelineResponse, + SendRequest, +} from "@azure/core-rest-pipeline"; import * as coreAuth from "@azure/core-auth"; import { - DataPolicyManifestsImpl, - PolicyAssignmentsImpl, PolicyDefinitionsImpl, + PolicyDefinitionVersionsImpl, PolicySetDefinitionsImpl, - PolicyExemptionsImpl + PolicySetDefinitionVersionsImpl, + PolicyAssignmentsImpl, } from "./operations"; import { - DataPolicyManifests, - PolicyAssignments, PolicyDefinitions, + PolicyDefinitionVersions, PolicySetDefinitions, - PolicyExemptions + PolicySetDefinitionVersions, + PolicyAssignments, } from "./operationsInterfaces"; import { PolicyClientOptionalParams } from "./models"; export class PolicyClient extends coreClient.ServiceClient { $host: string; subscriptionId?: string; + apiVersion: string; /** * Initializes a new instance of the PolicyClient class. * @param credentials Subscription credentials which uniquely identify client subscription. - * @param subscriptionId The ID of the target subscription. + * @param subscriptionId The ID of the target subscription. The value must be an UUID. * @param options The parameter options */ constructor( credentials: coreAuth.TokenCredential, subscriptionId: string, - options?: PolicyClientOptionalParams + options?: PolicyClientOptionalParams, ); constructor( credentials: coreAuth.TokenCredential, - options?: PolicyClientOptionalParams + options?: PolicyClientOptionalParams, ); constructor( credentials: coreAuth.TokenCredential, - subscriptionIdOrOptions?: string | PolicyClientOptionalParams, - options?: PolicyClientOptionalParams + subscriptionIdOrOptions?: PolicyClientOptionalParams | string, + options?: PolicyClientOptionalParams, ) { if (credentials === undefined) { throw new Error("'credentials' cannot be null"); } + let subscriptionId: string | undefined; - if (!subscriptionIdOrOptions !== undefined) { - if (typeof subscriptionIdOrOptions === "string") { - subscriptionId = subscriptionIdOrOptions; - } else if (typeof subscriptionIdOrOptions === "object") { - options = subscriptionIdOrOptions; - } + if (typeof subscriptionIdOrOptions === "string") { + subscriptionId = subscriptionIdOrOptions; + } else if (typeof subscriptionIdOrOptions === "object") { + options = subscriptionIdOrOptions; } // Initializing default values for options @@ -68,10 +73,10 @@ export class PolicyClient extends coreClient.ServiceClient { } const defaults: PolicyClientOptionalParams = { requestContentType: "application/json; charset=utf-8", - credential: credentials + credential: credentials, }; - const packageDetails = `azsdk-js-arm-policy/5.1.1`; + const packageDetails = `azsdk-js-arm-policy/6.0.0`; const userAgentPrefix = options.userAgentOptions && options.userAgentOptions.userAgentPrefix ? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}` @@ -81,20 +86,21 @@ export class PolicyClient extends coreClient.ServiceClient { ...defaults, ...options, userAgentOptions: { - userAgentPrefix + userAgentPrefix, }, endpoint: - options.endpoint ?? options.baseUri ?? "https://management.azure.com" + options.endpoint ?? options.baseUri ?? "https://management.azure.com", }; super(optionsWithDefaults); let bearerTokenAuthenticationPolicyFound: boolean = false; if (options?.pipeline && options.pipeline.getOrderedPolicies().length > 0) { - const pipelinePolicies: coreRestPipeline.PipelinePolicy[] = options.pipeline.getOrderedPolicies(); + const pipelinePolicies: coreRestPipeline.PipelinePolicy[] = + options.pipeline.getOrderedPolicies(); bearerTokenAuthenticationPolicyFound = pipelinePolicies.some( (pipelinePolicy) => pipelinePolicy.name === - coreRestPipeline.bearerTokenAuthenticationPolicyName + coreRestPipeline.bearerTokenAuthenticationPolicyName, ); } if ( @@ -104,7 +110,7 @@ export class PolicyClient extends coreClient.ServiceClient { !bearerTokenAuthenticationPolicyFound ) { this.pipeline.removePolicy({ - name: coreRestPipeline.bearerTokenAuthenticationPolicyName + name: coreRestPipeline.bearerTokenAuthenticationPolicyName, }); this.pipeline.addPolicy( coreRestPipeline.bearerTokenAuthenticationPolicy({ @@ -114,9 +120,9 @@ export class PolicyClient extends coreClient.ServiceClient { `${optionsWithDefaults.endpoint}/.default`, challengeCallbacks: { authorizeRequestOnChallenge: - coreClient.authorizeRequestOnClaimChallenge - } - }) + coreClient.authorizeRequestOnClaimChallenge, + }, + }), ); } // Parameter assignments @@ -124,16 +130,48 @@ export class PolicyClient extends coreClient.ServiceClient { // Assigning values to Constant parameters this.$host = options.$host || "https://management.azure.com"; - this.dataPolicyManifests = new DataPolicyManifestsImpl(this); - this.policyAssignments = new PolicyAssignmentsImpl(this); + this.apiVersion = options.apiVersion || "2024-05-01"; this.policyDefinitions = new PolicyDefinitionsImpl(this); + this.policyDefinitionVersions = new PolicyDefinitionVersionsImpl(this); this.policySetDefinitions = new PolicySetDefinitionsImpl(this); - this.policyExemptions = new PolicyExemptionsImpl(this); + this.policySetDefinitionVersions = new PolicySetDefinitionVersionsImpl( + this, + ); + this.policyAssignments = new PolicyAssignmentsImpl(this); + this.addCustomApiVersionPolicy(options.apiVersion); + } + + /** A function that adds a policy that sets the api-version (or equivalent) to reflect the library version. */ + private addCustomApiVersionPolicy(apiVersion?: string) { + if (!apiVersion) { + return; + } + const apiVersionPolicy = { + name: "CustomApiVersionPolicy", + async sendRequest( + request: PipelineRequest, + next: SendRequest, + ): Promise { + const param = request.url.split("?"); + if (param.length > 1) { + const newParams = param[1].split("&").map((item) => { + if (item.indexOf("api-version") > -1) { + return "api-version=" + apiVersion; + } else { + return item; + } + }); + request.url = param[0] + "?" + newParams.join("&"); + } + return next(request); + }, + }; + this.pipeline.addPolicy(apiVersionPolicy); } - dataPolicyManifests: DataPolicyManifests; - policyAssignments: PolicyAssignments; policyDefinitions: PolicyDefinitions; + policyDefinitionVersions: PolicyDefinitionVersions; policySetDefinitions: PolicySetDefinitions; - policyExemptions: PolicyExemptions; + policySetDefinitionVersions: PolicySetDefinitionVersions; + policyAssignments: PolicyAssignments; } diff --git a/sdk/policy/arm-policy/test/sampleTest.ts b/sdk/policy/arm-policy/test/sampleTest.ts new file mode 100644 index 000000000000..d64be981b694 --- /dev/null +++ b/sdk/policy/arm-policy/test/sampleTest.ts @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +import { + Recorder, + RecorderStartOptions, + env, +} from "@azure-tools/test-recorder"; +import { assert } from "chai"; +import { Context } from "mocha"; + +const replaceableVariables: Record = { + AZURE_CLIENT_ID: "azure_client_id", + AZURE_CLIENT_SECRET: "azure_client_secret", + AZURE_TENANT_ID: "88888888-8888-8888-8888-888888888888", + SUBSCRIPTION_ID: "azure_subscription_id", +}; + +const recorderOptions: RecorderStartOptions = { + envSetupForPlayback: replaceableVariables, +}; + +describe("My test", () => { + let recorder: Recorder; + + beforeEach(async function (this: Context) { + recorder = new Recorder(this.currentTest); + await recorder.start(recorderOptions); + }); + + afterEach(async function () { + await recorder.stop(); + }); + + it("sample test", async function () { + console.log("Hi, I'm a test!"); + }); +}); diff --git a/sdk/policy/arm-policy/tsconfig.json b/sdk/policy/arm-policy/tsconfig.json index bf4c4a024317..cd0af931e3e0 100644 --- a/sdk/policy/arm-policy/tsconfig.json +++ b/sdk/policy/arm-policy/tsconfig.json @@ -15,17 +15,14 @@ ], "declaration": true, "outDir": "./dist-esm", - "importHelpers": true, - "paths": { - "@azure/arm-policy": [ - "./src/index" - ] - } + "importHelpers": true }, "include": [ "./src/**/*.ts", "./test/**/*.ts", - "samples-dev/**/*.ts" + "./test/**/*.ts", + "./test/**/*.ts", + "./test/**/*.ts" ], "exclude": [ "node_modules" diff --git a/sdk/resources-subscriptions/arm-resources-subscriptions/LICENSE b/sdk/resources-subscriptions/arm-resources-subscriptions/LICENSE index 3a1d9b6f24f7..7d5934740965 100644 --- a/sdk/resources-subscriptions/arm-resources-subscriptions/LICENSE +++ b/sdk/resources-subscriptions/arm-resources-subscriptions/LICENSE @@ -1,6 +1,6 @@ The MIT License (MIT) -Copyright (c) 2023 Microsoft +Copyright (c) 2024 Microsoft Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal diff --git a/sdk/resources-subscriptions/arm-resources-subscriptions/_meta.json b/sdk/resources-subscriptions/arm-resources-subscriptions/_meta.json index 0c611e34e91d..28591836c37e 100644 --- a/sdk/resources-subscriptions/arm-resources-subscriptions/_meta.json +++ b/sdk/resources-subscriptions/arm-resources-subscriptions/_meta.json @@ -1,8 +1,8 @@ { - "commit": "2b5927fd07bfb51809a06ca35b6142f63ba77bab", + "commit": "5342edb61d78cec6e07b17a6cd8f7749c6697272", "readme": "specification/resources/resource-manager/readme.md", - "autorest_command": "autorest --version=3.9.3 --typescript --modelerfour.lenient-model-deduplication --azure-arm --head-as-boolean=true --license-header=MICROSOFT_MIT_NO_VERSION --generate-test --typescript-sdks-folder=D:\\Git\\azure-sdk-for-js ..\\azure-rest-api-specs\\specification\\resources\\resource-manager\\readme.md --use=@autorest/typescript@6.0.2 --generate-sample=true", + "autorest_command": "autorest --version=3.9.7 --typescript --modelerfour.lenient-model-deduplication --azure-arm --head-as-boolean=true --license-header=MICROSOFT_MIT_NO_VERSION --generate-test --typescript-sdks-folder=/mnt/vss/_work/1/s/azure-sdk-for-js ../azure-rest-api-specs/specification/resources/resource-manager/readme.md --use=@autorest/typescript@^6.0.12", "repository_url": "https://github.com/Azure/azure-rest-api-specs.git", - "release_tool": "@azure-tools/js-sdk-release-tools@2.6.2", - "use": "@autorest/typescript@6.0.2" + "release_tool": "@azure-tools/js-sdk-release-tools@2.7.14", + "use": "@autorest/typescript@^6.0.12" } \ No newline at end of file diff --git a/sdk/resources-subscriptions/arm-resources-subscriptions/package.json b/sdk/resources-subscriptions/arm-resources-subscriptions/package.json index 13225fc0fe8b..1a469cff8ee1 100644 --- a/sdk/resources-subscriptions/arm-resources-subscriptions/package.json +++ b/sdk/resources-subscriptions/arm-resources-subscriptions/package.json @@ -8,10 +8,10 @@ "node": ">=18.0.0" }, "dependencies": { - "@azure/core-auth": "^1.3.0", - "@azure/core-client": "^1.7.0", "@azure/core-paging": "^1.2.0", - "@azure/core-rest-pipeline": "^1.8.0", + "@azure/core-client": "^1.7.0", + "@azure/core-auth": "^1.6.0", + "@azure/core-rest-pipeline": "^1.14.0", "tslib": "^2.2.0" }, "keywords": [ @@ -26,19 +26,24 @@ "module": "./dist-esm/src/index.js", "types": "./types/arm-resources-subscriptions.d.ts", "devDependencies": { - "@azure-tools/test-credential": "^1.0.0", - "@azure-tools/test-recorder": "^3.0.0", + "@microsoft/api-extractor": "^7.31.1", + "mkdirp": "^3.0.1", + "typescript": "~5.5.3", + "uglify-js": "^3.4.9", + "rimraf": "^5.0.0", + "dotenv": "^16.0.0", "@azure/dev-tool": "^1.0.0", - "@azure/identity": "^4.0.1", - "@types/chai": "^4.2.8", + "@azure/identity": "^4.2.1", + "@azure-tools/test-recorder": "^3.0.0", + "@azure-tools/test-credential": "^1.1.0", + "mocha": "^10.0.0", "@types/mocha": "^10.0.0", - "@types/node": "^18.0.0", + "tsx": "^4.7.1", + "@types/chai": "^4.2.8", "chai": "^4.2.0", "cross-env": "^7.0.2", - "dotenv": "^16.0.0", - "mocha": "^10.0.0", - "ts-node": "^10.0.0", - "typescript": "~5.6.2" + "@types/node": "^18.0.0", + "ts-node": "^10.0.0" }, "repository": { "type": "git", @@ -65,30 +70,29 @@ "types/*" ], "scripts": { - "build": "npm run clean && tsc && dev-tool run bundle && npm run minify && dev-tool run vendored mkdirp ./review && npm run extract-api", - "build:browser": "echo skipped", + "build": "npm run clean && tsc && dev-tool run bundle && npm run minify && mkdirp ./review && npm run extract-api", + "minify": "uglifyjs -c -m --comments --source-map \"content='./dist/index.js.map'\" -o ./dist/index.min.js ./dist/index.js", + "prepack": "npm run build", + "pack": "npm pack 2>&1", + "extract-api": "dev-tool run extract-api", + "lint": "echo skipped", + "clean": "rimraf --glob dist dist-browser dist-esm test-dist temp types *.tgz *.log", "build:node": "echo skipped", - "build:samples": "echo skipped.", + "build:browser": "echo skipped", "build:test": "echo skipped", + "build:samples": "echo skipped.", "check-format": "echo skipped", - "clean": "dev-tool run vendored rimraf --glob dist dist-browser dist-esm test-dist temp types *.tgz *.log", "execute:samples": "echo skipped", - "extract-api": "dev-tool run extract-api", "format": "echo skipped", - "integration-test": "npm run integration-test:node && npm run integration-test:browser", - "integration-test:browser": "echo skipped", - "integration-test:node": "dev-tool run test:node-ts-input -- --timeout 1200000 'test/*.ts'", - "lint": "echo skipped", - "minify": "dev-tool run vendored uglifyjs -c -m --comments --source-map \"content='./dist/index.js.map'\" -o ./dist/index.min.js ./dist/index.js", - "pack": "npm pack 2>&1", - "prepack": "npm run build", "test": "npm run integration-test", - "test:browser": "echo skipped", "test:node": "echo skipped", + "test:browser": "echo skipped", "unit-test": "npm run unit-test:node && npm run unit-test:browser", - "unit-test:browser": "echo skipped", "unit-test:node": "cross-env TEST_MODE=playback npm run integration-test:node", - "update-snippets": "echo skipped" + "unit-test:browser": "echo skipped", + "integration-test": "npm run integration-test:node && npm run integration-test:browser", + "integration-test:node": "dev-tool run test:node-ts-input -- --timeout 1200000 'test/*.ts'", + "integration-test:browser": "echo skipped" }, "sideEffects": false, "//metadata": { @@ -100,13 +104,5 @@ ] }, "autoPublish": true, - "homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/resources-subscriptions/arm-resources-subscriptions", - "//sampleConfiguration": { - "productName": "", - "productSlugs": [ - "azure" - ], - "disableDocsMs": true, - "apiRefLink": "https://docs.microsoft.com/javascript/api/@azure/arm-resources-subscriptions?view=azure-node-preview" - } -} + "homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/resources-subscriptions/arm-resources-subscriptions" +} \ No newline at end of file diff --git a/sdk/resources-subscriptions/arm-resources-subscriptions/src/models/index.ts b/sdk/resources-subscriptions/arm-resources-subscriptions/src/models/index.ts index 6db2ed8937c1..d1a0fe76aedc 100644 --- a/sdk/resources-subscriptions/arm-resources-subscriptions/src/models/index.ts +++ b/sdk/resources-subscriptions/arm-resources-subscriptions/src/models/index.ts @@ -528,7 +528,7 @@ export enum KnownOrigin { /** System */ System = "system", /** UserSystem */ - UserSystem = "user,system" + UserSystem = "user,system", } /** @@ -545,7 +545,7 @@ export type Origin = string; /** Known values of {@link ActionType} that the service accepts. */ export enum KnownActionType { /** Internal */ - Internal = "Internal" + Internal = "Internal", } /** @@ -562,7 +562,7 @@ export enum KnownRegionType { /** Physical */ Physical = "Physical", /** Logical */ - Logical = "Logical" + Logical = "Logical", } /** @@ -582,7 +582,7 @@ export enum KnownRegionCategory { /** Extended */ Extended = "Extended", /** Other */ - Other = "Other" + Other = "Other", } /** @@ -601,7 +601,7 @@ export enum KnownResourceNameStatus { /** Allowed */ Allowed = "Allowed", /** Reserved */ - Reserved = "Reserved" + Reserved = "Reserved", } /** diff --git a/sdk/resources-subscriptions/arm-resources-subscriptions/src/models/mappers.ts b/sdk/resources-subscriptions/arm-resources-subscriptions/src/models/mappers.ts index 5f6ca4b369ab..a6c3d0404f2a 100644 --- a/sdk/resources-subscriptions/arm-resources-subscriptions/src/models/mappers.ts +++ b/sdk/resources-subscriptions/arm-resources-subscriptions/src/models/mappers.ts @@ -21,20 +21,20 @@ export const OperationListResult: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "Operation" - } - } - } + className: "Operation", + }, + }, + }, }, nextLink: { serializedName: "nextLink", readOnly: true, type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const Operation: coreClient.CompositeMapper = { @@ -46,39 +46,39 @@ export const Operation: coreClient.CompositeMapper = { serializedName: "name", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, isDataAction: { serializedName: "isDataAction", readOnly: true, type: { - name: "Boolean" - } + name: "Boolean", + }, }, display: { serializedName: "display", type: { name: "Composite", - className: "OperationDisplay" - } + className: "OperationDisplay", + }, }, origin: { serializedName: "origin", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, actionType: { serializedName: "actionType", readOnly: true, type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const OperationDisplay: coreClient.CompositeMapper = { @@ -90,32 +90,32 @@ export const OperationDisplay: coreClient.CompositeMapper = { serializedName: "provider", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, resource: { serializedName: "resource", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, operation: { serializedName: "operation", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, description: { serializedName: "description", readOnly: true, type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const CloudError: coreClient.CompositeMapper = { @@ -127,11 +127,11 @@ export const CloudError: coreClient.CompositeMapper = { serializedName: "error", type: { name: "Composite", - className: "ErrorResponse" - } - } - } - } + className: "ErrorResponse", + }, + }, + }, + }, }; export const ErrorResponse: coreClient.CompositeMapper = { @@ -143,22 +143,22 @@ export const ErrorResponse: coreClient.CompositeMapper = { serializedName: "code", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, message: { serializedName: "message", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, target: { serializedName: "target", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, details: { serializedName: "details", @@ -168,10 +168,10 @@ export const ErrorResponse: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "ErrorResponse" - } - } - } + className: "ErrorResponse", + }, + }, + }, }, additionalInfo: { serializedName: "additionalInfo", @@ -181,13 +181,13 @@ export const ErrorResponse: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "ErrorAdditionalInfo" - } - } - } - } - } - } + className: "ErrorAdditionalInfo", + }, + }, + }, + }, + }, + }, }; export const ErrorAdditionalInfo: coreClient.CompositeMapper = { @@ -199,19 +199,19 @@ export const ErrorAdditionalInfo: coreClient.CompositeMapper = { serializedName: "type", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, info: { serializedName: "info", readOnly: true, type: { name: "Dictionary", - value: { type: { name: "any" } } - } - } - } - } + value: { type: { name: "any" } }, + }, + }, + }, + }, }; export const LocationListResult: coreClient.CompositeMapper = { @@ -226,13 +226,13 @@ export const LocationListResult: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "Location" - } - } - } - } - } - } + className: "Location", + }, + }, + }, + }, + }, + }, }; export const Location: coreClient.CompositeMapper = { @@ -244,51 +244,51 @@ export const Location: coreClient.CompositeMapper = { serializedName: "id", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, subscriptionId: { serializedName: "subscriptionId", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, name: { serializedName: "name", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, type: { serializedName: "type", readOnly: true, type: { name: "Enum", - allowedValues: ["Region", "EdgeZone"] - } + allowedValues: ["Region", "EdgeZone"], + }, }, displayName: { serializedName: "displayName", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, regionalDisplayName: { serializedName: "regionalDisplayName", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, metadata: { serializedName: "metadata", type: { name: "Composite", - className: "LocationMetadata" - } + className: "LocationMetadata", + }, }, availabilityZoneMappings: { serializedName: "availabilityZoneMappings", @@ -297,13 +297,13 @@ export const Location: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "AvailabilityZoneMappings" - } - } - } - } - } - } + className: "AvailabilityZoneMappings", + }, + }, + }, + }, + }, + }, }; export const LocationMetadata: coreClient.CompositeMapper = { @@ -315,50 +315,50 @@ export const LocationMetadata: coreClient.CompositeMapper = { serializedName: "regionType", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, regionCategory: { serializedName: "regionCategory", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, geography: { serializedName: "geography", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, geographyGroup: { serializedName: "geographyGroup", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, longitude: { serializedName: "longitude", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, latitude: { serializedName: "latitude", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, physicalLocation: { serializedName: "physicalLocation", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, pairedRegion: { serializedName: "pairedRegion", @@ -367,20 +367,20 @@ export const LocationMetadata: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "PairedRegion" - } - } - } + className: "PairedRegion", + }, + }, + }, }, homeLocation: { serializedName: "homeLocation", readOnly: true, type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const PairedRegion: coreClient.CompositeMapper = { @@ -392,25 +392,25 @@ export const PairedRegion: coreClient.CompositeMapper = { serializedName: "name", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, id: { serializedName: "id", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, subscriptionId: { serializedName: "subscriptionId", readOnly: true, type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const AvailabilityZoneMappings: coreClient.CompositeMapper = { @@ -422,18 +422,18 @@ export const AvailabilityZoneMappings: coreClient.CompositeMapper = { serializedName: "logicalZone", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, physicalZone: { serializedName: "physicalZone", readOnly: true, type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const Subscription: coreClient.CompositeMapper = { @@ -445,50 +445,56 @@ export const Subscription: coreClient.CompositeMapper = { serializedName: "id", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, subscriptionId: { serializedName: "subscriptionId", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, displayName: { serializedName: "displayName", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, tenantId: { serializedName: "tenantId", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, state: { serializedName: "state", readOnly: true, type: { name: "Enum", - allowedValues: ["Enabled", "Warned", "PastDue", "Disabled", "Deleted"] - } + allowedValues: [ + "Enabled", + "Warned", + "PastDue", + "Disabled", + "Deleted", + ], + }, }, subscriptionPolicies: { serializedName: "subscriptionPolicies", type: { name: "Composite", - className: "SubscriptionPolicies" - } + className: "SubscriptionPolicies", + }, }, authorizationSource: { serializedName: "authorizationSource", type: { - name: "String" - } + name: "String", + }, }, managedByTenants: { serializedName: "managedByTenants", @@ -497,20 +503,20 @@ export const Subscription: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "ManagedByTenant" - } - } - } + className: "ManagedByTenant", + }, + }, + }, }, tags: { serializedName: "tags", type: { name: "Dictionary", - value: { type: { name: "String" } } - } - } - } - } + value: { type: { name: "String" } }, + }, + }, + }, + }, }; export const SubscriptionPolicies: coreClient.CompositeMapper = { @@ -522,26 +528,26 @@ export const SubscriptionPolicies: coreClient.CompositeMapper = { serializedName: "locationPlacementId", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, quotaId: { serializedName: "quotaId", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, spendingLimit: { serializedName: "spendingLimit", readOnly: true, type: { name: "Enum", - allowedValues: ["On", "Off", "CurrentPeriodOff"] - } - } - } - } + allowedValues: ["On", "Off", "CurrentPeriodOff"], + }, + }, + }, + }, }; export const ManagedByTenant: coreClient.CompositeMapper = { @@ -553,11 +559,11 @@ export const ManagedByTenant: coreClient.CompositeMapper = { serializedName: "tenantId", readOnly: true, type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const SubscriptionListResult: coreClient.CompositeMapper = { @@ -572,20 +578,20 @@ export const SubscriptionListResult: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "Subscription" - } - } - } + className: "Subscription", + }, + }, + }, }, nextLink: { serializedName: "nextLink", required: true, type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const TenantListResult: coreClient.CompositeMapper = { @@ -600,20 +606,20 @@ export const TenantListResult: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "TenantIdDescription" - } - } - } + className: "TenantIdDescription", + }, + }, + }, }, nextLink: { serializedName: "nextLink", required: true, type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const TenantIdDescription: coreClient.CompositeMapper = { @@ -625,44 +631,44 @@ export const TenantIdDescription: coreClient.CompositeMapper = { serializedName: "id", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, tenantId: { serializedName: "tenantId", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, tenantCategory: { serializedName: "tenantCategory", readOnly: true, type: { name: "Enum", - allowedValues: ["Home", "ProjectedBy", "ManagedBy"] - } + allowedValues: ["Home", "ProjectedBy", "ManagedBy"], + }, }, country: { serializedName: "country", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, countryCode: { serializedName: "countryCode", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, displayName: { serializedName: "displayName", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, domains: { serializedName: "domains", @@ -671,34 +677,34 @@ export const TenantIdDescription: coreClient.CompositeMapper = { name: "Sequence", element: { type: { - name: "String" - } - } - } + name: "String", + }, + }, + }, }, defaultDomain: { serializedName: "defaultDomain", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, tenantType: { serializedName: "tenantType", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, tenantBrandingLogoUrl: { serializedName: "tenantBrandingLogoUrl", readOnly: true, type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const CheckZonePeersRequest: coreClient.CompositeMapper = { @@ -709,8 +715,8 @@ export const CheckZonePeersRequest: coreClient.CompositeMapper = { location: { serializedName: "location", type: { - name: "String" - } + name: "String", + }, }, subscriptionIds: { serializedName: "subscriptionIds", @@ -718,13 +724,13 @@ export const CheckZonePeersRequest: coreClient.CompositeMapper = { name: "Sequence", element: { type: { - name: "String" - } - } - } - } - } - } + name: "String", + }, + }, + }, + }, + }, + }, }; export const CheckZonePeersResult: coreClient.CompositeMapper = { @@ -736,14 +742,14 @@ export const CheckZonePeersResult: coreClient.CompositeMapper = { serializedName: "subscriptionId", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, location: { serializedName: "location", type: { - name: "String" - } + name: "String", + }, }, availabilityZonePeers: { serializedName: "availabilityZonePeers", @@ -752,13 +758,13 @@ export const CheckZonePeersResult: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "AvailabilityZonePeers" - } - } - } - } - } - } + className: "AvailabilityZonePeers", + }, + }, + }, + }, + }, + }, }; export const AvailabilityZonePeers: coreClient.CompositeMapper = { @@ -770,8 +776,8 @@ export const AvailabilityZonePeers: coreClient.CompositeMapper = { serializedName: "availabilityZone", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, peers: { serializedName: "peers", @@ -780,13 +786,13 @@ export const AvailabilityZonePeers: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "Peers" - } - } - } - } - } - } + className: "Peers", + }, + }, + }, + }, + }, + }, }; export const Peers: coreClient.CompositeMapper = { @@ -798,18 +804,18 @@ export const Peers: coreClient.CompositeMapper = { serializedName: "subscriptionId", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, availabilityZone: { serializedName: "availabilityZone", readOnly: true, type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const ErrorResponseAutoGenerated: coreClient.CompositeMapper = { @@ -821,11 +827,11 @@ export const ErrorResponseAutoGenerated: coreClient.CompositeMapper = { serializedName: "error", type: { name: "Composite", - className: "ErrorDetail" - } - } - } - } + className: "ErrorDetail", + }, + }, + }, + }, }; export const ErrorDetail: coreClient.CompositeMapper = { @@ -837,22 +843,22 @@ export const ErrorDetail: coreClient.CompositeMapper = { serializedName: "code", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, message: { serializedName: "message", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, target: { serializedName: "target", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, details: { serializedName: "details", @@ -862,10 +868,10 @@ export const ErrorDetail: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "ErrorDetail" - } - } - } + className: "ErrorDetail", + }, + }, + }, }, additionalInfo: { serializedName: "additionalInfo", @@ -875,13 +881,13 @@ export const ErrorDetail: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "ErrorAdditionalInfo" - } - } - } - } - } - } + className: "ErrorAdditionalInfo", + }, + }, + }, + }, + }, + }, }; export const ResourceName: coreClient.CompositeMapper = { @@ -893,18 +899,18 @@ export const ResourceName: coreClient.CompositeMapper = { serializedName: "name", required: true, type: { - name: "String" - } + name: "String", + }, }, type: { serializedName: "type", required: true, type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const CheckResourceNameResult: coreClient.CompositeMapper = { @@ -915,23 +921,23 @@ export const CheckResourceNameResult: coreClient.CompositeMapper = { name: { serializedName: "name", type: { - name: "String" - } + name: "String", + }, }, type: { serializedName: "type", type: { - name: "String" - } + name: "String", + }, }, status: { serializedName: "status", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const OperationAutoGenerated: coreClient.CompositeMapper = { @@ -942,39 +948,39 @@ export const OperationAutoGenerated: coreClient.CompositeMapper = { name: { serializedName: "name", type: { - name: "String" - } + name: "String", + }, }, isDataAction: { serializedName: "isDataAction", readOnly: true, type: { - name: "Boolean" - } + name: "Boolean", + }, }, display: { serializedName: "display", type: { name: "Composite", - className: "OperationDisplayAutoGenerated" - } + className: "OperationDisplayAutoGenerated", + }, }, origin: { serializedName: "origin", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, actionType: { serializedName: "actionType", readOnly: true, type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const OperationDisplayAutoGenerated: coreClient.CompositeMapper = { @@ -985,29 +991,29 @@ export const OperationDisplayAutoGenerated: coreClient.CompositeMapper = { provider: { serializedName: "provider", type: { - name: "String" - } + name: "String", + }, }, resource: { serializedName: "resource", type: { - name: "String" - } + name: "String", + }, }, operation: { serializedName: "operation", type: { - name: "String" - } + name: "String", + }, }, description: { serializedName: "description", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const OperationListResultAutoGenerated: coreClient.CompositeMapper = { @@ -1022,17 +1028,17 @@ export const OperationListResultAutoGenerated: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "OperationAutoGenerated" - } - } - } + className: "OperationAutoGenerated", + }, + }, + }, }, nextLink: { serializedName: "nextLink", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; diff --git a/sdk/resources-subscriptions/arm-resources-subscriptions/src/models/parameters.ts b/sdk/resources-subscriptions/arm-resources-subscriptions/src/models/parameters.ts index 2d2011c70e74..965ef83a7885 100644 --- a/sdk/resources-subscriptions/arm-resources-subscriptions/src/models/parameters.ts +++ b/sdk/resources-subscriptions/arm-resources-subscriptions/src/models/parameters.ts @@ -9,11 +9,11 @@ import { OperationParameter, OperationURLParameter, - OperationQueryParameter + OperationQueryParameter, } from "@azure/core-client"; import { CheckZonePeersRequest as CheckZonePeersRequestMapper, - ResourceName as ResourceNameMapper + ResourceName as ResourceNameMapper, } from "../models/mappers"; export const accept: OperationParameter = { @@ -23,9 +23,9 @@ export const accept: OperationParameter = { isConstant: true, serializedName: "Accept", type: { - name: "String" - } - } + name: "String", + }, + }, }; export const $host: OperationURLParameter = { @@ -34,10 +34,10 @@ export const $host: OperationURLParameter = { serializedName: "$host", required: true, type: { - name: "String" - } + name: "String", + }, }, - skipEncoding: true + skipEncoding: true, }; export const apiVersion: OperationQueryParameter = { @@ -47,9 +47,9 @@ export const apiVersion: OperationQueryParameter = { isConstant: true, serializedName: "api-version", type: { - name: "String" - } - } + name: "String", + }, + }, }; export const nextLink: OperationURLParameter = { @@ -58,10 +58,10 @@ export const nextLink: OperationURLParameter = { serializedName: "nextLink", required: true, type: { - name: "String" - } + name: "String", + }, }, - skipEncoding: true + skipEncoding: true, }; export const subscriptionId: OperationURLParameter = { @@ -70,9 +70,9 @@ export const subscriptionId: OperationURLParameter = { serializedName: "subscriptionId", required: true, type: { - name: "String" - } - } + name: "String", + }, + }, }; export const includeExtendedLocations: OperationQueryParameter = { @@ -80,9 +80,9 @@ export const includeExtendedLocations: OperationQueryParameter = { mapper: { serializedName: "includeExtendedLocations", type: { - name: "Boolean" - } - } + name: "Boolean", + }, + }, }; export const contentType: OperationParameter = { @@ -92,17 +92,17 @@ export const contentType: OperationParameter = { isConstant: true, serializedName: "Content-Type", type: { - name: "String" - } - } + name: "String", + }, + }, }; export const parameters: OperationParameter = { parameterPath: "parameters", - mapper: CheckZonePeersRequestMapper + mapper: CheckZonePeersRequestMapper, }; export const resourceNameDefinition: OperationParameter = { parameterPath: ["options", "resourceNameDefinition"], - mapper: ResourceNameMapper + mapper: ResourceNameMapper, }; diff --git a/sdk/resources-subscriptions/arm-resources-subscriptions/src/operations/operations.ts b/sdk/resources-subscriptions/arm-resources-subscriptions/src/operations/operations.ts index 3808ae14959a..9e27d8928e4d 100644 --- a/sdk/resources-subscriptions/arm-resources-subscriptions/src/operations/operations.ts +++ b/sdk/resources-subscriptions/arm-resources-subscriptions/src/operations/operations.ts @@ -18,7 +18,7 @@ import { OperationsListNextOptionalParams, OperationsListOptionalParams, OperationsListResponse, - OperationsListNextResponse + OperationsListNextResponse, } from "../models"; /// @@ -39,7 +39,7 @@ export class OperationsImpl implements Operations { * @param options The options parameters. */ public list( - options?: OperationsListOptionalParams + options?: OperationsListOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listPagingAll(options); return { @@ -54,13 +54,13 @@ export class OperationsImpl implements Operations { throw new Error("maxPageSize is not supported by this operation."); } return this.listPagingPage(options, settings); - } + }, }; } private async *listPagingPage( options?: OperationsListOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: OperationsListResponse; let continuationToken = settings?.continuationToken; @@ -81,7 +81,7 @@ export class OperationsImpl implements Operations { } private async *listPagingAll( - options?: OperationsListOptionalParams + options?: OperationsListOptionalParams, ): AsyncIterableIterator { for await (const page of this.listPagingPage(options)) { yield* page; @@ -93,7 +93,7 @@ export class OperationsImpl implements Operations { * @param options The options parameters. */ private _list( - options?: OperationsListOptionalParams + options?: OperationsListOptionalParams, ): Promise { return this.client.sendOperationRequest({ options }, listOperationSpec); } @@ -105,11 +105,11 @@ export class OperationsImpl implements Operations { */ private _listNext( nextLink: string, - options?: OperationsListNextOptionalParams + options?: OperationsListNextOptionalParams, ): Promise { return this.client.sendOperationRequest( { nextLink, options }, - listNextOperationSpec + listNextOperationSpec, ); } } @@ -121,29 +121,29 @@ const listOperationSpec: coreClient.OperationSpec = { httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.OperationListResult + bodyMapper: Mappers.OperationListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [Parameters.$host], headerParameters: [Parameters.accept], - serializer + serializer, }; const listNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.OperationListResult + bodyMapper: Mappers.OperationListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, urlParameters: [Parameters.$host, Parameters.nextLink], headerParameters: [Parameters.accept], - serializer + serializer, }; diff --git a/sdk/resources-subscriptions/arm-resources-subscriptions/src/operations/subscriptions.ts b/sdk/resources-subscriptions/arm-resources-subscriptions/src/operations/subscriptions.ts index 1221f4bb1b8f..19c42462e4a5 100644 --- a/sdk/resources-subscriptions/arm-resources-subscriptions/src/operations/subscriptions.ts +++ b/sdk/resources-subscriptions/arm-resources-subscriptions/src/operations/subscriptions.ts @@ -26,7 +26,7 @@ import { CheckZonePeersRequest, SubscriptionsCheckZonePeersOptionalParams, SubscriptionsCheckZonePeersResponse, - SubscriptionsListNextResponse + SubscriptionsListNextResponse, } from "../models"; /// @@ -50,7 +50,7 @@ export class SubscriptionsImpl implements Subscriptions { */ public listLocations( subscriptionId: string, - options?: SubscriptionsListLocationsOptionalParams + options?: SubscriptionsListLocationsOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listLocationsPagingAll(subscriptionId, options); return { @@ -65,14 +65,14 @@ export class SubscriptionsImpl implements Subscriptions { throw new Error("maxPageSize is not supported by this operation."); } return this.listLocationsPagingPage(subscriptionId, options, settings); - } + }, }; } private async *listLocationsPagingPage( subscriptionId: string, options?: SubscriptionsListLocationsOptionalParams, - _settings?: PageSettings + _settings?: PageSettings, ): AsyncIterableIterator { let result: SubscriptionsListLocationsResponse; result = await this._listLocations(subscriptionId, options); @@ -81,11 +81,11 @@ export class SubscriptionsImpl implements Subscriptions { private async *listLocationsPagingAll( subscriptionId: string, - options?: SubscriptionsListLocationsOptionalParams + options?: SubscriptionsListLocationsOptionalParams, ): AsyncIterableIterator { for await (const page of this.listLocationsPagingPage( subscriptionId, - options + options, )) { yield* page; } @@ -96,7 +96,7 @@ export class SubscriptionsImpl implements Subscriptions { * @param options The options parameters. */ public list( - options?: SubscriptionsListOptionalParams + options?: SubscriptionsListOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listPagingAll(options); return { @@ -111,13 +111,13 @@ export class SubscriptionsImpl implements Subscriptions { throw new Error("maxPageSize is not supported by this operation."); } return this.listPagingPage(options, settings); - } + }, }; } private async *listPagingPage( options?: SubscriptionsListOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: SubscriptionsListResponse; let continuationToken = settings?.continuationToken; @@ -138,7 +138,7 @@ export class SubscriptionsImpl implements Subscriptions { } private async *listPagingAll( - options?: SubscriptionsListOptionalParams + options?: SubscriptionsListOptionalParams, ): AsyncIterableIterator { for await (const page of this.listPagingPage(options)) { yield* page; @@ -153,11 +153,11 @@ export class SubscriptionsImpl implements Subscriptions { */ private _listLocations( subscriptionId: string, - options?: SubscriptionsListLocationsOptionalParams + options?: SubscriptionsListLocationsOptionalParams, ): Promise { return this.client.sendOperationRequest( { subscriptionId, options }, - listLocationsOperationSpec + listLocationsOperationSpec, ); } @@ -168,11 +168,11 @@ export class SubscriptionsImpl implements Subscriptions { */ get( subscriptionId: string, - options?: SubscriptionsGetOptionalParams + options?: SubscriptionsGetOptionalParams, ): Promise { return this.client.sendOperationRequest( { subscriptionId, options }, - getOperationSpec + getOperationSpec, ); } @@ -181,7 +181,7 @@ export class SubscriptionsImpl implements Subscriptions { * @param options The options parameters. */ private _list( - options?: SubscriptionsListOptionalParams + options?: SubscriptionsListOptionalParams, ): Promise { return this.client.sendOperationRequest({ options }, listOperationSpec); } @@ -195,11 +195,11 @@ export class SubscriptionsImpl implements Subscriptions { checkZonePeers( subscriptionId: string, parameters: CheckZonePeersRequest, - options?: SubscriptionsCheckZonePeersOptionalParams + options?: SubscriptionsCheckZonePeersOptionalParams, ): Promise { return this.client.sendOperationRequest( { subscriptionId, parameters, options }, - checkZonePeersOperationSpec + checkZonePeersOperationSpec, ); } @@ -210,11 +210,11 @@ export class SubscriptionsImpl implements Subscriptions { */ private _listNext( nextLink: string, - options?: SubscriptionsListNextOptionalParams + options?: SubscriptionsListNextOptionalParams, ): Promise { return this.client.sendOperationRequest( { nextLink, options }, - listNextOperationSpec + listNextOperationSpec, ); } } @@ -226,80 +226,79 @@ const listLocationsOperationSpec: coreClient.OperationSpec = { httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.LocationListResult + bodyMapper: Mappers.LocationListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion, Parameters.includeExtendedLocations], urlParameters: [Parameters.$host, Parameters.subscriptionId], headerParameters: [Parameters.accept], - serializer + serializer, }; const getOperationSpec: coreClient.OperationSpec = { path: "/subscriptions/{subscriptionId}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.Subscription + bodyMapper: Mappers.Subscription, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [Parameters.$host, Parameters.subscriptionId], headerParameters: [Parameters.accept], - serializer + serializer, }; const listOperationSpec: coreClient.OperationSpec = { path: "/subscriptions", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.SubscriptionListResult + bodyMapper: Mappers.SubscriptionListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [Parameters.$host], headerParameters: [Parameters.accept], - serializer + serializer, }; const checkZonePeersOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/providers/Microsoft.Resources/checkZonePeers/", + path: "/subscriptions/{subscriptionId}/providers/Microsoft.Resources/checkZonePeers/", httpMethod: "POST", responses: { 200: { - bodyMapper: Mappers.CheckZonePeersResult + bodyMapper: Mappers.CheckZonePeersResult, }, default: { - bodyMapper: Mappers.ErrorResponseAutoGenerated - } + bodyMapper: Mappers.ErrorResponseAutoGenerated, + }, }, requestBody: Parameters.parameters, queryParameters: [Parameters.apiVersion], urlParameters: [Parameters.$host, Parameters.subscriptionId], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", - serializer + serializer, }; const listNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.SubscriptionListResult + bodyMapper: Mappers.SubscriptionListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, urlParameters: [Parameters.$host, Parameters.nextLink], headerParameters: [Parameters.accept], - serializer + serializer, }; diff --git a/sdk/resources-subscriptions/arm-resources-subscriptions/src/operations/tenants.ts b/sdk/resources-subscriptions/arm-resources-subscriptions/src/operations/tenants.ts index e7ccb62eed12..1ca29fe03ca3 100644 --- a/sdk/resources-subscriptions/arm-resources-subscriptions/src/operations/tenants.ts +++ b/sdk/resources-subscriptions/arm-resources-subscriptions/src/operations/tenants.ts @@ -18,7 +18,7 @@ import { TenantsListNextOptionalParams, TenantsListOptionalParams, TenantsListResponse, - TenantsListNextResponse + TenantsListNextResponse, } from "../models"; /// @@ -39,7 +39,7 @@ export class TenantsImpl implements Tenants { * @param options The options parameters. */ public list( - options?: TenantsListOptionalParams + options?: TenantsListOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listPagingAll(options); return { @@ -54,13 +54,13 @@ export class TenantsImpl implements Tenants { throw new Error("maxPageSize is not supported by this operation."); } return this.listPagingPage(options, settings); - } + }, }; } private async *listPagingPage( options?: TenantsListOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: TenantsListResponse; let continuationToken = settings?.continuationToken; @@ -81,7 +81,7 @@ export class TenantsImpl implements Tenants { } private async *listPagingAll( - options?: TenantsListOptionalParams + options?: TenantsListOptionalParams, ): AsyncIterableIterator { for await (const page of this.listPagingPage(options)) { yield* page; @@ -93,7 +93,7 @@ export class TenantsImpl implements Tenants { * @param options The options parameters. */ private _list( - options?: TenantsListOptionalParams + options?: TenantsListOptionalParams, ): Promise { return this.client.sendOperationRequest({ options }, listOperationSpec); } @@ -105,11 +105,11 @@ export class TenantsImpl implements Tenants { */ private _listNext( nextLink: string, - options?: TenantsListNextOptionalParams + options?: TenantsListNextOptionalParams, ): Promise { return this.client.sendOperationRequest( { nextLink, options }, - listNextOperationSpec + listNextOperationSpec, ); } } @@ -121,29 +121,29 @@ const listOperationSpec: coreClient.OperationSpec = { httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.TenantListResult + bodyMapper: Mappers.TenantListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [Parameters.$host], headerParameters: [Parameters.accept], - serializer + serializer, }; const listNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.TenantListResult + bodyMapper: Mappers.TenantListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, urlParameters: [Parameters.$host, Parameters.nextLink], headerParameters: [Parameters.accept], - serializer + serializer, }; diff --git a/sdk/resources-subscriptions/arm-resources-subscriptions/src/operationsInterfaces/operations.ts b/sdk/resources-subscriptions/arm-resources-subscriptions/src/operationsInterfaces/operations.ts index ac34435954c0..65cdf8035ab0 100644 --- a/sdk/resources-subscriptions/arm-resources-subscriptions/src/operationsInterfaces/operations.ts +++ b/sdk/resources-subscriptions/arm-resources-subscriptions/src/operationsInterfaces/operations.ts @@ -17,6 +17,6 @@ export interface Operations { * @param options The options parameters. */ list( - options?: OperationsListOptionalParams + options?: OperationsListOptionalParams, ): PagedAsyncIterableIterator; } diff --git a/sdk/resources-subscriptions/arm-resources-subscriptions/src/operationsInterfaces/subscriptions.ts b/sdk/resources-subscriptions/arm-resources-subscriptions/src/operationsInterfaces/subscriptions.ts index 4142f4ea2482..31d2bad21da2 100644 --- a/sdk/resources-subscriptions/arm-resources-subscriptions/src/operationsInterfaces/subscriptions.ts +++ b/sdk/resources-subscriptions/arm-resources-subscriptions/src/operationsInterfaces/subscriptions.ts @@ -16,7 +16,7 @@ import { SubscriptionsGetResponse, CheckZonePeersRequest, SubscriptionsCheckZonePeersOptionalParams, - SubscriptionsCheckZonePeersResponse + SubscriptionsCheckZonePeersResponse, } from "../models"; /// @@ -30,14 +30,14 @@ export interface Subscriptions { */ listLocations( subscriptionId: string, - options?: SubscriptionsListLocationsOptionalParams + options?: SubscriptionsListLocationsOptionalParams, ): PagedAsyncIterableIterator; /** * Gets all subscriptions for a tenant. * @param options The options parameters. */ list( - options?: SubscriptionsListOptionalParams + options?: SubscriptionsListOptionalParams, ): PagedAsyncIterableIterator; /** * Gets details about a specified subscription. @@ -46,7 +46,7 @@ export interface Subscriptions { */ get( subscriptionId: string, - options?: SubscriptionsGetOptionalParams + options?: SubscriptionsGetOptionalParams, ): Promise; /** * Compares a subscriptions logical zone mapping @@ -57,6 +57,6 @@ export interface Subscriptions { checkZonePeers( subscriptionId: string, parameters: CheckZonePeersRequest, - options?: SubscriptionsCheckZonePeersOptionalParams + options?: SubscriptionsCheckZonePeersOptionalParams, ): Promise; } diff --git a/sdk/resources-subscriptions/arm-resources-subscriptions/src/operationsInterfaces/tenants.ts b/sdk/resources-subscriptions/arm-resources-subscriptions/src/operationsInterfaces/tenants.ts index 423790d0f0ac..222c152ed5f1 100644 --- a/sdk/resources-subscriptions/arm-resources-subscriptions/src/operationsInterfaces/tenants.ts +++ b/sdk/resources-subscriptions/arm-resources-subscriptions/src/operationsInterfaces/tenants.ts @@ -17,6 +17,6 @@ export interface Tenants { * @param options The options parameters. */ list( - options?: TenantsListOptionalParams + options?: TenantsListOptionalParams, ): PagedAsyncIterableIterator; } diff --git a/sdk/resources-subscriptions/arm-resources-subscriptions/src/pagingHelper.ts b/sdk/resources-subscriptions/arm-resources-subscriptions/src/pagingHelper.ts index 269a2b9814b5..205cccc26592 100644 --- a/sdk/resources-subscriptions/arm-resources-subscriptions/src/pagingHelper.ts +++ b/sdk/resources-subscriptions/arm-resources-subscriptions/src/pagingHelper.ts @@ -28,7 +28,7 @@ export function getContinuationToken(page: unknown): string | undefined { export function setContinuationToken( page: unknown, - continuationToken: string | undefined + continuationToken: string | undefined, ): void { if (typeof page !== "object" || page === null || !continuationToken) { return; diff --git a/sdk/resources-subscriptions/arm-resources-subscriptions/src/subscriptionClient.ts b/sdk/resources-subscriptions/arm-resources-subscriptions/src/subscriptionClient.ts index 406ae23d19bf..5952a6ef8746 100644 --- a/sdk/resources-subscriptions/arm-resources-subscriptions/src/subscriptionClient.ts +++ b/sdk/resources-subscriptions/arm-resources-subscriptions/src/subscriptionClient.ts @@ -11,7 +11,7 @@ import * as coreRestPipeline from "@azure/core-rest-pipeline"; import { PipelineRequest, PipelineResponse, - SendRequest + SendRequest, } from "@azure/core-rest-pipeline"; import * as coreAuth from "@azure/core-auth"; import { OperationsImpl, SubscriptionsImpl, TenantsImpl } from "./operations"; @@ -21,7 +21,7 @@ import * as Mappers from "./models/mappers"; import { SubscriptionClientOptionalParams, CheckResourceNameOptionalParams, - CheckResourceNameResponse + CheckResourceNameResponse, } from "./models"; export class SubscriptionClient extends coreClient.ServiceClient { @@ -35,7 +35,7 @@ export class SubscriptionClient extends coreClient.ServiceClient { */ constructor( credentials: coreAuth.TokenCredential, - options?: SubscriptionClientOptionalParams + options?: SubscriptionClientOptionalParams, ) { if (credentials === undefined) { throw new Error("'credentials' cannot be null"); @@ -47,7 +47,7 @@ export class SubscriptionClient extends coreClient.ServiceClient { } const defaults: SubscriptionClientOptionalParams = { requestContentType: "application/json; charset=utf-8", - credential: credentials + credential: credentials, }; const packageDetails = `azsdk-js-arm-resources-subscriptions/2.1.1`; @@ -60,20 +60,21 @@ export class SubscriptionClient extends coreClient.ServiceClient { ...defaults, ...options, userAgentOptions: { - userAgentPrefix + userAgentPrefix, }, endpoint: - options.endpoint ?? options.baseUri ?? "https://management.azure.com" + options.endpoint ?? options.baseUri ?? "https://management.azure.com", }; super(optionsWithDefaults); let bearerTokenAuthenticationPolicyFound: boolean = false; if (options?.pipeline && options.pipeline.getOrderedPolicies().length > 0) { - const pipelinePolicies: coreRestPipeline.PipelinePolicy[] = options.pipeline.getOrderedPolicies(); + const pipelinePolicies: coreRestPipeline.PipelinePolicy[] = + options.pipeline.getOrderedPolicies(); bearerTokenAuthenticationPolicyFound = pipelinePolicies.some( (pipelinePolicy) => pipelinePolicy.name === - coreRestPipeline.bearerTokenAuthenticationPolicyName + coreRestPipeline.bearerTokenAuthenticationPolicyName, ); } if ( @@ -83,7 +84,7 @@ export class SubscriptionClient extends coreClient.ServiceClient { !bearerTokenAuthenticationPolicyFound ) { this.pipeline.removePolicy({ - name: coreRestPipeline.bearerTokenAuthenticationPolicyName + name: coreRestPipeline.bearerTokenAuthenticationPolicyName, }); this.pipeline.addPolicy( coreRestPipeline.bearerTokenAuthenticationPolicy({ @@ -93,9 +94,9 @@ export class SubscriptionClient extends coreClient.ServiceClient { `${optionsWithDefaults.endpoint}/.default`, challengeCallbacks: { authorizeRequestOnChallenge: - coreClient.authorizeRequestOnClaimChallenge - } - }) + coreClient.authorizeRequestOnClaimChallenge, + }, + }), ); } @@ -117,7 +118,7 @@ export class SubscriptionClient extends coreClient.ServiceClient { name: "CustomApiVersionPolicy", async sendRequest( request: PipelineRequest, - next: SendRequest + next: SendRequest, ): Promise { const param = request.url.split("?"); if (param.length > 1) { @@ -131,7 +132,7 @@ export class SubscriptionClient extends coreClient.ServiceClient { request.url = param[0] + "?" + newParams.join("&"); } return next(request); - } + }, }; this.pipeline.addPolicy(apiVersionPolicy); } @@ -142,11 +143,11 @@ export class SubscriptionClient extends coreClient.ServiceClient { * @param options The options parameters. */ checkResourceName( - options?: CheckResourceNameOptionalParams + options?: CheckResourceNameOptionalParams, ): Promise { return this.sendOperationRequest( { options }, - checkResourceNameOperationSpec + checkResourceNameOperationSpec, ); } @@ -162,16 +163,16 @@ const checkResourceNameOperationSpec: coreClient.OperationSpec = { httpMethod: "POST", responses: { 200: { - bodyMapper: Mappers.CheckResourceNameResult + bodyMapper: Mappers.CheckResourceNameResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, requestBody: Parameters.resourceNameDefinition, queryParameters: [Parameters.apiVersion], urlParameters: [Parameters.$host], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", - serializer + serializer, }; diff --git a/sdk/resources-subscriptions/arm-resources-subscriptions/test/sampleTest.ts b/sdk/resources-subscriptions/arm-resources-subscriptions/test/sampleTest.ts new file mode 100644 index 000000000000..d64be981b694 --- /dev/null +++ b/sdk/resources-subscriptions/arm-resources-subscriptions/test/sampleTest.ts @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +import { + Recorder, + RecorderStartOptions, + env, +} from "@azure-tools/test-recorder"; +import { assert } from "chai"; +import { Context } from "mocha"; + +const replaceableVariables: Record = { + AZURE_CLIENT_ID: "azure_client_id", + AZURE_CLIENT_SECRET: "azure_client_secret", + AZURE_TENANT_ID: "88888888-8888-8888-8888-888888888888", + SUBSCRIPTION_ID: "azure_subscription_id", +}; + +const recorderOptions: RecorderStartOptions = { + envSetupForPlayback: replaceableVariables, +}; + +describe("My test", () => { + let recorder: Recorder; + + beforeEach(async function (this: Context) { + recorder = new Recorder(this.currentTest); + await recorder.start(recorderOptions); + }); + + afterEach(async function () { + await recorder.stop(); + }); + + it("sample test", async function () { + console.log("Hi, I'm a test!"); + }); +}); diff --git a/sdk/resources-subscriptions/arm-resources-subscriptions/tsconfig.json b/sdk/resources-subscriptions/arm-resources-subscriptions/tsconfig.json index 32cefcc4d696..615e06592f2b 100644 --- a/sdk/resources-subscriptions/arm-resources-subscriptions/tsconfig.json +++ b/sdk/resources-subscriptions/arm-resources-subscriptions/tsconfig.json @@ -15,17 +15,18 @@ ], "declaration": true, "outDir": "./dist-esm", - "importHelpers": true, - "paths": { - "@azure/arm-resources-subscriptions": [ - "./src/index" - ] - } + "importHelpers": true }, "include": [ "./src/**/*.ts", "./test/**/*.ts", - "samples-dev/**/*.ts" + "./test/**/*.ts", + "./test/**/*.ts", + "./test/**/*.ts", + "./test/**/*.ts", + "./test/**/*.ts", + "./test/**/*.ts", + "./test/**/*.ts" ], "exclude": [ "node_modules" diff --git a/sdk/resources/arm-resources/CHANGELOG.md b/sdk/resources/arm-resources/CHANGELOG.md index 98302bcdc2ab..ed5f065d2c59 100644 --- a/sdk/resources/arm-resources/CHANGELOG.md +++ b/sdk/resources/arm-resources/CHANGELOG.md @@ -1,15 +1,59 @@ # Release History - -## 5.2.1 (Unreleased) - + +## 6.0.0 (2024-11-01) + ### Features Added -### Breaking Changes - -### Bugs Fixed + - Added operation TagsOperations.beginCreateOrUpdateAtScope + - Added operation TagsOperations.beginCreateOrUpdateAtScopeAndWait + - Added operation TagsOperations.beginDeleteAtScope + - Added operation TagsOperations.beginDeleteAtScopeAndWait + - Added operation TagsOperations.beginUpdateAtScope + - Added operation TagsOperations.beginUpdateAtScopeAndWait + - Added Interface DeploymentDiagnosticsDefinition + - Added Interface DeploymentParameter + - Added Interface DeploymentValidationError + - Added Interface ErrorDetail + - Added Interface KeyVaultParameterReference + - Added Interface KeyVaultReference + - Added Interface ResourceGroupsDeleteHeaders + - Added Interface TagsCreateOrUpdateAtScopeHeaders + - Added Interface TagsDeleteAtScopeHeaders + - Added Interface TagsUpdateAtScopeHeaders + - Added Type Alias ExportTemplateOutputFormat + - Added Type Alias Level + - Added Type Alias ValidationLevel + - Interface DeploymentProperties has a new optional parameter validationLevel + - Interface DeploymentPropertiesExtended has a new optional parameter diagnostics + - Interface DeploymentPropertiesExtended has a new optional parameter validationLevel + - Interface ExportTemplateRequest has a new optional parameter outputFormat + - Interface ResourceGroupExportResult has a new optional parameter output + - Interface TagsCreateOrUpdateAtScopeOptionalParams has a new optional parameter resumeFrom + - Interface TagsCreateOrUpdateAtScopeOptionalParams has a new optional parameter updateIntervalInMs + - Interface TagsDeleteAtScopeOptionalParams has a new optional parameter resumeFrom + - Interface TagsDeleteAtScopeOptionalParams has a new optional parameter updateIntervalInMs + - Interface TagsUpdateAtScopeOptionalParams has a new optional parameter resumeFrom + - Interface TagsUpdateAtScopeOptionalParams has a new optional parameter updateIntervalInMs + - Interface WhatIfChange has a new optional parameter deploymentId + - Interface WhatIfChange has a new optional parameter identifiers + - Interface WhatIfChange has a new optional parameter symbolicName + - Interface WhatIfOperationResult has a new optional parameter diagnostics + - Interface WhatIfOperationResult has a new optional parameter potentialChanges + - Added Enum KnownExportTemplateOutputFormat + - Added Enum KnownLevel + - Added Enum KnownValidationLevel -### Other Changes +### Breaking Changes + - Removed operation TagsOperations.createOrUpdateAtScope + - Removed operation TagsOperations.deleteAtScope + - Removed operation TagsOperations.updateAtScope + - Class ResourceManagementClient has a new signature + - Type of parameter parameters of interface DeploymentProperties is changed from Record to { + [propertyName: string]: DeploymentParameter; + } + + ## 5.2.0 (2023-03-13) ### Features Added @@ -51,7 +95,7 @@ ## 5.0.1 (2022-04-18) -### Features Added +**features** - Bug fix @@ -63,4 +107,4 @@ To understand the detail of the change, please refer to [Changelog](https://aka. To migrate the existing applications to the latest version, please refer to [Migration Guide](https://aka.ms/js-track2-migration-guide). -To learn more, please refer to our documentation [Quick Start](https://aka.ms/azsdk/js/mgmt/quickstart ). +To learn more, please refer to our documentation [Quick Start](https://aka.ms/azsdk/js/mgmt/quickstart). diff --git a/sdk/resources/arm-resources/LICENSE b/sdk/resources/arm-resources/LICENSE index 3a1d9b6f24f7..7d5934740965 100644 --- a/sdk/resources/arm-resources/LICENSE +++ b/sdk/resources/arm-resources/LICENSE @@ -1,6 +1,6 @@ The MIT License (MIT) -Copyright (c) 2023 Microsoft +Copyright (c) 2024 Microsoft Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal diff --git a/sdk/resources/arm-resources/_meta.json b/sdk/resources/arm-resources/_meta.json index e588fd1b883e..28591836c37e 100644 --- a/sdk/resources/arm-resources/_meta.json +++ b/sdk/resources/arm-resources/_meta.json @@ -1,8 +1,8 @@ { - "commit": "a42f1b58607091c4f255ead152a8ef323fa0b280", - "readme": "specification\\resources\\resource-manager\\readme.md", - "autorest_command": "autorest --version=3.9.3 --typescript --modelerfour.lenient-model-deduplication --azure-arm --head-as-boolean=true --license-header=MICROSOFT_MIT_NO_VERSION --generate-test --typescript-sdks-folder=D:\\Git\\azure-sdk-for-js ..\\azure-rest-api-specs\\specification\\resources\\resource-manager\\readme.md --use=@autorest/typescript@6.0.0-rc.9.20230306.1 --generate-sample=true", + "commit": "5342edb61d78cec6e07b17a6cd8f7749c6697272", + "readme": "specification/resources/resource-manager/readme.md", + "autorest_command": "autorest --version=3.9.7 --typescript --modelerfour.lenient-model-deduplication --azure-arm --head-as-boolean=true --license-header=MICROSOFT_MIT_NO_VERSION --generate-test --typescript-sdks-folder=/mnt/vss/_work/1/s/azure-sdk-for-js ../azure-rest-api-specs/specification/resources/resource-manager/readme.md --use=@autorest/typescript@^6.0.12", "repository_url": "https://github.com/Azure/azure-rest-api-specs.git", - "release_tool": "@azure-tools/js-sdk-release-tools@2.6.2", - "use": "@autorest/typescript@6.0.0-rc.9.20230306.1" + "release_tool": "@azure-tools/js-sdk-release-tools@2.7.14", + "use": "@autorest/typescript@^6.0.12" } \ No newline at end of file diff --git a/sdk/resources/arm-resources/package.json b/sdk/resources/arm-resources/package.json index 11420746013b..0c54a874c263 100644 --- a/sdk/resources/arm-resources/package.json +++ b/sdk/resources/arm-resources/package.json @@ -3,17 +3,17 @@ "sdk-type": "mgmt", "author": "Microsoft Corporation", "description": "A generated SDK for ResourceManagementClient.", - "version": "5.2.1", + "version": "6.0.0", "engines": { "node": ">=18.0.0" }, "dependencies": { - "@azure/abort-controller": "^1.0.0", - "@azure/core-auth": "^1.3.0", - "@azure/core-client": "^1.7.0", - "@azure/core-lro": "^2.5.0", + "@azure/core-lro": "^2.5.4", + "@azure/abort-controller": "^2.1.2", "@azure/core-paging": "^1.2.0", - "@azure/core-rest-pipeline": "^1.8.0", + "@azure/core-client": "^1.7.0", + "@azure/core-auth": "^1.6.0", + "@azure/core-rest-pipeline": "^1.14.0", "tslib": "^2.2.0" }, "keywords": [ @@ -28,19 +28,24 @@ "module": "./dist-esm/src/index.js", "types": "./types/arm-resources.d.ts", "devDependencies": { - "@azure-tools/test-credential": "^1.0.0", - "@azure-tools/test-recorder": "^3.0.0", + "@microsoft/api-extractor": "^7.31.1", + "mkdirp": "^3.0.1", + "typescript": "~5.5.3", + "uglify-js": "^3.4.9", + "rimraf": "^5.0.0", + "dotenv": "^16.0.0", "@azure/dev-tool": "^1.0.0", - "@azure/identity": "^4.0.1", - "@types/chai": "^4.2.8", + "@azure/identity": "^4.2.1", + "@azure-tools/test-recorder": "^3.0.0", + "@azure-tools/test-credential": "^1.1.0", + "mocha": "^10.0.0", "@types/mocha": "^10.0.0", - "@types/node": "^18.0.0", + "tsx": "^4.7.1", + "@types/chai": "^4.2.8", "chai": "^4.2.0", "cross-env": "^7.0.2", - "dotenv": "^16.0.0", - "mocha": "^10.0.0", - "ts-node": "^10.0.0", - "typescript": "~5.6.2" + "@types/node": "^18.0.0", + "ts-node": "^10.0.0" }, "repository": { "type": "git", @@ -67,30 +72,29 @@ "types/*" ], "scripts": { - "build": "npm run clean && tsc && dev-tool run bundle && npm run minify && dev-tool run vendored mkdirp ./review && npm run extract-api", - "build:browser": "echo skipped", + "build": "npm run clean && tsc && dev-tool run bundle && npm run minify && mkdirp ./review && npm run extract-api", + "minify": "uglifyjs -c -m --comments --source-map \"content='./dist/index.js.map'\" -o ./dist/index.min.js ./dist/index.js", + "prepack": "npm run build", + "pack": "npm pack 2>&1", + "extract-api": "dev-tool run extract-api", + "lint": "echo skipped", + "clean": "rimraf --glob dist dist-browser dist-esm test-dist temp types *.tgz *.log", "build:node": "echo skipped", - "build:samples": "echo skipped.", + "build:browser": "echo skipped", "build:test": "echo skipped", + "build:samples": "echo skipped.", "check-format": "echo skipped", - "clean": "dev-tool run vendored rimraf --glob dist dist-browser dist-esm test-dist temp types *.tgz *.log", "execute:samples": "echo skipped", - "extract-api": "dev-tool run extract-api", "format": "echo skipped", - "integration-test": "npm run integration-test:node && npm run integration-test:browser", - "integration-test:browser": "echo skipped", - "integration-test:node": "dev-tool run test:node-ts-input -- --timeout 1200000 'test/*.ts'", - "lint": "echo skipped", - "minify": "dev-tool run vendored uglifyjs -c -m --comments --source-map \"content='./dist/index.js.map'\" -o ./dist/index.min.js ./dist/index.js", - "pack": "npm pack 2>&1", - "prepack": "npm run build", "test": "npm run integration-test", - "test:browser": "echo skipped", "test:node": "echo skipped", + "test:browser": "echo skipped", "unit-test": "npm run unit-test:node && npm run unit-test:browser", - "unit-test:browser": "echo skipped", "unit-test:node": "cross-env TEST_MODE=playback npm run integration-test:node", - "update-snippets": "echo skipped" + "unit-test:browser": "echo skipped", + "integration-test": "npm run integration-test:node && npm run integration-test:browser", + "integration-test:node": "dev-tool run test:node-ts-input -- --timeout 1200000 'test/*.ts'", + "integration-test:browser": "echo skipped" }, "sideEffects": false, "//metadata": { @@ -102,13 +106,5 @@ ] }, "autoPublish": true, - "homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/resources/arm-resources", - "//sampleConfiguration": { - "productName": "", - "productSlugs": [ - "azure" - ], - "disableDocsMs": true, - "apiRefLink": "https://docs.microsoft.com/javascript/api/@azure/arm-resources?view=azure-node-preview" - } -} + "homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/resources/arm-resources" +} \ No newline at end of file diff --git a/sdk/resources/arm-resources/review/arm-resources.api.md b/sdk/resources/arm-resources/review/arm-resources.api.md index 4d8eb74a80a8..c361864810e3 100644 --- a/sdk/resources/arm-resources/review/arm-resources.api.md +++ b/sdk/resources/arm-resources/review/arm-resources.api.md @@ -96,6 +96,15 @@ export interface Deployment { }; } +// @public (undocumented) +export interface DeploymentDiagnosticsDefinition { + readonly additionalInfo?: ErrorAdditionalInfo[]; + readonly code: string; + readonly level: Level; + readonly message: string; + readonly target?: string; +} + // @public export interface DeploymentExportResult { template?: Record; @@ -278,16 +287,25 @@ export interface DeploymentOperationsListResult { value?: DeploymentOperation[]; } +// @public +export interface DeploymentParameter { + reference?: KeyVaultParameterReference; + value?: any; +} + // @public export interface DeploymentProperties { debugSetting?: DebugSetting; expressionEvaluationOptions?: ExpressionEvaluationOptions; mode: DeploymentMode; onErrorDeployment?: OnErrorDeployment; - parameters?: Record; + parameters?: { + [propertyName: string]: DeploymentParameter; + }; parametersLink?: ParametersLink; template?: Record; templateLink?: TemplateLink; + validationLevel?: ValidationLevel; } // @public @@ -295,6 +313,7 @@ export interface DeploymentPropertiesExtended { readonly correlationId?: string; readonly debugSetting?: DebugSetting; readonly dependencies?: Dependency[]; + readonly diagnostics?: DeploymentDiagnosticsDefinition[]; readonly duration?: string; readonly error?: ErrorResponse; readonly mode?: DeploymentMode; @@ -309,6 +328,7 @@ export interface DeploymentPropertiesExtended { readonly templateLink?: TemplateLink; readonly timestamp?: Date; readonly validatedResources?: ResourceReference[]; + validationLevel?: ValidationLevel; } // @public @@ -683,7 +703,7 @@ export interface DeploymentsValidateAtManagementGroupScopeOptionalParams extends } // @public -export type DeploymentsValidateAtManagementGroupScopeResponse = DeploymentValidateResult; +export type DeploymentsValidateAtManagementGroupScopeResponse = DeploymentExtended; // @public export interface DeploymentsValidateAtScopeOptionalParams extends coreClient.OperationOptions { @@ -692,7 +712,7 @@ export interface DeploymentsValidateAtScopeOptionalParams extends coreClient.Ope } // @public -export type DeploymentsValidateAtScopeResponse = DeploymentValidateResult; +export type DeploymentsValidateAtScopeResponse = DeploymentExtended; // @public export interface DeploymentsValidateAtSubscriptionScopeOptionalParams extends coreClient.OperationOptions { @@ -701,7 +721,7 @@ export interface DeploymentsValidateAtSubscriptionScopeOptionalParams extends co } // @public -export type DeploymentsValidateAtSubscriptionScopeResponse = DeploymentValidateResult; +export type DeploymentsValidateAtSubscriptionScopeResponse = DeploymentExtended; // @public export interface DeploymentsValidateAtTenantScopeOptionalParams extends coreClient.OperationOptions { @@ -710,7 +730,7 @@ export interface DeploymentsValidateAtTenantScopeOptionalParams extends coreClie } // @public -export type DeploymentsValidateAtTenantScopeResponse = DeploymentValidateResult; +export type DeploymentsValidateAtTenantScopeResponse = DeploymentExtended; // @public export interface DeploymentsValidateOptionalParams extends coreClient.OperationOptions { @@ -719,7 +739,7 @@ export interface DeploymentsValidateOptionalParams extends coreClient.OperationO } // @public -export type DeploymentsValidateResponse = DeploymentValidateResult; +export type DeploymentsValidateResponse = DeploymentExtended; // @public export interface DeploymentsWhatIfAtManagementGroupScopeHeaders { @@ -782,9 +802,8 @@ export interface DeploymentsWhatIfOptionalParams extends coreClient.OperationOpt export type DeploymentsWhatIfResponse = WhatIfOperationResult; // @public -export interface DeploymentValidateResult { - readonly error?: ErrorResponse; - properties?: DeploymentPropertiesExtended; +export interface DeploymentValidationError { + error?: ErrorDetail; } // @public @@ -809,6 +828,15 @@ export interface ErrorAdditionalInfo { readonly type?: string; } +// @public +export interface ErrorDetail { + readonly additionalInfo?: ErrorAdditionalInfo[]; + readonly code?: string; + readonly details?: ErrorDetail[]; + readonly message?: string; + readonly target?: string; +} + // @public export interface ErrorResponse { readonly additionalInfo?: ErrorAdditionalInfo[]; @@ -818,9 +846,13 @@ export interface ErrorResponse { readonly target?: string; } +// @public +export type ExportTemplateOutputFormat = string; + // @public export interface ExportTemplateRequest { options?: string; + outputFormat?: ExportTemplateOutputFormat; resources?: string[]; } @@ -889,6 +921,18 @@ export interface IdentityUserAssignedIdentitiesValue { readonly principalId?: string; } +// @public +export interface KeyVaultParameterReference { + keyVault: KeyVaultReference; + secretName: string; + secretVersion?: string; +} + +// @public +export interface KeyVaultReference { + id: string; +} + // @public export enum KnownAliasPathAttributes { Modifiable = "Modifiable", @@ -907,6 +951,12 @@ export enum KnownAliasPathTokenType { String = "String" } +// @public +export enum KnownExportTemplateOutputFormat { + Bicep = "Bicep", + Json = "Json" +} + // @public export enum KnownExpressionEvaluationOptionsScopeType { Inner = "Inner", @@ -919,6 +969,13 @@ export enum KnownExtendedLocationType { EdgeZone = "EdgeZone" } +// @public +export enum KnownLevel { + Error = "Error", + Info = "Info", + Warning = "Warning" +} + // @public export enum KnownProviderAuthorizationConsentState { Consented = "Consented", @@ -950,6 +1007,16 @@ export enum KnownTagsPatchOperation { Replace = "Replace" } +// @public +export enum KnownValidationLevel { + Provider = "Provider", + ProviderNoRbac = "ProviderNoRbac", + Template = "Template" +} + +// @public +export type Level = string; + // @public export interface OnErrorDeployment { deploymentName?: string; @@ -1235,6 +1302,7 @@ export interface ResourceGroup { // @public export interface ResourceGroupExportResult { error?: ErrorResponse; + output?: string; template?: Record; } @@ -1294,6 +1362,11 @@ export interface ResourceGroupsCreateOrUpdateOptionalParams extends coreClient.O // @public export type ResourceGroupsCreateOrUpdateResponse = ResourceGroup; +// @public +export interface ResourceGroupsDeleteHeaders { + location?: string; +} + // @public export interface ResourceGroupsDeleteOptionalParams extends coreClient.OperationOptions { forceDeletionTypes?: string; @@ -1354,6 +1427,7 @@ export class ResourceManagementClient extends coreClient.ServiceClient { // (undocumented) $host: string; constructor(credentials: coreAuth.TokenCredential, subscriptionId: string, options?: ResourceManagementClientOptionalParams); + constructor(credentials: coreAuth.TokenCredential, options?: ResourceManagementClientOptionalParams); // (undocumented) apiVersion: string; // (undocumented) @@ -1371,7 +1445,7 @@ export class ResourceManagementClient extends coreClient.ServiceClient { // (undocumented) resources: Resources; // (undocumented) - subscriptionId: string; + subscriptionId?: string; // (undocumented) tagsOperations: TagsOperations; } @@ -1621,8 +1695,15 @@ export interface Tags { }; } +// @public +export interface TagsCreateOrUpdateAtScopeHeaders { + location?: string; +} + // @public export interface TagsCreateOrUpdateAtScopeOptionalParams extends coreClient.OperationOptions { + resumeFrom?: string; + updateIntervalInMs?: number; } // @public @@ -1642,8 +1723,15 @@ export interface TagsCreateOrUpdateValueOptionalParams extends coreClient.Operat // @public export type TagsCreateOrUpdateValueResponse = TagValue; +// @public +export interface TagsDeleteAtScopeHeaders { + location?: string; +} + // @public export interface TagsDeleteAtScopeOptionalParams extends coreClient.OperationOptions { + resumeFrom?: string; + updateIntervalInMs?: number; } // @public @@ -1683,15 +1771,18 @@ export interface TagsListResult { // @public export interface TagsOperations { + beginCreateOrUpdateAtScope(scope: string, parameters: TagsResource, options?: TagsCreateOrUpdateAtScopeOptionalParams): Promise, TagsCreateOrUpdateAtScopeResponse>>; + beginCreateOrUpdateAtScopeAndWait(scope: string, parameters: TagsResource, options?: TagsCreateOrUpdateAtScopeOptionalParams): Promise; + beginDeleteAtScope(scope: string, options?: TagsDeleteAtScopeOptionalParams): Promise, void>>; + beginDeleteAtScopeAndWait(scope: string, options?: TagsDeleteAtScopeOptionalParams): Promise; + beginUpdateAtScope(scope: string, parameters: TagsPatchResource, options?: TagsUpdateAtScopeOptionalParams): Promise, TagsUpdateAtScopeResponse>>; + beginUpdateAtScopeAndWait(scope: string, parameters: TagsPatchResource, options?: TagsUpdateAtScopeOptionalParams): Promise; createOrUpdate(tagName: string, options?: TagsCreateOrUpdateOptionalParams): Promise; - createOrUpdateAtScope(scope: string, parameters: TagsResource, options?: TagsCreateOrUpdateAtScopeOptionalParams): Promise; createOrUpdateValue(tagName: string, tagValue: string, options?: TagsCreateOrUpdateValueOptionalParams): Promise; delete(tagName: string, options?: TagsDeleteOptionalParams): Promise; - deleteAtScope(scope: string, options?: TagsDeleteAtScopeOptionalParams): Promise; deleteValue(tagName: string, tagValue: string, options?: TagsDeleteValueOptionalParams): Promise; getAtScope(scope: string, options?: TagsGetAtScopeOptionalParams): Promise; list(options?: TagsListOptionalParams): PagedAsyncIterableIterator; - updateAtScope(scope: string, parameters: TagsPatchResource, options?: TagsUpdateAtScopeOptionalParams): Promise; } // @public @@ -1711,8 +1802,15 @@ export interface TagsResource { readonly type?: string; } +// @public +export interface TagsUpdateAtScopeHeaders { + location?: string; +} + // @public export interface TagsUpdateAtScopeOptionalParams extends coreClient.OperationOptions { + resumeFrom?: string; + updateIntervalInMs?: number; } // @public @@ -1747,20 +1845,28 @@ export interface TemplateLink { uri?: string; } +// @public +export type ValidationLevel = string; + // @public export interface WhatIfChange { after?: Record; before?: Record; changeType: ChangeType; delta?: WhatIfPropertyChange[]; + deploymentId?: string; + identifiers?: Record; resourceId: string; + symbolicName?: string; unsupportedReason?: string; } // @public export interface WhatIfOperationResult { changes?: WhatIfChange[]; + readonly diagnostics?: DeploymentDiagnosticsDefinition[]; error?: ErrorResponse; + potentialChanges?: WhatIfChange[]; status?: string; } diff --git a/sdk/resources/arm-resources/src/lroImpl.ts b/sdk/resources/arm-resources/src/lroImpl.ts index 52f6eaacfb83..5f88efab981b 100644 --- a/sdk/resources/arm-resources/src/lroImpl.ts +++ b/sdk/resources/arm-resources/src/lroImpl.ts @@ -28,15 +28,15 @@ export function createLroSpec(inputs: { sendInitialRequest: () => sendOperationFn(args, spec), sendPollRequest: ( path: string, - options?: { abortSignal?: AbortSignalLike } + options?: { abortSignal?: AbortSignalLike }, ) => { const { requestBody, ...restSpec } = spec; return sendOperationFn(args, { ...restSpec, httpMethod: "GET", path, - abortSignal: options?.abortSignal + abortSignal: options?.abortSignal, }); - } + }, }; } diff --git a/sdk/resources/arm-resources/src/models/index.ts b/sdk/resources/arm-resources/src/models/index.ts index 2c57cb76c149..519dacb600a3 100644 --- a/sdk/resources/arm-resources/src/models/index.ts +++ b/sdk/resources/arm-resources/src/models/index.ts @@ -102,7 +102,7 @@ export interface DeploymentProperties { /** The URI of the template. Use either the templateLink property or the template property, but not both. */ templateLink?: TemplateLink; /** Name and value pairs that define the deployment parameters for the template. You use this element when you want to provide the parameter values directly in the request rather than link to an existing parameter file. Use either the parametersLink property or the parameters property, but not both. It can be a JObject or a well formed JSON string. */ - parameters?: Record; + parameters?: { [propertyName: string]: DeploymentParameter }; /** The URI of parameters file. You use this element to link to an existing parameters file. Use either the parametersLink property or the parameters property, but not both. */ parametersLink?: ParametersLink; /** The mode that is used to deploy resources. This value can be either Incremental or Complete. In Incremental mode, resources are deployed without deleting existing resources that are not included in the template. In Complete mode, resources are deployed and existing resources in the resource group that are not included in the template are deleted. Be careful when using Complete mode as you may unintentionally delete resources. */ @@ -113,6 +113,8 @@ export interface DeploymentProperties { onErrorDeployment?: OnErrorDeployment; /** Specifies whether template expressions are evaluated within the scope of the parent template or nested template. Only applicable to nested templates. If not specified, default value is outer. */ expressionEvaluationOptions?: ExpressionEvaluationOptions; + /** The validation level of the deployment */ + validationLevel?: ValidationLevel; } /** Entity representing the reference to the template. */ @@ -129,6 +131,30 @@ export interface TemplateLink { queryString?: string; } +/** Deployment parameter for the template. */ +export interface DeploymentParameter { + /** Input value to the parameter . */ + value?: any; + /** Azure Key Vault parameter reference. */ + reference?: KeyVaultParameterReference; +} + +/** Azure Key Vault parameter reference. */ +export interface KeyVaultParameterReference { + /** Azure Key Vault reference. */ + keyVault: KeyVaultReference; + /** Azure Key Vault secret name. */ + secretName: string; + /** Azure Key Vault secret version. */ + secretVersion?: string; +} + +/** Azure Key Vault reference. */ +export interface KeyVaultReference { + /** Azure Key Vault resource id. */ + id: string; +} + /** Entity representing the reference to the deployment parameters. */ export interface ParametersLink { /** The URI of the parameters file. */ @@ -269,6 +295,13 @@ export interface DeploymentPropertiesExtended { * NOTE: This property will not be serialized. It can only be populated by the server. */ readonly error?: ErrorResponse; + /** + * Contains diagnostic information collected during validation process. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly diagnostics?: DeploymentDiagnosticsDefinition[]; + /** The validation level of the deployment */ + validationLevel?: ValidationLevel; } /** Resource provider information. */ @@ -458,15 +491,67 @@ export interface ResourceReference { readonly id?: string; } -/** Information from validate template deployment response. */ -export interface DeploymentValidateResult { +export interface DeploymentDiagnosticsDefinition { /** - * The deployment validation error. + * Denotes the additional response level. * NOTE: This property will not be serialized. It can only be populated by the server. */ - readonly error?: ErrorResponse; - /** The template deployment properties. */ - properties?: DeploymentPropertiesExtended; + readonly level: Level; + /** + * The error code. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly code: string; + /** + * The error message. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly message: string; + /** + * The error target. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly target?: string; + /** + * The error additional info. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly additionalInfo?: ErrorAdditionalInfo[]; +} + +/** The template deployment validation detected failures. */ +export interface DeploymentValidationError { + /** The error detail. */ + error?: ErrorDetail; +} + +/** The error detail. */ +export interface ErrorDetail { + /** + * The error code. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly code?: string; + /** + * The error message. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly message?: string; + /** + * The error target. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly target?: string; + /** + * The error details. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly details?: ErrorDetail[]; + /** + * The error additional info. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly additionalInfo?: ErrorAdditionalInfo[]; } /** The deployment export result. */ @@ -518,12 +603,25 @@ export interface WhatIfOperationResult { error?: ErrorResponse; /** List of resource changes predicted by What-If operation. */ changes?: WhatIfChange[]; + /** List of resource changes predicted by What-If operation. */ + potentialChanges?: WhatIfChange[]; + /** + * List of resource diagnostics detected by What-If operation. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly diagnostics?: DeploymentDiagnosticsDefinition[]; } /** Information about a single resource change predicted by What-If operation. */ export interface WhatIfChange { /** Resource ID */ resourceId: string; + /** The resource id of the Deployment responsible for this change. */ + deploymentId?: string; + /** The symbolic name of the resource responsible for this change. */ + symbolicName?: string; + /** Properties that define the extensible resource. */ + identifiers?: Record; /** Type of change that will be made to the resource when the deployment is executed. */ changeType: ChangeType; /** The explanation about why the resource is unsupported by What-If. */ @@ -802,12 +900,16 @@ export interface ExportTemplateRequest { resources?: string[]; /** The export template options. A CSV-formatted list containing zero or more of the following: 'IncludeParameterDefaultValue', 'IncludeComments', 'SkipResourceNameParameterization', 'SkipAllParameterization' */ options?: string; + /** The output format for the exported resources. */ + outputFormat?: ExportTemplateOutputFormat; } /** Resource group export result. */ export interface ResourceGroupExportResult { - /** The template content. */ + /** The template content. Used if outputFormat is empty or set to 'Json'. */ template?: Record; + /** The formatted export content. Used if outputFormat is set to 'Bicep'. */ + output?: string; /** The template export error. */ error?: ErrorResponse; } @@ -1143,6 +1245,30 @@ export interface DeploymentsWhatIfHeaders { retryAfter?: string; } +/** Defines headers for ResourceGroups_delete operation. */ +export interface ResourceGroupsDeleteHeaders { + /** URL to get status of this long-running operation. */ + location?: string; +} + +/** Defines headers for Tags_createOrUpdateAtScope operation. */ +export interface TagsCreateOrUpdateAtScopeHeaders { + /** URL to get status of this long-running operation. */ + location?: string; +} + +/** Defines headers for Tags_updateAtScope operation. */ +export interface TagsUpdateAtScopeHeaders { + /** URL to get status of this long-running operation. */ + location?: string; +} + +/** Defines headers for Tags_deleteAtScope operation. */ +export interface TagsDeleteAtScopeHeaders { + /** URL to get status of this long-running operation. */ + location?: string; +} + /** Known values of {@link ExpressionEvaluationOptionsScopeType} that the service accepts. */ export enum KnownExpressionEvaluationOptionsScopeType { /** NotSpecified */ @@ -1150,7 +1276,7 @@ export enum KnownExpressionEvaluationOptionsScopeType { /** Outer */ Outer = "Outer", /** Inner */ - Inner = "Inner" + Inner = "Inner", } /** @@ -1164,6 +1290,27 @@ export enum KnownExpressionEvaluationOptionsScopeType { */ export type ExpressionEvaluationOptionsScopeType = string; +/** Known values of {@link ValidationLevel} that the service accepts. */ +export enum KnownValidationLevel { + /** Static analysis of the template is performed. */ + Template = "Template", + /** Static analysis of the template is performed and resource declarations are sent to resource providers for semantic validation. Validates that the caller has RBAC write permissions on each resource. */ + Provider = "Provider", + /** Static analysis of the template is performed and resource declarations are sent to resource providers for semantic validation. Skips validating that the caller has RBAC write permissions on each resource. */ + ProviderNoRbac = "ProviderNoRbac", +} + +/** + * Defines values for ValidationLevel. \ + * {@link KnownValidationLevel} can be used interchangeably with ValidationLevel, + * this enum contains the known values that the service supports. + * ### Known values supported by the service + * **Template**: Static analysis of the template is performed. \ + * **Provider**: Static analysis of the template is performed and resource declarations are sent to resource providers for semantic validation. Validates that the caller has RBAC write permissions on each resource. \ + * **ProviderNoRbac**: Static analysis of the template is performed and resource declarations are sent to resource providers for semantic validation. Skips validating that the caller has RBAC write permissions on each resource. + */ +export type ValidationLevel = string; + /** Known values of {@link ProvisioningState} that the service accepts. */ export enum KnownProvisioningState { /** NotSpecified */ @@ -1189,7 +1336,7 @@ export enum KnownProvisioningState { /** Succeeded */ Succeeded = "Succeeded", /** Updating */ - Updating = "Updating" + Updating = "Updating", } /** @@ -1229,7 +1376,7 @@ export enum KnownAliasPathTokenType { /** The token type is number. */ Number = "Number", /** The token type is boolean. */ - Boolean = "Boolean" + Boolean = "Boolean", } /** @@ -1253,7 +1400,7 @@ export enum KnownAliasPathAttributes { /** The token that the alias path is referring to has no attributes. */ None = "None", /** The token that the alias path is referring to is modifiable by policies with 'modify' effect. */ - Modifiable = "Modifiable" + Modifiable = "Modifiable", } /** @@ -1275,7 +1422,7 @@ export enum KnownProviderAuthorizationConsentState { /** NotRequired */ NotRequired = "NotRequired", /** Consented */ - Consented = "Consented" + Consented = "Consented", } /** @@ -1290,10 +1437,31 @@ export enum KnownProviderAuthorizationConsentState { */ export type ProviderAuthorizationConsentState = string; +/** Known values of {@link Level} that the service accepts. */ +export enum KnownLevel { + /** Warning */ + Warning = "Warning", + /** Info */ + Info = "Info", + /** Error */ + Error = "Error", +} + +/** + * Defines values for Level. \ + * {@link KnownLevel} can be used interchangeably with Level, + * this enum contains the known values that the service supports. + * ### Known values supported by the service + * **Warning** \ + * **Info** \ + * **Error** + */ +export type Level = string; + /** Known values of {@link ExtendedLocationType} that the service accepts. */ export enum KnownExtendedLocationType { /** EdgeZone */ - EdgeZone = "EdgeZone" + EdgeZone = "EdgeZone", } /** @@ -1305,6 +1473,24 @@ export enum KnownExtendedLocationType { */ export type ExtendedLocationType = string; +/** Known values of {@link ExportTemplateOutputFormat} that the service accepts. */ +export enum KnownExportTemplateOutputFormat { + /** Json */ + Json = "Json", + /** Bicep */ + Bicep = "Bicep", +} + +/** + * Defines values for ExportTemplateOutputFormat. \ + * {@link KnownExportTemplateOutputFormat} can be used interchangeably with ExportTemplateOutputFormat, + * this enum contains the known values that the service supports. + * ### Known values supported by the service + * **Json** \ + * **Bicep** + */ +export type ExportTemplateOutputFormat = string; + /** Known values of {@link TagsPatchOperation} that the service accepts. */ export enum KnownTagsPatchOperation { /** The 'replace' option replaces the entire set of existing tags with a new set. */ @@ -1312,7 +1498,7 @@ export enum KnownTagsPatchOperation { /** The 'merge' option allows adding tags with new names and updating the values of tags with existing names. */ Merge = "Merge", /** The 'delete' option allows selectively deleting tags based on given names or name\/value pairs. */ - Delete = "Delete" + Delete = "Delete", } /** @@ -1435,7 +1621,7 @@ export interface DeploymentsValidateAtScopeOptionalParams } /** Contains response data for the validateAtScope operation. */ -export type DeploymentsValidateAtScopeResponse = DeploymentValidateResult; +export type DeploymentsValidateAtScopeResponse = DeploymentExtended; /** Optional parameters. */ export interface DeploymentsExportTemplateAtScopeOptionalParams @@ -1507,7 +1693,7 @@ export interface DeploymentsValidateAtTenantScopeOptionalParams } /** Contains response data for the validateAtTenantScope operation. */ -export type DeploymentsValidateAtTenantScopeResponse = DeploymentValidateResult; +export type DeploymentsValidateAtTenantScopeResponse = DeploymentExtended; /** Optional parameters. */ export interface DeploymentsWhatIfAtTenantScopeOptionalParams @@ -1526,7 +1712,8 @@ export interface DeploymentsExportTemplateAtTenantScopeOptionalParams extends coreClient.OperationOptions {} /** Contains response data for the exportTemplateAtTenantScope operation. */ -export type DeploymentsExportTemplateAtTenantScopeResponse = DeploymentExportResult; +export type DeploymentsExportTemplateAtTenantScopeResponse = + DeploymentExportResult; /** Optional parameters. */ export interface DeploymentsListAtTenantScopeOptionalParams @@ -1568,7 +1755,8 @@ export interface DeploymentsCreateOrUpdateAtManagementGroupScopeOptionalParams } /** Contains response data for the createOrUpdateAtManagementGroupScope operation. */ -export type DeploymentsCreateOrUpdateAtManagementGroupScopeResponse = DeploymentExtended; +export type DeploymentsCreateOrUpdateAtManagementGroupScopeResponse = + DeploymentExtended; /** Optional parameters. */ export interface DeploymentsGetAtManagementGroupScopeOptionalParams @@ -1591,7 +1779,8 @@ export interface DeploymentsValidateAtManagementGroupScopeOptionalParams } /** Contains response data for the validateAtManagementGroupScope operation. */ -export type DeploymentsValidateAtManagementGroupScopeResponse = DeploymentValidateResult; +export type DeploymentsValidateAtManagementGroupScopeResponse = + DeploymentExtended; /** Optional parameters. */ export interface DeploymentsWhatIfAtManagementGroupScopeOptionalParams @@ -1603,14 +1792,16 @@ export interface DeploymentsWhatIfAtManagementGroupScopeOptionalParams } /** Contains response data for the whatIfAtManagementGroupScope operation. */ -export type DeploymentsWhatIfAtManagementGroupScopeResponse = WhatIfOperationResult; +export type DeploymentsWhatIfAtManagementGroupScopeResponse = + WhatIfOperationResult; /** Optional parameters. */ export interface DeploymentsExportTemplateAtManagementGroupScopeOptionalParams extends coreClient.OperationOptions {} /** Contains response data for the exportTemplateAtManagementGroupScope operation. */ -export type DeploymentsExportTemplateAtManagementGroupScopeResponse = DeploymentExportResult; +export type DeploymentsExportTemplateAtManagementGroupScopeResponse = + DeploymentExportResult; /** Optional parameters. */ export interface DeploymentsListAtManagementGroupScopeOptionalParams @@ -1622,7 +1813,8 @@ export interface DeploymentsListAtManagementGroupScopeOptionalParams } /** Contains response data for the listAtManagementGroupScope operation. */ -export type DeploymentsListAtManagementGroupScopeResponse = DeploymentListResult; +export type DeploymentsListAtManagementGroupScopeResponse = + DeploymentListResult; /** Optional parameters. */ export interface DeploymentsDeleteAtSubscriptionScopeOptionalParams @@ -1652,7 +1844,8 @@ export interface DeploymentsCreateOrUpdateAtSubscriptionScopeOptionalParams } /** Contains response data for the createOrUpdateAtSubscriptionScope operation. */ -export type DeploymentsCreateOrUpdateAtSubscriptionScopeResponse = DeploymentExtended; +export type DeploymentsCreateOrUpdateAtSubscriptionScopeResponse = + DeploymentExtended; /** Optional parameters. */ export interface DeploymentsGetAtSubscriptionScopeOptionalParams @@ -1675,7 +1868,7 @@ export interface DeploymentsValidateAtSubscriptionScopeOptionalParams } /** Contains response data for the validateAtSubscriptionScope operation. */ -export type DeploymentsValidateAtSubscriptionScopeResponse = DeploymentValidateResult; +export type DeploymentsValidateAtSubscriptionScopeResponse = DeploymentExtended; /** Optional parameters. */ export interface DeploymentsWhatIfAtSubscriptionScopeOptionalParams @@ -1687,14 +1880,16 @@ export interface DeploymentsWhatIfAtSubscriptionScopeOptionalParams } /** Contains response data for the whatIfAtSubscriptionScope operation. */ -export type DeploymentsWhatIfAtSubscriptionScopeResponse = WhatIfOperationResult; +export type DeploymentsWhatIfAtSubscriptionScopeResponse = + WhatIfOperationResult; /** Optional parameters. */ export interface DeploymentsExportTemplateAtSubscriptionScopeOptionalParams extends coreClient.OperationOptions {} /** Contains response data for the exportTemplateAtSubscriptionScope operation. */ -export type DeploymentsExportTemplateAtSubscriptionScopeResponse = DeploymentExportResult; +export type DeploymentsExportTemplateAtSubscriptionScopeResponse = + DeploymentExportResult; /** Optional parameters. */ export interface DeploymentsListAtSubscriptionScopeOptionalParams @@ -1759,7 +1954,7 @@ export interface DeploymentsValidateOptionalParams } /** Contains response data for the validate operation. */ -export type DeploymentsValidateResponse = DeploymentValidateResult; +export type DeploymentsValidateResponse = DeploymentExtended; /** Optional parameters. */ export interface DeploymentsWhatIfOptionalParams @@ -1818,14 +2013,16 @@ export interface DeploymentsListAtManagementGroupScopeNextOptionalParams extends coreClient.OperationOptions {} /** Contains response data for the listAtManagementGroupScopeNext operation. */ -export type DeploymentsListAtManagementGroupScopeNextResponse = DeploymentListResult; +export type DeploymentsListAtManagementGroupScopeNextResponse = + DeploymentListResult; /** Optional parameters. */ export interface DeploymentsListAtSubscriptionScopeNextOptionalParams extends coreClient.OperationOptions {} /** Contains response data for the listAtSubscriptionScopeNext operation. */ -export type DeploymentsListAtSubscriptionScopeNextResponse = DeploymentListResult; +export type DeploymentsListAtSubscriptionScopeNextResponse = + DeploymentListResult; /** Optional parameters. */ export interface DeploymentsListByResourceGroupNextOptionalParams @@ -1963,7 +2160,7 @@ export interface ResourcesListOptionalParams extends coreClient.OperationOptions { /** The filter to apply on the operation.

Filter comparison operators include `eq` (equals) and `ne` (not equals) and may be used with the following properties: `location`, `resourceType`, `name`, `resourceGroup`, `identity`, `identity/principalId`, `plan`, `plan/publisher`, `plan/product`, `plan/name`, `plan/version`, and `plan/promotionCode`.

For example, to filter by a resource type, use `$filter=resourceType eq 'Microsoft.Network/virtualNetworks'`


`substringof(value, property)` can be used to filter for substrings of the following currently-supported properties: `name` and `resourceGroup`

For example, to get all resources with 'demo' anywhere in the resource name, use `$filter=substringof('demo', name)`

Multiple substring operations can also be combined using `and`/`or` operators.

Note that any truncated number of results queried via `$top` may also not be compatible when using a filter.


Resources can be filtered by tag names and values. For example, to filter for a tag name and value, use `$filter=tagName eq 'tag1' and tagValue eq 'Value1'`. Note that when resources are filtered by tag name and value, the original tags for each resource will not be returned in the results. Any list of additional properties queried via `$expand` may also not be compatible when filtering by tag names/values.

For tag names only, resources can be filtered by prefix using the following syntax: `$filter=startswith(tagName, 'depart')`. This query will return all resources with a tag name prefixed by the phrase `depart` (i.e.`department`, `departureDate`, `departureTime`, etc.)


Note that some properties can be combined when filtering resources, which include the following: `substringof() and/or resourceType`, `plan and plan/publisher and plan/name`, and `identity and identity/principalId`. */ filter?: string; - /** The number of results to return. If null is passed, returns all resources. */ + /** The number of recommendations per page if a paged version of this API is being used. */ top?: number; /** Comma-separated list of additional properties to be included in the response. Valid values include `createdTime`, `changedTime` and `provisioningState`. For example, `$expand=createdTime,changedTime`. */ expand?: string; @@ -2185,14 +2382,24 @@ export type TagsListResponse = TagsListResult; /** Optional parameters. */ export interface TagsCreateOrUpdateAtScopeOptionalParams - extends coreClient.OperationOptions {} + extends coreClient.OperationOptions { + /** Delay to wait until next poll, in milliseconds. */ + updateIntervalInMs?: number; + /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ + resumeFrom?: string; +} /** Contains response data for the createOrUpdateAtScope operation. */ export type TagsCreateOrUpdateAtScopeResponse = TagsResource; /** Optional parameters. */ export interface TagsUpdateAtScopeOptionalParams - extends coreClient.OperationOptions {} + extends coreClient.OperationOptions { + /** Delay to wait until next poll, in milliseconds. */ + updateIntervalInMs?: number; + /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ + resumeFrom?: string; +} /** Contains response data for the updateAtScope operation. */ export type TagsUpdateAtScopeResponse = TagsResource; @@ -2206,7 +2413,12 @@ export type TagsGetAtScopeResponse = TagsResource; /** Optional parameters. */ export interface TagsDeleteAtScopeOptionalParams - extends coreClient.OperationOptions {} + extends coreClient.OperationOptions { + /** Delay to wait until next poll, in milliseconds. */ + updateIntervalInMs?: number; + /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ + resumeFrom?: string; +} /** Optional parameters. */ export interface TagsListNextOptionalParams @@ -2230,7 +2442,8 @@ export interface DeploymentOperationsListAtScopeOptionalParams } /** Contains response data for the listAtScope operation. */ -export type DeploymentOperationsListAtScopeResponse = DeploymentOperationsListResult; +export type DeploymentOperationsListAtScopeResponse = + DeploymentOperationsListResult; /** Optional parameters. */ export interface DeploymentOperationsGetAtTenantScopeOptionalParams @@ -2247,14 +2460,16 @@ export interface DeploymentOperationsListAtTenantScopeOptionalParams } /** Contains response data for the listAtTenantScope operation. */ -export type DeploymentOperationsListAtTenantScopeResponse = DeploymentOperationsListResult; +export type DeploymentOperationsListAtTenantScopeResponse = + DeploymentOperationsListResult; /** Optional parameters. */ export interface DeploymentOperationsGetAtManagementGroupScopeOptionalParams extends coreClient.OperationOptions {} /** Contains response data for the getAtManagementGroupScope operation. */ -export type DeploymentOperationsGetAtManagementGroupScopeResponse = DeploymentOperation; +export type DeploymentOperationsGetAtManagementGroupScopeResponse = + DeploymentOperation; /** Optional parameters. */ export interface DeploymentOperationsListAtManagementGroupScopeOptionalParams @@ -2264,14 +2479,16 @@ export interface DeploymentOperationsListAtManagementGroupScopeOptionalParams } /** Contains response data for the listAtManagementGroupScope operation. */ -export type DeploymentOperationsListAtManagementGroupScopeResponse = DeploymentOperationsListResult; +export type DeploymentOperationsListAtManagementGroupScopeResponse = + DeploymentOperationsListResult; /** Optional parameters. */ export interface DeploymentOperationsGetAtSubscriptionScopeOptionalParams extends coreClient.OperationOptions {} /** Contains response data for the getAtSubscriptionScope operation. */ -export type DeploymentOperationsGetAtSubscriptionScopeResponse = DeploymentOperation; +export type DeploymentOperationsGetAtSubscriptionScopeResponse = + DeploymentOperation; /** Optional parameters. */ export interface DeploymentOperationsListAtSubscriptionScopeOptionalParams @@ -2281,7 +2498,8 @@ export interface DeploymentOperationsListAtSubscriptionScopeOptionalParams } /** Contains response data for the listAtSubscriptionScope operation. */ -export type DeploymentOperationsListAtSubscriptionScopeResponse = DeploymentOperationsListResult; +export type DeploymentOperationsListAtSubscriptionScopeResponse = + DeploymentOperationsListResult; /** Optional parameters. */ export interface DeploymentOperationsGetOptionalParams @@ -2305,35 +2523,40 @@ export interface DeploymentOperationsListAtScopeNextOptionalParams extends coreClient.OperationOptions {} /** Contains response data for the listAtScopeNext operation. */ -export type DeploymentOperationsListAtScopeNextResponse = DeploymentOperationsListResult; +export type DeploymentOperationsListAtScopeNextResponse = + DeploymentOperationsListResult; /** Optional parameters. */ export interface DeploymentOperationsListAtTenantScopeNextOptionalParams extends coreClient.OperationOptions {} /** Contains response data for the listAtTenantScopeNext operation. */ -export type DeploymentOperationsListAtTenantScopeNextResponse = DeploymentOperationsListResult; +export type DeploymentOperationsListAtTenantScopeNextResponse = + DeploymentOperationsListResult; /** Optional parameters. */ export interface DeploymentOperationsListAtManagementGroupScopeNextOptionalParams extends coreClient.OperationOptions {} /** Contains response data for the listAtManagementGroupScopeNext operation. */ -export type DeploymentOperationsListAtManagementGroupScopeNextResponse = DeploymentOperationsListResult; +export type DeploymentOperationsListAtManagementGroupScopeNextResponse = + DeploymentOperationsListResult; /** Optional parameters. */ export interface DeploymentOperationsListAtSubscriptionScopeNextOptionalParams extends coreClient.OperationOptions {} /** Contains response data for the listAtSubscriptionScopeNext operation. */ -export type DeploymentOperationsListAtSubscriptionScopeNextResponse = DeploymentOperationsListResult; +export type DeploymentOperationsListAtSubscriptionScopeNextResponse = + DeploymentOperationsListResult; /** Optional parameters. */ export interface DeploymentOperationsListNextOptionalParams extends coreClient.OperationOptions {} /** Contains response data for the listNext operation. */ -export type DeploymentOperationsListNextResponse = DeploymentOperationsListResult; +export type DeploymentOperationsListNextResponse = + DeploymentOperationsListResult; /** Optional parameters. */ export interface ResourceManagementClientOptionalParams diff --git a/sdk/resources/arm-resources/src/models/mappers.ts b/sdk/resources/arm-resources/src/models/mappers.ts index 851900fc8315..b89e4aeb5f52 100644 --- a/sdk/resources/arm-resources/src/models/mappers.ts +++ b/sdk/resources/arm-resources/src/models/mappers.ts @@ -20,19 +20,19 @@ export const OperationListResult: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "Operation" - } - } - } + className: "Operation", + }, + }, + }, }, nextLink: { serializedName: "nextLink", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const Operation: coreClient.CompositeMapper = { @@ -43,18 +43,18 @@ export const Operation: coreClient.CompositeMapper = { name: { serializedName: "name", type: { - name: "String" - } + name: "String", + }, }, display: { serializedName: "display", type: { name: "Composite", - className: "OperationDisplay" - } - } - } - } + className: "OperationDisplay", + }, + }, + }, + }, }; export const OperationDisplay: coreClient.CompositeMapper = { @@ -65,29 +65,29 @@ export const OperationDisplay: coreClient.CompositeMapper = { provider: { serializedName: "provider", type: { - name: "String" - } + name: "String", + }, }, resource: { serializedName: "resource", type: { - name: "String" - } + name: "String", + }, }, operation: { serializedName: "operation", type: { - name: "String" - } + name: "String", + }, }, description: { serializedName: "description", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const CloudError: coreClient.CompositeMapper = { @@ -99,11 +99,11 @@ export const CloudError: coreClient.CompositeMapper = { serializedName: "error", type: { name: "Composite", - className: "ErrorResponse" - } - } - } - } + className: "ErrorResponse", + }, + }, + }, + }, }; export const ErrorResponse: coreClient.CompositeMapper = { @@ -115,22 +115,22 @@ export const ErrorResponse: coreClient.CompositeMapper = { serializedName: "code", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, message: { serializedName: "message", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, target: { serializedName: "target", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, details: { serializedName: "details", @@ -140,10 +140,10 @@ export const ErrorResponse: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "ErrorResponse" - } - } - } + className: "ErrorResponse", + }, + }, + }, }, additionalInfo: { serializedName: "additionalInfo", @@ -153,13 +153,13 @@ export const ErrorResponse: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "ErrorAdditionalInfo" - } - } - } - } - } - } + className: "ErrorAdditionalInfo", + }, + }, + }, + }, + }, + }, }; export const ErrorAdditionalInfo: coreClient.CompositeMapper = { @@ -171,19 +171,19 @@ export const ErrorAdditionalInfo: coreClient.CompositeMapper = { serializedName: "type", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, info: { serializedName: "info", readOnly: true, type: { name: "Dictionary", - value: { type: { name: "any" } } - } - } - } - } + value: { type: { name: "any" } }, + }, + }, + }, + }, }; export const Deployment: coreClient.CompositeMapper = { @@ -194,25 +194,25 @@ export const Deployment: coreClient.CompositeMapper = { location: { serializedName: "location", type: { - name: "String" - } + name: "String", + }, }, properties: { serializedName: "properties", type: { name: "Composite", - className: "DeploymentProperties" - } + className: "DeploymentProperties", + }, }, tags: { serializedName: "tags", type: { name: "Dictionary", - value: { type: { name: "String" } } - } - } - } - } + value: { type: { name: "String" } }, + }, + }, + }, + }, }; export const DeploymentProperties: coreClient.CompositeMapper = { @@ -224,61 +224,69 @@ export const DeploymentProperties: coreClient.CompositeMapper = { serializedName: "template", type: { name: "Dictionary", - value: { type: { name: "any" } } - } + value: { type: { name: "any" } }, + }, }, templateLink: { serializedName: "templateLink", type: { name: "Composite", - className: "TemplateLink" - } + className: "TemplateLink", + }, }, parameters: { serializedName: "parameters", type: { name: "Dictionary", - value: { type: { name: "any" } } - } + value: { + type: { name: "Composite", className: "DeploymentParameter" }, + }, + }, }, parametersLink: { serializedName: "parametersLink", type: { name: "Composite", - className: "ParametersLink" - } + className: "ParametersLink", + }, }, mode: { serializedName: "mode", required: true, type: { name: "Enum", - allowedValues: ["Incremental", "Complete"] - } + allowedValues: ["Incremental", "Complete"], + }, }, debugSetting: { serializedName: "debugSetting", type: { name: "Composite", - className: "DebugSetting" - } + className: "DebugSetting", + }, }, onErrorDeployment: { serializedName: "onErrorDeployment", type: { name: "Composite", - className: "OnErrorDeployment" - } + className: "OnErrorDeployment", + }, }, expressionEvaluationOptions: { serializedName: "expressionEvaluationOptions", type: { name: "Composite", - className: "ExpressionEvaluationOptions" - } - } - } - } + className: "ExpressionEvaluationOptions", + }, + }, + validationLevel: { + serializedName: "validationLevel", + type: { + name: "String", + }, + }, + }, + }, }; export const TemplateLink: coreClient.CompositeMapper = { @@ -289,35 +297,102 @@ export const TemplateLink: coreClient.CompositeMapper = { uri: { serializedName: "uri", type: { - name: "String" - } + name: "String", + }, }, id: { serializedName: "id", type: { - name: "String" - } + name: "String", + }, }, relativePath: { serializedName: "relativePath", type: { - name: "String" - } + name: "String", + }, }, contentVersion: { serializedName: "contentVersion", type: { - name: "String" - } + name: "String", + }, }, queryString: { serializedName: "queryString", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, +}; + +export const DeploymentParameter: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "DeploymentParameter", + modelProperties: { + value: { + serializedName: "value", + type: { + name: "any", + }, + }, + reference: { + serializedName: "reference", + type: { + name: "Composite", + className: "KeyVaultParameterReference", + }, + }, + }, + }, +}; + +export const KeyVaultParameterReference: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "KeyVaultParameterReference", + modelProperties: { + keyVault: { + serializedName: "keyVault", + type: { + name: "Composite", + className: "KeyVaultReference", + }, + }, + secretName: { + serializedName: "secretName", + required: true, + type: { + name: "String", + }, + }, + secretVersion: { + serializedName: "secretVersion", + type: { + name: "String", + }, + }, + }, + }, +}; + +export const KeyVaultReference: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "KeyVaultReference", + modelProperties: { + id: { + serializedName: "id", + required: true, + type: { + name: "String", + }, + }, + }, + }, }; export const ParametersLink: coreClient.CompositeMapper = { @@ -329,17 +404,17 @@ export const ParametersLink: coreClient.CompositeMapper = { serializedName: "uri", required: true, type: { - name: "String" - } + name: "String", + }, }, contentVersion: { serializedName: "contentVersion", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const DebugSetting: coreClient.CompositeMapper = { @@ -350,11 +425,11 @@ export const DebugSetting: coreClient.CompositeMapper = { detailLevel: { serializedName: "detailLevel", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const OnErrorDeployment: coreClient.CompositeMapper = { @@ -366,17 +441,17 @@ export const OnErrorDeployment: coreClient.CompositeMapper = { serializedName: "type", type: { name: "Enum", - allowedValues: ["LastSuccessful", "SpecificDeployment"] - } + allowedValues: ["LastSuccessful", "SpecificDeployment"], + }, }, deploymentName: { serializedName: "deploymentName", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const ExpressionEvaluationOptions: coreClient.CompositeMapper = { @@ -387,11 +462,11 @@ export const ExpressionEvaluationOptions: coreClient.CompositeMapper = { scope: { serializedName: "scope", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const DeploymentExtended: coreClient.CompositeMapper = { @@ -403,45 +478,45 @@ export const DeploymentExtended: coreClient.CompositeMapper = { serializedName: "id", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, name: { serializedName: "name", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, type: { serializedName: "type", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, location: { serializedName: "location", type: { - name: "String" - } + name: "String", + }, }, properties: { serializedName: "properties", type: { name: "Composite", - className: "DeploymentPropertiesExtended" - } + className: "DeploymentPropertiesExtended", + }, }, tags: { serializedName: "tags", type: { name: "Dictionary", - value: { type: { name: "String" } } - } - } - } - } + value: { type: { name: "String" } }, + }, + }, + }, + }, }; export const DeploymentPropertiesExtended: coreClient.CompositeMapper = { @@ -453,37 +528,37 @@ export const DeploymentPropertiesExtended: coreClient.CompositeMapper = { serializedName: "provisioningState", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, correlationId: { serializedName: "correlationId", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, timestamp: { serializedName: "timestamp", readOnly: true, type: { - name: "DateTime" - } + name: "DateTime", + }, }, duration: { serializedName: "duration", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, outputs: { serializedName: "outputs", readOnly: true, type: { name: "Dictionary", - value: { type: { name: "any" } } - } + value: { type: { name: "any" } }, + }, }, providers: { serializedName: "providers", @@ -493,10 +568,10 @@ export const DeploymentPropertiesExtended: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "Provider" - } - } - } + className: "Provider", + }, + }, + }, }, dependencies: { serializedName: "dependencies", @@ -506,61 +581,61 @@ export const DeploymentPropertiesExtended: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "Dependency" - } - } - } + className: "Dependency", + }, + }, + }, }, templateLink: { serializedName: "templateLink", type: { name: "Composite", - className: "TemplateLink" - } + className: "TemplateLink", + }, }, parameters: { serializedName: "parameters", readOnly: true, type: { name: "Dictionary", - value: { type: { name: "any" } } - } + value: { type: { name: "any" } }, + }, }, parametersLink: { serializedName: "parametersLink", type: { name: "Composite", - className: "ParametersLink" - } + className: "ParametersLink", + }, }, mode: { serializedName: "mode", readOnly: true, type: { name: "Enum", - allowedValues: ["Incremental", "Complete"] - } + allowedValues: ["Incremental", "Complete"], + }, }, debugSetting: { serializedName: "debugSetting", type: { name: "Composite", - className: "DebugSetting" - } + className: "DebugSetting", + }, }, onErrorDeployment: { serializedName: "onErrorDeployment", type: { name: "Composite", - className: "OnErrorDeploymentExtended" - } + className: "OnErrorDeploymentExtended", + }, }, templateHash: { serializedName: "templateHash", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, outputResources: { serializedName: "outputResources", @@ -570,10 +645,10 @@ export const DeploymentPropertiesExtended: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "ResourceReference" - } - } - } + className: "ResourceReference", + }, + }, + }, }, validatedResources: { serializedName: "validatedResources", @@ -583,20 +658,39 @@ export const DeploymentPropertiesExtended: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "ResourceReference" - } - } - } + className: "ResourceReference", + }, + }, + }, }, error: { serializedName: "error", type: { name: "Composite", - className: "ErrorResponse" - } - } - } - } + className: "ErrorResponse", + }, + }, + diagnostics: { + serializedName: "diagnostics", + readOnly: true, + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "DeploymentDiagnosticsDefinition", + }, + }, + }, + }, + validationLevel: { + serializedName: "validationLevel", + type: { + name: "String", + }, + }, + }, + }, }; export const Provider: coreClient.CompositeMapper = { @@ -608,28 +702,28 @@ export const Provider: coreClient.CompositeMapper = { serializedName: "id", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, namespace: { serializedName: "namespace", type: { - name: "String" - } + name: "String", + }, }, registrationState: { serializedName: "registrationState", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, registrationPolicy: { serializedName: "registrationPolicy", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, resourceTypes: { serializedName: "resourceTypes", @@ -639,19 +733,19 @@ export const Provider: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "ProviderResourceType" - } - } - } + className: "ProviderResourceType", + }, + }, + }, }, providerAuthorizationConsentState: { serializedName: "providerAuthorizationConsentState", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const ProviderResourceType: coreClient.CompositeMapper = { @@ -662,8 +756,8 @@ export const ProviderResourceType: coreClient.CompositeMapper = { resourceType: { serializedName: "resourceType", type: { - name: "String" - } + name: "String", + }, }, locations: { serializedName: "locations", @@ -671,10 +765,10 @@ export const ProviderResourceType: coreClient.CompositeMapper = { name: "Sequence", element: { type: { - name: "String" - } - } - } + name: "String", + }, + }, + }, }, locationMappings: { serializedName: "locationMappings", @@ -683,10 +777,10 @@ export const ProviderResourceType: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "ProviderExtendedLocation" - } - } - } + className: "ProviderExtendedLocation", + }, + }, + }, }, aliases: { serializedName: "aliases", @@ -695,10 +789,10 @@ export const ProviderResourceType: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "Alias" - } - } - } + className: "Alias", + }, + }, + }, }, apiVersions: { serializedName: "apiVersions", @@ -706,17 +800,17 @@ export const ProviderResourceType: coreClient.CompositeMapper = { name: "Sequence", element: { type: { - name: "String" - } - } - } + name: "String", + }, + }, + }, }, defaultApiVersion: { serializedName: "defaultApiVersion", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, zoneMappings: { serializedName: "zoneMappings", @@ -725,10 +819,10 @@ export const ProviderResourceType: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "ZoneMapping" - } - } - } + className: "ZoneMapping", + }, + }, + }, }, apiProfiles: { serializedName: "apiProfiles", @@ -738,26 +832,26 @@ export const ProviderResourceType: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "ApiProfile" - } - } - } + className: "ApiProfile", + }, + }, + }, }, capabilities: { serializedName: "capabilities", type: { - name: "String" - } + name: "String", + }, }, properties: { serializedName: "properties", type: { name: "Dictionary", - value: { type: { name: "String" } } - } - } - } - } + value: { type: { name: "String" } }, + }, + }, + }, + }, }; export const ProviderExtendedLocation: coreClient.CompositeMapper = { @@ -768,14 +862,14 @@ export const ProviderExtendedLocation: coreClient.CompositeMapper = { location: { serializedName: "location", type: { - name: "String" - } + name: "String", + }, }, type: { serializedName: "type", type: { - name: "String" - } + name: "String", + }, }, extendedLocations: { serializedName: "extendedLocations", @@ -783,13 +877,13 @@ export const ProviderExtendedLocation: coreClient.CompositeMapper = { name: "Sequence", element: { type: { - name: "String" - } - } - } - } - } - } + name: "String", + }, + }, + }, + }, + }, + }, }; export const Alias: coreClient.CompositeMapper = { @@ -800,8 +894,8 @@ export const Alias: coreClient.CompositeMapper = { name: { serializedName: "name", type: { - name: "String" - } + name: "String", + }, }, paths: { serializedName: "paths", @@ -810,40 +904,40 @@ export const Alias: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "AliasPath" - } - } - } + className: "AliasPath", + }, + }, + }, }, type: { serializedName: "type", type: { name: "Enum", - allowedValues: ["NotSpecified", "PlainText", "Mask"] - } + allowedValues: ["NotSpecified", "PlainText", "Mask"], + }, }, defaultPath: { serializedName: "defaultPath", type: { - name: "String" - } + name: "String", + }, }, defaultPattern: { serializedName: "defaultPattern", type: { name: "Composite", - className: "AliasPattern" - } + className: "AliasPattern", + }, }, defaultMetadata: { serializedName: "defaultMetadata", type: { name: "Composite", - className: "AliasPathMetadata" - } - } - } - } + className: "AliasPathMetadata", + }, + }, + }, + }, }; export const AliasPath: coreClient.CompositeMapper = { @@ -854,8 +948,8 @@ export const AliasPath: coreClient.CompositeMapper = { path: { serializedName: "path", type: { - name: "String" - } + name: "String", + }, }, apiVersions: { serializedName: "apiVersions", @@ -863,27 +957,27 @@ export const AliasPath: coreClient.CompositeMapper = { name: "Sequence", element: { type: { - name: "String" - } - } - } + name: "String", + }, + }, + }, }, pattern: { serializedName: "pattern", type: { name: "Composite", - className: "AliasPattern" - } + className: "AliasPattern", + }, }, metadata: { serializedName: "metadata", type: { name: "Composite", - className: "AliasPathMetadata" - } - } - } - } + className: "AliasPathMetadata", + }, + }, + }, + }, }; export const AliasPattern: coreClient.CompositeMapper = { @@ -894,24 +988,24 @@ export const AliasPattern: coreClient.CompositeMapper = { phrase: { serializedName: "phrase", type: { - name: "String" - } + name: "String", + }, }, variable: { serializedName: "variable", type: { - name: "String" - } + name: "String", + }, }, type: { serializedName: "type", type: { name: "Enum", - allowedValues: ["NotSpecified", "Extract"] - } - } - } - } + allowedValues: ["NotSpecified", "Extract"], + }, + }, + }, + }, }; export const AliasPathMetadata: coreClient.CompositeMapper = { @@ -923,18 +1017,18 @@ export const AliasPathMetadata: coreClient.CompositeMapper = { serializedName: "type", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, attributes: { serializedName: "attributes", readOnly: true, type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const ZoneMapping: coreClient.CompositeMapper = { @@ -945,8 +1039,8 @@ export const ZoneMapping: coreClient.CompositeMapper = { location: { serializedName: "location", type: { - name: "String" - } + name: "String", + }, }, zones: { serializedName: "zones", @@ -954,13 +1048,13 @@ export const ZoneMapping: coreClient.CompositeMapper = { name: "Sequence", element: { type: { - name: "String" - } - } - } - } - } - } + name: "String", + }, + }, + }, + }, + }, + }, }; export const ApiProfile: coreClient.CompositeMapper = { @@ -972,18 +1066,18 @@ export const ApiProfile: coreClient.CompositeMapper = { serializedName: "profileVersion", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, apiVersion: { serializedName: "apiVersion", readOnly: true, type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const Dependency: coreClient.CompositeMapper = { @@ -998,31 +1092,31 @@ export const Dependency: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "BasicDependency" - } - } - } + className: "BasicDependency", + }, + }, + }, }, id: { serializedName: "id", type: { - name: "String" - } + name: "String", + }, }, resourceType: { serializedName: "resourceType", type: { - name: "String" - } + name: "String", + }, }, resourceName: { serializedName: "resourceName", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const BasicDependency: coreClient.CompositeMapper = { @@ -1033,23 +1127,23 @@ export const BasicDependency: coreClient.CompositeMapper = { id: { serializedName: "id", type: { - name: "String" - } + name: "String", + }, }, resourceType: { serializedName: "resourceType", type: { - name: "String" - } + name: "String", + }, }, resourceName: { serializedName: "resourceName", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const OnErrorDeploymentExtended: coreClient.CompositeMapper = { @@ -1061,24 +1155,24 @@ export const OnErrorDeploymentExtended: coreClient.CompositeMapper = { serializedName: "provisioningState", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, type: { serializedName: "type", type: { name: "Enum", - allowedValues: ["LastSuccessful", "SpecificDeployment"] - } + allowedValues: ["LastSuccessful", "SpecificDeployment"], + }, }, deploymentName: { serializedName: "deploymentName", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const ResourceReference: coreClient.CompositeMapper = { @@ -1090,34 +1184,136 @@ export const ResourceReference: coreClient.CompositeMapper = { serializedName: "id", readOnly: true, type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; -export const DeploymentValidateResult: coreClient.CompositeMapper = { +export const DeploymentDiagnosticsDefinition: coreClient.CompositeMapper = { type: { name: "Composite", - className: "DeploymentValidateResult", + className: "DeploymentDiagnosticsDefinition", + modelProperties: { + level: { + serializedName: "level", + required: true, + readOnly: true, + type: { + name: "String", + }, + }, + code: { + serializedName: "code", + required: true, + readOnly: true, + type: { + name: "String", + }, + }, + message: { + serializedName: "message", + required: true, + readOnly: true, + type: { + name: "String", + }, + }, + target: { + serializedName: "target", + readOnly: true, + type: { + name: "String", + }, + }, + additionalInfo: { + serializedName: "additionalInfo", + readOnly: true, + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "ErrorAdditionalInfo", + }, + }, + }, + }, + }, + }, +}; + +export const DeploymentValidationError: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "DeploymentValidationError", modelProperties: { error: { serializedName: "error", type: { name: "Composite", - className: "ErrorResponse" - } + className: "ErrorDetail", + }, }, - properties: { - serializedName: "properties", + }, + }, +}; + +export const ErrorDetail: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "ErrorDetail", + modelProperties: { + code: { + serializedName: "code", + readOnly: true, type: { - name: "Composite", - className: "DeploymentPropertiesExtended" - } - } - } - } + name: "String", + }, + }, + message: { + serializedName: "message", + readOnly: true, + type: { + name: "String", + }, + }, + target: { + serializedName: "target", + readOnly: true, + type: { + name: "String", + }, + }, + details: { + serializedName: "details", + readOnly: true, + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "ErrorDetail", + }, + }, + }, + }, + additionalInfo: { + serializedName: "additionalInfo", + readOnly: true, + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "ErrorAdditionalInfo", + }, + }, + }, + }, + }, + }, }; export const DeploymentExportResult: coreClient.CompositeMapper = { @@ -1129,11 +1325,11 @@ export const DeploymentExportResult: coreClient.CompositeMapper = { serializedName: "template", type: { name: "Dictionary", - value: { type: { name: "any" } } - } - } - } - } + value: { type: { name: "any" } }, + }, + }, + }, + }, }; export const DeploymentListResult: coreClient.CompositeMapper = { @@ -1148,20 +1344,20 @@ export const DeploymentListResult: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "DeploymentExtended" - } - } - } + className: "DeploymentExtended", + }, + }, + }, }, nextLink: { serializedName: "nextLink", readOnly: true, type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const ScopedDeployment: coreClient.CompositeMapper = { @@ -1173,25 +1369,25 @@ export const ScopedDeployment: coreClient.CompositeMapper = { serializedName: "location", required: true, type: { - name: "String" - } + name: "String", + }, }, properties: { serializedName: "properties", type: { name: "Composite", - className: "DeploymentProperties" - } + className: "DeploymentProperties", + }, }, tags: { serializedName: "tags", type: { name: "Dictionary", - value: { type: { name: "String" } } - } - } - } - } + value: { type: { name: "String" } }, + }, + }, + }, + }, }; export const ScopedDeploymentWhatIf: coreClient.CompositeMapper = { @@ -1203,18 +1399,18 @@ export const ScopedDeploymentWhatIf: coreClient.CompositeMapper = { serializedName: "location", required: true, type: { - name: "String" - } + name: "String", + }, }, properties: { serializedName: "properties", type: { name: "Composite", - className: "DeploymentWhatIfProperties" - } - } - } - } + className: "DeploymentWhatIfProperties", + }, + }, + }, + }, }; export const DeploymentWhatIfSettings: coreClient.CompositeMapper = { @@ -1226,11 +1422,11 @@ export const DeploymentWhatIfSettings: coreClient.CompositeMapper = { serializedName: "resultFormat", type: { name: "Enum", - allowedValues: ["ResourceIdOnly", "FullResourcePayloads"] - } - } - } - } + allowedValues: ["ResourceIdOnly", "FullResourcePayloads"], + }, + }, + }, + }, }; export const WhatIfOperationResult: coreClient.CompositeMapper = { @@ -1241,15 +1437,15 @@ export const WhatIfOperationResult: coreClient.CompositeMapper = { status: { serializedName: "status", type: { - name: "String" - } + name: "String", + }, }, error: { serializedName: "error", type: { name: "Composite", - className: "ErrorResponse" - } + className: "ErrorResponse", + }, }, changes: { serializedName: "properties.changes", @@ -1258,13 +1454,38 @@ export const WhatIfOperationResult: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "WhatIfChange" - } - } - } - } - } - } + className: "WhatIfChange", + }, + }, + }, + }, + potentialChanges: { + serializedName: "properties.potentialChanges", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "WhatIfChange", + }, + }, + }, + }, + diagnostics: { + serializedName: "properties.diagnostics", + readOnly: true, + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "DeploymentDiagnosticsDefinition", + }, + }, + }, + }, + }, + }, }; export const WhatIfChange: coreClient.CompositeMapper = { @@ -1276,8 +1497,27 @@ export const WhatIfChange: coreClient.CompositeMapper = { serializedName: "resourceId", required: true, type: { - name: "String" - } + name: "String", + }, + }, + deploymentId: { + serializedName: "deploymentId", + type: { + name: "String", + }, + }, + symbolicName: { + serializedName: "symbolicName", + type: { + name: "String", + }, + }, + identifiers: { + serializedName: "identifiers", + type: { + name: "Dictionary", + value: { type: { name: "any" } }, + }, }, changeType: { serializedName: "changeType", @@ -1291,29 +1531,29 @@ export const WhatIfChange: coreClient.CompositeMapper = { "Deploy", "NoChange", "Modify", - "Unsupported" - ] - } + "Unsupported", + ], + }, }, unsupportedReason: { serializedName: "unsupportedReason", type: { - name: "String" - } + name: "String", + }, }, before: { serializedName: "before", type: { name: "Dictionary", - value: { type: { name: "any" } } - } + value: { type: { name: "any" } }, + }, }, after: { serializedName: "after", type: { name: "Dictionary", - value: { type: { name: "any" } } - } + value: { type: { name: "any" } }, + }, }, delta: { serializedName: "delta", @@ -1322,13 +1562,13 @@ export const WhatIfChange: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "WhatIfPropertyChange" - } - } - } - } - } - } + className: "WhatIfPropertyChange", + }, + }, + }, + }, + }, + }, }; export const WhatIfPropertyChange: coreClient.CompositeMapper = { @@ -1340,30 +1580,30 @@ export const WhatIfPropertyChange: coreClient.CompositeMapper = { serializedName: "path", required: true, type: { - name: "String" - } + name: "String", + }, }, propertyChangeType: { serializedName: "propertyChangeType", required: true, type: { name: "Enum", - allowedValues: ["Create", "Delete", "Modify", "Array", "NoEffect"] - } + allowedValues: ["Create", "Delete", "Modify", "Array", "NoEffect"], + }, }, before: { serializedName: "before", type: { name: "Dictionary", - value: { type: { name: "any" } } - } + value: { type: { name: "any" } }, + }, }, after: { serializedName: "after", type: { name: "Dictionary", - value: { type: { name: "any" } } - } + value: { type: { name: "any" } }, + }, }, children: { serializedName: "children", @@ -1372,13 +1612,13 @@ export const WhatIfPropertyChange: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "WhatIfPropertyChange" - } - } - } - } - } - } + className: "WhatIfPropertyChange", + }, + }, + }, + }, + }, + }, }; export const DeploymentWhatIf: coreClient.CompositeMapper = { @@ -1389,18 +1629,18 @@ export const DeploymentWhatIf: coreClient.CompositeMapper = { location: { serializedName: "location", type: { - name: "String" - } + name: "String", + }, }, properties: { serializedName: "properties", type: { name: "Composite", - className: "DeploymentWhatIfProperties" - } - } - } - } + className: "DeploymentWhatIfProperties", + }, + }, + }, + }, }; export const ProviderPermissionListResult: coreClient.CompositeMapper = { @@ -1415,20 +1655,20 @@ export const ProviderPermissionListResult: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "ProviderPermission" - } - } - } + className: "ProviderPermission", + }, + }, + }, }, nextLink: { serializedName: "nextLink", readOnly: true, type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const ProviderPermission: coreClient.CompositeMapper = { @@ -1439,31 +1679,31 @@ export const ProviderPermission: coreClient.CompositeMapper = { applicationId: { serializedName: "applicationId", type: { - name: "String" - } + name: "String", + }, }, roleDefinition: { serializedName: "roleDefinition", type: { name: "Composite", - className: "RoleDefinition" - } + className: "RoleDefinition", + }, }, managedByRoleDefinition: { serializedName: "managedByRoleDefinition", type: { name: "Composite", - className: "RoleDefinition" - } + className: "RoleDefinition", + }, }, providerAuthorizationConsentState: { serializedName: "providerAuthorizationConsentState", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const RoleDefinition: coreClient.CompositeMapper = { @@ -1474,20 +1714,20 @@ export const RoleDefinition: coreClient.CompositeMapper = { id: { serializedName: "id", type: { - name: "String" - } + name: "String", + }, }, name: { serializedName: "name", type: { - name: "String" - } + name: "String", + }, }, isServiceRole: { serializedName: "isServiceRole", type: { - name: "Boolean" - } + name: "Boolean", + }, }, permissions: { serializedName: "permissions", @@ -1496,10 +1736,10 @@ export const RoleDefinition: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "Permission" - } - } - } + className: "Permission", + }, + }, + }, }, scopes: { serializedName: "scopes", @@ -1507,13 +1747,13 @@ export const RoleDefinition: coreClient.CompositeMapper = { name: "Sequence", element: { type: { - name: "String" - } - } - } - } - } - } + name: "String", + }, + }, + }, + }, + }, + }, }; export const Permission: coreClient.CompositeMapper = { @@ -1527,10 +1767,10 @@ export const Permission: coreClient.CompositeMapper = { name: "Sequence", element: { type: { - name: "String" - } - } - } + name: "String", + }, + }, + }, }, notActions: { serializedName: "notActions", @@ -1538,10 +1778,10 @@ export const Permission: coreClient.CompositeMapper = { name: "Sequence", element: { type: { - name: "String" - } - } - } + name: "String", + }, + }, + }, }, dataActions: { serializedName: "dataActions", @@ -1549,10 +1789,10 @@ export const Permission: coreClient.CompositeMapper = { name: "Sequence", element: { type: { - name: "String" - } - } - } + name: "String", + }, + }, + }, }, notDataActions: { serializedName: "notDataActions", @@ -1560,13 +1800,13 @@ export const Permission: coreClient.CompositeMapper = { name: "Sequence", element: { type: { - name: "String" - } - } - } - } - } - } + name: "String", + }, + }, + }, + }, + }, + }, }; export const ProviderRegistrationRequest: coreClient.CompositeMapper = { @@ -1578,11 +1818,11 @@ export const ProviderRegistrationRequest: coreClient.CompositeMapper = { serializedName: "thirdPartyProviderConsent", type: { name: "Composite", - className: "ProviderConsentDefinition" - } - } - } - } + className: "ProviderConsentDefinition", + }, + }, + }, + }, }; export const ProviderConsentDefinition: coreClient.CompositeMapper = { @@ -1593,11 +1833,11 @@ export const ProviderConsentDefinition: coreClient.CompositeMapper = { consentToAuthorization: { serializedName: "consentToAuthorization", type: { - name: "Boolean" - } - } - } - } + name: "Boolean", + }, + }, + }, + }, }; export const ProviderListResult: coreClient.CompositeMapper = { @@ -1612,20 +1852,20 @@ export const ProviderListResult: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "Provider" - } - } - } + className: "Provider", + }, + }, + }, }, nextLink: { serializedName: "nextLink", readOnly: true, type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const ProviderResourceTypeListResult: coreClient.CompositeMapper = { @@ -1640,20 +1880,20 @@ export const ProviderResourceTypeListResult: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "ProviderResourceType" - } - } - } + className: "ProviderResourceType", + }, + }, + }, }, nextLink: { serializedName: "nextLink", readOnly: true, type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const ResourceListResult: coreClient.CompositeMapper = { @@ -1668,20 +1908,20 @@ export const ResourceListResult: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "GenericResourceExpanded" - } - } - } + className: "GenericResourceExpanded", + }, + }, + }, }, nextLink: { serializedName: "nextLink", readOnly: true, type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const Plan: coreClient.CompositeMapper = { @@ -1692,35 +1932,35 @@ export const Plan: coreClient.CompositeMapper = { name: { serializedName: "name", type: { - name: "String" - } + name: "String", + }, }, publisher: { serializedName: "publisher", type: { - name: "String" - } + name: "String", + }, }, product: { serializedName: "product", type: { - name: "String" - } + name: "String", + }, }, promotionCode: { serializedName: "promotionCode", type: { - name: "String" - } + name: "String", + }, }, version: { serializedName: "version", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const Sku: coreClient.CompositeMapper = { @@ -1731,41 +1971,41 @@ export const Sku: coreClient.CompositeMapper = { name: { serializedName: "name", type: { - name: "String" - } + name: "String", + }, }, tier: { serializedName: "tier", type: { - name: "String" - } + name: "String", + }, }, size: { serializedName: "size", type: { - name: "String" - } + name: "String", + }, }, family: { serializedName: "family", type: { - name: "String" - } + name: "String", + }, }, model: { serializedName: "model", type: { - name: "String" - } + name: "String", + }, }, capacity: { serializedName: "capacity", type: { - name: "Number" - } - } - } - } + name: "Number", + }, + }, + }, + }, }; export const Identity: coreClient.CompositeMapper = { @@ -1777,15 +2017,15 @@ export const Identity: coreClient.CompositeMapper = { serializedName: "principalId", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, tenantId: { serializedName: "tenantId", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, type: { serializedName: "type", @@ -1795,9 +2035,9 @@ export const Identity: coreClient.CompositeMapper = { "SystemAssigned", "UserAssigned", "SystemAssigned, UserAssigned", - "None" - ] - } + "None", + ], + }, }, userAssignedIdentities: { serializedName: "userAssignedIdentities", @@ -1806,13 +2046,13 @@ export const Identity: coreClient.CompositeMapper = { value: { type: { name: "Composite", - className: "IdentityUserAssignedIdentitiesValue" - } - } - } - } - } - } + className: "IdentityUserAssignedIdentitiesValue", + }, + }, + }, + }, + }, + }, }; export const IdentityUserAssignedIdentitiesValue: coreClient.CompositeMapper = { @@ -1824,18 +2064,18 @@ export const IdentityUserAssignedIdentitiesValue: coreClient.CompositeMapper = { serializedName: "principalId", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, clientId: { serializedName: "clientId", readOnly: true, type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const Resource: coreClient.CompositeMapper = { @@ -1847,45 +2087,45 @@ export const Resource: coreClient.CompositeMapper = { serializedName: "id", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, name: { serializedName: "name", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, type: { serializedName: "type", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, location: { serializedName: "location", type: { - name: "String" - } + name: "String", + }, }, extendedLocation: { serializedName: "extendedLocation", type: { name: "Composite", - className: "ExtendedLocation" - } + className: "ExtendedLocation", + }, }, tags: { serializedName: "tags", type: { name: "Dictionary", - value: { type: { name: "String" } } - } - } - } - } + value: { type: { name: "String" } }, + }, + }, + }, + }, }; export const ExtendedLocation: coreClient.CompositeMapper = { @@ -1896,17 +2136,17 @@ export const ExtendedLocation: coreClient.CompositeMapper = { type: { serializedName: "type", type: { - name: "String" - } + name: "String", + }, }, name: { serializedName: "name", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const ResourceGroup: coreClient.CompositeMapper = { @@ -1918,52 +2158,52 @@ export const ResourceGroup: coreClient.CompositeMapper = { serializedName: "id", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, name: { serializedName: "name", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, type: { serializedName: "type", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, properties: { serializedName: "properties", type: { name: "Composite", - className: "ResourceGroupProperties" - } + className: "ResourceGroupProperties", + }, }, location: { serializedName: "location", required: true, type: { - name: "String" - } + name: "String", + }, }, managedBy: { serializedName: "managedBy", type: { - name: "String" - } + name: "String", + }, }, tags: { serializedName: "tags", type: { name: "Dictionary", - value: { type: { name: "String" } } - } - } - } - } + value: { type: { name: "String" } }, + }, + }, + }, + }, }; export const ResourceGroupProperties: coreClient.CompositeMapper = { @@ -1975,11 +2215,11 @@ export const ResourceGroupProperties: coreClient.CompositeMapper = { serializedName: "provisioningState", readOnly: true, type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const ResourceGroupPatchable: coreClient.CompositeMapper = { @@ -1990,31 +2230,31 @@ export const ResourceGroupPatchable: coreClient.CompositeMapper = { name: { serializedName: "name", type: { - name: "String" - } + name: "String", + }, }, properties: { serializedName: "properties", type: { name: "Composite", - className: "ResourceGroupProperties" - } + className: "ResourceGroupProperties", + }, }, managedBy: { serializedName: "managedBy", type: { - name: "String" - } + name: "String", + }, }, tags: { serializedName: "tags", type: { name: "Dictionary", - value: { type: { name: "String" } } - } - } - } - } + value: { type: { name: "String" } }, + }, + }, + }, + }, }; export const ExportTemplateRequest: coreClient.CompositeMapper = { @@ -2028,19 +2268,25 @@ export const ExportTemplateRequest: coreClient.CompositeMapper = { name: "Sequence", element: { type: { - name: "String" - } - } - } + name: "String", + }, + }, + }, }, options: { serializedName: "options", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + outputFormat: { + serializedName: "outputFormat", + type: { + name: "String", + }, + }, + }, + }, }; export const ResourceGroupExportResult: coreClient.CompositeMapper = { @@ -2052,18 +2298,24 @@ export const ResourceGroupExportResult: coreClient.CompositeMapper = { serializedName: "template", type: { name: "Dictionary", - value: { type: { name: "any" } } - } + value: { type: { name: "any" } }, + }, + }, + output: { + serializedName: "output", + type: { + name: "String", + }, }, error: { serializedName: "error", type: { name: "Composite", - className: "ErrorResponse" - } - } - } - } + className: "ErrorResponse", + }, + }, + }, + }, }; export const ResourceGroupListResult: coreClient.CompositeMapper = { @@ -2078,20 +2330,20 @@ export const ResourceGroupListResult: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "ResourceGroup" - } - } - } + className: "ResourceGroup", + }, + }, + }, }, nextLink: { serializedName: "nextLink", readOnly: true, type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const ResourcesMoveInfo: coreClient.CompositeMapper = { @@ -2105,19 +2357,19 @@ export const ResourcesMoveInfo: coreClient.CompositeMapper = { name: "Sequence", element: { type: { - name: "String" - } - } - } + name: "String", + }, + }, + }, }, targetResourceGroup: { serializedName: "targetResourceGroup", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const TagValue: coreClient.CompositeMapper = { @@ -2129,24 +2381,24 @@ export const TagValue: coreClient.CompositeMapper = { serializedName: "id", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, tagValue: { serializedName: "tagValue", type: { - name: "String" - } + name: "String", + }, }, count: { serializedName: "count", type: { name: "Composite", - className: "TagCount" - } - } - } - } + className: "TagCount", + }, + }, + }, + }, }; export const TagCount: coreClient.CompositeMapper = { @@ -2157,17 +2409,17 @@ export const TagCount: coreClient.CompositeMapper = { type: { serializedName: "type", type: { - name: "String" - } + name: "String", + }, }, value: { serializedName: "value", type: { - name: "Number" - } - } - } - } + name: "Number", + }, + }, + }, + }, }; export const TagDetails: coreClient.CompositeMapper = { @@ -2179,21 +2431,21 @@ export const TagDetails: coreClient.CompositeMapper = { serializedName: "id", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, tagName: { serializedName: "tagName", type: { - name: "String" - } + name: "String", + }, }, count: { serializedName: "count", type: { name: "Composite", - className: "TagCount" - } + className: "TagCount", + }, }, values: { serializedName: "values", @@ -2202,13 +2454,13 @@ export const TagDetails: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "TagValue" - } - } - } - } - } - } + className: "TagValue", + }, + }, + }, + }, + }, + }, }; export const TagsListResult: coreClient.CompositeMapper = { @@ -2223,20 +2475,20 @@ export const TagsListResult: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "TagDetails" - } - } - } + className: "TagDetails", + }, + }, + }, }, nextLink: { serializedName: "nextLink", readOnly: true, type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const DeploymentOperation: coreClient.CompositeMapper = { @@ -2248,25 +2500,25 @@ export const DeploymentOperation: coreClient.CompositeMapper = { serializedName: "id", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, operationId: { serializedName: "operationId", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, properties: { serializedName: "properties", type: { name: "Composite", - className: "DeploymentOperationProperties" - } - } - } - } + className: "DeploymentOperationProperties", + }, + }, + }, + }, }; export const DeploymentOperationProperties: coreClient.CompositeMapper = { @@ -2289,75 +2541,75 @@ export const DeploymentOperationProperties: coreClient.CompositeMapper = { "Action", "Read", "EvaluateDeploymentOutput", - "DeploymentCleanup" - ] - } + "DeploymentCleanup", + ], + }, }, provisioningState: { serializedName: "provisioningState", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, timestamp: { serializedName: "timestamp", readOnly: true, type: { - name: "DateTime" - } + name: "DateTime", + }, }, duration: { serializedName: "duration", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, serviceRequestId: { serializedName: "serviceRequestId", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, statusCode: { serializedName: "statusCode", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, statusMessage: { serializedName: "statusMessage", type: { name: "Composite", - className: "StatusMessage" - } + className: "StatusMessage", + }, }, targetResource: { serializedName: "targetResource", type: { name: "Composite", - className: "TargetResource" - } + className: "TargetResource", + }, }, request: { serializedName: "request", type: { name: "Composite", - className: "HttpMessage" - } + className: "HttpMessage", + }, }, response: { serializedName: "response", type: { name: "Composite", - className: "HttpMessage" - } - } - } - } + className: "HttpMessage", + }, + }, + }, + }, }; export const StatusMessage: coreClient.CompositeMapper = { @@ -2368,18 +2620,18 @@ export const StatusMessage: coreClient.CompositeMapper = { status: { serializedName: "status", type: { - name: "String" - } + name: "String", + }, }, error: { serializedName: "error", type: { name: "Composite", - className: "ErrorResponse" - } - } - } - } + className: "ErrorResponse", + }, + }, + }, + }, }; export const TargetResource: coreClient.CompositeMapper = { @@ -2390,23 +2642,23 @@ export const TargetResource: coreClient.CompositeMapper = { id: { serializedName: "id", type: { - name: "String" - } + name: "String", + }, }, resourceName: { serializedName: "resourceName", type: { - name: "String" - } + name: "String", + }, }, resourceType: { serializedName: "resourceType", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const HttpMessage: coreClient.CompositeMapper = { @@ -2418,11 +2670,11 @@ export const HttpMessage: coreClient.CompositeMapper = { serializedName: "content", type: { name: "Dictionary", - value: { type: { name: "any" } } - } - } - } - } + value: { type: { name: "any" } }, + }, + }, + }, + }, }; export const DeploymentOperationsListResult: coreClient.CompositeMapper = { @@ -2437,20 +2689,20 @@ export const DeploymentOperationsListResult: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "DeploymentOperation" - } - } - } + className: "DeploymentOperation", + }, + }, + }, }, nextLink: { serializedName: "nextLink", readOnly: true, type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const TemplateHashResult: coreClient.CompositeMapper = { @@ -2461,17 +2713,17 @@ export const TemplateHashResult: coreClient.CompositeMapper = { minifiedTemplate: { serializedName: "minifiedTemplate", type: { - name: "String" - } + name: "String", + }, }, templateHash: { serializedName: "templateHash", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const TagsResource: coreClient.CompositeMapper = { @@ -2483,32 +2735,32 @@ export const TagsResource: coreClient.CompositeMapper = { serializedName: "id", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, name: { serializedName: "name", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, type: { serializedName: "type", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, properties: { serializedName: "properties", type: { name: "Composite", - className: "Tags" - } - } - } - } + className: "Tags", + }, + }, + }, + }, }; export const Tags: coreClient.CompositeMapper = { @@ -2520,11 +2772,11 @@ export const Tags: coreClient.CompositeMapper = { serializedName: "tags", type: { name: "Dictionary", - value: { type: { name: "String" } } - } - } - } - } + value: { type: { name: "String" } }, + }, + }, + }, + }, }; export const TagsPatchResource: coreClient.CompositeMapper = { @@ -2535,18 +2787,18 @@ export const TagsPatchResource: coreClient.CompositeMapper = { operation: { serializedName: "operation", type: { - name: "String" - } + name: "String", + }, }, properties: { serializedName: "properties", type: { name: "Composite", - className: "Tags" - } - } - } - } + className: "Tags", + }, + }, + }, + }, }; export const DeploymentExtendedFilter: coreClient.CompositeMapper = { @@ -2557,11 +2809,11 @@ export const DeploymentExtendedFilter: coreClient.CompositeMapper = { provisioningState: { serializedName: "provisioningState", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const GenericResourceFilter: coreClient.CompositeMapper = { @@ -2572,23 +2824,23 @@ export const GenericResourceFilter: coreClient.CompositeMapper = { resourceType: { serializedName: "resourceType", type: { - name: "String" - } + name: "String", + }, }, tagname: { serializedName: "tagname", type: { - name: "String" - } + name: "String", + }, }, tagvalue: { serializedName: "tagvalue", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const ResourceGroupFilter: coreClient.CompositeMapper = { @@ -2599,57 +2851,58 @@ export const ResourceGroupFilter: coreClient.CompositeMapper = { tagName: { serializedName: "tagName", type: { - name: "String" - } + name: "String", + }, }, tagValue: { serializedName: "tagValue", type: { - name: "String" - } - } - } - } -}; - -export const ResourceProviderOperationDisplayProperties: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ResourceProviderOperationDisplayProperties", - modelProperties: { - publisher: { - serializedName: "publisher", - type: { - name: "String" - } - }, - provider: { - serializedName: "provider", - type: { - name: "String" - } - }, - resource: { - serializedName: "resource", - type: { - name: "String" - } + name: "String", + }, }, - operation: { - serializedName: "operation", - type: { - name: "String" - } + }, + }, +}; + +export const ResourceProviderOperationDisplayProperties: coreClient.CompositeMapper = + { + type: { + name: "Composite", + className: "ResourceProviderOperationDisplayProperties", + modelProperties: { + publisher: { + serializedName: "publisher", + type: { + name: "String", + }, + }, + provider: { + serializedName: "provider", + type: { + name: "String", + }, + }, + resource: { + serializedName: "resource", + type: { + name: "String", + }, + }, + operation: { + serializedName: "operation", + type: { + name: "String", + }, + }, + description: { + serializedName: "description", + type: { + name: "String", + }, + }, }, - description: { - serializedName: "description", - type: { - name: "String" - } - } - } - } -}; + }, + }; export const SubResource: coreClient.CompositeMapper = { type: { @@ -2659,11 +2912,11 @@ export const SubResource: coreClient.CompositeMapper = { id: { serializedName: "id", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const DeploymentWhatIfProperties: coreClient.CompositeMapper = { @@ -2676,11 +2929,11 @@ export const DeploymentWhatIfProperties: coreClient.CompositeMapper = { serializedName: "whatIfSettings", type: { name: "Composite", - className: "DeploymentWhatIfSettings" - } - } - } - } + className: "DeploymentWhatIfSettings", + }, + }, + }, + }, }; export const GenericResource: coreClient.CompositeMapper = { @@ -2693,47 +2946,47 @@ export const GenericResource: coreClient.CompositeMapper = { serializedName: "plan", type: { name: "Composite", - className: "Plan" - } + className: "Plan", + }, }, properties: { serializedName: "properties", type: { name: "Dictionary", - value: { type: { name: "any" } } - } + value: { type: { name: "any" } }, + }, }, kind: { constraints: { - Pattern: new RegExp("^[-\\w\\._,\\(\\)]+$") + Pattern: new RegExp("^[-\\w\\._,\\(\\)]+$"), }, serializedName: "kind", type: { - name: "String" - } + name: "String", + }, }, managedBy: { serializedName: "managedBy", type: { - name: "String" - } + name: "String", + }, }, sku: { serializedName: "sku", type: { name: "Composite", - className: "Sku" - } + className: "Sku", + }, }, identity: { serializedName: "identity", type: { name: "Composite", - className: "Identity" - } - } - } - } + className: "Identity", + }, + }, + }, + }, }; export const GenericResourceExpanded: coreClient.CompositeMapper = { @@ -2746,107 +2999,170 @@ export const GenericResourceExpanded: coreClient.CompositeMapper = { serializedName: "createdTime", readOnly: true, type: { - name: "DateTime" - } + name: "DateTime", + }, }, changedTime: { serializedName: "changedTime", readOnly: true, type: { - name: "DateTime" - } + name: "DateTime", + }, }, provisioningState: { serializedName: "provisioningState", readOnly: true, type: { - name: "String" - } - } - } - } -}; + name: "String", + }, + }, + }, + }, +}; + +export const DeploymentsWhatIfAtTenantScopeHeaders: coreClient.CompositeMapper = + { + type: { + name: "Composite", + className: "DeploymentsWhatIfAtTenantScopeHeaders", + modelProperties: { + location: { + serializedName: "location", + type: { + name: "String", + }, + }, + retryAfter: { + serializedName: "retry-after", + type: { + name: "String", + }, + }, + }, + }, + }; + +export const DeploymentsWhatIfAtManagementGroupScopeHeaders: coreClient.CompositeMapper = + { + type: { + name: "Composite", + className: "DeploymentsWhatIfAtManagementGroupScopeHeaders", + modelProperties: { + location: { + serializedName: "location", + type: { + name: "String", + }, + }, + retryAfter: { + serializedName: "retry-after", + type: { + name: "String", + }, + }, + }, + }, + }; + +export const DeploymentsWhatIfAtSubscriptionScopeHeaders: coreClient.CompositeMapper = + { + type: { + name: "Composite", + className: "DeploymentsWhatIfAtSubscriptionScopeHeaders", + modelProperties: { + location: { + serializedName: "location", + type: { + name: "String", + }, + }, + retryAfter: { + serializedName: "retry-after", + type: { + name: "String", + }, + }, + }, + }, + }; -export const DeploymentsWhatIfAtTenantScopeHeaders: coreClient.CompositeMapper = { +export const DeploymentsWhatIfHeaders: coreClient.CompositeMapper = { type: { name: "Composite", - className: "DeploymentsWhatIfAtTenantScopeHeaders", + className: "DeploymentsWhatIfHeaders", modelProperties: { location: { serializedName: "location", type: { - name: "String" - } + name: "String", + }, }, retryAfter: { serializedName: "retry-after", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; -export const DeploymentsWhatIfAtManagementGroupScopeHeaders: coreClient.CompositeMapper = { +export const ResourceGroupsDeleteHeaders: coreClient.CompositeMapper = { type: { name: "Composite", - className: "DeploymentsWhatIfAtManagementGroupScopeHeaders", + className: "ResourceGroupsDeleteHeaders", modelProperties: { location: { serializedName: "location", type: { - name: "String" - } + name: "String", + }, }, - retryAfter: { - serializedName: "retry-after", - type: { - name: "String" - } - } - } - } + }, + }, }; -export const DeploymentsWhatIfAtSubscriptionScopeHeaders: coreClient.CompositeMapper = { +export const TagsCreateOrUpdateAtScopeHeaders: coreClient.CompositeMapper = { type: { name: "Composite", - className: "DeploymentsWhatIfAtSubscriptionScopeHeaders", + className: "TagsCreateOrUpdateAtScopeHeaders", modelProperties: { location: { serializedName: "location", type: { - name: "String" - } + name: "String", + }, }, - retryAfter: { - serializedName: "retry-after", - type: { - name: "String" - } - } - } - } + }, + }, }; -export const DeploymentsWhatIfHeaders: coreClient.CompositeMapper = { +export const TagsUpdateAtScopeHeaders: coreClient.CompositeMapper = { type: { name: "Composite", - className: "DeploymentsWhatIfHeaders", + className: "TagsUpdateAtScopeHeaders", modelProperties: { location: { serializedName: "location", type: { - name: "String" - } + name: "String", + }, }, - retryAfter: { - serializedName: "retry-after", + }, + }, +}; + +export const TagsDeleteAtScopeHeaders: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "TagsDeleteAtScopeHeaders", + modelProperties: { + location: { + serializedName: "location", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; diff --git a/sdk/resources/arm-resources/src/models/parameters.ts b/sdk/resources/arm-resources/src/models/parameters.ts index 4e19dc1f6919..4831cb95af5e 100644 --- a/sdk/resources/arm-resources/src/models/parameters.ts +++ b/sdk/resources/arm-resources/src/models/parameters.ts @@ -9,7 +9,7 @@ import { OperationParameter, OperationURLParameter, - OperationQueryParameter + OperationQueryParameter, } from "@azure/core-client"; import { Deployment as DeploymentMapper, @@ -23,7 +23,7 @@ import { ResourceGroupPatchable as ResourceGroupPatchableMapper, ExportTemplateRequest as ExportTemplateRequestMapper, TagsResource as TagsResourceMapper, - TagsPatchResource as TagsPatchResourceMapper + TagsPatchResource as TagsPatchResourceMapper, } from "../models/mappers"; export const accept: OperationParameter = { @@ -33,9 +33,9 @@ export const accept: OperationParameter = { isConstant: true, serializedName: "Accept", type: { - name: "String" - } - } + name: "String", + }, + }, }; export const $host: OperationURLParameter = { @@ -44,22 +44,22 @@ export const $host: OperationURLParameter = { serializedName: "$host", required: true, type: { - name: "String" - } + name: "String", + }, }, - skipEncoding: true + skipEncoding: true, }; export const apiVersion: OperationQueryParameter = { parameterPath: "apiVersion", mapper: { - defaultValue: "2021-04-01", + defaultValue: "2024-11-01", isConstant: true, serializedName: "api-version", type: { - name: "String" - } - } + name: "String", + }, + }, }; export const nextLink: OperationURLParameter = { @@ -68,10 +68,10 @@ export const nextLink: OperationURLParameter = { serializedName: "nextLink", required: true, type: { - name: "String" - } + name: "String", + }, }, - skipEncoding: true + skipEncoding: true, }; export const scope: OperationURLParameter = { @@ -80,10 +80,10 @@ export const scope: OperationURLParameter = { serializedName: "scope", required: true, type: { - name: "String" - } + name: "String", + }, }, - skipEncoding: true + skipEncoding: true, }; export const deploymentName: OperationURLParameter = { @@ -92,14 +92,14 @@ export const deploymentName: OperationURLParameter = { constraints: { Pattern: new RegExp("^[-\\w\\._\\(\\)]+$"), MaxLength: 64, - MinLength: 1 + MinLength: 1, }, serializedName: "deploymentName", required: true, type: { - name: "String" - } - } + name: "String", + }, + }, }; export const contentType: OperationParameter = { @@ -109,14 +109,14 @@ export const contentType: OperationParameter = { isConstant: true, serializedName: "Content-Type", type: { - name: "String" - } - } + name: "String", + }, + }, }; export const parameters: OperationParameter = { parameterPath: "parameters", - mapper: DeploymentMapper + mapper: DeploymentMapper, }; export const filter: OperationQueryParameter = { @@ -124,9 +124,9 @@ export const filter: OperationQueryParameter = { mapper: { serializedName: "$filter", type: { - name: "String" - } - } + name: "String", + }, + }, }; export const top: OperationQueryParameter = { @@ -134,19 +134,19 @@ export const top: OperationQueryParameter = { mapper: { serializedName: "$top", type: { - name: "Number" - } - } + name: "Number", + }, + }, }; export const parameters1: OperationParameter = { parameterPath: "parameters", - mapper: ScopedDeploymentMapper + mapper: ScopedDeploymentMapper, }; export const parameters2: OperationParameter = { parameterPath: "parameters", - mapper: ScopedDeploymentWhatIfMapper + mapper: ScopedDeploymentWhatIfMapper, }; export const groupId: OperationURLParameter = { @@ -154,14 +154,14 @@ export const groupId: OperationURLParameter = { mapper: { constraints: { MaxLength: 90, - MinLength: 1 + MinLength: 1, }, serializedName: "groupId", required: true, type: { - name: "String" - } - } + name: "String", + }, + }, }; export const subscriptionId: OperationURLParameter = { @@ -170,14 +170,14 @@ export const subscriptionId: OperationURLParameter = { serializedName: "subscriptionId", required: true, type: { - name: "String" - } - } + name: "String", + }, + }, }; export const parameters3: OperationParameter = { parameterPath: "parameters", - mapper: DeploymentWhatIfMapper + mapper: DeploymentWhatIfMapper, }; export const resourceGroupName: OperationURLParameter = { @@ -186,14 +186,14 @@ export const resourceGroupName: OperationURLParameter = { constraints: { Pattern: new RegExp("^[-\\w\\._\\(\\)]+$"), MaxLength: 90, - MinLength: 1 + MinLength: 1, }, serializedName: "resourceGroupName", required: true, type: { - name: "String" - } - } + name: "String", + }, + }, }; export const template: OperationParameter = { @@ -203,9 +203,9 @@ export const template: OperationParameter = { required: true, type: { name: "Dictionary", - value: { type: { name: "any" } } - } - } + value: { type: { name: "any" } }, + }, + }, }; export const resourceProviderNamespace: OperationURLParameter = { @@ -214,14 +214,14 @@ export const resourceProviderNamespace: OperationURLParameter = { serializedName: "resourceProviderNamespace", required: true, type: { - name: "String" - } - } + name: "String", + }, + }, }; export const properties: OperationParameter = { parameterPath: ["options", "properties"], - mapper: ProviderRegistrationRequestMapper + mapper: ProviderRegistrationRequestMapper, }; export const expand: OperationQueryParameter = { @@ -229,14 +229,14 @@ export const expand: OperationQueryParameter = { mapper: { serializedName: "$expand", type: { - name: "String" - } - } + name: "String", + }, + }, }; export const parameters4: OperationParameter = { parameterPath: "parameters", - mapper: ResourcesMoveInfoMapper + mapper: ResourcesMoveInfoMapper, }; export const sourceResourceGroupName: OperationURLParameter = { @@ -245,14 +245,14 @@ export const sourceResourceGroupName: OperationURLParameter = { constraints: { Pattern: new RegExp("^[-\\w\\._\\(\\)]+$"), MaxLength: 90, - MinLength: 1 + MinLength: 1, }, serializedName: "sourceResourceGroupName", required: true, type: { - name: "String" - } - } + name: "String", + }, + }, }; export const parentResourcePath: OperationURLParameter = { @@ -261,10 +261,10 @@ export const parentResourcePath: OperationURLParameter = { serializedName: "parentResourcePath", required: true, type: { - name: "String" - } + name: "String", + }, }, - skipEncoding: true + skipEncoding: true, }; export const resourceType: OperationURLParameter = { @@ -273,10 +273,10 @@ export const resourceType: OperationURLParameter = { serializedName: "resourceType", required: true, type: { - name: "String" - } + name: "String", + }, }, - skipEncoding: true + skipEncoding: true, }; export const resourceName: OperationURLParameter = { @@ -285,9 +285,9 @@ export const resourceName: OperationURLParameter = { serializedName: "resourceName", required: true, type: { - name: "String" - } - } + name: "String", + }, + }, }; export const apiVersion1: OperationQueryParameter = { @@ -296,14 +296,14 @@ export const apiVersion1: OperationQueryParameter = { serializedName: "api-version", required: true, type: { - name: "String" - } - } + name: "String", + }, + }, }; export const parameters5: OperationParameter = { parameterPath: "parameters", - mapper: GenericResourceMapper + mapper: GenericResourceMapper, }; export const resourceId: OperationURLParameter = { @@ -312,15 +312,15 @@ export const resourceId: OperationURLParameter = { serializedName: "resourceId", required: true, type: { - name: "String" - } + name: "String", + }, }, - skipEncoding: true + skipEncoding: true, }; export const parameters6: OperationParameter = { parameterPath: "parameters", - mapper: ResourceGroupMapper + mapper: ResourceGroupMapper, }; export const forceDeletionTypes: OperationQueryParameter = { @@ -328,19 +328,19 @@ export const forceDeletionTypes: OperationQueryParameter = { mapper: { serializedName: "forceDeletionTypes", type: { - name: "String" - } - } + name: "String", + }, + }, }; export const parameters7: OperationParameter = { parameterPath: "parameters", - mapper: ResourceGroupPatchableMapper + mapper: ResourceGroupPatchableMapper, }; export const parameters8: OperationParameter = { parameterPath: "parameters", - mapper: ExportTemplateRequestMapper + mapper: ExportTemplateRequestMapper, }; export const resourceGroupName1: OperationURLParameter = { @@ -348,14 +348,14 @@ export const resourceGroupName1: OperationURLParameter = { mapper: { constraints: { MaxLength: 90, - MinLength: 1 + MinLength: 1, }, serializedName: "resourceGroupName", required: true, type: { - name: "String" - } - } + name: "String", + }, + }, }; export const tagName: OperationURLParameter = { @@ -364,9 +364,9 @@ export const tagName: OperationURLParameter = { serializedName: "tagName", required: true, type: { - name: "String" - } - } + name: "String", + }, + }, }; export const tagValue: OperationURLParameter = { @@ -375,19 +375,19 @@ export const tagValue: OperationURLParameter = { serializedName: "tagValue", required: true, type: { - name: "String" - } - } + name: "String", + }, + }, }; export const parameters9: OperationParameter = { parameterPath: "parameters", - mapper: TagsResourceMapper + mapper: TagsResourceMapper, }; export const parameters10: OperationParameter = { parameterPath: "parameters", - mapper: TagsPatchResourceMapper + mapper: TagsPatchResourceMapper, }; export const operationId: OperationURLParameter = { @@ -396,7 +396,7 @@ export const operationId: OperationURLParameter = { serializedName: "operationId", required: true, type: { - name: "String" - } - } + name: "String", + }, + }, }; diff --git a/sdk/resources/arm-resources/src/operations/deploymentOperations.ts b/sdk/resources/arm-resources/src/operations/deploymentOperations.ts index ac58be548913..8bd436dfc7aa 100644 --- a/sdk/resources/arm-resources/src/operations/deploymentOperations.ts +++ b/sdk/resources/arm-resources/src/operations/deploymentOperations.ts @@ -44,7 +44,7 @@ import { DeploymentOperationsListAtTenantScopeNextResponse, DeploymentOperationsListAtManagementGroupScopeNextResponse, DeploymentOperationsListAtSubscriptionScopeNextResponse, - DeploymentOperationsListNextResponse + DeploymentOperationsListNextResponse, } from "../models"; /// @@ -69,7 +69,7 @@ export class DeploymentOperationsImpl implements DeploymentOperations { public listAtScope( scope: string, deploymentName: string, - options?: DeploymentOperationsListAtScopeOptionalParams + options?: DeploymentOperationsListAtScopeOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listAtScopePagingAll(scope, deploymentName, options); return { @@ -87,9 +87,9 @@ export class DeploymentOperationsImpl implements DeploymentOperations { scope, deploymentName, options, - settings + settings, ); - } + }, }; } @@ -97,7 +97,7 @@ export class DeploymentOperationsImpl implements DeploymentOperations { scope: string, deploymentName: string, options?: DeploymentOperationsListAtScopeOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: DeploymentOperationsListAtScopeResponse; let continuationToken = settings?.continuationToken; @@ -113,7 +113,7 @@ export class DeploymentOperationsImpl implements DeploymentOperations { scope, deploymentName, continuationToken, - options + options, ); continuationToken = result.nextLink; let page = result.value || []; @@ -125,12 +125,12 @@ export class DeploymentOperationsImpl implements DeploymentOperations { private async *listAtScopePagingAll( scope: string, deploymentName: string, - options?: DeploymentOperationsListAtScopeOptionalParams + options?: DeploymentOperationsListAtScopeOptionalParams, ): AsyncIterableIterator { for await (const page of this.listAtScopePagingPage( scope, deploymentName, - options + options, )) { yield* page; } @@ -143,7 +143,7 @@ export class DeploymentOperationsImpl implements DeploymentOperations { */ public listAtTenantScope( deploymentName: string, - options?: DeploymentOperationsListAtTenantScopeOptionalParams + options?: DeploymentOperationsListAtTenantScopeOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listAtTenantScopePagingAll(deploymentName, options); return { @@ -160,16 +160,16 @@ export class DeploymentOperationsImpl implements DeploymentOperations { return this.listAtTenantScopePagingPage( deploymentName, options, - settings + settings, ); - } + }, }; } private async *listAtTenantScopePagingPage( deploymentName: string, options?: DeploymentOperationsListAtTenantScopeOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: DeploymentOperationsListAtTenantScopeResponse; let continuationToken = settings?.continuationToken; @@ -184,7 +184,7 @@ export class DeploymentOperationsImpl implements DeploymentOperations { result = await this._listAtTenantScopeNext( deploymentName, continuationToken, - options + options, ); continuationToken = result.nextLink; let page = result.value || []; @@ -195,11 +195,11 @@ export class DeploymentOperationsImpl implements DeploymentOperations { private async *listAtTenantScopePagingAll( deploymentName: string, - options?: DeploymentOperationsListAtTenantScopeOptionalParams + options?: DeploymentOperationsListAtTenantScopeOptionalParams, ): AsyncIterableIterator { for await (const page of this.listAtTenantScopePagingPage( deploymentName, - options + options, )) { yield* page; } @@ -214,12 +214,12 @@ export class DeploymentOperationsImpl implements DeploymentOperations { public listAtManagementGroupScope( groupId: string, deploymentName: string, - options?: DeploymentOperationsListAtManagementGroupScopeOptionalParams + options?: DeploymentOperationsListAtManagementGroupScopeOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listAtManagementGroupScopePagingAll( groupId, deploymentName, - options + options, ); return { next() { @@ -236,9 +236,9 @@ export class DeploymentOperationsImpl implements DeploymentOperations { groupId, deploymentName, options, - settings + settings, ); - } + }, }; } @@ -246,7 +246,7 @@ export class DeploymentOperationsImpl implements DeploymentOperations { groupId: string, deploymentName: string, options?: DeploymentOperationsListAtManagementGroupScopeOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: DeploymentOperationsListAtManagementGroupScopeResponse; let continuationToken = settings?.continuationToken; @@ -254,7 +254,7 @@ export class DeploymentOperationsImpl implements DeploymentOperations { result = await this._listAtManagementGroupScope( groupId, deploymentName, - options + options, ); let page = result.value || []; continuationToken = result.nextLink; @@ -266,7 +266,7 @@ export class DeploymentOperationsImpl implements DeploymentOperations { groupId, deploymentName, continuationToken, - options + options, ); continuationToken = result.nextLink; let page = result.value || []; @@ -278,12 +278,12 @@ export class DeploymentOperationsImpl implements DeploymentOperations { private async *listAtManagementGroupScopePagingAll( groupId: string, deploymentName: string, - options?: DeploymentOperationsListAtManagementGroupScopeOptionalParams + options?: DeploymentOperationsListAtManagementGroupScopeOptionalParams, ): AsyncIterableIterator { for await (const page of this.listAtManagementGroupScopePagingPage( groupId, deploymentName, - options + options, )) { yield* page; } @@ -296,7 +296,7 @@ export class DeploymentOperationsImpl implements DeploymentOperations { */ public listAtSubscriptionScope( deploymentName: string, - options?: DeploymentOperationsListAtSubscriptionScopeOptionalParams + options?: DeploymentOperationsListAtSubscriptionScopeOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listAtSubscriptionScopePagingAll(deploymentName, options); return { @@ -313,16 +313,16 @@ export class DeploymentOperationsImpl implements DeploymentOperations { return this.listAtSubscriptionScopePagingPage( deploymentName, options, - settings + settings, ); - } + }, }; } private async *listAtSubscriptionScopePagingPage( deploymentName: string, options?: DeploymentOperationsListAtSubscriptionScopeOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: DeploymentOperationsListAtSubscriptionScopeResponse; let continuationToken = settings?.continuationToken; @@ -337,7 +337,7 @@ export class DeploymentOperationsImpl implements DeploymentOperations { result = await this._listAtSubscriptionScopeNext( deploymentName, continuationToken, - options + options, ); continuationToken = result.nextLink; let page = result.value || []; @@ -348,11 +348,11 @@ export class DeploymentOperationsImpl implements DeploymentOperations { private async *listAtSubscriptionScopePagingAll( deploymentName: string, - options?: DeploymentOperationsListAtSubscriptionScopeOptionalParams + options?: DeploymentOperationsListAtSubscriptionScopeOptionalParams, ): AsyncIterableIterator { for await (const page of this.listAtSubscriptionScopePagingPage( deploymentName, - options + options, )) { yield* page; } @@ -367,7 +367,7 @@ export class DeploymentOperationsImpl implements DeploymentOperations { public list( resourceGroupName: string, deploymentName: string, - options?: DeploymentOperationsListOptionalParams + options?: DeploymentOperationsListOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listPagingAll(resourceGroupName, deploymentName, options); return { @@ -385,9 +385,9 @@ export class DeploymentOperationsImpl implements DeploymentOperations { resourceGroupName, deploymentName, options, - settings + settings, ); - } + }, }; } @@ -395,7 +395,7 @@ export class DeploymentOperationsImpl implements DeploymentOperations { resourceGroupName: string, deploymentName: string, options?: DeploymentOperationsListOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: DeploymentOperationsListResponse; let continuationToken = settings?.continuationToken; @@ -411,7 +411,7 @@ export class DeploymentOperationsImpl implements DeploymentOperations { resourceGroupName, deploymentName, continuationToken, - options + options, ); continuationToken = result.nextLink; let page = result.value || []; @@ -423,12 +423,12 @@ export class DeploymentOperationsImpl implements DeploymentOperations { private async *listPagingAll( resourceGroupName: string, deploymentName: string, - options?: DeploymentOperationsListOptionalParams + options?: DeploymentOperationsListOptionalParams, ): AsyncIterableIterator { for await (const page of this.listPagingPage( resourceGroupName, deploymentName, - options + options, )) { yield* page; } @@ -445,11 +445,11 @@ export class DeploymentOperationsImpl implements DeploymentOperations { scope: string, deploymentName: string, operationId: string, - options?: DeploymentOperationsGetAtScopeOptionalParams + options?: DeploymentOperationsGetAtScopeOptionalParams, ): Promise { return this.client.sendOperationRequest( { scope, deploymentName, operationId, options }, - getAtScopeOperationSpec + getAtScopeOperationSpec, ); } @@ -462,11 +462,11 @@ export class DeploymentOperationsImpl implements DeploymentOperations { private _listAtScope( scope: string, deploymentName: string, - options?: DeploymentOperationsListAtScopeOptionalParams + options?: DeploymentOperationsListAtScopeOptionalParams, ): Promise { return this.client.sendOperationRequest( { scope, deploymentName, options }, - listAtScopeOperationSpec + listAtScopeOperationSpec, ); } @@ -479,11 +479,11 @@ export class DeploymentOperationsImpl implements DeploymentOperations { getAtTenantScope( deploymentName: string, operationId: string, - options?: DeploymentOperationsGetAtTenantScopeOptionalParams + options?: DeploymentOperationsGetAtTenantScopeOptionalParams, ): Promise { return this.client.sendOperationRequest( { deploymentName, operationId, options }, - getAtTenantScopeOperationSpec + getAtTenantScopeOperationSpec, ); } @@ -494,11 +494,11 @@ export class DeploymentOperationsImpl implements DeploymentOperations { */ private _listAtTenantScope( deploymentName: string, - options?: DeploymentOperationsListAtTenantScopeOptionalParams + options?: DeploymentOperationsListAtTenantScopeOptionalParams, ): Promise { return this.client.sendOperationRequest( { deploymentName, options }, - listAtTenantScopeOperationSpec + listAtTenantScopeOperationSpec, ); } @@ -513,11 +513,11 @@ export class DeploymentOperationsImpl implements DeploymentOperations { groupId: string, deploymentName: string, operationId: string, - options?: DeploymentOperationsGetAtManagementGroupScopeOptionalParams + options?: DeploymentOperationsGetAtManagementGroupScopeOptionalParams, ): Promise { return this.client.sendOperationRequest( { groupId, deploymentName, operationId, options }, - getAtManagementGroupScopeOperationSpec + getAtManagementGroupScopeOperationSpec, ); } @@ -530,11 +530,11 @@ export class DeploymentOperationsImpl implements DeploymentOperations { private _listAtManagementGroupScope( groupId: string, deploymentName: string, - options?: DeploymentOperationsListAtManagementGroupScopeOptionalParams + options?: DeploymentOperationsListAtManagementGroupScopeOptionalParams, ): Promise { return this.client.sendOperationRequest( { groupId, deploymentName, options }, - listAtManagementGroupScopeOperationSpec + listAtManagementGroupScopeOperationSpec, ); } @@ -547,11 +547,11 @@ export class DeploymentOperationsImpl implements DeploymentOperations { getAtSubscriptionScope( deploymentName: string, operationId: string, - options?: DeploymentOperationsGetAtSubscriptionScopeOptionalParams + options?: DeploymentOperationsGetAtSubscriptionScopeOptionalParams, ): Promise { return this.client.sendOperationRequest( { deploymentName, operationId, options }, - getAtSubscriptionScopeOperationSpec + getAtSubscriptionScopeOperationSpec, ); } @@ -562,11 +562,11 @@ export class DeploymentOperationsImpl implements DeploymentOperations { */ private _listAtSubscriptionScope( deploymentName: string, - options?: DeploymentOperationsListAtSubscriptionScopeOptionalParams + options?: DeploymentOperationsListAtSubscriptionScopeOptionalParams, ): Promise { return this.client.sendOperationRequest( { deploymentName, options }, - listAtSubscriptionScopeOperationSpec + listAtSubscriptionScopeOperationSpec, ); } @@ -581,11 +581,11 @@ export class DeploymentOperationsImpl implements DeploymentOperations { resourceGroupName: string, deploymentName: string, operationId: string, - options?: DeploymentOperationsGetOptionalParams + options?: DeploymentOperationsGetOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceGroupName, deploymentName, operationId, options }, - getOperationSpec + getOperationSpec, ); } @@ -598,11 +598,11 @@ export class DeploymentOperationsImpl implements DeploymentOperations { private _list( resourceGroupName: string, deploymentName: string, - options?: DeploymentOperationsListOptionalParams + options?: DeploymentOperationsListOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceGroupName, deploymentName, options }, - listOperationSpec + listOperationSpec, ); } @@ -617,11 +617,11 @@ export class DeploymentOperationsImpl implements DeploymentOperations { scope: string, deploymentName: string, nextLink: string, - options?: DeploymentOperationsListAtScopeNextOptionalParams + options?: DeploymentOperationsListAtScopeNextOptionalParams, ): Promise { return this.client.sendOperationRequest( { scope, deploymentName, nextLink, options }, - listAtScopeNextOperationSpec + listAtScopeNextOperationSpec, ); } @@ -634,11 +634,11 @@ export class DeploymentOperationsImpl implements DeploymentOperations { private _listAtTenantScopeNext( deploymentName: string, nextLink: string, - options?: DeploymentOperationsListAtTenantScopeNextOptionalParams + options?: DeploymentOperationsListAtTenantScopeNextOptionalParams, ): Promise { return this.client.sendOperationRequest( { deploymentName, nextLink, options }, - listAtTenantScopeNextOperationSpec + listAtTenantScopeNextOperationSpec, ); } @@ -654,11 +654,11 @@ export class DeploymentOperationsImpl implements DeploymentOperations { groupId: string, deploymentName: string, nextLink: string, - options?: DeploymentOperationsListAtManagementGroupScopeNextOptionalParams + options?: DeploymentOperationsListAtManagementGroupScopeNextOptionalParams, ): Promise { return this.client.sendOperationRequest( { groupId, deploymentName, nextLink, options }, - listAtManagementGroupScopeNextOperationSpec + listAtManagementGroupScopeNextOperationSpec, ); } @@ -672,11 +672,11 @@ export class DeploymentOperationsImpl implements DeploymentOperations { private _listAtSubscriptionScopeNext( deploymentName: string, nextLink: string, - options?: DeploymentOperationsListAtSubscriptionScopeNextOptionalParams + options?: DeploymentOperationsListAtSubscriptionScopeNextOptionalParams, ): Promise { return this.client.sendOperationRequest( { deploymentName, nextLink, options }, - listAtSubscriptionScopeNextOperationSpec + listAtSubscriptionScopeNextOperationSpec, ); } @@ -691,11 +691,11 @@ export class DeploymentOperationsImpl implements DeploymentOperations { resourceGroupName: string, deploymentName: string, nextLink: string, - options?: DeploymentOperationsListNextOptionalParams + options?: DeploymentOperationsListNextOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceGroupName, deploymentName, nextLink, options }, - listNextOperationSpec + listNextOperationSpec, ); } } @@ -703,183 +703,174 @@ export class DeploymentOperationsImpl implements DeploymentOperations { const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); const getAtScopeOperationSpec: coreClient.OperationSpec = { - path: - "/{scope}/providers/Microsoft.Resources/deployments/{deploymentName}/operations/{operationId}", + path: "/{scope}/providers/Microsoft.Resources/deployments/{deploymentName}/operations/{operationId}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.DeploymentOperation + bodyMapper: Mappers.DeploymentOperation, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.scope, Parameters.deploymentName, - Parameters.operationId + Parameters.operationId, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const listAtScopeOperationSpec: coreClient.OperationSpec = { - path: - "/{scope}/providers/Microsoft.Resources/deployments/{deploymentName}/operations", + path: "/{scope}/providers/Microsoft.Resources/deployments/{deploymentName}/operations", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.DeploymentOperationsListResult + bodyMapper: Mappers.DeploymentOperationsListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion, Parameters.top], urlParameters: [ Parameters.$host, Parameters.scope, - Parameters.deploymentName + Parameters.deploymentName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const getAtTenantScopeOperationSpec: coreClient.OperationSpec = { - path: - "/providers/Microsoft.Resources/deployments/{deploymentName}/operations/{operationId}", + path: "/providers/Microsoft.Resources/deployments/{deploymentName}/operations/{operationId}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.DeploymentOperation + bodyMapper: Mappers.DeploymentOperation, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.deploymentName, - Parameters.operationId + Parameters.operationId, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const listAtTenantScopeOperationSpec: coreClient.OperationSpec = { - path: - "/providers/Microsoft.Resources/deployments/{deploymentName}/operations", + path: "/providers/Microsoft.Resources/deployments/{deploymentName}/operations", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.DeploymentOperationsListResult + bodyMapper: Mappers.DeploymentOperationsListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion, Parameters.top], urlParameters: [Parameters.$host, Parameters.deploymentName], headerParameters: [Parameters.accept], - serializer + serializer, }; const getAtManagementGroupScopeOperationSpec: coreClient.OperationSpec = { - path: - "/providers/Microsoft.Management/managementGroups/{groupId}/providers/Microsoft.Resources/deployments/{deploymentName}/operations/{operationId}", + path: "/providers/Microsoft.Management/managementGroups/{groupId}/providers/Microsoft.Resources/deployments/{deploymentName}/operations/{operationId}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.DeploymentOperation + bodyMapper: Mappers.DeploymentOperation, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.deploymentName, Parameters.groupId, - Parameters.operationId + Parameters.operationId, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const listAtManagementGroupScopeOperationSpec: coreClient.OperationSpec = { - path: - "/providers/Microsoft.Management/managementGroups/{groupId}/providers/Microsoft.Resources/deployments/{deploymentName}/operations", + path: "/providers/Microsoft.Management/managementGroups/{groupId}/providers/Microsoft.Resources/deployments/{deploymentName}/operations", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.DeploymentOperationsListResult + bodyMapper: Mappers.DeploymentOperationsListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion, Parameters.top], urlParameters: [ Parameters.$host, Parameters.deploymentName, - Parameters.groupId + Parameters.groupId, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const getAtSubscriptionScopeOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/providers/Microsoft.Resources/deployments/{deploymentName}/operations/{operationId}", + path: "/subscriptions/{subscriptionId}/providers/Microsoft.Resources/deployments/{deploymentName}/operations/{operationId}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.DeploymentOperation + bodyMapper: Mappers.DeploymentOperation, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.deploymentName, Parameters.subscriptionId, - Parameters.operationId + Parameters.operationId, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const listAtSubscriptionScopeOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/providers/Microsoft.Resources/deployments/{deploymentName}/operations", + path: "/subscriptions/{subscriptionId}/providers/Microsoft.Resources/deployments/{deploymentName}/operations", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.DeploymentOperationsListResult + bodyMapper: Mappers.DeploymentOperationsListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion, Parameters.top], urlParameters: [ Parameters.$host, Parameters.deploymentName, - Parameters.subscriptionId + Parameters.subscriptionId, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const getOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/deployments/{deploymentName}/operations/{operationId}", + path: "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/deployments/{deploymentName}/operations/{operationId}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.DeploymentOperation + bodyMapper: Mappers.DeploymentOperation, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ @@ -887,130 +878,129 @@ const getOperationSpec: coreClient.OperationSpec = { Parameters.deploymentName, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.operationId + Parameters.operationId, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const listOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/deployments/{deploymentName}/operations", + path: "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/deployments/{deploymentName}/operations", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.DeploymentOperationsListResult + bodyMapper: Mappers.DeploymentOperationsListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion, Parameters.top], urlParameters: [ Parameters.$host, Parameters.deploymentName, Parameters.subscriptionId, - Parameters.resourceGroupName + Parameters.resourceGroupName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const listAtScopeNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.DeploymentOperationsListResult + bodyMapper: Mappers.DeploymentOperationsListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, urlParameters: [ Parameters.$host, Parameters.nextLink, Parameters.scope, - Parameters.deploymentName + Parameters.deploymentName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const listAtTenantScopeNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.DeploymentOperationsListResult + bodyMapper: Mappers.DeploymentOperationsListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, urlParameters: [ Parameters.$host, Parameters.nextLink, - Parameters.deploymentName + Parameters.deploymentName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const listAtManagementGroupScopeNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.DeploymentOperationsListResult + bodyMapper: Mappers.DeploymentOperationsListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, urlParameters: [ Parameters.$host, Parameters.nextLink, Parameters.deploymentName, - Parameters.groupId + Parameters.groupId, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const listAtSubscriptionScopeNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.DeploymentOperationsListResult + bodyMapper: Mappers.DeploymentOperationsListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, urlParameters: [ Parameters.$host, Parameters.nextLink, Parameters.deploymentName, - Parameters.subscriptionId + Parameters.subscriptionId, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const listNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.DeploymentOperationsListResult + bodyMapper: Mappers.DeploymentOperationsListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, urlParameters: [ Parameters.$host, Parameters.nextLink, Parameters.deploymentName, Parameters.subscriptionId, - Parameters.resourceGroupName + Parameters.resourceGroupName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; diff --git a/sdk/resources/arm-resources/src/operations/deployments.ts b/sdk/resources/arm-resources/src/operations/deployments.ts index 16f7ba8fcda2..4ab527c890e6 100644 --- a/sdk/resources/arm-resources/src/operations/deployments.ts +++ b/sdk/resources/arm-resources/src/operations/deployments.ts @@ -16,7 +16,7 @@ import { ResourceManagementClient } from "../resourceManagementClient"; import { SimplePollerLike, OperationState, - createHttpPoller + createHttpPoller, } from "@azure/core-lro"; import { createLroSpec } from "../lroImpl"; import { @@ -114,7 +114,7 @@ import { DeploymentsListAtTenantScopeNextResponse, DeploymentsListAtManagementGroupScopeNextResponse, DeploymentsListAtSubscriptionScopeNextResponse, - DeploymentsListByResourceGroupNextResponse + DeploymentsListByResourceGroupNextResponse, } from "../models"; /// @@ -137,7 +137,7 @@ export class DeploymentsImpl implements Deployments { */ public listAtScope( scope: string, - options?: DeploymentsListAtScopeOptionalParams + options?: DeploymentsListAtScopeOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listAtScopePagingAll(scope, options); return { @@ -152,14 +152,14 @@ export class DeploymentsImpl implements Deployments { throw new Error("maxPageSize is not supported by this operation."); } return this.listAtScopePagingPage(scope, options, settings); - } + }, }; } private async *listAtScopePagingPage( scope: string, options?: DeploymentsListAtScopeOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: DeploymentsListAtScopeResponse; let continuationToken = settings?.continuationToken; @@ -181,7 +181,7 @@ export class DeploymentsImpl implements Deployments { private async *listAtScopePagingAll( scope: string, - options?: DeploymentsListAtScopeOptionalParams + options?: DeploymentsListAtScopeOptionalParams, ): AsyncIterableIterator { for await (const page of this.listAtScopePagingPage(scope, options)) { yield* page; @@ -193,7 +193,7 @@ export class DeploymentsImpl implements Deployments { * @param options The options parameters. */ public listAtTenantScope( - options?: DeploymentsListAtTenantScopeOptionalParams + options?: DeploymentsListAtTenantScopeOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listAtTenantScopePagingAll(options); return { @@ -208,13 +208,13 @@ export class DeploymentsImpl implements Deployments { throw new Error("maxPageSize is not supported by this operation."); } return this.listAtTenantScopePagingPage(options, settings); - } + }, }; } private async *listAtTenantScopePagingPage( options?: DeploymentsListAtTenantScopeOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: DeploymentsListAtTenantScopeResponse; let continuationToken = settings?.continuationToken; @@ -235,7 +235,7 @@ export class DeploymentsImpl implements Deployments { } private async *listAtTenantScopePagingAll( - options?: DeploymentsListAtTenantScopeOptionalParams + options?: DeploymentsListAtTenantScopeOptionalParams, ): AsyncIterableIterator { for await (const page of this.listAtTenantScopePagingPage(options)) { yield* page; @@ -249,7 +249,7 @@ export class DeploymentsImpl implements Deployments { */ public listAtManagementGroupScope( groupId: string, - options?: DeploymentsListAtManagementGroupScopeOptionalParams + options?: DeploymentsListAtManagementGroupScopeOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listAtManagementGroupScopePagingAll(groupId, options); return { @@ -266,16 +266,16 @@ export class DeploymentsImpl implements Deployments { return this.listAtManagementGroupScopePagingPage( groupId, options, - settings + settings, ); - } + }, }; } private async *listAtManagementGroupScopePagingPage( groupId: string, options?: DeploymentsListAtManagementGroupScopeOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: DeploymentsListAtManagementGroupScopeResponse; let continuationToken = settings?.continuationToken; @@ -290,7 +290,7 @@ export class DeploymentsImpl implements Deployments { result = await this._listAtManagementGroupScopeNext( groupId, continuationToken, - options + options, ); continuationToken = result.nextLink; let page = result.value || []; @@ -301,11 +301,11 @@ export class DeploymentsImpl implements Deployments { private async *listAtManagementGroupScopePagingAll( groupId: string, - options?: DeploymentsListAtManagementGroupScopeOptionalParams + options?: DeploymentsListAtManagementGroupScopeOptionalParams, ): AsyncIterableIterator { for await (const page of this.listAtManagementGroupScopePagingPage( groupId, - options + options, )) { yield* page; } @@ -316,7 +316,7 @@ export class DeploymentsImpl implements Deployments { * @param options The options parameters. */ public listAtSubscriptionScope( - options?: DeploymentsListAtSubscriptionScopeOptionalParams + options?: DeploymentsListAtSubscriptionScopeOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listAtSubscriptionScopePagingAll(options); return { @@ -331,13 +331,13 @@ export class DeploymentsImpl implements Deployments { throw new Error("maxPageSize is not supported by this operation."); } return this.listAtSubscriptionScopePagingPage(options, settings); - } + }, }; } private async *listAtSubscriptionScopePagingPage( options?: DeploymentsListAtSubscriptionScopeOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: DeploymentsListAtSubscriptionScopeResponse; let continuationToken = settings?.continuationToken; @@ -351,7 +351,7 @@ export class DeploymentsImpl implements Deployments { while (continuationToken) { result = await this._listAtSubscriptionScopeNext( continuationToken, - options + options, ); continuationToken = result.nextLink; let page = result.value || []; @@ -361,7 +361,7 @@ export class DeploymentsImpl implements Deployments { } private async *listAtSubscriptionScopePagingAll( - options?: DeploymentsListAtSubscriptionScopeOptionalParams + options?: DeploymentsListAtSubscriptionScopeOptionalParams, ): AsyncIterableIterator { for await (const page of this.listAtSubscriptionScopePagingPage(options)) { yield* page; @@ -376,7 +376,7 @@ export class DeploymentsImpl implements Deployments { */ public listByResourceGroup( resourceGroupName: string, - options?: DeploymentsListByResourceGroupOptionalParams + options?: DeploymentsListByResourceGroupOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listByResourceGroupPagingAll(resourceGroupName, options); return { @@ -393,16 +393,16 @@ export class DeploymentsImpl implements Deployments { return this.listByResourceGroupPagingPage( resourceGroupName, options, - settings + settings, ); - } + }, }; } private async *listByResourceGroupPagingPage( resourceGroupName: string, options?: DeploymentsListByResourceGroupOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: DeploymentsListByResourceGroupResponse; let continuationToken = settings?.continuationToken; @@ -417,7 +417,7 @@ export class DeploymentsImpl implements Deployments { result = await this._listByResourceGroupNext( resourceGroupName, continuationToken, - options + options, ); continuationToken = result.nextLink; let page = result.value || []; @@ -428,11 +428,11 @@ export class DeploymentsImpl implements Deployments { private async *listByResourceGroupPagingAll( resourceGroupName: string, - options?: DeploymentsListByResourceGroupOptionalParams + options?: DeploymentsListByResourceGroupOptionalParams, ): AsyncIterableIterator { for await (const page of this.listByResourceGroupPagingPage( resourceGroupName, - options + options, )) { yield* page; } @@ -440,12 +440,15 @@ export class DeploymentsImpl implements Deployments { /** * A template deployment that is currently running cannot be deleted. Deleting a template deployment - * removes the associated deployment operations. This is an asynchronous operation that returns a - * status of 202 until the template deployment is successfully deleted. The Location response header - * contains the URI that is used to obtain the status of the process. While the process is running, a - * call to the URI in the Location header returns a status of 202. When the process finishes, the URI - * in the Location header returns a status of 204 on success. If the asynchronous request failed, the - * URI in the Location header returns an error-level status code. + * removes the associated deployment operations. A deployment delete request may return one of the + * three status codes: 200, 202, 204. Status 200 is returned if the deployment existed and was + * synchronously deleted successfully. Status 204 is returned if the deployment didn't exist. It is an + * asynchronous operation if 202 is returned, the client needs to continue probing until the template + * deployment is successfully deleted. The Location response header contains the URI that is used to + * obtain the status of the process. While the process is running, a call to the URI in the Location + * header returns a status of 202. When the process finishes, the URI in the Location header returns a + * status of 204 on success. If the asynchronous request failed, the URI in the Location header returns + * an error-level status code. * @param scope The resource scope. * @param deploymentName The name of the deployment. * @param options The options parameters. @@ -453,25 +456,24 @@ export class DeploymentsImpl implements Deployments { async beginDeleteAtScope( scope: string, deploymentName: string, - options?: DeploymentsDeleteAtScopeOptionalParams + options?: DeploymentsDeleteAtScopeOptionalParams, ): Promise, void>> { const directSendOperation = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ): Promise => { return this.client.sendOperationRequest(args, spec); }; const sendOperationFn = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; + let currentRawResponse: coreClient.FullOperationResponse | undefined = + undefined; const providedCallback = args.options?.onResponse; const callback: coreClient.RawResponseCallback = ( rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown + flatResponse: unknown, ) => { currentRawResponse = rawResponse; providedCallback?.(rawResponse, flatResponse); @@ -480,8 +482,8 @@ export class DeploymentsImpl implements Deployments { ...args, options: { ...args.options, - onResponse: callback - } + onResponse: callback, + }, }; const flatResponse = await directSendOperation(updatedArgs, spec); return { @@ -489,19 +491,19 @@ export class DeploymentsImpl implements Deployments { rawResponse: { statusCode: currentRawResponse!.status, body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } + headers: currentRawResponse!.headers.toJSON(), + }, }; }; const lro = createLroSpec({ sendOperationFn, args: { scope, deploymentName, options }, - spec: deleteAtScopeOperationSpec + spec: deleteAtScopeOperationSpec, }); const poller = await createHttpPoller>(lro, { restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs + intervalInMs: options?.updateIntervalInMs, }); await poller.poll(); return poller; @@ -509,12 +511,15 @@ export class DeploymentsImpl implements Deployments { /** * A template deployment that is currently running cannot be deleted. Deleting a template deployment - * removes the associated deployment operations. This is an asynchronous operation that returns a - * status of 202 until the template deployment is successfully deleted. The Location response header - * contains the URI that is used to obtain the status of the process. While the process is running, a - * call to the URI in the Location header returns a status of 202. When the process finishes, the URI - * in the Location header returns a status of 204 on success. If the asynchronous request failed, the - * URI in the Location header returns an error-level status code. + * removes the associated deployment operations. A deployment delete request may return one of the + * three status codes: 200, 202, 204. Status 200 is returned if the deployment existed and was + * synchronously deleted successfully. Status 204 is returned if the deployment didn't exist. It is an + * asynchronous operation if 202 is returned, the client needs to continue probing until the template + * deployment is successfully deleted. The Location response header contains the URI that is used to + * obtain the status of the process. While the process is running, a call to the URI in the Location + * header returns a status of 202. When the process finishes, the URI in the Location header returns a + * status of 204 on success. If the asynchronous request failed, the URI in the Location header returns + * an error-level status code. * @param scope The resource scope. * @param deploymentName The name of the deployment. * @param options The options parameters. @@ -522,12 +527,12 @@ export class DeploymentsImpl implements Deployments { async beginDeleteAtScopeAndWait( scope: string, deploymentName: string, - options?: DeploymentsDeleteAtScopeOptionalParams + options?: DeploymentsDeleteAtScopeOptionalParams, ): Promise { const poller = await this.beginDeleteAtScope( scope, deploymentName, - options + options, ); return poller.pollUntilDone(); } @@ -541,11 +546,11 @@ export class DeploymentsImpl implements Deployments { checkExistenceAtScope( scope: string, deploymentName: string, - options?: DeploymentsCheckExistenceAtScopeOptionalParams + options?: DeploymentsCheckExistenceAtScopeOptionalParams, ): Promise { return this.client.sendOperationRequest( { scope, deploymentName, options }, - checkExistenceAtScopeOperationSpec + checkExistenceAtScopeOperationSpec, ); } @@ -560,7 +565,7 @@ export class DeploymentsImpl implements Deployments { scope: string, deploymentName: string, parameters: Deployment, - options?: DeploymentsCreateOrUpdateAtScopeOptionalParams + options?: DeploymentsCreateOrUpdateAtScopeOptionalParams, ): Promise< SimplePollerLike< OperationState, @@ -569,21 +574,20 @@ export class DeploymentsImpl implements Deployments { > { const directSendOperation = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ): Promise => { return this.client.sendOperationRequest(args, spec); }; const sendOperationFn = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; + let currentRawResponse: coreClient.FullOperationResponse | undefined = + undefined; const providedCallback = args.options?.onResponse; const callback: coreClient.RawResponseCallback = ( rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown + flatResponse: unknown, ) => { currentRawResponse = rawResponse; providedCallback?.(rawResponse, flatResponse); @@ -592,8 +596,8 @@ export class DeploymentsImpl implements Deployments { ...args, options: { ...args.options, - onResponse: callback - } + onResponse: callback, + }, }; const flatResponse = await directSendOperation(updatedArgs, spec); return { @@ -601,22 +605,22 @@ export class DeploymentsImpl implements Deployments { rawResponse: { statusCode: currentRawResponse!.status, body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } + headers: currentRawResponse!.headers.toJSON(), + }, }; }; const lro = createLroSpec({ sendOperationFn, args: { scope, deploymentName, parameters, options }, - spec: createOrUpdateAtScopeOperationSpec + spec: createOrUpdateAtScopeOperationSpec, }); const poller = await createHttpPoller< DeploymentsCreateOrUpdateAtScopeResponse, OperationState >(lro, { restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs + intervalInMs: options?.updateIntervalInMs, }); await poller.poll(); return poller; @@ -633,13 +637,13 @@ export class DeploymentsImpl implements Deployments { scope: string, deploymentName: string, parameters: Deployment, - options?: DeploymentsCreateOrUpdateAtScopeOptionalParams + options?: DeploymentsCreateOrUpdateAtScopeOptionalParams, ): Promise { const poller = await this.beginCreateOrUpdateAtScope( scope, deploymentName, parameters, - options + options, ); return poller.pollUntilDone(); } @@ -653,11 +657,11 @@ export class DeploymentsImpl implements Deployments { getAtScope( scope: string, deploymentName: string, - options?: DeploymentsGetAtScopeOptionalParams + options?: DeploymentsGetAtScopeOptionalParams, ): Promise { return this.client.sendOperationRequest( { scope, deploymentName, options }, - getAtScopeOperationSpec + getAtScopeOperationSpec, ); } @@ -672,11 +676,11 @@ export class DeploymentsImpl implements Deployments { cancelAtScope( scope: string, deploymentName: string, - options?: DeploymentsCancelAtScopeOptionalParams + options?: DeploymentsCancelAtScopeOptionalParams, ): Promise { return this.client.sendOperationRequest( { scope, deploymentName, options }, - cancelAtScopeOperationSpec + cancelAtScopeOperationSpec, ); } @@ -692,7 +696,7 @@ export class DeploymentsImpl implements Deployments { scope: string, deploymentName: string, parameters: Deployment, - options?: DeploymentsValidateAtScopeOptionalParams + options?: DeploymentsValidateAtScopeOptionalParams, ): Promise< SimplePollerLike< OperationState, @@ -701,21 +705,20 @@ export class DeploymentsImpl implements Deployments { > { const directSendOperation = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ): Promise => { return this.client.sendOperationRequest(args, spec); }; const sendOperationFn = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; + let currentRawResponse: coreClient.FullOperationResponse | undefined = + undefined; const providedCallback = args.options?.onResponse; const callback: coreClient.RawResponseCallback = ( rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown + flatResponse: unknown, ) => { currentRawResponse = rawResponse; providedCallback?.(rawResponse, flatResponse); @@ -724,8 +727,8 @@ export class DeploymentsImpl implements Deployments { ...args, options: { ...args.options, - onResponse: callback - } + onResponse: callback, + }, }; const flatResponse = await directSendOperation(updatedArgs, spec); return { @@ -733,22 +736,22 @@ export class DeploymentsImpl implements Deployments { rawResponse: { statusCode: currentRawResponse!.status, body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } + headers: currentRawResponse!.headers.toJSON(), + }, }; }; const lro = createLroSpec({ sendOperationFn, args: { scope, deploymentName, parameters, options }, - spec: validateAtScopeOperationSpec + spec: validateAtScopeOperationSpec, }); const poller = await createHttpPoller< DeploymentsValidateAtScopeResponse, OperationState >(lro, { restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs + intervalInMs: options?.updateIntervalInMs, }); await poller.poll(); return poller; @@ -766,13 +769,13 @@ export class DeploymentsImpl implements Deployments { scope: string, deploymentName: string, parameters: Deployment, - options?: DeploymentsValidateAtScopeOptionalParams + options?: DeploymentsValidateAtScopeOptionalParams, ): Promise { const poller = await this.beginValidateAtScope( scope, deploymentName, parameters, - options + options, ); return poller.pollUntilDone(); } @@ -786,11 +789,11 @@ export class DeploymentsImpl implements Deployments { exportTemplateAtScope( scope: string, deploymentName: string, - options?: DeploymentsExportTemplateAtScopeOptionalParams + options?: DeploymentsExportTemplateAtScopeOptionalParams, ): Promise { return this.client.sendOperationRequest( { scope, deploymentName, options }, - exportTemplateAtScopeOperationSpec + exportTemplateAtScopeOperationSpec, ); } @@ -801,11 +804,11 @@ export class DeploymentsImpl implements Deployments { */ private _listAtScope( scope: string, - options?: DeploymentsListAtScopeOptionalParams + options?: DeploymentsListAtScopeOptionalParams, ): Promise { return this.client.sendOperationRequest( { scope, options }, - listAtScopeOperationSpec + listAtScopeOperationSpec, ); } @@ -822,25 +825,24 @@ export class DeploymentsImpl implements Deployments { */ async beginDeleteAtTenantScope( deploymentName: string, - options?: DeploymentsDeleteAtTenantScopeOptionalParams + options?: DeploymentsDeleteAtTenantScopeOptionalParams, ): Promise, void>> { const directSendOperation = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ): Promise => { return this.client.sendOperationRequest(args, spec); }; const sendOperationFn = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; + let currentRawResponse: coreClient.FullOperationResponse | undefined = + undefined; const providedCallback = args.options?.onResponse; const callback: coreClient.RawResponseCallback = ( rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown + flatResponse: unknown, ) => { currentRawResponse = rawResponse; providedCallback?.(rawResponse, flatResponse); @@ -849,8 +851,8 @@ export class DeploymentsImpl implements Deployments { ...args, options: { ...args.options, - onResponse: callback - } + onResponse: callback, + }, }; const flatResponse = await directSendOperation(updatedArgs, spec); return { @@ -858,19 +860,19 @@ export class DeploymentsImpl implements Deployments { rawResponse: { statusCode: currentRawResponse!.status, body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } + headers: currentRawResponse!.headers.toJSON(), + }, }; }; const lro = createLroSpec({ sendOperationFn, args: { deploymentName, options }, - spec: deleteAtTenantScopeOperationSpec + spec: deleteAtTenantScopeOperationSpec, }); const poller = await createHttpPoller>(lro, { restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs + intervalInMs: options?.updateIntervalInMs, }); await poller.poll(); return poller; @@ -889,7 +891,7 @@ export class DeploymentsImpl implements Deployments { */ async beginDeleteAtTenantScopeAndWait( deploymentName: string, - options?: DeploymentsDeleteAtTenantScopeOptionalParams + options?: DeploymentsDeleteAtTenantScopeOptionalParams, ): Promise { const poller = await this.beginDeleteAtTenantScope(deploymentName, options); return poller.pollUntilDone(); @@ -902,11 +904,11 @@ export class DeploymentsImpl implements Deployments { */ checkExistenceAtTenantScope( deploymentName: string, - options?: DeploymentsCheckExistenceAtTenantScopeOptionalParams + options?: DeploymentsCheckExistenceAtTenantScopeOptionalParams, ): Promise { return this.client.sendOperationRequest( { deploymentName, options }, - checkExistenceAtTenantScopeOperationSpec + checkExistenceAtTenantScopeOperationSpec, ); } @@ -919,7 +921,7 @@ export class DeploymentsImpl implements Deployments { async beginCreateOrUpdateAtTenantScope( deploymentName: string, parameters: ScopedDeployment, - options?: DeploymentsCreateOrUpdateAtTenantScopeOptionalParams + options?: DeploymentsCreateOrUpdateAtTenantScopeOptionalParams, ): Promise< SimplePollerLike< OperationState, @@ -928,21 +930,20 @@ export class DeploymentsImpl implements Deployments { > { const directSendOperation = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ): Promise => { return this.client.sendOperationRequest(args, spec); }; const sendOperationFn = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; + let currentRawResponse: coreClient.FullOperationResponse | undefined = + undefined; const providedCallback = args.options?.onResponse; const callback: coreClient.RawResponseCallback = ( rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown + flatResponse: unknown, ) => { currentRawResponse = rawResponse; providedCallback?.(rawResponse, flatResponse); @@ -951,8 +952,8 @@ export class DeploymentsImpl implements Deployments { ...args, options: { ...args.options, - onResponse: callback - } + onResponse: callback, + }, }; const flatResponse = await directSendOperation(updatedArgs, spec); return { @@ -960,22 +961,22 @@ export class DeploymentsImpl implements Deployments { rawResponse: { statusCode: currentRawResponse!.status, body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } + headers: currentRawResponse!.headers.toJSON(), + }, }; }; const lro = createLroSpec({ sendOperationFn, args: { deploymentName, parameters, options }, - spec: createOrUpdateAtTenantScopeOperationSpec + spec: createOrUpdateAtTenantScopeOperationSpec, }); const poller = await createHttpPoller< DeploymentsCreateOrUpdateAtTenantScopeResponse, OperationState >(lro, { restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs + intervalInMs: options?.updateIntervalInMs, }); await poller.poll(); return poller; @@ -990,12 +991,12 @@ export class DeploymentsImpl implements Deployments { async beginCreateOrUpdateAtTenantScopeAndWait( deploymentName: string, parameters: ScopedDeployment, - options?: DeploymentsCreateOrUpdateAtTenantScopeOptionalParams + options?: DeploymentsCreateOrUpdateAtTenantScopeOptionalParams, ): Promise { const poller = await this.beginCreateOrUpdateAtTenantScope( deploymentName, parameters, - options + options, ); return poller.pollUntilDone(); } @@ -1007,11 +1008,11 @@ export class DeploymentsImpl implements Deployments { */ getAtTenantScope( deploymentName: string, - options?: DeploymentsGetAtTenantScopeOptionalParams + options?: DeploymentsGetAtTenantScopeOptionalParams, ): Promise { return this.client.sendOperationRequest( { deploymentName, options }, - getAtTenantScopeOperationSpec + getAtTenantScopeOperationSpec, ); } @@ -1024,11 +1025,11 @@ export class DeploymentsImpl implements Deployments { */ cancelAtTenantScope( deploymentName: string, - options?: DeploymentsCancelAtTenantScopeOptionalParams + options?: DeploymentsCancelAtTenantScopeOptionalParams, ): Promise { return this.client.sendOperationRequest( { deploymentName, options }, - cancelAtTenantScopeOperationSpec + cancelAtTenantScopeOperationSpec, ); } @@ -1042,7 +1043,7 @@ export class DeploymentsImpl implements Deployments { async beginValidateAtTenantScope( deploymentName: string, parameters: ScopedDeployment, - options?: DeploymentsValidateAtTenantScopeOptionalParams + options?: DeploymentsValidateAtTenantScopeOptionalParams, ): Promise< SimplePollerLike< OperationState, @@ -1051,21 +1052,20 @@ export class DeploymentsImpl implements Deployments { > { const directSendOperation = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ): Promise => { return this.client.sendOperationRequest(args, spec); }; const sendOperationFn = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; + let currentRawResponse: coreClient.FullOperationResponse | undefined = + undefined; const providedCallback = args.options?.onResponse; const callback: coreClient.RawResponseCallback = ( rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown + flatResponse: unknown, ) => { currentRawResponse = rawResponse; providedCallback?.(rawResponse, flatResponse); @@ -1074,8 +1074,8 @@ export class DeploymentsImpl implements Deployments { ...args, options: { ...args.options, - onResponse: callback - } + onResponse: callback, + }, }; const flatResponse = await directSendOperation(updatedArgs, spec); return { @@ -1083,22 +1083,22 @@ export class DeploymentsImpl implements Deployments { rawResponse: { statusCode: currentRawResponse!.status, body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } + headers: currentRawResponse!.headers.toJSON(), + }, }; }; const lro = createLroSpec({ sendOperationFn, args: { deploymentName, parameters, options }, - spec: validateAtTenantScopeOperationSpec + spec: validateAtTenantScopeOperationSpec, }); const poller = await createHttpPoller< DeploymentsValidateAtTenantScopeResponse, OperationState >(lro, { restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs + intervalInMs: options?.updateIntervalInMs, }); await poller.poll(); return poller; @@ -1114,12 +1114,12 @@ export class DeploymentsImpl implements Deployments { async beginValidateAtTenantScopeAndWait( deploymentName: string, parameters: ScopedDeployment, - options?: DeploymentsValidateAtTenantScopeOptionalParams + options?: DeploymentsValidateAtTenantScopeOptionalParams, ): Promise { const poller = await this.beginValidateAtTenantScope( deploymentName, parameters, - options + options, ); return poller.pollUntilDone(); } @@ -1133,7 +1133,7 @@ export class DeploymentsImpl implements Deployments { async beginWhatIfAtTenantScope( deploymentName: string, parameters: ScopedDeploymentWhatIf, - options?: DeploymentsWhatIfAtTenantScopeOptionalParams + options?: DeploymentsWhatIfAtTenantScopeOptionalParams, ): Promise< SimplePollerLike< OperationState, @@ -1142,21 +1142,20 @@ export class DeploymentsImpl implements Deployments { > { const directSendOperation = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ): Promise => { return this.client.sendOperationRequest(args, spec); }; const sendOperationFn = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; + let currentRawResponse: coreClient.FullOperationResponse | undefined = + undefined; const providedCallback = args.options?.onResponse; const callback: coreClient.RawResponseCallback = ( rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown + flatResponse: unknown, ) => { currentRawResponse = rawResponse; providedCallback?.(rawResponse, flatResponse); @@ -1165,8 +1164,8 @@ export class DeploymentsImpl implements Deployments { ...args, options: { ...args.options, - onResponse: callback - } + onResponse: callback, + }, }; const flatResponse = await directSendOperation(updatedArgs, spec); return { @@ -1174,15 +1173,15 @@ export class DeploymentsImpl implements Deployments { rawResponse: { statusCode: currentRawResponse!.status, body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } + headers: currentRawResponse!.headers.toJSON(), + }, }; }; const lro = createLroSpec({ sendOperationFn, args: { deploymentName, parameters, options }, - spec: whatIfAtTenantScopeOperationSpec + spec: whatIfAtTenantScopeOperationSpec, }); const poller = await createHttpPoller< DeploymentsWhatIfAtTenantScopeResponse, @@ -1190,7 +1189,7 @@ export class DeploymentsImpl implements Deployments { >(lro, { restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs, - resourceLocationConfig: "location" + resourceLocationConfig: "location", }); await poller.poll(); return poller; @@ -1205,12 +1204,12 @@ export class DeploymentsImpl implements Deployments { async beginWhatIfAtTenantScopeAndWait( deploymentName: string, parameters: ScopedDeploymentWhatIf, - options?: DeploymentsWhatIfAtTenantScopeOptionalParams + options?: DeploymentsWhatIfAtTenantScopeOptionalParams, ): Promise { const poller = await this.beginWhatIfAtTenantScope( deploymentName, parameters, - options + options, ); return poller.pollUntilDone(); } @@ -1222,11 +1221,11 @@ export class DeploymentsImpl implements Deployments { */ exportTemplateAtTenantScope( deploymentName: string, - options?: DeploymentsExportTemplateAtTenantScopeOptionalParams + options?: DeploymentsExportTemplateAtTenantScopeOptionalParams, ): Promise { return this.client.sendOperationRequest( { deploymentName, options }, - exportTemplateAtTenantScopeOperationSpec + exportTemplateAtTenantScopeOperationSpec, ); } @@ -1235,11 +1234,11 @@ export class DeploymentsImpl implements Deployments { * @param options The options parameters. */ private _listAtTenantScope( - options?: DeploymentsListAtTenantScopeOptionalParams + options?: DeploymentsListAtTenantScopeOptionalParams, ): Promise { return this.client.sendOperationRequest( { options }, - listAtTenantScopeOperationSpec + listAtTenantScopeOperationSpec, ); } @@ -1258,25 +1257,24 @@ export class DeploymentsImpl implements Deployments { async beginDeleteAtManagementGroupScope( groupId: string, deploymentName: string, - options?: DeploymentsDeleteAtManagementGroupScopeOptionalParams + options?: DeploymentsDeleteAtManagementGroupScopeOptionalParams, ): Promise, void>> { const directSendOperation = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ): Promise => { return this.client.sendOperationRequest(args, spec); }; const sendOperationFn = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; + let currentRawResponse: coreClient.FullOperationResponse | undefined = + undefined; const providedCallback = args.options?.onResponse; const callback: coreClient.RawResponseCallback = ( rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown + flatResponse: unknown, ) => { currentRawResponse = rawResponse; providedCallback?.(rawResponse, flatResponse); @@ -1285,8 +1283,8 @@ export class DeploymentsImpl implements Deployments { ...args, options: { ...args.options, - onResponse: callback - } + onResponse: callback, + }, }; const flatResponse = await directSendOperation(updatedArgs, spec); return { @@ -1294,19 +1292,19 @@ export class DeploymentsImpl implements Deployments { rawResponse: { statusCode: currentRawResponse!.status, body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } + headers: currentRawResponse!.headers.toJSON(), + }, }; }; const lro = createLroSpec({ sendOperationFn, args: { groupId, deploymentName, options }, - spec: deleteAtManagementGroupScopeOperationSpec + spec: deleteAtManagementGroupScopeOperationSpec, }); const poller = await createHttpPoller>(lro, { restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs + intervalInMs: options?.updateIntervalInMs, }); await poller.poll(); return poller; @@ -1327,12 +1325,12 @@ export class DeploymentsImpl implements Deployments { async beginDeleteAtManagementGroupScopeAndWait( groupId: string, deploymentName: string, - options?: DeploymentsDeleteAtManagementGroupScopeOptionalParams + options?: DeploymentsDeleteAtManagementGroupScopeOptionalParams, ): Promise { const poller = await this.beginDeleteAtManagementGroupScope( groupId, deploymentName, - options + options, ); return poller.pollUntilDone(); } @@ -1346,11 +1344,11 @@ export class DeploymentsImpl implements Deployments { checkExistenceAtManagementGroupScope( groupId: string, deploymentName: string, - options?: DeploymentsCheckExistenceAtManagementGroupScopeOptionalParams + options?: DeploymentsCheckExistenceAtManagementGroupScopeOptionalParams, ): Promise { return this.client.sendOperationRequest( { groupId, deploymentName, options }, - checkExistenceAtManagementGroupScopeOperationSpec + checkExistenceAtManagementGroupScopeOperationSpec, ); } @@ -1365,7 +1363,7 @@ export class DeploymentsImpl implements Deployments { groupId: string, deploymentName: string, parameters: ScopedDeployment, - options?: DeploymentsCreateOrUpdateAtManagementGroupScopeOptionalParams + options?: DeploymentsCreateOrUpdateAtManagementGroupScopeOptionalParams, ): Promise< SimplePollerLike< OperationState, @@ -1374,21 +1372,20 @@ export class DeploymentsImpl implements Deployments { > { const directSendOperation = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ): Promise => { return this.client.sendOperationRequest(args, spec); }; const sendOperationFn = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; + let currentRawResponse: coreClient.FullOperationResponse | undefined = + undefined; const providedCallback = args.options?.onResponse; const callback: coreClient.RawResponseCallback = ( rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown + flatResponse: unknown, ) => { currentRawResponse = rawResponse; providedCallback?.(rawResponse, flatResponse); @@ -1397,8 +1394,8 @@ export class DeploymentsImpl implements Deployments { ...args, options: { ...args.options, - onResponse: callback - } + onResponse: callback, + }, }; const flatResponse = await directSendOperation(updatedArgs, spec); return { @@ -1406,22 +1403,22 @@ export class DeploymentsImpl implements Deployments { rawResponse: { statusCode: currentRawResponse!.status, body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } + headers: currentRawResponse!.headers.toJSON(), + }, }; }; const lro = createLroSpec({ sendOperationFn, args: { groupId, deploymentName, parameters, options }, - spec: createOrUpdateAtManagementGroupScopeOperationSpec + spec: createOrUpdateAtManagementGroupScopeOperationSpec, }); const poller = await createHttpPoller< DeploymentsCreateOrUpdateAtManagementGroupScopeResponse, OperationState >(lro, { restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs + intervalInMs: options?.updateIntervalInMs, }); await poller.poll(); return poller; @@ -1438,13 +1435,13 @@ export class DeploymentsImpl implements Deployments { groupId: string, deploymentName: string, parameters: ScopedDeployment, - options?: DeploymentsCreateOrUpdateAtManagementGroupScopeOptionalParams + options?: DeploymentsCreateOrUpdateAtManagementGroupScopeOptionalParams, ): Promise { const poller = await this.beginCreateOrUpdateAtManagementGroupScope( groupId, deploymentName, parameters, - options + options, ); return poller.pollUntilDone(); } @@ -1458,11 +1455,11 @@ export class DeploymentsImpl implements Deployments { getAtManagementGroupScope( groupId: string, deploymentName: string, - options?: DeploymentsGetAtManagementGroupScopeOptionalParams + options?: DeploymentsGetAtManagementGroupScopeOptionalParams, ): Promise { return this.client.sendOperationRequest( { groupId, deploymentName, options }, - getAtManagementGroupScopeOperationSpec + getAtManagementGroupScopeOperationSpec, ); } @@ -1477,11 +1474,11 @@ export class DeploymentsImpl implements Deployments { cancelAtManagementGroupScope( groupId: string, deploymentName: string, - options?: DeploymentsCancelAtManagementGroupScopeOptionalParams + options?: DeploymentsCancelAtManagementGroupScopeOptionalParams, ): Promise { return this.client.sendOperationRequest( { groupId, deploymentName, options }, - cancelAtManagementGroupScopeOperationSpec + cancelAtManagementGroupScopeOperationSpec, ); } @@ -1497,7 +1494,7 @@ export class DeploymentsImpl implements Deployments { groupId: string, deploymentName: string, parameters: ScopedDeployment, - options?: DeploymentsValidateAtManagementGroupScopeOptionalParams + options?: DeploymentsValidateAtManagementGroupScopeOptionalParams, ): Promise< SimplePollerLike< OperationState, @@ -1506,21 +1503,20 @@ export class DeploymentsImpl implements Deployments { > { const directSendOperation = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ): Promise => { return this.client.sendOperationRequest(args, spec); }; const sendOperationFn = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; + let currentRawResponse: coreClient.FullOperationResponse | undefined = + undefined; const providedCallback = args.options?.onResponse; const callback: coreClient.RawResponseCallback = ( rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown + flatResponse: unknown, ) => { currentRawResponse = rawResponse; providedCallback?.(rawResponse, flatResponse); @@ -1529,8 +1525,8 @@ export class DeploymentsImpl implements Deployments { ...args, options: { ...args.options, - onResponse: callback - } + onResponse: callback, + }, }; const flatResponse = await directSendOperation(updatedArgs, spec); return { @@ -1538,22 +1534,22 @@ export class DeploymentsImpl implements Deployments { rawResponse: { statusCode: currentRawResponse!.status, body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } + headers: currentRawResponse!.headers.toJSON(), + }, }; }; const lro = createLroSpec({ sendOperationFn, args: { groupId, deploymentName, parameters, options }, - spec: validateAtManagementGroupScopeOperationSpec + spec: validateAtManagementGroupScopeOperationSpec, }); const poller = await createHttpPoller< DeploymentsValidateAtManagementGroupScopeResponse, OperationState >(lro, { restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs + intervalInMs: options?.updateIntervalInMs, }); await poller.poll(); return poller; @@ -1571,13 +1567,13 @@ export class DeploymentsImpl implements Deployments { groupId: string, deploymentName: string, parameters: ScopedDeployment, - options?: DeploymentsValidateAtManagementGroupScopeOptionalParams + options?: DeploymentsValidateAtManagementGroupScopeOptionalParams, ): Promise { const poller = await this.beginValidateAtManagementGroupScope( groupId, deploymentName, parameters, - options + options, ); return poller.pollUntilDone(); } @@ -1594,7 +1590,7 @@ export class DeploymentsImpl implements Deployments { groupId: string, deploymentName: string, parameters: ScopedDeploymentWhatIf, - options?: DeploymentsWhatIfAtManagementGroupScopeOptionalParams + options?: DeploymentsWhatIfAtManagementGroupScopeOptionalParams, ): Promise< SimplePollerLike< OperationState, @@ -1603,21 +1599,20 @@ export class DeploymentsImpl implements Deployments { > { const directSendOperation = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ): Promise => { return this.client.sendOperationRequest(args, spec); }; const sendOperationFn = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; + let currentRawResponse: coreClient.FullOperationResponse | undefined = + undefined; const providedCallback = args.options?.onResponse; const callback: coreClient.RawResponseCallback = ( rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown + flatResponse: unknown, ) => { currentRawResponse = rawResponse; providedCallback?.(rawResponse, flatResponse); @@ -1626,8 +1621,8 @@ export class DeploymentsImpl implements Deployments { ...args, options: { ...args.options, - onResponse: callback - } + onResponse: callback, + }, }; const flatResponse = await directSendOperation(updatedArgs, spec); return { @@ -1635,15 +1630,15 @@ export class DeploymentsImpl implements Deployments { rawResponse: { statusCode: currentRawResponse!.status, body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } + headers: currentRawResponse!.headers.toJSON(), + }, }; }; const lro = createLroSpec({ sendOperationFn, args: { groupId, deploymentName, parameters, options }, - spec: whatIfAtManagementGroupScopeOperationSpec + spec: whatIfAtManagementGroupScopeOperationSpec, }); const poller = await createHttpPoller< DeploymentsWhatIfAtManagementGroupScopeResponse, @@ -1651,7 +1646,7 @@ export class DeploymentsImpl implements Deployments { >(lro, { restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs, - resourceLocationConfig: "location" + resourceLocationConfig: "location", }); await poller.poll(); return poller; @@ -1669,13 +1664,13 @@ export class DeploymentsImpl implements Deployments { groupId: string, deploymentName: string, parameters: ScopedDeploymentWhatIf, - options?: DeploymentsWhatIfAtManagementGroupScopeOptionalParams + options?: DeploymentsWhatIfAtManagementGroupScopeOptionalParams, ): Promise { const poller = await this.beginWhatIfAtManagementGroupScope( groupId, deploymentName, parameters, - options + options, ); return poller.pollUntilDone(); } @@ -1689,11 +1684,11 @@ export class DeploymentsImpl implements Deployments { exportTemplateAtManagementGroupScope( groupId: string, deploymentName: string, - options?: DeploymentsExportTemplateAtManagementGroupScopeOptionalParams + options?: DeploymentsExportTemplateAtManagementGroupScopeOptionalParams, ): Promise { return this.client.sendOperationRequest( { groupId, deploymentName, options }, - exportTemplateAtManagementGroupScopeOperationSpec + exportTemplateAtManagementGroupScopeOperationSpec, ); } @@ -1704,11 +1699,11 @@ export class DeploymentsImpl implements Deployments { */ private _listAtManagementGroupScope( groupId: string, - options?: DeploymentsListAtManagementGroupScopeOptionalParams + options?: DeploymentsListAtManagementGroupScopeOptionalParams, ): Promise { return this.client.sendOperationRequest( { groupId, options }, - listAtManagementGroupScopeOperationSpec + listAtManagementGroupScopeOperationSpec, ); } @@ -1725,25 +1720,24 @@ export class DeploymentsImpl implements Deployments { */ async beginDeleteAtSubscriptionScope( deploymentName: string, - options?: DeploymentsDeleteAtSubscriptionScopeOptionalParams + options?: DeploymentsDeleteAtSubscriptionScopeOptionalParams, ): Promise, void>> { const directSendOperation = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ): Promise => { return this.client.sendOperationRequest(args, spec); }; const sendOperationFn = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; + let currentRawResponse: coreClient.FullOperationResponse | undefined = + undefined; const providedCallback = args.options?.onResponse; const callback: coreClient.RawResponseCallback = ( rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown + flatResponse: unknown, ) => { currentRawResponse = rawResponse; providedCallback?.(rawResponse, flatResponse); @@ -1752,8 +1746,8 @@ export class DeploymentsImpl implements Deployments { ...args, options: { ...args.options, - onResponse: callback - } + onResponse: callback, + }, }; const flatResponse = await directSendOperation(updatedArgs, spec); return { @@ -1761,19 +1755,19 @@ export class DeploymentsImpl implements Deployments { rawResponse: { statusCode: currentRawResponse!.status, body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } + headers: currentRawResponse!.headers.toJSON(), + }, }; }; const lro = createLroSpec({ sendOperationFn, args: { deploymentName, options }, - spec: deleteAtSubscriptionScopeOperationSpec + spec: deleteAtSubscriptionScopeOperationSpec, }); const poller = await createHttpPoller>(lro, { restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs + intervalInMs: options?.updateIntervalInMs, }); await poller.poll(); return poller; @@ -1792,11 +1786,11 @@ export class DeploymentsImpl implements Deployments { */ async beginDeleteAtSubscriptionScopeAndWait( deploymentName: string, - options?: DeploymentsDeleteAtSubscriptionScopeOptionalParams + options?: DeploymentsDeleteAtSubscriptionScopeOptionalParams, ): Promise { const poller = await this.beginDeleteAtSubscriptionScope( deploymentName, - options + options, ); return poller.pollUntilDone(); } @@ -1808,11 +1802,11 @@ export class DeploymentsImpl implements Deployments { */ checkExistenceAtSubscriptionScope( deploymentName: string, - options?: DeploymentsCheckExistenceAtSubscriptionScopeOptionalParams + options?: DeploymentsCheckExistenceAtSubscriptionScopeOptionalParams, ): Promise { return this.client.sendOperationRequest( { deploymentName, options }, - checkExistenceAtSubscriptionScopeOperationSpec + checkExistenceAtSubscriptionScopeOperationSpec, ); } @@ -1825,7 +1819,7 @@ export class DeploymentsImpl implements Deployments { async beginCreateOrUpdateAtSubscriptionScope( deploymentName: string, parameters: Deployment, - options?: DeploymentsCreateOrUpdateAtSubscriptionScopeOptionalParams + options?: DeploymentsCreateOrUpdateAtSubscriptionScopeOptionalParams, ): Promise< SimplePollerLike< OperationState, @@ -1834,21 +1828,20 @@ export class DeploymentsImpl implements Deployments { > { const directSendOperation = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ): Promise => { return this.client.sendOperationRequest(args, spec); }; const sendOperationFn = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; + let currentRawResponse: coreClient.FullOperationResponse | undefined = + undefined; const providedCallback = args.options?.onResponse; const callback: coreClient.RawResponseCallback = ( rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown + flatResponse: unknown, ) => { currentRawResponse = rawResponse; providedCallback?.(rawResponse, flatResponse); @@ -1857,8 +1850,8 @@ export class DeploymentsImpl implements Deployments { ...args, options: { ...args.options, - onResponse: callback - } + onResponse: callback, + }, }; const flatResponse = await directSendOperation(updatedArgs, spec); return { @@ -1866,22 +1859,22 @@ export class DeploymentsImpl implements Deployments { rawResponse: { statusCode: currentRawResponse!.status, body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } + headers: currentRawResponse!.headers.toJSON(), + }, }; }; const lro = createLroSpec({ sendOperationFn, args: { deploymentName, parameters, options }, - spec: createOrUpdateAtSubscriptionScopeOperationSpec + spec: createOrUpdateAtSubscriptionScopeOperationSpec, }); const poller = await createHttpPoller< DeploymentsCreateOrUpdateAtSubscriptionScopeResponse, OperationState >(lro, { restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs + intervalInMs: options?.updateIntervalInMs, }); await poller.poll(); return poller; @@ -1896,12 +1889,12 @@ export class DeploymentsImpl implements Deployments { async beginCreateOrUpdateAtSubscriptionScopeAndWait( deploymentName: string, parameters: Deployment, - options?: DeploymentsCreateOrUpdateAtSubscriptionScopeOptionalParams + options?: DeploymentsCreateOrUpdateAtSubscriptionScopeOptionalParams, ): Promise { const poller = await this.beginCreateOrUpdateAtSubscriptionScope( deploymentName, parameters, - options + options, ); return poller.pollUntilDone(); } @@ -1913,11 +1906,11 @@ export class DeploymentsImpl implements Deployments { */ getAtSubscriptionScope( deploymentName: string, - options?: DeploymentsGetAtSubscriptionScopeOptionalParams + options?: DeploymentsGetAtSubscriptionScopeOptionalParams, ): Promise { return this.client.sendOperationRequest( { deploymentName, options }, - getAtSubscriptionScopeOperationSpec + getAtSubscriptionScopeOperationSpec, ); } @@ -1930,11 +1923,11 @@ export class DeploymentsImpl implements Deployments { */ cancelAtSubscriptionScope( deploymentName: string, - options?: DeploymentsCancelAtSubscriptionScopeOptionalParams + options?: DeploymentsCancelAtSubscriptionScopeOptionalParams, ): Promise { return this.client.sendOperationRequest( { deploymentName, options }, - cancelAtSubscriptionScopeOperationSpec + cancelAtSubscriptionScopeOperationSpec, ); } @@ -1948,7 +1941,7 @@ export class DeploymentsImpl implements Deployments { async beginValidateAtSubscriptionScope( deploymentName: string, parameters: Deployment, - options?: DeploymentsValidateAtSubscriptionScopeOptionalParams + options?: DeploymentsValidateAtSubscriptionScopeOptionalParams, ): Promise< SimplePollerLike< OperationState, @@ -1957,21 +1950,20 @@ export class DeploymentsImpl implements Deployments { > { const directSendOperation = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ): Promise => { return this.client.sendOperationRequest(args, spec); }; const sendOperationFn = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; + let currentRawResponse: coreClient.FullOperationResponse | undefined = + undefined; const providedCallback = args.options?.onResponse; const callback: coreClient.RawResponseCallback = ( rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown + flatResponse: unknown, ) => { currentRawResponse = rawResponse; providedCallback?.(rawResponse, flatResponse); @@ -1980,8 +1972,8 @@ export class DeploymentsImpl implements Deployments { ...args, options: { ...args.options, - onResponse: callback - } + onResponse: callback, + }, }; const flatResponse = await directSendOperation(updatedArgs, spec); return { @@ -1989,22 +1981,22 @@ export class DeploymentsImpl implements Deployments { rawResponse: { statusCode: currentRawResponse!.status, body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } + headers: currentRawResponse!.headers.toJSON(), + }, }; }; const lro = createLroSpec({ sendOperationFn, args: { deploymentName, parameters, options }, - spec: validateAtSubscriptionScopeOperationSpec + spec: validateAtSubscriptionScopeOperationSpec, }); const poller = await createHttpPoller< DeploymentsValidateAtSubscriptionScopeResponse, OperationState >(lro, { restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs + intervalInMs: options?.updateIntervalInMs, }); await poller.poll(); return poller; @@ -2020,12 +2012,12 @@ export class DeploymentsImpl implements Deployments { async beginValidateAtSubscriptionScopeAndWait( deploymentName: string, parameters: Deployment, - options?: DeploymentsValidateAtSubscriptionScopeOptionalParams + options?: DeploymentsValidateAtSubscriptionScopeOptionalParams, ): Promise { const poller = await this.beginValidateAtSubscriptionScope( deploymentName, parameters, - options + options, ); return poller.pollUntilDone(); } @@ -2039,7 +2031,7 @@ export class DeploymentsImpl implements Deployments { async beginWhatIfAtSubscriptionScope( deploymentName: string, parameters: DeploymentWhatIf, - options?: DeploymentsWhatIfAtSubscriptionScopeOptionalParams + options?: DeploymentsWhatIfAtSubscriptionScopeOptionalParams, ): Promise< SimplePollerLike< OperationState, @@ -2048,21 +2040,20 @@ export class DeploymentsImpl implements Deployments { > { const directSendOperation = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ): Promise => { return this.client.sendOperationRequest(args, spec); }; const sendOperationFn = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; + let currentRawResponse: coreClient.FullOperationResponse | undefined = + undefined; const providedCallback = args.options?.onResponse; const callback: coreClient.RawResponseCallback = ( rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown + flatResponse: unknown, ) => { currentRawResponse = rawResponse; providedCallback?.(rawResponse, flatResponse); @@ -2071,8 +2062,8 @@ export class DeploymentsImpl implements Deployments { ...args, options: { ...args.options, - onResponse: callback - } + onResponse: callback, + }, }; const flatResponse = await directSendOperation(updatedArgs, spec); return { @@ -2080,15 +2071,15 @@ export class DeploymentsImpl implements Deployments { rawResponse: { statusCode: currentRawResponse!.status, body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } + headers: currentRawResponse!.headers.toJSON(), + }, }; }; const lro = createLroSpec({ sendOperationFn, args: { deploymentName, parameters, options }, - spec: whatIfAtSubscriptionScopeOperationSpec + spec: whatIfAtSubscriptionScopeOperationSpec, }); const poller = await createHttpPoller< DeploymentsWhatIfAtSubscriptionScopeResponse, @@ -2096,7 +2087,7 @@ export class DeploymentsImpl implements Deployments { >(lro, { restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs, - resourceLocationConfig: "location" + resourceLocationConfig: "location", }); await poller.poll(); return poller; @@ -2111,12 +2102,12 @@ export class DeploymentsImpl implements Deployments { async beginWhatIfAtSubscriptionScopeAndWait( deploymentName: string, parameters: DeploymentWhatIf, - options?: DeploymentsWhatIfAtSubscriptionScopeOptionalParams + options?: DeploymentsWhatIfAtSubscriptionScopeOptionalParams, ): Promise { const poller = await this.beginWhatIfAtSubscriptionScope( deploymentName, parameters, - options + options, ); return poller.pollUntilDone(); } @@ -2128,11 +2119,11 @@ export class DeploymentsImpl implements Deployments { */ exportTemplateAtSubscriptionScope( deploymentName: string, - options?: DeploymentsExportTemplateAtSubscriptionScopeOptionalParams + options?: DeploymentsExportTemplateAtSubscriptionScopeOptionalParams, ): Promise { return this.client.sendOperationRequest( { deploymentName, options }, - exportTemplateAtSubscriptionScopeOperationSpec + exportTemplateAtSubscriptionScopeOperationSpec, ); } @@ -2141,11 +2132,11 @@ export class DeploymentsImpl implements Deployments { * @param options The options parameters. */ private _listAtSubscriptionScope( - options?: DeploymentsListAtSubscriptionScopeOptionalParams + options?: DeploymentsListAtSubscriptionScopeOptionalParams, ): Promise { return this.client.sendOperationRequest( { options }, - listAtSubscriptionScopeOperationSpec + listAtSubscriptionScopeOperationSpec, ); } @@ -2166,25 +2157,24 @@ export class DeploymentsImpl implements Deployments { async beginDelete( resourceGroupName: string, deploymentName: string, - options?: DeploymentsDeleteOptionalParams + options?: DeploymentsDeleteOptionalParams, ): Promise, void>> { const directSendOperation = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ): Promise => { return this.client.sendOperationRequest(args, spec); }; const sendOperationFn = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; + let currentRawResponse: coreClient.FullOperationResponse | undefined = + undefined; const providedCallback = args.options?.onResponse; const callback: coreClient.RawResponseCallback = ( rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown + flatResponse: unknown, ) => { currentRawResponse = rawResponse; providedCallback?.(rawResponse, flatResponse); @@ -2193,8 +2183,8 @@ export class DeploymentsImpl implements Deployments { ...args, options: { ...args.options, - onResponse: callback - } + onResponse: callback, + }, }; const flatResponse = await directSendOperation(updatedArgs, spec); return { @@ -2202,19 +2192,19 @@ export class DeploymentsImpl implements Deployments { rawResponse: { statusCode: currentRawResponse!.status, body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } + headers: currentRawResponse!.headers.toJSON(), + }, }; }; const lro = createLroSpec({ sendOperationFn, args: { resourceGroupName, deploymentName, options }, - spec: deleteOperationSpec + spec: deleteOperationSpec, }); const poller = await createHttpPoller>(lro, { restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs + intervalInMs: options?.updateIntervalInMs, }); await poller.poll(); return poller; @@ -2237,12 +2227,12 @@ export class DeploymentsImpl implements Deployments { async beginDeleteAndWait( resourceGroupName: string, deploymentName: string, - options?: DeploymentsDeleteOptionalParams + options?: DeploymentsDeleteOptionalParams, ): Promise { const poller = await this.beginDelete( resourceGroupName, deploymentName, - options + options, ); return poller.pollUntilDone(); } @@ -2257,11 +2247,11 @@ export class DeploymentsImpl implements Deployments { checkExistence( resourceGroupName: string, deploymentName: string, - options?: DeploymentsCheckExistenceOptionalParams + options?: DeploymentsCheckExistenceOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceGroupName, deploymentName, options }, - checkExistenceOperationSpec + checkExistenceOperationSpec, ); } @@ -2277,7 +2267,7 @@ export class DeploymentsImpl implements Deployments { resourceGroupName: string, deploymentName: string, parameters: Deployment, - options?: DeploymentsCreateOrUpdateOptionalParams + options?: DeploymentsCreateOrUpdateOptionalParams, ): Promise< SimplePollerLike< OperationState, @@ -2286,21 +2276,20 @@ export class DeploymentsImpl implements Deployments { > { const directSendOperation = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ): Promise => { return this.client.sendOperationRequest(args, spec); }; const sendOperationFn = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; + let currentRawResponse: coreClient.FullOperationResponse | undefined = + undefined; const providedCallback = args.options?.onResponse; const callback: coreClient.RawResponseCallback = ( rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown + flatResponse: unknown, ) => { currentRawResponse = rawResponse; providedCallback?.(rawResponse, flatResponse); @@ -2309,8 +2298,8 @@ export class DeploymentsImpl implements Deployments { ...args, options: { ...args.options, - onResponse: callback - } + onResponse: callback, + }, }; const flatResponse = await directSendOperation(updatedArgs, spec); return { @@ -2318,22 +2307,22 @@ export class DeploymentsImpl implements Deployments { rawResponse: { statusCode: currentRawResponse!.status, body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } + headers: currentRawResponse!.headers.toJSON(), + }, }; }; const lro = createLroSpec({ sendOperationFn, args: { resourceGroupName, deploymentName, parameters, options }, - spec: createOrUpdateOperationSpec + spec: createOrUpdateOperationSpec, }); const poller = await createHttpPoller< DeploymentsCreateOrUpdateResponse, OperationState >(lro, { restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs + intervalInMs: options?.updateIntervalInMs, }); await poller.poll(); return poller; @@ -2351,13 +2340,13 @@ export class DeploymentsImpl implements Deployments { resourceGroupName: string, deploymentName: string, parameters: Deployment, - options?: DeploymentsCreateOrUpdateOptionalParams + options?: DeploymentsCreateOrUpdateOptionalParams, ): Promise { const poller = await this.beginCreateOrUpdate( resourceGroupName, deploymentName, parameters, - options + options, ); return poller.pollUntilDone(); } @@ -2371,11 +2360,11 @@ export class DeploymentsImpl implements Deployments { get( resourceGroupName: string, deploymentName: string, - options?: DeploymentsGetOptionalParams + options?: DeploymentsGetOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceGroupName, deploymentName, options }, - getOperationSpec + getOperationSpec, ); } @@ -2390,11 +2379,11 @@ export class DeploymentsImpl implements Deployments { cancel( resourceGroupName: string, deploymentName: string, - options?: DeploymentsCancelOptionalParams + options?: DeploymentsCancelOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceGroupName, deploymentName, options }, - cancelOperationSpec + cancelOperationSpec, ); } @@ -2411,7 +2400,7 @@ export class DeploymentsImpl implements Deployments { resourceGroupName: string, deploymentName: string, parameters: Deployment, - options?: DeploymentsValidateOptionalParams + options?: DeploymentsValidateOptionalParams, ): Promise< SimplePollerLike< OperationState, @@ -2420,21 +2409,20 @@ export class DeploymentsImpl implements Deployments { > { const directSendOperation = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ): Promise => { return this.client.sendOperationRequest(args, spec); }; const sendOperationFn = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; + let currentRawResponse: coreClient.FullOperationResponse | undefined = + undefined; const providedCallback = args.options?.onResponse; const callback: coreClient.RawResponseCallback = ( rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown + flatResponse: unknown, ) => { currentRawResponse = rawResponse; providedCallback?.(rawResponse, flatResponse); @@ -2443,8 +2431,8 @@ export class DeploymentsImpl implements Deployments { ...args, options: { ...args.options, - onResponse: callback - } + onResponse: callback, + }, }; const flatResponse = await directSendOperation(updatedArgs, spec); return { @@ -2452,22 +2440,22 @@ export class DeploymentsImpl implements Deployments { rawResponse: { statusCode: currentRawResponse!.status, body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } + headers: currentRawResponse!.headers.toJSON(), + }, }; }; const lro = createLroSpec({ sendOperationFn, args: { resourceGroupName, deploymentName, parameters, options }, - spec: validateOperationSpec + spec: validateOperationSpec, }); const poller = await createHttpPoller< DeploymentsValidateResponse, OperationState >(lro, { restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs + intervalInMs: options?.updateIntervalInMs, }); await poller.poll(); return poller; @@ -2486,13 +2474,13 @@ export class DeploymentsImpl implements Deployments { resourceGroupName: string, deploymentName: string, parameters: Deployment, - options?: DeploymentsValidateOptionalParams + options?: DeploymentsValidateOptionalParams, ): Promise { const poller = await this.beginValidate( resourceGroupName, deploymentName, parameters, - options + options, ); return poller.pollUntilDone(); } @@ -2509,7 +2497,7 @@ export class DeploymentsImpl implements Deployments { resourceGroupName: string, deploymentName: string, parameters: DeploymentWhatIf, - options?: DeploymentsWhatIfOptionalParams + options?: DeploymentsWhatIfOptionalParams, ): Promise< SimplePollerLike< OperationState, @@ -2518,21 +2506,20 @@ export class DeploymentsImpl implements Deployments { > { const directSendOperation = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ): Promise => { return this.client.sendOperationRequest(args, spec); }; const sendOperationFn = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; + let currentRawResponse: coreClient.FullOperationResponse | undefined = + undefined; const providedCallback = args.options?.onResponse; const callback: coreClient.RawResponseCallback = ( rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown + flatResponse: unknown, ) => { currentRawResponse = rawResponse; providedCallback?.(rawResponse, flatResponse); @@ -2541,8 +2528,8 @@ export class DeploymentsImpl implements Deployments { ...args, options: { ...args.options, - onResponse: callback - } + onResponse: callback, + }, }; const flatResponse = await directSendOperation(updatedArgs, spec); return { @@ -2550,15 +2537,15 @@ export class DeploymentsImpl implements Deployments { rawResponse: { statusCode: currentRawResponse!.status, body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } + headers: currentRawResponse!.headers.toJSON(), + }, }; }; const lro = createLroSpec({ sendOperationFn, args: { resourceGroupName, deploymentName, parameters, options }, - spec: whatIfOperationSpec + spec: whatIfOperationSpec, }); const poller = await createHttpPoller< DeploymentsWhatIfResponse, @@ -2566,7 +2553,7 @@ export class DeploymentsImpl implements Deployments { >(lro, { restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs, - resourceLocationConfig: "location" + resourceLocationConfig: "location", }); await poller.poll(); return poller; @@ -2584,13 +2571,13 @@ export class DeploymentsImpl implements Deployments { resourceGroupName: string, deploymentName: string, parameters: DeploymentWhatIf, - options?: DeploymentsWhatIfOptionalParams + options?: DeploymentsWhatIfOptionalParams, ): Promise { const poller = await this.beginWhatIf( resourceGroupName, deploymentName, parameters, - options + options, ); return poller.pollUntilDone(); } @@ -2604,11 +2591,11 @@ export class DeploymentsImpl implements Deployments { exportTemplate( resourceGroupName: string, deploymentName: string, - options?: DeploymentsExportTemplateOptionalParams + options?: DeploymentsExportTemplateOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceGroupName, deploymentName, options }, - exportTemplateOperationSpec + exportTemplateOperationSpec, ); } @@ -2620,11 +2607,11 @@ export class DeploymentsImpl implements Deployments { */ private _listByResourceGroup( resourceGroupName: string, - options?: DeploymentsListByResourceGroupOptionalParams + options?: DeploymentsListByResourceGroupOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceGroupName, options }, - listByResourceGroupOperationSpec + listByResourceGroupOperationSpec, ); } @@ -2635,11 +2622,11 @@ export class DeploymentsImpl implements Deployments { */ calculateTemplateHash( template: Record, - options?: DeploymentsCalculateTemplateHashOptionalParams + options?: DeploymentsCalculateTemplateHashOptionalParams, ): Promise { return this.client.sendOperationRequest( { template, options }, - calculateTemplateHashOperationSpec + calculateTemplateHashOperationSpec, ); } @@ -2652,11 +2639,11 @@ export class DeploymentsImpl implements Deployments { private _listAtScopeNext( scope: string, nextLink: string, - options?: DeploymentsListAtScopeNextOptionalParams + options?: DeploymentsListAtScopeNextOptionalParams, ): Promise { return this.client.sendOperationRequest( { scope, nextLink, options }, - listAtScopeNextOperationSpec + listAtScopeNextOperationSpec, ); } @@ -2667,11 +2654,11 @@ export class DeploymentsImpl implements Deployments { */ private _listAtTenantScopeNext( nextLink: string, - options?: DeploymentsListAtTenantScopeNextOptionalParams + options?: DeploymentsListAtTenantScopeNextOptionalParams, ): Promise { return this.client.sendOperationRequest( { nextLink, options }, - listAtTenantScopeNextOperationSpec + listAtTenantScopeNextOperationSpec, ); } @@ -2685,11 +2672,11 @@ export class DeploymentsImpl implements Deployments { private _listAtManagementGroupScopeNext( groupId: string, nextLink: string, - options?: DeploymentsListAtManagementGroupScopeNextOptionalParams + options?: DeploymentsListAtManagementGroupScopeNextOptionalParams, ): Promise { return this.client.sendOperationRequest( { groupId, nextLink, options }, - listAtManagementGroupScopeNextOperationSpec + listAtManagementGroupScopeNextOperationSpec, ); } @@ -2701,11 +2688,11 @@ export class DeploymentsImpl implements Deployments { */ private _listAtSubscriptionScopeNext( nextLink: string, - options?: DeploymentsListAtSubscriptionScopeNextOptionalParams + options?: DeploymentsListAtSubscriptionScopeNextOptionalParams, ): Promise { return this.client.sendOperationRequest( { nextLink, options }, - listAtSubscriptionScopeNextOperationSpec + listAtSubscriptionScopeNextOperationSpec, ); } @@ -2719,11 +2706,11 @@ export class DeploymentsImpl implements Deployments { private _listByResourceGroupNext( resourceGroupName: string, nextLink: string, - options?: DeploymentsListByResourceGroupNextOptionalParams + options?: DeploymentsListByResourceGroupNextOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceGroupName, nextLink, options }, - listByResourceGroupNextOperationSpec + listByResourceGroupNextOperationSpec, ); } } @@ -2739,17 +2726,17 @@ const deleteAtScopeOperationSpec: coreClient.OperationSpec = { 202: {}, 204: {}, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.scope, - Parameters.deploymentName + Parameters.deploymentName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const checkExistenceAtScopeOperationSpec: coreClient.OperationSpec = { path: "/{scope}/providers/Microsoft.Resources/deployments/{deploymentName}", @@ -2758,156 +2745,153 @@ const checkExistenceAtScopeOperationSpec: coreClient.OperationSpec = { 204: {}, 404: {}, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.scope, - Parameters.deploymentName + Parameters.deploymentName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const createOrUpdateAtScopeOperationSpec: coreClient.OperationSpec = { path: "/{scope}/providers/Microsoft.Resources/deployments/{deploymentName}", httpMethod: "PUT", responses: { 200: { - bodyMapper: Mappers.DeploymentExtended + bodyMapper: Mappers.DeploymentExtended, }, 201: { - bodyMapper: Mappers.DeploymentExtended + bodyMapper: Mappers.DeploymentExtended, }, 202: { - bodyMapper: Mappers.DeploymentExtended + bodyMapper: Mappers.DeploymentExtended, }, 204: { - bodyMapper: Mappers.DeploymentExtended + bodyMapper: Mappers.DeploymentExtended, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, requestBody: Parameters.parameters, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.scope, - Parameters.deploymentName + Parameters.deploymentName, ], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", - serializer + serializer, }; const getAtScopeOperationSpec: coreClient.OperationSpec = { path: "/{scope}/providers/Microsoft.Resources/deployments/{deploymentName}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.DeploymentExtended + bodyMapper: Mappers.DeploymentExtended, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.scope, - Parameters.deploymentName + Parameters.deploymentName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const cancelAtScopeOperationSpec: coreClient.OperationSpec = { - path: - "/{scope}/providers/Microsoft.Resources/deployments/{deploymentName}/cancel", + path: "/{scope}/providers/Microsoft.Resources/deployments/{deploymentName}/cancel", httpMethod: "POST", responses: { 204: {}, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.scope, - Parameters.deploymentName + Parameters.deploymentName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const validateAtScopeOperationSpec: coreClient.OperationSpec = { - path: - "/{scope}/providers/Microsoft.Resources/deployments/{deploymentName}/validate", + path: "/{scope}/providers/Microsoft.Resources/deployments/{deploymentName}/validate", httpMethod: "POST", responses: { 200: { - bodyMapper: Mappers.DeploymentValidateResult + bodyMapper: Mappers.DeploymentExtended, }, 201: { - bodyMapper: Mappers.DeploymentValidateResult + bodyMapper: Mappers.DeploymentExtended, }, 202: { - bodyMapper: Mappers.DeploymentValidateResult + bodyMapper: Mappers.DeploymentExtended, }, 204: { - bodyMapper: Mappers.DeploymentValidateResult + bodyMapper: Mappers.DeploymentExtended, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, requestBody: Parameters.parameters, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.scope, - Parameters.deploymentName + Parameters.deploymentName, ], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", - serializer + serializer, }; const exportTemplateAtScopeOperationSpec: coreClient.OperationSpec = { - path: - "/{scope}/providers/Microsoft.Resources/deployments/{deploymentName}/exportTemplate", + path: "/{scope}/providers/Microsoft.Resources/deployments/{deploymentName}/exportTemplate", httpMethod: "POST", responses: { 200: { - bodyMapper: Mappers.DeploymentExportResult + bodyMapper: Mappers.DeploymentExportResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.scope, - Parameters.deploymentName + Parameters.deploymentName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const listAtScopeOperationSpec: coreClient.OperationSpec = { path: "/{scope}/providers/Microsoft.Resources/deployments/", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.DeploymentListResult + bodyMapper: Mappers.DeploymentListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion, Parameters.filter, Parameters.top], urlParameters: [Parameters.$host, Parameters.scope], headerParameters: [Parameters.accept], - serializer + serializer, }; const deleteAtTenantScopeOperationSpec: coreClient.OperationSpec = { path: "/providers/Microsoft.Resources/deployments/{deploymentName}", @@ -2918,13 +2902,13 @@ const deleteAtTenantScopeOperationSpec: coreClient.OperationSpec = { 202: {}, 204: {}, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [Parameters.$host, Parameters.deploymentName], headerParameters: [Parameters.accept], - serializer + serializer, }; const checkExistenceAtTenantScopeOperationSpec: coreClient.OperationSpec = { path: "/providers/Microsoft.Resources/deployments/{deploymentName}", @@ -2933,56 +2917,56 @@ const checkExistenceAtTenantScopeOperationSpec: coreClient.OperationSpec = { 204: {}, 404: {}, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [Parameters.$host, Parameters.deploymentName], headerParameters: [Parameters.accept], - serializer + serializer, }; const createOrUpdateAtTenantScopeOperationSpec: coreClient.OperationSpec = { path: "/providers/Microsoft.Resources/deployments/{deploymentName}", httpMethod: "PUT", responses: { 200: { - bodyMapper: Mappers.DeploymentExtended + bodyMapper: Mappers.DeploymentExtended, }, 201: { - bodyMapper: Mappers.DeploymentExtended + bodyMapper: Mappers.DeploymentExtended, }, 202: { - bodyMapper: Mappers.DeploymentExtended + bodyMapper: Mappers.DeploymentExtended, }, 204: { - bodyMapper: Mappers.DeploymentExtended + bodyMapper: Mappers.DeploymentExtended, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, requestBody: Parameters.parameters1, queryParameters: [Parameters.apiVersion], urlParameters: [Parameters.$host, Parameters.deploymentName], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", - serializer + serializer, }; const getAtTenantScopeOperationSpec: coreClient.OperationSpec = { path: "/providers/Microsoft.Resources/deployments/{deploymentName}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.DeploymentExtended + bodyMapper: Mappers.DeploymentExtended, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [Parameters.$host, Parameters.deploymentName], headerParameters: [Parameters.accept], - serializer + serializer, }; const cancelAtTenantScopeOperationSpec: coreClient.OperationSpec = { path: "/providers/Microsoft.Resources/deployments/{deploymentName}/cancel", @@ -2990,104 +2974,102 @@ const cancelAtTenantScopeOperationSpec: coreClient.OperationSpec = { responses: { 204: {}, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [Parameters.$host, Parameters.deploymentName], headerParameters: [Parameters.accept], - serializer + serializer, }; const validateAtTenantScopeOperationSpec: coreClient.OperationSpec = { path: "/providers/Microsoft.Resources/deployments/{deploymentName}/validate", httpMethod: "POST", responses: { 200: { - bodyMapper: Mappers.DeploymentValidateResult + bodyMapper: Mappers.DeploymentExtended, }, 201: { - bodyMapper: Mappers.DeploymentValidateResult + bodyMapper: Mappers.DeploymentExtended, }, 202: { - bodyMapper: Mappers.DeploymentValidateResult + bodyMapper: Mappers.DeploymentExtended, }, 204: { - bodyMapper: Mappers.DeploymentValidateResult + bodyMapper: Mappers.DeploymentExtended, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, requestBody: Parameters.parameters1, queryParameters: [Parameters.apiVersion], urlParameters: [Parameters.$host, Parameters.deploymentName], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", - serializer + serializer, }; const whatIfAtTenantScopeOperationSpec: coreClient.OperationSpec = { path: "/providers/Microsoft.Resources/deployments/{deploymentName}/whatIf", httpMethod: "POST", responses: { 200: { - bodyMapper: Mappers.WhatIfOperationResult + bodyMapper: Mappers.WhatIfOperationResult, }, 201: { - bodyMapper: Mappers.WhatIfOperationResult + bodyMapper: Mappers.WhatIfOperationResult, }, 202: { - bodyMapper: Mappers.WhatIfOperationResult + bodyMapper: Mappers.WhatIfOperationResult, }, 204: { - bodyMapper: Mappers.WhatIfOperationResult + bodyMapper: Mappers.WhatIfOperationResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, requestBody: Parameters.parameters2, queryParameters: [Parameters.apiVersion], urlParameters: [Parameters.$host, Parameters.deploymentName], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", - serializer + serializer, }; const exportTemplateAtTenantScopeOperationSpec: coreClient.OperationSpec = { - path: - "/providers/Microsoft.Resources/deployments/{deploymentName}/exportTemplate", + path: "/providers/Microsoft.Resources/deployments/{deploymentName}/exportTemplate", httpMethod: "POST", responses: { 200: { - bodyMapper: Mappers.DeploymentExportResult + bodyMapper: Mappers.DeploymentExportResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [Parameters.$host, Parameters.deploymentName], headerParameters: [Parameters.accept], - serializer + serializer, }; const listAtTenantScopeOperationSpec: coreClient.OperationSpec = { path: "/providers/Microsoft.Resources/deployments/", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.DeploymentListResult + bodyMapper: Mappers.DeploymentListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion, Parameters.filter, Parameters.top], urlParameters: [Parameters.$host], headerParameters: [Parameters.accept], - serializer + serializer, }; const deleteAtManagementGroupScopeOperationSpec: coreClient.OperationSpec = { - path: - "/providers/Microsoft.Management/managementGroups/{groupId}/providers/Microsoft.Resources/deployments/{deploymentName}", + path: "/providers/Microsoft.Management/managementGroups/{groupId}/providers/Microsoft.Resources/deployments/{deploymentName}", httpMethod: "DELETE", responses: { 200: {}, @@ -3095,215 +3077,209 @@ const deleteAtManagementGroupScopeOperationSpec: coreClient.OperationSpec = { 202: {}, 204: {}, default: { - bodyMapper: Mappers.CloudError - } - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.deploymentName, - Parameters.groupId - ], - headerParameters: [Parameters.accept], - serializer -}; -const checkExistenceAtManagementGroupScopeOperationSpec: coreClient.OperationSpec = { - path: - "/providers/Microsoft.Management/managementGroups/{groupId}/providers/Microsoft.Resources/deployments/{deploymentName}", - httpMethod: "HEAD", - responses: { - 204: {}, - 404: {}, - default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.deploymentName, - Parameters.groupId + Parameters.groupId, ], headerParameters: [Parameters.accept], - serializer + serializer, }; -const createOrUpdateAtManagementGroupScopeOperationSpec: coreClient.OperationSpec = { - path: - "/providers/Microsoft.Management/managementGroups/{groupId}/providers/Microsoft.Resources/deployments/{deploymentName}", - httpMethod: "PUT", - responses: { - 200: { - bodyMapper: Mappers.DeploymentExtended - }, - 201: { - bodyMapper: Mappers.DeploymentExtended - }, - 202: { - bodyMapper: Mappers.DeploymentExtended +const checkExistenceAtManagementGroupScopeOperationSpec: coreClient.OperationSpec = + { + path: "/providers/Microsoft.Management/managementGroups/{groupId}/providers/Microsoft.Resources/deployments/{deploymentName}", + httpMethod: "HEAD", + responses: { + 204: {}, + 404: {}, + default: { + bodyMapper: Mappers.CloudError, + }, }, - 204: { - bodyMapper: Mappers.DeploymentExtended + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.deploymentName, + Parameters.groupId, + ], + headerParameters: [Parameters.accept], + serializer, + }; +const createOrUpdateAtManagementGroupScopeOperationSpec: coreClient.OperationSpec = + { + path: "/providers/Microsoft.Management/managementGroups/{groupId}/providers/Microsoft.Resources/deployments/{deploymentName}", + httpMethod: "PUT", + responses: { + 200: { + bodyMapper: Mappers.DeploymentExtended, + }, + 201: { + bodyMapper: Mappers.DeploymentExtended, + }, + 202: { + bodyMapper: Mappers.DeploymentExtended, + }, + 204: { + bodyMapper: Mappers.DeploymentExtended, + }, + default: { + bodyMapper: Mappers.CloudError, + }, }, - default: { - bodyMapper: Mappers.CloudError - } - }, - requestBody: Parameters.parameters1, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.deploymentName, - Parameters.groupId - ], - headerParameters: [Parameters.accept, Parameters.contentType], - mediaType: "json", - serializer -}; + requestBody: Parameters.parameters1, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.deploymentName, + Parameters.groupId, + ], + headerParameters: [Parameters.accept, Parameters.contentType], + mediaType: "json", + serializer, + }; const getAtManagementGroupScopeOperationSpec: coreClient.OperationSpec = { - path: - "/providers/Microsoft.Management/managementGroups/{groupId}/providers/Microsoft.Resources/deployments/{deploymentName}", + path: "/providers/Microsoft.Management/managementGroups/{groupId}/providers/Microsoft.Resources/deployments/{deploymentName}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.DeploymentExtended + bodyMapper: Mappers.DeploymentExtended, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.deploymentName, - Parameters.groupId + Parameters.groupId, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const cancelAtManagementGroupScopeOperationSpec: coreClient.OperationSpec = { - path: - "/providers/Microsoft.Management/managementGroups/{groupId}/providers/Microsoft.Resources/deployments/{deploymentName}/cancel", + path: "/providers/Microsoft.Management/managementGroups/{groupId}/providers/Microsoft.Resources/deployments/{deploymentName}/cancel", httpMethod: "POST", responses: { 204: {}, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.deploymentName, - Parameters.groupId + Parameters.groupId, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const validateAtManagementGroupScopeOperationSpec: coreClient.OperationSpec = { - path: - "/providers/Microsoft.Management/managementGroups/{groupId}/providers/Microsoft.Resources/deployments/{deploymentName}/validate", + path: "/providers/Microsoft.Management/managementGroups/{groupId}/providers/Microsoft.Resources/deployments/{deploymentName}/validate", httpMethod: "POST", responses: { 200: { - bodyMapper: Mappers.DeploymentValidateResult + bodyMapper: Mappers.DeploymentExtended, }, 201: { - bodyMapper: Mappers.DeploymentValidateResult + bodyMapper: Mappers.DeploymentExtended, }, 202: { - bodyMapper: Mappers.DeploymentValidateResult + bodyMapper: Mappers.DeploymentExtended, }, 204: { - bodyMapper: Mappers.DeploymentValidateResult + bodyMapper: Mappers.DeploymentExtended, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, requestBody: Parameters.parameters1, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.deploymentName, - Parameters.groupId + Parameters.groupId, ], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", - serializer + serializer, }; const whatIfAtManagementGroupScopeOperationSpec: coreClient.OperationSpec = { - path: - "/providers/Microsoft.Management/managementGroups/{groupId}/providers/Microsoft.Resources/deployments/{deploymentName}/whatIf", + path: "/providers/Microsoft.Management/managementGroups/{groupId}/providers/Microsoft.Resources/deployments/{deploymentName}/whatIf", httpMethod: "POST", responses: { 200: { - bodyMapper: Mappers.WhatIfOperationResult + bodyMapper: Mappers.WhatIfOperationResult, }, 201: { - bodyMapper: Mappers.WhatIfOperationResult + bodyMapper: Mappers.WhatIfOperationResult, }, 202: { - bodyMapper: Mappers.WhatIfOperationResult + bodyMapper: Mappers.WhatIfOperationResult, }, 204: { - bodyMapper: Mappers.WhatIfOperationResult + bodyMapper: Mappers.WhatIfOperationResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, requestBody: Parameters.parameters2, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.deploymentName, - Parameters.groupId + Parameters.groupId, ], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", - serializer + serializer, }; -const exportTemplateAtManagementGroupScopeOperationSpec: coreClient.OperationSpec = { - path: - "/providers/Microsoft.Management/managementGroups/{groupId}/providers/Microsoft.Resources/deployments/{deploymentName}/exportTemplate", - httpMethod: "POST", - responses: { - 200: { - bodyMapper: Mappers.DeploymentExportResult +const exportTemplateAtManagementGroupScopeOperationSpec: coreClient.OperationSpec = + { + path: "/providers/Microsoft.Management/managementGroups/{groupId}/providers/Microsoft.Resources/deployments/{deploymentName}/exportTemplate", + httpMethod: "POST", + responses: { + 200: { + bodyMapper: Mappers.DeploymentExportResult, + }, + default: { + bodyMapper: Mappers.CloudError, + }, }, - default: { - bodyMapper: Mappers.CloudError - } - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.deploymentName, - Parameters.groupId - ], - headerParameters: [Parameters.accept], - serializer -}; + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.deploymentName, + Parameters.groupId, + ], + headerParameters: [Parameters.accept], + serializer, + }; const listAtManagementGroupScopeOperationSpec: coreClient.OperationSpec = { - path: - "/providers/Microsoft.Management/managementGroups/{groupId}/providers/Microsoft.Resources/deployments/", + path: "/providers/Microsoft.Management/managementGroups/{groupId}/providers/Microsoft.Resources/deployments/", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.DeploymentListResult + bodyMapper: Mappers.DeploymentListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion, Parameters.filter, Parameters.top], urlParameters: [Parameters.$host, Parameters.groupId], headerParameters: [Parameters.accept], - serializer + serializer, }; const deleteAtSubscriptionScopeOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/providers/Microsoft.Resources/deployments/{deploymentName}", + path: "/subscriptions/{subscriptionId}/providers/Microsoft.Resources/deployments/{deploymentName}", httpMethod: "DELETE", responses: { 200: {}, @@ -3311,215 +3287,209 @@ const deleteAtSubscriptionScopeOperationSpec: coreClient.OperationSpec = { 202: {}, 204: {}, default: { - bodyMapper: Mappers.CloudError - } - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.deploymentName, - Parameters.subscriptionId - ], - headerParameters: [Parameters.accept], - serializer -}; -const checkExistenceAtSubscriptionScopeOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/providers/Microsoft.Resources/deployments/{deploymentName}", - httpMethod: "HEAD", - responses: { - 204: {}, - 404: {}, - default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.deploymentName, - Parameters.subscriptionId + Parameters.subscriptionId, ], headerParameters: [Parameters.accept], - serializer + serializer, }; -const createOrUpdateAtSubscriptionScopeOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/providers/Microsoft.Resources/deployments/{deploymentName}", - httpMethod: "PUT", - responses: { - 200: { - bodyMapper: Mappers.DeploymentExtended - }, - 201: { - bodyMapper: Mappers.DeploymentExtended - }, - 202: { - bodyMapper: Mappers.DeploymentExtended +const checkExistenceAtSubscriptionScopeOperationSpec: coreClient.OperationSpec = + { + path: "/subscriptions/{subscriptionId}/providers/Microsoft.Resources/deployments/{deploymentName}", + httpMethod: "HEAD", + responses: { + 204: {}, + 404: {}, + default: { + bodyMapper: Mappers.CloudError, + }, }, - 204: { - bodyMapper: Mappers.DeploymentExtended + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.deploymentName, + Parameters.subscriptionId, + ], + headerParameters: [Parameters.accept], + serializer, + }; +const createOrUpdateAtSubscriptionScopeOperationSpec: coreClient.OperationSpec = + { + path: "/subscriptions/{subscriptionId}/providers/Microsoft.Resources/deployments/{deploymentName}", + httpMethod: "PUT", + responses: { + 200: { + bodyMapper: Mappers.DeploymentExtended, + }, + 201: { + bodyMapper: Mappers.DeploymentExtended, + }, + 202: { + bodyMapper: Mappers.DeploymentExtended, + }, + 204: { + bodyMapper: Mappers.DeploymentExtended, + }, + default: { + bodyMapper: Mappers.CloudError, + }, }, - default: { - bodyMapper: Mappers.CloudError - } - }, - requestBody: Parameters.parameters, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.deploymentName, - Parameters.subscriptionId - ], - headerParameters: [Parameters.accept, Parameters.contentType], - mediaType: "json", - serializer -}; + requestBody: Parameters.parameters, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.deploymentName, + Parameters.subscriptionId, + ], + headerParameters: [Parameters.accept, Parameters.contentType], + mediaType: "json", + serializer, + }; const getAtSubscriptionScopeOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/providers/Microsoft.Resources/deployments/{deploymentName}", + path: "/subscriptions/{subscriptionId}/providers/Microsoft.Resources/deployments/{deploymentName}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.DeploymentExtended + bodyMapper: Mappers.DeploymentExtended, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.deploymentName, - Parameters.subscriptionId + Parameters.subscriptionId, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const cancelAtSubscriptionScopeOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/providers/Microsoft.Resources/deployments/{deploymentName}/cancel", + path: "/subscriptions/{subscriptionId}/providers/Microsoft.Resources/deployments/{deploymentName}/cancel", httpMethod: "POST", responses: { 204: {}, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.deploymentName, - Parameters.subscriptionId + Parameters.subscriptionId, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const validateAtSubscriptionScopeOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/providers/Microsoft.Resources/deployments/{deploymentName}/validate", + path: "/subscriptions/{subscriptionId}/providers/Microsoft.Resources/deployments/{deploymentName}/validate", httpMethod: "POST", responses: { 200: { - bodyMapper: Mappers.DeploymentValidateResult + bodyMapper: Mappers.DeploymentExtended, }, 201: { - bodyMapper: Mappers.DeploymentValidateResult + bodyMapper: Mappers.DeploymentExtended, }, 202: { - bodyMapper: Mappers.DeploymentValidateResult + bodyMapper: Mappers.DeploymentExtended, }, 204: { - bodyMapper: Mappers.DeploymentValidateResult + bodyMapper: Mappers.DeploymentExtended, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, requestBody: Parameters.parameters, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.deploymentName, - Parameters.subscriptionId + Parameters.subscriptionId, ], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", - serializer + serializer, }; const whatIfAtSubscriptionScopeOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/providers/Microsoft.Resources/deployments/{deploymentName}/whatIf", + path: "/subscriptions/{subscriptionId}/providers/Microsoft.Resources/deployments/{deploymentName}/whatIf", httpMethod: "POST", responses: { 200: { - bodyMapper: Mappers.WhatIfOperationResult + bodyMapper: Mappers.WhatIfOperationResult, }, 201: { - bodyMapper: Mappers.WhatIfOperationResult + bodyMapper: Mappers.WhatIfOperationResult, }, 202: { - bodyMapper: Mappers.WhatIfOperationResult + bodyMapper: Mappers.WhatIfOperationResult, }, 204: { - bodyMapper: Mappers.WhatIfOperationResult + bodyMapper: Mappers.WhatIfOperationResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, requestBody: Parameters.parameters3, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.deploymentName, - Parameters.subscriptionId + Parameters.subscriptionId, ], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", - serializer + serializer, }; -const exportTemplateAtSubscriptionScopeOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/providers/Microsoft.Resources/deployments/{deploymentName}/exportTemplate", - httpMethod: "POST", - responses: { - 200: { - bodyMapper: Mappers.DeploymentExportResult +const exportTemplateAtSubscriptionScopeOperationSpec: coreClient.OperationSpec = + { + path: "/subscriptions/{subscriptionId}/providers/Microsoft.Resources/deployments/{deploymentName}/exportTemplate", + httpMethod: "POST", + responses: { + 200: { + bodyMapper: Mappers.DeploymentExportResult, + }, + default: { + bodyMapper: Mappers.CloudError, + }, }, - default: { - bodyMapper: Mappers.CloudError - } - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.deploymentName, - Parameters.subscriptionId - ], - headerParameters: [Parameters.accept], - serializer -}; + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.deploymentName, + Parameters.subscriptionId, + ], + headerParameters: [Parameters.accept], + serializer, + }; const listAtSubscriptionScopeOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/providers/Microsoft.Resources/deployments/", + path: "/subscriptions/{subscriptionId}/providers/Microsoft.Resources/deployments/", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.DeploymentListResult + bodyMapper: Mappers.DeploymentListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion, Parameters.filter, Parameters.top], urlParameters: [Parameters.$host, Parameters.subscriptionId], headerParameters: [Parameters.accept], - serializer + serializer, }; const deleteOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.Resources/deployments/{deploymentName}", + path: "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.Resources/deployments/{deploymentName}", httpMethod: "DELETE", responses: { 200: {}, @@ -3527,60 +3497,58 @@ const deleteOperationSpec: coreClient.OperationSpec = { 202: {}, 204: {}, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.deploymentName, Parameters.subscriptionId, - Parameters.resourceGroupName + Parameters.resourceGroupName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const checkExistenceOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.Resources/deployments/{deploymentName}", + path: "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.Resources/deployments/{deploymentName}", httpMethod: "HEAD", responses: { 204: {}, 404: {}, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.deploymentName, Parameters.subscriptionId, - Parameters.resourceGroupName + Parameters.resourceGroupName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const createOrUpdateOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.Resources/deployments/{deploymentName}", + path: "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.Resources/deployments/{deploymentName}", httpMethod: "PUT", responses: { 200: { - bodyMapper: Mappers.DeploymentExtended + bodyMapper: Mappers.DeploymentExtended, }, 201: { - bodyMapper: Mappers.DeploymentExtended + bodyMapper: Mappers.DeploymentExtended, }, 202: { - bodyMapper: Mappers.DeploymentExtended + bodyMapper: Mappers.DeploymentExtended, }, 204: { - bodyMapper: Mappers.DeploymentExtended + bodyMapper: Mappers.DeploymentExtended, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, requestBody: Parameters.parameters, queryParameters: [Parameters.apiVersion], @@ -3588,74 +3556,71 @@ const createOrUpdateOperationSpec: coreClient.OperationSpec = { Parameters.$host, Parameters.deploymentName, Parameters.subscriptionId, - Parameters.resourceGroupName + Parameters.resourceGroupName, ], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", - serializer + serializer, }; const getOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.Resources/deployments/{deploymentName}", + path: "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.Resources/deployments/{deploymentName}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.DeploymentExtended + bodyMapper: Mappers.DeploymentExtended, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.deploymentName, Parameters.subscriptionId, - Parameters.resourceGroupName + Parameters.resourceGroupName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const cancelOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.Resources/deployments/{deploymentName}/cancel", + path: "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.Resources/deployments/{deploymentName}/cancel", httpMethod: "POST", responses: { 204: {}, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.deploymentName, Parameters.subscriptionId, - Parameters.resourceGroupName + Parameters.resourceGroupName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const validateOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.Resources/deployments/{deploymentName}/validate", + path: "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.Resources/deployments/{deploymentName}/validate", httpMethod: "POST", responses: { 200: { - bodyMapper: Mappers.DeploymentValidateResult + bodyMapper: Mappers.DeploymentExtended, }, 201: { - bodyMapper: Mappers.DeploymentValidateResult + bodyMapper: Mappers.DeploymentExtended, }, 202: { - bodyMapper: Mappers.DeploymentValidateResult + bodyMapper: Mappers.DeploymentExtended, }, 204: { - bodyMapper: Mappers.DeploymentValidateResult + bodyMapper: Mappers.DeploymentExtended, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, requestBody: Parameters.parameters, queryParameters: [Parameters.apiVersion], @@ -3663,32 +3628,31 @@ const validateOperationSpec: coreClient.OperationSpec = { Parameters.$host, Parameters.deploymentName, Parameters.subscriptionId, - Parameters.resourceGroupName + Parameters.resourceGroupName, ], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", - serializer + serializer, }; const whatIfOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.Resources/deployments/{deploymentName}/whatIf", + path: "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.Resources/deployments/{deploymentName}/whatIf", httpMethod: "POST", responses: { 200: { - bodyMapper: Mappers.WhatIfOperationResult + bodyMapper: Mappers.WhatIfOperationResult, }, 201: { - bodyMapper: Mappers.WhatIfOperationResult + bodyMapper: Mappers.WhatIfOperationResult, }, 202: { - bodyMapper: Mappers.WhatIfOperationResult + bodyMapper: Mappers.WhatIfOperationResult, }, 204: { - bodyMapper: Mappers.WhatIfOperationResult + bodyMapper: Mappers.WhatIfOperationResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, requestBody: Parameters.parameters3, queryParameters: [Parameters.apiVersion], @@ -3696,154 +3660,152 @@ const whatIfOperationSpec: coreClient.OperationSpec = { Parameters.$host, Parameters.deploymentName, Parameters.subscriptionId, - Parameters.resourceGroupName + Parameters.resourceGroupName, ], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", - serializer + serializer, }; const exportTemplateOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.Resources/deployments/{deploymentName}/exportTemplate", + path: "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.Resources/deployments/{deploymentName}/exportTemplate", httpMethod: "POST", responses: { 200: { - bodyMapper: Mappers.DeploymentExportResult + bodyMapper: Mappers.DeploymentExportResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.deploymentName, Parameters.subscriptionId, - Parameters.resourceGroupName + Parameters.resourceGroupName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const listByResourceGroupOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.Resources/deployments/", + path: "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.Resources/deployments/", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.DeploymentListResult + bodyMapper: Mappers.DeploymentListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion, Parameters.filter, Parameters.top], urlParameters: [ Parameters.$host, Parameters.subscriptionId, - Parameters.resourceGroupName + Parameters.resourceGroupName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const calculateTemplateHashOperationSpec: coreClient.OperationSpec = { path: "/providers/Microsoft.Resources/calculateTemplateHash", httpMethod: "POST", responses: { 200: { - bodyMapper: Mappers.TemplateHashResult + bodyMapper: Mappers.TemplateHashResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, requestBody: Parameters.template, queryParameters: [Parameters.apiVersion], urlParameters: [Parameters.$host], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", - serializer + serializer, }; const listAtScopeNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.DeploymentListResult + bodyMapper: Mappers.DeploymentListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, urlParameters: [Parameters.$host, Parameters.nextLink, Parameters.scope], headerParameters: [Parameters.accept], - serializer + serializer, }; const listAtTenantScopeNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.DeploymentListResult + bodyMapper: Mappers.DeploymentListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, urlParameters: [Parameters.$host, Parameters.nextLink], headerParameters: [Parameters.accept], - serializer + serializer, }; const listAtManagementGroupScopeNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.DeploymentListResult + bodyMapper: Mappers.DeploymentListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, urlParameters: [Parameters.$host, Parameters.nextLink, Parameters.groupId], headerParameters: [Parameters.accept], - serializer + serializer, }; const listAtSubscriptionScopeNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.DeploymentListResult + bodyMapper: Mappers.DeploymentListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, urlParameters: [ Parameters.$host, Parameters.nextLink, - Parameters.subscriptionId + Parameters.subscriptionId, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const listByResourceGroupNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.DeploymentListResult + bodyMapper: Mappers.DeploymentListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, urlParameters: [ Parameters.$host, Parameters.nextLink, Parameters.subscriptionId, - Parameters.resourceGroupName + Parameters.resourceGroupName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; diff --git a/sdk/resources/arm-resources/src/operations/operations.ts b/sdk/resources/arm-resources/src/operations/operations.ts index e218ad6bc0b6..9d870ab061e5 100644 --- a/sdk/resources/arm-resources/src/operations/operations.ts +++ b/sdk/resources/arm-resources/src/operations/operations.ts @@ -18,7 +18,7 @@ import { OperationsListNextOptionalParams, OperationsListOptionalParams, OperationsListResponse, - OperationsListNextResponse + OperationsListNextResponse, } from "../models"; /// @@ -39,7 +39,7 @@ export class OperationsImpl implements Operations { * @param options The options parameters. */ public list( - options?: OperationsListOptionalParams + options?: OperationsListOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listPagingAll(options); return { @@ -54,13 +54,13 @@ export class OperationsImpl implements Operations { throw new Error("maxPageSize is not supported by this operation."); } return this.listPagingPage(options, settings); - } + }, }; } private async *listPagingPage( options?: OperationsListOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: OperationsListResponse; let continuationToken = settings?.continuationToken; @@ -81,7 +81,7 @@ export class OperationsImpl implements Operations { } private async *listPagingAll( - options?: OperationsListOptionalParams + options?: OperationsListOptionalParams, ): AsyncIterableIterator { for await (const page of this.listPagingPage(options)) { yield* page; @@ -93,7 +93,7 @@ export class OperationsImpl implements Operations { * @param options The options parameters. */ private _list( - options?: OperationsListOptionalParams + options?: OperationsListOptionalParams, ): Promise { return this.client.sendOperationRequest({ options }, listOperationSpec); } @@ -105,11 +105,11 @@ export class OperationsImpl implements Operations { */ private _listNext( nextLink: string, - options?: OperationsListNextOptionalParams + options?: OperationsListNextOptionalParams, ): Promise { return this.client.sendOperationRequest( { nextLink, options }, - listNextOperationSpec + listNextOperationSpec, ); } } @@ -121,29 +121,29 @@ const listOperationSpec: coreClient.OperationSpec = { httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.OperationListResult + bodyMapper: Mappers.OperationListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [Parameters.$host], headerParameters: [Parameters.accept], - serializer + serializer, }; const listNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.OperationListResult + bodyMapper: Mappers.OperationListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, urlParameters: [Parameters.$host, Parameters.nextLink], headerParameters: [Parameters.accept], - serializer + serializer, }; diff --git a/sdk/resources/arm-resources/src/operations/providerResourceTypes.ts b/sdk/resources/arm-resources/src/operations/providerResourceTypes.ts index 4384a10c5ae4..6faf65f7c983 100644 --- a/sdk/resources/arm-resources/src/operations/providerResourceTypes.ts +++ b/sdk/resources/arm-resources/src/operations/providerResourceTypes.ts @@ -13,7 +13,7 @@ import * as Parameters from "../models/parameters"; import { ResourceManagementClient } from "../resourceManagementClient"; import { ProviderResourceTypesListOptionalParams, - ProviderResourceTypesListResponse + ProviderResourceTypesListResponse, } from "../models"; /** Class containing ProviderResourceTypes operations. */ @@ -35,11 +35,11 @@ export class ProviderResourceTypesImpl implements ProviderResourceTypes { */ list( resourceProviderNamespace: string, - options?: ProviderResourceTypesListOptionalParams + options?: ProviderResourceTypesListOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceProviderNamespace, options }, - listOperationSpec + listOperationSpec, ); } } @@ -47,23 +47,22 @@ export class ProviderResourceTypesImpl implements ProviderResourceTypes { const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); const listOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/providers/{resourceProviderNamespace}/resourceTypes", + path: "/subscriptions/{subscriptionId}/providers/{resourceProviderNamespace}/resourceTypes", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.ProviderResourceTypeListResult + bodyMapper: Mappers.ProviderResourceTypeListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion, Parameters.expand], urlParameters: [ Parameters.$host, Parameters.subscriptionId, - Parameters.resourceProviderNamespace + Parameters.resourceProviderNamespace, ], headerParameters: [Parameters.accept], - serializer + serializer, }; diff --git a/sdk/resources/arm-resources/src/operations/providers.ts b/sdk/resources/arm-resources/src/operations/providers.ts index 3d1d40950154..6f146c8404bc 100644 --- a/sdk/resources/arm-resources/src/operations/providers.ts +++ b/sdk/resources/arm-resources/src/operations/providers.ts @@ -33,7 +33,7 @@ import { ProvidersGetAtTenantScopeOptionalParams, ProvidersGetAtTenantScopeResponse, ProvidersListNextResponse, - ProvidersListAtTenantScopeNextResponse + ProvidersListAtTenantScopeNextResponse, } from "../models"; /// @@ -54,7 +54,7 @@ export class ProvidersImpl implements Providers { * @param options The options parameters. */ public list( - options?: ProvidersListOptionalParams + options?: ProvidersListOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listPagingAll(options); return { @@ -69,13 +69,13 @@ export class ProvidersImpl implements Providers { throw new Error("maxPageSize is not supported by this operation."); } return this.listPagingPage(options, settings); - } + }, }; } private async *listPagingPage( options?: ProvidersListOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: ProvidersListResponse; let continuationToken = settings?.continuationToken; @@ -96,7 +96,7 @@ export class ProvidersImpl implements Providers { } private async *listPagingAll( - options?: ProvidersListOptionalParams + options?: ProvidersListOptionalParams, ): AsyncIterableIterator { for await (const page of this.listPagingPage(options)) { yield* page; @@ -108,7 +108,7 @@ export class ProvidersImpl implements Providers { * @param options The options parameters. */ public listAtTenantScope( - options?: ProvidersListAtTenantScopeOptionalParams + options?: ProvidersListAtTenantScopeOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listAtTenantScopePagingAll(options); return { @@ -123,13 +123,13 @@ export class ProvidersImpl implements Providers { throw new Error("maxPageSize is not supported by this operation."); } return this.listAtTenantScopePagingPage(options, settings); - } + }, }; } private async *listAtTenantScopePagingPage( options?: ProvidersListAtTenantScopeOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: ProvidersListAtTenantScopeResponse; let continuationToken = settings?.continuationToken; @@ -150,7 +150,7 @@ export class ProvidersImpl implements Providers { } private async *listAtTenantScopePagingAll( - options?: ProvidersListAtTenantScopeOptionalParams + options?: ProvidersListAtTenantScopeOptionalParams, ): AsyncIterableIterator { for await (const page of this.listAtTenantScopePagingPage(options)) { yield* page; @@ -164,16 +164,19 @@ export class ProvidersImpl implements Providers { */ unregister( resourceProviderNamespace: string, - options?: ProvidersUnregisterOptionalParams + options?: ProvidersUnregisterOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceProviderNamespace, options }, - unregisterOperationSpec + unregisterOperationSpec, ); } /** - * Registers a management group with a resource provider. + * Registers a management group with a resource provider. Use this operation to register a resource + * provider with resource types that can be deployed at the management group scope. It does not + * recursively register subscriptions within the management group. Instead, you must register + * subscriptions individually. * @param resourceProviderNamespace The namespace of the resource provider to register. * @param groupId The management group ID. * @param options The options parameters. @@ -181,11 +184,11 @@ export class ProvidersImpl implements Providers { registerAtManagementGroupScope( resourceProviderNamespace: string, groupId: string, - options?: ProvidersRegisterAtManagementGroupScopeOptionalParams + options?: ProvidersRegisterAtManagementGroupScopeOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceProviderNamespace, groupId, options }, - registerAtManagementGroupScopeOperationSpec + registerAtManagementGroupScopeOperationSpec, ); } @@ -196,11 +199,11 @@ export class ProvidersImpl implements Providers { */ providerPermissions( resourceProviderNamespace: string, - options?: ProvidersProviderPermissionsOptionalParams + options?: ProvidersProviderPermissionsOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceProviderNamespace, options }, - providerPermissionsOperationSpec + providerPermissionsOperationSpec, ); } @@ -211,11 +214,11 @@ export class ProvidersImpl implements Providers { */ register( resourceProviderNamespace: string, - options?: ProvidersRegisterOptionalParams + options?: ProvidersRegisterOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceProviderNamespace, options }, - registerOperationSpec + registerOperationSpec, ); } @@ -224,7 +227,7 @@ export class ProvidersImpl implements Providers { * @param options The options parameters. */ private _list( - options?: ProvidersListOptionalParams + options?: ProvidersListOptionalParams, ): Promise { return this.client.sendOperationRequest({ options }, listOperationSpec); } @@ -234,11 +237,11 @@ export class ProvidersImpl implements Providers { * @param options The options parameters. */ private _listAtTenantScope( - options?: ProvidersListAtTenantScopeOptionalParams + options?: ProvidersListAtTenantScopeOptionalParams, ): Promise { return this.client.sendOperationRequest( { options }, - listAtTenantScopeOperationSpec + listAtTenantScopeOperationSpec, ); } @@ -249,11 +252,11 @@ export class ProvidersImpl implements Providers { */ get( resourceProviderNamespace: string, - options?: ProvidersGetOptionalParams + options?: ProvidersGetOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceProviderNamespace, options }, - getOperationSpec + getOperationSpec, ); } @@ -264,11 +267,11 @@ export class ProvidersImpl implements Providers { */ getAtTenantScope( resourceProviderNamespace: string, - options?: ProvidersGetAtTenantScopeOptionalParams + options?: ProvidersGetAtTenantScopeOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceProviderNamespace, options }, - getAtTenantScopeOperationSpec + getAtTenantScopeOperationSpec, ); } @@ -279,11 +282,11 @@ export class ProvidersImpl implements Providers { */ private _listNext( nextLink: string, - options?: ProvidersListNextOptionalParams + options?: ProvidersListNextOptionalParams, ): Promise { return this.client.sendOperationRequest( { nextLink, options }, - listNextOperationSpec + listNextOperationSpec, ); } @@ -294,11 +297,11 @@ export class ProvidersImpl implements Providers { */ private _listAtTenantScopeNext( nextLink: string, - options?: ProvidersListAtTenantScopeNextOptionalParams + options?: ProvidersListAtTenantScopeNextOptionalParams, ): Promise { return this.client.sendOperationRequest( { nextLink, options }, - listAtTenantScopeNextOperationSpec + listAtTenantScopeNextOperationSpec, ); } } @@ -306,188 +309,184 @@ export class ProvidersImpl implements Providers { const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); const unregisterOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/providers/{resourceProviderNamespace}/unregister", + path: "/subscriptions/{subscriptionId}/providers/{resourceProviderNamespace}/unregister", httpMethod: "POST", responses: { 200: { - bodyMapper: Mappers.Provider + bodyMapper: Mappers.Provider, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, - Parameters.resourceProviderNamespace + Parameters.resourceProviderNamespace, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const registerAtManagementGroupScopeOperationSpec: coreClient.OperationSpec = { - path: - "/providers/Microsoft.Management/managementGroups/{groupId}/providers/{resourceProviderNamespace}/register", + path: "/providers/Microsoft.Management/managementGroups/{groupId}/providers/{resourceProviderNamespace}/register", httpMethod: "POST", responses: { 200: {}, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.groupId, - Parameters.resourceProviderNamespace + Parameters.resourceProviderNamespace, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const providerPermissionsOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/providers/{resourceProviderNamespace}/providerPermissions", + path: "/subscriptions/{subscriptionId}/providers/{resourceProviderNamespace}/providerPermissions", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.ProviderPermissionListResult + bodyMapper: Mappers.ProviderPermissionListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, - Parameters.resourceProviderNamespace + Parameters.resourceProviderNamespace, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const registerOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/providers/{resourceProviderNamespace}/register", + path: "/subscriptions/{subscriptionId}/providers/{resourceProviderNamespace}/register", httpMethod: "POST", responses: { 200: { - bodyMapper: Mappers.Provider + bodyMapper: Mappers.Provider, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, requestBody: Parameters.properties, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, - Parameters.resourceProviderNamespace + Parameters.resourceProviderNamespace, ], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", - serializer + serializer, }; const listOperationSpec: coreClient.OperationSpec = { path: "/subscriptions/{subscriptionId}/providers", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.ProviderListResult + bodyMapper: Mappers.ProviderListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion, Parameters.expand], urlParameters: [Parameters.$host, Parameters.subscriptionId], headerParameters: [Parameters.accept], - serializer + serializer, }; const listAtTenantScopeOperationSpec: coreClient.OperationSpec = { path: "/providers", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.ProviderListResult + bodyMapper: Mappers.ProviderListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion, Parameters.expand], urlParameters: [Parameters.$host], headerParameters: [Parameters.accept], - serializer + serializer, }; const getOperationSpec: coreClient.OperationSpec = { path: "/subscriptions/{subscriptionId}/providers/{resourceProviderNamespace}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.Provider + bodyMapper: Mappers.Provider, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion, Parameters.expand], urlParameters: [ Parameters.$host, Parameters.subscriptionId, - Parameters.resourceProviderNamespace + Parameters.resourceProviderNamespace, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const getAtTenantScopeOperationSpec: coreClient.OperationSpec = { path: "/providers/{resourceProviderNamespace}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.Provider + bodyMapper: Mappers.Provider, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion, Parameters.expand], urlParameters: [Parameters.$host, Parameters.resourceProviderNamespace], headerParameters: [Parameters.accept], - serializer + serializer, }; const listNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.ProviderListResult + bodyMapper: Mappers.ProviderListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, urlParameters: [ Parameters.$host, Parameters.nextLink, - Parameters.subscriptionId + Parameters.subscriptionId, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const listAtTenantScopeNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.ProviderListResult + bodyMapper: Mappers.ProviderListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, urlParameters: [Parameters.$host, Parameters.nextLink], headerParameters: [Parameters.accept], - serializer + serializer, }; diff --git a/sdk/resources/arm-resources/src/operations/resourceGroups.ts b/sdk/resources/arm-resources/src/operations/resourceGroups.ts index 4550f443c26d..b987724988b0 100644 --- a/sdk/resources/arm-resources/src/operations/resourceGroups.ts +++ b/sdk/resources/arm-resources/src/operations/resourceGroups.ts @@ -16,7 +16,7 @@ import { ResourceManagementClient } from "../resourceManagementClient"; import { SimplePollerLike, OperationState, - createHttpPoller + createHttpPoller, } from "@azure/core-lro"; import { createLroSpec } from "../lroImpl"; import { @@ -37,7 +37,7 @@ import { ExportTemplateRequest, ResourceGroupsExportTemplateOptionalParams, ResourceGroupsExportTemplateResponse, - ResourceGroupsListNextResponse + ResourceGroupsListNextResponse, } from "../models"; /// @@ -58,7 +58,7 @@ export class ResourceGroupsImpl implements ResourceGroups { * @param options The options parameters. */ public list( - options?: ResourceGroupsListOptionalParams + options?: ResourceGroupsListOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listPagingAll(options); return { @@ -73,13 +73,13 @@ export class ResourceGroupsImpl implements ResourceGroups { throw new Error("maxPageSize is not supported by this operation."); } return this.listPagingPage(options, settings); - } + }, }; } private async *listPagingPage( options?: ResourceGroupsListOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: ResourceGroupsListResponse; let continuationToken = settings?.continuationToken; @@ -100,7 +100,7 @@ export class ResourceGroupsImpl implements ResourceGroups { } private async *listPagingAll( - options?: ResourceGroupsListOptionalParams + options?: ResourceGroupsListOptionalParams, ): AsyncIterableIterator { for await (const page of this.listPagingPage(options)) { yield* page; @@ -114,11 +114,11 @@ export class ResourceGroupsImpl implements ResourceGroups { */ checkExistence( resourceGroupName: string, - options?: ResourceGroupsCheckExistenceOptionalParams + options?: ResourceGroupsCheckExistenceOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceGroupName, options }, - checkExistenceOperationSpec + checkExistenceOperationSpec, ); } @@ -133,11 +133,11 @@ export class ResourceGroupsImpl implements ResourceGroups { createOrUpdate( resourceGroupName: string, parameters: ResourceGroup, - options?: ResourceGroupsCreateOrUpdateOptionalParams + options?: ResourceGroupsCreateOrUpdateOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceGroupName, parameters, options }, - createOrUpdateOperationSpec + createOrUpdateOperationSpec, ); } @@ -149,25 +149,24 @@ export class ResourceGroupsImpl implements ResourceGroups { */ async beginDelete( resourceGroupName: string, - options?: ResourceGroupsDeleteOptionalParams + options?: ResourceGroupsDeleteOptionalParams, ): Promise, void>> { const directSendOperation = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ): Promise => { return this.client.sendOperationRequest(args, spec); }; const sendOperationFn = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; + let currentRawResponse: coreClient.FullOperationResponse | undefined = + undefined; const providedCallback = args.options?.onResponse; const callback: coreClient.RawResponseCallback = ( rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown + flatResponse: unknown, ) => { currentRawResponse = rawResponse; providedCallback?.(rawResponse, flatResponse); @@ -176,8 +175,8 @@ export class ResourceGroupsImpl implements ResourceGroups { ...args, options: { ...args.options, - onResponse: callback - } + onResponse: callback, + }, }; const flatResponse = await directSendOperation(updatedArgs, spec); return { @@ -185,19 +184,19 @@ export class ResourceGroupsImpl implements ResourceGroups { rawResponse: { statusCode: currentRawResponse!.status, body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } + headers: currentRawResponse!.headers.toJSON(), + }, }; }; const lro = createLroSpec({ sendOperationFn, args: { resourceGroupName, options }, - spec: deleteOperationSpec + spec: deleteOperationSpec, }); const poller = await createHttpPoller>(lro, { restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs + intervalInMs: options?.updateIntervalInMs, }); await poller.poll(); return poller; @@ -211,7 +210,7 @@ export class ResourceGroupsImpl implements ResourceGroups { */ async beginDeleteAndWait( resourceGroupName: string, - options?: ResourceGroupsDeleteOptionalParams + options?: ResourceGroupsDeleteOptionalParams, ): Promise { const poller = await this.beginDelete(resourceGroupName, options); return poller.pollUntilDone(); @@ -224,11 +223,11 @@ export class ResourceGroupsImpl implements ResourceGroups { */ get( resourceGroupName: string, - options?: ResourceGroupsGetOptionalParams + options?: ResourceGroupsGetOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceGroupName, options }, - getOperationSpec + getOperationSpec, ); } @@ -243,11 +242,11 @@ export class ResourceGroupsImpl implements ResourceGroups { update( resourceGroupName: string, parameters: ResourceGroupPatchable, - options?: ResourceGroupsUpdateOptionalParams + options?: ResourceGroupsUpdateOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceGroupName, parameters, options }, - updateOperationSpec + updateOperationSpec, ); } @@ -260,7 +259,7 @@ export class ResourceGroupsImpl implements ResourceGroups { async beginExportTemplate( resourceGroupName: string, parameters: ExportTemplateRequest, - options?: ResourceGroupsExportTemplateOptionalParams + options?: ResourceGroupsExportTemplateOptionalParams, ): Promise< SimplePollerLike< OperationState, @@ -269,21 +268,20 @@ export class ResourceGroupsImpl implements ResourceGroups { > { const directSendOperation = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ): Promise => { return this.client.sendOperationRequest(args, spec); }; const sendOperationFn = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; + let currentRawResponse: coreClient.FullOperationResponse | undefined = + undefined; const providedCallback = args.options?.onResponse; const callback: coreClient.RawResponseCallback = ( rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown + flatResponse: unknown, ) => { currentRawResponse = rawResponse; providedCallback?.(rawResponse, flatResponse); @@ -292,8 +290,8 @@ export class ResourceGroupsImpl implements ResourceGroups { ...args, options: { ...args.options, - onResponse: callback - } + onResponse: callback, + }, }; const flatResponse = await directSendOperation(updatedArgs, spec); return { @@ -301,15 +299,15 @@ export class ResourceGroupsImpl implements ResourceGroups { rawResponse: { statusCode: currentRawResponse!.status, body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } + headers: currentRawResponse!.headers.toJSON(), + }, }; }; const lro = createLroSpec({ sendOperationFn, args: { resourceGroupName, parameters, options }, - spec: exportTemplateOperationSpec + spec: exportTemplateOperationSpec, }); const poller = await createHttpPoller< ResourceGroupsExportTemplateResponse, @@ -317,7 +315,7 @@ export class ResourceGroupsImpl implements ResourceGroups { >(lro, { restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs, - resourceLocationConfig: "location" + resourceLocationConfig: "location", }); await poller.poll(); return poller; @@ -332,12 +330,12 @@ export class ResourceGroupsImpl implements ResourceGroups { async beginExportTemplateAndWait( resourceGroupName: string, parameters: ExportTemplateRequest, - options?: ResourceGroupsExportTemplateOptionalParams + options?: ResourceGroupsExportTemplateOptionalParams, ): Promise { const poller = await this.beginExportTemplate( resourceGroupName, parameters, - options + options, ); return poller.pollUntilDone(); } @@ -347,7 +345,7 @@ export class ResourceGroupsImpl implements ResourceGroups { * @param options The options parameters. */ private _list( - options?: ResourceGroupsListOptionalParams + options?: ResourceGroupsListOptionalParams, ): Promise { return this.client.sendOperationRequest({ options }, listOperationSpec); } @@ -359,11 +357,11 @@ export class ResourceGroupsImpl implements ResourceGroups { */ private _listNext( nextLink: string, - options?: ResourceGroupsListNextOptionalParams + options?: ResourceGroupsListNextOptionalParams, ): Promise { return this.client.sendOperationRequest( { nextLink, options }, - listNextOperationSpec + listNextOperationSpec, ); } } @@ -377,42 +375,42 @@ const checkExistenceOperationSpec: coreClient.OperationSpec = { 204: {}, 404: {}, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, - Parameters.resourceGroupName + Parameters.resourceGroupName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const createOrUpdateOperationSpec: coreClient.OperationSpec = { path: "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}", httpMethod: "PUT", responses: { 200: { - bodyMapper: Mappers.ResourceGroup + bodyMapper: Mappers.ResourceGroup, }, 201: { - bodyMapper: Mappers.ResourceGroup + bodyMapper: Mappers.ResourceGroup, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, requestBody: Parameters.parameters6, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, - Parameters.resourceGroupName + Parameters.resourceGroupName, ], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", - serializer + serializer, }; const deleteOperationSpec: coreClient.OperationSpec = { path: "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}", @@ -423,124 +421,123 @@ const deleteOperationSpec: coreClient.OperationSpec = { 202: {}, 204: {}, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion, Parameters.forceDeletionTypes], urlParameters: [ Parameters.$host, Parameters.subscriptionId, - Parameters.resourceGroupName + Parameters.resourceGroupName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const getOperationSpec: coreClient.OperationSpec = { path: "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.ResourceGroup + bodyMapper: Mappers.ResourceGroup, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, - Parameters.resourceGroupName + Parameters.resourceGroupName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const updateOperationSpec: coreClient.OperationSpec = { path: "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}", httpMethod: "PATCH", responses: { 200: { - bodyMapper: Mappers.ResourceGroup + bodyMapper: Mappers.ResourceGroup, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, requestBody: Parameters.parameters7, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, - Parameters.resourceGroupName + Parameters.resourceGroupName, ], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", - serializer + serializer, }; const exportTemplateOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/exportTemplate", + path: "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/exportTemplate", httpMethod: "POST", responses: { 200: { - bodyMapper: Mappers.ResourceGroupExportResult + bodyMapper: Mappers.ResourceGroupExportResult, }, 201: { - bodyMapper: Mappers.ResourceGroupExportResult + bodyMapper: Mappers.ResourceGroupExportResult, }, 202: { - bodyMapper: Mappers.ResourceGroupExportResult + bodyMapper: Mappers.ResourceGroupExportResult, }, 204: { - bodyMapper: Mappers.ResourceGroupExportResult + bodyMapper: Mappers.ResourceGroupExportResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, requestBody: Parameters.parameters8, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, - Parameters.resourceGroupName1 + Parameters.resourceGroupName1, ], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", - serializer + serializer, }; const listOperationSpec: coreClient.OperationSpec = { path: "/subscriptions/{subscriptionId}/resourcegroups", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.ResourceGroupListResult + bodyMapper: Mappers.ResourceGroupListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion, Parameters.filter, Parameters.top], urlParameters: [Parameters.$host, Parameters.subscriptionId], headerParameters: [Parameters.accept], - serializer + serializer, }; const listNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.ResourceGroupListResult + bodyMapper: Mappers.ResourceGroupListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, urlParameters: [ Parameters.$host, Parameters.nextLink, - Parameters.subscriptionId + Parameters.subscriptionId, ], headerParameters: [Parameters.accept], - serializer + serializer, }; diff --git a/sdk/resources/arm-resources/src/operations/resources.ts b/sdk/resources/arm-resources/src/operations/resources.ts index 71347bd79aaf..97bd2b8b970d 100644 --- a/sdk/resources/arm-resources/src/operations/resources.ts +++ b/sdk/resources/arm-resources/src/operations/resources.ts @@ -16,7 +16,7 @@ import { ResourceManagementClient } from "../resourceManagementClient"; import { SimplePollerLike, OperationState, - createHttpPoller + createHttpPoller, } from "@azure/core-lro"; import { createLroSpec } from "../lroImpl"; import { @@ -50,7 +50,7 @@ import { ResourcesGetByIdOptionalParams, ResourcesGetByIdResponse, ResourcesListByResourceGroupNextResponse, - ResourcesListNextResponse + ResourcesListNextResponse, } from "../models"; /// @@ -73,7 +73,7 @@ export class ResourcesImpl implements Resources { */ public listByResourceGroup( resourceGroupName: string, - options?: ResourcesListByResourceGroupOptionalParams + options?: ResourcesListByResourceGroupOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listByResourceGroupPagingAll(resourceGroupName, options); return { @@ -90,16 +90,16 @@ export class ResourcesImpl implements Resources { return this.listByResourceGroupPagingPage( resourceGroupName, options, - settings + settings, ); - } + }, }; } private async *listByResourceGroupPagingPage( resourceGroupName: string, options?: ResourcesListByResourceGroupOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: ResourcesListByResourceGroupResponse; let continuationToken = settings?.continuationToken; @@ -114,7 +114,7 @@ export class ResourcesImpl implements Resources { result = await this._listByResourceGroupNext( resourceGroupName, continuationToken, - options + options, ); continuationToken = result.nextLink; let page = result.value || []; @@ -125,11 +125,11 @@ export class ResourcesImpl implements Resources { private async *listByResourceGroupPagingAll( resourceGroupName: string, - options?: ResourcesListByResourceGroupOptionalParams + options?: ResourcesListByResourceGroupOptionalParams, ): AsyncIterableIterator { for await (const page of this.listByResourceGroupPagingPage( resourceGroupName, - options + options, )) { yield* page; } @@ -140,7 +140,7 @@ export class ResourcesImpl implements Resources { * @param options The options parameters. */ public list( - options?: ResourcesListOptionalParams + options?: ResourcesListOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listPagingAll(options); return { @@ -155,13 +155,13 @@ export class ResourcesImpl implements Resources { throw new Error("maxPageSize is not supported by this operation."); } return this.listPagingPage(options, settings); - } + }, }; } private async *listPagingPage( options?: ResourcesListOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: ResourcesListResponse; let continuationToken = settings?.continuationToken; @@ -182,7 +182,7 @@ export class ResourcesImpl implements Resources { } private async *listPagingAll( - options?: ResourcesListOptionalParams + options?: ResourcesListOptionalParams, ): AsyncIterableIterator { for await (const page of this.listPagingPage(options)) { yield* page; @@ -196,11 +196,11 @@ export class ResourcesImpl implements Resources { */ private _listByResourceGroup( resourceGroupName: string, - options?: ResourcesListByResourceGroupOptionalParams + options?: ResourcesListByResourceGroupOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceGroupName, options }, - listByResourceGroupOperationSpec + listByResourceGroupOperationSpec, ); } @@ -217,25 +217,24 @@ export class ResourcesImpl implements Resources { async beginMoveResources( sourceResourceGroupName: string, parameters: ResourcesMoveInfo, - options?: ResourcesMoveResourcesOptionalParams + options?: ResourcesMoveResourcesOptionalParams, ): Promise, void>> { const directSendOperation = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ): Promise => { return this.client.sendOperationRequest(args, spec); }; const sendOperationFn = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; + let currentRawResponse: coreClient.FullOperationResponse | undefined = + undefined; const providedCallback = args.options?.onResponse; const callback: coreClient.RawResponseCallback = ( rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown + flatResponse: unknown, ) => { currentRawResponse = rawResponse; providedCallback?.(rawResponse, flatResponse); @@ -244,8 +243,8 @@ export class ResourcesImpl implements Resources { ...args, options: { ...args.options, - onResponse: callback - } + onResponse: callback, + }, }; const flatResponse = await directSendOperation(updatedArgs, spec); return { @@ -253,19 +252,19 @@ export class ResourcesImpl implements Resources { rawResponse: { statusCode: currentRawResponse!.status, body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } + headers: currentRawResponse!.headers.toJSON(), + }, }; }; const lro = createLroSpec({ sendOperationFn, args: { sourceResourceGroupName, parameters, options }, - spec: moveResourcesOperationSpec + spec: moveResourcesOperationSpec, }); const poller = await createHttpPoller>(lro, { restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs + intervalInMs: options?.updateIntervalInMs, }); await poller.poll(); return poller; @@ -284,12 +283,12 @@ export class ResourcesImpl implements Resources { async beginMoveResourcesAndWait( sourceResourceGroupName: string, parameters: ResourcesMoveInfo, - options?: ResourcesMoveResourcesOptionalParams + options?: ResourcesMoveResourcesOptionalParams, ): Promise { const poller = await this.beginMoveResources( sourceResourceGroupName, parameters, - options + options, ); return poller.pollUntilDone(); } @@ -309,25 +308,24 @@ export class ResourcesImpl implements Resources { async beginValidateMoveResources( sourceResourceGroupName: string, parameters: ResourcesMoveInfo, - options?: ResourcesValidateMoveResourcesOptionalParams + options?: ResourcesValidateMoveResourcesOptionalParams, ): Promise, void>> { const directSendOperation = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ): Promise => { return this.client.sendOperationRequest(args, spec); }; const sendOperationFn = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; + let currentRawResponse: coreClient.FullOperationResponse | undefined = + undefined; const providedCallback = args.options?.onResponse; const callback: coreClient.RawResponseCallback = ( rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown + flatResponse: unknown, ) => { currentRawResponse = rawResponse; providedCallback?.(rawResponse, flatResponse); @@ -336,8 +334,8 @@ export class ResourcesImpl implements Resources { ...args, options: { ...args.options, - onResponse: callback - } + onResponse: callback, + }, }; const flatResponse = await directSendOperation(updatedArgs, spec); return { @@ -345,19 +343,19 @@ export class ResourcesImpl implements Resources { rawResponse: { statusCode: currentRawResponse!.status, body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } + headers: currentRawResponse!.headers.toJSON(), + }, }; }; const lro = createLroSpec({ sendOperationFn, args: { sourceResourceGroupName, parameters, options }, - spec: validateMoveResourcesOperationSpec + spec: validateMoveResourcesOperationSpec, }); const poller = await createHttpPoller>(lro, { restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs + intervalInMs: options?.updateIntervalInMs, }); await poller.poll(); return poller; @@ -378,12 +376,12 @@ export class ResourcesImpl implements Resources { async beginValidateMoveResourcesAndWait( sourceResourceGroupName: string, parameters: ResourcesMoveInfo, - options?: ResourcesValidateMoveResourcesOptionalParams + options?: ResourcesValidateMoveResourcesOptionalParams, ): Promise { const poller = await this.beginValidateMoveResources( sourceResourceGroupName, parameters, - options + options, ); return poller.pollUntilDone(); } @@ -393,7 +391,7 @@ export class ResourcesImpl implements Resources { * @param options The options parameters. */ private _list( - options?: ResourcesListOptionalParams + options?: ResourcesListOptionalParams, ): Promise { return this.client.sendOperationRequest({ options }, listOperationSpec); } @@ -416,7 +414,7 @@ export class ResourcesImpl implements Resources { resourceType: string, resourceName: string, apiVersion: string, - options?: ResourcesCheckExistenceOptionalParams + options?: ResourcesCheckExistenceOptionalParams, ): Promise { return this.client.sendOperationRequest( { @@ -426,9 +424,9 @@ export class ResourcesImpl implements Resources { resourceType, resourceName, apiVersion, - options + options, }, - checkExistenceOperationSpec + checkExistenceOperationSpec, ); } @@ -450,25 +448,24 @@ export class ResourcesImpl implements Resources { resourceType: string, resourceName: string, apiVersion: string, - options?: ResourcesDeleteOptionalParams + options?: ResourcesDeleteOptionalParams, ): Promise, void>> { const directSendOperation = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ): Promise => { return this.client.sendOperationRequest(args, spec); }; const sendOperationFn = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; + let currentRawResponse: coreClient.FullOperationResponse | undefined = + undefined; const providedCallback = args.options?.onResponse; const callback: coreClient.RawResponseCallback = ( rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown + flatResponse: unknown, ) => { currentRawResponse = rawResponse; providedCallback?.(rawResponse, flatResponse); @@ -477,8 +474,8 @@ export class ResourcesImpl implements Resources { ...args, options: { ...args.options, - onResponse: callback - } + onResponse: callback, + }, }; const flatResponse = await directSendOperation(updatedArgs, spec); return { @@ -486,8 +483,8 @@ export class ResourcesImpl implements Resources { rawResponse: { statusCode: currentRawResponse!.status, body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } + headers: currentRawResponse!.headers.toJSON(), + }, }; }; @@ -500,13 +497,13 @@ export class ResourcesImpl implements Resources { resourceType, resourceName, apiVersion, - options + options, }, - spec: deleteOperationSpec + spec: deleteOperationSpec, }); const poller = await createHttpPoller>(lro, { restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs + intervalInMs: options?.updateIntervalInMs, }); await poller.poll(); return poller; @@ -530,7 +527,7 @@ export class ResourcesImpl implements Resources { resourceType: string, resourceName: string, apiVersion: string, - options?: ResourcesDeleteOptionalParams + options?: ResourcesDeleteOptionalParams, ): Promise { const poller = await this.beginDelete( resourceGroupName, @@ -539,7 +536,7 @@ export class ResourcesImpl implements Resources { resourceType, resourceName, apiVersion, - options + options, ); return poller.pollUntilDone(); } @@ -564,7 +561,7 @@ export class ResourcesImpl implements Resources { resourceName: string, apiVersion: string, parameters: GenericResource, - options?: ResourcesCreateOrUpdateOptionalParams + options?: ResourcesCreateOrUpdateOptionalParams, ): Promise< SimplePollerLike< OperationState, @@ -573,21 +570,20 @@ export class ResourcesImpl implements Resources { > { const directSendOperation = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ): Promise => { return this.client.sendOperationRequest(args, spec); }; const sendOperationFn = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; + let currentRawResponse: coreClient.FullOperationResponse | undefined = + undefined; const providedCallback = args.options?.onResponse; const callback: coreClient.RawResponseCallback = ( rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown + flatResponse: unknown, ) => { currentRawResponse = rawResponse; providedCallback?.(rawResponse, flatResponse); @@ -596,8 +592,8 @@ export class ResourcesImpl implements Resources { ...args, options: { ...args.options, - onResponse: callback - } + onResponse: callback, + }, }; const flatResponse = await directSendOperation(updatedArgs, spec); return { @@ -605,8 +601,8 @@ export class ResourcesImpl implements Resources { rawResponse: { statusCode: currentRawResponse!.status, body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } + headers: currentRawResponse!.headers.toJSON(), + }, }; }; @@ -620,16 +616,16 @@ export class ResourcesImpl implements Resources { resourceName, apiVersion, parameters, - options + options, }, - spec: createOrUpdateOperationSpec + spec: createOrUpdateOperationSpec, }); const poller = await createHttpPoller< ResourcesCreateOrUpdateResponse, OperationState >(lro, { restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs + intervalInMs: options?.updateIntervalInMs, }); await poller.poll(); return poller; @@ -655,7 +651,7 @@ export class ResourcesImpl implements Resources { resourceName: string, apiVersion: string, parameters: GenericResource, - options?: ResourcesCreateOrUpdateOptionalParams + options?: ResourcesCreateOrUpdateOptionalParams, ): Promise { const poller = await this.beginCreateOrUpdate( resourceGroupName, @@ -665,7 +661,7 @@ export class ResourcesImpl implements Resources { resourceName, apiVersion, parameters, - options + options, ); return poller.pollUntilDone(); } @@ -690,7 +686,7 @@ export class ResourcesImpl implements Resources { resourceName: string, apiVersion: string, parameters: GenericResource, - options?: ResourcesUpdateOptionalParams + options?: ResourcesUpdateOptionalParams, ): Promise< SimplePollerLike< OperationState, @@ -699,21 +695,20 @@ export class ResourcesImpl implements Resources { > { const directSendOperation = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ): Promise => { return this.client.sendOperationRequest(args, spec); }; const sendOperationFn = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; + let currentRawResponse: coreClient.FullOperationResponse | undefined = + undefined; const providedCallback = args.options?.onResponse; const callback: coreClient.RawResponseCallback = ( rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown + flatResponse: unknown, ) => { currentRawResponse = rawResponse; providedCallback?.(rawResponse, flatResponse); @@ -722,8 +717,8 @@ export class ResourcesImpl implements Resources { ...args, options: { ...args.options, - onResponse: callback - } + onResponse: callback, + }, }; const flatResponse = await directSendOperation(updatedArgs, spec); return { @@ -731,8 +726,8 @@ export class ResourcesImpl implements Resources { rawResponse: { statusCode: currentRawResponse!.status, body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } + headers: currentRawResponse!.headers.toJSON(), + }, }; }; @@ -746,16 +741,16 @@ export class ResourcesImpl implements Resources { resourceName, apiVersion, parameters, - options + options, }, - spec: updateOperationSpec + spec: updateOperationSpec, }); const poller = await createHttpPoller< ResourcesUpdateResponse, OperationState >(lro, { restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs + intervalInMs: options?.updateIntervalInMs, }); await poller.poll(); return poller; @@ -781,7 +776,7 @@ export class ResourcesImpl implements Resources { resourceName: string, apiVersion: string, parameters: GenericResource, - options?: ResourcesUpdateOptionalParams + options?: ResourcesUpdateOptionalParams, ): Promise { const poller = await this.beginUpdate( resourceGroupName, @@ -791,7 +786,7 @@ export class ResourcesImpl implements Resources { resourceName, apiVersion, parameters, - options + options, ); return poller.pollUntilDone(); } @@ -814,7 +809,7 @@ export class ResourcesImpl implements Resources { resourceType: string, resourceName: string, apiVersion: string, - options?: ResourcesGetOptionalParams + options?: ResourcesGetOptionalParams, ): Promise { return this.client.sendOperationRequest( { @@ -824,14 +819,16 @@ export class ResourcesImpl implements Resources { resourceType, resourceName, apiVersion, - options + options, }, - getOperationSpec + getOperationSpec, ); } /** - * Checks by ID whether a resource exists. + * Checks by ID whether a resource exists. This API currently works only for a limited set of Resource + * providers. In the event that a Resource provider does not implement this API, ARM will respond with + * a 405. The alternative then is to use the GET API to check for the existence of the resource. * @param resourceId The fully qualified ID of the resource, including the resource name and resource * type. Use the format, * /subscriptions/{guid}/resourceGroups/{resource-group-name}/{resource-provider-namespace}/{resource-type}/{resource-name} @@ -841,11 +838,11 @@ export class ResourcesImpl implements Resources { checkExistenceById( resourceId: string, apiVersion: string, - options?: ResourcesCheckExistenceByIdOptionalParams + options?: ResourcesCheckExistenceByIdOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceId, apiVersion, options }, - checkExistenceByIdOperationSpec + checkExistenceByIdOperationSpec, ); } @@ -860,25 +857,24 @@ export class ResourcesImpl implements Resources { async beginDeleteById( resourceId: string, apiVersion: string, - options?: ResourcesDeleteByIdOptionalParams + options?: ResourcesDeleteByIdOptionalParams, ): Promise, void>> { const directSendOperation = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ): Promise => { return this.client.sendOperationRequest(args, spec); }; const sendOperationFn = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; + let currentRawResponse: coreClient.FullOperationResponse | undefined = + undefined; const providedCallback = args.options?.onResponse; const callback: coreClient.RawResponseCallback = ( rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown + flatResponse: unknown, ) => { currentRawResponse = rawResponse; providedCallback?.(rawResponse, flatResponse); @@ -887,8 +883,8 @@ export class ResourcesImpl implements Resources { ...args, options: { ...args.options, - onResponse: callback - } + onResponse: callback, + }, }; const flatResponse = await directSendOperation(updatedArgs, spec); return { @@ -896,19 +892,19 @@ export class ResourcesImpl implements Resources { rawResponse: { statusCode: currentRawResponse!.status, body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } + headers: currentRawResponse!.headers.toJSON(), + }, }; }; const lro = createLroSpec({ sendOperationFn, args: { resourceId, apiVersion, options }, - spec: deleteByIdOperationSpec + spec: deleteByIdOperationSpec, }); const poller = await createHttpPoller>(lro, { restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs + intervalInMs: options?.updateIntervalInMs, }); await poller.poll(); return poller; @@ -925,7 +921,7 @@ export class ResourcesImpl implements Resources { async beginDeleteByIdAndWait( resourceId: string, apiVersion: string, - options?: ResourcesDeleteByIdOptionalParams + options?: ResourcesDeleteByIdOptionalParams, ): Promise { const poller = await this.beginDeleteById(resourceId, apiVersion, options); return poller.pollUntilDone(); @@ -944,7 +940,7 @@ export class ResourcesImpl implements Resources { resourceId: string, apiVersion: string, parameters: GenericResource, - options?: ResourcesCreateOrUpdateByIdOptionalParams + options?: ResourcesCreateOrUpdateByIdOptionalParams, ): Promise< SimplePollerLike< OperationState, @@ -953,21 +949,20 @@ export class ResourcesImpl implements Resources { > { const directSendOperation = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ): Promise => { return this.client.sendOperationRequest(args, spec); }; const sendOperationFn = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; + let currentRawResponse: coreClient.FullOperationResponse | undefined = + undefined; const providedCallback = args.options?.onResponse; const callback: coreClient.RawResponseCallback = ( rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown + flatResponse: unknown, ) => { currentRawResponse = rawResponse; providedCallback?.(rawResponse, flatResponse); @@ -976,8 +971,8 @@ export class ResourcesImpl implements Resources { ...args, options: { ...args.options, - onResponse: callback - } + onResponse: callback, + }, }; const flatResponse = await directSendOperation(updatedArgs, spec); return { @@ -985,22 +980,22 @@ export class ResourcesImpl implements Resources { rawResponse: { statusCode: currentRawResponse!.status, body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } + headers: currentRawResponse!.headers.toJSON(), + }, }; }; const lro = createLroSpec({ sendOperationFn, args: { resourceId, apiVersion, parameters, options }, - spec: createOrUpdateByIdOperationSpec + spec: createOrUpdateByIdOperationSpec, }); const poller = await createHttpPoller< ResourcesCreateOrUpdateByIdResponse, OperationState >(lro, { restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs + intervalInMs: options?.updateIntervalInMs, }); await poller.poll(); return poller; @@ -1019,13 +1014,13 @@ export class ResourcesImpl implements Resources { resourceId: string, apiVersion: string, parameters: GenericResource, - options?: ResourcesCreateOrUpdateByIdOptionalParams + options?: ResourcesCreateOrUpdateByIdOptionalParams, ): Promise { const poller = await this.beginCreateOrUpdateById( resourceId, apiVersion, parameters, - options + options, ); return poller.pollUntilDone(); } @@ -1043,7 +1038,7 @@ export class ResourcesImpl implements Resources { resourceId: string, apiVersion: string, parameters: GenericResource, - options?: ResourcesUpdateByIdOptionalParams + options?: ResourcesUpdateByIdOptionalParams, ): Promise< SimplePollerLike< OperationState, @@ -1052,21 +1047,20 @@ export class ResourcesImpl implements Resources { > { const directSendOperation = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ): Promise => { return this.client.sendOperationRequest(args, spec); }; const sendOperationFn = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; + let currentRawResponse: coreClient.FullOperationResponse | undefined = + undefined; const providedCallback = args.options?.onResponse; const callback: coreClient.RawResponseCallback = ( rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown + flatResponse: unknown, ) => { currentRawResponse = rawResponse; providedCallback?.(rawResponse, flatResponse); @@ -1075,8 +1069,8 @@ export class ResourcesImpl implements Resources { ...args, options: { ...args.options, - onResponse: callback - } + onResponse: callback, + }, }; const flatResponse = await directSendOperation(updatedArgs, spec); return { @@ -1084,22 +1078,22 @@ export class ResourcesImpl implements Resources { rawResponse: { statusCode: currentRawResponse!.status, body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } + headers: currentRawResponse!.headers.toJSON(), + }, }; }; const lro = createLroSpec({ sendOperationFn, args: { resourceId, apiVersion, parameters, options }, - spec: updateByIdOperationSpec + spec: updateByIdOperationSpec, }); const poller = await createHttpPoller< ResourcesUpdateByIdResponse, OperationState >(lro, { restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs + intervalInMs: options?.updateIntervalInMs, }); await poller.poll(); return poller; @@ -1118,13 +1112,13 @@ export class ResourcesImpl implements Resources { resourceId: string, apiVersion: string, parameters: GenericResource, - options?: ResourcesUpdateByIdOptionalParams + options?: ResourcesUpdateByIdOptionalParams, ): Promise { const poller = await this.beginUpdateById( resourceId, apiVersion, parameters, - options + options, ); return poller.pollUntilDone(); } @@ -1140,11 +1134,11 @@ export class ResourcesImpl implements Resources { getById( resourceId: string, apiVersion: string, - options?: ResourcesGetByIdOptionalParams + options?: ResourcesGetByIdOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceId, apiVersion, options }, - getByIdOperationSpec + getByIdOperationSpec, ); } @@ -1157,11 +1151,11 @@ export class ResourcesImpl implements Resources { private _listByResourceGroupNext( resourceGroupName: string, nextLink: string, - options?: ResourcesListByResourceGroupNextOptionalParams + options?: ResourcesListByResourceGroupNextOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceGroupName, nextLink, options }, - listByResourceGroupNextOperationSpec + listByResourceGroupNextOperationSpec, ); } @@ -1172,11 +1166,11 @@ export class ResourcesImpl implements Resources { */ private _listNext( nextLink: string, - options?: ResourcesListNextOptionalParams + options?: ResourcesListNextOptionalParams, ): Promise { return this.client.sendOperationRequest( { nextLink, options }, - listNextOperationSpec + listNextOperationSpec, ); } } @@ -1184,34 +1178,32 @@ export class ResourcesImpl implements Resources { const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); const listByResourceGroupOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/resources", + path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/resources", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.ResourceListResult + bodyMapper: Mappers.ResourceListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [ Parameters.apiVersion, Parameters.filter, Parameters.top, - Parameters.expand + Parameters.expand, ], urlParameters: [ Parameters.$host, Parameters.subscriptionId, - Parameters.resourceGroupName + Parameters.resourceGroupName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const moveResourcesOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{sourceResourceGroupName}/moveResources", + path: "/subscriptions/{subscriptionId}/resourceGroups/{sourceResourceGroupName}/moveResources", httpMethod: "POST", responses: { 200: {}, @@ -1219,23 +1211,22 @@ const moveResourcesOperationSpec: coreClient.OperationSpec = { 202: {}, 204: {}, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, requestBody: Parameters.parameters4, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, - Parameters.sourceResourceGroupName + Parameters.sourceResourceGroupName, ], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", - serializer + serializer, }; const validateMoveResourcesOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{sourceResourceGroupName}/validateMoveResources", + path: "/subscriptions/{subscriptionId}/resourceGroups/{sourceResourceGroupName}/validateMoveResources", httpMethod: "POST", responses: { 200: {}, @@ -1243,51 +1234,50 @@ const validateMoveResourcesOperationSpec: coreClient.OperationSpec = { 202: {}, 204: {}, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, requestBody: Parameters.parameters4, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, - Parameters.sourceResourceGroupName + Parameters.sourceResourceGroupName, ], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", - serializer + serializer, }; const listOperationSpec: coreClient.OperationSpec = { path: "/subscriptions/{subscriptionId}/resources", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.ResourceListResult + bodyMapper: Mappers.ResourceListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [ Parameters.apiVersion, Parameters.filter, Parameters.top, - Parameters.expand + Parameters.expand, ], urlParameters: [Parameters.$host, Parameters.subscriptionId], headerParameters: [Parameters.accept], - serializer + serializer, }; const checkExistenceOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{parentResourcePath}/{resourceType}/{resourceName}", + path: "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{parentResourcePath}/{resourceType}/{resourceName}", httpMethod: "HEAD", responses: { 204: {}, 404: {}, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion1], urlParameters: [ @@ -1297,14 +1287,13 @@ const checkExistenceOperationSpec: coreClient.OperationSpec = { Parameters.resourceProviderNamespace, Parameters.parentResourcePath, Parameters.resourceType, - Parameters.resourceName + Parameters.resourceName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const deleteOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{parentResourcePath}/{resourceType}/{resourceName}", + path: "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{parentResourcePath}/{resourceType}/{resourceName}", httpMethod: "DELETE", responses: { 200: {}, @@ -1312,8 +1301,8 @@ const deleteOperationSpec: coreClient.OperationSpec = { 202: {}, 204: {}, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion1], urlParameters: [ @@ -1323,31 +1312,30 @@ const deleteOperationSpec: coreClient.OperationSpec = { Parameters.resourceProviderNamespace, Parameters.parentResourcePath, Parameters.resourceType, - Parameters.resourceName + Parameters.resourceName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const createOrUpdateOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{parentResourcePath}/{resourceType}/{resourceName}", + path: "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{parentResourcePath}/{resourceType}/{resourceName}", httpMethod: "PUT", responses: { 200: { - bodyMapper: Mappers.GenericResource + bodyMapper: Mappers.GenericResource, }, 201: { - bodyMapper: Mappers.GenericResource + bodyMapper: Mappers.GenericResource, }, 202: { - bodyMapper: Mappers.GenericResource + bodyMapper: Mappers.GenericResource, }, 204: { - bodyMapper: Mappers.GenericResource + bodyMapper: Mappers.GenericResource, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, requestBody: Parameters.parameters5, queryParameters: [Parameters.apiVersion1], @@ -1358,32 +1346,31 @@ const createOrUpdateOperationSpec: coreClient.OperationSpec = { Parameters.resourceProviderNamespace, Parameters.parentResourcePath, Parameters.resourceType, - Parameters.resourceName + Parameters.resourceName, ], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", - serializer + serializer, }; const updateOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{parentResourcePath}/{resourceType}/{resourceName}", + path: "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{parentResourcePath}/{resourceType}/{resourceName}", httpMethod: "PATCH", responses: { 200: { - bodyMapper: Mappers.GenericResource + bodyMapper: Mappers.GenericResource, }, 201: { - bodyMapper: Mappers.GenericResource + bodyMapper: Mappers.GenericResource, }, 202: { - bodyMapper: Mappers.GenericResource + bodyMapper: Mappers.GenericResource, }, 204: { - bodyMapper: Mappers.GenericResource + bodyMapper: Mappers.GenericResource, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, requestBody: Parameters.parameters5, queryParameters: [Parameters.apiVersion1], @@ -1394,23 +1381,22 @@ const updateOperationSpec: coreClient.OperationSpec = { Parameters.resourceProviderNamespace, Parameters.parentResourcePath, Parameters.resourceType, - Parameters.resourceName + Parameters.resourceName, ], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", - serializer + serializer, }; const getOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{parentResourcePath}/{resourceType}/{resourceName}", + path: "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{parentResourcePath}/{resourceType}/{resourceName}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.GenericResource + bodyMapper: Mappers.GenericResource, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion1], urlParameters: [ @@ -1420,10 +1406,10 @@ const getOperationSpec: coreClient.OperationSpec = { Parameters.resourceProviderNamespace, Parameters.parentResourcePath, Parameters.resourceType, - Parameters.resourceName + Parameters.resourceName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const checkExistenceByIdOperationSpec: coreClient.OperationSpec = { path: "/{resourceId}", @@ -1432,13 +1418,13 @@ const checkExistenceByIdOperationSpec: coreClient.OperationSpec = { 204: {}, 404: {}, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion1], urlParameters: [Parameters.$host, Parameters.resourceId], headerParameters: [Parameters.accept], - serializer + serializer, }; const deleteByIdOperationSpec: coreClient.OperationSpec = { path: "/{resourceId}", @@ -1449,120 +1435,120 @@ const deleteByIdOperationSpec: coreClient.OperationSpec = { 202: {}, 204: {}, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion1], urlParameters: [Parameters.$host, Parameters.resourceId], headerParameters: [Parameters.accept], - serializer + serializer, }; const createOrUpdateByIdOperationSpec: coreClient.OperationSpec = { path: "/{resourceId}", httpMethod: "PUT", responses: { 200: { - bodyMapper: Mappers.GenericResource + bodyMapper: Mappers.GenericResource, }, 201: { - bodyMapper: Mappers.GenericResource + bodyMapper: Mappers.GenericResource, }, 202: { - bodyMapper: Mappers.GenericResource + bodyMapper: Mappers.GenericResource, }, 204: { - bodyMapper: Mappers.GenericResource + bodyMapper: Mappers.GenericResource, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, requestBody: Parameters.parameters5, queryParameters: [Parameters.apiVersion1], urlParameters: [Parameters.$host, Parameters.resourceId], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", - serializer + serializer, }; const updateByIdOperationSpec: coreClient.OperationSpec = { path: "/{resourceId}", httpMethod: "PATCH", responses: { 200: { - bodyMapper: Mappers.GenericResource + bodyMapper: Mappers.GenericResource, }, 201: { - bodyMapper: Mappers.GenericResource + bodyMapper: Mappers.GenericResource, }, 202: { - bodyMapper: Mappers.GenericResource + bodyMapper: Mappers.GenericResource, }, 204: { - bodyMapper: Mappers.GenericResource + bodyMapper: Mappers.GenericResource, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, requestBody: Parameters.parameters5, queryParameters: [Parameters.apiVersion1], urlParameters: [Parameters.$host, Parameters.resourceId], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", - serializer + serializer, }; const getByIdOperationSpec: coreClient.OperationSpec = { path: "/{resourceId}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.GenericResource + bodyMapper: Mappers.GenericResource, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion1], urlParameters: [Parameters.$host, Parameters.resourceId], headerParameters: [Parameters.accept], - serializer + serializer, }; const listByResourceGroupNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.ResourceListResult + bodyMapper: Mappers.ResourceListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, urlParameters: [ Parameters.$host, Parameters.nextLink, Parameters.subscriptionId, - Parameters.resourceGroupName + Parameters.resourceGroupName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const listNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.ResourceListResult + bodyMapper: Mappers.ResourceListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, urlParameters: [ Parameters.$host, Parameters.nextLink, - Parameters.subscriptionId + Parameters.subscriptionId, ], headerParameters: [Parameters.accept], - serializer + serializer, }; diff --git a/sdk/resources/arm-resources/src/operations/tagsOperations.ts b/sdk/resources/arm-resources/src/operations/tagsOperations.ts index 121ce4e824ec..75b249d8872f 100644 --- a/sdk/resources/arm-resources/src/operations/tagsOperations.ts +++ b/sdk/resources/arm-resources/src/operations/tagsOperations.ts @@ -13,6 +13,12 @@ import * as coreClient from "@azure/core-client"; import * as Mappers from "../models/mappers"; import * as Parameters from "../models/parameters"; import { ResourceManagementClient } from "../resourceManagementClient"; +import { + SimplePollerLike, + OperationState, + createHttpPoller, +} from "@azure/core-lro"; +import { createLroSpec } from "../lroImpl"; import { TagDetails, TagsListNextOptionalParams, @@ -33,7 +39,7 @@ import { TagsGetAtScopeOptionalParams, TagsGetAtScopeResponse, TagsDeleteAtScopeOptionalParams, - TagsListNextResponse + TagsListNextResponse, } from "../models"; /// @@ -57,7 +63,7 @@ export class TagsOperationsImpl implements TagsOperations { * @param options The options parameters. */ public list( - options?: TagsListOptionalParams + options?: TagsListOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listPagingAll(options); return { @@ -72,13 +78,13 @@ export class TagsOperationsImpl implements TagsOperations { throw new Error("maxPageSize is not supported by this operation."); } return this.listPagingPage(options, settings); - } + }, }; } private async *listPagingPage( options?: TagsListOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: TagsListResponse; let continuationToken = settings?.continuationToken; @@ -99,7 +105,7 @@ export class TagsOperationsImpl implements TagsOperations { } private async *listPagingAll( - options?: TagsListOptionalParams + options?: TagsListOptionalParams, ): AsyncIterableIterator { for await (const page of this.listPagingPage(options)) { yield* page; @@ -117,11 +123,11 @@ export class TagsOperationsImpl implements TagsOperations { deleteValue( tagName: string, tagValue: string, - options?: TagsDeleteValueOptionalParams + options?: TagsDeleteValueOptionalParams, ): Promise { return this.client.sendOperationRequest( { tagName, tagValue, options }, - deleteValueOperationSpec + deleteValueOperationSpec, ); } @@ -135,11 +141,11 @@ export class TagsOperationsImpl implements TagsOperations { createOrUpdateValue( tagName: string, tagValue: string, - options?: TagsCreateOrUpdateValueOptionalParams + options?: TagsCreateOrUpdateValueOptionalParams, ): Promise { return this.client.sendOperationRequest( { tagName, tagValue, options }, - createOrUpdateValueOperationSpec + createOrUpdateValueOperationSpec, ); } @@ -152,11 +158,11 @@ export class TagsOperationsImpl implements TagsOperations { */ createOrUpdate( tagName: string, - options?: TagsCreateOrUpdateOptionalParams + options?: TagsCreateOrUpdateOptionalParams, ): Promise { return this.client.sendOperationRequest( { tagName, options }, - createOrUpdateOperationSpec + createOrUpdateOperationSpec, ); } @@ -170,7 +176,7 @@ export class TagsOperationsImpl implements TagsOperations { delete(tagName: string, options?: TagsDeleteOptionalParams): Promise { return this.client.sendOperationRequest( { tagName, options }, - deleteOperationSpec + deleteOperationSpec, ); } @@ -192,15 +198,162 @@ export class TagsOperationsImpl implements TagsOperations { * @param parameters Wrapper resource for tags API requests and responses. * @param options The options parameters. */ - createOrUpdateAtScope( + async beginCreateOrUpdateAtScope( scope: string, parameters: TagsResource, - options?: TagsCreateOrUpdateAtScopeOptionalParams + options?: TagsCreateOrUpdateAtScopeOptionalParams, + ): Promise< + SimplePollerLike< + OperationState, + TagsCreateOrUpdateAtScopeResponse + > + > { + const directSendOperation = async ( + args: coreClient.OperationArguments, + spec: coreClient.OperationSpec, + ): Promise => { + return this.client.sendOperationRequest(args, spec); + }; + const sendOperationFn = async ( + args: coreClient.OperationArguments, + spec: coreClient.OperationSpec, + ) => { + let currentRawResponse: coreClient.FullOperationResponse | undefined = + undefined; + const providedCallback = args.options?.onResponse; + const callback: coreClient.RawResponseCallback = ( + rawResponse: coreClient.FullOperationResponse, + flatResponse: unknown, + ) => { + currentRawResponse = rawResponse; + providedCallback?.(rawResponse, flatResponse); + }; + const updatedArgs = { + ...args, + options: { + ...args.options, + onResponse: callback, + }, + }; + const flatResponse = await directSendOperation(updatedArgs, spec); + return { + flatResponse, + rawResponse: { + statusCode: currentRawResponse!.status, + body: currentRawResponse!.parsedBody, + headers: currentRawResponse!.headers.toJSON(), + }, + }; + }; + + const lro = createLroSpec({ + sendOperationFn, + args: { scope, parameters, options }, + spec: createOrUpdateAtScopeOperationSpec, + }); + const poller = await createHttpPoller< + TagsCreateOrUpdateAtScopeResponse, + OperationState + >(lro, { + restoreFrom: options?.resumeFrom, + intervalInMs: options?.updateIntervalInMs, + }); + await poller.poll(); + return poller; + } + + /** + * This operation allows adding or replacing the entire set of tags on the specified resource or + * subscription. The specified entity can have a maximum of 50 tags. + * @param scope The resource scope. + * @param parameters Wrapper resource for tags API requests and responses. + * @param options The options parameters. + */ + async beginCreateOrUpdateAtScopeAndWait( + scope: string, + parameters: TagsResource, + options?: TagsCreateOrUpdateAtScopeOptionalParams, ): Promise { - return this.client.sendOperationRequest( - { scope, parameters, options }, - createOrUpdateAtScopeOperationSpec + const poller = await this.beginCreateOrUpdateAtScope( + scope, + parameters, + options, ); + return poller.pollUntilDone(); + } + + /** + * This operation allows replacing, merging or selectively deleting tags on the specified resource or + * subscription. The specified entity can have a maximum of 50 tags at the end of the operation. The + * 'replace' option replaces the entire set of existing tags with a new set. The 'merge' option allows + * adding tags with new names and updating the values of tags with existing names. The 'delete' option + * allows selectively deleting tags based on given names or name/value pairs. + * @param scope The resource scope. + * @param parameters Wrapper resource for tags patch API request only. + * @param options The options parameters. + */ + async beginUpdateAtScope( + scope: string, + parameters: TagsPatchResource, + options?: TagsUpdateAtScopeOptionalParams, + ): Promise< + SimplePollerLike< + OperationState, + TagsUpdateAtScopeResponse + > + > { + const directSendOperation = async ( + args: coreClient.OperationArguments, + spec: coreClient.OperationSpec, + ): Promise => { + return this.client.sendOperationRequest(args, spec); + }; + const sendOperationFn = async ( + args: coreClient.OperationArguments, + spec: coreClient.OperationSpec, + ) => { + let currentRawResponse: coreClient.FullOperationResponse | undefined = + undefined; + const providedCallback = args.options?.onResponse; + const callback: coreClient.RawResponseCallback = ( + rawResponse: coreClient.FullOperationResponse, + flatResponse: unknown, + ) => { + currentRawResponse = rawResponse; + providedCallback?.(rawResponse, flatResponse); + }; + const updatedArgs = { + ...args, + options: { + ...args.options, + onResponse: callback, + }, + }; + const flatResponse = await directSendOperation(updatedArgs, spec); + return { + flatResponse, + rawResponse: { + statusCode: currentRawResponse!.status, + body: currentRawResponse!.parsedBody, + headers: currentRawResponse!.headers.toJSON(), + }, + }; + }; + + const lro = createLroSpec({ + sendOperationFn, + args: { scope, parameters, options }, + spec: updateAtScopeOperationSpec, + }); + const poller = await createHttpPoller< + TagsUpdateAtScopeResponse, + OperationState + >(lro, { + restoreFrom: options?.resumeFrom, + intervalInMs: options?.updateIntervalInMs, + }); + await poller.poll(); + return poller; } /** @@ -213,15 +366,13 @@ export class TagsOperationsImpl implements TagsOperations { * @param parameters Wrapper resource for tags patch API request only. * @param options The options parameters. */ - updateAtScope( + async beginUpdateAtScopeAndWait( scope: string, parameters: TagsPatchResource, - options?: TagsUpdateAtScopeOptionalParams + options?: TagsUpdateAtScopeOptionalParams, ): Promise { - return this.client.sendOperationRequest( - { scope, parameters, options }, - updateAtScopeOperationSpec - ); + const poller = await this.beginUpdateAtScope(scope, parameters, options); + return poller.pollUntilDone(); } /** @@ -231,11 +382,11 @@ export class TagsOperationsImpl implements TagsOperations { */ getAtScope( scope: string, - options?: TagsGetAtScopeOptionalParams + options?: TagsGetAtScopeOptionalParams, ): Promise { return this.client.sendOperationRequest( { scope, options }, - getAtScopeOperationSpec + getAtScopeOperationSpec, ); } @@ -244,14 +395,72 @@ export class TagsOperationsImpl implements TagsOperations { * @param scope The resource scope. * @param options The options parameters. */ - deleteAtScope( + async beginDeleteAtScope( + scope: string, + options?: TagsDeleteAtScopeOptionalParams, + ): Promise, void>> { + const directSendOperation = async ( + args: coreClient.OperationArguments, + spec: coreClient.OperationSpec, + ): Promise => { + return this.client.sendOperationRequest(args, spec); + }; + const sendOperationFn = async ( + args: coreClient.OperationArguments, + spec: coreClient.OperationSpec, + ) => { + let currentRawResponse: coreClient.FullOperationResponse | undefined = + undefined; + const providedCallback = args.options?.onResponse; + const callback: coreClient.RawResponseCallback = ( + rawResponse: coreClient.FullOperationResponse, + flatResponse: unknown, + ) => { + currentRawResponse = rawResponse; + providedCallback?.(rawResponse, flatResponse); + }; + const updatedArgs = { + ...args, + options: { + ...args.options, + onResponse: callback, + }, + }; + const flatResponse = await directSendOperation(updatedArgs, spec); + return { + flatResponse, + rawResponse: { + statusCode: currentRawResponse!.status, + body: currentRawResponse!.parsedBody, + headers: currentRawResponse!.headers.toJSON(), + }, + }; + }; + + const lro = createLroSpec({ + sendOperationFn, + args: { scope, options }, + spec: deleteAtScopeOperationSpec, + }); + const poller = await createHttpPoller>(lro, { + restoreFrom: options?.resumeFrom, + intervalInMs: options?.updateIntervalInMs, + }); + await poller.poll(); + return poller; + } + + /** + * Deletes the entire set of tags on a resource or subscription. + * @param scope The resource scope. + * @param options The options parameters. + */ + async beginDeleteAtScopeAndWait( scope: string, - options?: TagsDeleteAtScopeOptionalParams + options?: TagsDeleteAtScopeOptionalParams, ): Promise { - return this.client.sendOperationRequest( - { scope, options }, - deleteAtScopeOperationSpec - ); + const poller = await this.beginDeleteAtScope(scope, options); + return poller.pollUntilDone(); } /** @@ -261,11 +470,11 @@ export class TagsOperationsImpl implements TagsOperations { */ private _listNext( nextLink: string, - options?: TagsListNextOptionalParams + options?: TagsListNextOptionalParams, ): Promise { return this.client.sendOperationRequest( { nextLink, options }, - listNextOperationSpec + listNextOperationSpec, ); } } @@ -273,73 +482,71 @@ export class TagsOperationsImpl implements TagsOperations { const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); const deleteValueOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/tagNames/{tagName}/tagValues/{tagValue}", + path: "/subscriptions/{subscriptionId}/tagNames/{tagName}/tagValues/{tagValue}", httpMethod: "DELETE", responses: { 200: {}, 204: {}, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, Parameters.tagName, - Parameters.tagValue + Parameters.tagValue, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const createOrUpdateValueOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/tagNames/{tagName}/tagValues/{tagValue}", + path: "/subscriptions/{subscriptionId}/tagNames/{tagName}/tagValues/{tagValue}", httpMethod: "PUT", responses: { 200: { - bodyMapper: Mappers.TagValue + bodyMapper: Mappers.TagValue, }, 201: { - bodyMapper: Mappers.TagValue + bodyMapper: Mappers.TagValue, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, Parameters.tagName, - Parameters.tagValue + Parameters.tagValue, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const createOrUpdateOperationSpec: coreClient.OperationSpec = { path: "/subscriptions/{subscriptionId}/tagNames/{tagName}", httpMethod: "PUT", responses: { 200: { - bodyMapper: Mappers.TagDetails + bodyMapper: Mappers.TagDetails, }, 201: { - bodyMapper: Mappers.TagDetails + bodyMapper: Mappers.TagDetails, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, - Parameters.tagName + Parameters.tagName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const deleteOperationSpec: coreClient.OperationSpec = { path: "/subscriptions/{subscriptionId}/tagNames/{tagName}", @@ -348,116 +555,137 @@ const deleteOperationSpec: coreClient.OperationSpec = { 200: {}, 204: {}, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, - Parameters.tagName + Parameters.tagName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const listOperationSpec: coreClient.OperationSpec = { path: "/subscriptions/{subscriptionId}/tagNames", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.TagsListResult + bodyMapper: Mappers.TagsListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [Parameters.$host, Parameters.subscriptionId], headerParameters: [Parameters.accept], - serializer + serializer, }; const createOrUpdateAtScopeOperationSpec: coreClient.OperationSpec = { path: "/{scope}/providers/Microsoft.Resources/tags/default", httpMethod: "PUT", responses: { 200: { - bodyMapper: Mappers.TagsResource + bodyMapper: Mappers.TagsResource, + }, + 201: { + bodyMapper: Mappers.TagsResource, + }, + 202: { + bodyMapper: Mappers.TagsResource, + }, + 204: { + bodyMapper: Mappers.TagsResource, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, requestBody: Parameters.parameters9, queryParameters: [Parameters.apiVersion], urlParameters: [Parameters.$host, Parameters.scope], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", - serializer + serializer, }; const updateAtScopeOperationSpec: coreClient.OperationSpec = { path: "/{scope}/providers/Microsoft.Resources/tags/default", httpMethod: "PATCH", responses: { 200: { - bodyMapper: Mappers.TagsResource + bodyMapper: Mappers.TagsResource, + }, + 201: { + bodyMapper: Mappers.TagsResource, + }, + 202: { + bodyMapper: Mappers.TagsResource, + }, + 204: { + bodyMapper: Mappers.TagsResource, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, requestBody: Parameters.parameters10, queryParameters: [Parameters.apiVersion], urlParameters: [Parameters.$host, Parameters.scope], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", - serializer + serializer, }; const getAtScopeOperationSpec: coreClient.OperationSpec = { path: "/{scope}/providers/Microsoft.Resources/tags/default", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.TagsResource + bodyMapper: Mappers.TagsResource, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [Parameters.$host, Parameters.scope], headerParameters: [Parameters.accept], - serializer + serializer, }; const deleteAtScopeOperationSpec: coreClient.OperationSpec = { path: "/{scope}/providers/Microsoft.Resources/tags/default", httpMethod: "DELETE", responses: { 200: {}, + 201: {}, + 202: {}, + 204: {}, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [Parameters.$host, Parameters.scope], headerParameters: [Parameters.accept], - serializer + serializer, }; const listNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.TagsListResult + bodyMapper: Mappers.TagsListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, urlParameters: [ Parameters.$host, Parameters.nextLink, - Parameters.subscriptionId + Parameters.subscriptionId, ], headerParameters: [Parameters.accept], - serializer + serializer, }; diff --git a/sdk/resources/arm-resources/src/operationsInterfaces/deploymentOperations.ts b/sdk/resources/arm-resources/src/operationsInterfaces/deploymentOperations.ts index f55d69614dd8..4327062e0dde 100644 --- a/sdk/resources/arm-resources/src/operationsInterfaces/deploymentOperations.ts +++ b/sdk/resources/arm-resources/src/operationsInterfaces/deploymentOperations.ts @@ -23,7 +23,7 @@ import { DeploymentOperationsGetAtSubscriptionScopeOptionalParams, DeploymentOperationsGetAtSubscriptionScopeResponse, DeploymentOperationsGetOptionalParams, - DeploymentOperationsGetResponse + DeploymentOperationsGetResponse, } from "../models"; /// @@ -38,7 +38,7 @@ export interface DeploymentOperations { listAtScope( scope: string, deploymentName: string, - options?: DeploymentOperationsListAtScopeOptionalParams + options?: DeploymentOperationsListAtScopeOptionalParams, ): PagedAsyncIterableIterator; /** * Gets all deployments operations for a deployment. @@ -47,7 +47,7 @@ export interface DeploymentOperations { */ listAtTenantScope( deploymentName: string, - options?: DeploymentOperationsListAtTenantScopeOptionalParams + options?: DeploymentOperationsListAtTenantScopeOptionalParams, ): PagedAsyncIterableIterator; /** * Gets all deployments operations for a deployment. @@ -58,7 +58,7 @@ export interface DeploymentOperations { listAtManagementGroupScope( groupId: string, deploymentName: string, - options?: DeploymentOperationsListAtManagementGroupScopeOptionalParams + options?: DeploymentOperationsListAtManagementGroupScopeOptionalParams, ): PagedAsyncIterableIterator; /** * Gets all deployments operations for a deployment. @@ -67,7 +67,7 @@ export interface DeploymentOperations { */ listAtSubscriptionScope( deploymentName: string, - options?: DeploymentOperationsListAtSubscriptionScopeOptionalParams + options?: DeploymentOperationsListAtSubscriptionScopeOptionalParams, ): PagedAsyncIterableIterator; /** * Gets all deployments operations for a deployment. @@ -78,7 +78,7 @@ export interface DeploymentOperations { list( resourceGroupName: string, deploymentName: string, - options?: DeploymentOperationsListOptionalParams + options?: DeploymentOperationsListOptionalParams, ): PagedAsyncIterableIterator; /** * Gets a deployments operation. @@ -91,7 +91,7 @@ export interface DeploymentOperations { scope: string, deploymentName: string, operationId: string, - options?: DeploymentOperationsGetAtScopeOptionalParams + options?: DeploymentOperationsGetAtScopeOptionalParams, ): Promise; /** * Gets a deployments operation. @@ -102,7 +102,7 @@ export interface DeploymentOperations { getAtTenantScope( deploymentName: string, operationId: string, - options?: DeploymentOperationsGetAtTenantScopeOptionalParams + options?: DeploymentOperationsGetAtTenantScopeOptionalParams, ): Promise; /** * Gets a deployments operation. @@ -115,7 +115,7 @@ export interface DeploymentOperations { groupId: string, deploymentName: string, operationId: string, - options?: DeploymentOperationsGetAtManagementGroupScopeOptionalParams + options?: DeploymentOperationsGetAtManagementGroupScopeOptionalParams, ): Promise; /** * Gets a deployments operation. @@ -126,7 +126,7 @@ export interface DeploymentOperations { getAtSubscriptionScope( deploymentName: string, operationId: string, - options?: DeploymentOperationsGetAtSubscriptionScopeOptionalParams + options?: DeploymentOperationsGetAtSubscriptionScopeOptionalParams, ): Promise; /** * Gets a deployments operation. @@ -139,6 +139,6 @@ export interface DeploymentOperations { resourceGroupName: string, deploymentName: string, operationId: string, - options?: DeploymentOperationsGetOptionalParams + options?: DeploymentOperationsGetOptionalParams, ): Promise; } diff --git a/sdk/resources/arm-resources/src/operationsInterfaces/deployments.ts b/sdk/resources/arm-resources/src/operationsInterfaces/deployments.ts index 360326afc4d2..7da7fab4518a 100644 --- a/sdk/resources/arm-resources/src/operationsInterfaces/deployments.ts +++ b/sdk/resources/arm-resources/src/operationsInterfaces/deployments.ts @@ -88,7 +88,7 @@ import { DeploymentsExportTemplateOptionalParams, DeploymentsExportTemplateResponse, DeploymentsCalculateTemplateHashOptionalParams, - DeploymentsCalculateTemplateHashResponse + DeploymentsCalculateTemplateHashResponse, } from "../models"; /// @@ -101,14 +101,14 @@ export interface Deployments { */ listAtScope( scope: string, - options?: DeploymentsListAtScopeOptionalParams + options?: DeploymentsListAtScopeOptionalParams, ): PagedAsyncIterableIterator; /** * Get all the deployments at the tenant scope. * @param options The options parameters. */ listAtTenantScope( - options?: DeploymentsListAtTenantScopeOptionalParams + options?: DeploymentsListAtTenantScopeOptionalParams, ): PagedAsyncIterableIterator; /** * Get all the deployments for a management group. @@ -117,14 +117,14 @@ export interface Deployments { */ listAtManagementGroupScope( groupId: string, - options?: DeploymentsListAtManagementGroupScopeOptionalParams + options?: DeploymentsListAtManagementGroupScopeOptionalParams, ): PagedAsyncIterableIterator; /** * Get all the deployments for a subscription. * @param options The options parameters. */ listAtSubscriptionScope( - options?: DeploymentsListAtSubscriptionScopeOptionalParams + options?: DeploymentsListAtSubscriptionScopeOptionalParams, ): PagedAsyncIterableIterator; /** * Get all the deployments for a resource group. @@ -134,16 +134,19 @@ export interface Deployments { */ listByResourceGroup( resourceGroupName: string, - options?: DeploymentsListByResourceGroupOptionalParams + options?: DeploymentsListByResourceGroupOptionalParams, ): PagedAsyncIterableIterator; /** * A template deployment that is currently running cannot be deleted. Deleting a template deployment - * removes the associated deployment operations. This is an asynchronous operation that returns a - * status of 202 until the template deployment is successfully deleted. The Location response header - * contains the URI that is used to obtain the status of the process. While the process is running, a - * call to the URI in the Location header returns a status of 202. When the process finishes, the URI - * in the Location header returns a status of 204 on success. If the asynchronous request failed, the - * URI in the Location header returns an error-level status code. + * removes the associated deployment operations. A deployment delete request may return one of the + * three status codes: 200, 202, 204. Status 200 is returned if the deployment existed and was + * synchronously deleted successfully. Status 204 is returned if the deployment didn't exist. It is an + * asynchronous operation if 202 is returned, the client needs to continue probing until the template + * deployment is successfully deleted. The Location response header contains the URI that is used to + * obtain the status of the process. While the process is running, a call to the URI in the Location + * header returns a status of 202. When the process finishes, the URI in the Location header returns a + * status of 204 on success. If the asynchronous request failed, the URI in the Location header returns + * an error-level status code. * @param scope The resource scope. * @param deploymentName The name of the deployment. * @param options The options parameters. @@ -151,16 +154,19 @@ export interface Deployments { beginDeleteAtScope( scope: string, deploymentName: string, - options?: DeploymentsDeleteAtScopeOptionalParams + options?: DeploymentsDeleteAtScopeOptionalParams, ): Promise, void>>; /** * A template deployment that is currently running cannot be deleted. Deleting a template deployment - * removes the associated deployment operations. This is an asynchronous operation that returns a - * status of 202 until the template deployment is successfully deleted. The Location response header - * contains the URI that is used to obtain the status of the process. While the process is running, a - * call to the URI in the Location header returns a status of 202. When the process finishes, the URI - * in the Location header returns a status of 204 on success. If the asynchronous request failed, the - * URI in the Location header returns an error-level status code. + * removes the associated deployment operations. A deployment delete request may return one of the + * three status codes: 200, 202, 204. Status 200 is returned if the deployment existed and was + * synchronously deleted successfully. Status 204 is returned if the deployment didn't exist. It is an + * asynchronous operation if 202 is returned, the client needs to continue probing until the template + * deployment is successfully deleted. The Location response header contains the URI that is used to + * obtain the status of the process. While the process is running, a call to the URI in the Location + * header returns a status of 202. When the process finishes, the URI in the Location header returns a + * status of 204 on success. If the asynchronous request failed, the URI in the Location header returns + * an error-level status code. * @param scope The resource scope. * @param deploymentName The name of the deployment. * @param options The options parameters. @@ -168,7 +174,7 @@ export interface Deployments { beginDeleteAtScopeAndWait( scope: string, deploymentName: string, - options?: DeploymentsDeleteAtScopeOptionalParams + options?: DeploymentsDeleteAtScopeOptionalParams, ): Promise; /** * Checks whether the deployment exists. @@ -179,7 +185,7 @@ export interface Deployments { checkExistenceAtScope( scope: string, deploymentName: string, - options?: DeploymentsCheckExistenceAtScopeOptionalParams + options?: DeploymentsCheckExistenceAtScopeOptionalParams, ): Promise; /** * You can provide the template and parameters directly in the request or link to JSON files. @@ -192,7 +198,7 @@ export interface Deployments { scope: string, deploymentName: string, parameters: Deployment, - options?: DeploymentsCreateOrUpdateAtScopeOptionalParams + options?: DeploymentsCreateOrUpdateAtScopeOptionalParams, ): Promise< SimplePollerLike< OperationState, @@ -210,7 +216,7 @@ export interface Deployments { scope: string, deploymentName: string, parameters: Deployment, - options?: DeploymentsCreateOrUpdateAtScopeOptionalParams + options?: DeploymentsCreateOrUpdateAtScopeOptionalParams, ): Promise; /** * Gets a deployment. @@ -221,7 +227,7 @@ export interface Deployments { getAtScope( scope: string, deploymentName: string, - options?: DeploymentsGetAtScopeOptionalParams + options?: DeploymentsGetAtScopeOptionalParams, ): Promise; /** * You can cancel a deployment only if the provisioningState is Accepted or Running. After the @@ -234,7 +240,7 @@ export interface Deployments { cancelAtScope( scope: string, deploymentName: string, - options?: DeploymentsCancelAtScopeOptionalParams + options?: DeploymentsCancelAtScopeOptionalParams, ): Promise; /** * Validates whether the specified template is syntactically correct and will be accepted by Azure @@ -248,7 +254,7 @@ export interface Deployments { scope: string, deploymentName: string, parameters: Deployment, - options?: DeploymentsValidateAtScopeOptionalParams + options?: DeploymentsValidateAtScopeOptionalParams, ): Promise< SimplePollerLike< OperationState, @@ -267,7 +273,7 @@ export interface Deployments { scope: string, deploymentName: string, parameters: Deployment, - options?: DeploymentsValidateAtScopeOptionalParams + options?: DeploymentsValidateAtScopeOptionalParams, ): Promise; /** * Exports the template used for specified deployment. @@ -278,7 +284,7 @@ export interface Deployments { exportTemplateAtScope( scope: string, deploymentName: string, - options?: DeploymentsExportTemplateAtScopeOptionalParams + options?: DeploymentsExportTemplateAtScopeOptionalParams, ): Promise; /** * A template deployment that is currently running cannot be deleted. Deleting a template deployment @@ -293,7 +299,7 @@ export interface Deployments { */ beginDeleteAtTenantScope( deploymentName: string, - options?: DeploymentsDeleteAtTenantScopeOptionalParams + options?: DeploymentsDeleteAtTenantScopeOptionalParams, ): Promise, void>>; /** * A template deployment that is currently running cannot be deleted. Deleting a template deployment @@ -308,7 +314,7 @@ export interface Deployments { */ beginDeleteAtTenantScopeAndWait( deploymentName: string, - options?: DeploymentsDeleteAtTenantScopeOptionalParams + options?: DeploymentsDeleteAtTenantScopeOptionalParams, ): Promise; /** * Checks whether the deployment exists. @@ -317,7 +323,7 @@ export interface Deployments { */ checkExistenceAtTenantScope( deploymentName: string, - options?: DeploymentsCheckExistenceAtTenantScopeOptionalParams + options?: DeploymentsCheckExistenceAtTenantScopeOptionalParams, ): Promise; /** * You can provide the template and parameters directly in the request or link to JSON files. @@ -328,7 +334,7 @@ export interface Deployments { beginCreateOrUpdateAtTenantScope( deploymentName: string, parameters: ScopedDeployment, - options?: DeploymentsCreateOrUpdateAtTenantScopeOptionalParams + options?: DeploymentsCreateOrUpdateAtTenantScopeOptionalParams, ): Promise< SimplePollerLike< OperationState, @@ -344,7 +350,7 @@ export interface Deployments { beginCreateOrUpdateAtTenantScopeAndWait( deploymentName: string, parameters: ScopedDeployment, - options?: DeploymentsCreateOrUpdateAtTenantScopeOptionalParams + options?: DeploymentsCreateOrUpdateAtTenantScopeOptionalParams, ): Promise; /** * Gets a deployment. @@ -353,7 +359,7 @@ export interface Deployments { */ getAtTenantScope( deploymentName: string, - options?: DeploymentsGetAtTenantScopeOptionalParams + options?: DeploymentsGetAtTenantScopeOptionalParams, ): Promise; /** * You can cancel a deployment only if the provisioningState is Accepted or Running. After the @@ -364,7 +370,7 @@ export interface Deployments { */ cancelAtTenantScope( deploymentName: string, - options?: DeploymentsCancelAtTenantScopeOptionalParams + options?: DeploymentsCancelAtTenantScopeOptionalParams, ): Promise; /** * Validates whether the specified template is syntactically correct and will be accepted by Azure @@ -376,7 +382,7 @@ export interface Deployments { beginValidateAtTenantScope( deploymentName: string, parameters: ScopedDeployment, - options?: DeploymentsValidateAtTenantScopeOptionalParams + options?: DeploymentsValidateAtTenantScopeOptionalParams, ): Promise< SimplePollerLike< OperationState, @@ -393,7 +399,7 @@ export interface Deployments { beginValidateAtTenantScopeAndWait( deploymentName: string, parameters: ScopedDeployment, - options?: DeploymentsValidateAtTenantScopeOptionalParams + options?: DeploymentsValidateAtTenantScopeOptionalParams, ): Promise; /** * Returns changes that will be made by the deployment if executed at the scope of the tenant group. @@ -404,7 +410,7 @@ export interface Deployments { beginWhatIfAtTenantScope( deploymentName: string, parameters: ScopedDeploymentWhatIf, - options?: DeploymentsWhatIfAtTenantScopeOptionalParams + options?: DeploymentsWhatIfAtTenantScopeOptionalParams, ): Promise< SimplePollerLike< OperationState, @@ -420,7 +426,7 @@ export interface Deployments { beginWhatIfAtTenantScopeAndWait( deploymentName: string, parameters: ScopedDeploymentWhatIf, - options?: DeploymentsWhatIfAtTenantScopeOptionalParams + options?: DeploymentsWhatIfAtTenantScopeOptionalParams, ): Promise; /** * Exports the template used for specified deployment. @@ -429,7 +435,7 @@ export interface Deployments { */ exportTemplateAtTenantScope( deploymentName: string, - options?: DeploymentsExportTemplateAtTenantScopeOptionalParams + options?: DeploymentsExportTemplateAtTenantScopeOptionalParams, ): Promise; /** * A template deployment that is currently running cannot be deleted. Deleting a template deployment @@ -446,7 +452,7 @@ export interface Deployments { beginDeleteAtManagementGroupScope( groupId: string, deploymentName: string, - options?: DeploymentsDeleteAtManagementGroupScopeOptionalParams + options?: DeploymentsDeleteAtManagementGroupScopeOptionalParams, ): Promise, void>>; /** * A template deployment that is currently running cannot be deleted. Deleting a template deployment @@ -463,7 +469,7 @@ export interface Deployments { beginDeleteAtManagementGroupScopeAndWait( groupId: string, deploymentName: string, - options?: DeploymentsDeleteAtManagementGroupScopeOptionalParams + options?: DeploymentsDeleteAtManagementGroupScopeOptionalParams, ): Promise; /** * Checks whether the deployment exists. @@ -474,7 +480,7 @@ export interface Deployments { checkExistenceAtManagementGroupScope( groupId: string, deploymentName: string, - options?: DeploymentsCheckExistenceAtManagementGroupScopeOptionalParams + options?: DeploymentsCheckExistenceAtManagementGroupScopeOptionalParams, ): Promise; /** * You can provide the template and parameters directly in the request or link to JSON files. @@ -487,7 +493,7 @@ export interface Deployments { groupId: string, deploymentName: string, parameters: ScopedDeployment, - options?: DeploymentsCreateOrUpdateAtManagementGroupScopeOptionalParams + options?: DeploymentsCreateOrUpdateAtManagementGroupScopeOptionalParams, ): Promise< SimplePollerLike< OperationState, @@ -505,7 +511,7 @@ export interface Deployments { groupId: string, deploymentName: string, parameters: ScopedDeployment, - options?: DeploymentsCreateOrUpdateAtManagementGroupScopeOptionalParams + options?: DeploymentsCreateOrUpdateAtManagementGroupScopeOptionalParams, ): Promise; /** * Gets a deployment. @@ -516,7 +522,7 @@ export interface Deployments { getAtManagementGroupScope( groupId: string, deploymentName: string, - options?: DeploymentsGetAtManagementGroupScopeOptionalParams + options?: DeploymentsGetAtManagementGroupScopeOptionalParams, ): Promise; /** * You can cancel a deployment only if the provisioningState is Accepted or Running. After the @@ -529,7 +535,7 @@ export interface Deployments { cancelAtManagementGroupScope( groupId: string, deploymentName: string, - options?: DeploymentsCancelAtManagementGroupScopeOptionalParams + options?: DeploymentsCancelAtManagementGroupScopeOptionalParams, ): Promise; /** * Validates whether the specified template is syntactically correct and will be accepted by Azure @@ -543,7 +549,7 @@ export interface Deployments { groupId: string, deploymentName: string, parameters: ScopedDeployment, - options?: DeploymentsValidateAtManagementGroupScopeOptionalParams + options?: DeploymentsValidateAtManagementGroupScopeOptionalParams, ): Promise< SimplePollerLike< OperationState, @@ -562,7 +568,7 @@ export interface Deployments { groupId: string, deploymentName: string, parameters: ScopedDeployment, - options?: DeploymentsValidateAtManagementGroupScopeOptionalParams + options?: DeploymentsValidateAtManagementGroupScopeOptionalParams, ): Promise; /** * Returns changes that will be made by the deployment if executed at the scope of the management @@ -576,7 +582,7 @@ export interface Deployments { groupId: string, deploymentName: string, parameters: ScopedDeploymentWhatIf, - options?: DeploymentsWhatIfAtManagementGroupScopeOptionalParams + options?: DeploymentsWhatIfAtManagementGroupScopeOptionalParams, ): Promise< SimplePollerLike< OperationState, @@ -595,7 +601,7 @@ export interface Deployments { groupId: string, deploymentName: string, parameters: ScopedDeploymentWhatIf, - options?: DeploymentsWhatIfAtManagementGroupScopeOptionalParams + options?: DeploymentsWhatIfAtManagementGroupScopeOptionalParams, ): Promise; /** * Exports the template used for specified deployment. @@ -606,7 +612,7 @@ export interface Deployments { exportTemplateAtManagementGroupScope( groupId: string, deploymentName: string, - options?: DeploymentsExportTemplateAtManagementGroupScopeOptionalParams + options?: DeploymentsExportTemplateAtManagementGroupScopeOptionalParams, ): Promise; /** * A template deployment that is currently running cannot be deleted. Deleting a template deployment @@ -621,7 +627,7 @@ export interface Deployments { */ beginDeleteAtSubscriptionScope( deploymentName: string, - options?: DeploymentsDeleteAtSubscriptionScopeOptionalParams + options?: DeploymentsDeleteAtSubscriptionScopeOptionalParams, ): Promise, void>>; /** * A template deployment that is currently running cannot be deleted. Deleting a template deployment @@ -636,7 +642,7 @@ export interface Deployments { */ beginDeleteAtSubscriptionScopeAndWait( deploymentName: string, - options?: DeploymentsDeleteAtSubscriptionScopeOptionalParams + options?: DeploymentsDeleteAtSubscriptionScopeOptionalParams, ): Promise; /** * Checks whether the deployment exists. @@ -645,7 +651,7 @@ export interface Deployments { */ checkExistenceAtSubscriptionScope( deploymentName: string, - options?: DeploymentsCheckExistenceAtSubscriptionScopeOptionalParams + options?: DeploymentsCheckExistenceAtSubscriptionScopeOptionalParams, ): Promise; /** * You can provide the template and parameters directly in the request or link to JSON files. @@ -656,7 +662,7 @@ export interface Deployments { beginCreateOrUpdateAtSubscriptionScope( deploymentName: string, parameters: Deployment, - options?: DeploymentsCreateOrUpdateAtSubscriptionScopeOptionalParams + options?: DeploymentsCreateOrUpdateAtSubscriptionScopeOptionalParams, ): Promise< SimplePollerLike< OperationState, @@ -672,7 +678,7 @@ export interface Deployments { beginCreateOrUpdateAtSubscriptionScopeAndWait( deploymentName: string, parameters: Deployment, - options?: DeploymentsCreateOrUpdateAtSubscriptionScopeOptionalParams + options?: DeploymentsCreateOrUpdateAtSubscriptionScopeOptionalParams, ): Promise; /** * Gets a deployment. @@ -681,7 +687,7 @@ export interface Deployments { */ getAtSubscriptionScope( deploymentName: string, - options?: DeploymentsGetAtSubscriptionScopeOptionalParams + options?: DeploymentsGetAtSubscriptionScopeOptionalParams, ): Promise; /** * You can cancel a deployment only if the provisioningState is Accepted or Running. After the @@ -692,7 +698,7 @@ export interface Deployments { */ cancelAtSubscriptionScope( deploymentName: string, - options?: DeploymentsCancelAtSubscriptionScopeOptionalParams + options?: DeploymentsCancelAtSubscriptionScopeOptionalParams, ): Promise; /** * Validates whether the specified template is syntactically correct and will be accepted by Azure @@ -704,7 +710,7 @@ export interface Deployments { beginValidateAtSubscriptionScope( deploymentName: string, parameters: Deployment, - options?: DeploymentsValidateAtSubscriptionScopeOptionalParams + options?: DeploymentsValidateAtSubscriptionScopeOptionalParams, ): Promise< SimplePollerLike< OperationState, @@ -721,7 +727,7 @@ export interface Deployments { beginValidateAtSubscriptionScopeAndWait( deploymentName: string, parameters: Deployment, - options?: DeploymentsValidateAtSubscriptionScopeOptionalParams + options?: DeploymentsValidateAtSubscriptionScopeOptionalParams, ): Promise; /** * Returns changes that will be made by the deployment if executed at the scope of the subscription. @@ -732,7 +738,7 @@ export interface Deployments { beginWhatIfAtSubscriptionScope( deploymentName: string, parameters: DeploymentWhatIf, - options?: DeploymentsWhatIfAtSubscriptionScopeOptionalParams + options?: DeploymentsWhatIfAtSubscriptionScopeOptionalParams, ): Promise< SimplePollerLike< OperationState, @@ -748,7 +754,7 @@ export interface Deployments { beginWhatIfAtSubscriptionScopeAndWait( deploymentName: string, parameters: DeploymentWhatIf, - options?: DeploymentsWhatIfAtSubscriptionScopeOptionalParams + options?: DeploymentsWhatIfAtSubscriptionScopeOptionalParams, ): Promise; /** * Exports the template used for specified deployment. @@ -757,7 +763,7 @@ export interface Deployments { */ exportTemplateAtSubscriptionScope( deploymentName: string, - options?: DeploymentsExportTemplateAtSubscriptionScopeOptionalParams + options?: DeploymentsExportTemplateAtSubscriptionScopeOptionalParams, ): Promise; /** * A template deployment that is currently running cannot be deleted. Deleting a template deployment @@ -776,7 +782,7 @@ export interface Deployments { beginDelete( resourceGroupName: string, deploymentName: string, - options?: DeploymentsDeleteOptionalParams + options?: DeploymentsDeleteOptionalParams, ): Promise, void>>; /** * A template deployment that is currently running cannot be deleted. Deleting a template deployment @@ -795,7 +801,7 @@ export interface Deployments { beginDeleteAndWait( resourceGroupName: string, deploymentName: string, - options?: DeploymentsDeleteOptionalParams + options?: DeploymentsDeleteOptionalParams, ): Promise; /** * Checks whether the deployment exists. @@ -807,7 +813,7 @@ export interface Deployments { checkExistence( resourceGroupName: string, deploymentName: string, - options?: DeploymentsCheckExistenceOptionalParams + options?: DeploymentsCheckExistenceOptionalParams, ): Promise; /** * You can provide the template and parameters directly in the request or link to JSON files. @@ -821,7 +827,7 @@ export interface Deployments { resourceGroupName: string, deploymentName: string, parameters: Deployment, - options?: DeploymentsCreateOrUpdateOptionalParams + options?: DeploymentsCreateOrUpdateOptionalParams, ): Promise< SimplePollerLike< OperationState, @@ -840,7 +846,7 @@ export interface Deployments { resourceGroupName: string, deploymentName: string, parameters: Deployment, - options?: DeploymentsCreateOrUpdateOptionalParams + options?: DeploymentsCreateOrUpdateOptionalParams, ): Promise; /** * Gets a deployment. @@ -851,7 +857,7 @@ export interface Deployments { get( resourceGroupName: string, deploymentName: string, - options?: DeploymentsGetOptionalParams + options?: DeploymentsGetOptionalParams, ): Promise; /** * You can cancel a deployment only if the provisioningState is Accepted or Running. After the @@ -864,7 +870,7 @@ export interface Deployments { cancel( resourceGroupName: string, deploymentName: string, - options?: DeploymentsCancelOptionalParams + options?: DeploymentsCancelOptionalParams, ): Promise; /** * Validates whether the specified template is syntactically correct and will be accepted by Azure @@ -879,7 +885,7 @@ export interface Deployments { resourceGroupName: string, deploymentName: string, parameters: Deployment, - options?: DeploymentsValidateOptionalParams + options?: DeploymentsValidateOptionalParams, ): Promise< SimplePollerLike< OperationState, @@ -899,7 +905,7 @@ export interface Deployments { resourceGroupName: string, deploymentName: string, parameters: Deployment, - options?: DeploymentsValidateOptionalParams + options?: DeploymentsValidateOptionalParams, ): Promise; /** * Returns changes that will be made by the deployment if executed at the scope of the resource group. @@ -913,7 +919,7 @@ export interface Deployments { resourceGroupName: string, deploymentName: string, parameters: DeploymentWhatIf, - options?: DeploymentsWhatIfOptionalParams + options?: DeploymentsWhatIfOptionalParams, ): Promise< SimplePollerLike< OperationState, @@ -932,7 +938,7 @@ export interface Deployments { resourceGroupName: string, deploymentName: string, parameters: DeploymentWhatIf, - options?: DeploymentsWhatIfOptionalParams + options?: DeploymentsWhatIfOptionalParams, ): Promise; /** * Exports the template used for specified deployment. @@ -943,7 +949,7 @@ export interface Deployments { exportTemplate( resourceGroupName: string, deploymentName: string, - options?: DeploymentsExportTemplateOptionalParams + options?: DeploymentsExportTemplateOptionalParams, ): Promise; /** * Calculate the hash of the given template. @@ -952,6 +958,6 @@ export interface Deployments { */ calculateTemplateHash( template: Record, - options?: DeploymentsCalculateTemplateHashOptionalParams + options?: DeploymentsCalculateTemplateHashOptionalParams, ): Promise; } diff --git a/sdk/resources/arm-resources/src/operationsInterfaces/operations.ts b/sdk/resources/arm-resources/src/operationsInterfaces/operations.ts index ac34435954c0..65cdf8035ab0 100644 --- a/sdk/resources/arm-resources/src/operationsInterfaces/operations.ts +++ b/sdk/resources/arm-resources/src/operationsInterfaces/operations.ts @@ -17,6 +17,6 @@ export interface Operations { * @param options The options parameters. */ list( - options?: OperationsListOptionalParams + options?: OperationsListOptionalParams, ): PagedAsyncIterableIterator; } diff --git a/sdk/resources/arm-resources/src/operationsInterfaces/providerResourceTypes.ts b/sdk/resources/arm-resources/src/operationsInterfaces/providerResourceTypes.ts index f7010e50bd64..0e4c5c2f6dcb 100644 --- a/sdk/resources/arm-resources/src/operationsInterfaces/providerResourceTypes.ts +++ b/sdk/resources/arm-resources/src/operationsInterfaces/providerResourceTypes.ts @@ -8,7 +8,7 @@ import { ProviderResourceTypesListOptionalParams, - ProviderResourceTypesListResponse + ProviderResourceTypesListResponse, } from "../models"; /** Interface representing a ProviderResourceTypes. */ @@ -20,6 +20,6 @@ export interface ProviderResourceTypes { */ list( resourceProviderNamespace: string, - options?: ProviderResourceTypesListOptionalParams + options?: ProviderResourceTypesListOptionalParams, ): Promise; } diff --git a/sdk/resources/arm-resources/src/operationsInterfaces/providers.ts b/sdk/resources/arm-resources/src/operationsInterfaces/providers.ts index ee8f17fce3c8..9f74bdab2307 100644 --- a/sdk/resources/arm-resources/src/operationsInterfaces/providers.ts +++ b/sdk/resources/arm-resources/src/operationsInterfaces/providers.ts @@ -21,7 +21,7 @@ import { ProvidersGetOptionalParams, ProvidersGetResponse, ProvidersGetAtTenantScopeOptionalParams, - ProvidersGetAtTenantScopeResponse + ProvidersGetAtTenantScopeResponse, } from "../models"; /// @@ -32,14 +32,14 @@ export interface Providers { * @param options The options parameters. */ list( - options?: ProvidersListOptionalParams + options?: ProvidersListOptionalParams, ): PagedAsyncIterableIterator; /** * Gets all resource providers for the tenant. * @param options The options parameters. */ listAtTenantScope( - options?: ProvidersListAtTenantScopeOptionalParams + options?: ProvidersListAtTenantScopeOptionalParams, ): PagedAsyncIterableIterator; /** * Unregisters a subscription from a resource provider. @@ -48,10 +48,13 @@ export interface Providers { */ unregister( resourceProviderNamespace: string, - options?: ProvidersUnregisterOptionalParams + options?: ProvidersUnregisterOptionalParams, ): Promise; /** - * Registers a management group with a resource provider. + * Registers a management group with a resource provider. Use this operation to register a resource + * provider with resource types that can be deployed at the management group scope. It does not + * recursively register subscriptions within the management group. Instead, you must register + * subscriptions individually. * @param resourceProviderNamespace The namespace of the resource provider to register. * @param groupId The management group ID. * @param options The options parameters. @@ -59,7 +62,7 @@ export interface Providers { registerAtManagementGroupScope( resourceProviderNamespace: string, groupId: string, - options?: ProvidersRegisterAtManagementGroupScopeOptionalParams + options?: ProvidersRegisterAtManagementGroupScopeOptionalParams, ): Promise; /** * Get the provider permissions. @@ -68,7 +71,7 @@ export interface Providers { */ providerPermissions( resourceProviderNamespace: string, - options?: ProvidersProviderPermissionsOptionalParams + options?: ProvidersProviderPermissionsOptionalParams, ): Promise; /** * Registers a subscription with a resource provider. @@ -77,7 +80,7 @@ export interface Providers { */ register( resourceProviderNamespace: string, - options?: ProvidersRegisterOptionalParams + options?: ProvidersRegisterOptionalParams, ): Promise; /** * Gets the specified resource provider. @@ -86,7 +89,7 @@ export interface Providers { */ get( resourceProviderNamespace: string, - options?: ProvidersGetOptionalParams + options?: ProvidersGetOptionalParams, ): Promise; /** * Gets the specified resource provider at the tenant level. @@ -95,6 +98,6 @@ export interface Providers { */ getAtTenantScope( resourceProviderNamespace: string, - options?: ProvidersGetAtTenantScopeOptionalParams + options?: ProvidersGetAtTenantScopeOptionalParams, ): Promise; } diff --git a/sdk/resources/arm-resources/src/operationsInterfaces/resourceGroups.ts b/sdk/resources/arm-resources/src/operationsInterfaces/resourceGroups.ts index e7803b565192..3b58da505d02 100644 --- a/sdk/resources/arm-resources/src/operationsInterfaces/resourceGroups.ts +++ b/sdk/resources/arm-resources/src/operationsInterfaces/resourceGroups.ts @@ -23,7 +23,7 @@ import { ResourceGroupsUpdateResponse, ExportTemplateRequest, ResourceGroupsExportTemplateOptionalParams, - ResourceGroupsExportTemplateResponse + ResourceGroupsExportTemplateResponse, } from "../models"; /// @@ -34,7 +34,7 @@ export interface ResourceGroups { * @param options The options parameters. */ list( - options?: ResourceGroupsListOptionalParams + options?: ResourceGroupsListOptionalParams, ): PagedAsyncIterableIterator; /** * Checks whether a resource group exists. @@ -43,7 +43,7 @@ export interface ResourceGroups { */ checkExistence( resourceGroupName: string, - options?: ResourceGroupsCheckExistenceOptionalParams + options?: ResourceGroupsCheckExistenceOptionalParams, ): Promise; /** * Creates or updates a resource group. @@ -56,7 +56,7 @@ export interface ResourceGroups { createOrUpdate( resourceGroupName: string, parameters: ResourceGroup, - options?: ResourceGroupsCreateOrUpdateOptionalParams + options?: ResourceGroupsCreateOrUpdateOptionalParams, ): Promise; /** * When you delete a resource group, all of its resources are also deleted. Deleting a resource group @@ -66,7 +66,7 @@ export interface ResourceGroups { */ beginDelete( resourceGroupName: string, - options?: ResourceGroupsDeleteOptionalParams + options?: ResourceGroupsDeleteOptionalParams, ): Promise, void>>; /** * When you delete a resource group, all of its resources are also deleted. Deleting a resource group @@ -76,7 +76,7 @@ export interface ResourceGroups { */ beginDeleteAndWait( resourceGroupName: string, - options?: ResourceGroupsDeleteOptionalParams + options?: ResourceGroupsDeleteOptionalParams, ): Promise; /** * Gets a resource group. @@ -85,7 +85,7 @@ export interface ResourceGroups { */ get( resourceGroupName: string, - options?: ResourceGroupsGetOptionalParams + options?: ResourceGroupsGetOptionalParams, ): Promise; /** * Resource groups can be updated through a simple PATCH operation to a group address. The format of @@ -98,7 +98,7 @@ export interface ResourceGroups { update( resourceGroupName: string, parameters: ResourceGroupPatchable, - options?: ResourceGroupsUpdateOptionalParams + options?: ResourceGroupsUpdateOptionalParams, ): Promise; /** * Captures the specified resource group as a template. @@ -109,7 +109,7 @@ export interface ResourceGroups { beginExportTemplate( resourceGroupName: string, parameters: ExportTemplateRequest, - options?: ResourceGroupsExportTemplateOptionalParams + options?: ResourceGroupsExportTemplateOptionalParams, ): Promise< SimplePollerLike< OperationState, @@ -125,6 +125,6 @@ export interface ResourceGroups { beginExportTemplateAndWait( resourceGroupName: string, parameters: ExportTemplateRequest, - options?: ResourceGroupsExportTemplateOptionalParams + options?: ResourceGroupsExportTemplateOptionalParams, ): Promise; } diff --git a/sdk/resources/arm-resources/src/operationsInterfaces/resources.ts b/sdk/resources/arm-resources/src/operationsInterfaces/resources.ts index 4a0e0e0452be..15fa5db00db3 100644 --- a/sdk/resources/arm-resources/src/operationsInterfaces/resources.ts +++ b/sdk/resources/arm-resources/src/operationsInterfaces/resources.ts @@ -33,7 +33,7 @@ import { ResourcesUpdateByIdOptionalParams, ResourcesUpdateByIdResponse, ResourcesGetByIdOptionalParams, - ResourcesGetByIdResponse + ResourcesGetByIdResponse, } from "../models"; /// @@ -46,14 +46,14 @@ export interface Resources { */ listByResourceGroup( resourceGroupName: string, - options?: ResourcesListByResourceGroupOptionalParams + options?: ResourcesListByResourceGroupOptionalParams, ): PagedAsyncIterableIterator; /** * Get all the resources in a subscription. * @param options The options parameters. */ list( - options?: ResourcesListOptionalParams + options?: ResourcesListOptionalParams, ): PagedAsyncIterableIterator; /** * The resources to be moved must be in the same source resource group in the source subscription being @@ -68,7 +68,7 @@ export interface Resources { beginMoveResources( sourceResourceGroupName: string, parameters: ResourcesMoveInfo, - options?: ResourcesMoveResourcesOptionalParams + options?: ResourcesMoveResourcesOptionalParams, ): Promise, void>>; /** * The resources to be moved must be in the same source resource group in the source subscription being @@ -83,7 +83,7 @@ export interface Resources { beginMoveResourcesAndWait( sourceResourceGroupName: string, parameters: ResourcesMoveInfo, - options?: ResourcesMoveResourcesOptionalParams + options?: ResourcesMoveResourcesOptionalParams, ): Promise; /** * This operation checks whether the specified resources can be moved to the target. The resources to @@ -100,7 +100,7 @@ export interface Resources { beginValidateMoveResources( sourceResourceGroupName: string, parameters: ResourcesMoveInfo, - options?: ResourcesValidateMoveResourcesOptionalParams + options?: ResourcesValidateMoveResourcesOptionalParams, ): Promise, void>>; /** * This operation checks whether the specified resources can be moved to the target. The resources to @@ -117,7 +117,7 @@ export interface Resources { beginValidateMoveResourcesAndWait( sourceResourceGroupName: string, parameters: ResourcesMoveInfo, - options?: ResourcesValidateMoveResourcesOptionalParams + options?: ResourcesValidateMoveResourcesOptionalParams, ): Promise; /** * Checks whether a resource exists. @@ -137,7 +137,7 @@ export interface Resources { resourceType: string, resourceName: string, apiVersion: string, - options?: ResourcesCheckExistenceOptionalParams + options?: ResourcesCheckExistenceOptionalParams, ): Promise; /** * Deletes a resource. @@ -157,7 +157,7 @@ export interface Resources { resourceType: string, resourceName: string, apiVersion: string, - options?: ResourcesDeleteOptionalParams + options?: ResourcesDeleteOptionalParams, ): Promise, void>>; /** * Deletes a resource. @@ -177,7 +177,7 @@ export interface Resources { resourceType: string, resourceName: string, apiVersion: string, - options?: ResourcesDeleteOptionalParams + options?: ResourcesDeleteOptionalParams, ): Promise; /** * Creates a resource. @@ -199,7 +199,7 @@ export interface Resources { resourceName: string, apiVersion: string, parameters: GenericResource, - options?: ResourcesCreateOrUpdateOptionalParams + options?: ResourcesCreateOrUpdateOptionalParams, ): Promise< SimplePollerLike< OperationState, @@ -226,7 +226,7 @@ export interface Resources { resourceName: string, apiVersion: string, parameters: GenericResource, - options?: ResourcesCreateOrUpdateOptionalParams + options?: ResourcesCreateOrUpdateOptionalParams, ): Promise; /** * Updates a resource. @@ -248,7 +248,7 @@ export interface Resources { resourceName: string, apiVersion: string, parameters: GenericResource, - options?: ResourcesUpdateOptionalParams + options?: ResourcesUpdateOptionalParams, ): Promise< SimplePollerLike< OperationState, @@ -275,7 +275,7 @@ export interface Resources { resourceName: string, apiVersion: string, parameters: GenericResource, - options?: ResourcesUpdateOptionalParams + options?: ResourcesUpdateOptionalParams, ): Promise; /** * Gets a resource. @@ -295,10 +295,12 @@ export interface Resources { resourceType: string, resourceName: string, apiVersion: string, - options?: ResourcesGetOptionalParams + options?: ResourcesGetOptionalParams, ): Promise; /** - * Checks by ID whether a resource exists. + * Checks by ID whether a resource exists. This API currently works only for a limited set of Resource + * providers. In the event that a Resource provider does not implement this API, ARM will respond with + * a 405. The alternative then is to use the GET API to check for the existence of the resource. * @param resourceId The fully qualified ID of the resource, including the resource name and resource * type. Use the format, * /subscriptions/{guid}/resourceGroups/{resource-group-name}/{resource-provider-namespace}/{resource-type}/{resource-name} @@ -308,7 +310,7 @@ export interface Resources { checkExistenceById( resourceId: string, apiVersion: string, - options?: ResourcesCheckExistenceByIdOptionalParams + options?: ResourcesCheckExistenceByIdOptionalParams, ): Promise; /** * Deletes a resource by ID. @@ -321,7 +323,7 @@ export interface Resources { beginDeleteById( resourceId: string, apiVersion: string, - options?: ResourcesDeleteByIdOptionalParams + options?: ResourcesDeleteByIdOptionalParams, ): Promise, void>>; /** * Deletes a resource by ID. @@ -334,7 +336,7 @@ export interface Resources { beginDeleteByIdAndWait( resourceId: string, apiVersion: string, - options?: ResourcesDeleteByIdOptionalParams + options?: ResourcesDeleteByIdOptionalParams, ): Promise; /** * Create a resource by ID. @@ -349,7 +351,7 @@ export interface Resources { resourceId: string, apiVersion: string, parameters: GenericResource, - options?: ResourcesCreateOrUpdateByIdOptionalParams + options?: ResourcesCreateOrUpdateByIdOptionalParams, ): Promise< SimplePollerLike< OperationState, @@ -369,7 +371,7 @@ export interface Resources { resourceId: string, apiVersion: string, parameters: GenericResource, - options?: ResourcesCreateOrUpdateByIdOptionalParams + options?: ResourcesCreateOrUpdateByIdOptionalParams, ): Promise; /** * Updates a resource by ID. @@ -384,7 +386,7 @@ export interface Resources { resourceId: string, apiVersion: string, parameters: GenericResource, - options?: ResourcesUpdateByIdOptionalParams + options?: ResourcesUpdateByIdOptionalParams, ): Promise< SimplePollerLike< OperationState, @@ -404,7 +406,7 @@ export interface Resources { resourceId: string, apiVersion: string, parameters: GenericResource, - options?: ResourcesUpdateByIdOptionalParams + options?: ResourcesUpdateByIdOptionalParams, ): Promise; /** * Gets a resource by ID. @@ -417,6 +419,6 @@ export interface Resources { getById( resourceId: string, apiVersion: string, - options?: ResourcesGetByIdOptionalParams + options?: ResourcesGetByIdOptionalParams, ): Promise; } diff --git a/sdk/resources/arm-resources/src/operationsInterfaces/tagsOperations.ts b/sdk/resources/arm-resources/src/operationsInterfaces/tagsOperations.ts index 134193a3164f..a3f1cc1e0c37 100644 --- a/sdk/resources/arm-resources/src/operationsInterfaces/tagsOperations.ts +++ b/sdk/resources/arm-resources/src/operationsInterfaces/tagsOperations.ts @@ -7,6 +7,7 @@ */ import { PagedAsyncIterableIterator } from "@azure/core-paging"; +import { SimplePollerLike, OperationState } from "@azure/core-lro"; import { TagDetails, TagsListOptionalParams, @@ -24,7 +25,7 @@ import { TagsUpdateAtScopeResponse, TagsGetAtScopeOptionalParams, TagsGetAtScopeResponse, - TagsDeleteAtScopeOptionalParams + TagsDeleteAtScopeOptionalParams, } from "../models"; /// @@ -38,7 +39,7 @@ export interface TagsOperations { * @param options The options parameters. */ list( - options?: TagsListOptionalParams + options?: TagsListOptionalParams, ): PagedAsyncIterableIterator; /** * This operation allows deleting a value from the list of predefined values for an existing predefined @@ -51,7 +52,7 @@ export interface TagsOperations { deleteValue( tagName: string, tagValue: string, - options?: TagsDeleteValueOptionalParams + options?: TagsDeleteValueOptionalParams, ): Promise; /** * This operation allows adding a value to the list of predefined values for an existing predefined tag @@ -63,7 +64,7 @@ export interface TagsOperations { createOrUpdateValue( tagName: string, tagValue: string, - options?: TagsCreateOrUpdateValueOptionalParams + options?: TagsCreateOrUpdateValueOptionalParams, ): Promise; /** * This operation allows adding a name to the list of predefined tag names for the given subscription. @@ -74,7 +75,7 @@ export interface TagsOperations { */ createOrUpdate( tagName: string, - options?: TagsCreateOrUpdateOptionalParams + options?: TagsCreateOrUpdateOptionalParams, ): Promise; /** * This operation allows deleting a name from the list of predefined tag names for the given @@ -91,10 +92,27 @@ export interface TagsOperations { * @param parameters Wrapper resource for tags API requests and responses. * @param options The options parameters. */ - createOrUpdateAtScope( + beginCreateOrUpdateAtScope( scope: string, parameters: TagsResource, - options?: TagsCreateOrUpdateAtScopeOptionalParams + options?: TagsCreateOrUpdateAtScopeOptionalParams, + ): Promise< + SimplePollerLike< + OperationState, + TagsCreateOrUpdateAtScopeResponse + > + >; + /** + * This operation allows adding or replacing the entire set of tags on the specified resource or + * subscription. The specified entity can have a maximum of 50 tags. + * @param scope The resource scope. + * @param parameters Wrapper resource for tags API requests and responses. + * @param options The options parameters. + */ + beginCreateOrUpdateAtScopeAndWait( + scope: string, + parameters: TagsResource, + options?: TagsCreateOrUpdateAtScopeOptionalParams, ): Promise; /** * This operation allows replacing, merging or selectively deleting tags on the specified resource or @@ -106,10 +124,30 @@ export interface TagsOperations { * @param parameters Wrapper resource for tags patch API request only. * @param options The options parameters. */ - updateAtScope( + beginUpdateAtScope( scope: string, parameters: TagsPatchResource, - options?: TagsUpdateAtScopeOptionalParams + options?: TagsUpdateAtScopeOptionalParams, + ): Promise< + SimplePollerLike< + OperationState, + TagsUpdateAtScopeResponse + > + >; + /** + * This operation allows replacing, merging or selectively deleting tags on the specified resource or + * subscription. The specified entity can have a maximum of 50 tags at the end of the operation. The + * 'replace' option replaces the entire set of existing tags with a new set. The 'merge' option allows + * adding tags with new names and updating the values of tags with existing names. The 'delete' option + * allows selectively deleting tags based on given names or name/value pairs. + * @param scope The resource scope. + * @param parameters Wrapper resource for tags patch API request only. + * @param options The options parameters. + */ + beginUpdateAtScopeAndWait( + scope: string, + parameters: TagsPatchResource, + options?: TagsUpdateAtScopeOptionalParams, ): Promise; /** * Gets the entire set of tags on a resource or subscription. @@ -118,15 +156,24 @@ export interface TagsOperations { */ getAtScope( scope: string, - options?: TagsGetAtScopeOptionalParams + options?: TagsGetAtScopeOptionalParams, ): Promise; /** * Deletes the entire set of tags on a resource or subscription. * @param scope The resource scope. * @param options The options parameters. */ - deleteAtScope( + beginDeleteAtScope( + scope: string, + options?: TagsDeleteAtScopeOptionalParams, + ): Promise, void>>; + /** + * Deletes the entire set of tags on a resource or subscription. + * @param scope The resource scope. + * @param options The options parameters. + */ + beginDeleteAtScopeAndWait( scope: string, - options?: TagsDeleteAtScopeOptionalParams + options?: TagsDeleteAtScopeOptionalParams, ): Promise; } diff --git a/sdk/resources/arm-resources/src/pagingHelper.ts b/sdk/resources/arm-resources/src/pagingHelper.ts index 269a2b9814b5..205cccc26592 100644 --- a/sdk/resources/arm-resources/src/pagingHelper.ts +++ b/sdk/resources/arm-resources/src/pagingHelper.ts @@ -28,7 +28,7 @@ export function getContinuationToken(page: unknown): string | undefined { export function setContinuationToken( page: unknown, - continuationToken: string | undefined + continuationToken: string | undefined, ): void { if (typeof page !== "object" || page === null || !continuationToken) { return; diff --git a/sdk/resources/arm-resources/src/resourceManagementClient.ts b/sdk/resources/arm-resources/src/resourceManagementClient.ts index b6e0ea258726..b31e63950f40 100644 --- a/sdk/resources/arm-resources/src/resourceManagementClient.ts +++ b/sdk/resources/arm-resources/src/resourceManagementClient.ts @@ -11,7 +11,7 @@ import * as coreRestPipeline from "@azure/core-rest-pipeline"; import { PipelineRequest, PipelineResponse, - SendRequest + SendRequest, } from "@azure/core-rest-pipeline"; import * as coreAuth from "@azure/core-auth"; import { @@ -22,7 +22,7 @@ import { ResourcesImpl, ResourceGroupsImpl, TagsOperationsImpl, - DeploymentOperationsImpl + DeploymentOperationsImpl, } from "./operations"; import { Operations, @@ -32,14 +32,14 @@ import { Resources, ResourceGroups, TagsOperations, - DeploymentOperations + DeploymentOperations, } from "./operationsInterfaces"; import { ResourceManagementClientOptionalParams } from "./models"; export class ResourceManagementClient extends coreClient.ServiceClient { $host: string; apiVersion: string; - subscriptionId: string; + subscriptionId?: string; /** * Initializes a new instance of the ResourceManagementClient class. @@ -50,13 +50,27 @@ export class ResourceManagementClient extends coreClient.ServiceClient { constructor( credentials: coreAuth.TokenCredential, subscriptionId: string, - options?: ResourceManagementClientOptionalParams + options?: ResourceManagementClientOptionalParams, + ); + constructor( + credentials: coreAuth.TokenCredential, + options?: ResourceManagementClientOptionalParams, + ); + constructor( + credentials: coreAuth.TokenCredential, + subscriptionIdOrOptions?: ResourceManagementClientOptionalParams | string, + options?: ResourceManagementClientOptionalParams, ) { if (credentials === undefined) { throw new Error("'credentials' cannot be null"); } - if (subscriptionId === undefined) { - throw new Error("'subscriptionId' cannot be null"); + + let subscriptionId: string | undefined; + + if (typeof subscriptionIdOrOptions === "string") { + subscriptionId = subscriptionIdOrOptions; + } else if (typeof subscriptionIdOrOptions === "object") { + options = subscriptionIdOrOptions; } // Initializing default values for options @@ -65,10 +79,10 @@ export class ResourceManagementClient extends coreClient.ServiceClient { } const defaults: ResourceManagementClientOptionalParams = { requestContentType: "application/json; charset=utf-8", - credential: credentials + credential: credentials, }; - const packageDetails = `azsdk-js-arm-resources/5.2.1`; + const packageDetails = `azsdk-js-arm-resources/6.0.0`; const userAgentPrefix = options.userAgentOptions && options.userAgentOptions.userAgentPrefix ? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}` @@ -78,20 +92,21 @@ export class ResourceManagementClient extends coreClient.ServiceClient { ...defaults, ...options, userAgentOptions: { - userAgentPrefix + userAgentPrefix, }, endpoint: - options.endpoint ?? options.baseUri ?? "https://management.azure.com" + options.endpoint ?? options.baseUri ?? "https://management.azure.com", }; super(optionsWithDefaults); let bearerTokenAuthenticationPolicyFound: boolean = false; if (options?.pipeline && options.pipeline.getOrderedPolicies().length > 0) { - const pipelinePolicies: coreRestPipeline.PipelinePolicy[] = options.pipeline.getOrderedPolicies(); + const pipelinePolicies: coreRestPipeline.PipelinePolicy[] = + options.pipeline.getOrderedPolicies(); bearerTokenAuthenticationPolicyFound = pipelinePolicies.some( (pipelinePolicy) => pipelinePolicy.name === - coreRestPipeline.bearerTokenAuthenticationPolicyName + coreRestPipeline.bearerTokenAuthenticationPolicyName, ); } if ( @@ -101,7 +116,7 @@ export class ResourceManagementClient extends coreClient.ServiceClient { !bearerTokenAuthenticationPolicyFound ) { this.pipeline.removePolicy({ - name: coreRestPipeline.bearerTokenAuthenticationPolicyName + name: coreRestPipeline.bearerTokenAuthenticationPolicyName, }); this.pipeline.addPolicy( coreRestPipeline.bearerTokenAuthenticationPolicy({ @@ -111,9 +126,9 @@ export class ResourceManagementClient extends coreClient.ServiceClient { `${optionsWithDefaults.endpoint}/.default`, challengeCallbacks: { authorizeRequestOnChallenge: - coreClient.authorizeRequestOnClaimChallenge - } - }) + coreClient.authorizeRequestOnClaimChallenge, + }, + }), ); } // Parameter assignments @@ -121,7 +136,7 @@ export class ResourceManagementClient extends coreClient.ServiceClient { // Assigning values to Constant parameters this.$host = options.$host || "https://management.azure.com"; - this.apiVersion = options.apiVersion || "2021-04-01"; + this.apiVersion = options.apiVersion || "2024-11-01"; this.operations = new OperationsImpl(this); this.deployments = new DeploymentsImpl(this); this.providers = new ProvidersImpl(this); @@ -142,7 +157,7 @@ export class ResourceManagementClient extends coreClient.ServiceClient { name: "CustomApiVersionPolicy", async sendRequest( request: PipelineRequest, - next: SendRequest + next: SendRequest, ): Promise { const param = request.url.split("?"); if (param.length > 1) { @@ -156,7 +171,7 @@ export class ResourceManagementClient extends coreClient.ServiceClient { request.url = param[0] + "?" + newParams.join("&"); } return next(request); - } + }, }; this.pipeline.addPolicy(apiVersionPolicy); } diff --git a/sdk/resources/arm-resources/test/sampleTest.ts b/sdk/resources/arm-resources/test/sampleTest.ts new file mode 100644 index 000000000000..d64be981b694 --- /dev/null +++ b/sdk/resources/arm-resources/test/sampleTest.ts @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +import { + Recorder, + RecorderStartOptions, + env, +} from "@azure-tools/test-recorder"; +import { assert } from "chai"; +import { Context } from "mocha"; + +const replaceableVariables: Record = { + AZURE_CLIENT_ID: "azure_client_id", + AZURE_CLIENT_SECRET: "azure_client_secret", + AZURE_TENANT_ID: "88888888-8888-8888-8888-888888888888", + SUBSCRIPTION_ID: "azure_subscription_id", +}; + +const recorderOptions: RecorderStartOptions = { + envSetupForPlayback: replaceableVariables, +}; + +describe("My test", () => { + let recorder: Recorder; + + beforeEach(async function (this: Context) { + recorder = new Recorder(this.currentTest); + await recorder.start(recorderOptions); + }); + + afterEach(async function () { + await recorder.stop(); + }); + + it("sample test", async function () { + console.log("Hi, I'm a test!"); + }); +}); diff --git a/sdk/resources/arm-resources/tsconfig.json b/sdk/resources/arm-resources/tsconfig.json index b26efa5c66ab..3e6ae96443f3 100644 --- a/sdk/resources/arm-resources/tsconfig.json +++ b/sdk/resources/arm-resources/tsconfig.json @@ -15,17 +15,11 @@ ], "declaration": true, "outDir": "./dist-esm", - "importHelpers": true, - "paths": { - "@azure/arm-resources": [ - "./src/index" - ] - } + "importHelpers": true }, "include": [ "./src/**/*.ts", - "./test/**/*.ts", - "samples-dev/**/*.ts" + "./test/**/*.ts" ], "exclude": [ "node_modules" diff --git a/sdk/resourcesdeploymentstacks/arm-resourcesdeploymentstacks/_meta.json b/sdk/resourcesdeploymentstacks/arm-resourcesdeploymentstacks/_meta.json index 711ebacb70e8..28591836c37e 100644 --- a/sdk/resourcesdeploymentstacks/arm-resourcesdeploymentstacks/_meta.json +++ b/sdk/resourcesdeploymentstacks/arm-resourcesdeploymentstacks/_meta.json @@ -1,8 +1,8 @@ { - "commit": "3a9110b06d1053fb4ef5f5c56002506dcc283c95", + "commit": "5342edb61d78cec6e07b17a6cd8f7749c6697272", "readme": "specification/resources/resource-manager/readme.md", - "autorest_command": "autorest --version=3.9.7 --typescript --modelerfour.lenient-model-deduplication --azure-arm --head-as-boolean=true --license-header=MICROSOFT_MIT_NO_VERSION --generate-test --typescript-sdks-folder=D:\\Git\\azure-sdk-for-js ..\\azure-rest-api-specs\\specification\\resources\\resource-manager\\readme.md --use=@autorest/typescript@6.0.23 --generate-sample=true", + "autorest_command": "autorest --version=3.9.7 --typescript --modelerfour.lenient-model-deduplication --azure-arm --head-as-boolean=true --license-header=MICROSOFT_MIT_NO_VERSION --generate-test --typescript-sdks-folder=/mnt/vss/_work/1/s/azure-sdk-for-js ../azure-rest-api-specs/specification/resources/resource-manager/readme.md --use=@autorest/typescript@^6.0.12", "repository_url": "https://github.com/Azure/azure-rest-api-specs.git", - "release_tool": "@azure-tools/js-sdk-release-tools@2.7.9", - "use": "@autorest/typescript@6.0.23" + "release_tool": "@azure-tools/js-sdk-release-tools@2.7.14", + "use": "@autorest/typescript@^6.0.12" } \ No newline at end of file diff --git a/sdk/resourcesdeploymentstacks/arm-resourcesdeploymentstacks/package.json b/sdk/resourcesdeploymentstacks/arm-resourcesdeploymentstacks/package.json index aee822acc423..1d3ba8e5f913 100644 --- a/sdk/resourcesdeploymentstacks/arm-resourcesdeploymentstacks/package.json +++ b/sdk/resourcesdeploymentstacks/arm-resourcesdeploymentstacks/package.json @@ -8,11 +8,11 @@ "node": ">=18.0.0" }, "dependencies": { - "@azure/abort-controller": "^1.0.0", - "@azure/core-auth": "^1.6.0", - "@azure/core-client": "^1.7.0", "@azure/core-lro": "^2.5.4", + "@azure/abort-controller": "^2.1.2", "@azure/core-paging": "^1.2.0", + "@azure/core-client": "^1.7.0", + "@azure/core-auth": "^1.6.0", "@azure/core-rest-pipeline": "^1.14.0", "tslib": "^2.2.0" }, @@ -28,20 +28,24 @@ "module": "./dist-esm/src/index.js", "types": "./types/arm-resourcesdeploymentstacks.d.ts", "devDependencies": { - "@azure-tools/test-credential": "^1.1.0", - "@azure-tools/test-recorder": "^3.0.0", + "@microsoft/api-extractor": "^7.31.1", + "mkdirp": "^3.0.1", + "typescript": "~5.5.3", + "uglify-js": "^3.4.9", + "rimraf": "^5.0.0", + "dotenv": "^16.0.0", "@azure/dev-tool": "^1.0.0", - "@azure/identity": "^4.0.1", - "@types/chai": "^4.2.8", + "@azure/identity": "^4.2.1", + "@azure-tools/test-recorder": "^3.0.0", + "@azure-tools/test-credential": "^1.1.0", + "mocha": "^10.0.0", "@types/mocha": "^10.0.0", - "@types/node": "^18.0.0", + "tsx": "^4.7.1", + "@types/chai": "^4.2.8", "chai": "^4.2.0", "cross-env": "^7.0.2", - "dotenv": "^16.0.0", - "mocha": "^10.0.0", - "ts-node": "^10.0.0", - "tsx": "^4.7.1", - "typescript": "~5.6.2" + "@types/node": "^18.0.0", + "ts-node": "^10.0.0" }, "repository": { "type": "git", @@ -68,30 +72,29 @@ "types/*" ], "scripts": { - "build": "npm run clean && tsc && dev-tool run bundle && npm run minify && dev-tool run vendored mkdirp ./review && npm run extract-api", - "build:browser": "echo skipped", + "build": "npm run clean && tsc && dev-tool run bundle && npm run minify && mkdirp ./review && npm run extract-api", + "minify": "uglifyjs -c -m --comments --source-map \"content='./dist/index.js.map'\" -o ./dist/index.min.js ./dist/index.js", + "prepack": "npm run build", + "pack": "npm pack 2>&1", + "extract-api": "dev-tool run extract-api", + "lint": "echo skipped", + "clean": "rimraf --glob dist dist-browser dist-esm test-dist temp types *.tgz *.log", "build:node": "echo skipped", - "build:samples": "echo skipped.", + "build:browser": "echo skipped", "build:test": "echo skipped", + "build:samples": "echo skipped.", "check-format": "echo skipped", - "clean": "dev-tool run vendored rimraf --glob dist dist-browser dist-esm test-dist temp types *.tgz *.log", "execute:samples": "echo skipped", - "extract-api": "dev-tool run extract-api", "format": "echo skipped", - "integration-test": "npm run integration-test:node && npm run integration-test:browser", - "integration-test:browser": "echo skipped", - "integration-test:node": "dev-tool run test:node-ts-input -- --timeout 1200000 'test/*.ts'", - "lint": "echo skipped", - "minify": "dev-tool run vendored uglifyjs -c -m --comments --source-map \"content='./dist/index.js.map'\" -o ./dist/index.min.js ./dist/index.js", - "pack": "npm pack 2>&1", - "prepack": "npm run build", "test": "npm run integration-test", - "test:browser": "echo skipped", "test:node": "echo skipped", + "test:browser": "echo skipped", "unit-test": "npm run unit-test:node && npm run unit-test:browser", - "unit-test:browser": "echo skipped", "unit-test:node": "cross-env TEST_MODE=playback npm run integration-test:node", - "update-snippets": "echo skipped" + "unit-test:browser": "echo skipped", + "integration-test": "npm run integration-test:node && npm run integration-test:browser", + "integration-test:node": "dev-tool run test:node-ts-input -- --timeout 1200000 'test/*.ts'", + "integration-test:browser": "echo skipped" }, "sideEffects": false, "//metadata": { @@ -103,13 +106,5 @@ ] }, "autoPublish": true, - "homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/resourcesdeploymentstacks/arm-resourcesdeploymentstacks", - "//sampleConfiguration": { - "productName": "", - "productSlugs": [ - "azure" - ], - "disableDocsMs": true, - "apiRefLink": "https://docs.microsoft.com/javascript/api/@azure/arm-resourcesdeploymentstacks?view=azure-node-preview" - } -} + "homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/resourcesdeploymentstacks/arm-resourcesdeploymentstacks" +} \ No newline at end of file diff --git a/sdk/resourcesdeploymentstacks/arm-resourcesdeploymentstacks/test/sampleTest.ts b/sdk/resourcesdeploymentstacks/arm-resourcesdeploymentstacks/test/sampleTest.ts new file mode 100644 index 000000000000..d64be981b694 --- /dev/null +++ b/sdk/resourcesdeploymentstacks/arm-resourcesdeploymentstacks/test/sampleTest.ts @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +import { + Recorder, + RecorderStartOptions, + env, +} from "@azure-tools/test-recorder"; +import { assert } from "chai"; +import { Context } from "mocha"; + +const replaceableVariables: Record = { + AZURE_CLIENT_ID: "azure_client_id", + AZURE_CLIENT_SECRET: "azure_client_secret", + AZURE_TENANT_ID: "88888888-8888-8888-8888-888888888888", + SUBSCRIPTION_ID: "azure_subscription_id", +}; + +const recorderOptions: RecorderStartOptions = { + envSetupForPlayback: replaceableVariables, +}; + +describe("My test", () => { + let recorder: Recorder; + + beforeEach(async function (this: Context) { + recorder = new Recorder(this.currentTest); + await recorder.start(recorderOptions); + }); + + afterEach(async function () { + await recorder.stop(); + }); + + it("sample test", async function () { + console.log("Hi, I'm a test!"); + }); +}); diff --git a/sdk/resourcesdeploymentstacks/arm-resourcesdeploymentstacks/tsconfig.json b/sdk/resourcesdeploymentstacks/arm-resourcesdeploymentstacks/tsconfig.json index 322d36191552..bd91d2811430 100644 --- a/sdk/resourcesdeploymentstacks/arm-resourcesdeploymentstacks/tsconfig.json +++ b/sdk/resourcesdeploymentstacks/arm-resourcesdeploymentstacks/tsconfig.json @@ -15,17 +15,20 @@ ], "declaration": true, "outDir": "./dist-esm", - "importHelpers": true, - "paths": { - "@azure/arm-resourcesdeploymentstacks": [ - "./src/index" - ] - } + "importHelpers": true }, "include": [ "./src/**/*.ts", "./test/**/*.ts", - "samples-dev/**/*.ts" + "./test/**/*.ts", + "./test/**/*.ts", + "./test/**/*.ts", + "./test/**/*.ts", + "./test/**/*.ts", + "./test/**/*.ts", + "./test/**/*.ts", + "./test/**/*.ts", + "./test/**/*.ts" ], "exclude": [ "node_modules" diff --git a/sdk/templatespecs/arm-templatespecs/CHANGELOG.md b/sdk/templatespecs/arm-templatespecs/CHANGELOG.md index cabbd0a67e3b..a26a0c397672 100644 --- a/sdk/templatespecs/arm-templatespecs/CHANGELOG.md +++ b/sdk/templatespecs/arm-templatespecs/CHANGELOG.md @@ -1,15 +1,33 @@ # Release History - -## 2.1.1 (Unreleased) - + +## 3.0.0 (2024-11-01) + ### Features Added -### Breaking Changes - -### Bugs Fixed + - Added operation TemplateSpecs.getBuiltIn + - Added operation TemplateSpecs.listBuiltIns + - Added operation TemplateSpecVersions.getBuiltIn + - Added operation TemplateSpecVersions.listBuiltIns + - Added Interface TemplateSpecsGetBuiltInOptionalParams + - Added Interface TemplateSpecsListBuiltInsNextOptionalParams + - Added Interface TemplateSpecsListBuiltInsOptionalParams + - Added Interface TemplateSpecVersionsGetBuiltInOptionalParams + - Added Interface TemplateSpecVersionsListBuiltInsNextOptionalParams + - Added Interface TemplateSpecVersionsListBuiltInsOptionalParams + - Added Type Alias TemplateSpecsGetBuiltInResponse + - Added Type Alias TemplateSpecsListBuiltInsNextResponse + - Added Type Alias TemplateSpecsListBuiltInsResponse + - Added Type Alias TemplateSpecVersionsGetBuiltInResponse + - Added Type Alias TemplateSpecVersionsListBuiltInsNextResponse + - Added Type Alias TemplateSpecVersionsListBuiltInsResponse -### Other Changes +### Breaking Changes + - Class TemplateSpecsClient has a new signature + - Interface TemplateSpecsListByResourceGroupNextOptionalParams no longer has parameter expand + - Interface TemplateSpecsListBySubscriptionNextOptionalParams no longer has parameter expand + + ## 2.1.0 (2022-11-23) ### Features Added @@ -21,10 +39,10 @@ ## 2.0.1 (2022-04-18) -### Features Added +**features** - Bug fix ## 2.0.0 (2021-12-16) -- The package of @azure/arm-templatespecs is using our next generation design principles. To learn more, please refer to our documentation [Quick Start](https://aka.ms/azsdk/js/mgmt/quickstart ). +- The package of @azure/arm-templatespecs is using our next generation design principles. To learn more, please refer to our documentation [Quick Start](https://aka.ms/azsdk/js/mgmt/quickstart). diff --git a/sdk/templatespecs/arm-templatespecs/LICENSE b/sdk/templatespecs/arm-templatespecs/LICENSE index 5d1d36e0af80..7d5934740965 100644 --- a/sdk/templatespecs/arm-templatespecs/LICENSE +++ b/sdk/templatespecs/arm-templatespecs/LICENSE @@ -1,6 +1,6 @@ The MIT License (MIT) -Copyright (c) 2022 Microsoft +Copyright (c) 2024 Microsoft Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal diff --git a/sdk/templatespecs/arm-templatespecs/_meta.json b/sdk/templatespecs/arm-templatespecs/_meta.json index 4b98b8203a1f..28591836c37e 100644 --- a/sdk/templatespecs/arm-templatespecs/_meta.json +++ b/sdk/templatespecs/arm-templatespecs/_meta.json @@ -1,8 +1,8 @@ { - "commit": "a42f1b58607091c4f255ead152a8ef323fa0b280", - "readme": "specification\\resources\\resource-manager\\readme.md", - "autorest_command": "autorest --version=3.8.4 --typescript --modelerfour.lenient-model-deduplication --azure-arm --head-as-boolean=true --license-header=MICROSOFT_MIT_NO_VERSION --generate-test --typescript-sdks-folder=D:\\Git\\azure-sdk-for-js ..\\azure-rest-api-specs\\specification\\resources\\resource-manager\\readme.md --use=@autorest/typescript@6.0.0-rc.3.20221108.1 --generate-sample=true", + "commit": "5342edb61d78cec6e07b17a6cd8f7749c6697272", + "readme": "specification/resources/resource-manager/readme.md", + "autorest_command": "autorest --version=3.9.7 --typescript --modelerfour.lenient-model-deduplication --azure-arm --head-as-boolean=true --license-header=MICROSOFT_MIT_NO_VERSION --generate-test --typescript-sdks-folder=/mnt/vss/_work/1/s/azure-sdk-for-js ../azure-rest-api-specs/specification/resources/resource-manager/readme.md --use=@autorest/typescript@^6.0.12", "repository_url": "https://github.com/Azure/azure-rest-api-specs.git", - "release_tool": "@azure-tools/js-sdk-release-tools@2.4.2", - "use": "@autorest/typescript@6.0.0-rc.3.20221108.1" + "release_tool": "@azure-tools/js-sdk-release-tools@2.7.14", + "use": "@autorest/typescript@^6.0.12" } \ No newline at end of file diff --git a/sdk/templatespecs/arm-templatespecs/package.json b/sdk/templatespecs/arm-templatespecs/package.json index 71a6d9ee0a8f..679bba96345a 100644 --- a/sdk/templatespecs/arm-templatespecs/package.json +++ b/sdk/templatespecs/arm-templatespecs/package.json @@ -3,15 +3,15 @@ "sdk-type": "mgmt", "author": "Microsoft Corporation", "description": "A generated SDK for TemplateSpecsClient.", - "version": "2.1.1", + "version": "3.0.0", "engines": { "node": ">=18.0.0" }, "dependencies": { - "@azure/core-auth": "^1.3.0", - "@azure/core-client": "^1.6.1", "@azure/core-paging": "^1.2.0", - "@azure/core-rest-pipeline": "^1.8.0", + "@azure/core-client": "^1.7.0", + "@azure/core-auth": "^1.6.0", + "@azure/core-rest-pipeline": "^1.14.0", "tslib": "^2.2.0" }, "keywords": [ @@ -26,20 +26,25 @@ "module": "./dist-esm/src/index.js", "types": "./types/arm-templatespecs.d.ts", "devDependencies": { - "@azure-tools/test-credential": "^1.0.0", - "@azure-tools/test-recorder": "^3.0.0", + "@microsoft/api-extractor": "^7.31.1", + "mkdirp": "^3.0.1", + "typescript": "~5.5.3", + "uglify-js": "^3.4.9", + "rimraf": "^5.0.0", + "dotenv": "^16.0.0", "@azure/dev-tool": "^1.0.0", - "@azure/identity": "^4.0.1", - "@types/chai": "^4.2.8", + "@azure/identity": "^4.2.1", + "@azure-tools/test-recorder": "^3.0.0", + "@azure-tools/test-credential": "^1.1.0", + "mocha": "^10.0.0", "@types/mocha": "^10.0.0", - "@types/node": "^18.0.0", + "tsx": "^4.7.1", + "@types/chai": "^4.2.8", "chai": "^4.2.0", "cross-env": "^7.0.2", - "mocha": "^10.0.0", - "ts-node": "^10.0.0", - "typescript": "~5.6.2" + "@types/node": "^18.0.0", + "ts-node": "^10.0.0" }, - "homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/templatespecs/arm-templatespecs", "repository": { "type": "git", "url": "https://github.com/Azure/azure-sdk-for-js.git" @@ -65,30 +70,29 @@ "types/*" ], "scripts": { - "build": "npm run clean && tsc && dev-tool run bundle && npm run minify && dev-tool run vendored mkdirp ./review && npm run extract-api", - "build:browser": "echo skipped", + "build": "npm run clean && tsc && dev-tool run bundle && npm run minify && mkdirp ./review && npm run extract-api", + "minify": "uglifyjs -c -m --comments --source-map \"content='./dist/index.js.map'\" -o ./dist/index.min.js ./dist/index.js", + "prepack": "npm run build", + "pack": "npm pack 2>&1", + "extract-api": "dev-tool run extract-api", + "lint": "echo skipped", + "clean": "rimraf --glob dist dist-browser dist-esm test-dist temp types *.tgz *.log", "build:node": "echo skipped", - "build:samples": "echo skipped.", + "build:browser": "echo skipped", "build:test": "echo skipped", + "build:samples": "echo skipped.", "check-format": "echo skipped", - "clean": "dev-tool run vendored rimraf --glob dist dist-browser dist-esm test-dist temp types *.tgz *.log", "execute:samples": "echo skipped", - "extract-api": "dev-tool run extract-api", "format": "echo skipped", - "integration-test": "npm run integration-test:node && npm run integration-test:browser", - "integration-test:browser": "echo skipped", - "integration-test:node": "dev-tool run test:node-ts-input -- --timeout 1200000 'test/*.ts'", - "lint": "echo skipped", - "minify": "dev-tool run vendored uglifyjs -c -m --comments --source-map \"content='./dist/index.js.map'\" -o ./dist/index.min.js ./dist/index.js", - "pack": "npm pack 2>&1", - "prepack": "npm run build", "test": "npm run integration-test", - "test:browser": "echo skipped", "test:node": "echo skipped", + "test:browser": "echo skipped", "unit-test": "npm run unit-test:node && npm run unit-test:browser", - "unit-test:browser": "echo skipped", "unit-test:node": "cross-env TEST_MODE=playback npm run integration-test:node", - "update-snippets": "echo skipped" + "unit-test:browser": "echo skipped", + "integration-test": "npm run integration-test:node && npm run integration-test:browser", + "integration-test:node": "dev-tool run test:node-ts-input -- --timeout 1200000 'test/*.ts'", + "integration-test:browser": "echo skipped" }, "sideEffects": false, "//metadata": { @@ -100,12 +104,5 @@ ] }, "autoPublish": true, - "//sampleConfiguration": { - "productName": "", - "productSlugs": [ - "azure" - ], - "disableDocsMs": true, - "apiRefLink": "https://docs.microsoft.com/javascript/api/@azure/arm-templatespecs?view=azure-node-preview" - } -} + "homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/templatespecs/arm-templatespecs" +} \ No newline at end of file diff --git a/sdk/templatespecs/arm-templatespecs/review/arm-templatespecs.api.md b/sdk/templatespecs/arm-templatespecs/review/arm-templatespecs.api.md index 56c81b6f8c56..a45a09d0af6b 100644 --- a/sdk/templatespecs/arm-templatespecs/review/arm-templatespecs.api.md +++ b/sdk/templatespecs/arm-templatespecs/review/arm-templatespecs.api.md @@ -88,6 +88,8 @@ export interface TemplateSpecs { createOrUpdate(resourceGroupName: string, templateSpecName: string, templateSpec: TemplateSpec, options?: TemplateSpecsCreateOrUpdateOptionalParams): Promise; delete(resourceGroupName: string, templateSpecName: string, options?: TemplateSpecsDeleteOptionalParams): Promise; get(resourceGroupName: string, templateSpecName: string, options?: TemplateSpecsGetOptionalParams): Promise; + getBuiltIn(templateSpecName: string, options?: TemplateSpecsGetBuiltInOptionalParams): Promise; + listBuiltIns(options?: TemplateSpecsListBuiltInsOptionalParams): PagedAsyncIterableIterator; listByResourceGroup(resourceGroupName: string, options?: TemplateSpecsListByResourceGroupOptionalParams): PagedAsyncIterableIterator; listBySubscription(options?: TemplateSpecsListBySubscriptionOptionalParams): PagedAsyncIterableIterator; update(resourceGroupName: string, templateSpecName: string, options?: TemplateSpecsUpdateOptionalParams): Promise; @@ -98,10 +100,11 @@ export class TemplateSpecsClient extends coreClient.ServiceClient { // (undocumented) $host: string; constructor(credentials: coreAuth.TokenCredential, subscriptionId: string, options?: TemplateSpecsClientOptionalParams); + constructor(credentials: coreAuth.TokenCredential, options?: TemplateSpecsClientOptionalParams); // (undocumented) apiVersion: string; // (undocumented) - subscriptionId: string; + subscriptionId?: string; // (undocumented) templateSpecs: TemplateSpecs; // (undocumented) @@ -131,6 +134,14 @@ export interface TemplateSpecsError { error?: ErrorResponse; } +// @public +export interface TemplateSpecsGetBuiltInOptionalParams extends coreClient.OperationOptions { + expand?: TemplateSpecExpandKind; +} + +// @public +export type TemplateSpecsGetBuiltInResponse = TemplateSpec; + // @public export interface TemplateSpecsGetOptionalParams extends coreClient.OperationOptions { expand?: TemplateSpecExpandKind; @@ -140,10 +151,24 @@ export interface TemplateSpecsGetOptionalParams extends coreClient.OperationOpti export type TemplateSpecsGetResponse = TemplateSpec; // @public -export interface TemplateSpecsListByResourceGroupNextOptionalParams extends coreClient.OperationOptions { +export interface TemplateSpecsListBuiltInsNextOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type TemplateSpecsListBuiltInsNextResponse = TemplateSpecsListResult; + +// @public +export interface TemplateSpecsListBuiltInsOptionalParams extends coreClient.OperationOptions { expand?: TemplateSpecExpandKind; } +// @public +export type TemplateSpecsListBuiltInsResponse = TemplateSpecsListResult; + +// @public +export interface TemplateSpecsListByResourceGroupNextOptionalParams extends coreClient.OperationOptions { +} + // @public export type TemplateSpecsListByResourceGroupNextResponse = TemplateSpecsListResult; @@ -157,7 +182,6 @@ export type TemplateSpecsListByResourceGroupResponse = TemplateSpecsListResult; // @public export interface TemplateSpecsListBySubscriptionNextOptionalParams extends coreClient.OperationOptions { - expand?: TemplateSpecExpandKind; } // @public @@ -217,7 +241,9 @@ export interface TemplateSpecVersions { createOrUpdate(resourceGroupName: string, templateSpecName: string, templateSpecVersion: string, templateSpecVersionModel: TemplateSpecVersion, options?: TemplateSpecVersionsCreateOrUpdateOptionalParams): Promise; delete(resourceGroupName: string, templateSpecName: string, templateSpecVersion: string, options?: TemplateSpecVersionsDeleteOptionalParams): Promise; get(resourceGroupName: string, templateSpecName: string, templateSpecVersion: string, options?: TemplateSpecVersionsGetOptionalParams): Promise; + getBuiltIn(templateSpecName: string, templateSpecVersion: string, options?: TemplateSpecVersionsGetBuiltInOptionalParams): Promise; list(resourceGroupName: string, templateSpecName: string, options?: TemplateSpecVersionsListOptionalParams): PagedAsyncIterableIterator; + listBuiltIns(templateSpecName: string, options?: TemplateSpecVersionsListBuiltInsOptionalParams): PagedAsyncIterableIterator; update(resourceGroupName: string, templateSpecName: string, templateSpecVersion: string, options?: TemplateSpecVersionsUpdateOptionalParams): Promise; } @@ -232,6 +258,13 @@ export type TemplateSpecVersionsCreateOrUpdateResponse = TemplateSpecVersion; export interface TemplateSpecVersionsDeleteOptionalParams extends coreClient.OperationOptions { } +// @public +export interface TemplateSpecVersionsGetBuiltInOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type TemplateSpecVersionsGetBuiltInResponse = TemplateSpecVersion; + // @public export interface TemplateSpecVersionsGetOptionalParams extends coreClient.OperationOptions { } @@ -239,6 +272,20 @@ export interface TemplateSpecVersionsGetOptionalParams extends coreClient.Operat // @public export type TemplateSpecVersionsGetResponse = TemplateSpecVersion; +// @public +export interface TemplateSpecVersionsListBuiltInsNextOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type TemplateSpecVersionsListBuiltInsNextResponse = TemplateSpecVersionsListResult; + +// @public +export interface TemplateSpecVersionsListBuiltInsOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type TemplateSpecVersionsListBuiltInsResponse = TemplateSpecVersionsListResult; + // @public export interface TemplateSpecVersionsListNextOptionalParams extends coreClient.OperationOptions { } diff --git a/sdk/templatespecs/arm-templatespecs/src/models/index.ts b/sdk/templatespecs/arm-templatespecs/src/models/index.ts index f5969135d28f..177fa2d2f020 100644 --- a/sdk/templatespecs/arm-templatespecs/src/models/index.ts +++ b/sdk/templatespecs/arm-templatespecs/src/models/index.ts @@ -204,7 +204,7 @@ export enum KnownCreatedByType { /** ManagedIdentity */ ManagedIdentity = "ManagedIdentity", /** Key */ - Key = "Key" + Key = "Key", } /** @@ -222,7 +222,7 @@ export type CreatedByType = string; /** Known values of {@link TemplateSpecExpandKind} that the service accepts. */ export enum KnownTemplateSpecExpandKind { /** Includes version information with the Template Spec. */ - Versions = "versions" + Versions = "versions", } /** @@ -286,24 +286,47 @@ export interface TemplateSpecsListByResourceGroupOptionalParams export type TemplateSpecsListByResourceGroupResponse = TemplateSpecsListResult; /** Optional parameters. */ -export interface TemplateSpecsListBySubscriptionNextOptionalParams +export interface TemplateSpecsGetBuiltInOptionalParams extends coreClient.OperationOptions { /** Allows for expansion of additional Template Spec details in the response. Optional. */ expand?: TemplateSpecExpandKind; } -/** Contains response data for the listBySubscriptionNext operation. */ -export type TemplateSpecsListBySubscriptionNextResponse = TemplateSpecsListResult; +/** Contains response data for the getBuiltIn operation. */ +export type TemplateSpecsGetBuiltInResponse = TemplateSpec; /** Optional parameters. */ -export interface TemplateSpecsListByResourceGroupNextOptionalParams +export interface TemplateSpecsListBuiltInsOptionalParams extends coreClient.OperationOptions { /** Allows for expansion of additional Template Spec details in the response. Optional. */ expand?: TemplateSpecExpandKind; } +/** Contains response data for the listBuiltIns operation. */ +export type TemplateSpecsListBuiltInsResponse = TemplateSpecsListResult; + +/** Optional parameters. */ +export interface TemplateSpecsListBySubscriptionNextOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the listBySubscriptionNext operation. */ +export type TemplateSpecsListBySubscriptionNextResponse = + TemplateSpecsListResult; + +/** Optional parameters. */ +export interface TemplateSpecsListByResourceGroupNextOptionalParams + extends coreClient.OperationOptions {} + /** Contains response data for the listByResourceGroupNext operation. */ -export type TemplateSpecsListByResourceGroupNextResponse = TemplateSpecsListResult; +export type TemplateSpecsListByResourceGroupNextResponse = + TemplateSpecsListResult; + +/** Optional parameters. */ +export interface TemplateSpecsListBuiltInsNextOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the listBuiltInsNext operation. */ +export type TemplateSpecsListBuiltInsNextResponse = TemplateSpecsListResult; /** Optional parameters. */ export interface TemplateSpecVersionsCreateOrUpdateOptionalParams @@ -340,12 +363,36 @@ export interface TemplateSpecVersionsListOptionalParams /** Contains response data for the list operation. */ export type TemplateSpecVersionsListResponse = TemplateSpecVersionsListResult; +/** Optional parameters. */ +export interface TemplateSpecVersionsListBuiltInsOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the listBuiltIns operation. */ +export type TemplateSpecVersionsListBuiltInsResponse = + TemplateSpecVersionsListResult; + +/** Optional parameters. */ +export interface TemplateSpecVersionsGetBuiltInOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the getBuiltIn operation. */ +export type TemplateSpecVersionsGetBuiltInResponse = TemplateSpecVersion; + /** Optional parameters. */ export interface TemplateSpecVersionsListNextOptionalParams extends coreClient.OperationOptions {} /** Contains response data for the listNext operation. */ -export type TemplateSpecVersionsListNextResponse = TemplateSpecVersionsListResult; +export type TemplateSpecVersionsListNextResponse = + TemplateSpecVersionsListResult; + +/** Optional parameters. */ +export interface TemplateSpecVersionsListBuiltInsNextOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the listBuiltInsNext operation. */ +export type TemplateSpecVersionsListBuiltInsNextResponse = + TemplateSpecVersionsListResult; /** Optional parameters. */ export interface TemplateSpecsClientOptionalParams diff --git a/sdk/templatespecs/arm-templatespecs/src/models/mappers.ts b/sdk/templatespecs/arm-templatespecs/src/models/mappers.ts index b005c1e9585b..40955cd6bbdb 100644 --- a/sdk/templatespecs/arm-templatespecs/src/models/mappers.ts +++ b/sdk/templatespecs/arm-templatespecs/src/models/mappers.ts @@ -17,25 +17,25 @@ export const TemplateSpecVersionInfo: coreClient.CompositeMapper = { serializedName: "description", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, timeCreated: { serializedName: "timeCreated", readOnly: true, type: { - name: "DateTime" - } + name: "DateTime", + }, }, timeModified: { serializedName: "timeModified", readOnly: true, type: { - name: "DateTime" - } - } - } - } + name: "DateTime", + }, + }, + }, + }, }; export const AzureResourceBase: coreClient.CompositeMapper = { @@ -47,32 +47,32 @@ export const AzureResourceBase: coreClient.CompositeMapper = { serializedName: "id", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, name: { serializedName: "name", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, type: { serializedName: "type", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, systemData: { serializedName: "systemData", type: { name: "Composite", - className: "SystemData" - } - } - } - } + className: "SystemData", + }, + }, + }, + }, }; export const SystemData: coreClient.CompositeMapper = { @@ -83,41 +83,41 @@ export const SystemData: coreClient.CompositeMapper = { createdBy: { serializedName: "createdBy", type: { - name: "String" - } + name: "String", + }, }, createdByType: { serializedName: "createdByType", type: { - name: "String" - } + name: "String", + }, }, createdAt: { serializedName: "createdAt", type: { - name: "DateTime" - } + name: "DateTime", + }, }, lastModifiedBy: { serializedName: "lastModifiedBy", type: { - name: "String" - } + name: "String", + }, }, lastModifiedByType: { serializedName: "lastModifiedByType", type: { - name: "String" - } + name: "String", + }, }, lastModifiedAt: { serializedName: "lastModifiedAt", type: { - name: "DateTime" - } - } - } - } + name: "DateTime", + }, + }, + }, + }, }; export const TemplateSpecsError: coreClient.CompositeMapper = { @@ -129,11 +129,11 @@ export const TemplateSpecsError: coreClient.CompositeMapper = { serializedName: "error", type: { name: "Composite", - className: "ErrorResponse" - } - } - } - } + className: "ErrorResponse", + }, + }, + }, + }, }; export const ErrorResponse: coreClient.CompositeMapper = { @@ -145,22 +145,22 @@ export const ErrorResponse: coreClient.CompositeMapper = { serializedName: "code", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, message: { serializedName: "message", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, target: { serializedName: "target", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, details: { serializedName: "details", @@ -170,10 +170,10 @@ export const ErrorResponse: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "ErrorResponse" - } - } - } + className: "ErrorResponse", + }, + }, + }, }, additionalInfo: { serializedName: "additionalInfo", @@ -183,13 +183,13 @@ export const ErrorResponse: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "ErrorAdditionalInfo" - } - } - } - } - } - } + className: "ErrorAdditionalInfo", + }, + }, + }, + }, + }, + }, }; export const ErrorAdditionalInfo: coreClient.CompositeMapper = { @@ -201,19 +201,19 @@ export const ErrorAdditionalInfo: coreClient.CompositeMapper = { serializedName: "type", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, info: { serializedName: "info", readOnly: true, type: { name: "Dictionary", - value: { type: { name: "any" } } - } - } - } - } + value: { type: { name: "any" } }, + }, + }, + }, + }, }; export const TemplateSpecsListResult: coreClient.CompositeMapper = { @@ -228,20 +228,20 @@ export const TemplateSpecsListResult: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "TemplateSpec" - } - } - } + className: "TemplateSpec", + }, + }, + }, }, nextLink: { serializedName: "nextLink", readOnly: true, type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const LinkedTemplateArtifact: coreClient.CompositeMapper = { @@ -253,19 +253,19 @@ export const LinkedTemplateArtifact: coreClient.CompositeMapper = { serializedName: "path", required: true, type: { - name: "String" - } + name: "String", + }, }, template: { serializedName: "template", required: true, type: { name: "Dictionary", - value: { type: { name: "any" } } - } - } - } - } + value: { type: { name: "any" } }, + }, + }, + }, + }, }; export const TemplateSpecVersionsListResult: coreClient.CompositeMapper = { @@ -280,20 +280,20 @@ export const TemplateSpecVersionsListResult: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "TemplateSpecVersion" - } - } - } + className: "TemplateSpecVersion", + }, + }, + }, }, nextLink: { serializedName: "nextLink", readOnly: true, type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const TemplateSpec: coreClient.CompositeMapper = { @@ -306,40 +306,40 @@ export const TemplateSpec: coreClient.CompositeMapper = { serializedName: "location", required: true, type: { - name: "String" - } + name: "String", + }, }, tags: { serializedName: "tags", type: { name: "Dictionary", - value: { type: { name: "String" } } - } + value: { type: { name: "String" } }, + }, }, description: { constraints: { - MaxLength: 4096 + MaxLength: 4096, }, serializedName: "properties.description", type: { - name: "String" - } + name: "String", + }, }, displayName: { constraints: { - MaxLength: 64 + MaxLength: 64, }, serializedName: "properties.displayName", type: { - name: "String" - } + name: "String", + }, }, metadata: { serializedName: "properties.metadata", type: { name: "Dictionary", - value: { type: { name: "any" } } - } + value: { type: { name: "any" } }, + }, }, versions: { serializedName: "properties.versions", @@ -347,12 +347,12 @@ export const TemplateSpec: coreClient.CompositeMapper = { type: { name: "Dictionary", value: { - type: { name: "Composite", className: "TemplateSpecVersionInfo" } - } - } - } - } - } + type: { name: "Composite", className: "TemplateSpecVersionInfo" }, + }, + }, + }, + }, + }, }; export const TemplateSpecUpdateModel: coreClient.CompositeMapper = { @@ -365,11 +365,11 @@ export const TemplateSpecUpdateModel: coreClient.CompositeMapper = { serializedName: "tags", type: { name: "Dictionary", - value: { type: { name: "String" } } - } - } - } - } + value: { type: { name: "String" } }, + }, + }, + }, + }, }; export const TemplateSpecVersion: coreClient.CompositeMapper = { @@ -382,24 +382,24 @@ export const TemplateSpecVersion: coreClient.CompositeMapper = { serializedName: "location", required: true, type: { - name: "String" - } + name: "String", + }, }, tags: { serializedName: "tags", type: { name: "Dictionary", - value: { type: { name: "String" } } - } + value: { type: { name: "String" } }, + }, }, description: { constraints: { - MaxLength: 4096 + MaxLength: 4096, }, serializedName: "properties.description", type: { - name: "String" - } + name: "String", + }, }, linkedTemplates: { serializedName: "properties.linkedTemplates", @@ -408,34 +408,34 @@ export const TemplateSpecVersion: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "LinkedTemplateArtifact" - } - } - } + className: "LinkedTemplateArtifact", + }, + }, + }, }, metadata: { serializedName: "properties.metadata", type: { name: "Dictionary", - value: { type: { name: "any" } } - } + value: { type: { name: "any" } }, + }, }, mainTemplate: { serializedName: "properties.mainTemplate", type: { name: "Dictionary", - value: { type: { name: "any" } } - } + value: { type: { name: "any" } }, + }, }, uiFormDefinition: { serializedName: "properties.uiFormDefinition", type: { name: "Dictionary", - value: { type: { name: "any" } } - } - } - } - } + value: { type: { name: "any" } }, + }, + }, + }, + }, }; export const TemplateSpecVersionUpdateModel: coreClient.CompositeMapper = { @@ -448,9 +448,9 @@ export const TemplateSpecVersionUpdateModel: coreClient.CompositeMapper = { serializedName: "tags", type: { name: "Dictionary", - value: { type: { name: "String" } } - } - } - } - } + value: { type: { name: "String" } }, + }, + }, + }, + }, }; diff --git a/sdk/templatespecs/arm-templatespecs/src/models/parameters.ts b/sdk/templatespecs/arm-templatespecs/src/models/parameters.ts index e73e2a813d0a..1f582549f5cc 100644 --- a/sdk/templatespecs/arm-templatespecs/src/models/parameters.ts +++ b/sdk/templatespecs/arm-templatespecs/src/models/parameters.ts @@ -9,13 +9,13 @@ import { OperationParameter, OperationURLParameter, - OperationQueryParameter + OperationQueryParameter, } from "@azure/core-client"; import { TemplateSpec as TemplateSpecMapper, TemplateSpecUpdateModel as TemplateSpecUpdateModelMapper, TemplateSpecVersion as TemplateSpecVersionMapper, - TemplateSpecVersionUpdateModel as TemplateSpecVersionUpdateModelMapper + TemplateSpecVersionUpdateModel as TemplateSpecVersionUpdateModelMapper, } from "../models/mappers"; export const contentType: OperationParameter = { @@ -25,14 +25,14 @@ export const contentType: OperationParameter = { isConstant: true, serializedName: "Content-Type", type: { - name: "String" - } - } + name: "String", + }, + }, }; export const templateSpec: OperationParameter = { parameterPath: "templateSpec", - mapper: TemplateSpecMapper + mapper: TemplateSpecMapper, }; export const accept: OperationParameter = { @@ -42,9 +42,9 @@ export const accept: OperationParameter = { isConstant: true, serializedName: "Accept", type: { - name: "String" - } - } + name: "String", + }, + }, }; export const $host: OperationURLParameter = { @@ -53,10 +53,10 @@ export const $host: OperationURLParameter = { serializedName: "$host", required: true, type: { - name: "String" - } + name: "String", + }, }, - skipEncoding: true + skipEncoding: true, }; export const subscriptionId: OperationURLParameter = { @@ -65,9 +65,9 @@ export const subscriptionId: OperationURLParameter = { serializedName: "subscriptionId", required: true, type: { - name: "String" - } - } + name: "String", + }, + }, }; export const resourceGroupName: OperationURLParameter = { @@ -76,14 +76,14 @@ export const resourceGroupName: OperationURLParameter = { constraints: { Pattern: new RegExp("^[-\\w\\._\\(\\)]+$"), MaxLength: 90, - MinLength: 1 + MinLength: 1, }, serializedName: "resourceGroupName", required: true, type: { - name: "String" - } - } + name: "String", + }, + }, }; export const templateSpecName: OperationURLParameter = { @@ -92,31 +92,31 @@ export const templateSpecName: OperationURLParameter = { constraints: { Pattern: new RegExp("^[-\\w\\._\\(\\)]+$"), MaxLength: 90, - MinLength: 1 + MinLength: 1, }, serializedName: "templateSpecName", required: true, type: { - name: "String" - } - } + name: "String", + }, + }, }; export const apiVersion: OperationQueryParameter = { parameterPath: "apiVersion", mapper: { - defaultValue: "2021-05-01", + defaultValue: "2022-02-01", isConstant: true, serializedName: "api-version", type: { - name: "String" - } - } + name: "String", + }, + }, }; export const templateSpec1: OperationParameter = { parameterPath: ["options", "templateSpec"], - mapper: TemplateSpecUpdateModelMapper + mapper: TemplateSpecUpdateModelMapper, }; export const expand: OperationQueryParameter = { @@ -124,9 +124,9 @@ export const expand: OperationQueryParameter = { mapper: { serializedName: "$expand", type: { - name: "String" - } - } + name: "String", + }, + }, }; export const nextLink: OperationURLParameter = { @@ -135,15 +135,15 @@ export const nextLink: OperationURLParameter = { serializedName: "nextLink", required: true, type: { - name: "String" - } + name: "String", + }, }, - skipEncoding: true + skipEncoding: true, }; export const templateSpecVersionModel: OperationParameter = { parameterPath: "templateSpecVersionModel", - mapper: TemplateSpecVersionMapper + mapper: TemplateSpecVersionMapper, }; export const templateSpecVersion: OperationURLParameter = { @@ -152,17 +152,17 @@ export const templateSpecVersion: OperationURLParameter = { constraints: { Pattern: new RegExp("^[-\\w\\._\\(\\)]+$"), MaxLength: 90, - MinLength: 1 + MinLength: 1, }, serializedName: "templateSpecVersion", required: true, type: { - name: "String" - } - } + name: "String", + }, + }, }; export const templateSpecVersionUpdateModel: OperationParameter = { parameterPath: ["options", "templateSpecVersionUpdateModel"], - mapper: TemplateSpecVersionUpdateModelMapper + mapper: TemplateSpecVersionUpdateModelMapper, }; diff --git a/sdk/templatespecs/arm-templatespecs/src/operations/templateSpecVersions.ts b/sdk/templatespecs/arm-templatespecs/src/operations/templateSpecVersions.ts index b83a63c3b034..beb8adb13058 100644 --- a/sdk/templatespecs/arm-templatespecs/src/operations/templateSpecVersions.ts +++ b/sdk/templatespecs/arm-templatespecs/src/operations/templateSpecVersions.ts @@ -18,6 +18,9 @@ import { TemplateSpecVersionsListNextOptionalParams, TemplateSpecVersionsListOptionalParams, TemplateSpecVersionsListResponse, + TemplateSpecVersionsListBuiltInsNextOptionalParams, + TemplateSpecVersionsListBuiltInsOptionalParams, + TemplateSpecVersionsListBuiltInsResponse, TemplateSpecVersionsCreateOrUpdateOptionalParams, TemplateSpecVersionsCreateOrUpdateResponse, TemplateSpecVersionsUpdateOptionalParams, @@ -25,7 +28,10 @@ import { TemplateSpecVersionsGetOptionalParams, TemplateSpecVersionsGetResponse, TemplateSpecVersionsDeleteOptionalParams, - TemplateSpecVersionsListNextResponse + TemplateSpecVersionsGetBuiltInOptionalParams, + TemplateSpecVersionsGetBuiltInResponse, + TemplateSpecVersionsListNextResponse, + TemplateSpecVersionsListBuiltInsNextResponse, } from "../models"; /// @@ -50,12 +56,12 @@ export class TemplateSpecVersionsImpl implements TemplateSpecVersions { public list( resourceGroupName: string, templateSpecName: string, - options?: TemplateSpecVersionsListOptionalParams + options?: TemplateSpecVersionsListOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listPagingAll( resourceGroupName, templateSpecName, - options + options, ); return { next() { @@ -72,9 +78,9 @@ export class TemplateSpecVersionsImpl implements TemplateSpecVersions { resourceGroupName, templateSpecName, options, - settings + settings, ); - } + }, }; } @@ -82,7 +88,7 @@ export class TemplateSpecVersionsImpl implements TemplateSpecVersions { resourceGroupName: string, templateSpecName: string, options?: TemplateSpecVersionsListOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: TemplateSpecVersionsListResponse; let continuationToken = settings?.continuationToken; @@ -98,7 +104,7 @@ export class TemplateSpecVersionsImpl implements TemplateSpecVersions { resourceGroupName, templateSpecName, continuationToken, - options + options, ); continuationToken = result.nextLink; let page = result.value || []; @@ -110,12 +116,77 @@ export class TemplateSpecVersionsImpl implements TemplateSpecVersions { private async *listPagingAll( resourceGroupName: string, templateSpecName: string, - options?: TemplateSpecVersionsListOptionalParams + options?: TemplateSpecVersionsListOptionalParams, ): AsyncIterableIterator { for await (const page of this.listPagingPage( resourceGroupName, templateSpecName, - options + options, + )) { + yield* page; + } + } + + /** + * Lists all the Template Spec versions in the specified built-in Template Spec. + * @param templateSpecName Name of the Template Spec. + * @param options The options parameters. + */ + public listBuiltIns( + templateSpecName: string, + options?: TemplateSpecVersionsListBuiltInsOptionalParams, + ): PagedAsyncIterableIterator { + const iter = this.listBuiltInsPagingAll(templateSpecName, options); + return { + next() { + return iter.next(); + }, + [Symbol.asyncIterator]() { + return this; + }, + byPage: (settings?: PageSettings) => { + if (settings?.maxPageSize) { + throw new Error("maxPageSize is not supported by this operation."); + } + return this.listBuiltInsPagingPage(templateSpecName, options, settings); + }, + }; + } + + private async *listBuiltInsPagingPage( + templateSpecName: string, + options?: TemplateSpecVersionsListBuiltInsOptionalParams, + settings?: PageSettings, + ): AsyncIterableIterator { + let result: TemplateSpecVersionsListBuiltInsResponse; + let continuationToken = settings?.continuationToken; + if (!continuationToken) { + result = await this._listBuiltIns(templateSpecName, options); + let page = result.value || []; + continuationToken = result.nextLink; + setContinuationToken(page, continuationToken); + yield page; + } + while (continuationToken) { + result = await this._listBuiltInsNext( + templateSpecName, + continuationToken, + options, + ); + continuationToken = result.nextLink; + let page = result.value || []; + setContinuationToken(page, continuationToken); + yield page; + } + } + + private async *listBuiltInsPagingAll( + templateSpecName: string, + options?: TemplateSpecVersionsListBuiltInsOptionalParams, + ): AsyncIterableIterator { + for await (const page of this.listBuiltInsPagingPage( + templateSpecName, + options, )) { yield* page; } @@ -134,7 +205,7 @@ export class TemplateSpecVersionsImpl implements TemplateSpecVersions { templateSpecName: string, templateSpecVersion: string, templateSpecVersionModel: TemplateSpecVersion, - options?: TemplateSpecVersionsCreateOrUpdateOptionalParams + options?: TemplateSpecVersionsCreateOrUpdateOptionalParams, ): Promise { return this.client.sendOperationRequest( { @@ -142,9 +213,9 @@ export class TemplateSpecVersionsImpl implements TemplateSpecVersions { templateSpecName, templateSpecVersion, templateSpecVersionModel, - options + options, }, - createOrUpdateOperationSpec + createOrUpdateOperationSpec, ); } @@ -159,11 +230,11 @@ export class TemplateSpecVersionsImpl implements TemplateSpecVersions { resourceGroupName: string, templateSpecName: string, templateSpecVersion: string, - options?: TemplateSpecVersionsUpdateOptionalParams + options?: TemplateSpecVersionsUpdateOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceGroupName, templateSpecName, templateSpecVersion, options }, - updateOperationSpec + updateOperationSpec, ); } @@ -178,11 +249,11 @@ export class TemplateSpecVersionsImpl implements TemplateSpecVersions { resourceGroupName: string, templateSpecName: string, templateSpecVersion: string, - options?: TemplateSpecVersionsGetOptionalParams + options?: TemplateSpecVersionsGetOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceGroupName, templateSpecName, templateSpecVersion, options }, - getOperationSpec + getOperationSpec, ); } @@ -198,11 +269,11 @@ export class TemplateSpecVersionsImpl implements TemplateSpecVersions { resourceGroupName: string, templateSpecName: string, templateSpecVersion: string, - options?: TemplateSpecVersionsDeleteOptionalParams + options?: TemplateSpecVersionsDeleteOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceGroupName, templateSpecName, templateSpecVersion, options }, - deleteOperationSpec + deleteOperationSpec, ); } @@ -215,11 +286,43 @@ export class TemplateSpecVersionsImpl implements TemplateSpecVersions { private _list( resourceGroupName: string, templateSpecName: string, - options?: TemplateSpecVersionsListOptionalParams + options?: TemplateSpecVersionsListOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceGroupName, templateSpecName, options }, - listOperationSpec + listOperationSpec, + ); + } + + /** + * Lists all the Template Spec versions in the specified built-in Template Spec. + * @param templateSpecName Name of the Template Spec. + * @param options The options parameters. + */ + private _listBuiltIns( + templateSpecName: string, + options?: TemplateSpecVersionsListBuiltInsOptionalParams, + ): Promise { + return this.client.sendOperationRequest( + { templateSpecName, options }, + listBuiltInsOperationSpec, + ); + } + + /** + * Gets a Template Spec version from a specific built-in Template Spec. + * @param templateSpecName Name of the Template Spec. + * @param templateSpecVersion The version of the Template Spec. + * @param options The options parameters. + */ + getBuiltIn( + templateSpecName: string, + templateSpecVersion: string, + options?: TemplateSpecVersionsGetBuiltInOptionalParams, + ): Promise { + return this.client.sendOperationRequest( + { templateSpecName, templateSpecVersion, options }, + getBuiltInOperationSpec, ); } @@ -234,11 +337,28 @@ export class TemplateSpecVersionsImpl implements TemplateSpecVersions { resourceGroupName: string, templateSpecName: string, nextLink: string, - options?: TemplateSpecVersionsListNextOptionalParams + options?: TemplateSpecVersionsListNextOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceGroupName, templateSpecName, nextLink, options }, - listNextOperationSpec + listNextOperationSpec, + ); + } + + /** + * ListBuiltInsNext + * @param templateSpecName Name of the Template Spec. + * @param nextLink The nextLink from the previous successful call to the ListBuiltIns method. + * @param options The options parameters. + */ + private _listBuiltInsNext( + templateSpecName: string, + nextLink: string, + options?: TemplateSpecVersionsListBuiltInsNextOptionalParams, + ): Promise { + return this.client.sendOperationRequest( + { templateSpecName, nextLink, options }, + listBuiltInsNextOperationSpec, ); } } @@ -246,19 +366,18 @@ export class TemplateSpecVersionsImpl implements TemplateSpecVersions { const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); const createOrUpdateOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Resources/templateSpecs/{templateSpecName}/versions/{templateSpecVersion}", + path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Resources/templateSpecs/{templateSpecName}/versions/{templateSpecVersion}", httpMethod: "PUT", responses: { 200: { - bodyMapper: Mappers.TemplateSpecVersion + bodyMapper: Mappers.TemplateSpecVersion, }, 201: { - bodyMapper: Mappers.TemplateSpecVersion + bodyMapper: Mappers.TemplateSpecVersion, }, default: { - bodyMapper: Mappers.TemplateSpecsError - } + bodyMapper: Mappers.TemplateSpecsError, + }, }, requestBody: Parameters.templateSpecVersionModel, queryParameters: [Parameters.apiVersion], @@ -267,23 +386,22 @@ const createOrUpdateOperationSpec: coreClient.OperationSpec = { Parameters.subscriptionId, Parameters.resourceGroupName, Parameters.templateSpecName, - Parameters.templateSpecVersion + Parameters.templateSpecVersion, ], headerParameters: [Parameters.contentType, Parameters.accept], mediaType: "json", - serializer + serializer, }; const updateOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Resources/templateSpecs/{templateSpecName}/versions/{templateSpecVersion}", + path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Resources/templateSpecs/{templateSpecName}/versions/{templateSpecVersion}", httpMethod: "PATCH", responses: { 200: { - bodyMapper: Mappers.TemplateSpecVersion + bodyMapper: Mappers.TemplateSpecVersion, }, default: { - bodyMapper: Mappers.TemplateSpecsError - } + bodyMapper: Mappers.TemplateSpecsError, + }, }, requestBody: Parameters.templateSpecVersionUpdateModel, queryParameters: [Parameters.apiVersion], @@ -292,23 +410,22 @@ const updateOperationSpec: coreClient.OperationSpec = { Parameters.subscriptionId, Parameters.resourceGroupName, Parameters.templateSpecName, - Parameters.templateSpecVersion + Parameters.templateSpecVersion, ], headerParameters: [Parameters.contentType, Parameters.accept], mediaType: "json", - serializer + serializer, }; const getOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Resources/templateSpecs/{templateSpecName}/versions/{templateSpecVersion}", + path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Resources/templateSpecs/{templateSpecName}/versions/{templateSpecVersion}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.TemplateSpecVersion + bodyMapper: Mappers.TemplateSpecVersion, }, default: { - bodyMapper: Mappers.TemplateSpecsError - } + bodyMapper: Mappers.TemplateSpecsError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ @@ -316,21 +433,20 @@ const getOperationSpec: coreClient.OperationSpec = { Parameters.subscriptionId, Parameters.resourceGroupName, Parameters.templateSpecName, - Parameters.templateSpecVersion + Parameters.templateSpecVersion, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const deleteOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Resources/templateSpecs/{templateSpecName}/versions/{templateSpecVersion}", + path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Resources/templateSpecs/{templateSpecName}/versions/{templateSpecVersion}", httpMethod: "DELETE", responses: { 200: {}, 204: {}, default: { - bodyMapper: Mappers.TemplateSpecsError - } + bodyMapper: Mappers.TemplateSpecsError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ @@ -338,52 +454,105 @@ const deleteOperationSpec: coreClient.OperationSpec = { Parameters.subscriptionId, Parameters.resourceGroupName, Parameters.templateSpecName, - Parameters.templateSpecVersion + Parameters.templateSpecVersion, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const listOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Resources/templateSpecs/{templateSpecName}/versions", + path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Resources/templateSpecs/{templateSpecName}/versions", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.TemplateSpecVersionsListResult + bodyMapper: Mappers.TemplateSpecVersionsListResult, }, default: { - bodyMapper: Mappers.TemplateSpecsError - } + bodyMapper: Mappers.TemplateSpecsError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.templateSpecName + Parameters.templateSpecName, ], headerParameters: [Parameters.accept], - serializer + serializer, +}; +const listBuiltInsOperationSpec: coreClient.OperationSpec = { + path: "/providers/Microsoft.Resources/builtInTemplateSpecs/{templateSpecName}/versions", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.TemplateSpecVersionsListResult, + }, + default: { + bodyMapper: Mappers.TemplateSpecsError, + }, + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [Parameters.$host, Parameters.templateSpecName], + headerParameters: [Parameters.accept], + serializer, +}; +const getBuiltInOperationSpec: coreClient.OperationSpec = { + path: "/providers/Microsoft.Resources/builtInTemplateSpecs/{templateSpecName}/versions/{templateSpecVersion}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.TemplateSpecVersion, + }, + default: { + bodyMapper: Mappers.TemplateSpecsError, + }, + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.templateSpecName, + Parameters.templateSpecVersion, + ], + headerParameters: [Parameters.accept], + serializer, }; const listNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.TemplateSpecVersionsListResult + bodyMapper: Mappers.TemplateSpecVersionsListResult, }, default: { - bodyMapper: Mappers.TemplateSpecsError - } + bodyMapper: Mappers.TemplateSpecsError, + }, }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, Parameters.templateSpecName, - Parameters.nextLink + Parameters.nextLink, + ], + headerParameters: [Parameters.accept], + serializer, +}; +const listBuiltInsNextOperationSpec: coreClient.OperationSpec = { + path: "{nextLink}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.TemplateSpecVersionsListResult, + }, + default: { + bodyMapper: Mappers.TemplateSpecsError, + }, + }, + urlParameters: [ + Parameters.$host, + Parameters.templateSpecName, + Parameters.nextLink, ], headerParameters: [Parameters.accept], - serializer + serializer, }; diff --git a/sdk/templatespecs/arm-templatespecs/src/operations/templateSpecs.ts b/sdk/templatespecs/arm-templatespecs/src/operations/templateSpecs.ts index e64c4815016e..aff1f7b60629 100644 --- a/sdk/templatespecs/arm-templatespecs/src/operations/templateSpecs.ts +++ b/sdk/templatespecs/arm-templatespecs/src/operations/templateSpecs.ts @@ -21,6 +21,9 @@ import { TemplateSpecsListByResourceGroupNextOptionalParams, TemplateSpecsListByResourceGroupOptionalParams, TemplateSpecsListByResourceGroupResponse, + TemplateSpecsListBuiltInsNextOptionalParams, + TemplateSpecsListBuiltInsOptionalParams, + TemplateSpecsListBuiltInsResponse, TemplateSpecsCreateOrUpdateOptionalParams, TemplateSpecsCreateOrUpdateResponse, TemplateSpecsUpdateOptionalParams, @@ -28,8 +31,11 @@ import { TemplateSpecsGetOptionalParams, TemplateSpecsGetResponse, TemplateSpecsDeleteOptionalParams, + TemplateSpecsGetBuiltInOptionalParams, + TemplateSpecsGetBuiltInResponse, TemplateSpecsListBySubscriptionNextResponse, - TemplateSpecsListByResourceGroupNextResponse + TemplateSpecsListByResourceGroupNextResponse, + TemplateSpecsListBuiltInsNextResponse, } from "../models"; /// @@ -50,7 +56,7 @@ export class TemplateSpecsImpl implements TemplateSpecs { * @param options The options parameters. */ public listBySubscription( - options?: TemplateSpecsListBySubscriptionOptionalParams + options?: TemplateSpecsListBySubscriptionOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listBySubscriptionPagingAll(options); return { @@ -65,13 +71,13 @@ export class TemplateSpecsImpl implements TemplateSpecs { throw new Error("maxPageSize is not supported by this operation."); } return this.listBySubscriptionPagingPage(options, settings); - } + }, }; } private async *listBySubscriptionPagingPage( options?: TemplateSpecsListBySubscriptionOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: TemplateSpecsListBySubscriptionResponse; let continuationToken = settings?.continuationToken; @@ -92,7 +98,7 @@ export class TemplateSpecsImpl implements TemplateSpecs { } private async *listBySubscriptionPagingAll( - options?: TemplateSpecsListBySubscriptionOptionalParams + options?: TemplateSpecsListBySubscriptionOptionalParams, ): AsyncIterableIterator { for await (const page of this.listBySubscriptionPagingPage(options)) { yield* page; @@ -106,7 +112,7 @@ export class TemplateSpecsImpl implements TemplateSpecs { */ public listByResourceGroup( resourceGroupName: string, - options?: TemplateSpecsListByResourceGroupOptionalParams + options?: TemplateSpecsListByResourceGroupOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listByResourceGroupPagingAll(resourceGroupName, options); return { @@ -123,16 +129,16 @@ export class TemplateSpecsImpl implements TemplateSpecs { return this.listByResourceGroupPagingPage( resourceGroupName, options, - settings + settings, ); - } + }, }; } private async *listByResourceGroupPagingPage( resourceGroupName: string, options?: TemplateSpecsListByResourceGroupOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: TemplateSpecsListByResourceGroupResponse; let continuationToken = settings?.continuationToken; @@ -147,7 +153,7 @@ export class TemplateSpecsImpl implements TemplateSpecs { result = await this._listByResourceGroupNext( resourceGroupName, continuationToken, - options + options, ); continuationToken = result.nextLink; let page = result.value || []; @@ -158,16 +164,70 @@ export class TemplateSpecsImpl implements TemplateSpecs { private async *listByResourceGroupPagingAll( resourceGroupName: string, - options?: TemplateSpecsListByResourceGroupOptionalParams + options?: TemplateSpecsListByResourceGroupOptionalParams, ): AsyncIterableIterator { for await (const page of this.listByResourceGroupPagingPage( resourceGroupName, - options + options, )) { yield* page; } } + /** + * Lists built-in Template Specs. + * @param options The options parameters. + */ + public listBuiltIns( + options?: TemplateSpecsListBuiltInsOptionalParams, + ): PagedAsyncIterableIterator { + const iter = this.listBuiltInsPagingAll(options); + return { + next() { + return iter.next(); + }, + [Symbol.asyncIterator]() { + return this; + }, + byPage: (settings?: PageSettings) => { + if (settings?.maxPageSize) { + throw new Error("maxPageSize is not supported by this operation."); + } + return this.listBuiltInsPagingPage(options, settings); + }, + }; + } + + private async *listBuiltInsPagingPage( + options?: TemplateSpecsListBuiltInsOptionalParams, + settings?: PageSettings, + ): AsyncIterableIterator { + let result: TemplateSpecsListBuiltInsResponse; + let continuationToken = settings?.continuationToken; + if (!continuationToken) { + result = await this._listBuiltIns(options); + let page = result.value || []; + continuationToken = result.nextLink; + setContinuationToken(page, continuationToken); + yield page; + } + while (continuationToken) { + result = await this._listBuiltInsNext(continuationToken, options); + continuationToken = result.nextLink; + let page = result.value || []; + setContinuationToken(page, continuationToken); + yield page; + } + } + + private async *listBuiltInsPagingAll( + options?: TemplateSpecsListBuiltInsOptionalParams, + ): AsyncIterableIterator { + for await (const page of this.listBuiltInsPagingPage(options)) { + yield* page; + } + } + /** * Creates or updates a Template Spec. * @param resourceGroupName The name of the resource group. The name is case insensitive. @@ -179,11 +239,11 @@ export class TemplateSpecsImpl implements TemplateSpecs { resourceGroupName: string, templateSpecName: string, templateSpec: TemplateSpec, - options?: TemplateSpecsCreateOrUpdateOptionalParams + options?: TemplateSpecsCreateOrUpdateOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceGroupName, templateSpecName, templateSpec, options }, - createOrUpdateOperationSpec + createOrUpdateOperationSpec, ); } @@ -196,11 +256,11 @@ export class TemplateSpecsImpl implements TemplateSpecs { update( resourceGroupName: string, templateSpecName: string, - options?: TemplateSpecsUpdateOptionalParams + options?: TemplateSpecsUpdateOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceGroupName, templateSpecName, options }, - updateOperationSpec + updateOperationSpec, ); } @@ -213,11 +273,11 @@ export class TemplateSpecsImpl implements TemplateSpecs { get( resourceGroupName: string, templateSpecName: string, - options?: TemplateSpecsGetOptionalParams + options?: TemplateSpecsGetOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceGroupName, templateSpecName, options }, - getOperationSpec + getOperationSpec, ); } @@ -230,11 +290,11 @@ export class TemplateSpecsImpl implements TemplateSpecs { delete( resourceGroupName: string, templateSpecName: string, - options?: TemplateSpecsDeleteOptionalParams + options?: TemplateSpecsDeleteOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceGroupName, templateSpecName, options }, - deleteOperationSpec + deleteOperationSpec, ); } @@ -243,11 +303,11 @@ export class TemplateSpecsImpl implements TemplateSpecs { * @param options The options parameters. */ private _listBySubscription( - options?: TemplateSpecsListBySubscriptionOptionalParams + options?: TemplateSpecsListBySubscriptionOptionalParams, ): Promise { return this.client.sendOperationRequest( { options }, - listBySubscriptionOperationSpec + listBySubscriptionOperationSpec, ); } @@ -258,11 +318,39 @@ export class TemplateSpecsImpl implements TemplateSpecs { */ private _listByResourceGroup( resourceGroupName: string, - options?: TemplateSpecsListByResourceGroupOptionalParams + options?: TemplateSpecsListByResourceGroupOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceGroupName, options }, - listByResourceGroupOperationSpec + listByResourceGroupOperationSpec, + ); + } + + /** + * Gets a built-in Template Spec with a given name. + * @param templateSpecName Name of the Template Spec. + * @param options The options parameters. + */ + getBuiltIn( + templateSpecName: string, + options?: TemplateSpecsGetBuiltInOptionalParams, + ): Promise { + return this.client.sendOperationRequest( + { templateSpecName, options }, + getBuiltInOperationSpec, + ); + } + + /** + * Lists built-in Template Specs. + * @param options The options parameters. + */ + private _listBuiltIns( + options?: TemplateSpecsListBuiltInsOptionalParams, + ): Promise { + return this.client.sendOperationRequest( + { options }, + listBuiltInsOperationSpec, ); } @@ -273,11 +361,11 @@ export class TemplateSpecsImpl implements TemplateSpecs { */ private _listBySubscriptionNext( nextLink: string, - options?: TemplateSpecsListBySubscriptionNextOptionalParams + options?: TemplateSpecsListBySubscriptionNextOptionalParams, ): Promise { return this.client.sendOperationRequest( { nextLink, options }, - listBySubscriptionNextOperationSpec + listBySubscriptionNextOperationSpec, ); } @@ -290,11 +378,26 @@ export class TemplateSpecsImpl implements TemplateSpecs { private _listByResourceGroupNext( resourceGroupName: string, nextLink: string, - options?: TemplateSpecsListByResourceGroupNextOptionalParams + options?: TemplateSpecsListByResourceGroupNextOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceGroupName, nextLink, options }, - listByResourceGroupNextOperationSpec + listByResourceGroupNextOperationSpec, + ); + } + + /** + * ListBuiltInsNext + * @param nextLink The nextLink from the previous successful call to the ListBuiltIns method. + * @param options The options parameters. + */ + private _listBuiltInsNext( + nextLink: string, + options?: TemplateSpecsListBuiltInsNextOptionalParams, + ): Promise { + return this.client.sendOperationRequest( + { nextLink, options }, + listBuiltInsNextOperationSpec, ); } } @@ -302,19 +405,18 @@ export class TemplateSpecsImpl implements TemplateSpecs { const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); const createOrUpdateOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Resources/templateSpecs/{templateSpecName}", + path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Resources/templateSpecs/{templateSpecName}", httpMethod: "PUT", responses: { 200: { - bodyMapper: Mappers.TemplateSpec + bodyMapper: Mappers.TemplateSpec, }, 201: { - bodyMapper: Mappers.TemplateSpec + bodyMapper: Mappers.TemplateSpec, }, default: { - bodyMapper: Mappers.TemplateSpecsError - } + bodyMapper: Mappers.TemplateSpecsError, + }, }, requestBody: Parameters.templateSpec, queryParameters: [Parameters.apiVersion], @@ -322,23 +424,22 @@ const createOrUpdateOperationSpec: coreClient.OperationSpec = { Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.templateSpecName + Parameters.templateSpecName, ], headerParameters: [Parameters.contentType, Parameters.accept], mediaType: "json", - serializer + serializer, }; const updateOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Resources/templateSpecs/{templateSpecName}", + path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Resources/templateSpecs/{templateSpecName}", httpMethod: "PATCH", responses: { 200: { - bodyMapper: Mappers.TemplateSpec + bodyMapper: Mappers.TemplateSpec, }, default: { - bodyMapper: Mappers.TemplateSpecsError - } + bodyMapper: Mappers.TemplateSpecsError, + }, }, requestBody: Parameters.templateSpec1, queryParameters: [Parameters.apiVersion], @@ -346,131 +447,172 @@ const updateOperationSpec: coreClient.OperationSpec = { Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.templateSpecName + Parameters.templateSpecName, ], headerParameters: [Parameters.contentType, Parameters.accept], mediaType: "json", - serializer + serializer, }; const getOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Resources/templateSpecs/{templateSpecName}", + path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Resources/templateSpecs/{templateSpecName}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.TemplateSpec + bodyMapper: Mappers.TemplateSpec, }, default: { - bodyMapper: Mappers.TemplateSpecsError - } + bodyMapper: Mappers.TemplateSpecsError, + }, }, queryParameters: [Parameters.apiVersion, Parameters.expand], urlParameters: [ Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.templateSpecName + Parameters.templateSpecName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const deleteOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Resources/templateSpecs/{templateSpecName}", + path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Resources/templateSpecs/{templateSpecName}", httpMethod: "DELETE", responses: { 200: {}, 204: {}, default: { - bodyMapper: Mappers.TemplateSpecsError - } + bodyMapper: Mappers.TemplateSpecsError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.templateSpecName + Parameters.templateSpecName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const listBySubscriptionOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/providers/Microsoft.Resources/templateSpecs/", + path: "/subscriptions/{subscriptionId}/providers/Microsoft.Resources/templateSpecs/", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.TemplateSpecsListResult + bodyMapper: Mappers.TemplateSpecsListResult, }, default: { - bodyMapper: Mappers.TemplateSpecsError - } + bodyMapper: Mappers.TemplateSpecsError, + }, }, queryParameters: [Parameters.apiVersion, Parameters.expand], urlParameters: [Parameters.$host, Parameters.subscriptionId], headerParameters: [Parameters.accept], - serializer + serializer, }; const listByResourceGroupOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Resources/templateSpecs/", + path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Resources/templateSpecs/", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.TemplateSpecsListResult + bodyMapper: Mappers.TemplateSpecsListResult, }, default: { - bodyMapper: Mappers.TemplateSpecsError - } + bodyMapper: Mappers.TemplateSpecsError, + }, }, queryParameters: [Parameters.apiVersion, Parameters.expand], urlParameters: [ Parameters.$host, Parameters.subscriptionId, - Parameters.resourceGroupName + Parameters.resourceGroupName, ], headerParameters: [Parameters.accept], - serializer + serializer, +}; +const getBuiltInOperationSpec: coreClient.OperationSpec = { + path: "/providers/Microsoft.Resources/builtInTemplateSpecs/{templateSpecName}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.TemplateSpec, + }, + default: { + bodyMapper: Mappers.TemplateSpecsError, + }, + }, + queryParameters: [Parameters.apiVersion, Parameters.expand], + urlParameters: [Parameters.$host, Parameters.templateSpecName], + headerParameters: [Parameters.accept], + serializer, +}; +const listBuiltInsOperationSpec: coreClient.OperationSpec = { + path: "/providers/Microsoft.Resources/builtInTemplateSpecs/", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.TemplateSpecsListResult, + }, + default: { + bodyMapper: Mappers.TemplateSpecsError, + }, + }, + queryParameters: [Parameters.apiVersion, Parameters.expand], + urlParameters: [Parameters.$host], + headerParameters: [Parameters.accept], + serializer, }; const listBySubscriptionNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.TemplateSpecsListResult + bodyMapper: Mappers.TemplateSpecsListResult, }, default: { - bodyMapper: Mappers.TemplateSpecsError - } + bodyMapper: Mappers.TemplateSpecsError, + }, }, - queryParameters: [Parameters.apiVersion, Parameters.expand], urlParameters: [ Parameters.$host, Parameters.subscriptionId, - Parameters.nextLink + Parameters.nextLink, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const listByResourceGroupNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.TemplateSpecsListResult + bodyMapper: Mappers.TemplateSpecsListResult, }, default: { - bodyMapper: Mappers.TemplateSpecsError - } + bodyMapper: Mappers.TemplateSpecsError, + }, }, - queryParameters: [Parameters.apiVersion, Parameters.expand], urlParameters: [ Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.nextLink + Parameters.nextLink, ], headerParameters: [Parameters.accept], - serializer + serializer, +}; +const listBuiltInsNextOperationSpec: coreClient.OperationSpec = { + path: "{nextLink}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.TemplateSpecsListResult, + }, + default: { + bodyMapper: Mappers.TemplateSpecsError, + }, + }, + urlParameters: [Parameters.$host, Parameters.nextLink], + headerParameters: [Parameters.accept], + serializer, }; diff --git a/sdk/templatespecs/arm-templatespecs/src/operationsInterfaces/templateSpecVersions.ts b/sdk/templatespecs/arm-templatespecs/src/operationsInterfaces/templateSpecVersions.ts index 8fd4a0d9a125..6f0104c21d68 100644 --- a/sdk/templatespecs/arm-templatespecs/src/operationsInterfaces/templateSpecVersions.ts +++ b/sdk/templatespecs/arm-templatespecs/src/operationsInterfaces/templateSpecVersions.ts @@ -10,13 +10,16 @@ import { PagedAsyncIterableIterator } from "@azure/core-paging"; import { TemplateSpecVersion, TemplateSpecVersionsListOptionalParams, + TemplateSpecVersionsListBuiltInsOptionalParams, TemplateSpecVersionsCreateOrUpdateOptionalParams, TemplateSpecVersionsCreateOrUpdateResponse, TemplateSpecVersionsUpdateOptionalParams, TemplateSpecVersionsUpdateResponse, TemplateSpecVersionsGetOptionalParams, TemplateSpecVersionsGetResponse, - TemplateSpecVersionsDeleteOptionalParams + TemplateSpecVersionsDeleteOptionalParams, + TemplateSpecVersionsGetBuiltInOptionalParams, + TemplateSpecVersionsGetBuiltInResponse, } from "../models"; /// @@ -31,7 +34,16 @@ export interface TemplateSpecVersions { list( resourceGroupName: string, templateSpecName: string, - options?: TemplateSpecVersionsListOptionalParams + options?: TemplateSpecVersionsListOptionalParams, + ): PagedAsyncIterableIterator; + /** + * Lists all the Template Spec versions in the specified built-in Template Spec. + * @param templateSpecName Name of the Template Spec. + * @param options The options parameters. + */ + listBuiltIns( + templateSpecName: string, + options?: TemplateSpecVersionsListBuiltInsOptionalParams, ): PagedAsyncIterableIterator; /** * Creates or updates a Template Spec version. @@ -46,7 +58,7 @@ export interface TemplateSpecVersions { templateSpecName: string, templateSpecVersion: string, templateSpecVersionModel: TemplateSpecVersion, - options?: TemplateSpecVersionsCreateOrUpdateOptionalParams + options?: TemplateSpecVersionsCreateOrUpdateOptionalParams, ): Promise; /** * Updates Template Spec Version tags with specified values. @@ -59,7 +71,7 @@ export interface TemplateSpecVersions { resourceGroupName: string, templateSpecName: string, templateSpecVersion: string, - options?: TemplateSpecVersionsUpdateOptionalParams + options?: TemplateSpecVersionsUpdateOptionalParams, ): Promise; /** * Gets a Template Spec version from a specific Template Spec. @@ -72,7 +84,7 @@ export interface TemplateSpecVersions { resourceGroupName: string, templateSpecName: string, templateSpecVersion: string, - options?: TemplateSpecVersionsGetOptionalParams + options?: TemplateSpecVersionsGetOptionalParams, ): Promise; /** * Deletes a specific version from a Template Spec. When operation completes, status code 200 returned @@ -86,6 +98,17 @@ export interface TemplateSpecVersions { resourceGroupName: string, templateSpecName: string, templateSpecVersion: string, - options?: TemplateSpecVersionsDeleteOptionalParams + options?: TemplateSpecVersionsDeleteOptionalParams, ): Promise; + /** + * Gets a Template Spec version from a specific built-in Template Spec. + * @param templateSpecName Name of the Template Spec. + * @param templateSpecVersion The version of the Template Spec. + * @param options The options parameters. + */ + getBuiltIn( + templateSpecName: string, + templateSpecVersion: string, + options?: TemplateSpecVersionsGetBuiltInOptionalParams, + ): Promise; } diff --git a/sdk/templatespecs/arm-templatespecs/src/operationsInterfaces/templateSpecs.ts b/sdk/templatespecs/arm-templatespecs/src/operationsInterfaces/templateSpecs.ts index 0c0f41f19ff6..f09e7c56268d 100644 --- a/sdk/templatespecs/arm-templatespecs/src/operationsInterfaces/templateSpecs.ts +++ b/sdk/templatespecs/arm-templatespecs/src/operationsInterfaces/templateSpecs.ts @@ -11,13 +11,16 @@ import { TemplateSpec, TemplateSpecsListBySubscriptionOptionalParams, TemplateSpecsListByResourceGroupOptionalParams, + TemplateSpecsListBuiltInsOptionalParams, TemplateSpecsCreateOrUpdateOptionalParams, TemplateSpecsCreateOrUpdateResponse, TemplateSpecsUpdateOptionalParams, TemplateSpecsUpdateResponse, TemplateSpecsGetOptionalParams, TemplateSpecsGetResponse, - TemplateSpecsDeleteOptionalParams + TemplateSpecsDeleteOptionalParams, + TemplateSpecsGetBuiltInOptionalParams, + TemplateSpecsGetBuiltInResponse, } from "../models"; /// @@ -28,7 +31,7 @@ export interface TemplateSpecs { * @param options The options parameters. */ listBySubscription( - options?: TemplateSpecsListBySubscriptionOptionalParams + options?: TemplateSpecsListBySubscriptionOptionalParams, ): PagedAsyncIterableIterator; /** * Lists all the Template Specs within the specified resource group. @@ -37,7 +40,14 @@ export interface TemplateSpecs { */ listByResourceGroup( resourceGroupName: string, - options?: TemplateSpecsListByResourceGroupOptionalParams + options?: TemplateSpecsListByResourceGroupOptionalParams, + ): PagedAsyncIterableIterator; + /** + * Lists built-in Template Specs. + * @param options The options parameters. + */ + listBuiltIns( + options?: TemplateSpecsListBuiltInsOptionalParams, ): PagedAsyncIterableIterator; /** * Creates or updates a Template Spec. @@ -50,7 +60,7 @@ export interface TemplateSpecs { resourceGroupName: string, templateSpecName: string, templateSpec: TemplateSpec, - options?: TemplateSpecsCreateOrUpdateOptionalParams + options?: TemplateSpecsCreateOrUpdateOptionalParams, ): Promise; /** * Updates Template Spec tags with specified values. @@ -61,7 +71,7 @@ export interface TemplateSpecs { update( resourceGroupName: string, templateSpecName: string, - options?: TemplateSpecsUpdateOptionalParams + options?: TemplateSpecsUpdateOptionalParams, ): Promise; /** * Gets a Template Spec with a given name. @@ -72,7 +82,7 @@ export interface TemplateSpecs { get( resourceGroupName: string, templateSpecName: string, - options?: TemplateSpecsGetOptionalParams + options?: TemplateSpecsGetOptionalParams, ): Promise; /** * Deletes a Template Spec by name. When operation completes, status code 200 returned without content. @@ -83,6 +93,15 @@ export interface TemplateSpecs { delete( resourceGroupName: string, templateSpecName: string, - options?: TemplateSpecsDeleteOptionalParams + options?: TemplateSpecsDeleteOptionalParams, ): Promise; + /** + * Gets a built-in Template Spec with a given name. + * @param templateSpecName Name of the Template Spec. + * @param options The options parameters. + */ + getBuiltIn( + templateSpecName: string, + options?: TemplateSpecsGetBuiltInOptionalParams, + ): Promise; } diff --git a/sdk/templatespecs/arm-templatespecs/src/pagingHelper.ts b/sdk/templatespecs/arm-templatespecs/src/pagingHelper.ts index d85fc13bce1e..205cccc26592 100644 --- a/sdk/templatespecs/arm-templatespecs/src/pagingHelper.ts +++ b/sdk/templatespecs/arm-templatespecs/src/pagingHelper.ts @@ -13,11 +13,11 @@ export interface PageInfo { const pageMap = new WeakMap(); /** - * Given a result page from a pageable operation, returns a - * continuation token that can be used to begin paging from + * Given the last `.value` produced by the `byPage` iterator, + * returns a continuation token that can be used to begin paging from * that point later. - * @param page A result object from calling .byPage() on a paged operation. - * @returns The continuation token that can be passed into byPage(). + * @param page An object from accessing `value` on the IteratorResult from a `byPage` iterator. + * @returns The continuation token that can be passed into byPage() during future calls. */ export function getContinuationToken(page: unknown): string | undefined { if (typeof page !== "object" || page === null) { @@ -28,7 +28,7 @@ export function getContinuationToken(page: unknown): string | undefined { export function setContinuationToken( page: unknown, - continuationToken: string | undefined + continuationToken: string | undefined, ): void { if (typeof page !== "object" || page === null || !continuationToken) { return; diff --git a/sdk/templatespecs/arm-templatespecs/src/templateSpecsClient.ts b/sdk/templatespecs/arm-templatespecs/src/templateSpecsClient.ts index 00b5d1a469bd..eaaaff754954 100644 --- a/sdk/templatespecs/arm-templatespecs/src/templateSpecsClient.ts +++ b/sdk/templatespecs/arm-templatespecs/src/templateSpecsClient.ts @@ -11,7 +11,7 @@ import * as coreRestPipeline from "@azure/core-rest-pipeline"; import { PipelineRequest, PipelineResponse, - SendRequest + SendRequest, } from "@azure/core-rest-pipeline"; import * as coreAuth from "@azure/core-auth"; import { TemplateSpecsImpl, TemplateSpecVersionsImpl } from "./operations"; @@ -20,7 +20,7 @@ import { TemplateSpecsClientOptionalParams } from "./models"; export class TemplateSpecsClient extends coreClient.ServiceClient { $host: string; - subscriptionId: string; + subscriptionId?: string; apiVersion: string; /** @@ -32,13 +32,27 @@ export class TemplateSpecsClient extends coreClient.ServiceClient { constructor( credentials: coreAuth.TokenCredential, subscriptionId: string, - options?: TemplateSpecsClientOptionalParams + options?: TemplateSpecsClientOptionalParams, + ); + constructor( + credentials: coreAuth.TokenCredential, + options?: TemplateSpecsClientOptionalParams, + ); + constructor( + credentials: coreAuth.TokenCredential, + subscriptionIdOrOptions?: TemplateSpecsClientOptionalParams | string, + options?: TemplateSpecsClientOptionalParams, ) { if (credentials === undefined) { throw new Error("'credentials' cannot be null"); } - if (subscriptionId === undefined) { - throw new Error("'subscriptionId' cannot be null"); + + let subscriptionId: string | undefined; + + if (typeof subscriptionIdOrOptions === "string") { + subscriptionId = subscriptionIdOrOptions; + } else if (typeof subscriptionIdOrOptions === "object") { + options = subscriptionIdOrOptions; } // Initializing default values for options @@ -47,10 +61,10 @@ export class TemplateSpecsClient extends coreClient.ServiceClient { } const defaults: TemplateSpecsClientOptionalParams = { requestContentType: "application/json; charset=utf-8", - credential: credentials + credential: credentials, }; - const packageDetails = `azsdk-js-arm-templatespecs/2.1.1`; + const packageDetails = `azsdk-js-arm-templatespecs/3.0.0`; const userAgentPrefix = options.userAgentOptions && options.userAgentOptions.userAgentPrefix ? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}` @@ -60,20 +74,21 @@ export class TemplateSpecsClient extends coreClient.ServiceClient { ...defaults, ...options, userAgentOptions: { - userAgentPrefix + userAgentPrefix, }, endpoint: - options.endpoint ?? options.baseUri ?? "https://management.azure.com" + options.endpoint ?? options.baseUri ?? "https://management.azure.com", }; super(optionsWithDefaults); let bearerTokenAuthenticationPolicyFound: boolean = false; if (options?.pipeline && options.pipeline.getOrderedPolicies().length > 0) { - const pipelinePolicies: coreRestPipeline.PipelinePolicy[] = options.pipeline.getOrderedPolicies(); + const pipelinePolicies: coreRestPipeline.PipelinePolicy[] = + options.pipeline.getOrderedPolicies(); bearerTokenAuthenticationPolicyFound = pipelinePolicies.some( (pipelinePolicy) => pipelinePolicy.name === - coreRestPipeline.bearerTokenAuthenticationPolicyName + coreRestPipeline.bearerTokenAuthenticationPolicyName, ); } if ( @@ -83,7 +98,7 @@ export class TemplateSpecsClient extends coreClient.ServiceClient { !bearerTokenAuthenticationPolicyFound ) { this.pipeline.removePolicy({ - name: coreRestPipeline.bearerTokenAuthenticationPolicyName + name: coreRestPipeline.bearerTokenAuthenticationPolicyName, }); this.pipeline.addPolicy( coreRestPipeline.bearerTokenAuthenticationPolicy({ @@ -93,9 +108,9 @@ export class TemplateSpecsClient extends coreClient.ServiceClient { `${optionsWithDefaults.endpoint}/.default`, challengeCallbacks: { authorizeRequestOnChallenge: - coreClient.authorizeRequestOnClaimChallenge - } - }) + coreClient.authorizeRequestOnClaimChallenge, + }, + }), ); } // Parameter assignments @@ -103,7 +118,7 @@ export class TemplateSpecsClient extends coreClient.ServiceClient { // Assigning values to Constant parameters this.$host = options.$host || "https://management.azure.com"; - this.apiVersion = options.apiVersion || "2021-05-01"; + this.apiVersion = options.apiVersion || "2022-02-01"; this.templateSpecs = new TemplateSpecsImpl(this); this.templateSpecVersions = new TemplateSpecVersionsImpl(this); this.addCustomApiVersionPolicy(options.apiVersion); @@ -118,7 +133,7 @@ export class TemplateSpecsClient extends coreClient.ServiceClient { name: "CustomApiVersionPolicy", async sendRequest( request: PipelineRequest, - next: SendRequest + next: SendRequest, ): Promise { const param = request.url.split("?"); if (param.length > 1) { @@ -132,7 +147,7 @@ export class TemplateSpecsClient extends coreClient.ServiceClient { request.url = param[0] + "?" + newParams.join("&"); } return next(request); - } + }, }; this.pipeline.addPolicy(apiVersionPolicy); } diff --git a/sdk/templatespecs/arm-templatespecs/test/sampleTest.ts b/sdk/templatespecs/arm-templatespecs/test/sampleTest.ts index 8ff7deb0acbe..d64be981b694 100644 --- a/sdk/templatespecs/arm-templatespecs/test/sampleTest.ts +++ b/sdk/templatespecs/arm-templatespecs/test/sampleTest.ts @@ -9,7 +9,7 @@ import { Recorder, RecorderStartOptions, - env + env, } from "@azure-tools/test-recorder"; import { assert } from "chai"; import { Context } from "mocha"; @@ -18,15 +18,11 @@ const replaceableVariables: Record = { AZURE_CLIENT_ID: "azure_client_id", AZURE_CLIENT_SECRET: "azure_client_secret", AZURE_TENANT_ID: "88888888-8888-8888-8888-888888888888", - SUBSCRIPTION_ID: "azure_subscription_id" + SUBSCRIPTION_ID: "azure_subscription_id", }; const recorderOptions: RecorderStartOptions = { envSetupForPlayback: replaceableVariables, - removeCentralSanitizers: [ - "AZSDK3493", // .name in the body is not a secret and is listed below in the beforeEach section - "AZSDK3430", // .id in the body is not a secret and is listed below in the beforeEach section - ], }; describe("My test", () => { diff --git a/sdk/templatespecs/arm-templatespecs/tsconfig.json b/sdk/templatespecs/arm-templatespecs/tsconfig.json index c7cde0db5ad0..525ba19d4372 100644 --- a/sdk/templatespecs/arm-templatespecs/tsconfig.json +++ b/sdk/templatespecs/arm-templatespecs/tsconfig.json @@ -15,19 +15,19 @@ ], "declaration": true, "outDir": "./dist-esm", - "importHelpers": true, - "paths": { - "@azure/arm-templatespecs": [ - "./src/index" - ] - } + "importHelpers": true }, "include": [ "./src/**/*.ts", "./test/**/*.ts", - "samples-dev/**/*.ts", + "./test/**/*.ts", + "./test/**/*.ts", + "./test/**/*.ts", + "./test/**/*.ts", + "./test/**/*.ts", + "./test/**/*.ts" ], "exclude": [ "node_modules" ] -} +} \ No newline at end of file