cribl-control-plane 0.0.26a1__py3-none-any.whl → 0.0.27__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 (127) hide show
  1. cribl_control_plane/_version.py +3 -3
  2. cribl_control_plane/acl.py +203 -0
  3. cribl_control_plane/auth_sdk.py +9 -176
  4. cribl_control_plane/branches.py +335 -0
  5. cribl_control_plane/commits.py +1141 -0
  6. cribl_control_plane/commits_files.py +371 -0
  7. cribl_control_plane/configs_versions.py +189 -0
  8. cribl_control_plane/destinations.py +18 -729
  9. cribl_control_plane/destinations_pq.py +359 -0
  10. cribl_control_plane/errors/healthstatus_error.py +1 -1
  11. cribl_control_plane/groups_configs.py +17 -0
  12. cribl_control_plane/groups_sdk.py +18 -551
  13. cribl_control_plane/{healthinfo.py → health.py} +3 -1
  14. cribl_control_plane/hectokens.py +479 -0
  15. cribl_control_plane/models/__init__.py +3 -35
  16. cribl_control_plane/models/healthstatus.py +3 -3
  17. cribl_control_plane/models/inputappscope.py +5 -5
  18. cribl_control_plane/models/inputcollection.py +2 -2
  19. cribl_control_plane/models/inputconfluentcloud.py +3 -3
  20. cribl_control_plane/models/inputcribl.py +5 -5
  21. cribl_control_plane/models/inputcriblhttp.py +3 -3
  22. cribl_control_plane/models/inputcribllakehttp.py +3 -3
  23. cribl_control_plane/models/inputcriblmetrics.py +5 -5
  24. cribl_control_plane/models/inputcribltcp.py +3 -3
  25. cribl_control_plane/models/inputdatadogagent.py +3 -3
  26. cribl_control_plane/models/inputedgeprometheus.py +3 -3
  27. cribl_control_plane/models/inputelastic.py +3 -3
  28. cribl_control_plane/models/inputeventhub.py +3 -3
  29. cribl_control_plane/models/inputfile.py +5 -5
  30. cribl_control_plane/models/inputfirehose.py +3 -3
  31. cribl_control_plane/models/inputgooglepubsub.py +3 -3
  32. cribl_control_plane/models/inputgrafana.py +6 -6
  33. cribl_control_plane/models/inputhttp.py +3 -3
  34. cribl_control_plane/models/inputhttpraw.py +3 -3
  35. cribl_control_plane/models/inputjournalfiles.py +3 -3
  36. cribl_control_plane/models/inputkafka.py +3 -3
  37. cribl_control_plane/models/inputkinesis.py +3 -3
  38. cribl_control_plane/models/inputkubeevents.py +5 -5
  39. cribl_control_plane/models/inputkubelogs.py +5 -5
  40. cribl_control_plane/models/inputkubemetrics.py +5 -5
  41. cribl_control_plane/models/inputloki.py +3 -3
  42. cribl_control_plane/models/inputmodeldriventelemetry.py +3 -3
  43. cribl_control_plane/models/inputmsk.py +3 -3
  44. cribl_control_plane/models/inputnetflow.py +3 -3
  45. cribl_control_plane/models/inputoffice365mgmt.py +3 -3
  46. cribl_control_plane/models/inputoffice365msgtrace.py +3 -3
  47. cribl_control_plane/models/inputoffice365service.py +3 -3
  48. cribl_control_plane/models/inputopentelemetry.py +3 -3
  49. cribl_control_plane/models/inputprometheus.py +3 -3
  50. cribl_control_plane/models/inputprometheusrw.py +3 -3
  51. cribl_control_plane/models/inputrawudp.py +3 -3
  52. cribl_control_plane/models/inputsnmp.py +3 -3
  53. cribl_control_plane/models/inputsplunk.py +3 -3
  54. cribl_control_plane/models/inputsplunkhec.py +3 -3
  55. cribl_control_plane/models/inputsplunksearch.py +3 -3
  56. cribl_control_plane/models/inputsqs.py +3 -3
  57. cribl_control_plane/models/inputsystemmetrics.py +5 -5
  58. cribl_control_plane/models/inputsystemstate.py +5 -5
  59. cribl_control_plane/models/inputtcp.py +3 -3
  60. cribl_control_plane/models/inputtcpjson.py +3 -3
  61. cribl_control_plane/models/inputwef.py +3 -3
  62. cribl_control_plane/models/inputwindowsmetrics.py +5 -5
  63. cribl_control_plane/models/inputwiz.py +3 -3
  64. cribl_control_plane/models/inputzscalerhec.py +3 -3
  65. cribl_control_plane/models/outputazureblob.py +3 -3
  66. cribl_control_plane/models/outputazuredataexplorer.py +3 -3
  67. cribl_control_plane/models/outputazureeventhub.py +3 -3
  68. cribl_control_plane/models/outputclickhouse.py +3 -3
  69. cribl_control_plane/models/outputcloudwatch.py +3 -3
  70. cribl_control_plane/models/outputconfluentcloud.py +3 -3
  71. cribl_control_plane/models/outputcriblhttp.py +5 -5
  72. cribl_control_plane/models/outputcribllake.py +5 -5
  73. cribl_control_plane/models/outputcribltcp.py +5 -5
  74. cribl_control_plane/models/outputcrowdstrikenextgensiem.py +3 -3
  75. cribl_control_plane/models/outputdatadog.py +5 -5
  76. cribl_control_plane/models/outputdataset.py +5 -5
  77. cribl_control_plane/models/outputdevnull.py +5 -5
  78. cribl_control_plane/models/outputdiskspool.py +5 -5
  79. cribl_control_plane/models/outputdls3.py +3 -3
  80. cribl_control_plane/models/outputdynatracehttp.py +3 -3
  81. cribl_control_plane/models/outputdynatraceotlp.py +3 -3
  82. cribl_control_plane/models/outputelasticcloud.py +3 -3
  83. cribl_control_plane/models/outputexabeam.py +3 -3
  84. cribl_control_plane/models/outputgooglecloudlogging.py +3 -3
  85. cribl_control_plane/models/outputgooglecloudstorage.py +3 -3
  86. cribl_control_plane/models/outputgrafanacloud.py +10 -10
  87. cribl_control_plane/models/outputgraphite.py +3 -3
  88. cribl_control_plane/models/outputhumiohec.py +3 -3
  89. cribl_control_plane/models/outputkafka.py +3 -3
  90. cribl_control_plane/models/outputkinesis.py +3 -3
  91. cribl_control_plane/models/outputminio.py +3 -3
  92. cribl_control_plane/models/outputmsk.py +3 -3
  93. cribl_control_plane/models/outputnewrelic.py +5 -5
  94. cribl_control_plane/models/outputnewrelicevents.py +3 -3
  95. cribl_control_plane/models/outputring.py +5 -5
  96. cribl_control_plane/models/outputs3.py +3 -3
  97. cribl_control_plane/models/outputsecuritylake.py +3 -3
  98. cribl_control_plane/models/outputsentinel.py +3 -3
  99. cribl_control_plane/models/outputsentineloneaisiem.py +3 -3
  100. cribl_control_plane/models/outputservicenow.py +3 -3
  101. cribl_control_plane/models/outputsns.py +3 -3
  102. cribl_control_plane/models/outputsplunk.py +3 -3
  103. cribl_control_plane/models/outputsplunkhec.py +5 -5
  104. cribl_control_plane/models/outputsqs.py +3 -3
  105. cribl_control_plane/models/outputstatsd.py +3 -3
  106. cribl_control_plane/models/outputstatsdext.py +3 -3
  107. cribl_control_plane/models/outputsyslog.py +5 -5
  108. cribl_control_plane/models/outputtcpjson.py +5 -5
  109. cribl_control_plane/models/outputwebhook.py +5 -5
  110. cribl_control_plane/models/outputxsiam.py +5 -5
  111. cribl_control_plane/nodes.py +90 -68
  112. cribl_control_plane/samples.py +391 -0
  113. cribl_control_plane/sdk.py +11 -17
  114. cribl_control_plane/sources.py +15 -469
  115. cribl_control_plane/{workers_sdk.py → statuses.py} +23 -25
  116. cribl_control_plane/{deployments.py → summaries.py} +3 -3
  117. cribl_control_plane/teams.py +201 -0
  118. cribl_control_plane/tokens.py +182 -0
  119. cribl_control_plane/versions.py +26 -0
  120. cribl_control_plane/versions_configs.py +171 -0
  121. {cribl_control_plane-0.0.26a1.dist-info → cribl_control_plane-0.0.27.dist-info}/METADATA +67 -36
  122. {cribl_control_plane-0.0.26a1.dist-info → cribl_control_plane-0.0.27.dist-info}/RECORD +123 -114
  123. cribl_control_plane/models/createversionsyncop.py +0 -23
  124. cribl_control_plane/models/restartresponse.py +0 -26
  125. cribl_control_plane/models/updateworkersrestartop.py +0 -24
  126. cribl_control_plane/versioning.py +0 -2309
  127. {cribl_control_plane-0.0.26a1.dist-info → cribl_control_plane-0.0.27.dist-info}/WHEEL +0 -0
