robosystems-client 0.2.3__py3-none-any.whl → 0.2.4__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 robosystems-client might be problematic. Click here for more details.
- robosystems_client/api/agent/auto_select_agent.py +1 -41
- robosystems_client/api/agent/batch_process_queries.py +1 -41
- robosystems_client/api/agent/execute_specific_agent.py +1 -41
- robosystems_client/api/agent/get_agent_metadata.py +5 -49
- robosystems_client/api/agent/list_agents.py +4 -42
- robosystems_client/api/agent/recommend_agent.py +5 -45
- robosystems_client/api/auth/generate_sso_token.py +0 -18
- robosystems_client/api/auth/get_current_auth_user.py +14 -74
- robosystems_client/api/auth/logout_user.py +14 -50
- robosystems_client/api/auth/refresh_auth_session.py +14 -50
- robosystems_client/api/auth/resend_verification_email.py +14 -74
- robosystems_client/api/backup/create_backup.py +5 -45
- robosystems_client/api/backup/get_backup_download_url.py +4 -42
- robosystems_client/api/backup/get_backup_stats.py +5 -49
- robosystems_client/api/backup/list_backups.py +4 -42
- robosystems_client/api/backup/restore_backup.py +5 -45
- robosystems_client/api/connections/create_connection.py +5 -45
- robosystems_client/api/connections/create_link_token.py +5 -45
- robosystems_client/api/connections/delete_connection.py +5 -49
- robosystems_client/api/connections/exchange_link_token.py +5 -45
- robosystems_client/api/connections/get_connection.py +5 -49
- robosystems_client/api/connections/get_connection_options.py +5 -49
- robosystems_client/api/connections/init_o_auth.py +5 -45
- robosystems_client/api/connections/list_connections.py +4 -42
- robosystems_client/api/connections/oauth_callback.py +5 -45
- robosystems_client/api/connections/sync_connection.py +5 -45
- robosystems_client/api/graph_analytics/get_graph_metrics.py +5 -49
- robosystems_client/api/graph_analytics/get_graph_usage_stats.py +4 -42
- robosystems_client/api/graph_billing/get_current_graph_bill.py +5 -49
- robosystems_client/api/graph_billing/get_graph_billing_history.py +4 -42
- robosystems_client/api/graph_billing/get_graph_monthly_bill.py +5 -49
- robosystems_client/api/graph_billing/get_graph_usage_details.py +4 -42
- robosystems_client/api/graph_credits/check_credit_balance.py +0 -38
- robosystems_client/api/graph_credits/check_storage_limits.py +1 -45
- robosystems_client/api/graph_credits/get_credit_summary.py +1 -45
- robosystems_client/api/graph_credits/get_storage_usage.py +0 -38
- robosystems_client/api/graph_credits/list_credit_transactions.py +4 -42
- robosystems_client/api/graph_health/get_database_health.py +5 -49
- robosystems_client/api/graph_info/get_database_info.py +5 -49
- robosystems_client/api/graph_limits/get_graph_limits.py +5 -49
- robosystems_client/api/graphs/create_graph.py +21 -57
- robosystems_client/api/graphs/get_available_extensions.py +131 -15
- robosystems_client/api/graphs/get_graphs.py +154 -79
- robosystems_client/api/graphs/select_graph.py +117 -49
- robosystems_client/api/mcp/call_mcp_tool.py +24 -47
- robosystems_client/api/mcp/list_mcp_tools.py +13 -61
- robosystems_client/api/operations/cancel_operation.py +1 -45
- robosystems_client/api/operations/get_operation_status.py +1 -45
- robosystems_client/api/query/execute_cypher_query.py +69 -53
- robosystems_client/api/schema/export_graph_schema.py +223 -65
- robosystems_client/api/schema/get_graph_schema.py +137 -79
- robosystems_client/api/schema/validate_schema.py +5 -45
- robosystems_client/api/subgraphs/create_subgraph.py +5 -45
- robosystems_client/api/subgraphs/delete_subgraph.py +5 -45
- robosystems_client/api/subgraphs/get_subgraph_info.py +5 -49
- robosystems_client/api/subgraphs/get_subgraph_quota.py +5 -49
- robosystems_client/api/subgraphs/list_subgraphs.py +5 -49
- robosystems_client/api/tables/delete_file.py +181 -301
- robosystems_client/api/tables/get_file_info.py +117 -265
- robosystems_client/api/tables/get_upload_url.py +193 -389
- robosystems_client/api/tables/ingest_tables.py +277 -465
- robosystems_client/api/tables/list_table_files.py +193 -373
- robosystems_client/api/tables/list_tables.py +189 -361
- robosystems_client/api/tables/query_tables.py +85 -141
- robosystems_client/api/tables/update_file_status.py +205 -349
- robosystems_client/api/user/create_user_api_key.py +1 -41
- robosystems_client/api/user/get_all_credit_summaries.py +14 -111
- robosystems_client/api/user/get_current_user.py +14 -75
- robosystems_client/api/user/list_user_api_keys.py +14 -75
- robosystems_client/api/user/revoke_user_api_key.py +1 -45
- robosystems_client/api/user/update_user.py +1 -41
- robosystems_client/api/user/update_user_api_key.py +1 -41
- robosystems_client/api/user/update_user_password.py +1 -41
- robosystems_client/api/user_analytics/get_detailed_user_analytics.py +0 -38
- robosystems_client/api/user_analytics/get_user_usage_overview.py +14 -75
- robosystems_client/api/user_limits/get_all_shared_repository_limits.py +14 -105
- robosystems_client/api/user_limits/get_shared_repository_limits.py +1 -45
- robosystems_client/api/user_limits/get_user_limits.py +14 -75
- robosystems_client/api/user_limits/get_user_usage.py +14 -75
- robosystems_client/api/user_subscriptions/cancel_shared_repository_subscription.py +1 -45
- robosystems_client/api/user_subscriptions/get_repository_credits.py +1 -45
- robosystems_client/api/user_subscriptions/get_shared_repository_credits.py +14 -75
- robosystems_client/api/user_subscriptions/get_user_shared_subscriptions.py +0 -38
- robosystems_client/api/user_subscriptions/subscribe_to_shared_repository.py +1 -41
- robosystems_client/api/user_subscriptions/upgrade_shared_repository_subscription.py +1 -41
- robosystems_client/extensions/__init__.py +8 -1
- robosystems_client/extensions/auth_integration.py +1 -2
- robosystems_client/extensions/query_client.py +3 -2
- robosystems_client/extensions/sse_client.py +1 -1
- robosystems_client/extensions/table_ingest_client.py +5 -0
- robosystems_client/extensions/utils.py +2 -2
- robosystems_client/models/__init__.py +4 -4
- robosystems_client/models/create_graph_request.py +4 -3
- robosystems_client/models/cypher_query_request.py +5 -22
- robosystems_client/models/schema_export_response.py +4 -2
- robosystems_client/models/schema_info_response.py +77 -0
- robosystems_client/models/{get_graph_schema_response_getgraphschema.py → schema_info_response_schema.py} +6 -6
- robosystems_client/models/schema_validation_response.py +7 -6
- robosystems_client/models/table_query_request.py +37 -2
- {robosystems_client-0.2.3.dist-info → robosystems_client-0.2.4.dist-info}/METADATA +2 -4
- {robosystems_client-0.2.3.dist-info → robosystems_client-0.2.4.dist-info}/RECORD +103 -102
- {robosystems_client-0.2.3.dist-info → robosystems_client-0.2.4.dist-info}/WHEEL +0 -0
- {robosystems_client-0.2.3.dist-info → robosystems_client-0.2.4.dist-info}/licenses/LICENSE +0 -0
|
@@ -9,37 +9,17 @@ from ...models.get_shared_repository_limits_response_getsharedrepositorylimits i
|
|
|
9
9
|
GetSharedRepositoryLimitsResponseGetsharedrepositorylimits,
|
|
10
10
|
)
|
|
11
11
|
from ...models.http_validation_error import HTTPValidationError
|
|
12
|
-
from ...types import
|
|
12
|
+
from ...types import Response
|
|
13
13
|
|
|
14
14
|
|
|
15
15
|
def _get_kwargs(
|
|
16
16
|
repository: str,
|
|
17
|
-
*,
|
|
18
|
-
token: Union[None, Unset, str] = UNSET,
|
|
19
|
-
authorization: Union[None, Unset, str] = UNSET,
|
|
20
17
|
) -> dict[str, Any]:
|
|
21
|
-
headers: dict[str, Any] = {}
|
|
22
|
-
if not isinstance(authorization, Unset):
|
|
23
|
-
headers["authorization"] = authorization
|
|
24
|
-
|
|
25
|
-
params: dict[str, Any] = {}
|
|
26
|
-
|
|
27
|
-
json_token: Union[None, Unset, str]
|
|
28
|
-
if isinstance(token, Unset):
|
|
29
|
-
json_token = UNSET
|
|
30
|
-
else:
|
|
31
|
-
json_token = token
|
|
32
|
-
params["token"] = json_token
|
|
33
|
-
|
|
34
|
-
params = {k: v for k, v in params.items() if v is not UNSET and v is not None}
|
|
35
|
-
|
|
36
18
|
_kwargs: dict[str, Any] = {
|
|
37
19
|
"method": "get",
|
|
38
20
|
"url": f"/v1/user/limits/shared-repositories/{repository}",
|
|
39
|
-
"params": params,
|
|
40
21
|
}
|
|
41
22
|
|
|
42
|
-
_kwargs["headers"] = headers
|
|
43
23
|
return _kwargs
|
|
44
24
|
|
|
45
25
|
|
|
@@ -83,8 +63,6 @@ def sync_detailed(
|
|
|
83
63
|
repository: str,
|
|
84
64
|
*,
|
|
85
65
|
client: AuthenticatedClient,
|
|
86
|
-
token: Union[None, Unset, str] = UNSET,
|
|
87
|
-
authorization: Union[None, Unset, str] = UNSET,
|
|
88
66
|
) -> Response[
|
|
89
67
|
Union[GetSharedRepositoryLimitsResponseGetsharedrepositorylimits, HTTPValidationError]
|
|
90
68
|
]:
|
|
@@ -102,8 +80,6 @@ def sync_detailed(
|
|
|
102
80
|
|
|
103
81
|
Args:
|
|
104
82
|
repository (str): Repository name (e.g., 'sec')
|
|
105
|
-
token (Union[None, Unset, str]): JWT token for SSE authentication
|
|
106
|
-
authorization (Union[None, Unset, str]):
|
|
107
83
|
|
|
108
84
|
Raises:
|
|
109
85
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
@@ -115,8 +91,6 @@ def sync_detailed(
|
|
|
115
91
|
|
|
116
92
|
kwargs = _get_kwargs(
|
|
117
93
|
repository=repository,
|
|
118
|
-
token=token,
|
|
119
|
-
authorization=authorization,
|
|
120
94
|
)
|
|
121
95
|
|
|
122
96
|
response = client.get_httpx_client().request(
|
|
@@ -130,8 +104,6 @@ def sync(
|
|
|
130
104
|
repository: str,
|
|
131
105
|
*,
|
|
132
106
|
client: AuthenticatedClient,
|
|
133
|
-
token: Union[None, Unset, str] = UNSET,
|
|
134
|
-
authorization: Union[None, Unset, str] = UNSET,
|
|
135
107
|
) -> Optional[
|
|
136
108
|
Union[GetSharedRepositoryLimitsResponseGetsharedrepositorylimits, HTTPValidationError]
|
|
137
109
|
]:
|
|
@@ -149,8 +121,6 @@ def sync(
|
|
|
149
121
|
|
|
150
122
|
Args:
|
|
151
123
|
repository (str): Repository name (e.g., 'sec')
|
|
152
|
-
token (Union[None, Unset, str]): JWT token for SSE authentication
|
|
153
|
-
authorization (Union[None, Unset, str]):
|
|
154
124
|
|
|
155
125
|
Raises:
|
|
156
126
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
@@ -163,8 +133,6 @@ def sync(
|
|
|
163
133
|
return sync_detailed(
|
|
164
134
|
repository=repository,
|
|
165
135
|
client=client,
|
|
166
|
-
token=token,
|
|
167
|
-
authorization=authorization,
|
|
168
136
|
).parsed
|
|
169
137
|
|
|
170
138
|
|
|
@@ -172,8 +140,6 @@ async def asyncio_detailed(
|
|
|
172
140
|
repository: str,
|
|
173
141
|
*,
|
|
174
142
|
client: AuthenticatedClient,
|
|
175
|
-
token: Union[None, Unset, str] = UNSET,
|
|
176
|
-
authorization: Union[None, Unset, str] = UNSET,
|
|
177
143
|
) -> Response[
|
|
178
144
|
Union[GetSharedRepositoryLimitsResponseGetsharedrepositorylimits, HTTPValidationError]
|
|
179
145
|
]:
|
|
@@ -191,8 +157,6 @@ async def asyncio_detailed(
|
|
|
191
157
|
|
|
192
158
|
Args:
|
|
193
159
|
repository (str): Repository name (e.g., 'sec')
|
|
194
|
-
token (Union[None, Unset, str]): JWT token for SSE authentication
|
|
195
|
-
authorization (Union[None, Unset, str]):
|
|
196
160
|
|
|
197
161
|
Raises:
|
|
198
162
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
@@ -204,8 +168,6 @@ async def asyncio_detailed(
|
|
|
204
168
|
|
|
205
169
|
kwargs = _get_kwargs(
|
|
206
170
|
repository=repository,
|
|
207
|
-
token=token,
|
|
208
|
-
authorization=authorization,
|
|
209
171
|
)
|
|
210
172
|
|
|
211
173
|
response = await client.get_async_httpx_client().request(**kwargs)
|
|
@@ -217,8 +179,6 @@ async def asyncio(
|
|
|
217
179
|
repository: str,
|
|
218
180
|
*,
|
|
219
181
|
client: AuthenticatedClient,
|
|
220
|
-
token: Union[None, Unset, str] = UNSET,
|
|
221
|
-
authorization: Union[None, Unset, str] = UNSET,
|
|
222
182
|
) -> Optional[
|
|
223
183
|
Union[GetSharedRepositoryLimitsResponseGetsharedrepositorylimits, HTTPValidationError]
|
|
224
184
|
]:
|
|
@@ -236,8 +196,6 @@ async def asyncio(
|
|
|
236
196
|
|
|
237
197
|
Args:
|
|
238
198
|
repository (str): Repository name (e.g., 'sec')
|
|
239
|
-
token (Union[None, Unset, str]): JWT token for SSE authentication
|
|
240
|
-
authorization (Union[None, Unset, str]):
|
|
241
199
|
|
|
242
200
|
Raises:
|
|
243
201
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
@@ -251,7 +209,5 @@ async def asyncio(
|
|
|
251
209
|
await asyncio_detailed(
|
|
252
210
|
repository=repository,
|
|
253
211
|
client=client,
|
|
254
|
-
token=token,
|
|
255
|
-
authorization=authorization,
|
|
256
212
|
)
|
|
257
213
|
).parsed
|
|
@@ -5,44 +5,22 @@ import httpx
|
|
|
5
5
|
|
|
6
6
|
from ... import errors
|
|
7
7
|
from ...client import AuthenticatedClient, Client
|
|
8
|
-
from ...models.http_validation_error import HTTPValidationError
|
|
9
8
|
from ...models.user_limits_response import UserLimitsResponse
|
|
10
|
-
from ...types import
|
|
9
|
+
from ...types import Response
|
|
11
10
|
|
|
12
11
|
|
|
13
|
-
def _get_kwargs(
|
|
14
|
-
*,
|
|
15
|
-
token: Union[None, Unset, str] = UNSET,
|
|
16
|
-
authorization: Union[None, Unset, str] = UNSET,
|
|
17
|
-
) -> dict[str, Any]:
|
|
18
|
-
headers: dict[str, Any] = {}
|
|
19
|
-
if not isinstance(authorization, Unset):
|
|
20
|
-
headers["authorization"] = authorization
|
|
21
|
-
|
|
22
|
-
params: dict[str, Any] = {}
|
|
23
|
-
|
|
24
|
-
json_token: Union[None, Unset, str]
|
|
25
|
-
if isinstance(token, Unset):
|
|
26
|
-
json_token = UNSET
|
|
27
|
-
else:
|
|
28
|
-
json_token = token
|
|
29
|
-
params["token"] = json_token
|
|
30
|
-
|
|
31
|
-
params = {k: v for k, v in params.items() if v is not UNSET and v is not None}
|
|
32
|
-
|
|
12
|
+
def _get_kwargs() -> dict[str, Any]:
|
|
33
13
|
_kwargs: dict[str, Any] = {
|
|
34
14
|
"method": "get",
|
|
35
15
|
"url": "/v1/user/limits",
|
|
36
|
-
"params": params,
|
|
37
16
|
}
|
|
38
17
|
|
|
39
|
-
_kwargs["headers"] = headers
|
|
40
18
|
return _kwargs
|
|
41
19
|
|
|
42
20
|
|
|
43
21
|
def _parse_response(
|
|
44
22
|
*, client: Union[AuthenticatedClient, Client], response: httpx.Response
|
|
45
|
-
) -> Optional[Union[Any,
|
|
23
|
+
) -> Optional[Union[Any, UserLimitsResponse]]:
|
|
46
24
|
if response.status_code == 200:
|
|
47
25
|
response_200 = UserLimitsResponse.from_dict(response.json())
|
|
48
26
|
|
|
@@ -52,11 +30,6 @@ def _parse_response(
|
|
|
52
30
|
response_404 = cast(Any, None)
|
|
53
31
|
return response_404
|
|
54
32
|
|
|
55
|
-
if response.status_code == 422:
|
|
56
|
-
response_422 = HTTPValidationError.from_dict(response.json())
|
|
57
|
-
|
|
58
|
-
return response_422
|
|
59
|
-
|
|
60
33
|
if client.raise_on_unexpected_status:
|
|
61
34
|
raise errors.UnexpectedStatus(response.status_code, response.content)
|
|
62
35
|
else:
|
|
@@ -65,7 +38,7 @@ def _parse_response(
|
|
|
65
38
|
|
|
66
39
|
def _build_response(
|
|
67
40
|
*, client: Union[AuthenticatedClient, Client], response: httpx.Response
|
|
68
|
-
) -> Response[Union[Any,
|
|
41
|
+
) -> Response[Union[Any, UserLimitsResponse]]:
|
|
69
42
|
return Response(
|
|
70
43
|
status_code=HTTPStatus(response.status_code),
|
|
71
44
|
content=response.content,
|
|
@@ -77,29 +50,20 @@ def _build_response(
|
|
|
77
50
|
def sync_detailed(
|
|
78
51
|
*,
|
|
79
52
|
client: AuthenticatedClient,
|
|
80
|
-
|
|
81
|
-
authorization: Union[None, Unset, str] = UNSET,
|
|
82
|
-
) -> Response[Union[Any, HTTPValidationError, UserLimitsResponse]]:
|
|
53
|
+
) -> Response[Union[Any, UserLimitsResponse]]:
|
|
83
54
|
"""Get user limits
|
|
84
55
|
|
|
85
56
|
Retrieve current limits and restrictions for the authenticated user
|
|
86
57
|
|
|
87
|
-
Args:
|
|
88
|
-
token (Union[None, Unset, str]): JWT token for SSE authentication
|
|
89
|
-
authorization (Union[None, Unset, str]):
|
|
90
|
-
|
|
91
58
|
Raises:
|
|
92
59
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
93
60
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
94
61
|
|
|
95
62
|
Returns:
|
|
96
|
-
Response[Union[Any,
|
|
63
|
+
Response[Union[Any, UserLimitsResponse]]
|
|
97
64
|
"""
|
|
98
65
|
|
|
99
|
-
kwargs = _get_kwargs(
|
|
100
|
-
token=token,
|
|
101
|
-
authorization=authorization,
|
|
102
|
-
)
|
|
66
|
+
kwargs = _get_kwargs()
|
|
103
67
|
|
|
104
68
|
response = client.get_httpx_client().request(
|
|
105
69
|
**kwargs,
|
|
@@ -111,58 +75,41 @@ def sync_detailed(
|
|
|
111
75
|
def sync(
|
|
112
76
|
*,
|
|
113
77
|
client: AuthenticatedClient,
|
|
114
|
-
|
|
115
|
-
authorization: Union[None, Unset, str] = UNSET,
|
|
116
|
-
) -> Optional[Union[Any, HTTPValidationError, UserLimitsResponse]]:
|
|
78
|
+
) -> Optional[Union[Any, UserLimitsResponse]]:
|
|
117
79
|
"""Get user limits
|
|
118
80
|
|
|
119
81
|
Retrieve current limits and restrictions for the authenticated user
|
|
120
82
|
|
|
121
|
-
Args:
|
|
122
|
-
token (Union[None, Unset, str]): JWT token for SSE authentication
|
|
123
|
-
authorization (Union[None, Unset, str]):
|
|
124
|
-
|
|
125
83
|
Raises:
|
|
126
84
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
127
85
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
128
86
|
|
|
129
87
|
Returns:
|
|
130
|
-
Union[Any,
|
|
88
|
+
Union[Any, UserLimitsResponse]
|
|
131
89
|
"""
|
|
132
90
|
|
|
133
91
|
return sync_detailed(
|
|
134
92
|
client=client,
|
|
135
|
-
token=token,
|
|
136
|
-
authorization=authorization,
|
|
137
93
|
).parsed
|
|
138
94
|
|
|
139
95
|
|
|
140
96
|
async def asyncio_detailed(
|
|
141
97
|
*,
|
|
142
98
|
client: AuthenticatedClient,
|
|
143
|
-
|
|
144
|
-
authorization: Union[None, Unset, str] = UNSET,
|
|
145
|
-
) -> Response[Union[Any, HTTPValidationError, UserLimitsResponse]]:
|
|
99
|
+
) -> Response[Union[Any, UserLimitsResponse]]:
|
|
146
100
|
"""Get user limits
|
|
147
101
|
|
|
148
102
|
Retrieve current limits and restrictions for the authenticated user
|
|
149
103
|
|
|
150
|
-
Args:
|
|
151
|
-
token (Union[None, Unset, str]): JWT token for SSE authentication
|
|
152
|
-
authorization (Union[None, Unset, str]):
|
|
153
|
-
|
|
154
104
|
Raises:
|
|
155
105
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
156
106
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
157
107
|
|
|
158
108
|
Returns:
|
|
159
|
-
Response[Union[Any,
|
|
109
|
+
Response[Union[Any, UserLimitsResponse]]
|
|
160
110
|
"""
|
|
161
111
|
|
|
162
|
-
kwargs = _get_kwargs(
|
|
163
|
-
token=token,
|
|
164
|
-
authorization=authorization,
|
|
165
|
-
)
|
|
112
|
+
kwargs = _get_kwargs()
|
|
166
113
|
|
|
167
114
|
response = await client.get_async_httpx_client().request(**kwargs)
|
|
168
115
|
|
|
@@ -172,29 +119,21 @@ async def asyncio_detailed(
|
|
|
172
119
|
async def asyncio(
|
|
173
120
|
*,
|
|
174
121
|
client: AuthenticatedClient,
|
|
175
|
-
|
|
176
|
-
authorization: Union[None, Unset, str] = UNSET,
|
|
177
|
-
) -> Optional[Union[Any, HTTPValidationError, UserLimitsResponse]]:
|
|
122
|
+
) -> Optional[Union[Any, UserLimitsResponse]]:
|
|
178
123
|
"""Get user limits
|
|
179
124
|
|
|
180
125
|
Retrieve current limits and restrictions for the authenticated user
|
|
181
126
|
|
|
182
|
-
Args:
|
|
183
|
-
token (Union[None, Unset, str]): JWT token for SSE authentication
|
|
184
|
-
authorization (Union[None, Unset, str]):
|
|
185
|
-
|
|
186
127
|
Raises:
|
|
187
128
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
188
129
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
189
130
|
|
|
190
131
|
Returns:
|
|
191
|
-
Union[Any,
|
|
132
|
+
Union[Any, UserLimitsResponse]
|
|
192
133
|
"""
|
|
193
134
|
|
|
194
135
|
return (
|
|
195
136
|
await asyncio_detailed(
|
|
196
137
|
client=client,
|
|
197
|
-
token=token,
|
|
198
|
-
authorization=authorization,
|
|
199
138
|
)
|
|
200
139
|
).parsed
|
|
@@ -5,54 +5,27 @@ import httpx
|
|
|
5
5
|
|
|
6
6
|
from ... import errors
|
|
7
7
|
from ...client import AuthenticatedClient, Client
|
|
8
|
-
from ...models.http_validation_error import HTTPValidationError
|
|
9
8
|
from ...models.user_usage_response import UserUsageResponse
|
|
10
|
-
from ...types import
|
|
9
|
+
from ...types import Response
|
|
11
10
|
|
|
12
11
|
|
|
13
|
-
def _get_kwargs(
|
|
14
|
-
*,
|
|
15
|
-
token: Union[None, Unset, str] = UNSET,
|
|
16
|
-
authorization: Union[None, Unset, str] = UNSET,
|
|
17
|
-
) -> dict[str, Any]:
|
|
18
|
-
headers: dict[str, Any] = {}
|
|
19
|
-
if not isinstance(authorization, Unset):
|
|
20
|
-
headers["authorization"] = authorization
|
|
21
|
-
|
|
22
|
-
params: dict[str, Any] = {}
|
|
23
|
-
|
|
24
|
-
json_token: Union[None, Unset, str]
|
|
25
|
-
if isinstance(token, Unset):
|
|
26
|
-
json_token = UNSET
|
|
27
|
-
else:
|
|
28
|
-
json_token = token
|
|
29
|
-
params["token"] = json_token
|
|
30
|
-
|
|
31
|
-
params = {k: v for k, v in params.items() if v is not UNSET and v is not None}
|
|
32
|
-
|
|
12
|
+
def _get_kwargs() -> dict[str, Any]:
|
|
33
13
|
_kwargs: dict[str, Any] = {
|
|
34
14
|
"method": "get",
|
|
35
15
|
"url": "/v1/user/limits/usage",
|
|
36
|
-
"params": params,
|
|
37
16
|
}
|
|
38
17
|
|
|
39
|
-
_kwargs["headers"] = headers
|
|
40
18
|
return _kwargs
|
|
41
19
|
|
|
42
20
|
|
|
43
21
|
def _parse_response(
|
|
44
22
|
*, client: Union[AuthenticatedClient, Client], response: httpx.Response
|
|
45
|
-
) -> Optional[
|
|
23
|
+
) -> Optional[UserUsageResponse]:
|
|
46
24
|
if response.status_code == 200:
|
|
47
25
|
response_200 = UserUsageResponse.from_dict(response.json())
|
|
48
26
|
|
|
49
27
|
return response_200
|
|
50
28
|
|
|
51
|
-
if response.status_code == 422:
|
|
52
|
-
response_422 = HTTPValidationError.from_dict(response.json())
|
|
53
|
-
|
|
54
|
-
return response_422
|
|
55
|
-
|
|
56
29
|
if client.raise_on_unexpected_status:
|
|
57
30
|
raise errors.UnexpectedStatus(response.status_code, response.content)
|
|
58
31
|
else:
|
|
@@ -61,7 +34,7 @@ def _parse_response(
|
|
|
61
34
|
|
|
62
35
|
def _build_response(
|
|
63
36
|
*, client: Union[AuthenticatedClient, Client], response: httpx.Response
|
|
64
|
-
) -> Response[
|
|
37
|
+
) -> Response[UserUsageResponse]:
|
|
65
38
|
return Response(
|
|
66
39
|
status_code=HTTPStatus(response.status_code),
|
|
67
40
|
content=response.content,
|
|
@@ -73,29 +46,20 @@ def _build_response(
|
|
|
73
46
|
def sync_detailed(
|
|
74
47
|
*,
|
|
75
48
|
client: AuthenticatedClient,
|
|
76
|
-
|
|
77
|
-
authorization: Union[None, Unset, str] = UNSET,
|
|
78
|
-
) -> Response[Union[HTTPValidationError, UserUsageResponse]]:
|
|
49
|
+
) -> Response[UserUsageResponse]:
|
|
79
50
|
"""Get user usage statistics
|
|
80
51
|
|
|
81
52
|
Retrieve current usage statistics and remaining limits for the authenticated user
|
|
82
53
|
|
|
83
|
-
Args:
|
|
84
|
-
token (Union[None, Unset, str]): JWT token for SSE authentication
|
|
85
|
-
authorization (Union[None, Unset, str]):
|
|
86
|
-
|
|
87
54
|
Raises:
|
|
88
55
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
89
56
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
90
57
|
|
|
91
58
|
Returns:
|
|
92
|
-
Response[
|
|
59
|
+
Response[UserUsageResponse]
|
|
93
60
|
"""
|
|
94
61
|
|
|
95
|
-
kwargs = _get_kwargs(
|
|
96
|
-
token=token,
|
|
97
|
-
authorization=authorization,
|
|
98
|
-
)
|
|
62
|
+
kwargs = _get_kwargs()
|
|
99
63
|
|
|
100
64
|
response = client.get_httpx_client().request(
|
|
101
65
|
**kwargs,
|
|
@@ -107,58 +71,41 @@ def sync_detailed(
|
|
|
107
71
|
def sync(
|
|
108
72
|
*,
|
|
109
73
|
client: AuthenticatedClient,
|
|
110
|
-
|
|
111
|
-
authorization: Union[None, Unset, str] = UNSET,
|
|
112
|
-
) -> Optional[Union[HTTPValidationError, UserUsageResponse]]:
|
|
74
|
+
) -> Optional[UserUsageResponse]:
|
|
113
75
|
"""Get user usage statistics
|
|
114
76
|
|
|
115
77
|
Retrieve current usage statistics and remaining limits for the authenticated user
|
|
116
78
|
|
|
117
|
-
Args:
|
|
118
|
-
token (Union[None, Unset, str]): JWT token for SSE authentication
|
|
119
|
-
authorization (Union[None, Unset, str]):
|
|
120
|
-
|
|
121
79
|
Raises:
|
|
122
80
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
123
81
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
124
82
|
|
|
125
83
|
Returns:
|
|
126
|
-
|
|
84
|
+
UserUsageResponse
|
|
127
85
|
"""
|
|
128
86
|
|
|
129
87
|
return sync_detailed(
|
|
130
88
|
client=client,
|
|
131
|
-
token=token,
|
|
132
|
-
authorization=authorization,
|
|
133
89
|
).parsed
|
|
134
90
|
|
|
135
91
|
|
|
136
92
|
async def asyncio_detailed(
|
|
137
93
|
*,
|
|
138
94
|
client: AuthenticatedClient,
|
|
139
|
-
|
|
140
|
-
authorization: Union[None, Unset, str] = UNSET,
|
|
141
|
-
) -> Response[Union[HTTPValidationError, UserUsageResponse]]:
|
|
95
|
+
) -> Response[UserUsageResponse]:
|
|
142
96
|
"""Get user usage statistics
|
|
143
97
|
|
|
144
98
|
Retrieve current usage statistics and remaining limits for the authenticated user
|
|
145
99
|
|
|
146
|
-
Args:
|
|
147
|
-
token (Union[None, Unset, str]): JWT token for SSE authentication
|
|
148
|
-
authorization (Union[None, Unset, str]):
|
|
149
|
-
|
|
150
100
|
Raises:
|
|
151
101
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
152
102
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
153
103
|
|
|
154
104
|
Returns:
|
|
155
|
-
Response[
|
|
105
|
+
Response[UserUsageResponse]
|
|
156
106
|
"""
|
|
157
107
|
|
|
158
|
-
kwargs = _get_kwargs(
|
|
159
|
-
token=token,
|
|
160
|
-
authorization=authorization,
|
|
161
|
-
)
|
|
108
|
+
kwargs = _get_kwargs()
|
|
162
109
|
|
|
163
110
|
response = await client.get_async_httpx_client().request(**kwargs)
|
|
164
111
|
|
|
@@ -168,29 +115,21 @@ async def asyncio_detailed(
|
|
|
168
115
|
async def asyncio(
|
|
169
116
|
*,
|
|
170
117
|
client: AuthenticatedClient,
|
|
171
|
-
|
|
172
|
-
authorization: Union[None, Unset, str] = UNSET,
|
|
173
|
-
) -> Optional[Union[HTTPValidationError, UserUsageResponse]]:
|
|
118
|
+
) -> Optional[UserUsageResponse]:
|
|
174
119
|
"""Get user usage statistics
|
|
175
120
|
|
|
176
121
|
Retrieve current usage statistics and remaining limits for the authenticated user
|
|
177
122
|
|
|
178
|
-
Args:
|
|
179
|
-
token (Union[None, Unset, str]): JWT token for SSE authentication
|
|
180
|
-
authorization (Union[None, Unset, str]):
|
|
181
|
-
|
|
182
123
|
Raises:
|
|
183
124
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
184
125
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
185
126
|
|
|
186
127
|
Returns:
|
|
187
|
-
|
|
128
|
+
UserUsageResponse
|
|
188
129
|
"""
|
|
189
130
|
|
|
190
131
|
return (
|
|
191
132
|
await asyncio_detailed(
|
|
192
133
|
client=client,
|
|
193
|
-
token=token,
|
|
194
|
-
authorization=authorization,
|
|
195
134
|
)
|
|
196
135
|
).parsed
|
|
@@ -7,37 +7,17 @@ from ... import errors
|
|
|
7
7
|
from ...client import AuthenticatedClient, Client
|
|
8
8
|
from ...models.cancellation_response import CancellationResponse
|
|
9
9
|
from ...models.http_validation_error import HTTPValidationError
|
|
10
|
-
from ...types import
|
|
10
|
+
from ...types import Response
|
|
11
11
|
|
|
12
12
|
|
|
13
13
|
def _get_kwargs(
|
|
14
14
|
subscription_id: str,
|
|
15
|
-
*,
|
|
16
|
-
token: Union[None, Unset, str] = UNSET,
|
|
17
|
-
authorization: Union[None, Unset, str] = UNSET,
|
|
18
15
|
) -> dict[str, Any]:
|
|
19
|
-
headers: dict[str, Any] = {}
|
|
20
|
-
if not isinstance(authorization, Unset):
|
|
21
|
-
headers["authorization"] = authorization
|
|
22
|
-
|
|
23
|
-
params: dict[str, Any] = {}
|
|
24
|
-
|
|
25
|
-
json_token: Union[None, Unset, str]
|
|
26
|
-
if isinstance(token, Unset):
|
|
27
|
-
json_token = UNSET
|
|
28
|
-
else:
|
|
29
|
-
json_token = token
|
|
30
|
-
params["token"] = json_token
|
|
31
|
-
|
|
32
|
-
params = {k: v for k, v in params.items() if v is not UNSET and v is not None}
|
|
33
|
-
|
|
34
16
|
_kwargs: dict[str, Any] = {
|
|
35
17
|
"method": "delete",
|
|
36
18
|
"url": f"/v1/user/subscriptions/shared-repositories/{subscription_id}",
|
|
37
|
-
"params": params,
|
|
38
19
|
}
|
|
39
20
|
|
|
40
|
-
_kwargs["headers"] = headers
|
|
41
21
|
return _kwargs
|
|
42
22
|
|
|
43
23
|
|
|
@@ -87,8 +67,6 @@ def sync_detailed(
|
|
|
87
67
|
subscription_id: str,
|
|
88
68
|
*,
|
|
89
69
|
client: AuthenticatedClient,
|
|
90
|
-
token: Union[None, Unset, str] = UNSET,
|
|
91
|
-
authorization: Union[None, Unset, str] = UNSET,
|
|
92
70
|
) -> Response[Union[Any, CancellationResponse, HTTPValidationError]]:
|
|
93
71
|
"""Cancel Subscription
|
|
94
72
|
|
|
@@ -96,8 +74,6 @@ def sync_detailed(
|
|
|
96
74
|
|
|
97
75
|
Args:
|
|
98
76
|
subscription_id (str):
|
|
99
|
-
token (Union[None, Unset, str]): JWT token for SSE authentication
|
|
100
|
-
authorization (Union[None, Unset, str]):
|
|
101
77
|
|
|
102
78
|
Raises:
|
|
103
79
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
@@ -109,8 +85,6 @@ def sync_detailed(
|
|
|
109
85
|
|
|
110
86
|
kwargs = _get_kwargs(
|
|
111
87
|
subscription_id=subscription_id,
|
|
112
|
-
token=token,
|
|
113
|
-
authorization=authorization,
|
|
114
88
|
)
|
|
115
89
|
|
|
116
90
|
response = client.get_httpx_client().request(
|
|
@@ -124,8 +98,6 @@ def sync(
|
|
|
124
98
|
subscription_id: str,
|
|
125
99
|
*,
|
|
126
100
|
client: AuthenticatedClient,
|
|
127
|
-
token: Union[None, Unset, str] = UNSET,
|
|
128
|
-
authorization: Union[None, Unset, str] = UNSET,
|
|
129
101
|
) -> Optional[Union[Any, CancellationResponse, HTTPValidationError]]:
|
|
130
102
|
"""Cancel Subscription
|
|
131
103
|
|
|
@@ -133,8 +105,6 @@ def sync(
|
|
|
133
105
|
|
|
134
106
|
Args:
|
|
135
107
|
subscription_id (str):
|
|
136
|
-
token (Union[None, Unset, str]): JWT token for SSE authentication
|
|
137
|
-
authorization (Union[None, Unset, str]):
|
|
138
108
|
|
|
139
109
|
Raises:
|
|
140
110
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
@@ -147,8 +117,6 @@ def sync(
|
|
|
147
117
|
return sync_detailed(
|
|
148
118
|
subscription_id=subscription_id,
|
|
149
119
|
client=client,
|
|
150
|
-
token=token,
|
|
151
|
-
authorization=authorization,
|
|
152
120
|
).parsed
|
|
153
121
|
|
|
154
122
|
|
|
@@ -156,8 +124,6 @@ async def asyncio_detailed(
|
|
|
156
124
|
subscription_id: str,
|
|
157
125
|
*,
|
|
158
126
|
client: AuthenticatedClient,
|
|
159
|
-
token: Union[None, Unset, str] = UNSET,
|
|
160
|
-
authorization: Union[None, Unset, str] = UNSET,
|
|
161
127
|
) -> Response[Union[Any, CancellationResponse, HTTPValidationError]]:
|
|
162
128
|
"""Cancel Subscription
|
|
163
129
|
|
|
@@ -165,8 +131,6 @@ async def asyncio_detailed(
|
|
|
165
131
|
|
|
166
132
|
Args:
|
|
167
133
|
subscription_id (str):
|
|
168
|
-
token (Union[None, Unset, str]): JWT token for SSE authentication
|
|
169
|
-
authorization (Union[None, Unset, str]):
|
|
170
134
|
|
|
171
135
|
Raises:
|
|
172
136
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
@@ -178,8 +142,6 @@ async def asyncio_detailed(
|
|
|
178
142
|
|
|
179
143
|
kwargs = _get_kwargs(
|
|
180
144
|
subscription_id=subscription_id,
|
|
181
|
-
token=token,
|
|
182
|
-
authorization=authorization,
|
|
183
145
|
)
|
|
184
146
|
|
|
185
147
|
response = await client.get_async_httpx_client().request(**kwargs)
|
|
@@ -191,8 +153,6 @@ async def asyncio(
|
|
|
191
153
|
subscription_id: str,
|
|
192
154
|
*,
|
|
193
155
|
client: AuthenticatedClient,
|
|
194
|
-
token: Union[None, Unset, str] = UNSET,
|
|
195
|
-
authorization: Union[None, Unset, str] = UNSET,
|
|
196
156
|
) -> Optional[Union[Any, CancellationResponse, HTTPValidationError]]:
|
|
197
157
|
"""Cancel Subscription
|
|
198
158
|
|
|
@@ -200,8 +160,6 @@ async def asyncio(
|
|
|
200
160
|
|
|
201
161
|
Args:
|
|
202
162
|
subscription_id (str):
|
|
203
|
-
token (Union[None, Unset, str]): JWT token for SSE authentication
|
|
204
|
-
authorization (Union[None, Unset, str]):
|
|
205
163
|
|
|
206
164
|
Raises:
|
|
207
165
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
@@ -215,7 +173,5 @@ async def asyncio(
|
|
|
215
173
|
await asyncio_detailed(
|
|
216
174
|
subscription_id=subscription_id,
|
|
217
175
|
client=client,
|
|
218
|
-
token=token,
|
|
219
|
-
authorization=authorization,
|
|
220
176
|
)
|
|
221
177
|
).parsed
|