cribl-control-plane 0.0.37a1__py3-none-any.whl → 0.0.38__py3-none-any.whl

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.

Potentially problematic release.


This version of cribl-control-plane might be problematic. Click here for more details.

Files changed (38) hide show
  1. cribl_control_plane/_version.py +3 -3
  2. cribl_control_plane/commits.py +56 -46
  3. cribl_control_plane/commits_files.py +12 -12
  4. cribl_control_plane/models/__init__.py +533 -215
  5. cribl_control_plane/models/createversioncommitop.py +26 -1
  6. cribl_control_plane/models/createversionrevertop.py +4 -2
  7. cribl_control_plane/models/createversionundoop.py +4 -2
  8. cribl_control_plane/models/getpacksbyidop.py +37 -0
  9. cribl_control_plane/models/getversioncountop.py +3 -2
  10. cribl_control_plane/models/getversiondiffop.py +3 -2
  11. cribl_control_plane/models/getversionfilesop.py +3 -2
  12. cribl_control_plane/models/getversionop.py +4 -2
  13. cribl_control_plane/models/getversionshowop.py +3 -2
  14. cribl_control_plane/models/getversionstatusop.py +4 -2
  15. cribl_control_plane/models/gitrevertparams.py +3 -3
  16. cribl_control_plane/models/input.py +77 -76
  17. cribl_control_plane/models/inputcrowdstrike.py +2 -2
  18. cribl_control_plane/models/inputgrafana.py +678 -67
  19. cribl_control_plane/models/inputs3.py +2 -2
  20. cribl_control_plane/models/inputs3inventory.py +2 -2
  21. cribl_control_plane/models/inputsecuritylake.py +2 -2
  22. cribl_control_plane/models/inputsyslog.py +406 -37
  23. cribl_control_plane/models/inputwizwebhook.py +393 -0
  24. cribl_control_plane/models/output.py +75 -77
  25. cribl_control_plane/models/outputcrowdstrikenextgensiem.py +1 -1
  26. cribl_control_plane/models/outputgooglepubsub.py +7 -28
  27. cribl_control_plane/models/outputgrafanacloud.py +565 -69
  28. cribl_control_plane/models/packinfo.py +5 -5
  29. cribl_control_plane/models/packinstallinfo.py +5 -5
  30. cribl_control_plane/models/packrequestbody_union.py +140 -0
  31. cribl_control_plane/models/packupgraderequest.py +26 -0
  32. cribl_control_plane/models/updatepacksbyidop.py +9 -28
  33. cribl_control_plane/packs.py +236 -116
  34. cribl_control_plane/statuses.py +6 -6
  35. {cribl_control_plane-0.0.37a1.dist-info → cribl_control_plane-0.0.38.dist-info}/METADATA +4 -3
  36. {cribl_control_plane-0.0.37a1.dist-info → cribl_control_plane-0.0.38.dist-info}/RECORD +37 -34
  37. cribl_control_plane/models/packrequestbody.py +0 -75
  38. {cribl_control_plane-0.0.37a1.dist-info → cribl_control_plane-0.0.38.dist-info}/WHEEL +0 -0
@@ -4,33 +4,33 @@ from __future__ import annotations
4
4
  from cribl_control_plane.types import BaseModel
5
5
  from enum import Enum
6
6
  import pydantic
7
- from typing import List, Optional
8
- from typing_extensions import Annotated, NotRequired, TypedDict
7
+ from typing import List, Optional, Union
8
+ from typing_extensions import Annotated, NotRequired, TypeAliasType, TypedDict
9
9
 
10
10
 
11
- class OutputGrafanaCloudType(str, Enum):
11
+ class OutputGrafanaCloudType2(str, Enum):
12
12
  GRAFANA_CLOUD = "grafana_cloud"
13
13
 
14
14
 
15
- class OutputGrafanaCloudMessageFormat(str, Enum):
15
+ class OutputGrafanaCloudMessageFormat2(str, Enum):
16
16
  r"""Format to use when sending logs to Loki (Protobuf or JSON)"""
17
17
 
18
18
  PROTOBUF = "protobuf"
19
19
  JSON = "json"
20
20
 
21
21
 
22
- class OutputGrafanaCloudLabelTypedDict(TypedDict):
22
+ class OutputGrafanaCloudLabel2TypedDict(TypedDict):
23
23
  value: str
24
24
  name: NotRequired[str]
25
25
 
26
26
 
27
- class OutputGrafanaCloudLabel(BaseModel):
27
+ class OutputGrafanaCloudLabel2(BaseModel):
28
28
  value: str
29
29
 
30
30
  name: Optional[str] = ""
31
31
 
32
32
 
33
- class OutputGrafanaCloudPrometheusAuthAuthenticationType(str, Enum):
33
+ class OutputGrafanaCloudPrometheusAuthAuthenticationType2(str, Enum):
34
34
  NONE = "none"
35
35
  TOKEN = "token"
36
36
  TEXT_SECRET = "textSecret"
@@ -38,8 +38,8 @@ class OutputGrafanaCloudPrometheusAuthAuthenticationType(str, Enum):
38
38
  CREDENTIALS_SECRET = "credentialsSecret"
39
39
 
40
40
 
41
- class OutputGrafanaCloudPrometheusAuthTypedDict(TypedDict):
42
- auth_type: NotRequired[OutputGrafanaCloudPrometheusAuthAuthenticationType]
41
+ class OutputGrafanaCloudPrometheusAuth2TypedDict(TypedDict):
42
+ auth_type: NotRequired[OutputGrafanaCloudPrometheusAuthAuthenticationType2]
43
43
  token: NotRequired[str]
44
44
  r"""Bearer token to include in the authorization header. In Grafana Cloud, this is generally built by concatenating the username and the API key, separated by a colon. Example: <your-username>:<your-api-key>"""
45
45
  text_secret: NotRequired[str]
@@ -52,11 +52,11 @@ class OutputGrafanaCloudPrometheusAuthTypedDict(TypedDict):
52
52
  r"""Select or create a secret that references your credentials"""
53
53
 
54
54
 
55
- class OutputGrafanaCloudPrometheusAuth(BaseModel):
55
+ class OutputGrafanaCloudPrometheusAuth2(BaseModel):
56
56
  auth_type: Annotated[
57
- Optional[OutputGrafanaCloudPrometheusAuthAuthenticationType],
57
+ Optional[OutputGrafanaCloudPrometheusAuthAuthenticationType2],
58
58
  pydantic.Field(alias="authType"),
59
- ] = OutputGrafanaCloudPrometheusAuthAuthenticationType.BASIC
59
+ ] = OutputGrafanaCloudPrometheusAuthAuthenticationType2.BASIC
60
60
 
61
61
  token: Optional[str] = None
62
62
  r"""Bearer token to include in the authorization header. In Grafana Cloud, this is generally built by concatenating the username and the API key, separated by a colon. Example: <your-username>:<your-api-key>"""
@@ -76,7 +76,7 @@ class OutputGrafanaCloudPrometheusAuth(BaseModel):
76
76
  r"""Select or create a secret that references your credentials"""
77
77
 
78
78
 
79
- class OutputGrafanaCloudLokiAuthAuthenticationType(str, Enum):
79
+ class OutputGrafanaCloudLokiAuthAuthenticationType2(str, Enum):
80
80
  NONE = "none"
81
81
  TOKEN = "token"
82
82
  TEXT_SECRET = "textSecret"
@@ -84,8 +84,8 @@ class OutputGrafanaCloudLokiAuthAuthenticationType(str, Enum):
84
84
  CREDENTIALS_SECRET = "credentialsSecret"
85
85
 
86
86
 
87
- class OutputGrafanaCloudLokiAuthTypedDict(TypedDict):
88
- auth_type: NotRequired[OutputGrafanaCloudLokiAuthAuthenticationType]
87
+ class OutputGrafanaCloudLokiAuth2TypedDict(TypedDict):
88
+ auth_type: NotRequired[OutputGrafanaCloudLokiAuthAuthenticationType2]
89
89
  token: NotRequired[str]
