windmill-api 1.421.2__py3-none-any.whl → 1.422.1__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 windmill-api might be problematic. Click here for more details.
- windmill_api/api/setting/acknowledge_all_critical_alerts.py +120 -0
- windmill_api/api/setting/acknowledge_critical_alert.py +146 -0
- windmill_api/api/setting/get_critical_alerts.py +204 -0
- windmill_api/models/critical_alert.py +101 -0
- windmill_api/models/get_critical_alerts_response_200_item.py +101 -0
- {windmill_api-1.421.2.dist-info → windmill_api-1.422.1.dist-info}/METADATA +1 -1
- {windmill_api-1.421.2.dist-info → windmill_api-1.422.1.dist-info}/RECORD +9 -4
- {windmill_api-1.421.2.dist-info → windmill_api-1.422.1.dist-info}/LICENSE +0 -0
- {windmill_api-1.421.2.dist-info → windmill_api-1.422.1.dist-info}/WHEEL +0 -0
|
@@ -0,0 +1,120 @@
|
|
|
1
|
+
from http import HTTPStatus
|
|
2
|
+
from typing import Any, Dict, Optional, Union, cast
|
|
3
|
+
|
|
4
|
+
import httpx
|
|
5
|
+
|
|
6
|
+
from ... import errors
|
|
7
|
+
from ...client import AuthenticatedClient, Client
|
|
8
|
+
from ...types import Response
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
def _get_kwargs() -> Dict[str, Any]:
|
|
12
|
+
pass
|
|
13
|
+
|
|
14
|
+
return {
|
|
15
|
+
"method": "post",
|
|
16
|
+
"url": "/settings/critical_alerts/acknowledge_all",
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
|
|
20
|
+
def _parse_response(*, client: Union[AuthenticatedClient, Client], response: httpx.Response) -> Optional[str]:
|
|
21
|
+
if response.status_code == HTTPStatus.OK:
|
|
22
|
+
response_200 = cast(str, response.json())
|
|
23
|
+
return response_200
|
|
24
|
+
if client.raise_on_unexpected_status:
|
|
25
|
+
raise errors.UnexpectedStatus(response.status_code, response.content)
|
|
26
|
+
else:
|
|
27
|
+
return None
|
|
28
|
+
|
|
29
|
+
|
|
30
|
+
def _build_response(*, client: Union[AuthenticatedClient, Client], response: httpx.Response) -> Response[str]:
|
|
31
|
+
return Response(
|
|
32
|
+
status_code=HTTPStatus(response.status_code),
|
|
33
|
+
content=response.content,
|
|
34
|
+
headers=response.headers,
|
|
35
|
+
parsed=_parse_response(client=client, response=response),
|
|
36
|
+
)
|
|
37
|
+
|
|
38
|
+
|
|
39
|
+
def sync_detailed(
|
|
40
|
+
*,
|
|
41
|
+
client: Union[AuthenticatedClient, Client],
|
|
42
|
+
) -> Response[str]:
|
|
43
|
+
"""Acknowledge all unacknowledged critical alerts
|
|
44
|
+
|
|
45
|
+
Raises:
|
|
46
|
+
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
47
|
+
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
48
|
+
|
|
49
|
+
Returns:
|
|
50
|
+
Response[str]
|
|
51
|
+
"""
|
|
52
|
+
|
|
53
|
+
kwargs = _get_kwargs()
|
|
54
|
+
|
|
55
|
+
response = client.get_httpx_client().request(
|
|
56
|
+
**kwargs,
|
|
57
|
+
)
|
|
58
|
+
|
|
59
|
+
return _build_response(client=client, response=response)
|
|
60
|
+
|
|
61
|
+
|
|
62
|
+
def sync(
|
|
63
|
+
*,
|
|
64
|
+
client: Union[AuthenticatedClient, Client],
|
|
65
|
+
) -> Optional[str]:
|
|
66
|
+
"""Acknowledge all unacknowledged critical alerts
|
|
67
|
+
|
|
68
|
+
Raises:
|
|
69
|
+
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
70
|
+
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
71
|
+
|
|
72
|
+
Returns:
|
|
73
|
+
str
|
|
74
|
+
"""
|
|
75
|
+
|
|
76
|
+
return sync_detailed(
|
|
77
|
+
client=client,
|
|
78
|
+
).parsed
|
|
79
|
+
|
|
80
|
+
|
|
81
|
+
async def asyncio_detailed(
|
|
82
|
+
*,
|
|
83
|
+
client: Union[AuthenticatedClient, Client],
|
|
84
|
+
) -> Response[str]:
|
|
85
|
+
"""Acknowledge all unacknowledged critical alerts
|
|
86
|
+
|
|
87
|
+
Raises:
|
|
88
|
+
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
89
|
+
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
90
|
+
|
|
91
|
+
Returns:
|
|
92
|
+
Response[str]
|
|
93
|
+
"""
|
|
94
|
+
|
|
95
|
+
kwargs = _get_kwargs()
|
|
96
|
+
|
|
97
|
+
response = await client.get_async_httpx_client().request(**kwargs)
|
|
98
|
+
|
|
99
|
+
return _build_response(client=client, response=response)
|
|
100
|
+
|
|
101
|
+
|
|
102
|
+
async def asyncio(
|
|
103
|
+
*,
|
|
104
|
+
client: Union[AuthenticatedClient, Client],
|
|
105
|
+
) -> Optional[str]:
|
|
106
|
+
"""Acknowledge all unacknowledged critical alerts
|
|
107
|
+
|
|
108
|
+
Raises:
|
|
109
|
+
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
110
|
+
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
111
|
+
|
|
112
|
+
Returns:
|
|
113
|
+
str
|
|
114
|
+
"""
|
|
115
|
+
|
|
116
|
+
return (
|
|
117
|
+
await asyncio_detailed(
|
|
118
|
+
client=client,
|
|
119
|
+
)
|
|
120
|
+
).parsed
|
|
@@ -0,0 +1,146 @@
|
|
|
1
|
+
from http import HTTPStatus
|
|
2
|
+
from typing import Any, Dict, Optional, Union, cast
|
|
3
|
+
|
|
4
|
+
import httpx
|
|
5
|
+
|
|
6
|
+
from ... import errors
|
|
7
|
+
from ...client import AuthenticatedClient, Client
|
|
8
|
+
from ...types import Response
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
def _get_kwargs(
|
|
12
|
+
id: int,
|
|
13
|
+
) -> Dict[str, Any]:
|
|
14
|
+
pass
|
|
15
|
+
|
|
16
|
+
return {
|
|
17
|
+
"method": "post",
|
|
18
|
+
"url": "/settings/critical_alerts/{id}/acknowledge".format(
|
|
19
|
+
id=id,
|
|
20
|
+
),
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
|
|
24
|
+
def _parse_response(*, client: Union[AuthenticatedClient, Client], response: httpx.Response) -> Optional[str]:
|
|
25
|
+
if response.status_code == HTTPStatus.OK:
|
|
26
|
+
response_200 = cast(str, response.json())
|
|
27
|
+
return response_200
|
|
28
|
+
if client.raise_on_unexpected_status:
|
|
29
|
+
raise errors.UnexpectedStatus(response.status_code, response.content)
|
|
30
|
+
else:
|
|
31
|
+
return None
|
|
32
|
+
|
|
33
|
+
|
|
34
|
+
def _build_response(*, client: Union[AuthenticatedClient, Client], response: httpx.Response) -> Response[str]:
|
|
35
|
+
return Response(
|
|
36
|
+
status_code=HTTPStatus(response.status_code),
|
|
37
|
+
content=response.content,
|
|
38
|
+
headers=response.headers,
|
|
39
|
+
parsed=_parse_response(client=client, response=response),
|
|
40
|
+
)
|
|
41
|
+
|
|
42
|
+
|
|
43
|
+
def sync_detailed(
|
|
44
|
+
id: int,
|
|
45
|
+
*,
|
|
46
|
+
client: Union[AuthenticatedClient, Client],
|
|
47
|
+
) -> Response[str]:
|
|
48
|
+
"""Acknowledge a critical alert
|
|
49
|
+
|
|
50
|
+
Args:
|
|
51
|
+
id (int):
|
|
52
|
+
|
|
53
|
+
Raises:
|
|
54
|
+
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
55
|
+
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
56
|
+
|
|
57
|
+
Returns:
|
|
58
|
+
Response[str]
|
|
59
|
+
"""
|
|
60
|
+
|
|
61
|
+
kwargs = _get_kwargs(
|
|
62
|
+
id=id,
|
|
63
|
+
)
|
|
64
|
+
|
|
65
|
+
response = client.get_httpx_client().request(
|
|
66
|
+
**kwargs,
|
|
67
|
+
)
|
|
68
|
+
|
|
69
|
+
return _build_response(client=client, response=response)
|
|
70
|
+
|
|
71
|
+
|
|
72
|
+
def sync(
|
|
73
|
+
id: int,
|
|
74
|
+
*,
|
|
75
|
+
client: Union[AuthenticatedClient, Client],
|
|
76
|
+
) -> Optional[str]:
|
|
77
|
+
"""Acknowledge a critical alert
|
|
78
|
+
|
|
79
|
+
Args:
|
|
80
|
+
id (int):
|
|
81
|
+
|
|
82
|
+
Raises:
|
|
83
|
+
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
84
|
+
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
85
|
+
|
|
86
|
+
Returns:
|
|
87
|
+
str
|
|
88
|
+
"""
|
|
89
|
+
|
|
90
|
+
return sync_detailed(
|
|
91
|
+
id=id,
|
|
92
|
+
client=client,
|
|
93
|
+
).parsed
|
|
94
|
+
|
|
95
|
+
|
|
96
|
+
async def asyncio_detailed(
|
|
97
|
+
id: int,
|
|
98
|
+
*,
|
|
99
|
+
client: Union[AuthenticatedClient, Client],
|
|
100
|
+
) -> Response[str]:
|
|
101
|
+
"""Acknowledge a critical alert
|
|
102
|
+
|
|
103
|
+
Args:
|
|
104
|
+
id (int):
|
|
105
|
+
|
|
106
|
+
Raises:
|
|
107
|
+
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
108
|
+
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
109
|
+
|
|
110
|
+
Returns:
|
|
111
|
+
Response[str]
|
|
112
|
+
"""
|
|
113
|
+
|
|
114
|
+
kwargs = _get_kwargs(
|
|
115
|
+
id=id,
|
|
116
|
+
)
|
|
117
|
+
|
|
118
|
+
response = await client.get_async_httpx_client().request(**kwargs)
|
|
119
|
+
|
|
120
|
+
return _build_response(client=client, response=response)
|
|
121
|
+
|
|
122
|
+
|
|
123
|
+
async def asyncio(
|
|
124
|
+
id: int,
|
|
125
|
+
*,
|
|
126
|
+
client: Union[AuthenticatedClient, Client],
|
|
127
|
+
) -> Optional[str]:
|
|
128
|
+
"""Acknowledge a critical alert
|
|
129
|
+
|
|
130
|
+
Args:
|
|
131
|
+
id (int):
|
|
132
|
+
|
|
133
|
+
Raises:
|
|
134
|
+
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
135
|
+
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
136
|
+
|
|
137
|
+
Returns:
|
|
138
|
+
str
|
|
139
|
+
"""
|
|
140
|
+
|
|
141
|
+
return (
|
|
142
|
+
await asyncio_detailed(
|
|
143
|
+
id=id,
|
|
144
|
+
client=client,
|
|
145
|
+
)
|
|
146
|
+
).parsed
|
|
@@ -0,0 +1,204 @@
|
|
|
1
|
+
from http import HTTPStatus
|
|
2
|
+
from typing import Any, Dict, List, Optional, Union
|
|
3
|
+
|
|
4
|
+
import httpx
|
|
5
|
+
|
|
6
|
+
from ... import errors
|
|
7
|
+
from ...client import AuthenticatedClient, Client
|
|
8
|
+
from ...models.get_critical_alerts_response_200_item import GetCriticalAlertsResponse200Item
|
|
9
|
+
from ...types import UNSET, Response, Unset
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
def _get_kwargs(
|
|
13
|
+
*,
|
|
14
|
+
page: Union[Unset, None, int] = 1,
|
|
15
|
+
page_size: Union[Unset, None, int] = 10,
|
|
16
|
+
acknowledged: Union[Unset, None, bool] = UNSET,
|
|
17
|
+
) -> Dict[str, Any]:
|
|
18
|
+
pass
|
|
19
|
+
|
|
20
|
+
params: Dict[str, Any] = {}
|
|
21
|
+
params["page"] = page
|
|
22
|
+
|
|
23
|
+
params["page_size"] = page_size
|
|
24
|
+
|
|
25
|
+
params["acknowledged"] = acknowledged
|
|
26
|
+
|
|
27
|
+
params = {k: v for k, v in params.items() if v is not UNSET and v is not None}
|
|
28
|
+
|
|
29
|
+
return {
|
|
30
|
+
"method": "get",
|
|
31
|
+
"url": "/settings/critical_alerts",
|
|
32
|
+
"params": params,
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
|
|
36
|
+
def _parse_response(
|
|
37
|
+
*, client: Union[AuthenticatedClient, Client], response: httpx.Response
|
|
38
|
+
) -> Optional[List["GetCriticalAlertsResponse200Item"]]:
|
|
39
|
+
if response.status_code == HTTPStatus.OK:
|
|
40
|
+
response_200 = []
|
|
41
|
+
_response_200 = response.json()
|
|
42
|
+
for response_200_item_data in _response_200:
|
|
43
|
+
response_200_item = GetCriticalAlertsResponse200Item.from_dict(response_200_item_data)
|
|
44
|
+
|
|
45
|
+
response_200.append(response_200_item)
|
|
46
|
+
|
|
47
|
+
return response_200
|
|
48
|
+
if client.raise_on_unexpected_status:
|
|
49
|
+
raise errors.UnexpectedStatus(response.status_code, response.content)
|
|
50
|
+
else:
|
|
51
|
+
return None
|
|
52
|
+
|
|
53
|
+
|
|
54
|
+
def _build_response(
|
|
55
|
+
*, client: Union[AuthenticatedClient, Client], response: httpx.Response
|
|
56
|
+
) -> Response[List["GetCriticalAlertsResponse200Item"]]:
|
|
57
|
+
return Response(
|
|
58
|
+
status_code=HTTPStatus(response.status_code),
|
|
59
|
+
content=response.content,
|
|
60
|
+
headers=response.headers,
|
|
61
|
+
parsed=_parse_response(client=client, response=response),
|
|
62
|
+
)
|
|
63
|
+
|
|
64
|
+
|
|
65
|
+
def sync_detailed(
|
|
66
|
+
*,
|
|
67
|
+
client: Union[AuthenticatedClient, Client],
|
|
68
|
+
page: Union[Unset, None, int] = 1,
|
|
69
|
+
page_size: Union[Unset, None, int] = 10,
|
|
70
|
+
acknowledged: Union[Unset, None, bool] = UNSET,
|
|
71
|
+
) -> Response[List["GetCriticalAlertsResponse200Item"]]:
|
|
72
|
+
"""Get all critical alerts
|
|
73
|
+
|
|
74
|
+
Args:
|
|
75
|
+
page (Union[Unset, None, int]): The page number to retrieve (minimum value is 1) Default:
|
|
76
|
+
1.
|
|
77
|
+
page_size (Union[Unset, None, int]): Number of alerts per page (maximum is 100) Default:
|
|
78
|
+
10.
|
|
79
|
+
acknowledged (Union[Unset, None, bool]): Filter by acknowledgment status; true for
|
|
80
|
+
acknowledged, false for unacknowledged, and omit for all alerts
|
|
81
|
+
|
|
82
|
+
Raises:
|
|
83
|
+
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
84
|
+
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
85
|
+
|
|
86
|
+
Returns:
|
|
87
|
+
Response[List['GetCriticalAlertsResponse200Item']]
|
|
88
|
+
"""
|
|
89
|
+
|
|
90
|
+
kwargs = _get_kwargs(
|
|
91
|
+
page=page,
|
|
92
|
+
page_size=page_size,
|
|
93
|
+
acknowledged=acknowledged,
|
|
94
|
+
)
|
|
95
|
+
|
|
96
|
+
response = client.get_httpx_client().request(
|
|
97
|
+
**kwargs,
|
|
98
|
+
)
|
|
99
|
+
|
|
100
|
+
return _build_response(client=client, response=response)
|
|
101
|
+
|
|
102
|
+
|
|
103
|
+
def sync(
|
|
104
|
+
*,
|
|
105
|
+
client: Union[AuthenticatedClient, Client],
|
|
106
|
+
page: Union[Unset, None, int] = 1,
|
|
107
|
+
page_size: Union[Unset, None, int] = 10,
|
|
108
|
+
acknowledged: Union[Unset, None, bool] = UNSET,
|
|
109
|
+
) -> Optional[List["GetCriticalAlertsResponse200Item"]]:
|
|
110
|
+
"""Get all critical alerts
|
|
111
|
+
|
|
112
|
+
Args:
|
|
113
|
+
page (Union[Unset, None, int]): The page number to retrieve (minimum value is 1) Default:
|
|
114
|
+
1.
|
|
115
|
+
page_size (Union[Unset, None, int]): Number of alerts per page (maximum is 100) Default:
|
|
116
|
+
10.
|
|
117
|
+
acknowledged (Union[Unset, None, bool]): Filter by acknowledgment status; true for
|
|
118
|
+
acknowledged, false for unacknowledged, and omit for all alerts
|
|
119
|
+
|
|
120
|
+
Raises:
|
|
121
|
+
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
122
|
+
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
123
|
+
|
|
124
|
+
Returns:
|
|
125
|
+
List['GetCriticalAlertsResponse200Item']
|
|
126
|
+
"""
|
|
127
|
+
|
|
128
|
+
return sync_detailed(
|
|
129
|
+
client=client,
|
|
130
|
+
page=page,
|
|
131
|
+
page_size=page_size,
|
|
132
|
+
acknowledged=acknowledged,
|
|
133
|
+
).parsed
|
|
134
|
+
|
|
135
|
+
|
|
136
|
+
async def asyncio_detailed(
|
|
137
|
+
*,
|
|
138
|
+
client: Union[AuthenticatedClient, Client],
|
|
139
|
+
page: Union[Unset, None, int] = 1,
|
|
140
|
+
page_size: Union[Unset, None, int] = 10,
|
|
141
|
+
acknowledged: Union[Unset, None, bool] = UNSET,
|
|
142
|
+
) -> Response[List["GetCriticalAlertsResponse200Item"]]:
|
|
143
|
+
"""Get all critical alerts
|
|
144
|
+
|
|
145
|
+
Args:
|
|
146
|
+
page (Union[Unset, None, int]): The page number to retrieve (minimum value is 1) Default:
|
|
147
|
+
1.
|
|
148
|
+
page_size (Union[Unset, None, int]): Number of alerts per page (maximum is 100) Default:
|
|
149
|
+
10.
|
|
150
|
+
acknowledged (Union[Unset, None, bool]): Filter by acknowledgment status; true for
|
|
151
|
+
acknowledged, false for unacknowledged, and omit for all alerts
|
|
152
|
+
|
|
153
|
+
Raises:
|
|
154
|
+
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
155
|
+
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
156
|
+
|
|
157
|
+
Returns:
|
|
158
|
+
Response[List['GetCriticalAlertsResponse200Item']]
|
|
159
|
+
"""
|
|
160
|
+
|
|
161
|
+
kwargs = _get_kwargs(
|
|
162
|
+
page=page,
|
|
163
|
+
page_size=page_size,
|
|
164
|
+
acknowledged=acknowledged,
|
|
165
|
+
)
|
|
166
|
+
|
|
167
|
+
response = await client.get_async_httpx_client().request(**kwargs)
|
|
168
|
+
|
|
169
|
+
return _build_response(client=client, response=response)
|
|
170
|
+
|
|
171
|
+
|
|
172
|
+
async def asyncio(
|
|
173
|
+
*,
|
|
174
|
+
client: Union[AuthenticatedClient, Client],
|
|
175
|
+
page: Union[Unset, None, int] = 1,
|
|
176
|
+
page_size: Union[Unset, None, int] = 10,
|
|
177
|
+
acknowledged: Union[Unset, None, bool] = UNSET,
|
|
178
|
+
) -> Optional[List["GetCriticalAlertsResponse200Item"]]:
|
|
179
|
+
"""Get all critical alerts
|
|
180
|
+
|
|
181
|
+
Args:
|
|
182
|
+
page (Union[Unset, None, int]): The page number to retrieve (minimum value is 1) Default:
|
|
183
|
+
1.
|
|
184
|
+
page_size (Union[Unset, None, int]): Number of alerts per page (maximum is 100) Default:
|
|
185
|
+
10.
|
|
186
|
+
acknowledged (Union[Unset, None, bool]): Filter by acknowledgment status; true for
|
|
187
|
+
acknowledged, false for unacknowledged, and omit for all alerts
|
|
188
|
+
|
|
189
|
+
Raises:
|
|
190
|
+
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
191
|
+
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
192
|
+
|
|
193
|
+
Returns:
|
|
194
|
+
List['GetCriticalAlertsResponse200Item']
|
|
195
|
+
"""
|
|
196
|
+
|
|
197
|
+
return (
|
|
198
|
+
await asyncio_detailed(
|
|
199
|
+
client=client,
|
|
200
|
+
page=page,
|
|
201
|
+
page_size=page_size,
|
|
202
|
+
acknowledged=acknowledged,
|
|
203
|
+
)
|
|
204
|
+
).parsed
|
|
@@ -0,0 +1,101 @@
|
|
|
1
|
+
import datetime
|
|
2
|
+
from typing import Any, Dict, List, Type, TypeVar, Union
|
|
3
|
+
|
|
4
|
+
from attrs import define as _attrs_define
|
|
5
|
+
from attrs import field as _attrs_field
|
|
6
|
+
from dateutil.parser import isoparse
|
|
7
|
+
|
|
8
|
+
from ..types import UNSET, Unset
|
|
9
|
+
|
|
10
|
+
T = TypeVar("T", bound="CriticalAlert")
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
@_attrs_define
|
|
14
|
+
class CriticalAlert:
|
|
15
|
+
"""
|
|
16
|
+
Attributes:
|
|
17
|
+
id (Union[Unset, int]): Unique identifier for the alert
|
|
18
|
+
alert_type (Union[Unset, str]): Type of alert (e.g., critical_error)
|
|
19
|
+
message (Union[Unset, str]): The message content of the alert
|
|
20
|
+
created_at (Union[Unset, datetime.datetime]): Time when the alert was created
|
|
21
|
+
acknowledged (Union[Unset, None, bool]): Acknowledgment status of the alert, can be true, false, or null if not
|
|
22
|
+
set
|
|
23
|
+
"""
|
|
24
|
+
|
|
25
|
+
id: Union[Unset, int] = UNSET
|
|
26
|
+
alert_type: Union[Unset, str] = UNSET
|
|
27
|
+
message: Union[Unset, str] = UNSET
|
|
28
|
+
created_at: Union[Unset, datetime.datetime] = UNSET
|
|
29
|
+
acknowledged: Union[Unset, None, bool] = UNSET
|
|
30
|
+
additional_properties: Dict[str, Any] = _attrs_field(init=False, factory=dict)
|
|
31
|
+
|
|
32
|
+
def to_dict(self) -> Dict[str, Any]:
|
|
33
|
+
id = self.id
|
|
34
|
+
alert_type = self.alert_type
|
|
35
|
+
message = self.message
|
|
36
|
+
created_at: Union[Unset, str] = UNSET
|
|
37
|
+
if not isinstance(self.created_at, Unset):
|
|
38
|
+
created_at = self.created_at.isoformat()
|
|
39
|
+
|
|
40
|
+
acknowledged = self.acknowledged
|
|
41
|
+
|
|
42
|
+
field_dict: Dict[str, Any] = {}
|
|
43
|
+
field_dict.update(self.additional_properties)
|
|
44
|
+
field_dict.update({})
|
|
45
|
+
if id is not UNSET:
|
|
46
|
+
field_dict["id"] = id
|
|
47
|
+
if alert_type is not UNSET:
|
|
48
|
+
field_dict["alert_type"] = alert_type
|
|
49
|
+
if message is not UNSET:
|
|
50
|
+
field_dict["message"] = message
|
|
51
|
+
if created_at is not UNSET:
|
|
52
|
+
field_dict["created_at"] = created_at
|
|
53
|
+
if acknowledged is not UNSET:
|
|
54
|
+
field_dict["acknowledged"] = acknowledged
|
|
55
|
+
|
|
56
|
+
return field_dict
|
|
57
|
+
|
|
58
|
+
@classmethod
|
|
59
|
+
def from_dict(cls: Type[T], src_dict: Dict[str, Any]) -> T:
|
|
60
|
+
d = src_dict.copy()
|
|
61
|
+
id = d.pop("id", UNSET)
|
|
62
|
+
|
|
63
|
+
alert_type = d.pop("alert_type", UNSET)
|
|
64
|
+
|
|
65
|
+
message = d.pop("message", UNSET)
|
|
66
|
+
|
|
67
|
+
_created_at = d.pop("created_at", UNSET)
|
|
68
|
+
created_at: Union[Unset, datetime.datetime]
|
|
69
|
+
if isinstance(_created_at, Unset):
|
|
70
|
+
created_at = UNSET
|
|
71
|
+
else:
|
|
72
|
+
created_at = isoparse(_created_at)
|
|
73
|
+
|
|
74
|
+
acknowledged = d.pop("acknowledged", UNSET)
|
|
75
|
+
|
|
76
|
+
critical_alert = cls(
|
|
77
|
+
id=id,
|
|
78
|
+
alert_type=alert_type,
|
|
79
|
+
message=message,
|
|
80
|
+
created_at=created_at,
|
|
81
|
+
acknowledged=acknowledged,
|
|
82
|
+
)
|
|
83
|
+
|
|
84
|
+
critical_alert.additional_properties = d
|
|
85
|
+
return critical_alert
|
|
86
|
+
|
|
87
|
+
@property
|
|
88
|
+
def additional_keys(self) -> List[str]:
|
|
89
|
+
return list(self.additional_properties.keys())
|
|
90
|
+
|
|
91
|
+
def __getitem__(self, key: str) -> Any:
|
|
92
|
+
return self.additional_properties[key]
|
|
93
|
+
|
|
94
|
+
def __setitem__(self, key: str, value: Any) -> None:
|
|
95
|
+
self.additional_properties[key] = value
|
|
96
|
+
|
|
97
|
+
def __delitem__(self, key: str) -> None:
|
|
98
|
+
del self.additional_properties[key]
|
|
99
|
+
|
|
100
|
+
def __contains__(self, key: str) -> bool:
|
|
101
|
+
return key in self.additional_properties
|
|
@@ -0,0 +1,101 @@
|
|
|
1
|
+
import datetime
|
|
2
|
+
from typing import Any, Dict, List, Type, TypeVar, Union
|
|
3
|
+
|
|
4
|
+
from attrs import define as _attrs_define
|
|
5
|
+
from attrs import field as _attrs_field
|
|
6
|
+
from dateutil.parser import isoparse
|
|
7
|
+
|
|
8
|
+
from ..types import UNSET, Unset
|
|
9
|
+
|
|
10
|
+
T = TypeVar("T", bound="GetCriticalAlertsResponse200Item")
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
@_attrs_define
|
|
14
|
+
class GetCriticalAlertsResponse200Item:
|
|
15
|
+
"""
|
|
16
|
+
Attributes:
|
|
17
|
+
id (Union[Unset, int]): Unique identifier for the alert
|
|
18
|
+
alert_type (Union[Unset, str]): Type of alert (e.g., critical_error)
|
|
19
|
+
message (Union[Unset, str]): The message content of the alert
|
|
20
|
+
created_at (Union[Unset, datetime.datetime]): Time when the alert was created
|
|
21
|
+
acknowledged (Union[Unset, None, bool]): Acknowledgment status of the alert, can be true, false, or null if not
|
|
22
|
+
set
|
|
23
|
+
"""
|
|
24
|
+
|
|
25
|
+
id: Union[Unset, int] = UNSET
|
|
26
|
+
alert_type: Union[Unset, str] = UNSET
|
|
27
|
+
message: Union[Unset, str] = UNSET
|
|
28
|
+
created_at: Union[Unset, datetime.datetime] = UNSET
|
|
29
|
+
acknowledged: Union[Unset, None, bool] = UNSET
|
|
30
|
+
additional_properties: Dict[str, Any] = _attrs_field(init=False, factory=dict)
|
|
31
|
+
|
|
32
|
+
def to_dict(self) -> Dict[str, Any]:
|
|
33
|
+
id = self.id
|
|
34
|
+
alert_type = self.alert_type
|
|
35
|
+
message = self.message
|
|
36
|
+
created_at: Union[Unset, str] = UNSET
|
|
37
|
+
if not isinstance(self.created_at, Unset):
|
|
38
|
+
created_at = self.created_at.isoformat()
|
|
39
|
+
|
|
40
|
+
acknowledged = self.acknowledged
|
|
41
|
+
|
|
42
|
+
field_dict: Dict[str, Any] = {}
|
|
43
|
+
field_dict.update(self.additional_properties)
|
|
44
|
+
field_dict.update({})
|
|
45
|
+
if id is not UNSET:
|
|
46
|
+
field_dict["id"] = id
|
|
47
|
+
if alert_type is not UNSET:
|
|
48
|
+
field_dict["alert_type"] = alert_type
|
|
49
|
+
if message is not UNSET:
|
|
50
|
+
field_dict["message"] = message
|
|
51
|
+
if created_at is not UNSET:
|
|
52
|
+
field_dict["created_at"] = created_at
|
|
53
|
+
if acknowledged is not UNSET:
|
|
54
|
+
field_dict["acknowledged"] = acknowledged
|
|
55
|
+
|
|
56
|
+
return field_dict
|
|
57
|
+
|
|
58
|
+
@classmethod
|
|
59
|
+
def from_dict(cls: Type[T], src_dict: Dict[str, Any]) -> T:
|
|
60
|
+
d = src_dict.copy()
|
|
61
|
+
id = d.pop("id", UNSET)
|
|
62
|
+
|
|
63
|
+
alert_type = d.pop("alert_type", UNSET)
|
|
64
|
+
|
|
65
|
+
message = d.pop("message", UNSET)
|
|
66
|
+
|
|
67
|
+
_created_at = d.pop("created_at", UNSET)
|
|
68
|
+
created_at: Union[Unset, datetime.datetime]
|
|
69
|
+
if isinstance(_created_at, Unset):
|
|
70
|
+
created_at = UNSET
|
|
71
|
+
else:
|
|
72
|
+
created_at = isoparse(_created_at)
|
|
73
|
+
|
|
74
|
+
acknowledged = d.pop("acknowledged", UNSET)
|
|
75
|
+
|
|
76
|
+
get_critical_alerts_response_200_item = cls(
|
|
77
|
+
id=id,
|
|
78
|
+
alert_type=alert_type,
|
|
79
|
+
message=message,
|
|
80
|
+
created_at=created_at,
|
|
81
|
+
acknowledged=acknowledged,
|
|
82
|
+
)
|
|
83
|
+
|
|
84
|
+
get_critical_alerts_response_200_item.additional_properties = d
|
|
85
|
+
return get_critical_alerts_response_200_item
|
|
86
|
+
|
|
87
|
+
@property
|
|
88
|
+
def additional_keys(self) -> List[str]:
|
|
89
|
+
return list(self.additional_properties.keys())
|
|
90
|
+
|
|
91
|
+
def __getitem__(self, key: str) -> Any:
|
|
92
|
+
return self.additional_properties[key]
|
|
93
|
+
|
|
94
|
+
def __setitem__(self, key: str, value: Any) -> None:
|
|
95
|
+
self.additional_properties[key] = value
|
|
96
|
+
|
|
97
|
+
def __delitem__(self, key: str) -> None:
|
|
98
|
+
del self.additional_properties[key]
|
|
99
|
+
|
|
100
|
+
def __contains__(self, key: str) -> bool:
|
|
101
|
+
return key in self.additional_properties
|
|
@@ -270,7 +270,10 @@ windmill_api/api/service_logs/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5N
|
|
|
270
270
|
windmill_api/api/service_logs/get_log_file.py,sha256=EFwKZgOSH9r0jv-3f3QPAJCZCxQHq6nFgP5X8yQm3mw,2245
|
|
271
271
|
windmill_api/api/service_logs/list_log_files.py,sha256=ueR8yr9-yjBbzqG5e9OREkcVIzIJ9fdO-WJrAS_xqsU,6189
|
|
272
272
|
windmill_api/api/setting/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
273
|
+
windmill_api/api/setting/acknowledge_all_critical_alerts.py,sha256=K6Zr9UEdjg9rzN3XAQ1AcD0Y-puATfBaUiiKsHiH6F8,3205
|
|
274
|
+
windmill_api/api/setting/acknowledge_critical_alert.py,sha256=ADXBa_SZj3crnxo3w2odchssMEnETlmtKjOSeV0lpCA,3427
|
|
273
275
|
windmill_api/api/setting/create_customer_portal_session.py,sha256=rUOT27UsoKKImfwdgIXF57u2fMWe-DtEaeFflD314mY,2608
|
|
276
|
+
windmill_api/api/setting/get_critical_alerts.py,sha256=rvtYBd_zML4clQSmExEtknadAesiKI6JL6XvpfhjnHo,6713
|
|
274
277
|
windmill_api/api/setting/get_global.py,sha256=fROXxArQM5x7HHue_VWX9Y2i-Dm_byRs9Y1yIsYDogI,2287
|
|
275
278
|
windmill_api/api/setting/get_latest_key_renewal_attempt.py,sha256=MJtImlDMxdeizItTpsMIbBlWcJLc0pjwVTkeOIinAKE,3916
|
|
276
279
|
windmill_api/api/setting/get_local.py,sha256=zSx_gnsuRuDjUb0GA5tS5eiZk_8OVTM54j_d06Wxf2M,2092
|
|
@@ -655,6 +658,7 @@ windmill_api/models/create_websocket_trigger_json_body_initial_messages_item_typ
|
|
|
655
658
|
windmill_api/models/create_websocket_trigger_json_body_url_runnable_args.py,sha256=OAFtivMu4oZtifEkw15s2mFnpaXTxFOVO5BYEKXXk00,1398
|
|
656
659
|
windmill_api/models/create_workspace.py,sha256=WO8QwIF11s_Lxgode8eC59QmBsPiepnfes6vIMcJihs,1867
|
|
657
660
|
windmill_api/models/create_workspace_json_body.py,sha256=EH0XdQbDncCaLa7qWY5peYzj3cZeUGSwmwyLa_09IDg,1913
|
|
661
|
+
windmill_api/models/critical_alert.py,sha256=CZ5UtBkZA0Ds1WrI1kRqbQQIDdzsYUAP0ttUmPy9QSw,3255
|
|
658
662
|
windmill_api/models/decline_invite_json_body.py,sha256=APY6WrYS2XvpWr0TefDZUSgNN-1gICXnmDHmit9MI88,1553
|
|
659
663
|
windmill_api/models/delete_completed_job_response_200.py,sha256=_tYQvnyE_osYdjztCUN31_6DXWVjlo4Gx1XTTI3ryLg,12995
|
|
660
664
|
windmill_api/models/delete_completed_job_response_200_args.py,sha256=hVhS2-tklk9gIRyCrY3-3wA0_Sq80Jpr2WmOJH91x5Q,1332
|
|
@@ -1375,6 +1379,7 @@ windmill_api/models/get_completed_job_response_200_raw_flow_preprocessor_module_
|
|
|
1375
1379
|
windmill_api/models/get_completed_job_response_200_raw_flow_preprocessor_module_suspend_user_groups_required_type_1.py,sha256=uX0SlnpjRQnc4k3eyBkfc_2zzj_vuMWrydXVV3WZOjQ,2447
|
|
1376
1380
|
windmill_api/models/get_completed_job_response_200_raw_flow_preprocessor_module_suspend_user_groups_required_type_1_type.py,sha256=u-YheCK0vWC6q48xofM368suCbrdf0cLeJ4nbNc1yoU,220
|
|
1377
1381
|
windmill_api/models/get_completed_job_result_maybe_response_200.py,sha256=no4BzZB_3zRVawLJh9ZsjH5ntuZ8Zj90QGYQd7mFmaI,2333
|
|
1382
|
+
windmill_api/models/get_critical_alerts_response_200_item.py,sha256=rAuA-WEmFz4T-2uJC0EFvKGgM0r7Don8jRRrL_vocL8,3362
|
|
1378
1383
|
windmill_api/models/get_default_scripts_response_200.py,sha256=ekfscpG1XtNxHvpokDZ7pI0W6DAdITytKNg09XwSgtc,2537
|
|
1379
1384
|
windmill_api/models/get_deploy_to_response_200.py,sha256=xZHLxF4DVyJtjVYFRWhSC4gCu1nC1wIAHlvwB-dV8EU,1623
|
|
1380
1385
|
windmill_api/models/get_flow_by_path_response_200.py,sha256=v8FxxokWZhVdKXEfqA8mdmZIzEMI_gCiNjfilZNAC5k,7321
|
|
@@ -3454,7 +3459,7 @@ windmill_api/models/workspace_git_sync_settings_repositories_item_exclude_types_
|
|
|
3454
3459
|
windmill_api/models/workspace_invite.py,sha256=HnAJWGv5LwxWkz1T3fhgHKIccO7RFC1lixwUUXG6CXs,2037
|
|
3455
3460
|
windmill_api/py.typed,sha256=8ZJUsxZiuOy1oJeVhsTWQhTG_6pTVHVXk5hJL79ebTk,25
|
|
3456
3461
|
windmill_api/types.py,sha256=GoYub3t4hQP2Yn5tsvShsBfIY3vHUmblU0MXszDx_V0,968
|
|
3457
|
-
windmill_api-1.
|
|
3458
|
-
windmill_api-1.
|
|
3459
|
-
windmill_api-1.
|
|
3460
|
-
windmill_api-1.
|
|
3462
|
+
windmill_api-1.422.1.dist-info/LICENSE,sha256=qJVFNTaOevCeSY6NoXeUG1SPOwQ1K-PxVQ2iEWJzX-A,11348
|
|
3463
|
+
windmill_api-1.422.1.dist-info/METADATA,sha256=wRZRgLurnRueuUM8Vj2V1cMkeJ0gxPgBwhEkZPTv6Hc,5023
|
|
3464
|
+
windmill_api-1.422.1.dist-info/WHEEL,sha256=d2fvjOD7sXsVzChCqf0Ty0JbHKBaLYwDbGQDwQTnJ50,88
|
|
3465
|
+
windmill_api-1.422.1.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|