pulumi-newrelic 5.21.0a1710157101__py3-none-any.whl → 5.39.0a1736849617__py3-none-any.whl
Sign up to get free protection for your applications and to get access to all the features.
- pulumi_newrelic/__init__.py +9 -0
- pulumi_newrelic/_inputs.py +7153 -461
- pulumi_newrelic/_utilities.py +41 -5
- pulumi_newrelic/account_management.py +11 -6
- pulumi_newrelic/alert_channel.py +116 -127
- pulumi_newrelic/alert_condition.py +116 -129
- pulumi_newrelic/alert_muting_rule.py +128 -76
- pulumi_newrelic/alert_policy.py +78 -75
- pulumi_newrelic/alert_policy_channel.py +77 -68
- pulumi_newrelic/api_access_key.py +45 -28
- pulumi_newrelic/browser_application.py +77 -78
- pulumi_newrelic/cloud/_inputs.py +2527 -1082
- pulumi_newrelic/cloud/aws_govcloud_integrations.py +133 -128
- pulumi_newrelic/cloud/aws_govcloud_link_account.py +23 -20
- pulumi_newrelic/cloud/aws_integrations.py +298 -1326
- pulumi_newrelic/cloud/aws_link_account.py +23 -20
- pulumi_newrelic/cloud/azure_integrations.py +521 -483
- pulumi_newrelic/cloud/azure_link_account.py +34 -31
- pulumi_newrelic/cloud/gcp_integrations.py +341 -322
- pulumi_newrelic/cloud/gcp_link_account.py +23 -20
- pulumi_newrelic/cloud/outputs.py +327 -1072
- pulumi_newrelic/config/__init__.pyi +6 -1
- pulumi_newrelic/config/vars.py +7 -2
- pulumi_newrelic/data_partition_rule.py +19 -18
- pulumi_newrelic/entity_tags.py +32 -31
- pulumi_newrelic/events_to_metrics_rule.py +23 -20
- pulumi_newrelic/get_account.py +24 -16
- pulumi_newrelic/get_alert_channel.py +26 -13
- pulumi_newrelic/get_alert_policy.py +35 -12
- pulumi_newrelic/get_application.py +39 -31
- pulumi_newrelic/get_authentication_domain.py +17 -13
- pulumi_newrelic/get_cloud_account.py +26 -18
- pulumi_newrelic/get_entity.py +90 -147
- pulumi_newrelic/get_group.py +58 -13
- pulumi_newrelic/get_key_transaction.py +109 -34
- pulumi_newrelic/get_notification_destination.py +64 -14
- pulumi_newrelic/get_obfuscation_expression.py +36 -28
- pulumi_newrelic/get_service_level_alert_helper.py +135 -117
- pulumi_newrelic/get_test_grok_pattern.py +29 -18
- pulumi_newrelic/get_user.py +17 -9
- pulumi_newrelic/group.py +5 -146
- pulumi_newrelic/infra_alert_condition.py +160 -167
- pulumi_newrelic/insights/_inputs.py +43 -0
- pulumi_newrelic/insights/event.py +48 -47
- pulumi_newrelic/insights/outputs.py +5 -0
- pulumi_newrelic/key_transaction.py +464 -0
- pulumi_newrelic/log_parsing_rule.py +25 -24
- pulumi_newrelic/monitor_downtime.py +211 -225
- pulumi_newrelic/notification_channel.py +381 -366
- pulumi_newrelic/notification_destination.py +192 -54
- pulumi_newrelic/nrql_alert_condition.py +345 -262
- pulumi_newrelic/nrql_drop_rule.py +31 -30
- pulumi_newrelic/obfuscation_expression.py +23 -20
- pulumi_newrelic/obfuscation_rule.py +38 -33
- pulumi_newrelic/one_dashboard.py +29 -24
- pulumi_newrelic/one_dashboard_json.py +19 -14
- pulumi_newrelic/one_dashboard_raw.py +110 -105
- pulumi_newrelic/outputs.py +2446 -245
- pulumi_newrelic/plugins/_inputs.py +145 -10
- pulumi_newrelic/plugins/application_settings.py +25 -36
- pulumi_newrelic/plugins/outputs.py +15 -10
- pulumi_newrelic/plugins/workload.py +215 -92
- pulumi_newrelic/provider.py +27 -33
- pulumi_newrelic/pulumi-plugin.json +2 -1
- pulumi_newrelic/service_level.py +185 -186
- pulumi_newrelic/synthetics/_inputs.py +159 -2
- pulumi_newrelic/synthetics/alert_condition.py +87 -98
- pulumi_newrelic/synthetics/broken_links_monitor.py +216 -99
- pulumi_newrelic/synthetics/cert_check_monitor.py +219 -100
- pulumi_newrelic/synthetics/get_private_location.py +34 -30
- pulumi_newrelic/synthetics/get_secure_credential.py +24 -16
- pulumi_newrelic/synthetics/monitor.py +348 -193
- pulumi_newrelic/synthetics/multi_location_alert_condition.py +105 -100
- pulumi_newrelic/synthetics/outputs.py +7 -2
- pulumi_newrelic/synthetics/private_location.py +25 -20
- pulumi_newrelic/synthetics/script_monitor.py +317 -182
- pulumi_newrelic/synthetics/secure_credential.py +23 -22
- pulumi_newrelic/synthetics/step_monitor.py +405 -100
- pulumi_newrelic/user.py +13 -10
- pulumi_newrelic/workflow.py +209 -196
- {pulumi_newrelic-5.21.0a1710157101.dist-info → pulumi_newrelic-5.39.0a1736849617.dist-info}/METADATA +7 -6
- pulumi_newrelic-5.39.0a1736849617.dist-info/RECORD +90 -0
- {pulumi_newrelic-5.21.0a1710157101.dist-info → pulumi_newrelic-5.39.0a1736849617.dist-info}/WHEEL +1 -1
- pulumi_newrelic-5.21.0a1710157101.dist-info/RECORD +0 -89
- {pulumi_newrelic-5.21.0a1710157101.dist-info → pulumi_newrelic-5.39.0a1736849617.dist-info}/top_level.txt +0 -0
@@ -4,9 +4,14 @@
|
|
4
4
|
|
5
5
|
import copy
|
6
6
|
import warnings
|
7
|
+
import sys
|
7
8
|
import pulumi
|
8
9
|
import pulumi.runtime
|
9
10
|
from typing import Any, Mapping, Optional, Sequence, Union, overload
|
11
|
+
if sys.version_info >= (3, 11):
|
12
|
+
from typing import NotRequired, TypedDict, TypeAlias
|
13
|
+
else:
|
14
|
+
from typing_extensions import NotRequired, TypedDict, TypeAlias
|
10
15
|
from . import _utilities
|
11
16
|
|
12
17
|
__all__ = [
|
@@ -21,13 +26,46 @@ class GetKeyTransactionResult:
|
|
21
26
|
"""
|
22
27
|
A collection of values returned by getKeyTransaction.
|
23
28
|
"""
|
24
|
-
def __init__(__self__, id=None, name=None):
|
29
|
+
def __init__(__self__, account_id=None, domain=None, guid=None, id=None, name=None, type=None):
|
30
|
+
if account_id and not isinstance(account_id, str):
|
31
|
+
raise TypeError("Expected argument 'account_id' to be a str")
|
32
|
+
pulumi.set(__self__, "account_id", account_id)
|
33
|
+
if domain and not isinstance(domain, str):
|
34
|
+
raise TypeError("Expected argument 'domain' to be a str")
|
35
|
+
pulumi.set(__self__, "domain", domain)
|
36
|
+
if guid and not isinstance(guid, str):
|
37
|
+
raise TypeError("Expected argument 'guid' to be a str")
|
38
|
+
pulumi.set(__self__, "guid", guid)
|
25
39
|
if id and not isinstance(id, str):
|
26
40
|
raise TypeError("Expected argument 'id' to be a str")
|
27
41
|
pulumi.set(__self__, "id", id)
|
28
42
|
if name and not isinstance(name, str):
|
29
43
|
raise TypeError("Expected argument 'name' to be a str")
|
30
44
|
pulumi.set(__self__, "name", name)
|
45
|
+
if type and not isinstance(type, str):
|
46
|
+
raise TypeError("Expected argument 'type' to be a str")
|
47
|
+
pulumi.set(__self__, "type", type)
|
48
|
+
|
49
|
+
@property
|
50
|
+
@pulumi.getter(name="accountId")
|
51
|
+
def account_id(self) -> str:
|
52
|
+
return pulumi.get(self, "account_id")
|
53
|
+
|
54
|
+
@property
|
55
|
+
@pulumi.getter
|
56
|
+
def domain(self) -> str:
|
57
|
+
"""
|
58
|
+
Domain of the key transaction in New Relic.
|
59
|
+
"""
|
60
|
+
return pulumi.get(self, "domain")
|
61
|
+
|
62
|
+
@property
|
63
|
+
@pulumi.getter
|
64
|
+
def guid(self) -> str:
|
65
|
+
"""
|
66
|
+
GUID of the key transaction in New Relic.
|
67
|
+
"""
|
68
|
+
return pulumi.get(self, "guid")
|
31
69
|
|
32
70
|
@property
|
33
71
|
@pulumi.getter
|
@@ -42,6 +80,14 @@ class GetKeyTransactionResult:
|
|
42
80
|
def name(self) -> str:
|
43
81
|
return pulumi.get(self, "name")
|
44
82
|
|
83
|
+
@property
|
84
|
+
@pulumi.getter
|
85
|
+
def type(self) -> str:
|
86
|
+
"""
|
87
|
+
Type of the key transaction in New Relic.
|
88
|
+
"""
|
89
|
+
return pulumi.get(self, "type")
|
90
|
+
|
45
91
|
|
46
92
|
class AwaitableGetKeyTransactionResult(GetKeyTransactionResult):
|
47
93
|
# pylint: disable=using-constant-test
|
@@ -49,85 +95,114 @@ class AwaitableGetKeyTransactionResult(GetKeyTransactionResult):
|
|
49
95
|
if False:
|
50
96
|
yield self
|
51
97
|
return GetKeyTransactionResult(
|
98
|
+
account_id=self.account_id,
|
99
|
+
domain=self.domain,
|
100
|
+
guid=self.guid,
|
52
101
|
id=self.id,
|
53
|
-
name=self.name
|
102
|
+
name=self.name,
|
103
|
+
type=self.type)
|
54
104
|
|
55
105
|
|
56
|
-
def get_key_transaction(
|
106
|
+
def get_key_transaction(account_id: Optional[str] = None,
|
107
|
+
guid: Optional[str] = None,
|
108
|
+
name: Optional[str] = None,
|
57
109
|
opts: Optional[pulumi.InvokeOptions] = None) -> AwaitableGetKeyTransactionResult:
|
58
110
|
"""
|
59
111
|
Use this data source to get information about a specific key transaction in New Relic that already exists.
|
60
112
|
|
61
113
|
## Example Usage
|
62
114
|
|
63
|
-
<!--Start PulumiCodeChooser -->
|
64
115
|
```python
|
65
116
|
import pulumi
|
66
117
|
import pulumi_newrelic as newrelic
|
67
118
|
|
68
119
|
txn = newrelic.get_key_transaction(name="txn")
|
69
|
-
|
70
|
-
foo_alert_condition = newrelic.AlertCondition("
|
71
|
-
policy_id=
|
120
|
+
foo = newrelic.AlertPolicy("foo", name="foo")
|
121
|
+
foo_alert_condition = newrelic.AlertCondition("foo",
|
122
|
+
policy_id=foo.id,
|
123
|
+
name="foo",
|
72
124
|
type="apm_kt_metric",
|
73
125
|
entities=[txn.id],
|
74
126
|
metric="error_percentage",
|
75
127
|
runbook_url="https://www.example.com",
|
76
|
-
terms=[
|
77
|
-
duration
|
78
|
-
operator
|
79
|
-
priority
|
80
|
-
threshold
|
81
|
-
time_function
|
82
|
-
|
128
|
+
terms=[{
|
129
|
+
"duration": 5,
|
130
|
+
"operator": "below",
|
131
|
+
"priority": "critical",
|
132
|
+
"threshold": 0.75,
|
133
|
+
"time_function": "all",
|
134
|
+
}])
|
83
135
|
```
|
84
|
-
<!--End PulumiCodeChooser -->
|
85
136
|
|
86
137
|
|
138
|
+
:param str account_id: The account ID you would like to search for key transactions in. Defaults to `account_id` in the `provider{}` (or `NEW_RELIC_ACCOUNT_ID` in your environment) if not specified.
|
139
|
+
|
140
|
+
> **NOTE** If the `name` specified in the configuration matches the names of multiple key transactions in the account, the data source will return the first match from the list of all matching key transactions retrieved from the API. However, when using the `guid` argument as the search criterion, only the key transaction with that particular GUID is returned, as each key transaction has a unique GUID.
|
141
|
+
:param str guid: GUID of the key transaction in New Relic.
|
87
142
|
:param str name: The name of the key transaction in New Relic.
|
88
143
|
"""
|
89
144
|
__args__ = dict()
|
145
|
+
__args__['accountId'] = account_id
|
146
|
+
__args__['guid'] = guid
|
90
147
|
__args__['name'] = name
|
91
148
|
opts = pulumi.InvokeOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
|
92
149
|
__ret__ = pulumi.runtime.invoke('newrelic:index/getKeyTransaction:getKeyTransaction', __args__, opts=opts, typ=GetKeyTransactionResult).value
|
93
150
|
|
94
151
|
return AwaitableGetKeyTransactionResult(
|
152
|
+
account_id=pulumi.get(__ret__, 'account_id'),
|
153
|
+
domain=pulumi.get(__ret__, 'domain'),
|
154
|
+
guid=pulumi.get(__ret__, 'guid'),
|
95
155
|
id=pulumi.get(__ret__, 'id'),
|
96
|
-
name=pulumi.get(__ret__, 'name')
|
97
|
-
|
98
|
-
|
99
|
-
|
100
|
-
|
101
|
-
opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetKeyTransactionResult]:
|
156
|
+
name=pulumi.get(__ret__, 'name'),
|
157
|
+
type=pulumi.get(__ret__, 'type'))
|
158
|
+
def get_key_transaction_output(account_id: Optional[pulumi.Input[Optional[str]]] = None,
|
159
|
+
guid: Optional[pulumi.Input[Optional[str]]] = None,
|
160
|
+
name: Optional[pulumi.Input[str]] = None,
|
161
|
+
opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetKeyTransactionResult]:
|
102
162
|
"""
|
103
163
|
Use this data source to get information about a specific key transaction in New Relic that already exists.
|
104
164
|
|
105
165
|
## Example Usage
|
106
166
|
|
107
|
-
<!--Start PulumiCodeChooser -->
|
108
167
|
```python
|
109
168
|
import pulumi
|
110
169
|
import pulumi_newrelic as newrelic
|
111
170
|
|
112
171
|
txn = newrelic.get_key_transaction(name="txn")
|
113
|
-
|
114
|
-
foo_alert_condition = newrelic.AlertCondition("
|
115
|
-
policy_id=
|
172
|
+
foo = newrelic.AlertPolicy("foo", name="foo")
|
173
|
+
foo_alert_condition = newrelic.AlertCondition("foo",
|
174
|
+
policy_id=foo.id,
|
175
|
+
name="foo",
|
116
176
|
type="apm_kt_metric",
|
117
177
|
entities=[txn.id],
|
118
178
|
metric="error_percentage",
|
119
179
|
runbook_url="https://www.example.com",
|
120
|
-
terms=[
|
121
|
-
duration
|
122
|
-
operator
|
123
|
-
priority
|
124
|
-
threshold
|
125
|
-
time_function
|
126
|
-
|
180
|
+
terms=[{
|
181
|
+
"duration": 5,
|
182
|
+
"operator": "below",
|
183
|
+
"priority": "critical",
|
184
|
+
"threshold": 0.75,
|
185
|
+
"time_function": "all",
|
186
|
+
}])
|
127
187
|
```
|
128
|
-
<!--End PulumiCodeChooser -->
|
129
188
|
|
130
189
|
|
190
|
+
:param str account_id: The account ID you would like to search for key transactions in. Defaults to `account_id` in the `provider{}` (or `NEW_RELIC_ACCOUNT_ID` in your environment) if not specified.
|
191
|
+
|
192
|
+
> **NOTE** If the `name` specified in the configuration matches the names of multiple key transactions in the account, the data source will return the first match from the list of all matching key transactions retrieved from the API. However, when using the `guid` argument as the search criterion, only the key transaction with that particular GUID is returned, as each key transaction has a unique GUID.
|
193
|
+
:param str guid: GUID of the key transaction in New Relic.
|
131
194
|
:param str name: The name of the key transaction in New Relic.
|
132
195
|
"""
|
133
|
-
|
196
|
+
__args__ = dict()
|
197
|
+
__args__['accountId'] = account_id
|
198
|
+
__args__['guid'] = guid
|
199
|
+
__args__['name'] = name
|
200
|
+
opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
|
201
|
+
__ret__ = pulumi.runtime.invoke_output('newrelic:index/getKeyTransaction:getKeyTransaction', __args__, opts=opts, typ=GetKeyTransactionResult)
|
202
|
+
return __ret__.apply(lambda __response__: GetKeyTransactionResult(
|
203
|
+
account_id=pulumi.get(__response__, 'account_id'),
|
204
|
+
domain=pulumi.get(__response__, 'domain'),
|
205
|
+
guid=pulumi.get(__response__, 'guid'),
|
206
|
+
id=pulumi.get(__response__, 'id'),
|
207
|
+
name=pulumi.get(__response__, 'name'),
|
208
|
+
type=pulumi.get(__response__, 'type')))
|
@@ -4,11 +4,17 @@
|
|
4
4
|
|
5
5
|
import copy
|
6
6
|
import warnings
|
7
|
+
import sys
|
7
8
|
import pulumi
|
8
9
|
import pulumi.runtime
|
9
10
|
from typing import Any, Mapping, Optional, Sequence, Union, overload
|
11
|
+
if sys.version_info >= (3, 11):
|
12
|
+
from typing import NotRequired, TypedDict, TypeAlias
|
13
|
+
else:
|
14
|
+
from typing_extensions import NotRequired, TypedDict, TypeAlias
|
10
15
|
from . import _utilities
|
11
16
|
from . import outputs
|
17
|
+
from ._inputs import *
|
12
18
|
|
13
19
|
__all__ = [
|
14
20
|
'GetNotificationDestinationResult',
|
@@ -22,13 +28,16 @@ class GetNotificationDestinationResult:
|
|
22
28
|
"""
|
23
29
|
A collection of values returned by getNotificationDestination.
|
24
30
|
"""
|
25
|
-
def __init__(__self__, account_id=None, active=None, id=None, name=None, properties=None, status=None, type=None):
|
26
|
-
if account_id and not isinstance(account_id,
|
27
|
-
raise TypeError("Expected argument 'account_id' to be a
|
31
|
+
def __init__(__self__, account_id=None, active=None, guid=None, id=None, name=None, properties=None, secure_urls=None, status=None, type=None):
|
32
|
+
if account_id and not isinstance(account_id, str):
|
33
|
+
raise TypeError("Expected argument 'account_id' to be a str")
|
28
34
|
pulumi.set(__self__, "account_id", account_id)
|
29
35
|
if active and not isinstance(active, bool):
|
30
36
|
raise TypeError("Expected argument 'active' to be a bool")
|
31
37
|
pulumi.set(__self__, "active", active)
|
38
|
+
if guid and not isinstance(guid, str):
|
39
|
+
raise TypeError("Expected argument 'guid' to be a str")
|
40
|
+
pulumi.set(__self__, "guid", guid)
|
32
41
|
if id and not isinstance(id, str):
|
33
42
|
raise TypeError("Expected argument 'id' to be a str")
|
34
43
|
pulumi.set(__self__, "id", id)
|
@@ -38,6 +47,9 @@ class GetNotificationDestinationResult:
|
|
38
47
|
if properties and not isinstance(properties, list):
|
39
48
|
raise TypeError("Expected argument 'properties' to be a list")
|
40
49
|
pulumi.set(__self__, "properties", properties)
|
50
|
+
if secure_urls and not isinstance(secure_urls, list):
|
51
|
+
raise TypeError("Expected argument 'secure_urls' to be a list")
|
52
|
+
pulumi.set(__self__, "secure_urls", secure_urls)
|
41
53
|
if status and not isinstance(status, str):
|
42
54
|
raise TypeError("Expected argument 'status' to be a str")
|
43
55
|
pulumi.set(__self__, "status", status)
|
@@ -47,7 +59,7 @@ class GetNotificationDestinationResult:
|
|
47
59
|
|
48
60
|
@property
|
49
61
|
@pulumi.getter(name="accountId")
|
50
|
-
def account_id(self) ->
|
62
|
+
def account_id(self) -> str:
|
51
63
|
return pulumi.get(self, "account_id")
|
52
64
|
|
53
65
|
@property
|
@@ -58,6 +70,14 @@ class GetNotificationDestinationResult:
|
|
58
70
|
"""
|
59
71
|
return pulumi.get(self, "active")
|
60
72
|
|
73
|
+
@property
|
74
|
+
@pulumi.getter
|
75
|
+
def guid(self) -> str:
|
76
|
+
"""
|
77
|
+
The unique entity identifier of the destination in New Relic.
|
78
|
+
"""
|
79
|
+
return pulumi.get(self, "guid")
|
80
|
+
|
61
81
|
@property
|
62
82
|
@pulumi.getter
|
63
83
|
def id(self) -> Optional[str]:
|
@@ -79,6 +99,14 @@ class GetNotificationDestinationResult:
|
|
79
99
|
"""
|
80
100
|
return pulumi.get(self, "properties")
|
81
101
|
|
102
|
+
@property
|
103
|
+
@pulumi.getter(name="secureUrls")
|
104
|
+
def secure_urls(self) -> Sequence['outputs.GetNotificationDestinationSecureUrlResult']:
|
105
|
+
"""
|
106
|
+
The URL in secure format, showing only the `prefix`, as the `secure_suffix` is a secret.
|
107
|
+
"""
|
108
|
+
return pulumi.get(self, "secure_urls")
|
109
|
+
|
82
110
|
@property
|
83
111
|
@pulumi.getter
|
84
112
|
def status(self) -> str:
|
@@ -91,7 +119,7 @@ class GetNotificationDestinationResult:
|
|
91
119
|
@pulumi.getter
|
92
120
|
def type(self) -> str:
|
93
121
|
"""
|
94
|
-
The notification destination type, either: `EMAIL`, `SERVICE_NOW`, `WEBHOOK`, `JIRA`, `MOBILE_PUSH`, `EVENT_BRIDGE`, `PAGERDUTY_ACCOUNT_INTEGRATION` or `PAGERDUTY_SERVICE_INTEGRATION`, `SLACK` and `SLACK_COLLABORATION`.
|
122
|
+
The notification destination type, either: `EMAIL`, `SERVICE_NOW`, `SERVICE_NOW_APP`, `WEBHOOK`, `JIRA`, `MOBILE_PUSH`, `EVENT_BRIDGE`, `PAGERDUTY_ACCOUNT_INTEGRATION` or `PAGERDUTY_SERVICE_INTEGRATION`, `SLACK` and `SLACK_COLLABORATION`.
|
95
123
|
"""
|
96
124
|
return pulumi.get(self, "type")
|
97
125
|
|
@@ -104,55 +132,77 @@ class AwaitableGetNotificationDestinationResult(GetNotificationDestinationResult
|
|
104
132
|
return GetNotificationDestinationResult(
|
105
133
|
account_id=self.account_id,
|
106
134
|
active=self.active,
|
135
|
+
guid=self.guid,
|
107
136
|
id=self.id,
|
108
137
|
name=self.name,
|
109
138
|
properties=self.properties,
|
139
|
+
secure_urls=self.secure_urls,
|
110
140
|
status=self.status,
|
111
141
|
type=self.type)
|
112
142
|
|
113
143
|
|
114
|
-
def get_notification_destination(account_id: Optional[
|
144
|
+
def get_notification_destination(account_id: Optional[str] = None,
|
115
145
|
id: Optional[str] = None,
|
116
146
|
name: Optional[str] = None,
|
147
|
+
secure_urls: Optional[Sequence[Union['GetNotificationDestinationSecureUrlArgs', 'GetNotificationDestinationSecureUrlArgsDict']]] = None,
|
117
148
|
opts: Optional[pulumi.InvokeOptions] = None) -> AwaitableGetNotificationDestinationResult:
|
118
149
|
"""
|
119
150
|
Use this data source to access information about an existing resource.
|
120
151
|
|
121
|
-
:param
|
152
|
+
:param str account_id: The New Relic account ID to operate on. This allows you to override the `account_id` attribute set on the provider. Defaults to the environment variable `NEW_RELIC_ACCOUNT_ID`.
|
122
153
|
:param str id: The id of the notification destination in New Relic.
|
123
154
|
:param str name: The name of the notification destination.
|
124
155
|
|
125
156
|
Optional:
|
157
|
+
:param Sequence[Union['GetNotificationDestinationSecureUrlArgs', 'GetNotificationDestinationSecureUrlArgsDict']] secure_urls: The URL in secure format, showing only the `prefix`, as the `secure_suffix` is a secret.
|
126
158
|
"""
|
127
159
|
__args__ = dict()
|
128
160
|
__args__['accountId'] = account_id
|
129
161
|
__args__['id'] = id
|
130
162
|
__args__['name'] = name
|
163
|
+
__args__['secureUrls'] = secure_urls
|
131
164
|
opts = pulumi.InvokeOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
|
132
165
|
__ret__ = pulumi.runtime.invoke('newrelic:index/getNotificationDestination:getNotificationDestination', __args__, opts=opts, typ=GetNotificationDestinationResult).value
|
133
166
|
|
134
167
|
return AwaitableGetNotificationDestinationResult(
|
135
168
|
account_id=pulumi.get(__ret__, 'account_id'),
|
136
169
|
active=pulumi.get(__ret__, 'active'),
|
170
|
+
guid=pulumi.get(__ret__, 'guid'),
|
137
171
|
id=pulumi.get(__ret__, 'id'),
|
138
172
|
name=pulumi.get(__ret__, 'name'),
|
139
173
|
properties=pulumi.get(__ret__, 'properties'),
|
174
|
+
secure_urls=pulumi.get(__ret__, 'secure_urls'),
|
140
175
|
status=pulumi.get(__ret__, 'status'),
|
141
176
|
type=pulumi.get(__ret__, 'type'))
|
142
|
-
|
143
|
-
|
144
|
-
@_utilities.lift_output_func(get_notification_destination)
|
145
|
-
def get_notification_destination_output(account_id: Optional[pulumi.Input[Optional[int]]] = None,
|
177
|
+
def get_notification_destination_output(account_id: Optional[pulumi.Input[Optional[str]]] = None,
|
146
178
|
id: Optional[pulumi.Input[Optional[str]]] = None,
|
147
179
|
name: Optional[pulumi.Input[Optional[str]]] = None,
|
148
|
-
|
180
|
+
secure_urls: Optional[pulumi.Input[Optional[Sequence[Union['GetNotificationDestinationSecureUrlArgs', 'GetNotificationDestinationSecureUrlArgsDict']]]]] = None,
|
181
|
+
opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetNotificationDestinationResult]:
|
149
182
|
"""
|
150
183
|
Use this data source to access information about an existing resource.
|
151
184
|
|
152
|
-
:param
|
185
|
+
:param str account_id: The New Relic account ID to operate on. This allows you to override the `account_id` attribute set on the provider. Defaults to the environment variable `NEW_RELIC_ACCOUNT_ID`.
|
153
186
|
:param str id: The id of the notification destination in New Relic.
|
154
187
|
:param str name: The name of the notification destination.
|
155
188
|
|
156
189
|
Optional:
|
190
|
+
:param Sequence[Union['GetNotificationDestinationSecureUrlArgs', 'GetNotificationDestinationSecureUrlArgsDict']] secure_urls: The URL in secure format, showing only the `prefix`, as the `secure_suffix` is a secret.
|
157
191
|
"""
|
158
|
-
|
192
|
+
__args__ = dict()
|
193
|
+
__args__['accountId'] = account_id
|
194
|
+
__args__['id'] = id
|
195
|
+
__args__['name'] = name
|
196
|
+
__args__['secureUrls'] = secure_urls
|
197
|
+
opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
|
198
|
+
__ret__ = pulumi.runtime.invoke_output('newrelic:index/getNotificationDestination:getNotificationDestination', __args__, opts=opts, typ=GetNotificationDestinationResult)
|
199
|
+
return __ret__.apply(lambda __response__: GetNotificationDestinationResult(
|
200
|
+
account_id=pulumi.get(__response__, 'account_id'),
|
201
|
+
active=pulumi.get(__response__, 'active'),
|
202
|
+
guid=pulumi.get(__response__, 'guid'),
|
203
|
+
id=pulumi.get(__response__, 'id'),
|
204
|
+
name=pulumi.get(__response__, 'name'),
|
205
|
+
properties=pulumi.get(__response__, 'properties'),
|
206
|
+
secure_urls=pulumi.get(__response__, 'secure_urls'),
|
207
|
+
status=pulumi.get(__response__, 'status'),
|
208
|
+
type=pulumi.get(__response__, 'type')))
|
@@ -4,9 +4,14 @@
|
|
4
4
|
|
5
5
|
import copy
|
6
6
|
import warnings
|
7
|
+
import sys
|
7
8
|
import pulumi
|
8
9
|
import pulumi.runtime
|
9
10
|
from typing import Any, Mapping, Optional, Sequence, Union, overload
|
11
|
+
if sys.version_info >= (3, 11):
|
12
|
+
from typing import NotRequired, TypedDict, TypeAlias
|
13
|
+
else:
|
14
|
+
from typing_extensions import NotRequired, TypedDict, TypeAlias
|
10
15
|
from . import _utilities
|
11
16
|
|
12
17
|
__all__ = [
|
@@ -22,8 +27,8 @@ class GetObfuscationExpressionResult:
|
|
22
27
|
A collection of values returned by getObfuscationExpression.
|
23
28
|
"""
|
24
29
|
def __init__(__self__, account_id=None, id=None, name=None):
|
25
|
-
if account_id and not isinstance(account_id,
|
26
|
-
raise TypeError("Expected argument 'account_id' to be a
|
30
|
+
if account_id and not isinstance(account_id, str):
|
31
|
+
raise TypeError("Expected argument 'account_id' to be a str")
|
27
32
|
pulumi.set(__self__, "account_id", account_id)
|
28
33
|
if id and not isinstance(id, str):
|
29
34
|
raise TypeError("Expected argument 'id' to be a str")
|
@@ -34,7 +39,7 @@ class GetObfuscationExpressionResult:
|
|
34
39
|
|
35
40
|
@property
|
36
41
|
@pulumi.getter(name="accountId")
|
37
|
-
def account_id(self) -> Optional[
|
42
|
+
def account_id(self) -> Optional[str]:
|
38
43
|
return pulumi.get(self, "account_id")
|
39
44
|
|
40
45
|
@property
|
@@ -62,7 +67,7 @@ class AwaitableGetObfuscationExpressionResult(GetObfuscationExpressionResult):
|
|
62
67
|
name=self.name)
|
63
68
|
|
64
69
|
|
65
|
-
def get_obfuscation_expression(account_id: Optional[
|
70
|
+
def get_obfuscation_expression(account_id: Optional[str] = None,
|
66
71
|
name: Optional[str] = None,
|
67
72
|
opts: Optional[pulumi.InvokeOptions] = None) -> AwaitableGetObfuscationExpressionResult:
|
68
73
|
"""
|
@@ -70,27 +75,26 @@ def get_obfuscation_expression(account_id: Optional[int] = None,
|
|
70
75
|
|
71
76
|
## Example Usage
|
72
77
|
|
73
|
-
<!--Start PulumiCodeChooser -->
|
74
78
|
```python
|
75
79
|
import pulumi
|
76
80
|
import pulumi_newrelic as newrelic
|
77
81
|
|
78
|
-
expression = newrelic.get_obfuscation_expression(account_id=123456,
|
82
|
+
expression = newrelic.get_obfuscation_expression(account_id="123456",
|
79
83
|
name="The expression")
|
80
84
|
rule = newrelic.ObfuscationRule("rule",
|
85
|
+
name="ruleName",
|
81
86
|
description="description of the rule",
|
82
87
|
filter="hostStatus=running",
|
83
88
|
enabled=True,
|
84
|
-
actions=[
|
85
|
-
attributes
|
86
|
-
expression_id
|
87
|
-
method
|
88
|
-
|
89
|
+
actions=[{
|
90
|
+
"attributes": ["message"],
|
91
|
+
"expression_id": expression.id,
|
92
|
+
"method": "MASK",
|
93
|
+
}])
|
89
94
|
```
|
90
|
-
<!--End PulumiCodeChooser -->
|
91
95
|
|
92
96
|
|
93
|
-
:param
|
97
|
+
:param str account_id: The account id associated with the obfuscation expression. If left empty will default to account ID specified in provider level configuration.
|
94
98
|
:param str name: Name of expression.
|
95
99
|
"""
|
96
100
|
__args__ = dict()
|
@@ -103,38 +107,42 @@ def get_obfuscation_expression(account_id: Optional[int] = None,
|
|
103
107
|
account_id=pulumi.get(__ret__, 'account_id'),
|
104
108
|
id=pulumi.get(__ret__, 'id'),
|
105
109
|
name=pulumi.get(__ret__, 'name'))
|
106
|
-
|
107
|
-
|
108
|
-
@_utilities.lift_output_func(get_obfuscation_expression)
|
109
|
-
def get_obfuscation_expression_output(account_id: Optional[pulumi.Input[Optional[int]]] = None,
|
110
|
+
def get_obfuscation_expression_output(account_id: Optional[pulumi.Input[Optional[str]]] = None,
|
110
111
|
name: Optional[pulumi.Input[str]] = None,
|
111
|
-
opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetObfuscationExpressionResult]:
|
112
|
+
opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetObfuscationExpressionResult]:
|
112
113
|
"""
|
113
114
|
Use this data source to get information about a specific Obfuscation Expression in New Relic that already exists.
|
114
115
|
|
115
116
|
## Example Usage
|
116
117
|
|
117
|
-
<!--Start PulumiCodeChooser -->
|
118
118
|
```python
|
119
119
|
import pulumi
|
120
120
|
import pulumi_newrelic as newrelic
|
121
121
|
|
122
|
-
expression = newrelic.get_obfuscation_expression(account_id=123456,
|
122
|
+
expression = newrelic.get_obfuscation_expression(account_id="123456",
|
123
123
|
name="The expression")
|
124
124
|
rule = newrelic.ObfuscationRule("rule",
|
125
|
+
name="ruleName",
|
125
126
|
description="description of the rule",
|
126
127
|
filter="hostStatus=running",
|
127
128
|
enabled=True,
|
128
|
-
actions=[
|
129
|
-
attributes
|
130
|
-
expression_id
|
131
|
-
method
|
132
|
-
|
129
|
+
actions=[{
|
130
|
+
"attributes": ["message"],
|
131
|
+
"expression_id": expression.id,
|
132
|
+
"method": "MASK",
|
133
|
+
}])
|
133
134
|
```
|
134
|
-
<!--End PulumiCodeChooser -->
|
135
135
|
|
136
136
|
|
137
|
-
:param
|
137
|
+
:param str account_id: The account id associated with the obfuscation expression. If left empty will default to account ID specified in provider level configuration.
|
138
138
|
:param str name: Name of expression.
|
139
139
|
"""
|
140
|
-
|
140
|
+
__args__ = dict()
|
141
|
+
__args__['accountId'] = account_id
|
142
|
+
__args__['name'] = name
|
143
|
+
opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
|
144
|
+
__ret__ = pulumi.runtime.invoke_output('newrelic:index/getObfuscationExpression:getObfuscationExpression', __args__, opts=opts, typ=GetObfuscationExpressionResult)
|
145
|
+
return __ret__.apply(lambda __response__: GetObfuscationExpressionResult(
|
146
|
+
account_id=pulumi.get(__response__, 'account_id'),
|
147
|
+
id=pulumi.get(__response__, 'id'),
|
148
|
+
name=pulumi.get(__response__, 'name')))
|