@gradientedge/cdk-utils-azure 1.0.1 → 2.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (94) hide show
  1. package/README.md +30 -0
  2. package/dist/src/common/constants.d.ts +4 -0
  3. package/dist/src/common/constants.js +3 -0
  4. package/dist/src/common/construct.d.ts +2 -1
  5. package/dist/src/common/construct.js +4 -3
  6. package/dist/src/common/resource-name-formatter.d.ts +2 -1
  7. package/dist/src/common/resource-name-formatter.js +3 -2
  8. package/dist/src/common/stack.d.ts +2 -1
  9. package/dist/src/common/stack.js +5 -4
  10. package/dist/src/common/tagging.d.ts +3 -0
  11. package/dist/src/common/tagging.js +3 -0
  12. package/dist/src/common/types.d.ts +5 -1
  13. package/dist/src/construct/event-handler/main.d.ts +2 -1
  14. package/dist/src/construct/event-handler/main.js +2 -1
  15. package/dist/src/construct/event-handler/types.d.ts +6 -0
  16. package/dist/src/construct/function-app/main.d.ts +2 -1
  17. package/dist/src/construct/function-app/main.js +4 -3
  18. package/dist/src/construct/function-app/types.d.ts +3 -0
  19. package/dist/src/construct/rest-api/main.d.ts +2 -1
  20. package/dist/src/construct/rest-api/main.js +2 -1
  21. package/dist/src/construct/rest-api/types.d.ts +3 -0
  22. package/dist/src/construct/rest-api-function/main.d.ts +2 -1
  23. package/dist/src/construct/rest-api-function/main.js +2 -1
  24. package/dist/src/construct/rest-api-function/types.d.ts +4 -0
  25. package/dist/src/construct/rest-api-with-cache/main.d.ts +2 -1
  26. package/dist/src/construct/rest-api-with-cache/main.js +2 -1
  27. package/dist/src/construct/rest-api-with-cache/types.d.ts +2 -0
  28. package/dist/src/construct/site-with-webapp/main.d.ts +2 -1
  29. package/dist/src/construct/site-with-webapp/main.js +4 -3
  30. package/dist/src/construct/site-with-webapp/types.d.ts +3 -0
  31. package/dist/src/services/api-management/main.d.ts +5 -8
  32. package/dist/src/services/api-management/main.js +14 -17
  33. package/dist/src/services/api-management/types.d.ts +17 -0
  34. package/dist/src/services/app-configuration/main.d.ts +2 -1
  35. package/dist/src/services/app-configuration/main.js +4 -3
  36. package/dist/src/services/app-configuration/types.d.ts +1 -0
  37. package/dist/src/services/app-service/main.d.ts +2 -1
  38. package/dist/src/services/app-service/main.js +6 -5
  39. package/dist/src/services/app-service/types.d.ts +3 -2
  40. package/dist/src/services/application-insights/main.d.ts +2 -1
  41. package/dist/src/services/application-insights/main.js +5 -4
  42. package/dist/src/services/application-insights/types.d.ts +2 -0
  43. package/dist/src/services/authorisation/constants.d.ts +1 -0
  44. package/dist/src/services/authorisation/constants.js +1 -0
  45. package/dist/src/services/authorisation/main.d.ts +2 -1
  46. package/dist/src/services/authorisation/main.js +3 -2
  47. package/dist/src/services/authorisation/types.d.ts +1 -0
  48. package/dist/src/services/cosmosdb/constants.d.ts +2 -0
  49. package/dist/src/services/cosmosdb/constants.js +2 -0
  50. package/dist/src/services/cosmosdb/main.d.ts +2 -1
  51. package/dist/src/services/cosmosdb/main.js +8 -7
  52. package/dist/src/services/cosmosdb/types.d.ts +4 -0
  53. package/dist/src/services/dns/main.d.ts +2 -1
  54. package/dist/src/services/dns/main.js +7 -6
  55. package/dist/src/services/dns/types.d.ts +4 -0
  56. package/dist/src/services/eventgrid/main.d.ts +2 -1
  57. package/dist/src/services/eventgrid/main.js +11 -10
  58. package/dist/src/services/eventgrid/types.d.ts +5 -0
  59. package/dist/src/services/function/main.d.ts +3 -2
  60. package/dist/src/services/function/main.js +10 -9
  61. package/dist/src/services/function/types.d.ts +3 -0
  62. package/dist/src/services/key-vault/main.d.ts +2 -1
  63. package/dist/src/services/key-vault/main.js +5 -4
  64. package/dist/src/services/key-vault/types.d.ts +2 -0
  65. package/dist/src/services/monitor/main.d.ts +2 -1
  66. package/dist/src/services/monitor/main.js +3 -2
  67. package/dist/src/services/monitor/types.d.ts +1 -0
  68. package/dist/src/services/operational-insights/main.d.ts +2 -1
  69. package/dist/src/services/operational-insights/main.js +5 -4
  70. package/dist/src/services/operational-insights/types.d.ts +2 -0
  71. package/dist/src/services/portal/error.d.ts +1 -0
  72. package/dist/src/services/portal/error.js +1 -0
  73. package/dist/src/services/portal/main.d.ts +2 -1
  74. package/dist/src/services/portal/main.js +4 -3
  75. package/dist/src/services/portal/renderer.d.ts +1 -0
  76. package/dist/src/services/portal/renderer.js +3 -2
  77. package/dist/src/services/portal/types.d.ts +7 -0
  78. package/dist/src/services/redis/main.d.ts +2 -1
  79. package/dist/src/services/redis/main.js +4 -3
  80. package/dist/src/services/redis/types.d.ts +1 -0
  81. package/dist/src/services/resource-group/main.d.ts +2 -1
  82. package/dist/src/services/resource-group/main.js +4 -3
  83. package/dist/src/services/resource-group/types.d.ts +1 -0
  84. package/dist/src/services/security-center/main.d.ts +2 -1
  85. package/dist/src/services/security-center/main.js +3 -2
  86. package/dist/src/services/security-center/types.d.ts +1 -0
  87. package/dist/src/services/servicebus/main.d.ts +2 -1
  88. package/dist/src/services/servicebus/main.js +8 -7
  89. package/dist/src/services/servicebus/types.d.ts +5 -0
  90. package/dist/src/services/storage/main.d.ts +2 -2
  91. package/dist/src/services/storage/main.js +7 -7
  92. package/dist/src/services/storage/types.d.ts +6 -0
  93. package/dist/src/types/index.d.ts +1 -0
  94. package/package.json +14 -3