90
90
  r"""Bearer token to include in the authorization header. In Grafana Cloud, this is generally built by concatenating the username and the API key, separated by a colon. Example: <your-username>:<your-api-key>"""
91
91
  text_secret: NotRequired[str]
@@ -98,11 +98,11 @@ class OutputGrafanaCloudLokiAuthTypedDict(TypedDict):
98
98
  r"""Select or create a secret that references your credentials"""
99
99
 
100
100
 
101
- class OutputGrafanaCloudLokiAuth(BaseModel):
101
+ class OutputGrafanaCloudLokiAuth2(BaseModel):
102
102
  auth_type: Annotated[
103
- Optional[OutputGrafanaCloudLokiAuthAuthenticationType],
103
+ Optional[OutputGrafanaCloudLokiAuthAuthenticationType2],
104
104
  pydantic.Field(alias="authType"),
105
- ] = OutputGrafanaCloudLokiAuthAuthenticationType.BASIC
105
+ ] = OutputGrafanaCloudLokiAuthAuthenticationType2.BASIC
106
106
 
107
107
  token: Optional[str] = None
108
108
  r"""Bearer token to include in the authorization header. In Grafana Cloud, this is generally built by concatenating the username and the API key, separated by a colon. Example: <your-username>:<your-api-key>"""
@@ -122,18 +122,18 @@ class OutputGrafanaCloudLokiAuth(BaseModel):
122
122
  r"""Select or create a secret that references your credentials"""
123
123
 
124
124
 
125
- class OutputGrafanaCloudExtraHTTPHeaderTypedDict(TypedDict):
125
+ class OutputGrafanaCloudExtraHTTPHeader2TypedDict(TypedDict):
126
126
  value: str
127
127
  name: NotRequired[str]
128
128
 
129
129
 
130
- class OutputGrafanaCloudExtraHTTPHeader(BaseModel):
130
+ class OutputGrafanaCloudExtraHTTPHeader2(BaseModel):
131
131
  value: str
132
132
 
133
133
  name: Optional[str] = None
134
134
 
135
135
 
136
- class OutputGrafanaCloudFailedRequestLoggingMode(str, Enum):
136
+ class OutputGrafanaCloudFailedRequestLoggingMode2(str, Enum):
137
137
  r"""Data to log when a request fails. All headers are redacted by default, unless listed as safe headers below."""
138
138
 
139
139
  PAYLOAD = "payload"
@@ -141,7 +141,7 @@ class OutputGrafanaCloudFailedRequestLoggingMode(str, Enum):
141
141
  NONE = "none"
142
142
 
143
143
 
144
- class OutputGrafanaCloudResponseRetrySettingTypedDict(TypedDict):
144
+ class OutputGrafanaCloudResponseRetrySetting2TypedDict(TypedDict):
145
145
  http_status: float
146
146
  r"""The HTTP response status code that will trigger retries"""
147
147
  initial_backoff: NotRequired[float]
@@ -152,7 +152,7 @@ class OutputGrafanaCloudResponseRetrySettingTypedDict(TypedDict):
152
152
  r"""The maximum backoff interval, in milliseconds, Cribl Stream should apply. Default (and minimum) is 10,000 ms (10 seconds); maximum is 180,000 ms (180 seconds)."""
153
153
 
154
154
 
155
- class OutputGrafanaCloudResponseRetrySetting(BaseModel):
155
+ class OutputGrafanaCloudResponseRetrySetting2(BaseModel):
156
156
  http_status: Annotated[float, pydantic.Field(alias="httpStatus")]
157
157
  r"""The HTTP response status code that will trigger retries"""
158
158
 
@@ -168,7 +168,7 @@ class OutputGrafanaCloudResponseRetrySetting(BaseModel):
168
168
  r"""The maximum backoff interval, in milliseconds, Cribl Stream should apply. Default (and minimum) is 10,000 ms (10 seconds); maximum is 180,000 ms (180 seconds)."""
169
169
 
170
170
 
171
- class OutputGrafanaCloudTimeoutRetrySettingsTypedDict(TypedDict):
171
+ class OutputGrafanaCloudTimeoutRetrySettings2TypedDict(TypedDict):
172
172
  timeout_retry: NotRequired[bool]
173
173
  initial_backoff: NotRequired[float]
174
174
  r"""How long, in milliseconds, Cribl Stream should wait before initiating backoff. Maximum interval is 600,000 ms (10 minutes)."""
@@ -178,7 +178,7 @@ class OutputGrafanaCloudTimeoutRetrySettingsTypedDict(TypedDict):
178
178
  r"""The maximum backoff interval, in milliseconds, Cribl Stream should apply. Default (and minimum) is 10,000 ms (10 seconds); maximum is 180,000 ms (180 seconds)."""
179
179
 
180
180
 
181
- class OutputGrafanaCloudTimeoutRetrySettings(BaseModel):
181
+ class OutputGrafanaCloudTimeoutRetrySettings2(BaseModel):
182
182
  timeout_retry: Annotated[Optional[bool], pydantic.Field(alias="timeoutRetry")] = (
183
183
  False
184
184
  )
@@ -195,7 +195,7 @@ class OutputGrafanaCloudTimeoutRetrySettings(BaseModel):
195
195
  r"""The maximum backoff interval, in milliseconds, Cribl Stream should apply. Default (and minimum) is 10,000 ms (10 seconds); maximum is 180,000 ms (180 seconds)."""
196
196
 
197
197
 
198
- class OutputGrafanaCloudBackpressureBehavior(str, Enum):
198
+ class OutputGrafanaCloudBackpressureBehavior2(str, Enum):
199
199
  r"""How to handle events when all receivers are exerting backpressure"""
200
200
 
201
201
  BLOCK = "block"
@@ -203,21 +203,21 @@ class OutputGrafanaCloudBackpressureBehavior(str, Enum):
203
203
  QUEUE = "queue"
204
204
 
205
205
 
206
- class OutputGrafanaCloudCompression(str, Enum):
206
+ class OutputGrafanaCloudCompression2(str, Enum):
207
207
  r"""Codec to use to compress the persisted data"""
208
208
 
209
209
  NONE = "none"
210
210
  GZIP = "gzip"
211
211
 
212
212
 
213
- class OutputGrafanaCloudQueueFullBehavior(str, Enum):
213
+ class OutputGrafanaCloudQueueFullBehavior2(str, Enum):
214
214
  r"""How to handle events when the queue is exerting backpressure (full capacity or low disk). 'Block' is the same behavior as non-PQ blocking. 'Drop new data' throws away incoming data, while leaving the contents of the PQ unchanged."""
215
215
 
216
216
  BLOCK = "block"
217
217
  DROP = "drop"
218
218
 
219
219
 
220
- class OutputGrafanaCloudMode(str, Enum):
220
+ class OutputGrafanaCloudMode2(str, Enum):
221
221
  r"""In Error mode, PQ writes events to the filesystem if the Destination is unavailable. In Backpressure mode, PQ writes events to the filesystem when it detects backpressure from the Destination. In Always On mode, PQ always writes events to the filesystem."""
222
222
 
223
223
  ERROR = "error"
@@ -225,16 +225,18 @@ class OutputGrafanaCloudMode(str, Enum):
225
225
  ALWAYS = "always"
226
226
 
227
227
 
228
- class OutputGrafanaCloudPqControlsTypedDict(TypedDict):
228
+ class OutputGrafanaCloudPqControls2TypedDict(TypedDict):
229
229
  pass
230
230
 
231
231
 
232
- class OutputGrafanaCloudPqControls(BaseModel):
232
+ class OutputGrafanaCloudPqControls2(BaseModel):
233
233
  pass
234
234
 
235
235
 
