daknode 0.1.0__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.
- daknode/__init__.py +8 -0
- daknode/api/__init__.py +1 -0
- daknode/api/block_rules/__init__.py +1 -0
- daknode/api/block_rules/create_block_rule.py +211 -0
- daknode/api/block_rules/create_inbox_block_rule.py +225 -0
- daknode/api/block_rules/delete_block_rule.py +192 -0
- daknode/api/block_rules/list_block_rules.py +214 -0
- daknode/api/block_rules/list_inbox_block_rules.py +228 -0
- daknode/api/consent/__init__.py +1 -0
- daknode/api/consent/create_consent.py +203 -0
- daknode/api/consent/revoke.py +195 -0
- daknode/api/control_plane/__init__.py +1 -0
- daknode/api/control_plane/close_workspace.py +184 -0
- daknode/api/control_plane/create_workspace.py +211 -0
- daknode/api/control_plane/list_workspaces.py +155 -0
- daknode/api/control_plane/read_workspace.py +176 -0
- daknode/api/control_plane/update_workspace.py +197 -0
- daknode/api/dead_letters/__init__.py +1 -0
- daknode/api/dead_letters/list_dead_letters.py +198 -0
- daknode/api/dead_letters/replay_dead_letter.py +216 -0
- daknode/api/inboxes/__init__.py +1 -0
- daknode/api/inboxes/create_inbox.py +183 -0
- daknode/api/inboxes/register_webhook.py +225 -0
- daknode/api/inboxes/rotate_webhook_secret.py +224 -0
- daknode/api/messages/__init__.py +1 -0
- daknode/api/messages/get_message.py +176 -0
- daknode/api/messages/get_thread.py +184 -0
- daknode/api/messages/list_messages.py +228 -0
- daknode/api/messages/list_threads.py +228 -0
- daknode/api/privacy/__init__.py +1 -0
- daknode/api/privacy/create_erasure_request.py +227 -0
- daknode/api/privacy/read_erasure_request.py +200 -0
- daknode/api/public/__init__.py +1 -0
- daknode/api/public/agent_signup.py +191 -0
- daknode/api/public/agent_verify.py +191 -0
- daknode/api/search/__init__.py +1 -0
- daknode/api/search/search.py +207 -0
- daknode/api/send/__init__.py +1 -0
- daknode/api/send/send.py +254 -0
- daknode/client.py +270 -0
- daknode/errors.py +14 -0
- daknode/models/__init__.py +79 -0
- daknode/models/block_rule_create.py +104 -0
- daknode/models/block_rule_out.py +160 -0
- daknode/models/block_rule_page.py +116 -0
- daknode/models/consent_request.py +104 -0
- daknode/models/consent_response.py +105 -0
- daknode/models/create_erasure_request_response_create_erasure_request.py +63 -0
- daknode/models/create_in.py +119 -0
- daknode/models/dead_letter_response.py +205 -0
- daknode/models/erasure_request_body.py +60 -0
- daknode/models/http_validation_error.py +97 -0
- daknode/models/inbox_create_request.py +120 -0
- daknode/models/inbox_response.py +148 -0
- daknode/models/message_out.py +309 -0
- daknode/models/message_page.py +116 -0
- daknode/models/read_erasure_request_response_read_erasure_request.py +63 -0
- daknode/models/replay_response.py +113 -0
- daknode/models/revoke_request.py +74 -0
- daknode/models/revoke_response_revoke.py +63 -0
- daknode/models/search_match.py +170 -0
- daknode/models/search_request.py +107 -0
- daknode/models/search_response.py +124 -0
- daknode/models/send_request.py +162 -0
- daknode/models/send_response_send.py +63 -0
- daknode/models/signup_in.py +63 -0
- daknode/models/signup_out.py +102 -0
- daknode/models/thread_detail_out.py +223 -0
- daknode/models/thread_out.py +163 -0
- daknode/models/thread_page.py +116 -0
- daknode/models/timeline_item_out.py +280 -0
- daknode/models/update_in.py +111 -0
- daknode/models/validation_error.py +141 -0
- daknode/models/validation_error_context.py +63 -0
- daknode/models/verify_in.py +67 -0
- daknode/models/verify_out.py +74 -0
- daknode/models/webhook_register_request.py +74 -0
- daknode/models/workspace_list_out.py +92 -0
- daknode/models/workspace_out.py +147 -0
- daknode/py.typed +1 -0
- daknode/types.py +53 -0
- daknode-0.1.0.dist-info/METADATA +143 -0
- daknode-0.1.0.dist-info/RECORD +84 -0
- daknode-0.1.0.dist-info/WHEEL +4 -0
|
@@ -0,0 +1,155 @@
|
|
|
1
|
+
from http import HTTPStatus
|
|
2
|
+
from typing import Any, Optional, Union, cast
|
|
3
|
+
|
|
4
|
+
import httpx
|
|
5
|
+
|
|
6
|
+
from ...client import AuthenticatedClient, Client
|
|
7
|
+
from ...types import Response, UNSET
|
|
8
|
+
from ... import errors
|
|
9
|
+
|
|
10
|
+
from ...models.workspace_list_out import WorkspaceListOut
|
|
11
|
+
from typing import cast
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
def _get_kwargs(
|
|
16
|
+
|
|
17
|
+
) -> dict[str, Any]:
|
|
18
|
+
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
|
|
24
|
+
_kwargs: dict[str, Any] = {
|
|
25
|
+
"method": "get",
|
|
26
|
+
"url": "/v1/workspaces",
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
|
|
30
|
+
return _kwargs
|
|
31
|
+
|
|
32
|
+
|
|
33
|
+
def _parse_response(*, client: Union[AuthenticatedClient, Client], response: httpx.Response) -> Optional[WorkspaceListOut]:
|
|
34
|
+
if response.status_code == 200:
|
|
35
|
+
response_200 = WorkspaceListOut.from_dict(response.json())
|
|
36
|
+
|
|
37
|
+
|
|
38
|
+
|
|
39
|
+
return response_200
|
|
40
|
+
if client.raise_on_unexpected_status:
|
|
41
|
+
raise errors.UnexpectedStatus(response.status_code, response.content)
|
|
42
|
+
else:
|
|
43
|
+
return None
|
|
44
|
+
|
|
45
|
+
|
|
46
|
+
def _build_response(*, client: Union[AuthenticatedClient, Client], response: httpx.Response) -> Response[WorkspaceListOut]:
|
|
47
|
+
return Response(
|
|
48
|
+
status_code=HTTPStatus(response.status_code),
|
|
49
|
+
content=response.content,
|
|
50
|
+
headers=response.headers,
|
|
51
|
+
parsed=_parse_response(client=client, response=response),
|
|
52
|
+
)
|
|
53
|
+
|
|
54
|
+
|
|
55
|
+
def sync_detailed(
|
|
56
|
+
*,
|
|
57
|
+
client: AuthenticatedClient,
|
|
58
|
+
|
|
59
|
+
) -> Response[WorkspaceListOut]:
|
|
60
|
+
""" List Workspaces
|
|
61
|
+
|
|
62
|
+
Active Workspaces of the credential's own Account.
|
|
63
|
+
|
|
64
|
+
Raises:
|
|
65
|
+
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
66
|
+
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
67
|
+
|
|
68
|
+
Returns:
|
|
69
|
+
Response[WorkspaceListOut]
|
|
70
|
+
"""
|
|
71
|
+
|
|
72
|
+
|
|
73
|
+
kwargs = _get_kwargs(
|
|
74
|
+
|
|
75
|
+
)
|
|
76
|
+
|
|
77
|
+
response = client.get_httpx_client().request(
|
|
78
|
+
**kwargs,
|
|
79
|
+
)
|
|
80
|
+
|
|
81
|
+
return _build_response(client=client, response=response)
|
|
82
|
+
|
|
83
|
+
def sync(
|
|
84
|
+
*,
|
|
85
|
+
client: AuthenticatedClient,
|
|
86
|
+
|
|
87
|
+
) -> Optional[WorkspaceListOut]:
|
|
88
|
+
""" List Workspaces
|
|
89
|
+
|
|
90
|
+
Active Workspaces of the credential's own Account.
|
|
91
|
+
|
|
92
|
+
Raises:
|
|
93
|
+
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
94
|
+
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
95
|
+
|
|
96
|
+
Returns:
|
|
97
|
+
WorkspaceListOut
|
|
98
|
+
"""
|
|
99
|
+
|
|
100
|
+
|
|
101
|
+
return sync_detailed(
|
|
102
|
+
client=client,
|
|
103
|
+
|
|
104
|
+
).parsed
|
|
105
|
+
|
|
106
|
+
async def asyncio_detailed(
|
|
107
|
+
*,
|
|
108
|
+
client: AuthenticatedClient,
|
|
109
|
+
|
|
110
|
+
) -> Response[WorkspaceListOut]:
|
|
111
|
+
""" List Workspaces
|
|
112
|
+
|
|
113
|
+
Active Workspaces of the credential's own Account.
|
|
114
|
+
|
|
115
|
+
Raises:
|
|
116
|
+
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
117
|
+
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
118
|
+
|
|
119
|
+
Returns:
|
|
120
|
+
Response[WorkspaceListOut]
|
|
121
|
+
"""
|
|
122
|
+
|
|
123
|
+
|
|
124
|
+
kwargs = _get_kwargs(
|
|
125
|
+
|
|
126
|
+
)
|
|
127
|
+
|
|
128
|
+
response = await client.get_async_httpx_client().request(
|
|
129
|
+
**kwargs
|
|
130
|
+
)
|
|
131
|
+
|
|
132
|
+
return _build_response(client=client, response=response)
|
|
133
|
+
|
|
134
|
+
async def asyncio(
|
|
135
|
+
*,
|
|
136
|
+
client: AuthenticatedClient,
|
|
137
|
+
|
|
138
|
+
) -> Optional[WorkspaceListOut]:
|
|
139
|
+
""" List Workspaces
|
|
140
|
+
|
|
141
|
+
Active Workspaces of the credential's own Account.
|
|
142
|
+
|
|
143
|
+
Raises:
|
|
144
|
+
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
145
|
+
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
146
|
+
|
|
147
|
+
Returns:
|
|
148
|
+
WorkspaceListOut
|
|
149
|
+
"""
|
|
150
|
+
|
|
151
|
+
|
|
152
|
+
return (await asyncio_detailed(
|
|
153
|
+
client=client,
|
|
154
|
+
|
|
155
|
+
)).parsed
|
|
@@ -0,0 +1,176 @@
|
|
|
1
|
+
from http import HTTPStatus
|
|
2
|
+
from typing import Any, Optional, Union, cast
|
|
3
|
+
|
|
4
|
+
import httpx
|
|
5
|
+
|
|
6
|
+
from ...client import AuthenticatedClient, Client
|
|
7
|
+
from ...types import Response, UNSET
|
|
8
|
+
from ... import errors
|
|
9
|
+
|
|
10
|
+
from ...models.http_validation_error import HTTPValidationError
|
|
11
|
+
from ...models.workspace_out import WorkspaceOut
|
|
12
|
+
from typing import cast
|
|
13
|
+
from uuid import UUID
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
def _get_kwargs(
|
|
18
|
+
workspace_id: UUID,
|
|
19
|
+
|
|
20
|
+
) -> dict[str, Any]:
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
|
|
24
|
+
|
|
25
|
+
|
|
26
|
+
|
|
27
|
+
_kwargs: dict[str, Any] = {
|
|
28
|
+
"method": "get",
|
|
29
|
+
"url": "/v1/workspaces/{workspace_id}".format(workspace_id=workspace_id,),
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
|
|
33
|
+
return _kwargs
|
|
34
|
+
|
|
35
|
+
|
|
36
|
+
def _parse_response(*, client: Union[AuthenticatedClient, Client], response: httpx.Response) -> Optional[Union[HTTPValidationError, WorkspaceOut]]:
|
|
37
|
+
if response.status_code == 200:
|
|
38
|
+
response_200 = WorkspaceOut.from_dict(response.json())
|
|
39
|
+
|
|
40
|
+
|
|
41
|
+
|
|
42
|
+
return response_200
|
|
43
|
+
if response.status_code == 422:
|
|
44
|
+
response_422 = HTTPValidationError.from_dict(response.json())
|
|
45
|
+
|
|
46
|
+
|
|
47
|
+
|
|
48
|
+
return response_422
|
|
49
|
+
if client.raise_on_unexpected_status:
|
|
50
|
+
raise errors.UnexpectedStatus(response.status_code, response.content)
|
|
51
|
+
else:
|
|
52
|
+
return None
|
|
53
|
+
|
|
54
|
+
|
|
55
|
+
def _build_response(*, client: Union[AuthenticatedClient, Client], response: httpx.Response) -> Response[Union[HTTPValidationError, WorkspaceOut]]:
|
|
56
|
+
return Response(
|
|
57
|
+
status_code=HTTPStatus(response.status_code),
|
|
58
|
+
content=response.content,
|
|
59
|
+
headers=response.headers,
|
|
60
|
+
parsed=_parse_response(client=client, response=response),
|
|
61
|
+
)
|
|
62
|
+
|
|
63
|
+
|
|
64
|
+
def sync_detailed(
|
|
65
|
+
workspace_id: UUID,
|
|
66
|
+
*,
|
|
67
|
+
client: AuthenticatedClient,
|
|
68
|
+
|
|
69
|
+
) -> Response[Union[HTTPValidationError, WorkspaceOut]]:
|
|
70
|
+
""" Read Workspace
|
|
71
|
+
|
|
72
|
+
Args:
|
|
73
|
+
workspace_id (UUID):
|
|
74
|
+
|
|
75
|
+
Raises:
|
|
76
|
+
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
77
|
+
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
78
|
+
|
|
79
|
+
Returns:
|
|
80
|
+
Response[Union[HTTPValidationError, WorkspaceOut]]
|
|
81
|
+
"""
|
|
82
|
+
|
|
83
|
+
|
|
84
|
+
kwargs = _get_kwargs(
|
|
85
|
+
workspace_id=workspace_id,
|
|
86
|
+
|
|
87
|
+
)
|
|
88
|
+
|
|
89
|
+
response = client.get_httpx_client().request(
|
|
90
|
+
**kwargs,
|
|
91
|
+
)
|
|
92
|
+
|
|
93
|
+
return _build_response(client=client, response=response)
|
|
94
|
+
|
|
95
|
+
def sync(
|
|
96
|
+
workspace_id: UUID,
|
|
97
|
+
*,
|
|
98
|
+
client: AuthenticatedClient,
|
|
99
|
+
|
|
100
|
+
) -> Optional[Union[HTTPValidationError, WorkspaceOut]]:
|
|
101
|
+
""" Read Workspace
|
|
102
|
+
|
|
103
|
+
Args:
|
|
104
|
+
workspace_id (UUID):
|
|
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
|
+
Union[HTTPValidationError, WorkspaceOut]
|
|
112
|
+
"""
|
|
113
|
+
|
|
114
|
+
|
|
115
|
+
return sync_detailed(
|
|
116
|
+
workspace_id=workspace_id,
|
|
117
|
+
client=client,
|
|
118
|
+
|
|
119
|
+
).parsed
|
|
120
|
+
|
|
121
|
+
async def asyncio_detailed(
|
|
122
|
+
workspace_id: UUID,
|
|
123
|
+
*,
|
|
124
|
+
client: AuthenticatedClient,
|
|
125
|
+
|
|
126
|
+
) -> Response[Union[HTTPValidationError, WorkspaceOut]]:
|
|
127
|
+
""" Read Workspace
|
|
128
|
+
|
|
129
|
+
Args:
|
|
130
|
+
workspace_id (UUID):
|
|
131
|
+
|
|
132
|
+
Raises:
|
|
133
|
+
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
134
|
+
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
135
|
+
|
|
136
|
+
Returns:
|
|
137
|
+
Response[Union[HTTPValidationError, WorkspaceOut]]
|
|
138
|
+
"""
|
|
139
|
+
|
|
140
|
+
|
|
141
|
+
kwargs = _get_kwargs(
|
|
142
|
+
workspace_id=workspace_id,
|
|
143
|
+
|
|
144
|
+
)
|
|
145
|
+
|
|
146
|
+
response = await client.get_async_httpx_client().request(
|
|
147
|
+
**kwargs
|
|
148
|
+
)
|
|
149
|
+
|
|
150
|
+
return _build_response(client=client, response=response)
|
|
151
|
+
|
|
152
|
+
async def asyncio(
|
|
153
|
+
workspace_id: UUID,
|
|
154
|
+
*,
|
|
155
|
+
client: AuthenticatedClient,
|
|
156
|
+
|
|
157
|
+
) -> Optional[Union[HTTPValidationError, WorkspaceOut]]:
|
|
158
|
+
""" Read Workspace
|
|
159
|
+
|
|
160
|
+
Args:
|
|
161
|
+
workspace_id (UUID):
|
|
162
|
+
|
|
163
|
+
Raises:
|
|
164
|
+
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
165
|
+
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
166
|
+
|
|
167
|
+
Returns:
|
|
168
|
+
Union[HTTPValidationError, WorkspaceOut]
|
|
169
|
+
"""
|
|
170
|
+
|
|
171
|
+
|
|
172
|
+
return (await asyncio_detailed(
|
|
173
|
+
workspace_id=workspace_id,
|
|
174
|
+
client=client,
|
|
175
|
+
|
|
176
|
+
)).parsed
|
|
@@ -0,0 +1,197 @@
|
|
|
1
|
+
from http import HTTPStatus
|
|
2
|
+
from typing import Any, Optional, Union, cast
|
|
3
|
+
|
|
4
|
+
import httpx
|
|
5
|
+
|
|
6
|
+
from ...client import AuthenticatedClient, Client
|
|
7
|
+
from ...types import Response, UNSET
|
|
8
|
+
from ... import errors
|
|
9
|
+
|
|
10
|
+
from ...models.http_validation_error import HTTPValidationError
|
|
11
|
+
from ...models.update_in import UpdateIn
|
|
12
|
+
from ...models.workspace_out import WorkspaceOut
|
|
13
|
+
from typing import cast
|
|
14
|
+
from uuid import UUID
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
def _get_kwargs(
|
|
19
|
+
workspace_id: UUID,
|
|
20
|
+
*,
|
|
21
|
+
body: UpdateIn,
|
|
22
|
+
|
|
23
|
+
) -> dict[str, Any]:
|
|
24
|
+
headers: dict[str, Any] = {}
|
|
25
|
+
|
|
26
|
+
|
|
27
|
+
|
|
28
|
+
|
|
29
|
+
|
|
30
|
+
|
|
31
|
+
_kwargs: dict[str, Any] = {
|
|
32
|
+
"method": "patch",
|
|
33
|
+
"url": "/v1/workspaces/{workspace_id}".format(workspace_id=workspace_id,),
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
_kwargs["json"] = body.to_dict()
|
|
37
|
+
|
|
38
|
+
|
|
39
|
+
headers["Content-Type"] = "application/json"
|
|
40
|
+
|
|
41
|
+
_kwargs["headers"] = headers
|
|
42
|
+
return _kwargs
|
|
43
|
+
|
|
44
|
+
|
|
45
|
+
def _parse_response(*, client: Union[AuthenticatedClient, Client], response: httpx.Response) -> Optional[Union[HTTPValidationError, WorkspaceOut]]:
|
|
46
|
+
if response.status_code == 200:
|
|
47
|
+
response_200 = WorkspaceOut.from_dict(response.json())
|
|
48
|
+
|
|
49
|
+
|
|
50
|
+
|
|
51
|
+
return response_200
|
|
52
|
+
if response.status_code == 422:
|
|
53
|
+
response_422 = HTTPValidationError.from_dict(response.json())
|
|
54
|
+
|
|
55
|
+
|
|
56
|
+
|
|
57
|
+
return response_422
|
|
58
|
+
if client.raise_on_unexpected_status:
|
|
59
|
+
raise errors.UnexpectedStatus(response.status_code, response.content)
|
|
60
|
+
else:
|
|
61
|
+
return None
|
|
62
|
+
|
|
63
|
+
|
|
64
|
+
def _build_response(*, client: Union[AuthenticatedClient, Client], response: httpx.Response) -> Response[Union[HTTPValidationError, WorkspaceOut]]:
|
|
65
|
+
return Response(
|
|
66
|
+
status_code=HTTPStatus(response.status_code),
|
|
67
|
+
content=response.content,
|
|
68
|
+
headers=response.headers,
|
|
69
|
+
parsed=_parse_response(client=client, response=response),
|
|
70
|
+
)
|
|
71
|
+
|
|
72
|
+
|
|
73
|
+
def sync_detailed(
|
|
74
|
+
workspace_id: UUID,
|
|
75
|
+
*,
|
|
76
|
+
client: AuthenticatedClient,
|
|
77
|
+
body: UpdateIn,
|
|
78
|
+
|
|
79
|
+
) -> Response[Union[HTTPValidationError, WorkspaceOut]]:
|
|
80
|
+
""" Update Workspace
|
|
81
|
+
|
|
82
|
+
Args:
|
|
83
|
+
workspace_id (UUID):
|
|
84
|
+
body (UpdateIn):
|
|
85
|
+
|
|
86
|
+
Raises:
|
|
87
|
+
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
88
|
+
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
89
|
+
|
|
90
|
+
Returns:
|
|
91
|
+
Response[Union[HTTPValidationError, WorkspaceOut]]
|
|
92
|
+
"""
|
|
93
|
+
|
|
94
|
+
|
|
95
|
+
kwargs = _get_kwargs(
|
|
96
|
+
workspace_id=workspace_id,
|
|
97
|
+
body=body,
|
|
98
|
+
|
|
99
|
+
)
|
|
100
|
+
|
|
101
|
+
response = client.get_httpx_client().request(
|
|
102
|
+
**kwargs,
|
|
103
|
+
)
|
|
104
|
+
|
|
105
|
+
return _build_response(client=client, response=response)
|
|
106
|
+
|
|
107
|
+
def sync(
|
|
108
|
+
workspace_id: UUID,
|
|
109
|
+
*,
|
|
110
|
+
client: AuthenticatedClient,
|
|
111
|
+
body: UpdateIn,
|
|
112
|
+
|
|
113
|
+
) -> Optional[Union[HTTPValidationError, WorkspaceOut]]:
|
|
114
|
+
""" Update Workspace
|
|
115
|
+
|
|
116
|
+
Args:
|
|
117
|
+
workspace_id (UUID):
|
|
118
|
+
body (UpdateIn):
|
|
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
|
+
Union[HTTPValidationError, WorkspaceOut]
|
|
126
|
+
"""
|
|
127
|
+
|
|
128
|
+
|
|
129
|
+
return sync_detailed(
|
|
130
|
+
workspace_id=workspace_id,
|
|
131
|
+
client=client,
|
|
132
|
+
body=body,
|
|
133
|
+
|
|
134
|
+
).parsed
|
|
135
|
+
|
|
136
|
+
async def asyncio_detailed(
|
|
137
|
+
workspace_id: UUID,
|
|
138
|
+
*,
|
|
139
|
+
client: AuthenticatedClient,
|
|
140
|
+
body: UpdateIn,
|
|
141
|
+
|
|
142
|
+
) -> Response[Union[HTTPValidationError, WorkspaceOut]]:
|
|
143
|
+
""" Update Workspace
|
|
144
|
+
|
|
145
|
+
Args:
|
|
146
|
+
workspace_id (UUID):
|
|
147
|
+
body (UpdateIn):
|
|
148
|
+
|
|
149
|
+
Raises:
|
|
150
|
+
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
151
|
+
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
152
|
+
|
|
153
|
+
Returns:
|
|
154
|
+
Response[Union[HTTPValidationError, WorkspaceOut]]
|
|
155
|
+
"""
|
|
156
|
+
|
|
157
|
+
|
|
158
|
+
kwargs = _get_kwargs(
|
|
159
|
+
workspace_id=workspace_id,
|
|
160
|
+
body=body,
|
|
161
|
+
|
|
162
|
+
)
|
|
163
|
+
|
|
164
|
+
response = await client.get_async_httpx_client().request(
|
|
165
|
+
**kwargs
|
|
166
|
+
)
|
|
167
|
+
|
|
168
|
+
return _build_response(client=client, response=response)
|
|
169
|
+
|
|
170
|
+
async def asyncio(
|
|
171
|
+
workspace_id: UUID,
|
|
172
|
+
*,
|
|
173
|
+
client: AuthenticatedClient,
|
|
174
|
+
body: UpdateIn,
|
|
175
|
+
|
|
176
|
+
) -> Optional[Union[HTTPValidationError, WorkspaceOut]]:
|
|
177
|
+
""" Update Workspace
|
|
178
|
+
|
|
179
|
+
Args:
|
|
180
|
+
workspace_id (UUID):
|
|
181
|
+
body (UpdateIn):
|
|
182
|
+
|
|
183
|
+
Raises:
|
|
184
|
+
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
185
|
+
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
186
|
+
|
|
187
|
+
Returns:
|
|
188
|
+
Union[HTTPValidationError, WorkspaceOut]
|
|
189
|
+
"""
|
|
190
|
+
|
|
191
|
+
|
|
192
|
+
return (await asyncio_detailed(
|
|
193
|
+
workspace_id=workspace_id,
|
|
194
|
+
client=client,
|
|
195
|
+
body=body,
|
|
196
|
+
|
|
197
|
+
)).parsed
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
""" Contains endpoint functions for accessing the API """
|