Skip to content

Commit

Permalink
add missing properties to incident_custom_field resource documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
jedelson-pagerduty authored and imjaroiswebdev committed Nov 15, 2023
1 parent 3cdf794 commit c19de50
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 12 deletions.
27 changes: 20 additions & 7 deletions website/docs/r/incident_custom_field.html.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -14,15 +14,25 @@ An [Incident Custom Field](https://support.pagerduty.com/docs/custom-fields-on-i

```hcl
resource "pagerduty_incident_custom_field" "cs_impact" {
name = "impact"
data_type = "string"
field_type = "single_value"
name = "impact"
display_name = "Customer Impact"
data_type = "string"
field_type = "single_value"
}
resource "pagerduty_incident_custom_field" "sre_environment" {
name = "environment"
data_type = "string"
field_type = "single_value_fixed"
name = "environment"
display_name = "Environment"
data_type = "string"
field_type = "single_value_fixed"
}
resource "pagerduty_incident_custom_field" "false_alarm" {
name = "false_alarm"
display_name = "False Alarm"
data_type = "boolean"
field_type = "single_value"
default_value = "false"
}
```

Expand All @@ -31,8 +41,11 @@ resource "pagerduty_incident_custom_field" "sre_environment" {
The following arguments are supported:

* `name` - (Required) The name of the field.
* `display_name` - (Required) The display name of the field.
* `description` - (Optional) The description of the field.
* `data_type` - (Required) The data type of the field. Must be one of `string`, `integer`, `float`, `boolean`, `datetime`, or `url`.
* `field_type` - (Required) The field type of the field. Must be one of `single_value`, `single_value_fixed`, `multi_value`, or `multi_value_fixed`.
* `field_type` - (Required) The field type of the field. Must be one of `single_value`, `single_value_fixed`, `multi_value`, or `multi_value_fixed`.
* `default_value` - (Optional) The default value to set when new incidents are created. Always specified as a string.

## Attributes Reference

Expand Down
11 changes: 6 additions & 5 deletions website/docs/r/incident_custom_field_option.html.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -15,15 +15,16 @@ i.e. has the `field_type` of `single_value_fixed` or `multi_value_fixed`.

```hcl
resource "pagerduty_incident_custom_field" "sre_environment" {
name = "environment"
data_type = "string"
field_type = "single_value_fixed"
name = "environment"
display_name = "Environment"
data_type = "string"
field_type = "single_value_fixed"
}
resource "pagerduty_incident_custom_field_option" "dev_environment" {
field = pagerduty_incident_custom_field.sre_environment.id
field = pagerduty_incident_custom_field.sre_environment.id
data_type = "string"
value = "dev"
value = "dev"
}
resource "pagerduty_incident_custom_field_option" "stage_environment" {
Expand Down

0 comments on commit c19de50

Please sign in to comment.