236
- class OutputGrafanaCloudTypedDict(TypedDict):
237
- type: OutputGrafanaCloudType
236
+ class OutputGrafanaCloudGrafanaCloud2TypedDict(TypedDict):
237
+ type: OutputGrafanaCloudType2
238
+ prometheus_url: str
239
+ r"""The remote_write endpoint to send Prometheus metrics to, such as https://prometheus-blocks-prod-us-central1.grafana.net/api/prom/push"""
238
240
  id: NotRequired[str]
239
241
  r"""Unique ID for this output"""
240
242
  pipeline: NotRequired[str]
@@ -247,18 +249,16 @@ class OutputGrafanaCloudTypedDict(TypedDict):
247
249
  r"""Tags for filtering and grouping in @{product}"""
248
250
  loki_url: NotRequired[str]
249
251
  r"""The endpoint to send logs to, such as https://logs-prod-us-central1.grafana.net"""
250
- prometheus_url: NotRequired[str]
251
- r"""The remote_write endpoint to send Prometheus metrics to, such as https://prometheus-blocks-prod-us-central1.grafana.net/api/prom/push"""
252
252
  message: NotRequired[str]
253
253
  r"""Name of the event field that contains the message to send. If not specified, Stream sends a JSON representation of the whole event."""
254
- message_format: NotRequired[OutputGrafanaCloudMessageFormat]
254
+ message_format: NotRequired[OutputGrafanaCloudMessageFormat2]
255
255
  r"""Format to use when sending logs to Loki (Protobuf or JSON)"""
256
- labels: NotRequired[List[OutputGrafanaCloudLabelTypedDict]]
256
+ labels: NotRequired[List[OutputGrafanaCloudLabel2TypedDict]]
257
257
  r"""List of labels to send with logs. Labels define Loki streams, so use static labels to avoid proliferating label value combinations and streams. Can be merged and/or overridden by the event's __labels field. Example: '__labels: {host: \"cribl.io\", level: \"error\"}'"""
258
258
  metric_rename_expr: NotRequired[str]
259
259
  r"""JavaScript expression that can be used to rename metrics. For example, name.replace(/\./g, '_') will replace all '.' characters in a metric's name with the supported '_' character. Use the 'name' global variable to access the metric's name. You can access event fields' values via __e.<fieldName>."""
260
- prometheus_auth: NotRequired[OutputGrafanaCloudPrometheusAuthTypedDict]
261
- loki_auth: NotRequired[OutputGrafanaCloudLokiAuthTypedDict]
260
+ prometheus_auth: NotRequired[OutputGrafanaCloudPrometheusAuth2TypedDict]
261
+ loki_auth: NotRequired[OutputGrafanaCloudLokiAuth2TypedDict]
262
262
  concurrency: NotRequired[float]
263
263
  r"""Maximum number of ongoing requests before blocking. Warning: Setting this value > 1 can cause Loki and Prometheus to complain about entries being delivered out of order."""
264
264
  max_payload_size_kb: NotRequired[float]
@@ -274,24 +274,28 @@ class OutputGrafanaCloudTypedDict(TypedDict):
274
274
  r"""Amount of time, in seconds, to wait for a request to complete before canceling it"""
275
275
  flush_period_sec: NotRequired[float]
276
276
  r"""Maximum time between requests. Small values could cause the payload size to be smaller than the configured Maximum time between requests. Small values can reduce the payload size below the configured 'Max record size' and 'Max events per request'. Warning: Setting this too low can increase the number of ongoing requests (depending on the value of 'Request concurrency'); this can cause Loki and Prometheus to complain about entries being delivered out of order."""
277
- extra_http_headers: NotRequired[List[OutputGrafanaCloudExtraHTTPHeaderTypedDict]]
277
+ extra_http_headers: NotRequired[List[OutputGrafanaCloudExtraHTTPHeader2TypedDict]]
278
278
  r"""Headers to add to all events"""
279
279
  use_round_robin_dns: NotRequired[bool]
280
280
  r"""Enable round-robin DNS lookup. When a DNS server returns multiple addresses, @{product} will cycle through them in the order returned. For optimal performance, consider enabling this setting for non-load balanced destinations."""
281
- failed_request_logging_mode: NotRequired[OutputGrafanaCloudFailedRequestLoggingMode]
281
+ failed_request_logging_mode: NotRequired[
282
+ OutputGrafanaCloudFailedRequestLoggingMode2
283
+ ]
282
284
  r"""Data to log when a request fails. All headers are redacted by default, unless listed as safe headers below."""
283
285
  safe_headers: NotRequired[List[str]]
284
286
  r"""List of headers that are safe to log in plain text"""
285
287
  send_structured_metadata: NotRequired[bool]
286
288
  r"""Add structured metadata fields from __structuredMetadata to each log. Key-value pairs must be strings."""
287
289
  response_retry_settings: NotRequired[
288
- List[OutputGrafanaCloudResponseRetrySettingTypedDict]
290
+ List[OutputGrafanaCloudResponseRetrySetting2TypedDict]
289
291
  ]
290
292
  r"""Automatically retry after unsuccessful response status codes, such as 429 (Too Many Requests) or 503 (Service Unavailable)"""
291
- timeout_retry_settings: NotRequired[OutputGrafanaCloudTimeoutRetrySettingsTypedDict]
293
+ timeout_retry_settings: NotRequired[
294
+ OutputGrafanaCloudTimeoutRetrySettings2TypedDict
295
+ ]
292
296
  response_honor_retry_after_header: NotRequired[bool]
293
297
  r"""Honor any Retry-After header that specifies a delay (in seconds) no longer than 180 seconds after the retry request. @{product} limits the delay to 180 seconds, even if the Retry-After header specifies a longer delay. When enabled, takes precedence over user-configured retry options. When disabled, all Retry-After headers are ignored."""
294
- on_backpressure: NotRequired[OutputGrafanaCloudBackpressureBehavior]
298
+ on_backpressure: NotRequired[OutputGrafanaCloudBackpressureBehavior2]
295
299
  r"""How to handle events when all receivers are exerting backpressure"""
296
300
  description: NotRequired[str]
297
301
  compress: NotRequired[bool]
@@ -302,17 +306,20 @@ class OutputGrafanaCloudTypedDict(TypedDict):
302
306
  r"""The maximum disk space that the queue can consume (as an average per Worker Process) before queueing stops. Enter a numeral with units of KB, MB, etc."""
303
307
  pq_path: NotRequired[str]
304
308
  r"""The location for the persistent queue files. To this field's value, the system will append: /<worker-id>/<output-id>."""
305
- pq_compress: NotRequired[OutputGrafanaCloudCompression]
309
+ pq_compress: NotRequired[OutputGrafanaCloudCompression2]
306
310
  r"""Codec to use to compress the persisted data"""
307
- pq_on_backpressure: NotRequired[OutputGrafanaCloudQueueFullBehavior]
311
+ pq_on_backpressure: NotRequired[OutputGrafanaCloudQueueFullBehavior2]
308
312
  r"""How to handle events when the queue is exerting backpressure (full capacity or low disk). 'Block' is the same behavior as non-PQ blocking. 'Drop new data' throws away incoming data, while leaving the contents of the PQ unchanged."""
309
- pq_mode: NotRequired[OutputGrafanaCloudMode]
313
+ pq_mode: NotRequired[OutputGrafanaCloudMode2]
310
314
  r"""In Error mode, PQ writes events to the filesystem if the Destination is unavailable. In Backpressure mode, PQ writes events to the filesystem when it detects backpressure from the Destination. In Always On mode, PQ always writes events to the filesystem."""
311
- pq_controls: NotRequired[OutputGrafanaCloudPqControlsTypedDict]
315
+ pq_controls: NotRequired[OutputGrafanaCloudPqControls2TypedDict]
316
+
312
317
 
318
+ class OutputGrafanaCloudGrafanaCloud2(BaseModel):
319
+ type: OutputGrafanaCloudType2
313
320
 
