]> git.immae.eu Git - github/fretlink/terraform-provider-statuscake.git/blame - website/docs/r/test.html.markdown
Update docs reflecting contact_id deprecation
[github/fretlink/terraform-provider-statuscake.git] / website / docs / r / test.html.markdown
CommitLineData
d3491090 1---
2layout: "statuscake"
3page_title: "StatusCake: statuscake_test"
4sidebar_current: "docs-statuscake-test"
5description: |-
6 The statuscake_test resource allows StatusCake tests to be managed by Terraform.
7---
8
9# statuscake\_test
10
6f91d719 11The test resource allows StatusCake tests to be managed by Terraform.
d3491090 12
13## Example Usage
14
b8e9f053 15```hcl
d3491090 16resource "statuscake_test" "google" {
4efdab41
MS
17 website_name = "google.com"
18 website_url = "www.google.com"
19 test_type = "HTTP"
20 check_rate = 300
21 contact_group = ["12345"]
d3491090 22}
23```
24
25## Argument Reference
26
27The following arguments are supported:
28
29* `website_name` - (Required) This is the name of the test and the website to be monitored.
30* `website_url` - (Required) The URL of the website to be monitored
31* `check_rate` - (Optional) Test check rate in seconds. Defaults to 300
23a4886b 32* `contact_id` - **Deprecated** (Optional) The id of the contact group to be added to the test. Each test can have only one.
4efdab41 33* `contact_group` - (Optional) Set test contact groups, must be array of strings.
4d37ac3f 34* `test_type` - (Required) The type of Test. Either HTTP, TCP, PING, or DNS
d3491090 35* `paused` - (Optional) Whether or not the test is paused. Defaults to false.
36* `timeout` - (Optional) The timeout of the test in seconds.
8165842a 37* `confirmations` - (Optional) The number of confirmation servers to use in order to detect downtime. Defaults to 0.
46abe953 38* `port` - (Optional) The port to use when specifying a TCP test.
c1e00ec2 39* `trigger_rate` - (Optional) The number of minutes to wait before sending an alert. Default is `5`.
41dde1b8
AG
40* `custom_header` - (Optional) Custom HTTP header, must be supplied as JSON.
41* `user_agent` - (Optional) Test with a custom user agent set.
42* `node_locations` - (Optional) Set test node locations, must be array of strings.
43* `ping_url` - (Optional) A URL to ping if a site goes down.
44* `basic_user` - (Optional) A Basic Auth User account to use to login
45* `basic_pass` - (Optional) If BasicUser is set then this should be the password for the BasicUser.
46* `public` - (Optional) Set 1 to enable public reporting, 0 to disable.
47* `logo_image` - (Optional) A URL to a image to use for public reporting.
48* `branding` - (Optional) Set to 0 to use branding (default) or 1 to disable public reporting branding).
49* `website_host` - (Optional) Used internally, when possible please add.
50* `virus` - (Optional) Enable virus checking or not. 1 to enable
51* `find_string` - (Optional) A string that should either be found or not found.
52* `do_not_find` - (Optional) If the above string should be found to trigger a alert. 1 = will trigger if find_string found.
53* `real_browser` - (Optional) Use 1 to TURN OFF real browser testing.
bc2bde6b 54* `test_tags` - (Optional) Set test tags, must be array of strings.
23a4886b 55* `status_codes` - (Optional) Comma Separated List of StatusCodes to Trigger Error on. Defaults are "204, 205, 206, 303, 400, 401, 403, 404, 405, 406, 408, 410, 413, 444, 429, 494, 495, 496, 499, 500, 501, 502, 503, 504, 505, 506, 507, 508, 509, 510, 511, 521, 522, 523, 524, 520, 598, 599".
41dde1b8
AG
56* `use_jar` - (Optional) Set to true to enable the Cookie Jar. Required for some redirects. Default is false.
57* `post_raw` - (Optional) Use to populate the RAW POST data field on the test.
58* `final_endpoint` - (Optional) Use to specify the expected Final URL in the testing process.
59* `follow_redirect` - (Optional) Use to specify whether redirects should be followed, set to true to enable. Default is false.
d3491090 60
61## Attributes Reference
62
63The following attribute is exported:
64
6f91d719 65* `test_id` - A unique identifier for the test.