@@ -0,0 +1,335 @@
1
+ """Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT."""
2
+
3
+ from .basesdk import BaseSDK
4
+ from cribl_control_plane import errors, models, utils
5
+ from cribl_control_plane._hooks import HookContext
6
+ from cribl_control_plane.types import OptionalNullable, UNSET
7
+ from cribl_control_plane.utils import get_security_from_env
8
+ from cribl_control_plane.utils.unmarshal_json_response import unmarshal_json_response
9
+ from typing import Any, Mapping, Optional
10
+
11
+
12
+ class Branches(BaseSDK):
13
+ def list(
14
+ self,
15
+ *,
16
+ retries: OptionalNullable[utils.RetryConfig] = UNSET,
17
+ server_url: Optional[str] = None,
18
+ timeout_ms: Optional[int] = None,
19
+ http_headers: Optional[Mapping[str, str]] = None,
20
+ ) -> models.GetVersionBranchResponse:
21
+ r"""List all branches in the Git repository used for Cribl configuration
22
+
23
+ get the list of branches
24
+
25
+ :param retries: Override the default retry configuration for this method
26
+ :param server_url: Override the default server URL for this method
27
+ :param timeout_ms: Override the default request timeout configuration for this method in milliseconds
28
+ :param http_headers: Additional headers to set or replace on requests.
29
+ """
30
+ base_url = None
31
+ url_variables = None
32
+ if timeout_ms is None:
33
+ timeout_ms = self.sdk_configuration.timeout_ms
34
+
35
+ if server_url is not None:
36
+ base_url = server_url
37
+ else:
38
+ base_url = self._get_url(base_url, url_variables)
39
+ req = self._build_request(
40
+ method="GET",
41
+ path="/version/branch",
42
+ base_url=base_url,
43
+ url_variables=url_variables,
44
+ request=None,
45
+ request_body_required=False,
46
+ request_has_path_params=False,
47
+ request_has_query_params=True,
48
+ user_agent_header="user-agent",
49
+ accept_header_value="application/json",
50
+ http_headers=http_headers,
51
+ security=self.sdk_configuration.security,
52
+ timeout_ms=timeout_ms,
53
+ )
54
+
55
+ if retries == UNSET:
56
+ if self.sdk_configuration.retry_config is not UNSET:
57
+ retries = self.sdk_configuration.retry_config
58
+
59
+ retry_config = None
60
+ if isinstance(retries, utils.RetryConfig):
61
+ retry_config = (retries, ["429", "500", "502", "503", "504"])
62
+
63
+ http_res = self.do_request(
64
+ hook_ctx=HookContext(
65
+ config=self.sdk_configuration,
66
+ base_url=base_url or "",
67
+ operation_id="getVersionBranch",
68
+ oauth2_scopes=[],
69
+ security_source=get_security_from_env(
70
+ self.sdk_configuration.security, models.Security
71
+ ),
72
+ ),
73
+ request=req,
74
+ error_status_codes=["401", "4XX", "500", "5XX"],
75
+ retry_config=retry_config,
76
+ )
77
+
78
+ response_data: Any = None
79
+ if utils.match_response(http_res, "200", "application/json"):
80
+ return unmarshal_json_response(models.GetVersionBranchResponse, http_res)
81
+ if utils.match_response(http_res, "500", "application/json"):
82
+ response_data = unmarshal_json_response(errors.ErrorData, http_res)
83
+ raise errors.Error(response_data, http_res)
84
+ if utils.match_response(http_res, ["401", "4XX"], "*"):
85
+ http_res_text = utils.stream_to_text(http_res)
86
+ raise errors.APIError("API error occurred", http_res, http_res_text)
87
+ if utils.match_response(http_res, "5XX", "*"):
88
+ http_res_text = utils.stream_to_text(http_res)
89
+ raise errors.APIError("API error occurred", http_res, http_res_text)
90
+
91
+ raise errors.APIError("Unexpected response received", http_res)
92
+
93
+ async def list_async(
94
+ self,
95
+ *,
96
+ retries: OptionalNullable[utils.RetryConfig] = UNSET,
97
+ server_url: Optional[str] = None,
98
+ timeout_ms: Optional[int] = None,
99
+ http_headers: Optional[Mapping[str, str]] = None,
100
+ ) -> models.GetVersionBranchResponse:
101
+ r"""List all branches in the Git repository used for Cribl configuration
102
+
103
+ get the list of branches
104
+
105
+ :param retries: Override the default retry configuration for this method
106
+ :param server_url: Override the default server URL for this method
107
+ :param timeout_ms: Override the default request timeout configuration for this method in milliseconds
108
+ :param http_headers: Additional headers to set or replace on requests.
109
+ """
110
+ base_url = None
111
+ url_variables = None
112
+ if timeout_ms is None:
113
+ timeout_ms = self.sdk_configuration.timeout_ms
114
+
115
+ if server_url is not None:
116
+ base_url = server_url
117
+ else:
118
+ base_url = self._get_url(base_url, url_variables)
119
+ req = self._build_request_async(
120
+ method="GET",
121
+ path="/version/branch",
122
+ base_url=base_url,
123
+ url_variables=url_variables,
124
+ request=None,
125
+ request_body_required=False,
126
+ request_has_path_params=False,
127
+ request_has_query_params=True,
128
+ user_agent_header="user-agent",
129
+ accept_header_value="application/json",
130
+ http_headers=http_headers,
131
+ security=self.sdk_configuration.security,
132
+ timeout_ms=timeout_ms,
133
+ )
134
+
135
+ if retries == UNSET:
136
+ if self.sdk_configuration.retry_config is not UNSET:
137
+ retries = self.sdk_configuration.retry_config
138
+
139
+ retry_config = None
140
+ if isinstance(retries, utils.RetryConfig):
141
+ retry_config = (retries, ["429", "500", "502", "503", "504"])
142
+
143
+ http_res = await self.do_request_async(
144
+ hook_ctx=HookContext(
145
+ config=self.sdk_configuration,
146
+ base_url=base_url or "",
147
+ operation_id="getVersionBranch",
148
+ oauth2_scopes=[],
149
+ security_source=get_security_from_env(
150
+ self.sdk_configuration.security, models.Security
151
+ ),
152
+ ),
153
+ request=req,
154
+ error_status_codes=["401", "4XX", "500", "5XX"],
155
+ retry_config=retry_config,
156
+ )
157
+
158
+ response_data: Any = None
159
+ if utils.match_response(http_res, "200", "application/json"):
160
+ return unmarshal_json_response(models.GetVersionBranchResponse, http_res)
161
+ if utils.match_response(http_res, "500", "application/json"):
162
+ response_data = unmarshal_json_response(errors.ErrorData, http_res)
163
+ raise errors.Error(response_data, http_res)
164
+ if utils.match_response(http_res, ["401", "4XX"], "*"):
165
+ http_res_text = await utils.stream_to_text_async(http_res)
166
+ raise errors.APIError("API error occurred", http_res, http_res_text)
167
+ if utils.match_response(http_res, "5XX", "*"):
168
+ http_res_text = await utils.stream_to_text_async(http_res)
169
+ raise errors.APIError("API error occurred", http_res, http_res_text)
170
+
171
+ raise errors.APIError("Unexpected response received", http_res)
172
+
173
+ def get(
174
+ self,
175
+ *,
176
+ retries: OptionalNullable[utils.RetryConfig] = UNSET,
177
+ server_url: Optional[str] = None,
178
+ timeout_ms: Optional[int] = None,
179
+ http_headers: Optional[Mapping[str, str]] = None,
180
+ ) -> models.GetVersionCurrentBranchResponse:
181
+ r"""Retrieve the name of the Git branch that the Cribl configuration is checked out to
182
+
183
+ returns git branch that the config is checked out to, if any
184
+
185
+ :param retries: Override the default retry configuration for this method
186
+ :param server_url: Override the default server URL for this method
187
+ :param timeout_ms: Override the default request timeout configuration for this method in milliseconds
188
+ :param http_headers: Additional headers to set or replace on requests.
189
+ """
190
+ base_url = None
191
+ url_variables = None
192
+ if timeout_ms is None:
193
+ timeout_ms = self.sdk_configuration.timeout_ms
194
+
195
+ if server_url is not None:
196
+ base_url = server_url
197
+ else:
198
+ base_url = self._get_url(base_url, url_variables)
199
+ req = self._build_request(
200
+ method="GET",
201
+ path="/version/current-branch",
202
+ base_url=base_url,
203
+ url_variables=url_variables,
204
+ request=None,
205
+ request_body_required=False,
206
+ request_has_path_params=False,
207
+ request_has_query_params=True,
208
+ user_agent_header="user-agent",
209
+ accept_header_value="application/json",
210
+ http_headers=http_headers,
211
+ security=self.sdk_configuration.security,
212
+ timeout_ms=timeout_ms,
213
+ )
214
+
215
+ if retries == UNSET:
216
+ if self.sdk_configuration.retry_config is not UNSET:
217
+ retries = self.sdk_configuration.retry_config
218
+
219
+ retry_config = None
220
+ if isinstance(retries, utils.RetryConfig):
221
+ retry_config = (retries, ["429", "500", "502", "503", "504"])
222
+
223
+ http_res = self.do_request(
224
+ hook_ctx=HookContext(
225
+ config=self.sdk_configuration,
226
+ base_url=base_url or "",
227
+ operation_id="getVersionCurrentBranch",
228
+ oauth2_scopes=[],
229
+ security_source=get_security_from_env(
230
+ self.sdk_configuration.security, models.Security
231
+ ),
232
+ ),
233
+ request=req,
234
+ error_status_codes=["401", "4XX", "500", "5XX"],
235
+ retry_config=retry_config,
236
+ )
237
+
238
+ response_data: Any = None
239
+ if utils.match_response(http_res, "200", "application/json"):
240
+ return unmarshal_json_response(
241
+ models.GetVersionCurrentBranchResponse, http_res
242
+ )
243
+ if utils.match_response(http_res, "500", "application/json"):
244
+ response_data = unmarshal_json_response(errors.ErrorData, http_res)
245
+ raise errors.Error(response_data, http_res)
246
+ if utils.match_response(http_res, ["401", "4XX"], "*"):
247
+ http_res_text = utils.stream_to_text(http_res)
248
+ raise errors.APIError("API error occurred", http_res, http_res_text)
249
+ if utils.match_response(http_res, "5XX", "*"):
250
+ http_res_text = utils.stream_to_text(http_res)
251
+ raise errors.APIError("API error occurred", http_res, http_res_text)
252
+
253
+ raise errors.APIError("Unexpected response received", http_res)
254
+
255
+ async def get_async(
256
+ self,
257
+ *,
258
+ retries: OptionalNullable[utils.RetryConfig] = UNSET,
259
+ server_url: Optional[str] = None,
260
+ timeout_ms: Optional[int] = None,
261
+ http_headers: Optional[Mapping[str, str]] = None,
262
+ ) -> models.GetVersionCurrentBranchResponse:
263
+ r"""Retrieve the name of the Git branch that the Cribl configuration is checked out to
264
+
265
+ returns git branch that the config is checked out to, if any
266
+
267
+ :param retries: Override the default retry configuration for this method
268
+ :param server_url: Override the default server URL for this method
269
+ :param timeout_ms: Override the default request timeout configuration for this method in milliseconds
270
+ :param http_headers: Additional headers to set or replace on requests.
271
+ """
272
+ base_url = None
273
+ url_variables = None
274
+ if timeout_ms is None:
275
+ timeout_ms = self.sdk_configuration.timeout_ms
276
+
277
+ if server_url is not None:
278
+ base_url = server_url
279
+ else:
280
+ base_url = self._get_url(base_url, url_variables)
281
+ req = self._build_request_async(
282
+ method="GET",
283
+ path="/version/current-branch",
284
+ base_url=base_url,
285
+ url_variables=url_variables,
286
+ request=None,
287
+ request_body_required=False,
288
+ request_has_path_params=False,
289
+ request_has_query_params=True,
290
+ user_agent_header="user-agent",
291
+ accept_header_value="application/json",
292
+ http_headers=http_headers,
293
+ security=self.sdk_configuration.security,
294
+ timeout_ms=timeout_ms,
295
+ )
296
+
297
+ if retries == UNSET:
298
+ if self.sdk_configuration.retry_config is not UNSET:
299
+ retries = self.sdk_configuration.retry_config
300
+
301
+ retry_config = None
302
+ if isinstance(retries, utils.RetryConfig):
303
+ retry_config = (retries, ["429", "500", "502", "503", "504"])
304
+
305
+ http_res = await self.do_request_async(
306
+ hook_ctx=HookContext(
307
+ config=self.sdk_configuration,
308
+ base_url=base_url or "",
309
+ operation_id="getVersionCurrentBranch",
310
+ oauth2_scopes=[],
311
+ security_source=get_security_from_env(
312
+ self.sdk_configuration.security, models.Security
313
+ ),
314
+ ),
315
+ request=req,
316
+ error_status_codes=["401", "4XX", "500", "5XX"],
317
+ retry_config=retry_config,
318
+ )
319
+
320
+ response_data: Any = None
321
+ if utils.match_response(http_res, "200", "application/json"):
322
+ return unmarshal_json_response(
323
+ models.GetVersionCurrentBranchResponse, http_res
324
+ )
325
+ if utils.match_response(http_res, "500", "application/json"):
326
+ response_data = unmarshal_json_response(errors.ErrorData, http_res)
327
+ raise errors.Error(response_data, http_res)
328
+ if utils.match_response(http_res, ["401", "4XX"], "*"):
329
+ http_res_text = await utils.stream_to_text_async(http_res)
330
+ raise errors.APIError("API error occurred", http_res, http_res_text)
331
+ if utils.match_response(http_res, "5XX", "*"):
332
+ http_res_text = await utils.stream_to_text_async(http_res)
333
+ raise errors.APIError("API error occurred", http_res, http_res_text)
334
+
335
+ raise errors.APIError("Unexpected response received", http_res)