314
- class OutputGrafanaCloud(BaseModel):
315
- type: OutputGrafanaCloudType
321
+ prometheus_url: Annotated[str, pydantic.Field(alias="prometheusUrl")]
322
+ r"""The remote_write endpoint to send Prometheus metrics to, such as https://prometheus-blocks-prod-us-central1.grafana.net/api/prom/push"""
316
323
 
317
324
  id: Optional[str] = None
318
325
  r"""Unique ID for this output"""
@@ -334,6 +341,479 @@ class OutputGrafanaCloud(BaseModel):
334
341
  loki_url: Annotated[Optional[str], pydantic.Field(alias="lokiUrl")] = None
335
342
  r"""The endpoint to send logs to, such as https://logs-prod-us-central1.grafana.net"""
336
343
 
344
+ message: Optional[str] = None
345
+ r"""Name of the event field that contains the message to send. If not specified, Stream sends a JSON representation of the whole event."""
346
+
347
+ message_format: Annotated[
348
+ Optional[OutputGrafanaCloudMessageFormat2],
349
+ pydantic.Field(alias="messageFormat"),
350
+ ] = OutputGrafanaCloudMessageFormat2.PROTOBUF
351
+ r"""Format to use when sending logs to Loki (Protobuf or JSON)"""
352
+
353
+ labels: Optional[List[OutputGrafanaCloudLabel2]] = None
354
+ r"""List of labels to send with logs. Labels define Loki streams, so use static labels to avoid proliferating label value combinations and streams. Can be merged and/or overridden by the event's __labels field. Example: '__labels: {host: \"cribl.io\", level: \"error\"}'"""
355
+
356
+ metric_rename_expr: Annotated[
357
+ Optional[str], pydantic.Field(alias="metricRenameExpr")
358
+ ] = "name.replace(/[^a-zA-Z0-9_]/g, '_')"
359
+ r"""JavaScript expression that can be used to rename metrics. For example, name.replace(/\./g, '_') will replace all '.' characters in a metric's name with the supported '_' character. Use the 'name' global variable to access the metric's name. You can access event fields' values via __e.<fieldName>."""
360
+
361
+ prometheus_auth: Annotated[
362
+ Optional[OutputGrafanaCloudPrometheusAuth2],
363
+ pydantic.Field(alias="prometheusAuth"),
364
+ ] = None
365
+
366
+ loki_auth: Annotated[
367
+ Optional[OutputGrafanaCloudLokiAuth2], pydantic.Field(alias="lokiAuth")
368
+ ] = None
369
+
370
+ concurrency: Optional[float] = 1
371
+ r"""Maximum number of ongoing requests before blocking. Warning: Setting this value > 1 can cause Loki and Prometheus to complain about entries being delivered out of order."""
372
+
373
+ max_payload_size_kb: Annotated[
374
+ Optional[float], pydantic.Field(alias="maxPayloadSizeKB")
375
+ ] = 4096
376
+ r"""Maximum size, in KB, of the request body. Warning: Setting this too low can increase the number of ongoing requests (depending on the value of 'Request concurrency'); this can cause Loki and Prometheus to complain about entries being delivered out of order."""
377
+
378
+ max_payload_events: Annotated[
379
+ Optional[float], pydantic.Field(alias="maxPayloadEvents")
380
+ ] = 0
381
+ r"""Maximum number of events to include in the request body. Default is 0 (unlimited). Warning: Setting this too low can increase the number of ongoing requests (depending on the value of 'Request concurrency'); this can cause Loki and Prometheus to complain about entries being delivered out of order."""
382
+
383
+ reject_unauthorized: Annotated[
384
+ Optional[bool], pydantic.Field(alias="rejectUnauthorized")
385
+ ] = True
386
+ r"""Reject certificates not authorized by a CA in the CA certificate path or by another trusted CA (such as the system's).
387
+ Enabled by default. When this setting is also present in TLS Settings (Client Side),
388
+ that value will take precedence.
389
+ """
390
+
391
+ timeout_sec: Annotated[Optional[float], pydantic.Field(alias="timeoutSec")] = 30
392
+ r"""Amount of time, in seconds, to wait for a request to complete before canceling it"""
393
+
394
+ flush_period_sec: Annotated[
395
+ Optional[float], pydantic.Field(alias="flushPeriodSec")
396
+ ] = 15
397
+ r"""Maximum time between requests. Small values could cause the payload size to be smaller than the configured Maximum time between requests. Small values can reduce the payload size below the configured 'Max record size' and 'Max events per request'. Warning: Setting this too low can increase the number of ongoing requests (depending on the value of 'Request concurrency'); this can cause Loki and Prometheus to complain about entries being delivered out of order."""
398
+
399
+ extra_http_headers: Annotated[
400
+ Optional[List[OutputGrafanaCloudExtraHTTPHeader2]],
401
+ pydantic.Field(alias="extraHttpHeaders"),
402
+ ] = None
403
+ r"""Headers to add to all events"""
404
+
405
+ use_round_robin_dns: Annotated[
406
+ Optional[bool], pydantic.Field(alias="useRoundRobinDns")
407
+ ] = False
408
+ r"""Enable round-robin DNS lookup. When a DNS server returns multiple addresses, @{product} will cycle through them in the order returned. For optimal performance, consider enabling this setting for non-load balanced destinations."""
409
+
410
+ failed_request_logging_mode: Annotated[
411
+ Optional[OutputGrafanaCloudFailedRequestLoggingMode2],
412
+ pydantic.Field(alias="failedRequestLoggingMode"),
413
+ ] = OutputGrafanaCloudFailedRequestLoggingMode2.NONE
414
+ r"""Data to log when a request fails. All headers are redacted by default, unless listed as safe headers below."""
415
+
416
+ safe_headers: Annotated[
417
+ Optional[List[str]], pydantic.Field(alias="safeHeaders")
418
+ ] = None
419
+ r"""List of headers that are safe to log in plain text"""
420
+
421
+ send_structured_metadata: Annotated[
422
+ Optional[bool], pydantic.Field(alias="sendStructuredMetadata")
423
+ ] = False
424
+ r"""Add structured metadata fields from __structuredMetadata to each log. Key-value pairs must be strings."""
425
+
426
+ response_retry_settings: Annotated[
427
+ Optional[List[OutputGrafanaCloudResponseRetrySetting2]],
428
+ pydantic.Field(alias="responseRetrySettings"),
429
+ ] = None
430
+ r"""Automatically retry after unsuccessful response status codes, such as 429 (Too Many Requests) or 503 (Service Unavailable)"""
431
+
432
+ timeout_retry_settings: Annotated[
433
+ Optional[OutputGrafanaCloudTimeoutRetrySettings2],
434
+ pydantic.Field(alias="timeoutRetrySettings"),
435
+ ] = None
436
+
437
+ response_honor_retry_after_header: Annotated[
438
+ Optional[bool], pydantic.Field(alias="responseHonorRetryAfterHeader")
439
+ ] = False
440
+ r"""Honor any Retry-After header that specifies a delay (in seconds) no longer than 180 seconds after the retry request. @{product} limits the delay to 180 seconds, even if the Retry-After header specifies a longer delay. When enabled, takes precedence over user-configured retry options. When disabled, all Retry-After headers are ignored."""
441
+
442
+ on_backpressure: Annotated[
443
+ Optional[OutputGrafanaCloudBackpressureBehavior2],
444
+ pydantic.Field(alias="onBackpressure"),
445
+ ] = OutputGrafanaCloudBackpressureBehavior2.BLOCK
446
+ r"""How to handle events when all receivers are exerting backpressure"""
447
+
448
+ description: Optional[str] = None
449
+
450
+ compress: Optional[bool] = True
451
+ r"""Compress the payload body before sending. Applies only to JSON payloads; the Protobuf variant for both Prometheus and Loki are snappy-compressed by default."""
452
+
453
+ pq_max_file_size: Annotated[
454
+ Optional[str], pydantic.Field(alias="pqMaxFileSize")
455
+ ] = "1 MB"
456
+ r"""The maximum size to store in each queue file before closing and optionally compressing (KB, MB, etc.)"""
457
+
458
+ pq_max_size: Annotated[Optional[str], pydantic.Field(alias="pqMaxSize")] = "5GB"
459
+ r"""The maximum disk space that the queue can consume (as an average per Worker Process) before queueing stops. Enter a numeral with units of KB, MB, etc."""
460
+
461
+ pq_path: Annotated[Optional[str], pydantic.Field(alias="pqPath")] = (
462
+ "$CRIBL_HOME/state/queues"
463
+ )
464
+ r"""The location for the persistent queue files. To this field's value, the system will append: /<worker-id>/<output-id>."""
465
+
466
+ pq_compress: Annotated[
467
+ Optional[OutputGrafanaCloudCompression2], pydantic.Field(alias="pqCompress")
468
+ ] = OutputGrafanaCloudCompression2.NONE
469
+ r"""Codec to use to compress the persisted data"""
470
+
471
+ pq_on_backpressure: Annotated[
472
+ Optional[OutputGrafanaCloudQueueFullBehavior2],
473
+ pydantic.Field(alias="pqOnBackpressure"),
474
+ ] = OutputGrafanaCloudQueueFullBehavior2.BLOCK
475
+ r"""How to handle events when the queue is exerting backpressure (full capacity or low disk). 'Block' is the same behavior as non-PQ blocking. 'Drop new data' throws away incoming data, while leaving the contents of the PQ unchanged."""
476
+
477
+ pq_mode: Annotated[
478
+ Optional[OutputGrafanaCloudMode2], pydantic.Field(alias="pqMode")
479
+ ] = OutputGrafanaCloudMode2.ERROR
480
+ r"""In Error mode, PQ writes events to the filesystem if the Destination is unavailable. In Backpressure mode, PQ writes events to the filesystem when it detects backpressure from the Destination. In Always On mode, PQ always writes events to the filesystem."""
481
+
482
+ pq_controls: Annotated[
483
+ Optional[OutputGrafanaCloudPqControls2], pydantic.Field(alias="pqControls")
484
+ ] = None
485
+
486
+
487
+ class OutputGrafanaCloudType1(str, Enum):
488
+ GRAFANA_CLOUD = "grafana_cloud"
489
+
490
+
491
+ class OutputGrafanaCloudMessageFormat1(str, Enum):
492
+ r"""Format to use when sending logs to Loki (Protobuf or JSON)"""
493
+
494
+ PROTOBUF = "protobuf"
495
+ JSON = "json"
496
+
497
+
498
+ class OutputGrafanaCloudLabel1TypedDict(TypedDict):
499
+ value: str
500
+ name: NotRequired[str]
501
+
502
+
503
+ class OutputGrafanaCloudLabel1(BaseModel):
504
+ value: str
505
+
506
+ name: Optional[str] = ""
507
+
508
+
509
+ class OutputGrafanaCloudPrometheusAuthAuthenticationType1(str, Enum):
510
+ NONE = "none"
511
+ TOKEN = "token"
512
+ TEXT_SECRET = "textSecret"
513
+ BASIC = "basic"
514
+ CREDENTIALS_SECRET = "credentialsSecret"
515
+
516
+
517
+ class OutputGrafanaCloudPrometheusAuth1TypedDict(TypedDict):
518
+ auth_type: NotRequired[OutputGrafanaCloudPrometheusAuthAuthenticationType1]
519
+ token: NotRequired[str]
520
+ r"""Bearer token to include in the authorization header. In Grafana Cloud, this is generally built by concatenating the username and the API key, separated by a colon. Example: <your-username>:<your-api-key>"""
521
+ text_secret: NotRequired[str]
522
+ r"""Select or create a stored text secret"""
523
+ username: NotRequired[str]
524
+ r"""Username for authentication"""
525
+ password: NotRequired[str]
526
+ r"""Password (API key in Grafana Cloud domain) for authentication"""
527
+ credentials_secret: NotRequired[str]
528
+ r"""Select or create a secret that references your credentials"""
529
+
530
+
531
+ class OutputGrafanaCloudPrometheusAuth1(BaseModel):
532
+ auth_type: Annotated[
533
+ Optional[OutputGrafanaCloudPrometheusAuthAuthenticationType1],
534
+ pydantic.Field(alias="authType"),
535
+ ] = OutputGrafanaCloudPrometheusAuthAuthenticationType1.BASIC
536
+
537
+ token: Optional[str] = None
538
+ r"""Bearer token to include in the authorization header. In Grafana Cloud, this is generally built by concatenating the username and the API key, separated by a colon. Example: <your-username>:<your-api-key>"""
539
+
540
+ text_secret: Annotated[Optional[str], pydantic.Field(alias="textSecret")] = None
541
+ r"""Select or create a stored text secret"""
542
+
543
+ username: Optional[str] = None
544
+ r"""Username for authentication"""
545
+
546
+ password: Optional[str] = None
547
+ r"""Password (API key in Grafana Cloud domain) for authentication"""
548
+
549
+ credentials_secret: Annotated[
550
+ Optional[str], pydantic.Field(alias="credentialsSecret")
551
+ ] = None
552
+ r"""Select or create a secret that references your credentials"""
553
+
554
+
555
+ class OutputGrafanaCloudLokiAuthAuthenticationType1(str, Enum):
556
+ NONE = "none"
557
+ TOKEN = "token"
558
+ TEXT_SECRET = "textSecret"
559
+ BASIC = "basic"
560
+ CREDENTIALS_SECRET = "credentialsSecret"
561
+
562
+
563
+ class OutputGrafanaCloudLokiAuth1TypedDict(TypedDict):
564
+ auth_type: NotRequired[OutputGrafanaCloudLokiAuthAuthenticationType1]
565
+ token: NotRequired[str]
566
+ r"""Bearer token to include in the authorization header. In Grafana Cloud, this is generally built by concatenating the username and the API key, separated by a colon. Example: <your-username>:<your-api-key>"""
567
+ text_secret: NotRequired[str]
568
+ r"""Select or create a stored text secret"""
569
+ username: NotRequired[str]
570
+ r"""Username for authentication"""
571
+ password: NotRequired[str]
572
+ r"""Password (API key in Grafana Cloud domain) for authentication"""
573
+ credentials_secret: NotRequired[str]
574
+ r"""Select or create a secret that references your credentials"""
575
+
576
+
577
+ class OutputGrafanaCloudLokiAuth1(BaseModel):
578
+ auth_type: Annotated[
579
+ Optional[OutputGrafanaCloudLokiAuthAuthenticationType1],
580
+ pydantic.Field(alias="authType"),
581
+ ] = OutputGrafanaCloudLokiAuthAuthenticationType1.BASIC
582
+
583
+ token: Optional[str] = None
584
+ r"""Bearer token to include in the authorization header. In Grafana Cloud, this is generally built by concatenating the username and the API key, separated by a colon. Example: <your-username>:<your-api-key>"""
585
+
586
+ text_secret: Annotated[Optional[str], pydantic.Field(alias="textSecret")] = None
587
+ r"""Select or create a stored text secret"""
588
+
589
+ username: Optional[str] = None
590
+ r"""Username for authentication"""
591
+
592
+ password: Optional[str] = None
593
+ r"""Password (API key in Grafana Cloud domain) for authentication"""
594
+
595
+ credentials_secret: Annotated[
596
+ Optional[str], pydantic.Field(alias="credentialsSecret")
597
+ ] = None
598
+ r"""Select or create a secret that references your credentials"""
599
+
600
+
601
+ class OutputGrafanaCloudExtraHTTPHeader1TypedDict(TypedDict):
602
+ value: str
603
+ name: NotRequired[str]
604
+
605
+
606
+ class OutputGrafanaCloudExtraHTTPHeader1(BaseModel):
607
+ value: str
608
+
609
+ name: Optional[str] = None
610
+
611
+
612
+ class OutputGrafanaCloudFailedRequestLoggingMode1(str, Enum):
613
+ r"""Data to log when a request fails. All headers are redacted by default, unless listed as safe headers below."""
614
+
615
+ PAYLOAD = "payload"
616
+ PAYLOAD_AND_HEADERS = "payloadAndHeaders"
617
+ NONE = "none"
618
+
619
+
620
+ class OutputGrafanaCloudResponseRetrySetting1TypedDict(TypedDict):
621
+ http_status: float
622
+ r"""The HTTP response status code that will trigger retries"""
623
+ initial_backoff: NotRequired[float]
624
+ r"""How long, in milliseconds, Cribl Stream should wait before initiating backoff. Maximum interval is 600,000 ms (10 minutes)."""
625
+ backoff_rate: NotRequired[float]
626
+ r"""Base for exponential backoff. A value of 2 (default) means Cribl Stream will retry after 2 seconds, then 4 seconds, then 8 seconds, etc."""
627
+ max_backoff: NotRequired[float]
628
+ r"""The maximum backoff interval, in milliseconds, Cribl Stream should apply. Default (and minimum) is 10,000 ms (10 seconds); maximum is 180,000 ms (180 seconds)."""
629
+
630
+
631
+ class OutputGrafanaCloudResponseRetrySetting1(BaseModel):
632
+ http_status: Annotated[float, pydantic.Field(alias="httpStatus")]
633
+ r"""The HTTP response status code that will trigger retries"""
634
+
635
+ initial_backoff: Annotated[
636
+ Optional[float], pydantic.Field(alias="initialBackoff")
637
+ ] = 1000
638
+ r"""How long, in milliseconds, Cribl Stream should wait before initiating backoff. Maximum interval is 600,000 ms (10 minutes)."""
639
+
640
+ backoff_rate: Annotated[Optional[float], pydantic.Field(alias="backoffRate")] = 2
641
+ r"""Base for exponential backoff. A value of 2 (default) means Cribl Stream will retry after 2 seconds, then 4 seconds, then 8 seconds, etc."""
642
+
643
+ max_backoff: Annotated[Optional[float], pydantic.Field(alias="maxBackoff")] = 10000
644
+ r"""The maximum backoff interval, in milliseconds, Cribl Stream should apply. Default (and minimum) is 10,000 ms (10 seconds); maximum is 180,000 ms (180 seconds)."""
645
+
646
+
647
+ class OutputGrafanaCloudTimeoutRetrySettings1TypedDict(TypedDict):
648
+ timeout_retry: NotRequired[bool]
649
+ initial_backoff: NotRequired[float]
650
+ r"""How long, in milliseconds, Cribl Stream should wait before initiating backoff. Maximum interval is 600,000 ms (10 minutes)."""
651
+ backoff_rate: NotRequired[float]
652
+ r"""Base for exponential backoff. A value of 2 (default) means Cribl Stream will retry after 2 seconds, then 4 seconds, then 8 seconds, etc."""
653
+ max_backoff: NotRequired[float]
654
+ r"""The maximum backoff interval, in milliseconds, Cribl Stream should apply. Default (and minimum) is 10,000 ms (10 seconds); maximum is 180,000 ms (180 seconds)."""
655
+
656
+
657
+ class OutputGrafanaCloudTimeoutRetrySettings1(BaseModel):
658
+ timeout_retry: Annotated[Optional[bool], pydantic.Field(alias="timeoutRetry")] = (
659
+ False
660
+ )
661
+
662
+ initial_backoff: Annotated[
663
+ Optional[float], pydantic.Field(alias="initialBackoff")
664
+ ] = 1000
665
+ r"""How long, in milliseconds, Cribl Stream should wait before initiating backoff. Maximum interval is 600,000 ms (10 minutes)."""
666
+
667
+ backoff_rate: Annotated[Optional[float], pydantic.Field(alias="backoffRate")] = 2
668
+ r"""Base for exponential backoff. A value of 2 (default) means Cribl Stream will retry after 2 seconds, then 4 seconds, then 8 seconds, etc."""
669
+
670
+ max_backoff: Annotated[Optional[float], pydantic.Field(alias="maxBackoff")] = 10000
671
+ r"""The maximum backoff interval, in milliseconds, Cribl Stream should apply. Default (and minimum) is 10,000 ms (10 seconds); maximum is 180,000 ms (180 seconds)."""
672
+
673
+
674
+ class OutputGrafanaCloudBackpressureBehavior1(str, Enum):
675
+ r"""How to handle events when all receivers are exerting backpressure"""
676
+
677
+ BLOCK = "block"
678
+ DROP = "drop"
679
+ QUEUE = "queue"
680
+
681
+
682
+ class OutputGrafanaCloudCompression1(str, Enum):
683
+ r"""Codec to use to compress the persisted data"""
684
+
685
+ NONE = "none"
686
+ GZIP = "gzip"
687
+
688
+
689
+ class OutputGrafanaCloudQueueFullBehavior1(str, Enum):
690
+ r"""How to handle events when the queue is exerting backpressure (full capacity or low disk). 'Block' is the same behavior as non-PQ blocking. 'Drop new data' throws away incoming data, while leaving the contents of the PQ unchanged."""
691
+
692
+ BLOCK = "block"
693
+ DROP = "drop"
694
+
695
+
696
+ class OutputGrafanaCloudMode1(str, Enum):
697
+ r"""In Error mode, PQ writes events to the filesystem if the Destination is unavailable. In Backpressure mode, PQ writes events to the filesystem when it detects backpressure from the Destination. In Always On mode, PQ always writes events to the filesystem."""
698
+
699
+ ERROR = "error"
700
+ BACKPRESSURE = "backpressure"
701
+ ALWAYS = "always"
702
+
703
+
704
+ class OutputGrafanaCloudPqControls1TypedDict(TypedDict):
705
+ pass
706
+
707
+
708
+ class OutputGrafanaCloudPqControls1(BaseModel):
709
+ pass
710
+
711
+
712
+ class OutputGrafanaCloudGrafanaCloud1TypedDict(TypedDict):
713
+ type: OutputGrafanaCloudType1
714
+ loki_url: str
715
+ r"""The endpoint to send logs to, such as https://logs-prod-us-central1.grafana.net"""
716
+ id: NotRequired[str]
717
+ r"""Unique ID for this output"""
718
+ pipeline: NotRequired[str]
719
+ r"""Pipeline to process data before sending out to this output"""
720
+ system_fields: NotRequired[List[str]]
721
+ r"""Fields to automatically add to events, such as cribl_pipe. Supports wildcards. These fields are added as dimensions and labels to generated metrics and logs, respectively."""
722
+ environment: NotRequired[str]
723
+ r"""Optionally, enable this config only on a specified Git branch. If empty, will be enabled everywhere."""
724
+ streamtags: NotRequired[List[str]]
725
+ r"""Tags for filtering and grouping in @{product}"""
726
+ prometheus_url: NotRequired[str]
727
+ r"""The remote_write endpoint to send Prometheus metrics to, such as https://prometheus-blocks-prod-us-central1.grafana.net/api/prom/push"""
728
+ message: NotRequired[str]
729
+ r"""Name of the event field that contains the message to send. If not specified, Stream sends a JSON representation of the whole event."""
730
+ message_format: NotRequired[OutputGrafanaCloudMessageFormat1]
731
+ r"""Format to use when sending logs to Loki (Protobuf or JSON)"""
732
+ labels: NotRequired[List[OutputGrafanaCloudLabel1TypedDict]]
733
+ r"""List of labels to send with logs. Labels define Loki streams, so use static labels to avoid proliferating label value combinations and streams. Can be merged and/or overridden by the event's __labels field. Example: '__labels: {host: \"cribl.io\", level: \"error\"}'"""
734
+ metric_rename_expr: NotRequired[str]
735
+ r"""JavaScript expression that can be used to rename metrics. For example, name.replace(/\./g, '_') will replace all '.' characters in a metric's name with the supported '_' character. Use the 'name' global variable to access the metric's name. You can access event fields' values via __e.<fieldName>."""
736
+ prometheus_auth: NotRequired[OutputGrafanaCloudPrometheusAuth1TypedDict]
737
+ loki_auth: NotRequired[OutputGrafanaCloudLokiAuth1TypedDict]
738
+ concurrency: NotRequired[float]
739
+ r"""Maximum number of ongoing requests before blocking. Warning: Setting this value > 1 can cause Loki and Prometheus to complain about entries being delivered out of order."""
740
+ max_payload_size_kb: NotRequired[float]
741
+ r"""Maximum size, in KB, of the request body. Warning: Setting this too low can increase the number of ongoing requests (depending on the value of 'Request concurrency'); this can cause Loki and Prometheus to complain about entries being delivered out of order."""
742
+ max_payload_events: NotRequired[float]
743
+ r"""Maximum number of events to include in the request body. Default is 0 (unlimited). Warning: Setting this too low can increase the number of ongoing requests (depending on the value of 'Request concurrency'); this can cause Loki and Prometheus to complain about entries being delivered out of order."""
744
+ reject_unauthorized: NotRequired[bool]
745
+ r"""Reject certificates not authorized by a CA in the CA certificate path or by another trusted CA (such as the system's).
746
+ Enabled by default. When this setting is also present in TLS Settings (Client Side),
747
+ that value will take precedence.
748
+ """
749
+ timeout_sec: NotRequired[float]
750
+ r"""Amount of time, in seconds, to wait for a request to complete before canceling it"""
751
+ flush_period_sec: NotRequired[float]
752
+ r"""Maximum time between requests. Small values could cause the payload size to be smaller than the configured Maximum time between requests. Small values can reduce the payload size below the configured 'Max record size' and 'Max events per request'. Warning: Setting this too low can increase the number of ongoing requests (depending on the value of 'Request concurrency'); this can cause Loki and Prometheus to complain about entries being delivered out of order."""
753
+ extra_http_headers: NotRequired[List[OutputGrafanaCloudExtraHTTPHeader1TypedDict]]
754
+ r"""Headers to add to all events"""
755
+ use_round_robin_dns: NotRequired[bool]
756
+ r"""Enable round-robin DNS lookup. When a DNS server returns multiple addresses, @{product} will cycle through them in the order returned. For optimal performance, consider enabling this setting for non-load balanced destinations."""
757
+ failed_request_logging_mode: NotRequired[
758
+ OutputGrafanaCloudFailedRequestLoggingMode1
759
+ ]
760
+ r"""Data to log when a request fails. All headers are redacted by default, unless listed as safe headers below."""
761
+ safe_headers: NotRequired[List[str]]
762
+ r"""List of headers that are safe to log in plain text"""
763
+ send_structured_metadata: NotRequired[bool]
764
+ r"""Add structured metadata fields from __structuredMetadata to each log. Key-value pairs must be strings."""
765
+ response_retry_settings: NotRequired[
766
+ List[OutputGrafanaCloudResponseRetrySetting1TypedDict]
767
+ ]
768
+ r"""Automatically retry after unsuccessful response status codes, such as 429 (Too Many Requests) or 503 (Service Unavailable)"""
769
+ timeout_retry_settings: NotRequired[
770
+ OutputGrafanaCloudTimeoutRetrySettings1TypedDict
771
+ ]
772
+ response_honor_retry_after_header: NotRequired[bool]
773
+ r"""Honor any Retry-After header that specifies a delay (in seconds) no longer than 180 seconds after the retry request. @{product} limits the delay to 180 seconds, even if the Retry-After header specifies a longer delay. When enabled, takes precedence over user-configured retry options. When disabled, all Retry-After headers are ignored."""
774
+ on_backpressure: NotRequired[OutputGrafanaCloudBackpressureBehavior1]
775
+ r"""How to handle events when all receivers are exerting backpressure"""
776
+ description: NotRequired[str]
777
+ compress: NotRequired[bool]
778
+ r"""Compress the payload body before sending. Applies only to JSON payloads; the Protobuf variant for both Prometheus and Loki are snappy-compressed by default."""
779
+ pq_max_file_size: NotRequired[str]
780
+ r"""The maximum size to store in each queue file before closing and optionally compressing (KB, MB, etc.)"""
781
+ pq_max_size: NotRequired[str]
782
+ r"""The maximum disk space that the queue can consume (as an average per Worker Process) before queueing stops. Enter a numeral with units of KB, MB, etc."""
783
+ pq_path: NotRequired[str]
784
+ r"""The location for the persistent queue files. To this field's value, the system will append: /<worker-id>/<output-id>."""
785
+ pq_compress: NotRequired[OutputGrafanaCloudCompression1]
786
+ r"""Codec to use to compress the persisted data"""
787
+ pq_on_backpressure: NotRequired[OutputGrafanaCloudQueueFullBehavior1]
788
+ r"""How to handle events when the queue is exerting backpressure (full capacity or low disk). 'Block' is the same behavior as non-PQ blocking. 'Drop new data' throws away incoming data, while leaving the contents of the PQ unchanged."""
789
+ pq_mode: NotRequired[OutputGrafanaCloudMode1]
790
+ r"""In Error mode, PQ writes events to the filesystem if the Destination is unavailable. In Backpressure mode, PQ writes events to the filesystem when it detects backpressure from the Destination. In Always On mode, PQ always writes events to the filesystem."""
791
+ pq_controls: NotRequired[OutputGrafanaCloudPqControls1TypedDict]
792
+
793
+
794
+ class OutputGrafanaCloudGrafanaCloud1(BaseModel):
795
+ type: OutputGrafanaCloudType1
796
+
797
+ loki_url: Annotated[str, pydantic.Field(alias="lokiUrl")]
798
+ r"""The endpoint to send logs to, such as https://logs-prod-us-central1.grafana.net"""
799
+
800
+ id: Optional[str] = None
801
+ r"""Unique ID for this output"""
802
+
803
+ pipeline: Optional[str] = None
804
+ r"""Pipeline to process data before sending out to this output"""
805
+
806
+ system_fields: Annotated[
807
+ Optional[List[str]], pydantic.Field(alias="systemFields")
808
+ ] = None
809
+ r"""Fields to automatically add to events, such as cribl_pipe. Supports wildcards. These fields are added as dimensions and labels to generated metrics and logs, respectively."""
810
+
811
+ environment: Optional[str] = None
812
+ r"""Optionally, enable this config only on a specified Git branch. If empty, will be enabled everywhere."""
813
+
814
+ streamtags: Optional[List[str]] = None
815
+ r"""Tags for filtering and grouping in @{product}"""
816
+
337
817
  prometheus_url: Annotated[Optional[str], pydantic.Field(alias="prometheusUrl")] = (
338
818
  None
339
819
  )
