@gradientedge/cdk-utils-azure 2.33.0 → 2.35.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 (57) hide show
  1. package/dist/src/common/constants.d.ts +7 -1
  2. package/dist/src/common/constants.js +7 -1
  3. package/dist/src/common/construct.d.ts +47 -0
  4. package/dist/src/common/construct.js +45 -0
  5. package/dist/src/common/resource-name-formatter.d.ts +5 -0
  6. package/dist/src/common/resource-name-formatter.js +5 -0
  7. package/dist/src/common/stack.d.ts +29 -0
  8. package/dist/src/common/stack.js +29 -0
  9. package/dist/src/common/types.d.ts +53 -4
  10. package/dist/src/construct/event-handler/main.d.ts +4 -0
  11. package/dist/src/construct/event-handler/main.js +4 -0
  12. package/dist/src/construct/event-handler/types.d.ts +43 -6
  13. package/dist/src/construct/function-app/main.d.ts +23 -0
  14. package/dist/src/construct/function-app/main.js +23 -0
  15. package/dist/src/construct/function-app/types.d.ts +38 -3
  16. package/dist/src/construct/rest-api/main.d.ts +3 -0
  17. package/dist/src/construct/rest-api/main.js +3 -0
  18. package/dist/src/construct/rest-api/types.d.ts +26 -3
  19. package/dist/src/construct/rest-api-function/main.d.ts +2 -0
  20. package/dist/src/construct/rest-api-function/main.js +2 -0
  21. package/dist/src/construct/rest-api-function/types.d.ts +34 -4
  22. package/dist/src/construct/rest-api-with-cache/main.d.ts +2 -0
  23. package/dist/src/construct/rest-api-with-cache/main.js +1 -0
  24. package/dist/src/construct/rest-api-with-cache/types.d.ts +14 -2
  25. package/dist/src/construct/site-with-webapp/main.d.ts +3 -0
  26. package/dist/src/construct/site-with-webapp/main.js +3 -0
  27. package/dist/src/construct/site-with-webapp/types.d.ts +29 -3
  28. package/dist/src/services/api-management/types.d.ts +110 -17
  29. package/dist/src/services/app-configuration/types.d.ts +5 -1
  30. package/dist/src/services/app-service/types.d.ts +10 -2
  31. package/dist/src/services/application-insights/renderer.d.ts +21 -0
  32. package/dist/src/services/application-insights/renderer.js +21 -0
  33. package/dist/src/services/application-insights/types.d.ts +30 -4
  34. package/dist/src/services/authorisation/constants.d.ts +7 -0
  35. package/dist/src/services/authorisation/constants.js +7 -0
  36. package/dist/src/services/authorisation/types.d.ts +5 -1
  37. package/dist/src/services/cosmosdb/constants.d.ts +14 -2
  38. package/dist/src/services/cosmosdb/constants.js +14 -2
  39. package/dist/src/services/cosmosdb/types.d.ts +20 -4
  40. package/dist/src/services/dns/types.d.ts +20 -4
  41. package/dist/src/services/eventgrid/types.d.ts +25 -5
  42. package/dist/src/services/function/types.d.ts +27 -3
  43. package/dist/src/services/key-vault/types.d.ts +10 -2
  44. package/dist/src/services/monitor/types.d.ts +5 -1
  45. package/dist/src/services/operational-insights/types.d.ts +10 -2
  46. package/dist/src/services/portal/error.d.ts +16 -1
  47. package/dist/src/services/portal/error.js +16 -1
  48. package/dist/src/services/portal/renderer.d.ts +44 -1
  49. package/dist/src/services/portal/renderer.js +44 -1
  50. package/dist/src/services/portal/types.d.ts +61 -8
  51. package/dist/src/services/redis/types.d.ts +16 -3
  52. package/dist/src/services/resource-group/types.d.ts +5 -1
  53. package/dist/src/services/security-center/types.d.ts +5 -1
  54. package/dist/src/services/servicebus/types.d.ts +25 -5
  55. package/dist/src/services/storage/types.d.ts +38 -6
  56. package/dist/src/types/index.d.ts +5 -1
  57. package/package.json +5 -5