@@ -5,6 +5,7 @@ import { AppServicePlan, WebApp } from '@pulumi/azure-native/web/index.js';
5
5
  import { Output } from '@pulumi/pulumi';
6
6
  import { CommonAzureStackProps } from '../../common/index.js';
7
7
  import { LinuxWebAppProps, ServicePlanProps, StorageAccountProps, StorageContainerProps } from '../../services/index.js';
8
+ /** @category Interface */
8
9
  export interface SiteProps {
9
10
  appServicePlan: ServicePlanProps;
10
11
  codeArchiveFile: GetFileOutputArgs;
@@ -12,6 +13,7 @@ export interface SiteProps {
12
13
  storageContainer: StorageContainerProps;
13
14
  webApp: LinuxWebAppProps;
14
15
  }
16
+ /** @category Interface */
15
17
  export interface SiteWithWebAppProps extends CommonAzureStackProps {
16
18
  deploySource: string;
17
19
  nodeOptions: string;
@@ -20,6 +22,7 @@ export interface SiteWithWebAppProps extends CommonAzureStackProps {
20
22
  site: SiteProps;
21
23
  startCommand: string;
22
24
  }
25
+ /** @category Interface */
23
26
  export interface Site {
24
27
  appServicePlan: AppServicePlan;
25
28
  codeArchiveFile: Output<archive.GetFileResult>;
@@ -1,9 +1,9 @@
1
1
  import * as redis from '@pulumi/azure-native/redis/index.js';
2
2
  import { ResourceOptions } from '@pulumi/pulumi';
3
3
  import { CommonAzureConstruct } from '../../common/index.js';
4
- import { ApiDiagnosticProps, ApiManagementApiProps, ApiManagementBackendProps, ApiManagementCustomDomainProps, ApiManagementProps, ApiOperationPolicyProps, ApiOperationProps, ApiPolicyProps, ApiSubscriptionProps, CacheProps, LoggerProps, NamedValueProps, ResolveApiManagementProps } from './types.js';
4
+ import { ApiDiagnosticProps, ApiManagementApiProps, ApiManagementBackendProps, ApiManagementProps, ApiOperationPolicyProps, ApiOperationProps, ApiPolicyProps, ApiSubscriptionProps, CacheProps, LoggerProps, NamedValueProps, ResolveApiManagementProps } from './types.js';
5
5
  /**
6
- * @classdesc Provides operations on Azure API Management using Pulumi
6
+ * Provides operations on Azure API Management using Pulumi
7
7
  * - A new instance of this class is injected into {@link CommonAzureConstruct} constructor.
8
8
  * - If a custom construct extends {@link CommonAzureConstruct}, an instance is available within the context.
9
9
  * @example
@@ -18,6 +18,7 @@ import { ApiDiagnosticProps, ApiManagementApiProps, ApiManagementBackendProps, A
18
18
  * }
19
19
  * }
20
20
  * ```
21
+ * @category Service
21
22
  */
22
23
  export declare class AzureApiManagementManager {
23
24
  /**
@@ -132,12 +133,8 @@ export declare class AzureApiManagementManager {
132
133
  createPolicy(id: string, scope: CommonAzureConstruct, props: ApiPolicyProps, resourceOptions?: ResourceOptions): import("@pulumi/azure-native/apimanagement/apiPolicy.js").ApiPolicy;
133
134
  /**
134
135
  * @summary Method to create a new API Management custom domain
135
- * @param id scoped id of the resource
136
- * @param scope scope in which this resource is defined
137
- * @param props API Management custom domain properties
138
- * @param resourceOptions Optional settings to control resource behaviour
139
- * @note In Pulumi Azure Native, custom domains are configured as part of the API Management service resource,
136
+ * In Pulumi Azure Native, custom domains are configured as part of the API Management service resource,
140
137
  * not as a separate resource. Use the hostnameConfigurations property when creating the service.
141
138
  */
142
- createApiManagementCustomDomain(id: string, scope: CommonAzureConstruct, props: ApiManagementCustomDomainProps): void;
139
+ createApiManagementCustomDomain(): void;
143
140
  }
@@ -1,6 +1,6 @@
1
1
  import { Api, ApiDiagnostic, ApiManagementService, ApiOperation, ApiOperationPolicy, ApiPolicy, Backend, BackendProtocol, Cache, getApiManagementServiceOutput, Logger, LoggerType, NamedValue, Protocol, Subscription, } from '@pulumi/azure-native/apimanagement/index.js';
2
2
  /**
3
- * @classdesc Provides operations on Azure API Management using Pulumi
3
+ * Provides operations on Azure API Management using Pulumi
4
4
  * - A new instance of this class is injected into {@link CommonAzureConstruct} constructor.
5
5
  * - If a custom construct extends {@link CommonAzureConstruct}, an instance is available within the context.
6
6
  * @example
@@ -15,6 +15,7 @@ import { Api, ApiDiagnostic, ApiManagementService, ApiOperation, ApiOperationPol
15
15
  * }
16
16
  * }
17
17
  * ```
18
+ * @category Service
18
19
  */
19
20
  export class AzureApiManagementManager {
20
21
  /**
@@ -29,13 +30,13 @@ export class AzureApiManagementManager {
29
30
  */
30
31
  createApiManagementService(id, scope, props, applicationInsightsKey, externalRedisCache, resourceOptions) {
31
32
  if (!props)
32
- throw `Props undefined for ${id}`;
33
+ throw new Error(`Props undefined for ${id}`);
33
34
  // Get resource group name
34
35
  const resourceGroupName = scope.props.resourceGroupName
35
36
  ? scope.resourceNameFormatter.format(scope.props.resourceGroupName)
36
37
  : props.resourceGroupName;
37
38
  if (!resourceGroupName)
38
- throw `Resource group name undefined for ${id}`;
39
+ throw new Error(`Resource group name undefined for ${id}`);
39
40
  const apiManagementService = new ApiManagementService(`${id}-am`, {
40
41
  ...props,
41
42
  serviceName: scope.resourceNameFormatter.format(props.serviceName?.toString(), scope.props.resourceNameOptions?.apiManagement),
@@ -82,7 +83,7 @@ export class AzureApiManagementManager {
82
83
  */
83
84
  resolveApiManagementService(id, scope, props, resourceOptions) {
84
85
  if (!props)
85
- throw `Props undefined for ${id}`;
86
+ throw new Error(`Props undefined for ${id}`);
86
87
  return getApiManagementServiceOutput({
87
88
  serviceName: scope.resourceNameFormatter.format(props.serviceName?.toString(), scope.props.resourceNameOptions?.dataAzurermApiManagement),
88
89
  resourceGroupName: scope.props.resourceGroupName
@@ -100,7 +101,7 @@ export class AzureApiManagementManager {
100
101
  */
101
102
  createBackend(id, scope, props, resourceOptions) {
102
103
  if (!props)
103
- throw `Props undefined for ${id}`;
104
+ throw new Error(`Props undefined for ${id}`);
104
105
  return new Backend(`${id}-am-be`, {
105
106
  ...props,
106
107
  backendId: scope.resourceNameFormatter.format(props.backendId?.toString(), scope.props.resourceNameOptions?.apiManagementBackend),
@@ -118,7 +119,7 @@ export class AzureApiManagementManager {
118
119
  */
119
120
  createApi(id, scope, props, resourceOptions) {
120
121
  if (!props)
121
- throw `Props undefined for ${id}`;
122
+ throw new Error(`Props undefined for ${id}`);
122
123
  const api = new Api(`${id}-am-api`, {
123
124
  ...props,
124
125
  apiId: scope.resourceNameFormatter.format(props.apiId?.toString(), scope.props.resourceNameOptions?.apiManagementApi),
@@ -138,7 +139,7 @@ export class AzureApiManagementManager {
138
139
  */
139
140
  createApiDiagnostic(id, scope, props, resourceOptions) {
140
141
  if (!props)
141
- throw `Props undefined for ${id}`;
142
+ throw new Error(`Props undefined for ${id}`);
142
143
  return new ApiDiagnostic(`${id}`, props, { parent: scope, ...resourceOptions });
143
144
  }
144
145
  /**
@@ -151,7 +152,7 @@ export class AzureApiManagementManager {
151
152
  */
152
153
  createLogger(id, scope, props, resourceOptions) {
153
154
  if (!props)
154
- throw `Props undefined for ${id}`;
155
+ throw new Error(`Props undefined for ${id}`);
155
156
  return new Logger(`${id}`, props, { parent: scope, ...resourceOptions });
156
157
  }
157
158
  /**
@@ -164,7 +165,7 @@ export class AzureApiManagementManager {
164
165
  */
165
166
  createNamedValue(id, scope, props, resourceOptions) {
166
167
  if (!props)
167
- throw `Props undefined for ${id}`;
168
+ throw new Error(`Props undefined for ${id}`);
168
169
  return new NamedValue(`${id}`, props, { parent: scope, ...resourceOptions });
169
170
  }
170
171
  /**
@@ -177,7 +178,7 @@ export class AzureApiManagementManager {
177
178
  */
178
179
  createSubscription(id, scope, props, resourceOptions) {
179
180
  if (!props)
180
- throw `Props undefined for ${id}`;
181
+ throw new Error(`Props undefined for ${id}`);
181
182
  return new Subscription(`${id}`, props, { parent: scope, ...resourceOptions });
182
183
  }
183
184
  /**
@@ -190,7 +191,7 @@ export class AzureApiManagementManager {
190
191
  */
191
192
  createCache(id, scope, props, resourceOptions) {
192
193
  if (!props)
193
- throw `Props undefined for ${id}`;
194
+ throw new Error(`Props undefined for ${id}`);
194
195
  return new Cache(`${id}`, props, { parent: scope, ...resourceOptions });
195
196
  }
196
197
  /**
@@ -228,14 +229,10 @@ export class AzureApiManagementManager {
228
229
  }
229
230
  /**
230
231
  * @summary Method to create a new API Management custom domain
231
- * @param id scoped id of the resource
232
- * @param scope scope in which this resource is defined
233
- * @param props API Management custom domain properties
234
- * @param resourceOptions Optional settings to control resource behaviour
235
- * @note In Pulumi Azure Native, custom domains are configured as part of the API Management service resource,
232
+ * In Pulumi Azure Native, custom domains are configured as part of the API Management service resource,
236
233
  * not as a separate resource. Use the hostnameConfigurations property when creating the service.
237
234
  */
238
- createApiManagementCustomDomain(id, scope, props) {
235
+ createApiManagementCustomDomain() {
239
236
  // Note: In Pulumi Azure Native, custom domains are part of the ApiManagementService
240
237
  // This method is provided for API compatibility but should be configured
241
238
  // via the hostnameConfigurations property of ApiManagementService instead
@@ -1,24 +1,32 @@
1
1
  import { ApiArgs, ApiDiagnosticArgs, ApiManagementServiceArgs, ApiOperationArgs, ApiOperationPolicyArgs, ApiPolicyArgs, BackendArgs, CacheArgs, GetApiManagementServiceOutputArgs, LoggerArgs, NamedValueArgs, SubscriptionArgs } from '@pulumi/azure-native/apimanagement/index.js';
2
+ /** @category Interface */
2
3
  export interface ApiManagementProps extends ApiManagementServiceArgs {
3
4
  certificateKeyVaultId?: string;
4
5
  apiStackName?: string;
5
6
  useExistingApiManagement?: boolean;
6
7
  }
8
+ /** @category Interface */
7
9
  export interface ApiManagementBackendProps extends BackendArgs {
8
10
  backendUrlPath?: string;
9
11
  apiManagementId?: string;
10
12
  circuitBreaker?: any;
11
13
  }
14
+ /** @category Interface */
12
15
  export interface ApiDiagnosticProps extends ApiDiagnosticArgs {
13
16
  }
17
+ /** @category Interface */
14
18
  export interface LoggerProps extends LoggerArgs {
15
19
  }
20
+ /** @category Interface */
16
21
  export interface NamedValueProps extends NamedValueArgs {
17
22
  }
23
+ /** @category Interface */
18
24
  export interface ApiSubscriptionProps extends SubscriptionArgs {
19
25
  }
26
+ /** @category Interface */
20
27
  export interface CacheProps extends CacheArgs {
21
28
  }
29
+ /** @category Interface */
22
30
  export interface ApiManagementCustomDomainProps {
23
31
  apiManagementId: string;
24
32
  gateway?: Array<{
@@ -35,6 +43,7 @@ export interface ApiManagementCustomDomainProps {
35
43
  certificateId?: string;
36
44
  }>;
37
45
  }
46
+ /** @category Interface */
38
47
  export interface ApiManagementApiProps extends ApiArgs {
39
48
  operations: ApiManagementApiOperationProps[];
40
49
  commonInboundPolicyXml?: string;
@@ -43,30 +52,38 @@ export interface ApiManagementApiProps extends ApiArgs {
43
52
  cacheSetOutboundPolicy?: string;
44
53
  rateLimit?: ApiManagementApiRateLimit;
45
54
  }
55
+ /** @category Interface */
46
56
  export interface ApiManagementApiOperationProps extends ApiOperationArgs {
47
57
  caching?: ApiManagementApiCaching;
48
58
  }
59
+ /** @category Interface */
49
60
  export interface ApiManagementApiCaching {
50
61
  enableCacheSet?: boolean;
51
62
  enableCacheInvalidation?: boolean;
52
63
  ttlInSecs?: number;
53
64
  cachingType?: string;
54
65
  }
66
+ /** @category Interface */
55
67
  export interface ApiManagementApiRateLimit {
56
68
  calls: number;
57
69
  renewalPeriodInSecs: number;
58
70
  }
71
+ /** @category Interface */
59
72
  export interface ApiManagementRedisCacheProps {
60
73
  apiManagementId: string;
61
74
  connectionString: string;
62
75
  cacheLocation: string;
63
76
  redisCacheId: string;
64
77
  }
78
+ /** @category Interface */
65
79
  export interface ResolveApiManagementProps extends GetApiManagementServiceOutputArgs {
66
80
  }
81
+ /** @category Interface */
67
82
  export interface ApiOperationProps extends ApiOperationArgs {
68
83
  }
84
+ /** @category Interface */
69
85
  export interface ApiOperationPolicyProps extends ApiOperationPolicyArgs {
70
86
  }
87
+ /** @category Interface */
71
88
  export interface ApiPolicyProps extends ApiPolicyArgs {
72
89
  }
@@ -2,7 +2,7 @@ import { ResourceOptions } from '@pulumi/pulumi';
2
2
  import { CommonAzureConstruct } from '../../common/index.js';
3
3
  import { AppConfigurationProps } from './types.js';
4
4
  /**
5
- * @classdesc Provides operations on Azure App Configuration using Pulumi
5
+ * Provides operations on Azure App Configuration using Pulumi
6
6
  * - A new instance of this class is injected into {@link CommonAzureConstruct} constructor.
7
7
  * - If a custom construct extends {@link CommonAzureConstruct}, an instance is available within the context.
8
8
  * @example
@@ -17,6 +17,7 @@ import { AppConfigurationProps } from './types.js';
17
17
  * }
18
18
  * }
19
19
  * ```
20
+ * @category Service
20
21
  */
21
22
  export declare class AzureAppConfigurationManager {
22
23
  /**
@@ -1,6 +1,6 @@
1
1
  import { ConfigurationStore, IdentityType } from '@pulumi/azure-native/appconfiguration/index.js';
2
2
  /**
3
- * @classdesc Provides operations on Azure App Configuration using Pulumi
3
+ * Provides operations on Azure App Configuration using Pulumi
4
4
  * - A new instance of this class is injected into {@link CommonAzureConstruct} constructor.
5
5
  * - If a custom construct extends {@link CommonAzureConstruct}, an instance is available within the context.
6
6
  * @example
@@ -15,6 +15,7 @@ import { ConfigurationStore, IdentityType } from '@pulumi/azure-native/appconfig
15
15
  * }
16
16
  * }
17
17
  * ```
18
+ * @category Service
18
19
  */
19
20
  export class AzureAppConfigurationManager {
20
21
  /**
@@ -27,13 +28,13 @@ export class AzureAppConfigurationManager {
27
28
  */
28
29
  createConfigurationStore(id, scope, props, resourceOptions) {
29
30
  if (!props)
30
- throw `Props undefined for ${id}`;
31
+ throw new Error(`Props undefined for ${id}`);
31
32
  // Get resource group name
32
33
  const resourceGroupName = scope.props.resourceGroupName
33
34
  ? scope.resourceNameFormatter.format(scope.props.resourceGroupName)
34
35
  : props.resourceGroupName;
35
36
  if (!resourceGroupName)
36
- throw `Resource group name undefined for ${id}`;
37
+ throw new Error(`Resource group name undefined for ${id}`);
37
38
  return new ConfigurationStore(`${id}-ac`, {
38
39
  ...props,
39
40
  configStoreName: scope.resourceNameFormatter.format(props.configStoreName?.toString(), scope.props.resourceNameOptions?.appConfiguration),
@@ -1,3 +1,4 @@
1
1
  import { ConfigurationStoreArgs } from '@pulumi/azure-native/appconfiguration/index.js';
2
+ /** @category Interface */
2
3
  export interface AppConfigurationProps extends ConfigurationStoreArgs {
3
4
  }
@@ -2,7 +2,7 @@ import { ResourceOptions } from '@pulumi/pulumi';
2
2
  import { CommonAzureConstruct } from '../../common/index.js';
3
3
  import { LinuxWebAppProps, ServicePlanProps } from './types.js';
4
4
  /**
5
- * @classdesc Provides operations on Azure App Service using Pulumi
5
+ * Provides operations on Azure App Service using Pulumi
6
6
  * - A new instance of this class is injected into {@link CommonAzureConstruct} constructor.
7
7
  * - If a custom construct extends {@link CommonAzureConstruct}, an instance is available within the context.
8
8
  * @example
@@ -17,6 +17,7 @@ import { LinuxWebAppProps, ServicePlanProps } from './types.js';
17
17
  * }
18
18
  * }
19
19
  * ```
20
+ * @category Service
20
21
  */
21
22
  export declare class AzureAppServiceManager {
22
23
  /**
@@ -1,6 +1,6 @@
1
1
  import { AppServicePlan, ManagedServiceIdentityType, SupportedTlsVersions, WebApp, } from '@pulumi/azure-native/web/index.js';
2
2
  /**
3
- * @classdesc Provides operations on Azure App Service using Pulumi
3
+ * Provides operations on Azure App Service using Pulumi
4
4
  * - A new instance of this class is injected into {@link CommonAzureConstruct} constructor.
5
5
  * - If a custom construct extends {@link CommonAzureConstruct}, an instance is available within the context.
6
6
  * @example
@@ -15,6 +15,7 @@ import { AppServicePlan, ManagedServiceIdentityType, SupportedTlsVersions, WebAp
15
15
  * }
16
16
  * }
17
17
  * ```
18
+ * @category Service
18
19
  */
19
20
  export class AzureAppServiceManager {
20
21
  /**
@@ -27,13 +28,13 @@ export class AzureAppServiceManager {
27
28
  */
28
29
  createAppServicePlan(id, scope, props, resourceOptions) {
29
30
  if (!props)
30
- throw `Props undefined for ${id}`;
31
+ throw new Error(`Props undefined for ${id}`);
31
32
  // Get resource group name
32
33
  const resourceGroupName = scope.props.resourceGroupName
33
34
  ? scope.resourceNameFormatter.format(scope.props.resourceGroupName)
34
35
  : props.resourceGroupName;
35
36
  if (!resourceGroupName)
36
- throw `Resource group name undefined for ${id}`;
37
+ throw new Error(`Resource group name undefined for ${id}`);
37
38
  return new AppServicePlan(`${id}-as`, {
38
39
  ...props,
39
40
  name: scope.resourceNameFormatter.format(props.name?.toString(), scope.props.resourceNameOptions?.appServicePlan),
@@ -60,13 +61,13 @@ export class AzureAppServiceManager {
60
61
  */
61
62
  createLinuxWebApp(id, scope, props, resourceOptions) {
62
63
  if (!props)
63
- throw `Props undefined for ${id}`;
64
+ throw new Error(`Props undefined for ${id}`);
64
65
  // Get resource group name
65
66
  const resourceGroupName = scope.props.resourceGroupName
66
67
  ? scope.resourceNameFormatter.format(scope.props.resourceGroupName)
67
68
  : props.resourceGroupName;
68
69
  if (!resourceGroupName)
69
- throw `Resource group name undefined for ${id}`;
70
+ throw new Error(`Resource group name undefined for ${id}`);
70
71
  return new WebApp(`${id}-lwa`, {
71
72
  ...props,
72
73
  name: scope.resourceNameFormatter.format(props.name?.toString(), scope.props.resourceNameOptions?.linuxWebApp),
@@ -1,6 +1,7 @@
1
- import { AppServicePlanArgs } from '@pulumi/azure-native/web/index.js';
2
- import { WebAppArgs } from '@pulumi/azure-native/web/index.js';
1
+ import { AppServicePlanArgs, WebAppArgs } from '@pulumi/azure-native/web/index.js';
2
+ /** @category Interface */
3
3
  export interface ServicePlanProps extends AppServicePlanArgs {
4
4
  }
5
+ /** @category Interface */
5
6
  export interface LinuxWebAppProps extends WebAppArgs {
6
7
  }
@@ -2,7 +2,7 @@ import { ResourceOptions } from '@pulumi/pulumi';
2
2
  import { CommonAzureConstruct } from '../../common/index.js';
3
3
  import { ApplicationInsightsProps, ComponentCurrentBillingFeatureProps } from './types.js';
4
4
  /**
5
- * @classdesc Provides operations on Azure Application Insights using Pulumi
5
+ * Provides operations on Azure Application Insights using Pulumi
6
6
  * - A new instance of this class is injected into {@link CommonAzureConstruct} constructor.
7
7
  * - If a custom construct extends {@link CommonAzureConstruct}, an instance is available within the context.
8
8
  * @example
@@ -17,6 +17,7 @@ import { ApplicationInsightsProps, ComponentCurrentBillingFeatureProps } from '.
17
17
  * }
18
18
  * }
19
19
  * ```
20
+ * @category Service
20
21
  */
21
22
  export declare class AzureApplicationInsightsManager {
22
23
  /**
@@ -1,6 +1,6 @@
1
1
  import { ApplicationType, Component, ComponentCurrentBillingFeature, } from '@pulumi/azure-native/applicationinsights/index.js';
2
2
  /**
3
- * @classdesc Provides operations on Azure Application Insights using Pulumi
3
+ * Provides operations on Azure Application Insights using Pulumi
4
4
  * - A new instance of this class is injected into {@link CommonAzureConstruct} constructor.
5
5
  * - If a custom construct extends {@link CommonAzureConstruct}, an instance is available within the context.
6
6
  * @example
@@ -15,6 +15,7 @@ import { ApplicationType, Component, ComponentCurrentBillingFeature, } from '@pu
15
15
  * }
16
16
  * }
17
17
  * ```
18
+ * @category Service
18
19
  */
19
20
  export class AzureApplicationInsightsManager {
20
21
  /**
@@ -27,13 +28,13 @@ export class AzureApplicationInsightsManager {
27
28
  */
28
29
  createComponent(id, scope, props, resourceOptions) {
29
30
  if (!props)
30
- throw `Props undefined for ${id}`;
31
+ throw new Error(`Props undefined for ${id}`);
31
32
  // Get resource group name
32
33
  const resourceGroupName = scope.props.resourceGroupName
33
34
  ? `${scope.props.resourceGroupName}-${scope.props.stage}`
34
35
  : props.resourceGroupName;
35
36
  if (!resourceGroupName)
36
- throw `Resource group name undefined for ${id}`;
37
+ throw new Error(`Resource group name undefined for ${id}`);
37
38
  const component = new Component(`${id}-ai`, {
38
39
  ...props,
39
40
  resourceName: scope.resourceNameFormatter.format(props.resourceName?.toString(), scope.props.resourceNameOptions?.applicationInsights),
@@ -62,7 +63,7 @@ export class AzureApplicationInsightsManager {
62
63
  */
63
64
  createComponentCurrentBillingFeature(id, scope, props, resourceOptions) {
64
65
  if (!props)
65
- throw `Props undefined for ${id}`;
66
+ throw new Error(`Props undefined for ${id}`);
66
67
  return new ComponentCurrentBillingFeature(`${id}`, props, { parent: scope, ...resourceOptions });
67
68
  }
68
69
  }
@@ -1,6 +1,8 @@
1
1
  import { ComponentArgs, ComponentCurrentBillingFeatureArgs } from '@pulumi/azure-native/applicationinsights/index.js';
2
+ /** @category Interface */
2
3
  export interface ComponentCurrentBillingFeatureProps extends ComponentCurrentBillingFeatureArgs {
3
4
  }
5
+ /** @category Interface */
4
6
  export interface ApplicationInsightsProps extends ComponentArgs {
5
7
  billingFeatures?: ComponentCurrentBillingFeatureProps;
6
8
  }
@@ -2,6 +2,7 @@
2
2
  * @summary Enumerations for publicly available built in RBAC roles
3
3
  * @see https://learn.microsoft.com/en-us/azure/role-based-access-control/built-in-roles
4
4
  */
5
+ /** @category Enum */
5
6
  export declare enum RoleDefinitionId {
6
7
  APP_CONFIGURATION_DATA_READER = "/providers/Microsoft.Authorization/roleDefinitions/516239f1-63e1-4d78-a4de-a74fb236a071",
7
8
  APP_CONFIGURATION_DATA_OWNER = "/providers/Microsoft.Authorization/roleDefinitions/5ae67dd6-50cb-40e7-96ff-dc2bfa4b606b",
@@ -2,6 +2,7 @@
2
2
  * @summary Enumerations for publicly available built in RBAC roles
3
3
  * @see https://learn.microsoft.com/en-us/azure/role-based-access-control/built-in-roles
4
4
  */
5
+ /** @category Enum */
5
6
  export var RoleDefinitionId;
6
7
  (function (RoleDefinitionId) {
7
8
  RoleDefinitionId["APP_CONFIGURATION_DATA_READER"] = "/providers/Microsoft.Authorization/roleDefinitions/516239f1-63e1-4d78-a4de-a74fb236a071";
@@ -3,7 +3,7 @@ import { CommonAzureConstruct } from '../../common/index.js';
3
3
  import { RoleDefinitionId } from './constants.js';
4
4
  import { RoleAssignmentProps } from './types.js';
5
5
  /**
6
- * @classdesc Provides operations on Azure Authorisation using Pulumi
6
+ * Provides operations on Azure Authorisation using Pulumi
7
7
  * - A new instance of this class is injected into {@link CommonAzureConstruct} constructor.
8
8
  * - If a custom construct extends {@link CommonAzureConstruct}, an instance is available within the context.
9
9
  * @example
@@ -18,6 +18,7 @@ import { RoleAssignmentProps } from './types.js';
18
18
  * }
19
19
  * }
20
20
  * ```
21
+ * @category Service
21
22
  */
22
23
  export declare class AzureAuthorisationManager {
23
24
  /**
@@ -1,6 +1,6 @@
1
1
  import { RoleAssignment } from '@pulumi/azure-native/authorization/index.js';
2
2
  /**
3
- * @classdesc Provides operations on Azure Authorisation using Pulumi
3
+ * Provides operations on Azure Authorisation using Pulumi
4
4
  * - A new instance of this class is injected into {@link CommonAzureConstruct} constructor.
5
5
  * - If a custom construct extends {@link CommonAzureConstruct}, an instance is available within the context.
6
6
  * @example
@@ -15,6 +15,7 @@ import { RoleAssignment } from '@pulumi/azure-native/authorization/index.js';
15
15
  * }
16
16
  * }
17
17
  * ```
18
+ * @category Service
18
19
  */
19
20
  export class AzureAuthorisationManager {
20
21
  /**
@@ -27,7 +28,7 @@ export class AzureAuthorisationManager {
27
28
  */
28
29
  createRoleAssignment(id, scope, props, resourceOptions) {
29
30
  if (!props)
30
- throw `Props undefined for ${id}`;
31
+ throw new Error(`Props undefined for ${id}`);
31
32
  return new RoleAssignment(`${id}`, props, { parent: scope, ...resourceOptions });
32
33
  }
33
34
  /**
@@ -1,3 +1,4 @@
1
1
  import { RoleAssignmentArgs } from '@pulumi/azure-native/authorization/index.js';
2
+ /** @category Interface */
2
3
  export interface RoleAssignmentProps extends RoleAssignmentArgs {
3
4
  }
@@ -1,7 +1,9 @@
1
+ /** @category Enum */
1
2
  export declare enum CosmosRoleDefinition {
2
3
  CONTRIBUTOR = "CONTRIBUTOR",
3
4
  READER = "READER"
4
5
  }
6
+ /** @category Enum */
5
7
  export declare enum CosmosRoleDefinitionId {
6
8
  CONTRIBUTOR = "00000000-0000-0000-0000-000000000001",
7
9
  READER = "00000000-0000-0000-0000-000000000002"
@@ -1,8 +1,10 @@
1
+ /** @category Enum */
1
2
  export var CosmosRoleDefinition;
2
3
  (function (CosmosRoleDefinition) {
3
4
  CosmosRoleDefinition["CONTRIBUTOR"] = "CONTRIBUTOR";
4
5
  CosmosRoleDefinition["READER"] = "READER";
5
6
  })(CosmosRoleDefinition || (CosmosRoleDefinition = {}));
7
+ /** @category Enum */
6
8
  export var CosmosRoleDefinitionId;
7
9
  (function (CosmosRoleDefinitionId) {
8
10
  CosmosRoleDefinitionId["CONTRIBUTOR"] = "00000000-0000-0000-0000-000000000001";
@@ -3,7 +3,7 @@ import { CommonAzureConstruct } from '../../common/index.js';
3
3
  import { CosmosRoleDefinition } from './constants.js';
4
4
  import { CosmosdbAccountProps, CosmosdbSqlContainerProps, CosmosdbSqlDatabaseProps, SqlResourceSqlRoleAssignmentProps } from './types.js';
5
5
  /**
6
- * @classdesc Provides operations on Azure CosmosDB using Pulumi
6
+ * Provides operations on Azure CosmosDB using Pulumi
7
7
  * - A new instance of this class is injected into {@link CommonAzureConstruct} constructor.
8
8
  * - If a custom construct extends {@link CommonAzureConstruct}, an instance is available within the context.
9
9
  * @example
@@ -18,6 +18,7 @@ import { CosmosdbAccountProps, CosmosdbSqlContainerProps, CosmosdbSqlDatabasePro
18
18
  * }
19
19
  * }
20
20
  * ```
21
+ * @category Service
21
22
  */
22
23
  export declare class AzureCosmosDbManager {
23
24
  /**
@@ -1,7 +1,7 @@
1
1
  import { DatabaseAccount, getDatabaseAccountOutput, getSqlResourceSqlRoleDefinitionOutput, ResourceIdentityType, SqlResourceSqlContainer, SqlResourceSqlDatabase, SqlResourceSqlRoleAssignment, } from '@pulumi/azure-native/cosmosdb/index.js';
2
2
  import { CosmosRoleDefinition, CosmosRoleDefinitionId } from './constants.js';
3
3
  /**
4
- * @classdesc Provides operations on Azure CosmosDB using Pulumi
4
+ * Provides operations on Azure CosmosDB using Pulumi
5
5
  * - A new instance of this class is injected into {@link CommonAzureConstruct} constructor.
6
6
  * - If a custom construct extends {@link CommonAzureConstruct}, an instance is available within the context.
7
7
  * @example
@@ -16,6 +16,7 @@ import { CosmosRoleDefinition, CosmosRoleDefinitionId } from './constants.js';
16
16
  * }
17
17
  * }
18
18
  * ```
19
+ * @category Service
19
20
  */
20
21
  export class AzureCosmosDbManager {
21
22
  /**
@@ -28,13 +29,13 @@ export class AzureCosmosDbManager {
28
29
  */
29
30
  createCosmosDbAccount(id, scope, props, resourceOptions) {
30
31
  if (!props)
31
- throw `Props undefined for ${id}`;
32
+ throw new Error(`Props undefined for ${id}`);
32
33
  // Get resource group name
33
34
  const resourceGroupName = scope.props.resourceGroupName
34
35
  ? scope.resourceNameFormatter.format(scope.props.resourceGroupName)
35
36
  : props.resourceGroupName;
36
37
  if (!resourceGroupName)
37
- throw `Resource group name undefined for ${id}`;
38
+ throw new Error(`Resource group name undefined for ${id}`);
38
39
  return new DatabaseAccount(`${id}-ca`, {
39
40
  ...props,
40
41
  accountName: scope.resourceNameFormatter.format(props.accountName?.toString(), scope.props.resourceNameOptions?.cosmosDbAccount),
@@ -58,13 +59,13 @@ export class AzureCosmosDbManager {
58
59
  */
59
60
  createCosmosDbDatabase(id, scope, props, resourceOptions) {
60
61
  if (!props)
61
- throw `Props undefined for ${id}`;
62
+ throw new Error(`Props undefined for ${id}`);
62
63
  // Get resource group name
63
64
  const resourceGroupName = scope.props.resourceGroupName
64
65
  ? scope.resourceNameFormatter.format(scope.props.resourceGroupName)
65
66
  : props.resourceGroupName;
66
67
  if (!resourceGroupName)
67
- throw `Resource group name undefined for ${id}`;
68
+ throw new Error(`Resource group name undefined for ${id}`);
68
69
  return new SqlResourceSqlDatabase(`${id}-cd`, {
69
70
  ...props,
70
71
  databaseName: scope.resourceNameFormatter.format(props.databaseName?.toString(), scope.props.resourceNameOptions?.cosmosDbSqlDatabase),
@@ -81,13 +82,13 @@ export class AzureCosmosDbManager {
81
82
  */
82
83
  createCosmosDbContainer(id, scope, props, resourceOptions) {
83
84
  if (!props)
84
- throw `Props undefined for ${id}`;
85
+ throw new Error(`Props undefined for ${id}`);
85
86
  // Get resource group name
86
87
  const resourceGroupName = scope.props.resourceGroupName
87
88
  ? `${scope.props.resourceGroupName}-${scope.props.stage}`
88
89
  : props.resourceGroupName;
89
90
  if (!resourceGroupName)
90
- throw `Resource group name undefined for ${id}`;
91
+ throw new Error(`Resource group name undefined for ${id}`);
91
92
  return new SqlResourceSqlContainer(`${id}-cc`, {
92
93
  ...props,
93
94
  containerName: scope.resourceNameFormatter.format(props.containerName?.toString(), scope.props.resourceNameOptions?.cosmosDbSqlContainer),
@@ -1,9 +1,13 @@
1
1
  import { DatabaseAccountArgs, SqlResourceSqlContainerArgs, SqlResourceSqlDatabaseArgs, SqlResourceSqlRoleAssignmentArgs } from '@pulumi/azure-native/cosmosdb/index.js';
2
+ /** @category Interface */
2
3
  export interface CosmosdbAccountProps extends DatabaseAccountArgs {
3
4
  }
5
+ /** @category Interface */
4
6
  export interface CosmosdbSqlDatabaseProps extends SqlResourceSqlDatabaseArgs {
5
7
  }
8
+ /** @category Interface */
6
9
  export interface CosmosdbSqlContainerProps extends SqlResourceSqlContainerArgs {
7
10
  }
11
+ /** @category Interface */
8
12
  export interface SqlResourceSqlRoleAssignmentProps extends SqlResourceSqlRoleAssignmentArgs {
9
13
  }