@@ -343,11 +823,12 @@ class OutputGrafanaCloud(BaseModel):
343
823
  r"""Name of the event field that contains the message to send. If not specified, Stream sends a JSON representation of the whole event."""
344
824
 
345
825
  message_format: Annotated[
346
- Optional[OutputGrafanaCloudMessageFormat], pydantic.Field(alias="messageFormat")
347
- ] = OutputGrafanaCloudMessageFormat.PROTOBUF
826
+ Optional[OutputGrafanaCloudMessageFormat1],
827
+ pydantic.Field(alias="messageFormat"),
828
+ ] = OutputGrafanaCloudMessageFormat1.PROTOBUF
348
829
  r"""Format to use when sending logs to Loki (Protobuf or JSON)"""
349
830
 
350
- labels: Optional[List[OutputGrafanaCloudLabel]] = None
831
+ labels: Optional[List[OutputGrafanaCloudLabel1]] = None
351
832
  r"""List of labels to send with logs. Labels define Loki streams, so use static labels to avoid proliferating label value combinations and streams. Can be merged and/or overridden by the event's __labels field. Example: '__labels: {host: \"cribl.io\", level: \"error\"}'"""
352
833
 
353
834
  metric_rename_expr: Annotated[
@@ -356,12 +837,12 @@ class OutputGrafanaCloud(BaseModel):
356
837
  r"""JavaScript expression that can be used to rename metrics. For example, name.replace(/\./g, '_') will replace all '.' characters in a metric's name with the supported '_' character. Use the 'name' global variable to access the metric's name. You can access event fields' values via __e.<fieldName>."""
357
838
 
358
839
  prometheus_auth: Annotated[
359
- Optional[OutputGrafanaCloudPrometheusAuth],
840
+ Optional[OutputGrafanaCloudPrometheusAuth1],
360
841
  pydantic.Field(alias="prometheusAuth"),
361
842
  ] = None
362
843
 
363
844
  loki_auth: Annotated[
364
- Optional[OutputGrafanaCloudLokiAuth], pydantic.Field(alias="lokiAuth")
845
+ Optional[OutputGrafanaCloudLokiAuth1], pydantic.Field(alias="lokiAuth")
365
846
  ] = None
366
847
 
367
848
  concurrency: Optional[float] = 1
@@ -394,7 +875,7 @@ class OutputGrafanaCloud(BaseModel):
394
875
  r"""Maximum time between requests. Small values could cause the payload size to be smaller than the configured Maximum time between requests. Small values can reduce the payload size below the configured 'Max record size' and 'Max events per request'. Warning: Setting this too low can increase the number of ongoing requests (depending on the value of 'Request concurrency'); this can cause Loki and Prometheus to complain about entries being delivered out of order."""
395
876
 
396
877
  extra_http_headers: Annotated[
397
- Optional[List[OutputGrafanaCloudExtraHTTPHeader]],
878
+ Optional[List[OutputGrafanaCloudExtraHTTPHeader1]],
398
879
  pydantic.Field(alias="extraHttpHeaders"),
399
880
  ] = None
400
881
  r"""Headers to add to all events"""
@@ -405,9 +886,9 @@ class OutputGrafanaCloud(BaseModel):
405
886
  r"""Enable round-robin DNS lookup. When a DNS server returns multiple addresses, @{product} will cycle through them in the order returned. For optimal performance, consider enabling this setting for non-load balanced destinations."""
406
887
 
407
888
  failed_request_logging_mode: Annotated[
408
- Optional[OutputGrafanaCloudFailedRequestLoggingMode],
889
+ Optional[OutputGrafanaCloudFailedRequestLoggingMode1],
409
890
  pydantic.Field(alias="failedRequestLoggingMode"),
410
- ] = OutputGrafanaCloudFailedRequestLoggingMode.NONE
891
+ ] = OutputGrafanaCloudFailedRequestLoggingMode1.NONE
411
892
  r"""Data to log when a request fails. All headers are redacted by default, unless listed as safe headers below."""