@@ -1,7 +1,13 @@
1
- /** @category Enum */
1
+ /**
2
+ * Supported remote backend types for Azure infrastructure state management
3
+ * @category Enum
4
+ */
2
5
  export declare enum AzureRemoteBackend {
6
+ /** Azure Resource Manager backend for storing state in Azure Blob Storage */
3
7
  azurerm = "azurerm",
8
+ /** Pulumi Cloud backend for managed state storage */
4
9
  pulumi = "pulumi",
10
+ /** Local file system backend for development and testing */
5
11
  local = "local"
6
12
  }
7
13
  /**
@@ -1,8 +1,14 @@
1
- /** @category Enum */
1
+ /**
2
+ * Supported remote backend types for Azure infrastructure state management
3
+ * @category Enum
4
+ */
2
5
  export var AzureRemoteBackend;
3
6
  (function (AzureRemoteBackend) {
7
+ /** Azure Resource Manager backend for storing state in Azure Blob Storage */
4
8
  AzureRemoteBackend["azurerm"] = "azurerm";
9
+ /** Pulumi Cloud backend for managed state storage */
5
10
  AzureRemoteBackend["pulumi"] = "pulumi";
11
+ /** Local file system backend for development and testing */
6
12
  AzureRemoteBackend["local"] = "local";
7
13
  })(AzureRemoteBackend || (AzureRemoteBackend = {}));
8
14
  /**
@@ -25,34 +25,81 @@ import { CommonAzureStackProps } from './types.js';
25
25
  * @category Common
26
26
  */
