@checkly/pulumi 0.0.1-alpha.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 (73) hide show
  1. package/Pulumi.yaml +0 -0
  2. package/README.md +4 -0
  3. package/alertChannel.ts +321 -0
  4. package/bin/LICENSE +21 -0
  5. package/bin/README.md +90 -0
  6. package/bin/alertChannel.d.ts +266 -0
  7. package/bin/alertChannel.js +204 -0
  8. package/bin/alertChannel.js.map +1 -0
  9. package/bin/check.d.ts +328 -0
  10. package/bin/check.js +110 -0
  11. package/bin/check.js.map +1 -0
  12. package/bin/checkGroup.d.ts +238 -0
  13. package/bin/checkGroup.js +93 -0
  14. package/bin/checkGroup.js.map +1 -0
  15. package/bin/config/index.d.ts +1 -0
  16. package/bin/config/index.js +21 -0
  17. package/bin/config/index.js.map +1 -0
  18. package/bin/config/vars.d.ts +3 -0
  19. package/bin/config/vars.js +25 -0
  20. package/bin/config/vars.js.map +1 -0
  21. package/bin/dashboard.d.ts +66 -0
  22. package/bin/dashboard.js +93 -0
  23. package/bin/dashboard.js.map +1 -0
  24. package/bin/index.d.ts +12 -0
  25. package/bin/index.js +89 -0
  26. package/bin/index.js.map +1 -0
  27. package/bin/maintenanceWindow.d.ts +157 -0
  28. package/bin/maintenanceWindow.js +115 -0
  29. package/bin/maintenanceWindow.js.map +1 -0
  30. package/bin/package.json +28 -0
  31. package/bin/package.json.bak +28 -0
  32. package/bin/provider.d.ts +33 -0
  33. package/bin/provider.js +52 -0
  34. package/bin/provider.js.map +1 -0
  35. package/bin/snippet.d.ts +60 -0
  36. package/bin/snippet.js +56 -0
  37. package/bin/snippet.js.map +1 -0
  38. package/bin/triggerCheck.d.ts +71 -0
  39. package/bin/triggerCheck.js +75 -0
  40. package/bin/triggerCheck.js.map +1 -0
  41. package/bin/triggerCheckGroup.d.ts +71 -0
  42. package/bin/triggerCheckGroup.js +75 -0
  43. package/bin/triggerCheckGroup.js.map +1 -0
  44. package/bin/types/index.d.ts +3 -0
  45. package/bin/types/index.js +11 -0
  46. package/bin/types/index.js.map +1 -0
  47. package/bin/types/input.d.ts +330 -0
  48. package/bin/types/input.js +14 -0
  49. package/bin/types/input.js.map +1 -0
  50. package/bin/types/output.d.ts +329 -0
  51. package/bin/types/output.js +14 -0
  52. package/bin/types/output.js.map +1 -0
  53. package/bin/utilities.d.ts +4 -0
  54. package/bin/utilities.js +52 -0
  55. package/bin/utilities.js.map +1 -0
  56. package/bin/yarn.lock +743 -0
  57. package/check.ts +416 -0
  58. package/checkGroup.ts +308 -0
  59. package/config/index.ts +5 -0
  60. package/config/vars.ts +33 -0
  61. package/dashboard.ts +143 -0
  62. package/index.ts +81 -0
  63. package/maintenanceWindow.ts +219 -0
  64. package/package.json +28 -0
  65. package/provider.ts +64 -0
  66. package/snippet.ts +100 -0
  67. package/triggerCheck.ts +113 -0
  68. package/triggerCheckGroup.ts +113 -0
  69. package/tsconfig.json +33 -0
  70. package/types/index.ts +11 -0
  71. package/types/input.ts +352 -0
  72. package/types/output.ts +353 -0
  73. package/utilities.ts +49 -0