412
893
 
413
894
  safe_headers: Annotated[
@@ -421,13 +902,13 @@ class OutputGrafanaCloud(BaseModel):
421
902
  r"""Add structured metadata fields from __structuredMetadata to each log. Key-value pairs must be strings."""
422
903
 
423
904
  response_retry_settings: Annotated[
424
- Optional[List[OutputGrafanaCloudResponseRetrySetting]],
905
+ Optional[List[OutputGrafanaCloudResponseRetrySetting1]],
425
906
  pydantic.Field(alias="responseRetrySettings"),
426
907
  ] = None
427
908
  r"""Automatically retry after unsuccessful response status codes, such as 429 (Too Many Requests) or 503 (Service Unavailable)"""
428
909
 
429
910
  timeout_retry_settings: Annotated[
430
- Optional[OutputGrafanaCloudTimeoutRetrySettings],
911
+ Optional[OutputGrafanaCloudTimeoutRetrySettings1],
431
912
  pydantic.Field(alias="timeoutRetrySettings"),
432
913
  ] = None
433
914
 
@@ -437,9 +918,9 @@ class OutputGrafanaCloud(BaseModel):
437
918
  r"""Honor any Retry-After header that specifies a delay (in seconds) no longer than 180 seconds after the retry request. @{product} limits the delay to 180 seconds, even if the Retry-After header specifies a longer delay. When enabled, takes precedence over user-configured retry options. When disabled, all Retry-After headers are ignored."""
438
919
 
439
920
  on_backpressure: Annotated[
440
- Optional[OutputGrafanaCloudBackpressureBehavior],
921
+ Optional[OutputGrafanaCloudBackpressureBehavior1],
441
922
  pydantic.Field(alias="onBackpressure"),
442
- ] = OutputGrafanaCloudBackpressureBehavior.BLOCK
923
+ ] = OutputGrafanaCloudBackpressureBehavior1.BLOCK
443
924
  r"""How to handle events when all receivers are exerting backpressure"""
