@cdktf-providers/newrelic 3.75.4

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 (147) hide show
  1. package/LICENSE +355 -0
  2. package/README.md +19 -0
  3. package/dist/account-management/index.d.ts +64 -0
  4. package/dist/account-management/index.js +131 -0
  5. package/dist/alert-channel/index.d.ts +347 -0
  6. package/dist/alert-channel/index.js +810 -0
  7. package/dist/alert-condition/index.d.ts +267 -0
  8. package/dist/alert-condition/index.js +587 -0
  9. package/dist/alert-muting-rule/index.d.ts +305 -0
  10. package/dist/alert-muting-rule/index.js +731 -0
  11. package/dist/alert-policy/index.d.ts +87 -0
  12. package/dist/alert-policy/index.js +180 -0
  13. package/dist/alert-policy-channel/index.d.ts +110 -0
  14. package/dist/alert-policy-channel/index.js +260 -0
  15. package/dist/api-access-key/index.d.ts +98 -0
  16. package/dist/api-access-key/index.js +230 -0
  17. package/dist/application-settings/index.d.ts +410 -0
  18. package/dist/application-settings/index.js +966 -0
  19. package/dist/browser-application/index.d.ts +101 -0
  20. package/dist/browser-application/index.js +215 -0
  21. package/dist/cloud-aws-govcloud-integrations/index.d.ts +1519 -0
  22. package/dist/cloud-aws-govcloud-integrations/index.js +3846 -0
  23. package/dist/cloud-aws-govcloud-link-account/index.d.ts +86 -0
  24. package/dist/cloud-aws-govcloud-link-account/index.js +177 -0
  25. package/dist/cloud-aws-integrations/index.d.ts +3294 -0
  26. package/dist/cloud-aws-integrations/index.js +8554 -0
  27. package/dist/cloud-aws-link-account/index.d.ts +86 -0
  28. package/dist/cloud-aws-link-account/index.js +177 -0
  29. package/dist/cloud-azure-integrations/index.d.ts +1662 -0
  30. package/dist/cloud-azure-integrations/index.js +4338 -0
  31. package/dist/cloud-azure-link-account/index.d.ts +105 -0
  32. package/dist/cloud-azure-link-account/index.js +214 -0
  33. package/dist/cloud-gcp-integrations/index.d.ts +1045 -0
  34. package/dist/cloud-gcp-integrations/index.js +2742 -0
  35. package/dist/cloud-gcp-link-account/index.d.ts +75 -0
  36. package/dist/cloud-gcp-link-account/index.js +154 -0
  37. package/dist/cloud-oci-link-account/index.d.ts +191 -0
  38. package/dist/cloud-oci-link-account/index.js +392 -0
  39. package/dist/data-newrelic-account/index.d.ts +77 -0
  40. package/dist/data-newrelic-account/index.js +160 -0
  41. package/dist/data-newrelic-alert-channel/index.d.ts +122 -0
  42. package/dist/data-newrelic-alert-channel/index.js +295 -0
  43. package/dist/data-newrelic-alert-policy/index.d.ts +78 -0
  44. package/dist/data-newrelic-alert-policy/index.js +165 -0
  45. package/dist/data-newrelic-application/index.d.ts +56 -0
  46. package/dist/data-newrelic-application/index.js +119 -0
  47. package/dist/data-newrelic-authentication-domain/index.d.ts +43 -0
  48. package/dist/data-newrelic-authentication-domain/index.js +92 -0
  49. package/dist/data-newrelic-cloud-account/index.d.ts +75 -0
  50. package/dist/data-newrelic-cloud-account/index.js +154 -0
  51. package/dist/data-newrelic-entity/index.d.ts +185 -0
  52. package/dist/data-newrelic-entity/index.js +414 -0
  53. package/dist/data-newrelic-group/index.d.ts +54 -0
  54. package/dist/data-newrelic-group/index.js +116 -0
  55. package/dist/data-newrelic-key-transaction/index.d.ts +78 -0
  56. package/dist/data-newrelic-key-transaction/index.js +165 -0
  57. package/dist/data-newrelic-notification-destination/index.d.ts +161 -0
  58. package/dist/data-newrelic-notification-destination/index.js +368 -0
  59. package/dist/data-newrelic-obfuscation-expression/index.d.ts +65 -0
  60. package/dist/data-newrelic-obfuscation-expression/index.js +134 -0
  61. package/dist/data-newrelic-service-level-alert-helper/index.d.ts +107 -0
  62. package/dist/data-newrelic-service-level-alert-helper/index.js +256 -0
  63. package/dist/data-newrelic-synthetics-private-location/index.d.ts +76 -0
  64. package/dist/data-newrelic-synthetics-private-location/index.js +157 -0
  65. package/dist/data-newrelic-synthetics-secure-credential/index.d.ts +67 -0
  66. package/dist/data-newrelic-synthetics-secure-credential/index.js +142 -0
  67. package/dist/data-newrelic-test-grok-pattern/index.d.ts +145 -0
  68. package/dist/data-newrelic-test-grok-pattern/index.js +312 -0
  69. package/dist/data-newrelic-user/index.d.ts +65 -0
  70. package/dist/data-newrelic-user/index.js +138 -0
  71. package/dist/data-partition-rule/index.d.ts +142 -0
  72. package/dist/data-partition-rule/index.js +327 -0
  73. package/dist/entity-tags/index.d.ts +152 -0
  74. package/dist/entity-tags/index.js +367 -0
  75. package/dist/events-to-metrics-rule/index.d.ts +98 -0
  76. package/dist/events-to-metrics-rule/index.js +204 -0
  77. package/dist/group/index.d.ts +75 -0
  78. package/dist/group/index.js +154 -0
  79. package/dist/index.d.ts +67 -0
  80. package/dist/index.js +68 -0
  81. package/dist/infra-alert-condition/index.d.ts +289 -0
  82. package/dist/infra-alert-condition/index.js +691 -0
  83. package/dist/insights-event/index.d.ts +182 -0
  84. package/dist/insights-event/index.js +427 -0
  85. package/dist/key-transaction/index.d.ts +96 -0
  86. package/dist/key-transaction/index.js +199 -0
  87. package/dist/lazy-index.d.ts +0 -0
  88. package/dist/lazy-index.js +68 -0
  89. package/dist/log-parsing-rule/index.d.ts +128 -0
  90. package/dist/log-parsing-rule/index.js +264 -0
  91. package/dist/monitor-downtime/index.d.ts +255 -0
  92. package/dist/monitor-downtime/index.js +603 -0
  93. package/dist/notification-channel/index.d.ts +236 -0
  94. package/dist/notification-channel/index.js +561 -0
  95. package/dist/notification-destination/index.d.ts +402 -0
  96. package/dist/notification-destination/index.js +1039 -0
  97. package/dist/nrql-alert-condition/index.d.ts +892 -0
  98. package/dist/nrql-alert-condition/index.js +2177 -0
  99. package/dist/nrql-drop-rule/index.d.ts +123 -0
  100. package/dist/nrql-drop-rule/index.js +291 -0
  101. package/dist/obfuscation-expression/index.d.ts +86 -0
  102. package/dist/obfuscation-expression/index.js +177 -0
  103. package/dist/obfuscation-rule/index.d.ts +169 -0
  104. package/dist/obfuscation-rule/index.js +372 -0
  105. package/dist/one-dashboard/index-structs/index.d.ts +2 -0
  106. package/dist/one-dashboard/index-structs/index.js +2 -0
  107. package/dist/one-dashboard/index-structs/structs0.d.ts +6996 -0
  108. package/dist/one-dashboard/index-structs/structs0.js +18191 -0
  109. package/dist/one-dashboard/index-structs/structs400.d.ts +3699 -0
  110. package/dist/one-dashboard/index-structs/structs400.js +9611 -0
  111. package/dist/one-dashboard/index.d.ts +112 -0
  112. package/dist/one-dashboard/index.js +232 -0
  113. package/dist/one-dashboard-json/index.d.ts +112 -0
  114. package/dist/one-dashboard-json/index.js +280 -0
  115. package/dist/one-dashboard-raw/index.d.ts +274 -0
  116. package/dist/one-dashboard-raw/index.js +666 -0
  117. package/dist/pipeline-cloud-rule/index.d.ts +86 -0
  118. package/dist/pipeline-cloud-rule/index.js +177 -0
  119. package/dist/provider/index.d.ts +160 -0
  120. package/dist/provider/index.js +378 -0
  121. package/dist/service-level/index.d.ts +501 -0
  122. package/dist/service-level/index.js +1425 -0
  123. package/dist/synthetics-alert-condition/index.d.ts +97 -0
  124. package/dist/synthetics-alert-condition/index.js +201 -0
  125. package/dist/synthetics-broken-links-monitor/index.d.ts +217 -0
  126. package/dist/synthetics-broken-links-monitor/index.js +474 -0
  127. package/dist/synthetics-cert-check-monitor/index.d.ts +222 -0
  128. package/dist/synthetics-cert-check-monitor/index.js +490 -0
  129. package/dist/synthetics-monitor/index.d.ts +404 -0
  130. package/dist/synthetics-monitor/index.js +885 -0
  131. package/dist/synthetics-multilocation-alert-condition/index.d.ts +177 -0
  132. package/dist/synthetics-multilocation-alert-condition/index.js +407 -0
  133. package/dist/synthetics-private-location/index.d.ts +90 -0
  134. package/dist/synthetics-private-location/index.js +193 -0
  135. package/dist/synthetics-script-monitor/index.d.ts +348 -0
  136. package/dist/synthetics-script-monitor/index.js +768 -0
  137. package/dist/synthetics-secure-credential/index.d.ts +132 -0
  138. package/dist/synthetics-secure-credential/index.js +306 -0
  139. package/dist/synthetics-step-monitor/index.d.ts +368 -0
  140. package/dist/synthetics-step-monitor/index.js +834 -0
  141. package/dist/user/index.d.ts +85 -0
  142. package/dist/user/index.js +174 -0
  143. package/dist/workflow/index.d.ts +441 -0
  144. package/dist/workflow/index.js +1066 -0
  145. package/dist/workload/index.d.ts +514 -0
  146. package/dist/workload/index.js +1283 -0
  147. package/package.json +50 -0