27
27
  export declare class CommonAzureConstruct extends ComponentResource {
28
+ /** Stack properties for the construct */
28
29
  props: CommonAzureStackProps;
30
+ /** Optional Pulumi component resource options */
29
31
  options?: ComponentResourceOptions;
32
+ /** Unique identifier for the construct */
30
33
  id: string;
34
+ /** The Azure resource group associated with this construct */
31
35
  resourceGroup: ResourceGroup;
36
+ /** The fully qualified domain name derived from domainName and subDomain */
32
37
  fullyQualifiedDomainName: string;
38
+ /** Manager for Azure RBAC role assignments */
33
39
  authorisationManager: AzureAuthorisationManager;
40
+ /** Manager for Azure API Management resources */
34
41
  apiManagementManager: AzureApiManagementManager;
42
+ /** Manager for Azure App Configuration resources */
35
43
  appConfigurationManager: AzureAppConfigurationManager;
44
+ /** Manager for Azure App Service resources */
36
45
  appServiceManager: AzureAppServiceManager;
46
+ /** Manager for Azure Application Insights resources */
37
47
  applicationInsightsManager: AzureApplicationInsightsManager;
48
+ /** Manager for Azure CosmosDB resources */
38
49
  cosmosDbManager: AzureCosmosDbManager;
50
+ /** Manager for Azure DNS resources */
39
51
  dnsManager: AzureDnsManager;
52
+ /** Manager for Azure Event Grid resources */
40
53
  eventgridManager: AzureEventgridManager;
54
+ /** Manager for Azure Function App resources */
41
55
  functionManager: AzureFunctionManager;
56
+ /** Manager for Azure Key Vault resources */
42
57
  keyVaultManager: AzureKeyVaultManager;
58
+ /** Manager for Azure Log Analytics Workspace resources */
43
59
  operationalInsightsManager: AzureOperationalInsightsManager;
60
+ /** Manager for Azure Portal Dashboard resources */
44
61
  portalManager: AzurePortalManager;
62
+ /** Manager for Azure Monitor diagnostic settings */
45
63
  monitorManager: AzureMonitorManager;
64
+ /** Manager for Azure Managed Redis (Enterprise) resources */
46
65
  redisManager: AzureRedisManager;
66
+ /** Manager for Azure Resource Group resources */
47
67
  resourceGroupManager: AzureResourceGroupManager;
68
+ /** Formatter for Azure resource names based on naming conventions */
48
69
  resourceNameFormatter: AzureResourceNameFormatter;
70
+ /** Manager for Azure Security Center (Defender) resources */
49
71
  securityCentermanager: AzureSecurityCentermanager;
72
+ /** Manager for Azure Service Bus resources */
50
73
  serviceBusManager: AzureServiceBusManager;
74
+ /** Manager for Azure Storage resources */
51
75
  storageManager: AzureStorageManager;
76
+ /** Shared Log Analytics Workspace resolved from props, used for diagnostic logging */
52
77
  commonLogAnalyticsWorkspace: Workspace | Output<GetWorkspaceResult>;
78
+ /**
79
+ * @summary Create a new CommonAzureConstruct
80
+ * @param name the scoped name of the construct
81
+ * @param props the common Azure stack properties
82
+ * @param options optional Pulumi component resource options
83
+ */
53
84
  constructor(name: string, props: CommonAzureStackProps, options?: ComponentResourceOptions);
85
+ /**
86
+ * @summary Resolve a Pulumi stack reference for cross-stack outputs
87
+ * @param id scoped id of the stack reference resource
88
+ * @param stackName optional fully qualified stack name; defaults to id if not provided
89
+ */
54
90
  protected resolveStack(id: string, stackName?: string): pulumi.StackReference;
91
+ /**
92
+ * @summary Create the resource group for this construct
93
+ * - Uses the resourceGroupName from props or falls back to the construct id
94
+ * - Registers resource group id and name as stack outputs
95
+ * - No-op if the resource group already exists
96
+ */
55
97
  protected createResourceGroup(): void;
98
+ /**
99
+ * @summary Resolve a shared Log Analytics Workspace from props
100
+ * - Populates the commonLogAnalyticsWorkspace property for use in diagnostic settings
101
+ * - No-op if commonLogAnalyticsWorkspace is not configured in props
102
+ */
56
103
  protected resolveCommonLogAnalyticsWorkspace(): void;
57
104
  /**
58
105
  * @summary Determine the fully qualified domain name based on domainName & subDomain
@@ -24,29 +24,58 @@ import { AzureResourceNameFormatter } from './resource-name-formatter.js';
24
24
  * @category Common
25
25
  */
26
26
  export class CommonAzureConstruct extends ComponentResource {
27
+ /** Unique identifier for the construct */
27
28
  id;
29
+ /** The Azure resource group associated with this construct */
28
30
  resourceGroup;
31
+ /** The fully qualified domain name derived from domainName and subDomain */
29
32
  fullyQualifiedDomainName;
33
+ /** Manager for Azure RBAC role assignments */
30
34
  authorisationManager;
35
+ /** Manager for Azure API Management resources */
31
36
  apiManagementManager;
37
+ /** Manager for Azure App Configuration resources */
32
38
  appConfigurationManager;
39
+ /** Manager for Azure App Service resources */
33
40
  appServiceManager;
41
+ /** Manager for Azure Application Insights resources */
34
42
  applicationInsightsManager;
43
+ /** Manager for Azure CosmosDB resources */
35
44
  cosmosDbManager;
45
+ /** Manager for Azure DNS resources */
36
46
  dnsManager;
47
+ /** Manager for Azure Event Grid resources */
37
48
  eventgridManager;
49
+ /** Manager for Azure Function App resources */
38
50
  functionManager;
51
+ /** Manager for Azure Key Vault resources */
39
52
  keyVaultManager;
53
+ /** Manager for Azure Log Analytics Workspace resources */
40
54
  operationalInsightsManager;
55
+ /** Manager for Azure Portal Dashboard resources */
41
56
  portalManager;
57
+ /** Manager for Azure Monitor diagnostic settings */
42
58
  monitorManager;
59
+ /** Manager for Azure Managed Redis (Enterprise) resources */
43
60
  redisManager;
61
+ /** Manager for Azure Resource Group resources */
44
62
  resourceGroupManager;
63
+ /** Formatter for Azure resource names based on naming conventions */
45
64
  resourceNameFormatter;
65
+ /** Manager for Azure Security Center (Defender) resources */
46
66
  securityCentermanager;
67
+ /** Manager for Azure Service Bus resources */
47
68
  serviceBusManager;
69
+ /** Manager for Azure Storage resources */
48
70
  storageManager;
71
+ /** Shared Log Analytics Workspace resolved from props, used for diagnostic logging */
49
72
  commonLogAnalyticsWorkspace;
73
+ /**
74
+ * @summary Create a new CommonAzureConstruct
75
+ * @param name the scoped name of the construct
76
+ * @param props the common Azure stack properties
77
+ * @param options optional Pulumi component resource options
78
+ */
50
79
  constructor(name, props, options) {
51
80
  super(`construct:${name}`, name, props, options);
52
81
  this.props = props;
@@ -73,6 +102,11 @@ export class CommonAzureConstruct extends ComponentResource {
73
102
  this.storageManager = new AzureStorageManager();
74
103
  this.determineFullyQualifiedDomain();
75
104
  }
105
+ /**
106
+ * @summary Resolve a Pulumi stack reference for cross-stack outputs
107
+ * @param id scoped id of the stack reference resource
108
+ * @param stackName optional fully qualified stack name; defaults to id if not provided
109
+ */
76
110
  resolveStack(id, stackName) {
77
111
  const name = stackName ?? id;
78
112
  if (!name)
@@ -81,6 +115,12 @@ export class CommonAzureConstruct extends ComponentResource {
81
115
  name,
82
116
  });
83
117
  }
118
+ /**
119
+ * @summary Create the resource group for this construct
120
+ * - Uses the resourceGroupName from props or falls back to the construct id
121
+ * - Registers resource group id and name as stack outputs
122
+ * - No-op if the resource group already exists
123
+ */
84
124
  createResourceGroup() {
85
125
  if (this.resourceGroup)
86
126
  return;
@@ -93,6 +133,11 @@ export class CommonAzureConstruct extends ComponentResource {
93
133
  resourceGroupName: this.resourceGroup.name,
94
134
  });
95
135
  }
136
+ /**
137
+ * @summary Resolve a shared Log Analytics Workspace from props
138
+ * - Populates the commonLogAnalyticsWorkspace property for use in diagnostic settings
139
+ * - No-op if commonLogAnalyticsWorkspace is not configured in props
140
+ */
96
141
  resolveCommonLogAnalyticsWorkspace() {
97
142
  if (!this.props.commonLogAnalyticsWorkspace || !this.props.commonLogAnalyticsWorkspace.workspaceName)
98
143
  return;
@@ -7,7 +7,12 @@ import { AzureResourceNameFormatterProps, CommonAzureStackProps } from '../index
7
7
  * @category Common
8
8
  */
9
9
  export declare class AzureResourceNameFormatter {
10
+ /** Stack properties containing naming configuration */
10
11
  props: CommonAzureStackProps;
12
+ /**
13
+ * @summary Create a new AzureResourceNameFormatter
14
+ * @param props the common Azure stack properties containing naming configuration
15
+ */
11
16
  constructor(props: CommonAzureStackProps);
12
17
  /**
13
18
  * @summary Helper method to format azure resource name based on the provided options
@@ -6,7 +6,12 @@
6
6
  * @category Common
7
7
  */
8
8
  export class AzureResourceNameFormatter {
9
+ /** Stack properties containing naming configuration */
9
10
  props;
11
+ /**
12
+ * @summary Create a new AzureResourceNameFormatter
13
+ * @param props the common Azure stack properties containing naming configuration
14
+ */
10
15
  constructor(props) {
11
16
  this.props = props;
12
17
  }
@@ -17,11 +17,22 @@ import { CommonAzureStackProps } from './types.js';
17
17
  * @category Common
18
18
  */
19
19
  export declare class CommonAzureStack extends ComponentResource {
20
+ /** Default Node.js runtime version for Azure Function Apps */
20
21
  static NODEJS_RUNTIME: string;
22
+ /** The construct instance created by this stack */
21
23
  construct: CommonAzureConstruct;
24
+ /** Stack properties including environment-specific configuration */
22
25
  props: CommonAzureStackProps;
26
+ /** Pulumi config instance for reading stack configuration values */
23
27
  config: Config;
28
+ /** Registered stack outputs for cross-stack references */
24
29
  outputs?: Record<string, unknown>;
30
+ /**
31
+ * @summary Create a new CommonAzureStack
32
+ * @param name the scoped name of the stack
33
+ * @param props the common Azure stack properties
34
+ * @param options optional Pulumi component resource options
35
+ */
25
36
  constructor(name: string, props: CommonAzureStackProps, options?: ComponentResourceOptions);
26
37
  /**
27
38
  * @summary Method to determine the core construct properties injected via context
@@ -41,12 +52,30 @@ export declare class CommonAzureStack extends ComponentResource {
41
52
  * - Primary use is to have layered config for each environment which is injected into the context
42
53
  */
43
54
  protected determineStageContexts(): any;
55
+ /**
56
+ * @summary Create the construct instance for this stack
57
+ * - Override in subclasses to provision infrastructure resources
58
+ */
44
59
  protected createConstruct(): void;
60
+ /**
61
+ * @summary Register stack outputs for cross-stack consumption
62
+ * - Registers resource group id and name if a construct with a resource group exists
63
+ */
45
64
  protected registerOutputs(): void;
46
65
  /**
47
66
  * @summary Determine the fully qualified domain name based on domainName & subDomain
48
67
  */
49
68
  protected fullyQualifiedDomain(): string;
69
+ /**
70
+ * @summary Walk up the directory tree to locate the infrastructure root containing the stage context path
71
+ * @returns The directory path containing the stage context configuration
72
+ * @throws Error if the stage context directory cannot be found within 6 parent directories
73
+ */
50
74
  protected static determineEnvironmentProperty(): string;
75
+ /**
76
+ * @summary Retrieve a specific property from the stage-specific environment configuration file
77
+ * @param property the property key to retrieve from the environment config
78
+ * @returns The value of the requested property from the stage config JSON
79
+ */
51
80
  protected static getEnvironmentProperty(property: string): any;
52
81
  }
@@ -21,11 +21,22 @@ import { registerTagTransformation } from './tagging.js';
21
21
  * @category Common
22
22
  */
23
23
  export class CommonAzureStack extends ComponentResource {
24
+ /** Default Node.js runtime version for Azure Function Apps */
24
25
  static NODEJS_RUNTIME = '22';
26
+ /** The construct instance created by this stack */
25
27
  construct;
28
+ /** Stack properties including environment-specific configuration */
26
29
  props;
30
+ /** Pulumi config instance for reading stack configuration values */
27
31
  config;
32
+ /** Registered stack outputs for cross-stack references */
28
33
  outputs;
34
+ /**
35
+ * @summary Create a new CommonAzureStack
36
+ * @param name the scoped name of the stack
37
+ * @param props the common Azure stack properties
38
+ * @param options optional Pulumi component resource options
39
+ */
29
40
  constructor(name, props, options) {
30
41
  super(`stack:${name}`, name, props, options);
31
42
  /* initialise config */
@@ -113,7 +124,15 @@ export class CommonAzureStack extends ComponentResource {
113
124
  /* parse as JSON properties */
114
125
  return JSON.parse(stageContextPropsBuffer.toString('utf-8'));
115
126
  }
127
+ /**
128
+ * @summary Create the construct instance for this stack
129
+ * - Override in subclasses to provision infrastructure resources
130
+ */
116
131
  createConstruct() { }
132
+ /**
133
+ * @summary Register stack outputs for cross-stack consumption
134
+ * - Registers resource group id and name if a construct with a resource group exists
135
+ */
117
136
  registerOutputs() {
118
137
  if (this.construct && this.construct.resourceGroup) {
119
138
  this.outputs = _.merge(this.outputs, {
@@ -131,6 +150,11 @@ export class CommonAzureStack extends ComponentResource {
131
150
  const subDomain = this.props.subDomain;
132
151
  return subDomain ? `${subDomain}.${domainName}` : domainName;
133
152
  }
153
+ /**
154
+ * @summary Walk up the directory tree to locate the infrastructure root containing the stage context path
155
+ * @returns The directory path containing the stage context configuration
156
+ * @throws Error if the stage context directory cannot be found within 6 parent directories
157
+ */
134
158
  static determineEnvironmentProperty() {
135
159
  const config = new Config();
136
160
  const stageContextPath = config.get('stageContextPath');
@@ -147,6 +171,11 @@ export class CommonAzureStack extends ComponentResource {
147
171
  }
148
172
  throw new Error('Could not locate infrastructure root (pulumi-env/ not found)');
149
173
  }
174
+ /**
175
+ * @summary Retrieve a specific property from the stage-specific environment configuration file
176
+ * @param property the property key to retrieve from the environment config
177
+ * @returns The value of the requested property from the stage config JSON
178
+ */
150
179
  static getEnvironmentProperty(property) {
151
180
  const config = new Config();
152
181
  const stage = config.get('stage');
@@ -2,60 +2,109 @@ import { GetComponentOutputArgs } from '@pulumi/azure-native/applicationinsights
2
2
  import { GetWorkspaceOutputArgs } from '@pulumi/azure-native/operationalinsights/index.js';
3
3
  import { BaseProps } from '@gradientedge/cdk-utils-common';
4
4
  import { AzureLocation, AzureRemoteBackend } from './constants.js';
5
- /** @category Interface */
5
+ /**
6
+ * Configuration for an Azure location/region
7
+ * @category Interface
8
+ */
6
9
  export interface AzureLocationConfig {
10
+ /** Unique identifier for the location */
7
11
  id: string;
12
+ /** Display name of the location */
8
13
  name: string;
9
14
  }
10
15
  /**
11
16
  * @interface CommonAzureStackProps
12
17
  * Common properties for Azure stack configuration using Pulumi
13
18
  */
14
- /** @category Interface */
19
+ /**
20
+ * Common properties for Azure stack configuration using Pulumi
21
+ * @category Interface
22
+ */
15
23
  export interface CommonAzureStackProps extends BaseProps {
24
+ /** Optional Pulumi stack name for cross-stack references */
16
25
  stackName?: string;
26
+ /** Optional Azure resource group name override */
17
27
  resourceGroupName?: string;
28
+ /** Remote backend configuration for Pulumi state storage */
18
29
  remoteBackend?: AzureRemoteBackendProps;
30
+ /** Global prefix applied to all resource names */
19
31
  globalPrefix?: string;
32
+ /** Global suffix applied to all resource names */
20
33
  globalSuffix?: string;
34
+ /** Prefix applied to individual resource names */
21
35
  resourcePrefix?: string;
36
+ /** Suffix applied to individual resource names */
22
37
  resourceSuffix?: string;
38
+ /** Per-resource naming options keyed by resource type identifier */
23
39
  resourceNameOptions?: {
24
40
  [key: string]: AzureResourceNameFormatterProps;
25
41
  };
42
+ /** Primary Azure region for resource deployment */
26
43
  location: AzureLocation;
44
+ /** Location configuration map for multi-region deployments */
27
45
  locationConfig?: Record<AzureLocation, AzureLocationConfig>;
46
+ /** List of supported locales for the deployment */
28
47
  locales?: string[];
48
+ /** Default tags applied to all taggable Azure resources */
29
49
  defaultTags?: {
30
50
  [key: string]: string;
31
51
  };
52
+ /** Shared Log Analytics Workspace lookup arguments for diagnostic logging */
32
53
  commonLogAnalyticsWorkspace?: GetWorkspaceOutputArgs;
54
+ /** Shared Application Insights component lookup arguments for telemetry */
33
55
  commonApplicationInsights?: GetComponentOutputArgs;
56
+ /** Azure subscription ID for the deployment */
34
57
  subscriptionId?: string;
58
+ /** Azure Active Directory tenant ID */
35
59
  tenantId?: string;
60
+ /** Service principal client ID for authentication */
36
61
  clientId?: string;
62
+ /** Service principal client secret for authentication */
37
63
  clientSecret?: string;
64
+ /** Azure cloud environment (e.g. 'public', 'usgovernment') */
38
65
  environment?: string;
66
+ /** Enable OpenID Connect (OIDC) authentication */
39
67
  useOidc?: boolean;
68
+ /** OIDC request token for federated identity */
40
69
  oidcRequestToken?: string;
70
+ /** OIDC request URL for federated identity */
41
71
  oidcRequestUrl?: string;
72
+ /** Enable Managed Service Identity (MSI) authentication */
42
73
  useMsi?: boolean;
74
+ /** Custom MSI endpoint URL */
43
75
  msiEndpoint?: string;
44
76
  }
45
- /** @category Interface */
77
+ /**
78
+ * Properties for configuring Azure remote backend state storage
79
+ * @category Interface
80
+ */
46
81
  export interface AzureRemoteBackendProps {
82
+ /** The type of remote backend to use */
47
83
  type: AzureRemoteBackend;
84
+ /** Azure Storage Account name for state storage */
48
85
  storageAccountName?: string;
86
+ /** Azure Storage container name for state files */
49
87
  containerName?: string;
88
+ /** Resource group containing the storage account */
50
89
  resourceGroupName?: string;
90
+ /** Azure subscription ID for the backend storage account */
51
91
  subscriptionId?: string;
92
+ /** State file key/path within the container */
52
93
  key?: string;
53
94
  }
54
- /** @category Interface */
95
+ /**
96
+ * Options to control the formatting of Azure resource names
97
+ * @category Interface
98
+ */
55
99
  export interface AzureResourceNameFormatterProps {
100
+ /** When true, excludes both prefix and suffix from the formatted name */
56
101
  exclude?: boolean;
102
+ /** When true, includes the global prefix from stack props */
57
103
  globalPrefix?: boolean;
104
+ /** When true, includes the global suffix from stack props */
58
105
  globalSuffix?: boolean;
106
+ /** Custom prefix for this specific resource name */
59
107
  prefix?: string;
108
+ /** Custom suffix for this specific resource name */
60
109
  suffix?: string;
61
110
  }
@@ -18,9 +18,13 @@ import { AzureEventHandlerProps, EventHandlerEventGridSubscription, EventHandler
18
18
  * @category Construct
19
19
  */
20
20
  export declare class AzureEventHandler extends AzureFunctionApp {
21
+ /** Event handler properties */
21
22
  props: AzureEventHandlerProps;
23
+ /** Provisioned EventGrid subscription resources including dead-letter storage */
22
24
  eventGridEventSubscription: EventHandlerEventGridSubscription;
25
+ /** The provisioned or resolved EventGrid topic */
23
26
  eventGridTopic: Topic | Output<GetTopicResult>;
27
+ /** Provisioned Service Bus resources (namespace and queue) */
24
28
  serviceBus: EventHandlerServiceBus;
25
29
  /**
26
30
  * @summary Create a new AzureEventHandler
@@ -18,9 +18,13 @@ import { AzureFunctionApp } from '../function-app/index.js';
18
18
  * @category Construct
19
19
  */
20
20
  export class AzureEventHandler extends AzureFunctionApp {
21
+ /** Event handler properties */
21
22
  props;
23
+ /** Provisioned EventGrid subscription resources including dead-letter storage */
22
24
  eventGridEventSubscription;
25
+ /** The provisioned or resolved EventGrid topic */
23
26
  eventGridTopic;
27
+ /** Provisioned Service Bus resources (namespace and queue) */
24
28
  serviceBus;
25
29
  /**
26
30
  * @summary Create a new AzureEventHandler
@@ -4,40 +4,77 @@ import { BlobContainer, StorageAccount } from '@pulumi/azure-native/storage/inde
4
4
  import { Input, Output } from '@pulumi/pulumi';
5
5
  import { DefenderForStorageProps, EventgridEventSubscriptionProps, EventgridTopicProps, ServiceBusNamespaceProps, ServiceBusQueueProps, StorageAccountProps, StorageContainerProps } from '../../services/index.js';
6
6
  import { AzureFunctionAppProps } from '../function-app/index.js';
7
- /** @category Interface */
7
+ /**
8
+ * Properties for the EventGrid subscription dead-letter queue storage
9
+ * @category Interface
10
+ */
8
11
  export interface EventHandlerEventGridSubscriptionProps {
12
+ /** Storage account properties for the dead-letter queue */
9
13
  dlqStorageAccount: StorageAccountProps;
14
+ /** Storage container properties for the dead-letter queue */
10
15
  dlqStorageContainer: StorageContainerProps;
11
16
  }
12
- /** @category Interface */
17
+ /**
18
+ * Provisioned EventGrid subscription resources including dead-letter storage
19
+ * @category Interface
20
+ */
13
21
  export interface EventHandlerEventGridSubscription {
22
+ /** The provisioned dead-letter queue storage account */
14
23
  dlqStorageAccount?: StorageAccount;
24
+ /** The provisioned dead-letter queue storage container */
15
25
  dlqStorageContainer?: BlobContainer;
26
+ /** The provisioned EventGrid event subscription */
16
27
  eventSubscription?: EventSubscription;
17
28
  }
18
- /** @category Interface */
29
+ /**
30
+ * Properties for configuring the Service Bus integration in the event handler
31
+ * @category Interface
32
+ */
19
33
  export interface EventHandlerServiceBusProps {
34
+ /** Service Bus namespace properties */
20
35
  namespace?: ServiceBusNamespaceProps;
36
+ /** Service Bus queue properties */
21
37
  queue?: ServiceBusQueueProps;
38
+ /** When true, resolves an existing Service Bus instead of creating a new one */
22
39
  useExisting?: boolean;
23
40
  }
24
- /** @category Interface */
41
+ /**
42
+ * Provisioned Service Bus resources for the event handler
43
+ * @category Interface
44
+ */
25
45
  export interface EventHandlerServiceBus {
46
+ /** The provisioned or resolved Service Bus namespace */
26
47
  namespace: Namespace | Output<GetNamespaceResult>;
48
+ /** The provisioned or resolved Service Bus queue */
27
49
  queue: Queue | Output<GetQueueResult>;
28
50
  }
29
- /** @category Interface */
51
+ /**
52
+ * Properties for configuring the EventGrid topic in the event handler
53
+ * @category Interface
54
+ */
30
55
  export interface EventHandlerEventGridTopicProps extends EventgridTopicProps {
56
+ /** When true, resolves an existing EventGrid topic instead of creating a new one */
31
57
  useExistingTopic: boolean;
58
+ /** Subscription ID of the existing EventGrid topic (for cross-subscription access) */
32
59
  existingSubscriptionId?: string;
60
+ /** Name of the existing EventGrid topic to resolve */
33
61
  existingTopicName?: string;
62
+ /** Resource group name of the existing EventGrid topic */
34
63
  existingResourceGroupName?: Input<string>;
35
64
  }
36
- /** @category Interface */
65
+ /**
66
+ * Properties for the {@link AzureEventHandler} construct
67
+ * @category Interface
68
+ */
37
69
  export interface AzureEventHandlerProps extends AzureFunctionAppProps {
70
+ /** Microsoft Defender for Storage configuration */
38
71
  defender?: DefenderForStorageProps;
72
+ /** EventGrid event subscription properties */
39
73
  eventGridEventSubscription?: EventgridEventSubscriptionProps;
74
+ /** EventGrid subscription dead-letter queue storage properties */
40
75
  eventGridSubscription: EventHandlerEventGridSubscriptionProps;
76
+ /** EventGrid topic properties */
41
77
  eventGridTopic: EventHandlerEventGridTopicProps;
78
+ /** Service Bus integration properties */
42
79
  serviceBus?: EventHandlerServiceBusProps;
43
80
  }
@@ -25,28 +25,51 @@ import { AzureFunctionAppProps } from './types.js';
25
25
  * @category Construct
26
26
  */
27
27
  export declare class AzureFunctionApp extends CommonAzureConstruct {
28
+ /** Function app properties */
28
29
  props: AzureFunctionAppProps;
30
+ /** The provisioned Azure Function App web app resource */
29
31
  app: WebApp;
32
+ /** The provisioned App Service Plan for the function app */
30
33
  appServicePlan: AppServicePlan;
34
+ /** Environment variables to inject into the function app configuration */
31
35
  appEnvironmentVariables: Record<string, any>;
36
+ /** The provisioned storage account for the function app */
32
37
  appStorageAccount: StorageAccount;
38
+ /** The provisioned storage container for deployment artifacts */
33
39
  appDeploymentStorageContainer: BlobContainer;
40
+ /** The provisioned storage container for function app data */
34
41
  appStorageContainer: BlobContainer;
42
+ /** The provisioned or resolved App Configuration store */
35
43
  appConfig: ConfigurationStore | Output<GetConfigurationStoreResult>;
44
+ /** The archive file output for the function app deployment package */
36
45
  appCodeArchiveFile: Output<archive.GetFileResult>;
46
+ /** Hash of the app configuration for change detection */
37
47
  appConfigHash: string;
48
+ /** Map of resource group names to sets of Key Vault names for role assignments */
38
49
  appKeyVaultsByResourceGroup: Map<string, Set<string>>;
50
+ /** Connection strings to configure on the function app */
39
51
  appConnectionStrings: any[];
52
+ /** Prefix for App Configuration key names */
40
53
  appConfigPrefix?: string;
54
+ /** Parsed app configuration data (processed version) */
41
55
  appConfigurationsParsedConfig: any;
56
+ /** Parsed app configuration data (original version before processing) */
42
57
  appConfigurationsOriginalParsedConfig: any;
58
+ /** The provisioned Key Vault for data storage secrets */
43
59
  dataKeyVault: Vault;
60
+ /** The provisioned data storage account */
44
61
  dataStorageAccount: StorageAccount;
62
+ /** The provisioned data storage container */
45
63
  dataStorageContainer: BlobContainer;
64
+ /** The resolved Application Insights component for telemetry */
46
65
  applicationInsights: Output<GetComponentResult>;
66
+ /** The provisioned Azure Portal dashboard for monitoring */
47
67
  functionDashboard: Dashboard;
68
+ /** Role assignment granting the function app access to the storage account */
48
69
  storageRoleAssignment: RoleAssignment;
70
+ /** Role assignment granting the function app access to the App Configuration store */
49
71
  appConfigRoleAssignment: RoleAssignment;
72
+ /** Role assignment granting the function app access to EventGrid topics */
50
73
  eventGridRoleAssignment: RoleAssignment;
51
74
  /**
52
75
  * @summary Create a new AzureFunctionApp