444
925
 
445
926
  description: Optional[str] = None
@@ -461,21 +942,36 @@ class OutputGrafanaCloud(BaseModel):
461
942
  r"""The location for the persistent queue files. To this field's value, the system will append: /<worker-id>/<output-id>."""
462
943
 
463
944
  pq_compress: Annotated[
464
- Optional[OutputGrafanaCloudCompression], pydantic.Field(alias="pqCompress")
465
- ] = OutputGrafanaCloudCompression.NONE
945
+ Optional[OutputGrafanaCloudCompression1], pydantic.Field(alias="pqCompress")
946
+ ] = OutputGrafanaCloudCompression1.NONE
466
947
  r"""Codec to use to compress the persisted data"""
467
948
 
468
949
  pq_on_backpressure: Annotated[
469
- Optional[OutputGrafanaCloudQueueFullBehavior],
950
+ Optional[OutputGrafanaCloudQueueFullBehavior1],
470
951
  pydantic.Field(alias="pqOnBackpressure"),
471
- ] = OutputGrafanaCloudQueueFullBehavior.BLOCK
952
+ ] = OutputGrafanaCloudQueueFullBehavior1.BLOCK
472
953
  r"""How to handle events when the queue is exerting backpressure (full capacity or low disk). 'Block' is the same behavior as non-PQ blocking. 'Drop new data' throws away incoming data, while leaving the contents of the PQ unchanged."""