@@ -0,0 +1,87 @@
1
+ import { Construct } from 'constructs';
2
+ import * as cdktf from 'cdktf';
3
+ export interface AlertPolicyConfig extends cdktf.TerraformMetaArguments {
4
+ /**
5
+ * The New Relic account ID to operate on.
6
+ *
7
+ * Docs at Terraform Registry: {@link https://registry.terraform.io/providers/newrelic/newrelic/3.75.4/docs/resources/alert_policy#account_id AlertPolicy#account_id}
8
+ */
9
+ readonly accountId?: number;
10
+ /**
11
+ * An array of channel IDs (integers) to assign to the policy. Adding or removing channel IDs from this array will result in a new alert policy resource being created and the old one being destroyed. Also note that channel IDs cannot be imported via terraform import.
12
+ *
13
+ * Docs at Terraform Registry: {@link https://registry.terraform.io/providers/newrelic/newrelic/3.75.4/docs/resources/alert_policy#channel_ids AlertPolicy#channel_ids}
14
+ */
15
+ readonly channelIds?: number[];
16
+ /**
17
+ * Docs at Terraform Registry: {@link https://registry.terraform.io/providers/newrelic/newrelic/3.75.4/docs/resources/alert_policy#id AlertPolicy#id}
18
+ *
19
+ * Please be aware that the id field is automatically added to all resources in Terraform providers using a Terraform provider SDK version below 2.
20
+ * If you experience problems setting this value it might not be settable. Please take a look at the provider documentation to ensure it should be settable.
21
+ */
22
+ readonly id?: string;
23
+ /**
24
+ * The rollup strategy for the policy. Options include: PER_POLICY, PER_CONDITION, or PER_CONDITION_AND_TARGET. The default is PER_POLICY.
25
+ *
26
+ * Docs at Terraform Registry: {@link https://registry.terraform.io/providers/newrelic/newrelic/3.75.4/docs/resources/alert_policy#incident_preference AlertPolicy#incident_preference}
27
+ */
28
+ readonly incidentPreference?: string;
29
+ /**
30
+ * The name of the policy.
31
+ *
32
+ * Docs at Terraform Registry: {@link https://registry.terraform.io/providers/newrelic/newrelic/3.75.4/docs/resources/alert_policy#name AlertPolicy#name}
33
+ */
34
+ readonly name: string;
35
+ }
36
+ /**
37
+ * Represents a {@link https://registry.terraform.io/providers/newrelic/newrelic/3.75.4/docs/resources/alert_policy newrelic_alert_policy}
38
+ */
39
+ export declare class AlertPolicy extends cdktf.TerraformResource {
40
+ static readonly tfResourceType = "newrelic_alert_policy";
41
+ /**
42
+ * Generates CDKTF code for importing a AlertPolicy resource upon running "cdktf plan <stack-name>"
43
+ * @param scope The scope in which to define this construct
44
+ * @param importToId The construct id used in the generated config for the AlertPolicy to import
45
+ * @param importFromId The id of the existing AlertPolicy that should be imported. Refer to the {@link https://registry.terraform.io/providers/newrelic/newrelic/3.75.4/docs/resources/alert_policy#import import section} in the documentation of this resource for the id to use
46
+ * @param provider? Optional instance of the provider where the AlertPolicy to import is found
47
+ */
48
+ static generateConfigForImport(scope: Construct, importToId: string, importFromId: string, provider?: cdktf.TerraformProvider): any;
49
+ /**
50
+ * Create a new {@link https://registry.terraform.io/providers/newrelic/newrelic/3.75.4/docs/resources/alert_policy newrelic_alert_policy} Resource
51
+ *
52
+ * @param scope The scope in which to define this construct
53
+ * @param id The scoped construct ID. Must be unique amongst siblings in the same scope
54
+ * @param options AlertPolicyConfig
55
+ */
56
+ constructor(scope: Construct, id: string, config: AlertPolicyConfig);
57
+ private _accountId?;
58
+ get accountId(): number;
59
+ set accountId(value: number);
60
+ resetAccountId(): void;
61
+ get accountIdInput(): number;
62
+ private _channelIds?;
63
+ get channelIds(): number[];
64
+ set channelIds(value: number[]);
65
+ resetChannelIds(): void;
66
+ get channelIdsInput(): number[];
67
+ private _id?;
68
+ get id(): string;
69
+ set id(value: string);
70
+ resetId(): void;
71
+ get idInput(): string;
72
+ private _incidentPreference?;
73
+ get incidentPreference(): string;
74
+ set incidentPreference(value: string);
75
+ resetIncidentPreference(): void;
76
+ get incidentPreferenceInput(): string;
77
+ private _name?;
78
+ get name(): string;
79
+ set name(value: string);
80
+ get nameInput(): string;
81
+ protected synthesizeAttributes(): {
82
+ [name: string]: any;
83
+ };
84
+ protected synthesizeHclAttributes(): {
85
+ [name: string]: any;
86
+ };
87
+ }
@@ -0,0 +1,180 @@
1
+ // https://registry.terraform.io/providers/newrelic/newrelic/3.75.4/docs/resources/alert_policy
2
+ // generated from terraform resource schema
3
+ import * as cdktf from 'cdktf';
4
+ /**
5
+ * Represents a {@link https://registry.terraform.io/providers/newrelic/newrelic/3.75.4/docs/resources/alert_policy newrelic_alert_policy}
6
+ */
7
+ export class AlertPolicy extends cdktf.TerraformResource {
8
+ // =================
9
+ // STATIC PROPERTIES
10
+ // =================
11
+ static tfResourceType = "newrelic_alert_policy";
12
+ // ==============
13
+ // STATIC Methods
14
+ // ==============
15
+ /**
16
+ * Generates CDKTF code for importing a AlertPolicy resource upon running "cdktf plan <stack-name>"
17
+ * @param scope The scope in which to define this construct
18
+ * @param importToId The construct id used in the generated config for the AlertPolicy to import
19
+ * @param importFromId The id of the existing AlertPolicy that should be imported. Refer to the {@link https://registry.terraform.io/providers/newrelic/newrelic/3.75.4/docs/resources/alert_policy#import import section} in the documentation of this resource for the id to use
20
+ * @param provider? Optional instance of the provider where the AlertPolicy to import is found
21
+ */
22
+ static generateConfigForImport(scope, importToId, importFromId, provider) {
23
+ return new cdktf.ImportableResource(scope, importToId, { terraformResourceType: "newrelic_alert_policy", importId: importFromId, provider });
24
+ }
25
+ // ===========
26
+ // INITIALIZER
27
+ // ===========
28
+ /**
29
+ * Create a new {@link https://registry.terraform.io/providers/newrelic/newrelic/3.75.4/docs/resources/alert_policy newrelic_alert_policy} Resource
30
+ *
31
+ * @param scope The scope in which to define this construct
32
+ * @param id The scoped construct ID. Must be unique amongst siblings in the same scope
33
+ * @param options AlertPolicyConfig
34
+ */
35
+ constructor(scope, id, config) {
36
+ super(scope, id, {
37
+ terraformResourceType: 'newrelic_alert_policy',
38
+ terraformGeneratorMetadata: {
39
+ providerName: 'newrelic',
40
+ providerVersion: '3.75.4',
41
+ providerVersionConstraint: '3.75.4'
42
+ },
43
+ provider: config.provider,
44
+ dependsOn: config.dependsOn,
45
+ count: config.count,
46
+ lifecycle: config.lifecycle,
47
+ provisioners: config.provisioners,
48
+ connection: config.connection,
49
+ forEach: config.forEach
50
+ });
51
+ this._accountId = config.accountId;
52
+ this._channelIds = config.channelIds;
53
+ this._id = config.id;
54
+ this._incidentPreference = config.incidentPreference;
55
+ this._name = config.name;
56
+ }
57
+ // ==========
58
+ // ATTRIBUTES
59
+ // ==========
60
+ // account_id - computed: true, optional: true, required: false
61
+ _accountId;
62
+ get accountId() {
63
+ return this.getNumberAttribute('account_id');
64
+ }
65
+ set accountId(value) {
66
+ this._accountId = value;
67
+ }
68
+ resetAccountId() {
69
+ this._accountId = undefined;
70
+ }
71
+ // Temporarily expose input value. Use with caution.
72
+ get accountIdInput() {
73
+ return this._accountId;
74
+ }
75
+ // channel_ids - computed: false, optional: true, required: false
76
+ _channelIds;
77
+ get channelIds() {
78
+ return this.getNumberListAttribute('channel_ids');
79
+ }
80
+ set channelIds(value) {
81
+ this._channelIds = value;
82
+ }
83
+ resetChannelIds() {
84
+ this._channelIds = undefined;
85
+ }
86
+ // Temporarily expose input value. Use with caution.
87
+ get channelIdsInput() {
88
+ return this._channelIds;
89
+ }
90
+ // id - computed: true, optional: true, required: false
91
+ _id;
92
+ get id() {
93
+ return this.getStringAttribute('id');
94
+ }
95
+ set id(value) {
96
+ this._id = value;
97
+ }
98
+ resetId() {
99
+ this._id = undefined;
100
+ }
101
+ // Temporarily expose input value. Use with caution.
102
+ get idInput() {
103
+ return this._id;
104
+ }
105
+ // incident_preference - computed: false, optional: true, required: false
106
+ _incidentPreference;
107
+ get incidentPreference() {
108
+ return this.getStringAttribute('incident_preference');
109
+ }
110
+ set incidentPreference(value) {
111
+ this._incidentPreference = value;
112
+ }
113
+ resetIncidentPreference() {
114
+ this._incidentPreference = undefined;
115
+ }
116
+ // Temporarily expose input value. Use with caution.
117
+ get incidentPreferenceInput() {
118
+ return this._incidentPreference;
119
+ }
120
+ // name - computed: false, optional: false, required: true
121
+ _name;
122
+ get name() {
123
+ return this.getStringAttribute('name');
124
+ }
125
+ set name(value) {
126
+ this._name = value;
127
+ }
128
+ // Temporarily expose input value. Use with caution.
129
+ get nameInput() {
130
+ return this._name;
131
+ }
132
+ // =========
133
+ // SYNTHESIS
134
+ // =========
135
+ synthesizeAttributes() {
136
+ return {
137
+ account_id: cdktf.numberToTerraform(this._accountId),
138
+ channel_ids: cdktf.listMapper(cdktf.numberToTerraform, false)(this._channelIds),
139
+ id: cdktf.stringToTerraform(this._id),
140
+ incident_preference: cdktf.stringToTerraform(this._incidentPreference),
141
+ name: cdktf.stringToTerraform(this._name),
142
+ };
143
+ }
144
+ synthesizeHclAttributes() {
145
+ const attrs = {
146
+ account_id: {
147
+ value: cdktf.numberToHclTerraform(this._accountId),
148
+ isBlock: false,
149
+ type: "simple",
150
+ storageClassType: "number",
151
+ },
152
+ channel_ids: {
153
+ value: cdktf.listMapperHcl(cdktf.numberToHclTerraform, false)(this._channelIds),
154
+ isBlock: false,
155
+ type: "list",
156
+ storageClassType: "numberList",
157
+ },
158
+ id: {
159
+ value: cdktf.stringToHclTerraform(this._id),
160
+ isBlock: false,
161
+ type: "simple",
162
+ storageClassType: "string",
163
+ },
164
+ incident_preference: {
165
+ value: cdktf.stringToHclTerraform(this._incidentPreference),
166
+ isBlock: false,
167
+ type: "simple",
168
+ storageClassType: "string",
169
+ },
170
+ name: {
171
+ value: cdktf.stringToHclTerraform(this._name),
172
+ isBlock: false,
173
+ type: "simple",
174
+ storageClassType: "string",
175
+ },
176
+ };
177
+ // remove undefined attributes
178
+ return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined));
179
+ }
180
+ }
@@ -0,0 +1,110 @@
1
+ import { Construct } from 'constructs';
2
+ import * as cdktf from 'cdktf';
3
+ export interface AlertPolicyChannelConfig extends cdktf.TerraformMetaArguments {
4
+ /**
5
+ * The New Relic account ID where you want to link the channel to.
6
+ *
7
+ * Docs at Terraform Registry: {@link https://registry.terraform.io/providers/newrelic/newrelic/3.75.4/docs/resources/alert_policy_channel#account_id AlertPolicyChannel#account_id}
8
+ */
9
+ readonly accountId?: number;
10
+ /**
11
+ * Array of channel IDs to apply to the specified policy. We recommended sorting channel IDs in ascending order to avoid drift your Terraform state.
12
+ *
13
+ * Docs at Terraform Registry: {@link https://registry.terraform.io/providers/newrelic/newrelic/3.75.4/docs/resources/alert_policy_channel#channel_ids AlertPolicyChannel#channel_ids}
14
+ */
15
+ readonly channelIds: number[];
16
+ /**
17
+ * Docs at Terraform Registry: {@link https://registry.terraform.io/providers/newrelic/newrelic/3.75.4/docs/resources/alert_policy_channel#id AlertPolicyChannel#id}
18
+ *
19
+ * Please be aware that the id field is automatically added to all resources in Terraform providers using a Terraform provider SDK version below 2.
20
+ * If you experience problems setting this value it might not be settable. Please take a look at the provider documentation to ensure it should be settable.
21
+ */
22
+ readonly id?: string;
23
+ /**
24
+ * The ID of the policy.
25
+ *
26
+ * Docs at Terraform Registry: {@link https://registry.terraform.io/providers/newrelic/newrelic/3.75.4/docs/resources/alert_policy_channel#policy_id AlertPolicyChannel#policy_id}
27
+ */
28
+ readonly policyId: number;
29
+ /**
30
+ * timeouts block
31
+ *
32
+ * Docs at Terraform Registry: {@link https://registry.terraform.io/providers/newrelic/newrelic/3.75.4/docs/resources/alert_policy_channel#timeouts AlertPolicyChannel#timeouts}
33
+ */
34
+ readonly timeouts?: AlertPolicyChannelTimeouts;
35
+ }
36
+ export interface AlertPolicyChannelTimeouts {
37
+ /**
38
+ * Docs at Terraform Registry: {@link https://registry.terraform.io/providers/newrelic/newrelic/3.75.4/docs/resources/alert_policy_channel#create AlertPolicyChannel#create}
39
+ */
40
+ readonly create?: string;
41
+ }
42
+ export declare function alertPolicyChannelTimeoutsToTerraform(struct?: AlertPolicyChannelTimeouts | cdktf.IResolvable): any;
43
+ export declare function alertPolicyChannelTimeoutsToHclTerraform(struct?: AlertPolicyChannelTimeouts | cdktf.IResolvable): any;
44
+ export declare class AlertPolicyChannelTimeoutsOutputReference extends cdktf.ComplexObject {
45
+ private isEmptyObject;
46
+ private resolvableValue?;
47
+ /**
48
+ * @param terraformResource The parent resource
49
+ * @param terraformAttribute The attribute on the parent resource this class is referencing
50
+ */
51
+ constructor(terraformResource: cdktf.IInterpolatingParent, terraformAttribute: string);
52
+ get internalValue(): AlertPolicyChannelTimeouts | cdktf.IResolvable | undefined;
53
+ set internalValue(value: AlertPolicyChannelTimeouts | cdktf.IResolvable | undefined);
54
+ private _create?;
55
+ get create(): string;
56
+ set create(value: string);
57
+ resetCreate(): void;
58
+ get createInput(): string;
59
+ }
60
+ /**
61
+ * Represents a {@link https://registry.terraform.io/providers/newrelic/newrelic/3.75.4/docs/resources/alert_policy_channel newrelic_alert_policy_channel}
62
+ */
63
+ export declare class AlertPolicyChannel extends cdktf.TerraformResource {
64
+ static readonly tfResourceType = "newrelic_alert_policy_channel";
65
+ /**
66
+ * Generates CDKTF code for importing a AlertPolicyChannel resource upon running "cdktf plan <stack-name>"
67
+ * @param scope The scope in which to define this construct
68
+ * @param importToId The construct id used in the generated config for the AlertPolicyChannel to import
69
+ * @param importFromId The id of the existing AlertPolicyChannel that should be imported. Refer to the {@link https://registry.terraform.io/providers/newrelic/newrelic/3.75.4/docs/resources/alert_policy_channel#import import section} in the documentation of this resource for the id to use
70
+ * @param provider? Optional instance of the provider where the AlertPolicyChannel to import is found
71
+ */
72
+ static generateConfigForImport(scope: Construct, importToId: string, importFromId: string, provider?: cdktf.TerraformProvider): any;
73
+ /**
74
+ * Create a new {@link https://registry.terraform.io/providers/newrelic/newrelic/3.75.4/docs/resources/alert_policy_channel newrelic_alert_policy_channel} Resource
75
+ *
76
+ * @param scope The scope in which to define this construct
77
+ * @param id The scoped construct ID. Must be unique amongst siblings in the same scope
78
+ * @param options AlertPolicyChannelConfig
79
+ */
80
+ constructor(scope: Construct, id: string, config: AlertPolicyChannelConfig);
81
+ private _accountId?;
82
+ get accountId(): number;
83
+ set accountId(value: number);
84
+ resetAccountId(): void;
85
+ get accountIdInput(): number;
86
+ private _channelIds?;
87
+ get channelIds(): number[];
88
+ set channelIds(value: number[]);
89
+ get channelIdsInput(): number[];
90
+ private _id?;
91
+ get id(): string;
92
+ set id(value: string);
93
+ resetId(): void;
94
+ get idInput(): string;
95
+ private _policyId?;
96
+ get policyId(): number;
97
+ set policyId(value: number);
98
+ get policyIdInput(): number;
99
+ private _timeouts;
100
+ get timeouts(): AlertPolicyChannelTimeoutsOutputReference;
101
+ putTimeouts(value: AlertPolicyChannelTimeouts): void;
102
+ resetTimeouts(): void;
103
+ get timeoutsInput(): any;
104
+ protected synthesizeAttributes(): {
105
+ [name: string]: any;
106
+ };
107
+ protected synthesizeHclAttributes(): {
108
+ [name: string]: any;
109
+ };
110
+ }
@@ -0,0 +1,260 @@
1
+ // https://registry.terraform.io/providers/newrelic/newrelic/3.75.4/docs/resources/alert_policy_channel
2
+ // generated from terraform resource schema
3
+ import * as cdktf from 'cdktf';
4
+ export function alertPolicyChannelTimeoutsToTerraform(struct) {
5
+ if (!cdktf.canInspect(struct) || cdktf.Tokenization.isResolvable(struct)) {
6
+ return struct;
7
+ }
8
+ if (cdktf.isComplexElement(struct)) {
9
+ throw new Error("A complex element was used as configuration, this is not supported: https://cdk.tf/complex-object-as-configuration");
10
+ }
11
+ return {
12
+ create: cdktf.stringToTerraform(struct.create),
13
+ };
14
+ }
15
+ export function alertPolicyChannelTimeoutsToHclTerraform(struct) {
16
+ if (!cdktf.canInspect(struct) || cdktf.Tokenization.isResolvable(struct)) {
17
+ return struct;
18
+ }
19
+ if (cdktf.isComplexElement(struct)) {
20
+ throw new Error("A complex element was used as configuration, this is not supported: https://cdk.tf/complex-object-as-configuration");
21
+ }
22
+ const attrs = {
23
+ create: {
24
+ value: cdktf.stringToHclTerraform(struct.create),
25
+ isBlock: false,
26
+ type: "simple",
27
+ storageClassType: "string",
28
+ },
29
+ };
30
+ // remove undefined attributes
31
+ return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined));
32
+ }
33
+ export class AlertPolicyChannelTimeoutsOutputReference extends cdktf.ComplexObject {
34
+ isEmptyObject = false;
35
+ resolvableValue;
36
+ /**
37
+ * @param terraformResource The parent resource
38
+ * @param terraformAttribute The attribute on the parent resource this class is referencing
39
+ */
40
+ constructor(terraformResource, terraformAttribute) {
41
+ super(terraformResource, terraformAttribute, false);
42
+ }
43
+ get internalValue() {
44
+ if (this.resolvableValue) {
45
+ return this.resolvableValue;
46
+ }
47
+ let hasAnyValues = this.isEmptyObject;
48
+ const internalValueResult = {};
49
+ if (this._create !== undefined) {
50
+ hasAnyValues = true;
51
+ internalValueResult.create = this._create;
52
+ }
53
+ return hasAnyValues ? internalValueResult : undefined;
54
+ }
55
+ set internalValue(value) {
56
+ if (value === undefined) {
57
+ this.isEmptyObject = false;
58
+ this.resolvableValue = undefined;
59
+ this._create = undefined;
60
+ }
61
+ else if (cdktf.Tokenization.isResolvable(value)) {
62
+ this.isEmptyObject = false;
63
+ this.resolvableValue = value;
64
+ }
65
+ else {
66
+ this.isEmptyObject = Object.keys(value).length === 0;
67
+ this.resolvableValue = undefined;
68
+ this._create = value.create;
69
+ }
70
+ }
71
+ // create - computed: false, optional: true, required: false
72
+ _create;
73
+ get create() {
74
+ return this.getStringAttribute('create');
75
+ }
76
+ set create(value) {
77
+ this._create = value;
78
+ }
79
+ resetCreate() {
80
+ this._create = undefined;
81
+ }
82
+ // Temporarily expose input value. Use with caution.
83
+ get createInput() {
84
+ return this._create;
85
+ }
86
+ }
87
+ /**
88
+ * Represents a {@link https://registry.terraform.io/providers/newrelic/newrelic/3.75.4/docs/resources/alert_policy_channel newrelic_alert_policy_channel}
89
+ */
90
+ export class AlertPolicyChannel extends cdktf.TerraformResource {
91
+ // =================
92
+ // STATIC PROPERTIES
93
+ // =================
94
+ static tfResourceType = "newrelic_alert_policy_channel";
95
+ // ==============
96
+ // STATIC Methods
97
+ // ==============
98
+ /**
99
+ * Generates CDKTF code for importing a AlertPolicyChannel resource upon running "cdktf plan <stack-name>"
100
+ * @param scope The scope in which to define this construct
101
+ * @param importToId The construct id used in the generated config for the AlertPolicyChannel to import
102
+ * @param importFromId The id of the existing AlertPolicyChannel that should be imported. Refer to the {@link https://registry.terraform.io/providers/newrelic/newrelic/3.75.4/docs/resources/alert_policy_channel#import import section} in the documentation of this resource for the id to use
103
+ * @param provider? Optional instance of the provider where the AlertPolicyChannel to import is found
104
+ */
105
+ static generateConfigForImport(scope, importToId, importFromId, provider) {
106
+ return new cdktf.ImportableResource(scope, importToId, { terraformResourceType: "newrelic_alert_policy_channel", importId: importFromId, provider });
107
+ }
108
+ // ===========
109
+ // INITIALIZER
110
+ // ===========
111
+ /**
112
+ * Create a new {@link https://registry.terraform.io/providers/newrelic/newrelic/3.75.4/docs/resources/alert_policy_channel newrelic_alert_policy_channel} Resource
113
+ *
114
+ * @param scope The scope in which to define this construct
115
+ * @param id The scoped construct ID. Must be unique amongst siblings in the same scope
116
+ * @param options AlertPolicyChannelConfig
117
+ */
118
+ constructor(scope, id, config) {
119
+ super(scope, id, {
120
+ terraformResourceType: 'newrelic_alert_policy_channel',
121
+ terraformGeneratorMetadata: {
122
+ providerName: 'newrelic',
123
+ providerVersion: '3.75.4',
124
+ providerVersionConstraint: '3.75.4'
125
+ },
126
+ provider: config.provider,
127
+ dependsOn: config.dependsOn,
128
+ count: config.count,
129
+ lifecycle: config.lifecycle,
130
+ provisioners: config.provisioners,
131
+ connection: config.connection,
132
+ forEach: config.forEach
133
+ });
134
+ this._accountId = config.accountId;
135
+ this._channelIds = config.channelIds;
136
+ this._id = config.id;
137
+ this._policyId = config.policyId;
138
+ this._timeouts.internalValue = config.timeouts;
139
+ }
140
+ // ==========
141
+ // ATTRIBUTES
142
+ // ==========
143
+ // account_id - computed: true, optional: true, required: false
144
+ _accountId;
145
+ get accountId() {
146
+ return this.getNumberAttribute('account_id');
147
+ }
148
+ set accountId(value) {
149
+ this._accountId = value;
150
+ }
151
+ resetAccountId() {
152
+ this._accountId = undefined;
153
+ }
154
+ // Temporarily expose input value. Use with caution.
155
+ get accountIdInput() {
156
+ return this._accountId;
157
+ }
158
+ // channel_ids - computed: false, optional: false, required: true
159
+ _channelIds;
160
+ get channelIds() {
161
+ return cdktf.Token.asNumberList(cdktf.Fn.tolist(this.getNumberListAttribute('channel_ids')));
162
+ }
163
+ set channelIds(value) {
164
+ this._channelIds = value;
165
+ }
166
+ // Temporarily expose input value. Use with caution.
167
+ get channelIdsInput() {
168
+ return this._channelIds;
169
+ }
170
+ // id - computed: true, optional: true, required: false
171
+ _id;
172
+ get id() {
173
+ return this.getStringAttribute('id');
174
+ }
175
+ set id(value) {
176
+ this._id = value;
177
+ }
178
+ resetId() {
179
+ this._id = undefined;
180
+ }
181
+ // Temporarily expose input value. Use with caution.
182
+ get idInput() {
183
+ return this._id;
184
+ }
185
+ // policy_id - computed: false, optional: false, required: true
186
+ _policyId;
187
+ get policyId() {
188
+ return this.getNumberAttribute('policy_id');
189
+ }
190
+ set policyId(value) {
191
+ this._policyId = value;
192
+ }
193
+ // Temporarily expose input value. Use with caution.
194
+ get policyIdInput() {
195
+ return this._policyId;
196
+ }
197
+ // timeouts - computed: false, optional: true, required: false
198
+ _timeouts = new AlertPolicyChannelTimeoutsOutputReference(this, "timeouts");
199
+ get timeouts() {
200
+ return this._timeouts;
201
+ }
202
+ putTimeouts(value) {
203
+ this._timeouts.internalValue = value;
204
+ }
205
+ resetTimeouts() {
206
+ this._timeouts.internalValue = undefined;
207
+ }
208
+ // Temporarily expose input value. Use with caution.
209
+ get timeoutsInput() {
210
+ return this._timeouts.internalValue;
211
+ }
212
+ // =========
213
+ // SYNTHESIS
214
+ // =========
215
+ synthesizeAttributes() {
216
+ return {
217
+ account_id: cdktf.numberToTerraform(this._accountId),
218
+ channel_ids: cdktf.listMapper(cdktf.numberToTerraform, false)(this._channelIds),
219
+ id: cdktf.stringToTerraform(this._id),
220
+ policy_id: cdktf.numberToTerraform(this._policyId),
221
+ timeouts: alertPolicyChannelTimeoutsToTerraform(this._timeouts.internalValue),
222
+ };
223
+ }
224
+ synthesizeHclAttributes() {
225
+ const attrs = {
226
+ account_id: {
227
+ value: cdktf.numberToHclTerraform(this._accountId),
228
+ isBlock: false,
229
+ type: "simple",
230
+ storageClassType: "number",
231
+ },
232
+ channel_ids: {
233
+ value: cdktf.listMapperHcl(cdktf.numberToHclTerraform, false)(this._channelIds),
234
+ isBlock: false,
235
+ type: "set",
236
+ storageClassType: "numberList",
237
+ },
238
+ id: {
239
+ value: cdktf.stringToHclTerraform(this._id),
240
+ isBlock: false,
241
+ type: "simple",
242
+ storageClassType: "string",
243
+ },
244
+ policy_id: {
245
+ value: cdktf.numberToHclTerraform(this._policyId),
246
+ isBlock: false,
247
+ type: "simple",
248
+ storageClassType: "number",
249
+ },
250
+ timeouts: {
251
+ value: alertPolicyChannelTimeoutsToHclTerraform(this._timeouts.internalValue),
252
+ isBlock: true,
253
+ type: "struct",
254
+ storageClassType: "AlertPolicyChannelTimeouts",
255
+ },
256
+ };
257
+ // remove undefined attributes
258
+ return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined));
259
+ }
260
+ }