package/Pulumi.yaml ADDED
File without changes
package/README.md ADDED
@@ -0,0 +1,4 @@
1
+ > This provider is a derived work of the [Terraform Provider](https://github.com/checkly/terraform-provider-checkly)
2
+ > distributed under [MPL 2.0](https://www.mozilla.org/en-US/MPL/2.0/). If you encounter a bug or missing feature,
3
+ > first check the [`pulumi/pulumi-checkly` repo](https://github.com/pulumi/pulumi-checkly/issues); however, if that doesn't turn up anything,
4
+ > please consult the source [`checkly/terraform-provider-checkly` repo](https://github.com/checkly/terraform-provider-checkly/issues).
@@ -0,0 +1,321 @@
1
+ // *** WARNING: this file was generated by the Pulumi Terraform Bridge (tfgen) Tool. ***
2
+ // *** Do not edit by hand unless you're certain you know what you are doing! ***
3
+
4
+ import * as pulumi from "@pulumi/pulumi";
5
+ import { input as inputs, output as outputs } from "./types";
6
+ import * as utilities from "./utilities";
7
+
8
+ /**
9
+ * ## # checkly.AlertChannel
10
+ *
11
+ * The `checkly.AlertChannel` resource allows users to manage Checkly alert channels.
12
+ *
13
+ * Checkly's Alert Channels feature allows you to define global alerting channels for the checks in your account:
14
+ *
15
+ * ## Example Usage
16
+ *
17
+ * *An Email alert channel*
18
+ * ```typescript
19
+ * import * as pulumi from "@pulumi/pulumi";
20
+ * import * as checkly from "@pulumi/checkly";
21
+ *
22
+ * const emailAc = new checkly.AlertChannel("email_ac", {
23
+ * email: {
24
+ * address: "john@example.com",
25
+ * },
26
+ * sendDegraded: true,
27
+ * sendFailure: false,
28
+ * sendRecovery: true,
29
+ * sslExpiry: true,
30
+ * sslExpiryThreshold: 22,
31
+ * });
32
+ * ```
33
+ *
34
+ * *A SMS alert channel*
35
+ * ```typescript
36
+ * import * as pulumi from "@pulumi/pulumi";
37
+ * import * as checkly from "@pulumi/checkly";
38
+ *
39
+ * const smsAc = new checkly.AlertChannel("sms_ac", {
40
+ * sendFailure: true,
41
+ * sendRecovery: true,
42
+ * sms: {
43
+ * name: "john",
44
+ * number: "0123456789",
45
+ * },
46
+ * });
47
+ * ```
48
+ *
49
+ * *A Slack alert channel*
50
+ * ```typescript
51
+ * import * as pulumi from "@pulumi/pulumi";
52
+ * import * as checkly from "@pulumi/checkly";
53
+ *
54
+ * const slackAc = new checkly.AlertChannel("slack_ac", {
55
+ * slack: {
56
+ * channel: "#checkly-notifications",
57
+ * url: "https://slack.com/webhook",
58
+ * },
59
+ * });
60
+ * ```
61
+ *
62
+ * *An Opsgenie alert channel*
63
+ * ```typescript
64
+ * import * as pulumi from "@pulumi/pulumi";
65
+ * import * as checkly from "@pulumi/checkly";
66
+ *
67
+ * const opsgenieAc = new checkly.AlertChannel("opsgenie_ac", {
68
+ * opsgenie: {
69
+ * apiKey: "fookey",
70
+ * name: "opsalerts",
71
+ * priority: "foopriority",
72
+ * region: "fooregion",
73
+ * },
74
+ * });
75
+ * ```
76
+ *
77
+ * *An Pagerduty alert channel*
78
+ * ```typescript
79
+ * import * as pulumi from "@pulumi/pulumi";
80
+ * import * as checkly from "@pulumi/checkly";
81
+ *
82
+ * const pagerdutyAc = new checkly.AlertChannel("pagerduty_ac", {
83
+ * pagerduty: {
84
+ * account: "checkly",
85
+ * serviceKey: "key1",
86
+ * serviceName: "pdalert",
87
+ * },
88
+ * });
89
+ * ```
90
+ *
91
+ * *An Webhook alert channel*
92
+ * ```typescript
93
+ * import * as pulumi from "@pulumi/pulumi";
94
+ * import * as checkly from "@pulumi/checkly";
95
+ *
96
+ * const webhookAc = new checkly.AlertChannel("webhook_ac", {
97
+ * webhook: {
98
+ * method: "get",
99
+ * name: "foo",
100
+ * template: "footemplate",
101
+ * url: "http://example.com/foo",
102
+ * webhookSecret: "foosecret",
103
+ * },
104
+ * });
105
+ * ```
106
+ *
107
+ * *Connecting the alert channel to a check
108
+ * ```typescript
109
+ * import * as pulumi from "@pulumi/pulumi";
110
+ * import * as checkly from "@pulumi/checkly";
111
+ *
112
+ * const example_check = new checkly.Check("example-check", {alertChannelSubscriptions: [
113
+ * {
114
+ * channelId: checkly_alert_channel.email_ac.id,
115
+ * activated: true,
116
+ * },
117
+ * {
118
+ * channelId: checkly_alert_channel.sms_ac.id,
119
+ * activated: true,
120
+ * },
121
+ * ]});
122
+ * ```
123
+ *
124
+ * *Connecting the alert channel to a check group
125
+ * ```typescript
126
+ * import * as pulumi from "@pulumi/pulumi";
127
+ * import * as checkly from "@pulumi/checkly";
128
+ *
129
+ * const test_group1 = new checkly.CheckGroup("test-group1", {alertChannelSubscriptions: [
130
+ * {
131
+ * channelId: checkly_alert_channel.email_ac.id,
132
+ * activated: true,
133
+ * },
134
+ * {
135
+ * channelId: checkly_alert_channel.sms_ac.id,
136
+ * activated: true,
137
+ * },
138
+ * ]});
139
+ * ```
140
+ */
141
+ export class AlertChannel extends pulumi.CustomResource {
142
+ /**
143
+ * Get an existing AlertChannel resource's state with the given name, ID, and optional extra
144
+ * properties used to qualify the lookup.
145
+ *
146
+ * @param name The _unique_ name of the resulting resource.
147
+ * @param id The _unique_ provider ID of the resource to lookup.
148
+ * @param state Any extra arguments used during the lookup.
149
+ * @param opts Optional settings to control the behavior of the CustomResource.
150
+ */
151
+ public static get(name: string, id: pulumi.Input<pulumi.ID>, state?: AlertChannelState, opts?: pulumi.CustomResourceOptions): AlertChannel {
152
+ return new AlertChannel(name, <any>state, { ...opts, id: id });
153
+ }
154
+
155
+ /** @internal */
156
+ public static readonly __pulumiType = 'checkly:index/alertChannel:AlertChannel';
157
+
158
+ /**
159
+ * Returns true if the given object is an instance of AlertChannel. This is designed to work even
160
+ * when multiple copies of the Pulumi SDK have been loaded into the same process.
161
+ */
162
+ public static isInstance(obj: any): obj is AlertChannel {
163
+ if (obj === undefined || obj === null) {
164
+ return false;
165
+ }
166
+ return obj['__pulumiType'] === AlertChannel.__pulumiType;
167
+ }
168
+
169
+ /**
170
+ * :
171
+ */
172
+ public readonly email!: pulumi.Output<outputs.AlertChannelEmail | undefined>;
173
+ public readonly opsgenie!: pulumi.Output<outputs.AlertChannelOpsgenie | undefined>;
174
+ public readonly pagerduty!: pulumi.Output<outputs.AlertChannelPagerduty | undefined>;
175
+ /**
176
+ * . Possible values: `true` | `false`.
177
+ */
178
+ public readonly sendDegraded!: pulumi.Output<boolean | undefined>;
179
+ /**
180
+ * . Possible values: `true` | `false`.
181
+ */
182
+ public readonly sendFailure!: pulumi.Output<boolean | undefined>;
183
+ /**
184
+ * . Possible values: `true` | `false`.
185
+ */
186
+ public readonly sendRecovery!: pulumi.Output<boolean | undefined>;
187
+ public readonly slack!: pulumi.Output<outputs.AlertChannelSlack | undefined>;
188
+ /**
189
+ * :
190
+ */
191
+ public readonly sms!: pulumi.Output<outputs.AlertChannelSms | undefined>;
192
+ /**
193
+ * . Possible values: `true` | `false`.
194
+ */
195
+ public readonly sslExpiry!: pulumi.Output<boolean | undefined>;
196
+ /**
197
+ * . Possible values between 1 and 30. Default is `30`.
198
+ */
199
+ public readonly sslExpiryThreshold!: pulumi.Output<number | undefined>;
200
+ public readonly webhook!: pulumi.Output<outputs.AlertChannelWebhook | undefined>;
201
+
202
+ /**
203
+ * Create a AlertChannel resource with the given unique name, arguments, and options.
204
+ *
205
+ * @param name The _unique_ name of the resource.
206
+ * @param args The arguments to use to populate this resource's properties.
207
+ * @param opts A bag of options that control this resource's behavior.
208
+ */
209
+ constructor(name: string, args?: AlertChannelArgs, opts?: pulumi.CustomResourceOptions)
210
+ constructor(name: string, argsOrState?: AlertChannelArgs | AlertChannelState, opts?: pulumi.CustomResourceOptions) {
211
+ let resourceInputs: pulumi.Inputs = {};
212
+ opts = opts || {};
213
+ if (opts.id) {
214
+ const state = argsOrState as AlertChannelState | undefined;
215
+ resourceInputs["email"] = state ? state.email : undefined;
216
+ resourceInputs["opsgenie"] = state ? state.opsgenie : undefined;
217
+ resourceInputs["pagerduty"] = state ? state.pagerduty : undefined;
218
+ resourceInputs["sendDegraded"] = state ? state.sendDegraded : undefined;
219
+ resourceInputs["sendFailure"] = state ? state.sendFailure : undefined;
220
+ resourceInputs["sendRecovery"] = state ? state.sendRecovery : undefined;
221
+ resourceInputs["slack"] = state ? state.slack : undefined;
222
+ resourceInputs["sms"] = state ? state.sms : undefined;
223
+ resourceInputs["sslExpiry"] = state ? state.sslExpiry : undefined;
224
+ resourceInputs["sslExpiryThreshold"] = state ? state.sslExpiryThreshold : undefined;
225
+ resourceInputs["webhook"] = state ? state.webhook : undefined;
226
+ } else {
227
+ const args = argsOrState as AlertChannelArgs | undefined;
228
+ resourceInputs["email"] = args ? args.email : undefined;
229
+ resourceInputs["opsgenie"] = args ? args.opsgenie : undefined;
230
+ resourceInputs["pagerduty"] = args ? args.pagerduty : undefined;
231
+ resourceInputs["sendDegraded"] = args ? args.sendDegraded : undefined;
232
+ resourceInputs["sendFailure"] = args ? args.sendFailure : undefined;
233
+ resourceInputs["sendRecovery"] = args ? args.sendRecovery : undefined;
234
+ resourceInputs["slack"] = args ? args.slack : undefined;
235
+ resourceInputs["sms"] = args ? args.sms : undefined;
236
+ resourceInputs["sslExpiry"] = args ? args.sslExpiry : undefined;
237
+ resourceInputs["sslExpiryThreshold"] = args ? args.sslExpiryThreshold : undefined;
238
+ resourceInputs["webhook"] = args ? args.webhook : undefined;
239
+ }
240
+ if (!opts.version) {
241
+ opts = pulumi.mergeOptions(opts, { version: utilities.getVersion()});
242
+ }
243
+ super(AlertChannel.__pulumiType, name, resourceInputs, opts);
244
+ }
245
+ }
246
+
247
+ /**
248
+ * Input properties used for looking up and filtering AlertChannel resources.
249
+ */
250
+ export interface AlertChannelState {
251
+ /**
252
+ * :
253
+ */
254
+ email?: pulumi.Input<inputs.AlertChannelEmail>;
255
+ opsgenie?: pulumi.Input<inputs.AlertChannelOpsgenie>;
256
+ pagerduty?: pulumi.Input<inputs.AlertChannelPagerduty>;
257
+ /**
258
+ * . Possible values: `true` | `false`.
259
+ */
260
+ sendDegraded?: pulumi.Input<boolean>;
261
+ /**
262
+ * . Possible values: `true` | `false`.
263
+ */
264
+ sendFailure?: pulumi.Input<boolean>;
265
+ /**
266
+ * . Possible values: `true` | `false`.
267
+ */
268
+ sendRecovery?: pulumi.Input<boolean>;
269
+ slack?: pulumi.Input<inputs.AlertChannelSlack>;
270
+ /**
271
+ * :
272
+ */
273
+ sms?: pulumi.Input<inputs.AlertChannelSms>;
274
+ /**
275
+ * . Possible values: `true` | `false`.
276
+ */
277
+ sslExpiry?: pulumi.Input<boolean>;
278
+ /**
279
+ * . Possible values between 1 and 30. Default is `30`.
280
+ */
281
+ sslExpiryThreshold?: pulumi.Input<number>;
282
+ webhook?: pulumi.Input<inputs.AlertChannelWebhook>;
283
+ }
284
+
285
+ /**
286
+ * The set of arguments for constructing a AlertChannel resource.
287
+ */
288
+ export interface AlertChannelArgs {
289
+ /**
290
+ * :
291
+ */
292
+ email?: pulumi.Input<inputs.AlertChannelEmail>;
293
+ opsgenie?: pulumi.Input<inputs.AlertChannelOpsgenie>;
294
+ pagerduty?: pulumi.Input<inputs.AlertChannelPagerduty>;
295
+ /**
296
+ * . Possible values: `true` | `false`.
297
+ */
298
+ sendDegraded?: pulumi.Input<boolean>;
299
+ /**
300
+ * . Possible values: `true` | `false`.
301
+ */
302
+ sendFailure?: pulumi.Input<boolean>;
303
+ /**
304
+ * . Possible values: `true` | `false`.
305
+ */
306
+ sendRecovery?: pulumi.Input<boolean>;
307
+ slack?: pulumi.Input<inputs.AlertChannelSlack>;
308
+ /**
309
+ * :
310
+ */
311
+ sms?: pulumi.Input<inputs.AlertChannelSms>;
312
+ /**
313
+ * . Possible values: `true` | `false`.
314
+ */
315
+ sslExpiry?: pulumi.Input<boolean>;
316
+ /**
317
+ * . Possible values between 1 and 30. Default is `30`.
318
+ */
319
+ sslExpiryThreshold?: pulumi.Input<number>;
320
+ webhook?: pulumi.Input<inputs.AlertChannelWebhook>;
321
+ }
package/bin/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2022 Checkly Inc.
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/bin/README.md ADDED
@@ -0,0 +1,90 @@
1
+ **🚨 This project is still in very early stages and is not stable, _use at your own risk_! 🚨**
2
+
3
+ <p align="center">
4
+ <img width="400px" src="./assets/pulumi.svg" alt="Pulumi" />
5
+ </p>
6
+
7
+ <p>
8
+ <img height="128" src="./assets/checkly.svg" align="right" />
9
+ <h1>Checkly Pulumi Provider</h1>
10
+ </p>
11
+
12
+ > 🟪 Pulumi provider for the [Checkly](https://checklyhq.com) Delightful Active Monitoring
13
+
14
+ <br>
15
+
16
+ ## 🪛 Installing
17
+
18
+ This package is available for several languages/platforms:
19
+
20
+ ### Node.js (JavaScript/TypeScript)
21
+
22
+ To use from JavaScript or TypeScript in Node.js, install using either `npm`:
23
+
24
+ ```bash
25
+ npm install @pulumi/checkly
26
+ ```
27
+
28
+ or `yarn`:
29
+
30
+ ```bash
31
+ yarn add @pulumi/checkly
32
+ ```
33
+
34
+ ### Python
35
+
36
+ To use from Python, install using `pip`:
37
+
38
+ ```bash
39
+ pip install pulumi_checkly
40
+ ```
41
+
42
+ ### Go
43
+
44
+ To use from Go, use `go get` to grab the latest version of the library:
45
+
46
+ ```bash
47
+ go get github.com/pulumi/pulumi-checkly/sdk/go/...
48
+ ```
49
+
50
+ ### .NET
51
+
52
+ To use from .NET, install using `dotnet add package`:
53
+
54
+ ```bash
55
+ dotnet add package Pulumi.Checkly
56
+ ```
57
+
58
+ <br>
59
+
60
+ ## ⚙️ Configuration
61
+
62
+ The following configuration points are available for the `foo` provider:
63
+
64
+ - `checkly:apiKey` (environment: `CHECKLY_API_KEY`) - the Checkly API Key.
65
+ - `checkly:accountId` (environment: `CHECKLY_ACCOUNT_ID`) - the Checkly account ID.
66
+
67
+ <br>
68
+
69
+ ## 📖 Reference
70
+
71
+ For detailed reference documentation, please visit [the Pulumi registry](https://www.pulumi.com/registry/packages/checkly/api-docs/).
72
+
73
+ <br>
74
+
75
+ ## 📄 License
76
+
77
+ [MIT](https://github.com/checkly/pulumi-checkly/blob/main/LICENSE)
78
+
79
+ <br>
80
+
81
+
82
+ <p align="center">
83
+ <a href="https://checklyhq.com?utm_source=github&utm_medium=sponsor-logo-github&utm_campaign=headless-recorder" target="_blank">
84
+ <img width="100px" src="https://www.checklyhq.com/images/text_racoon_logo.svg" alt="Checkly" />
85
+ </a>
86
+ <br />
87
+ <i><sub>Delightful Active Monitoring for Developers</sub></i>
88
+ <br>
89
+ <b><sub>From Checkly with ♥️</sub></b>
90
+ <p>
@@ -0,0 +1,266 @@
1
+ import * as pulumi from "@pulumi/pulumi";
2
+ import { input as inputs, output as outputs } from "./types";
3
+ /**
4
+ * ## # checkly.AlertChannel
5
+ *
6
+ * The `checkly.AlertChannel` resource allows users to manage Checkly alert channels.
7
+ *
8
+ * Checkly's Alert Channels feature allows you to define global alerting channels for the checks in your account:
9
+ *
10
+ * ## Example Usage
11
+ *
12
+ * *An Email alert channel*
13
+ * ```typescript
14
+ * import * as pulumi from "@pulumi/pulumi";
15
+ * import * as checkly from "@pulumi/checkly";
16
+ *
17
+ * const emailAc = new checkly.AlertChannel("email_ac", {
18
+ * email: {
19
+ * address: "john@example.com",
20
+ * },
21
+ * sendDegraded: true,
22
+ * sendFailure: false,
23
+ * sendRecovery: true,
24
+ * sslExpiry: true,
25
+ * sslExpiryThreshold: 22,
26
+ * });
27
+ * ```
28
+ *
29
+ * *A SMS alert channel*
30
+ * ```typescript
31
+ * import * as pulumi from "@pulumi/pulumi";
32
+ * import * as checkly from "@pulumi/checkly";
33
+ *
34
+ * const smsAc = new checkly.AlertChannel("sms_ac", {
35
+ * sendFailure: true,
36
+ * sendRecovery: true,
37
+ * sms: {
38
+ * name: "john",
39
+ * number: "0123456789",
40
+ * },
41
+ * });
42
+ * ```
43
+ *
44
+ * *A Slack alert channel*
45
+ * ```typescript
46
+ * import * as pulumi from "@pulumi/pulumi";
47
+ * import * as checkly from "@pulumi/checkly";
48
+ *
49
+ * const slackAc = new checkly.AlertChannel("slack_ac", {
50
+ * slack: {
51
+ * channel: "#checkly-notifications",
52
+ * url: "https://slack.com/webhook",
53
+ * },
54
+ * });
55
+ * ```
56
+ *
57
+ * *An Opsgenie alert channel*
58
+ * ```typescript
59
+ * import * as pulumi from "@pulumi/pulumi";
60
+ * import * as checkly from "@pulumi/checkly";
61
+ *
62
+ * const opsgenieAc = new checkly.AlertChannel("opsgenie_ac", {
63
+ * opsgenie: {
64
+ * apiKey: "fookey",
65
+ * name: "opsalerts",
66
+ * priority: "foopriority",
67
+ * region: "fooregion",
68
+ * },
69
+ * });
70
+ * ```
71
+ *
72
+ * *An Pagerduty alert channel*
73
+ * ```typescript
74
+ * import * as pulumi from "@pulumi/pulumi";
75
+ * import * as checkly from "@pulumi/checkly";
76
+ *
77
+ * const pagerdutyAc = new checkly.AlertChannel("pagerduty_ac", {
78
+ * pagerduty: {
79
+ * account: "checkly",
80
+ * serviceKey: "key1",
81
+ * serviceName: "pdalert",
82
+ * },
83
+ * });
84
+ * ```
85
+ *
86
+ * *An Webhook alert channel*
87
+ * ```typescript
88
+ * import * as pulumi from "@pulumi/pulumi";
89
+ * import * as checkly from "@pulumi/checkly";
90
+ *
91
+ * const webhookAc = new checkly.AlertChannel("webhook_ac", {
92
+ * webhook: {
93
+ * method: "get",
94
+ * name: "foo",
95
+ * template: "footemplate",
96
+ * url: "http://example.com/foo",
97
+ * webhookSecret: "foosecret",
98
+ * },
99
+ * });
100
+ * ```
101
+ *
102
+ * *Connecting the alert channel to a check
103
+ * ```typescript
104
+ * import * as pulumi from "@pulumi/pulumi";
105
+ * import * as checkly from "@pulumi/checkly";
106
+ *
107
+ * const example_check = new checkly.Check("example-check", {alertChannelSubscriptions: [
108
+ * {
109
+ * channelId: checkly_alert_channel.email_ac.id,
110
+ * activated: true,
111
+ * },
112
+ * {
113
+ * channelId: checkly_alert_channel.sms_ac.id,
114
+ * activated: true,
115
+ * },
116
+ * ]});
117
+ * ```
118
+ *
119
+ * *Connecting the alert channel to a check group
120
+ * ```typescript
121
+ * import * as pulumi from "@pulumi/pulumi";
122
+ * import * as checkly from "@pulumi/checkly";
123
+ *
124
+ * const test_group1 = new checkly.CheckGroup("test-group1", {alertChannelSubscriptions: [
125
+ * {
126
+ * channelId: checkly_alert_channel.email_ac.id,
127
+ * activated: true,
128
+ * },
129
+ * {
130
+ * channelId: checkly_alert_channel.sms_ac.id,
131
+ * activated: true,
132
+ * },
133
+ * ]});
134
+ * ```
135
+ */
136
+ export declare class AlertChannel extends pulumi.CustomResource {
137
+ /**
138
+ * Get an existing AlertChannel resource's state with the given name, ID, and optional extra
139
+ * properties used to qualify the lookup.
140
+ *
141
+ * @param name The _unique_ name of the resulting resource.
142
+ * @param id The _unique_ provider ID of the resource to lookup.
143
+ * @param state Any extra arguments used during the lookup.
144
+ * @param opts Optional settings to control the behavior of the CustomResource.
145
+ */
146
+ static get(name: string, id: pulumi.Input<pulumi.ID>, state?: AlertChannelState, opts?: pulumi.CustomResourceOptions): AlertChannel;
147
+ /**
148
+ * Returns true if the given object is an instance of AlertChannel. This is designed to work even
149
+ * when multiple copies of the Pulumi SDK have been loaded into the same process.
150
+ */
151
+ static isInstance(obj: any): obj is AlertChannel;
152
+ /**
153
+ * :
154
+ */
155
+ readonly email: pulumi.Output<outputs.AlertChannelEmail | undefined>;
156
+ readonly opsgenie: pulumi.Output<outputs.AlertChannelOpsgenie | undefined>;
157
+ readonly pagerduty: pulumi.Output<outputs.AlertChannelPagerduty | undefined>;
158
+ /**
159
+ * . Possible values: `true` | `false`.
160
+ */
161
+ readonly sendDegraded: pulumi.Output<boolean | undefined>;
162
+ /**
163
+ * . Possible values: `true` | `false`.
164
+ */
165
+ readonly sendFailure: pulumi.Output<boolean | undefined>;
166
+ /**
167
+ * . Possible values: `true` | `false`.
168
+ */
169
+ readonly sendRecovery: pulumi.Output<boolean | undefined>;
170
+ readonly slack: pulumi.Output<outputs.AlertChannelSlack | undefined>;
171
+ /**
172
+ * :
173
+ */
174
+ readonly sms: pulumi.Output<outputs.AlertChannelSms | undefined>;
175
+ /**
176
+ * . Possible values: `true` | `false`.
177
+ */
178
+ readonly sslExpiry: pulumi.Output<boolean | undefined>;
179
+ /**
180
+ * . Possible values between 1 and 30. Default is `30`.
181
+ */
182
+ readonly sslExpiryThreshold: pulumi.Output<number | undefined>;
183
+ readonly webhook: pulumi.Output<outputs.AlertChannelWebhook | undefined>;
184
+ /**
185
+ * Create a AlertChannel resource with the given unique name, arguments, and options.
186
+ *
187
+ * @param name The _unique_ name of the resource.
188
+ * @param args The arguments to use to populate this resource's properties.
189
+ * @param opts A bag of options that control this resource's behavior.
190
+ */
191
+ constructor(name: string, args?: AlertChannelArgs, opts?: pulumi.CustomResourceOptions);
192
+ }
193
+ /**
194
+ * Input properties used for looking up and filtering AlertChannel resources.
195
+ */
196
+ export interface AlertChannelState {
197
+ /**
198
+ * :
199
+ */
200
+ email?: pulumi.Input<inputs.AlertChannelEmail>;
201
+ opsgenie?: pulumi.Input<inputs.AlertChannelOpsgenie>;
202
+ pagerduty?: pulumi.Input<inputs.AlertChannelPagerduty>;
203
+ /**
204
+ * . Possible values: `true` | `false`.
205
+ */
206
+ sendDegraded?: pulumi.Input<boolean>;
207
+ /**
208
+ * . Possible values: `true` | `false`.
209
+ */
210
+ sendFailure?: pulumi.Input<boolean>;
211
+ /**
212
+ * . Possible values: `true` | `false`.
213
+ */
214
+ sendRecovery?: pulumi.Input<boolean>;
215
+ slack?: pulumi.Input<inputs.AlertChannelSlack>;
216
+ /**
217
+ * :
218
+ */
219
+ sms?: pulumi.Input<inputs.AlertChannelSms>;
220
+ /**
221
+ * . Possible values: `true` | `false`.
222
+ */
223
+ sslExpiry?: pulumi.Input<boolean>;
224
+ /**
225
+ * . Possible values between 1 and 30. Default is `30`.
226
+ */
227
+ sslExpiryThreshold?: pulumi.Input<number>;
228
+ webhook?: pulumi.Input<inputs.AlertChannelWebhook>;
229
+ }
230
+ /**
231
+ * The set of arguments for constructing a AlertChannel resource.
232
+ */
233
+ export interface AlertChannelArgs {
234
+ /**
235
+ * :
236
+ */
237
+ email?: pulumi.Input<inputs.AlertChannelEmail>;
238
+ opsgenie?: pulumi.Input<inputs.AlertChannelOpsgenie>;
239
+ pagerduty?: pulumi.Input<inputs.AlertChannelPagerduty>;
240
+ /**
241
+ * . Possible values: `true` | `false`.
242
+ */
243
+ sendDegraded?: pulumi.Input<boolean>;
244
+ /**
245
+ * . Possible values: `true` | `false`.
246
+ */
247
+ sendFailure?: pulumi.Input<boolean>;
248
+ /**
249
+ * . Possible values: `true` | `false`.
250
+ */
251
+ sendRecovery?: pulumi.Input<boolean>;
252
+ slack?: pulumi.Input<inputs.AlertChannelSlack>;
253
+ /**
254
+ * :
255
+ */
256
+ sms?: pulumi.Input<inputs.AlertChannelSms>;
257
+ /**
258
+ * . Possible values: `true` | `false`.
259
+ */
260
+ sslExpiry?: pulumi.Input<boolean>;
261
+ /**
262
+ * . Possible values between 1 and 30. Default is `30`.
263
+ */
264
+ sslExpiryThreshold?: pulumi.Input<number>;
265
+ webhook?: pulumi.Input<inputs.AlertChannelWebhook>;
266
+ }