473
954
 
474
955
  pq_mode: Annotated[
475
- Optional[OutputGrafanaCloudMode], pydantic.Field(alias="pqMode")
476
- ] = OutputGrafanaCloudMode.ERROR
956
+ Optional[OutputGrafanaCloudMode1], pydantic.Field(alias="pqMode")
957
+ ] = OutputGrafanaCloudMode1.ERROR
477
958
  r"""In Error mode, PQ writes events to the filesystem if the Destination is unavailable. In Backpressure mode, PQ writes events to the filesystem when it detects backpressure from the Destination. In Always On mode, PQ always writes events to the filesystem."""
478
959
 
479
960
  pq_controls: Annotated[
480
- Optional[OutputGrafanaCloudPqControls], pydantic.Field(alias="pqControls")
961
+ Optional[OutputGrafanaCloudPqControls1], pydantic.Field(alias="pqControls")
481
962
  ] = None
963
+
964
+
965
+ OutputGrafanaCloudTypedDict = TypeAliasType(
966
+ "OutputGrafanaCloudTypedDict",
967
+ Union[
968
+ OutputGrafanaCloudGrafanaCloud1TypedDict,
969
+ OutputGrafanaCloudGrafanaCloud2TypedDict,
970
+ ],
971
+ )
972
+
973
+
974
+ OutputGrafanaCloud = TypeAliasType(
975
+ "OutputGrafanaCloud",
976
+ Union[OutputGrafanaCloudGrafanaCloud1, OutputGrafanaCloudGrafanaCloud2],
977
+ )