robosystems-client 0.1.12__py3-none-any.whl → 0.1.14__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.
- robosystems_client/api/backup/create_backup.py +1 -1
- robosystems_client/api/backup/export_backup.py +14 -19
- robosystems_client/api/backup/get_backup_download_url.py +1 -1
- robosystems_client/api/backup/get_backup_stats.py +19 -1
- robosystems_client/api/backup/list_backups.py +19 -1
- robosystems_client/api/backup/restore_backup.py +1 -1
- robosystems_client/api/copy/copy_data_to_graph.py +479 -0
- robosystems_client/api/{credits_ → graph_credits}/check_credit_balance.py +42 -20
- robosystems_client/api/graph_health/__init__.py +1 -0
- robosystems_client/api/{graph_status → graph_health}/get_database_health.py +1 -1
- robosystems_client/api/graph_info/__init__.py +1 -0
- robosystems_client/api/{graph_status → graph_info}/get_database_info.py +1 -1
- robosystems_client/api/graph_limits/__init__.py +1 -0
- robosystems_client/api/graph_limits/get_graph_limits.py +259 -0
- robosystems_client/api/subgraphs/create_subgraph.py +63 -173
- robosystems_client/api/subgraphs/delete_subgraph.py +14 -14
- robosystems_client/api/subgraphs/get_subgraph_info.py +14 -14
- robosystems_client/api/subgraphs/get_subgraph_quota.py +8 -4
- robosystems_client/api/subgraphs/list_subgraphs.py +39 -75
- robosystems_client/api/user/get_all_credit_summaries.py +1 -1
- robosystems_client/extensions/README.md +211 -0
- robosystems_client/extensions/__init__.py +29 -0
- robosystems_client/extensions/copy_client.py +469 -0
- robosystems_client/extensions/extensions.py +17 -0
- robosystems_client/models/__init__.py +26 -10
- robosystems_client/models/copy_response.py +275 -0
- robosystems_client/models/{kuzu_backup_health_response_kuzubackuphealth.py → copy_response_error_details_type_0.py} +5 -5
- robosystems_client/models/copy_response_status.py +11 -0
- robosystems_client/models/custom_schema_definition.py +2 -2
- robosystems_client/models/data_frame_copy_request.py +125 -0
- robosystems_client/models/data_frame_copy_request_format.py +10 -0
- robosystems_client/models/get_graph_limits_response_getgraphlimits.py +44 -0
- robosystems_client/models/s3_copy_request.py +378 -0
- robosystems_client/models/s3_copy_request_file_format.py +12 -0
- robosystems_client/models/s3_copy_request_s3_url_style_type_0.py +9 -0
- robosystems_client/models/url_copy_request.py +157 -0
- robosystems_client/models/url_copy_request_file_format.py +10 -0
- robosystems_client/models/url_copy_request_headers_type_0.py +44 -0
- {robosystems_client-0.1.12.dist-info → robosystems_client-0.1.14.dist-info}/METADATA +1 -1
- {robosystems_client-0.1.12.dist-info → robosystems_client-0.1.14.dist-info}/RECORD +52 -44
- robosystems_client/api/backup/kuzu_backup_health.py +0 -202
- robosystems_client/api/billing/get_available_subscription_plans_v1_graph_id_billing_available_plans_get.py +0 -198
- robosystems_client/api/billing/get_credit_billing_info_v1_graph_id_billing_credits_get.py +0 -210
- robosystems_client/api/billing/get_graph_pricing_info_v1_graph_id_billing_pricing_get.py +0 -198
- robosystems_client/api/billing/get_graph_subscription_v1_graph_id_billing_subscription_get.py +0 -198
- robosystems_client/api/billing/upgrade_graph_subscription_v1_graph_id_billing_subscription_upgrade_post.py +0 -216
- robosystems_client/models/backup_export_request.py +0 -72
- robosystems_client/models/credit_check_request.py +0 -82
- robosystems_client/models/upgrade_subscription_request.py +0 -82
- /robosystems_client/api/{billing → copy}/__init__.py +0 -0
- /robosystems_client/api/{credits_ → graph_billing}/__init__.py +0 -0
- /robosystems_client/api/{billing → graph_billing}/get_current_graph_bill.py +0 -0
- /robosystems_client/api/{billing → graph_billing}/get_graph_billing_history.py +0 -0
- /robosystems_client/api/{billing → graph_billing}/get_graph_monthly_bill.py +0 -0
- /robosystems_client/api/{billing → graph_billing}/get_graph_usage_details.py +0 -0
- /robosystems_client/api/{graph_status → graph_credits}/__init__.py +0 -0
- /robosystems_client/api/{credits_ → graph_credits}/check_storage_limits.py +0 -0
- /robosystems_client/api/{credits_ → graph_credits}/get_credit_summary.py +0 -0
- /robosystems_client/api/{credits_ → graph_credits}/get_storage_usage.py +0 -0
- /robosystems_client/api/{credits_ → graph_credits}/list_credit_transactions.py +0 -0
- {robosystems_client-0.1.12.dist-info → robosystems_client-0.1.14.dist-info}/WHEEL +0 -0
|
@@ -1,210 +0,0 @@
|
|
|
1
|
-
from http import HTTPStatus
|
|
2
|
-
from typing import Any, Optional, Union
|
|
3
|
-
|
|
4
|
-
import httpx
|
|
5
|
-
|
|
6
|
-
from ... import errors
|
|
7
|
-
from ...client import AuthenticatedClient, Client
|
|
8
|
-
from ...models.http_validation_error import HTTPValidationError
|
|
9
|
-
from ...types import UNSET, Response, Unset
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
def _get_kwargs(
|
|
13
|
-
graph_id: str,
|
|
14
|
-
*,
|
|
15
|
-
authorization: Union[None, Unset, str] = UNSET,
|
|
16
|
-
auth_token: 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
|
-
cookies = {}
|
|
23
|
-
if auth_token is not UNSET:
|
|
24
|
-
cookies["auth-token"] = auth_token
|
|
25
|
-
|
|
26
|
-
_kwargs: dict[str, Any] = {
|
|
27
|
-
"method": "get",
|
|
28
|
-
"url": f"/v1/{graph_id}/billing/credits",
|
|
29
|
-
"cookies": cookies,
|
|
30
|
-
}
|
|
31
|
-
|
|
32
|
-
_kwargs["headers"] = headers
|
|
33
|
-
return _kwargs
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
def _parse_response(
|
|
37
|
-
*, client: Union[AuthenticatedClient, Client], response: httpx.Response
|
|
38
|
-
) -> Optional[Union[Any, HTTPValidationError]]:
|
|
39
|
-
if response.status_code == 200:
|
|
40
|
-
response_200 = response.json()
|
|
41
|
-
return response_200
|
|
42
|
-
if response.status_code == 422:
|
|
43
|
-
response_422 = HTTPValidationError.from_dict(response.json())
|
|
44
|
-
|
|
45
|
-
return response_422
|
|
46
|
-
if client.raise_on_unexpected_status:
|
|
47
|
-
raise errors.UnexpectedStatus(response.status_code, response.content)
|
|
48
|
-
else:
|
|
49
|
-
return None
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
def _build_response(
|
|
53
|
-
*, client: Union[AuthenticatedClient, Client], response: httpx.Response
|
|
54
|
-
) -> Response[Union[Any, HTTPValidationError]]:
|
|
55
|
-
return Response(
|
|
56
|
-
status_code=HTTPStatus(response.status_code),
|
|
57
|
-
content=response.content,
|
|
58
|
-
headers=response.headers,
|
|
59
|
-
parsed=_parse_response(client=client, response=response),
|
|
60
|
-
)
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
def sync_detailed(
|
|
64
|
-
graph_id: str,
|
|
65
|
-
*,
|
|
66
|
-
client: AuthenticatedClient,
|
|
67
|
-
authorization: Union[None, Unset, str] = UNSET,
|
|
68
|
-
auth_token: Union[None, Unset, str] = UNSET,
|
|
69
|
-
) -> Response[Union[Any, HTTPValidationError]]:
|
|
70
|
-
"""Get Credit Billing Info
|
|
71
|
-
|
|
72
|
-
Get credit-based billing information for a specific graph.
|
|
73
|
-
|
|
74
|
-
This endpoint provides comprehensive credit usage and billing information
|
|
75
|
-
without consuming credits (for billing transparency).
|
|
76
|
-
|
|
77
|
-
Args:
|
|
78
|
-
graph_id (str): Graph database ID
|
|
79
|
-
authorization (Union[None, Unset, str]):
|
|
80
|
-
auth_token (Union[None, Unset, str]):
|
|
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[Union[Any, HTTPValidationError]]
|
|
88
|
-
"""
|
|
89
|
-
|
|
90
|
-
kwargs = _get_kwargs(
|
|
91
|
-
graph_id=graph_id,
|
|
92
|
-
authorization=authorization,
|
|
93
|
-
auth_token=auth_token,
|
|
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
|
-
graph_id: str,
|
|
105
|
-
*,
|
|
106
|
-
client: AuthenticatedClient,
|
|
107
|
-
authorization: Union[None, Unset, str] = UNSET,
|
|
108
|
-
auth_token: Union[None, Unset, str] = UNSET,
|
|
109
|
-
) -> Optional[Union[Any, HTTPValidationError]]:
|
|
110
|
-
"""Get Credit Billing Info
|
|
111
|
-
|
|
112
|
-
Get credit-based billing information for a specific graph.
|
|
113
|
-
|
|
114
|
-
This endpoint provides comprehensive credit usage and billing information
|
|
115
|
-
without consuming credits (for billing transparency).
|
|
116
|
-
|
|
117
|
-
Args:
|
|
118
|
-
graph_id (str): Graph database ID
|
|
119
|
-
authorization (Union[None, Unset, str]):
|
|
120
|
-
auth_token (Union[None, Unset, str]):
|
|
121
|
-
|
|
122
|
-
Raises:
|
|
123
|
-
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
124
|
-
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
125
|
-
|
|
126
|
-
Returns:
|
|
127
|
-
Union[Any, HTTPValidationError]
|
|
128
|
-
"""
|
|
129
|
-
|
|
130
|
-
return sync_detailed(
|
|
131
|
-
graph_id=graph_id,
|
|
132
|
-
client=client,
|
|
133
|
-
authorization=authorization,
|
|
134
|
-
auth_token=auth_token,
|
|
135
|
-
).parsed
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
async def asyncio_detailed(
|
|
139
|
-
graph_id: str,
|
|
140
|
-
*,
|
|
141
|
-
client: AuthenticatedClient,
|
|
142
|
-
authorization: Union[None, Unset, str] = UNSET,
|
|
143
|
-
auth_token: Union[None, Unset, str] = UNSET,
|
|
144
|
-
) -> Response[Union[Any, HTTPValidationError]]:
|
|
145
|
-
"""Get Credit Billing Info
|
|
146
|
-
|
|
147
|
-
Get credit-based billing information for a specific graph.
|
|
148
|
-
|
|
149
|
-
This endpoint provides comprehensive credit usage and billing information
|
|
150
|
-
without consuming credits (for billing transparency).
|
|
151
|
-
|
|
152
|
-
Args:
|
|
153
|
-
graph_id (str): Graph database ID
|
|
154
|
-
authorization (Union[None, Unset, str]):
|
|
155
|
-
auth_token (Union[None, Unset, str]):
|
|
156
|
-
|
|
157
|
-
Raises:
|
|
158
|
-
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
159
|
-
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
160
|
-
|
|
161
|
-
Returns:
|
|
162
|
-
Response[Union[Any, HTTPValidationError]]
|
|
163
|
-
"""
|
|
164
|
-
|
|
165
|
-
kwargs = _get_kwargs(
|
|
166
|
-
graph_id=graph_id,
|
|
167
|
-
authorization=authorization,
|
|
168
|
-
auth_token=auth_token,
|
|
169
|
-
)
|
|
170
|
-
|
|
171
|
-
response = await client.get_async_httpx_client().request(**kwargs)
|
|
172
|
-
|
|
173
|
-
return _build_response(client=client, response=response)
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
async def asyncio(
|
|
177
|
-
graph_id: str,
|
|
178
|
-
*,
|
|
179
|
-
client: AuthenticatedClient,
|
|
180
|
-
authorization: Union[None, Unset, str] = UNSET,
|
|
181
|
-
auth_token: Union[None, Unset, str] = UNSET,
|
|
182
|
-
) -> Optional[Union[Any, HTTPValidationError]]:
|
|
183
|
-
"""Get Credit Billing Info
|
|
184
|
-
|
|
185
|
-
Get credit-based billing information for a specific graph.
|
|
186
|
-
|
|
187
|
-
This endpoint provides comprehensive credit usage and billing information
|
|
188
|
-
without consuming credits (for billing transparency).
|
|
189
|
-
|
|
190
|
-
Args:
|
|
191
|
-
graph_id (str): Graph database ID
|
|
192
|
-
authorization (Union[None, Unset, str]):
|
|
193
|
-
auth_token (Union[None, Unset, str]):
|
|
194
|
-
|
|
195
|
-
Raises:
|
|
196
|
-
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
197
|
-
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
198
|
-
|
|
199
|
-
Returns:
|
|
200
|
-
Union[Any, HTTPValidationError]
|
|
201
|
-
"""
|
|
202
|
-
|
|
203
|
-
return (
|
|
204
|
-
await asyncio_detailed(
|
|
205
|
-
graph_id=graph_id,
|
|
206
|
-
client=client,
|
|
207
|
-
authorization=authorization,
|
|
208
|
-
auth_token=auth_token,
|
|
209
|
-
)
|
|
210
|
-
).parsed
|
|
@@ -1,198 +0,0 @@
|
|
|
1
|
-
from http import HTTPStatus
|
|
2
|
-
from typing import Any, Optional, Union
|
|
3
|
-
|
|
4
|
-
import httpx
|
|
5
|
-
|
|
6
|
-
from ... import errors
|
|
7
|
-
from ...client import AuthenticatedClient, Client
|
|
8
|
-
from ...models.http_validation_error import HTTPValidationError
|
|
9
|
-
from ...types import UNSET, Response, Unset
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
def _get_kwargs(
|
|
13
|
-
graph_id: str,
|
|
14
|
-
*,
|
|
15
|
-
authorization: Union[None, Unset, str] = UNSET,
|
|
16
|
-
auth_token: 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
|
-
cookies = {}
|
|
23
|
-
if auth_token is not UNSET:
|
|
24
|
-
cookies["auth-token"] = auth_token
|
|
25
|
-
|
|
26
|
-
_kwargs: dict[str, Any] = {
|
|
27
|
-
"method": "get",
|
|
28
|
-
"url": f"/v1/{graph_id}/billing/pricing",
|
|
29
|
-
"cookies": cookies,
|
|
30
|
-
}
|
|
31
|
-
|
|
32
|
-
_kwargs["headers"] = headers
|
|
33
|
-
return _kwargs
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
def _parse_response(
|
|
37
|
-
*, client: Union[AuthenticatedClient, Client], response: httpx.Response
|
|
38
|
-
) -> Optional[Union[Any, HTTPValidationError]]:
|
|
39
|
-
if response.status_code == 200:
|
|
40
|
-
response_200 = response.json()
|
|
41
|
-
return response_200
|
|
42
|
-
if response.status_code == 422:
|
|
43
|
-
response_422 = HTTPValidationError.from_dict(response.json())
|
|
44
|
-
|
|
45
|
-
return response_422
|
|
46
|
-
if client.raise_on_unexpected_status:
|
|
47
|
-
raise errors.UnexpectedStatus(response.status_code, response.content)
|
|
48
|
-
else:
|
|
49
|
-
return None
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
def _build_response(
|
|
53
|
-
*, client: Union[AuthenticatedClient, Client], response: httpx.Response
|
|
54
|
-
) -> Response[Union[Any, HTTPValidationError]]:
|
|
55
|
-
return Response(
|
|
56
|
-
status_code=HTTPStatus(response.status_code),
|
|
57
|
-
content=response.content,
|
|
58
|
-
headers=response.headers,
|
|
59
|
-
parsed=_parse_response(client=client, response=response),
|
|
60
|
-
)
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
def sync_detailed(
|
|
64
|
-
graph_id: str,
|
|
65
|
-
*,
|
|
66
|
-
client: AuthenticatedClient,
|
|
67
|
-
authorization: Union[None, Unset, str] = UNSET,
|
|
68
|
-
auth_token: Union[None, Unset, str] = UNSET,
|
|
69
|
-
) -> Response[Union[Any, HTTPValidationError]]:
|
|
70
|
-
"""Get Graph Pricing Info
|
|
71
|
-
|
|
72
|
-
Get pricing information for a specific graph database.
|
|
73
|
-
|
|
74
|
-
Args:
|
|
75
|
-
graph_id (str): Graph database ID
|
|
76
|
-
authorization (Union[None, Unset, str]):
|
|
77
|
-
auth_token (Union[None, Unset, str]):
|
|
78
|
-
|
|
79
|
-
Raises:
|
|
80
|
-
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
81
|
-
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
82
|
-
|
|
83
|
-
Returns:
|
|
84
|
-
Response[Union[Any, HTTPValidationError]]
|
|
85
|
-
"""
|
|
86
|
-
|
|
87
|
-
kwargs = _get_kwargs(
|
|
88
|
-
graph_id=graph_id,
|
|
89
|
-
authorization=authorization,
|
|
90
|
-
auth_token=auth_token,
|
|
91
|
-
)
|
|
92
|
-
|
|
93
|
-
response = client.get_httpx_client().request(
|
|
94
|
-
**kwargs,
|
|
95
|
-
)
|
|
96
|
-
|
|
97
|
-
return _build_response(client=client, response=response)
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
def sync(
|
|
101
|
-
graph_id: str,
|
|
102
|
-
*,
|
|
103
|
-
client: AuthenticatedClient,
|
|
104
|
-
authorization: Union[None, Unset, str] = UNSET,
|
|
105
|
-
auth_token: Union[None, Unset, str] = UNSET,
|
|
106
|
-
) -> Optional[Union[Any, HTTPValidationError]]:
|
|
107
|
-
"""Get Graph Pricing Info
|
|
108
|
-
|
|
109
|
-
Get pricing information for a specific graph database.
|
|
110
|
-
|
|
111
|
-
Args:
|
|
112
|
-
graph_id (str): Graph database ID
|
|
113
|
-
authorization (Union[None, Unset, str]):
|
|
114
|
-
auth_token (Union[None, Unset, str]):
|
|
115
|
-
|
|
116
|
-
Raises:
|
|
117
|
-
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
118
|
-
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
119
|
-
|
|
120
|
-
Returns:
|
|
121
|
-
Union[Any, HTTPValidationError]
|
|
122
|
-
"""
|
|
123
|
-
|
|
124
|
-
return sync_detailed(
|
|
125
|
-
graph_id=graph_id,
|
|
126
|
-
client=client,
|
|
127
|
-
authorization=authorization,
|
|
128
|
-
auth_token=auth_token,
|
|
129
|
-
).parsed
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
async def asyncio_detailed(
|
|
133
|
-
graph_id: str,
|
|
134
|
-
*,
|
|
135
|
-
client: AuthenticatedClient,
|
|
136
|
-
authorization: Union[None, Unset, str] = UNSET,
|
|
137
|
-
auth_token: Union[None, Unset, str] = UNSET,
|
|
138
|
-
) -> Response[Union[Any, HTTPValidationError]]:
|
|
139
|
-
"""Get Graph Pricing Info
|
|
140
|
-
|
|
141
|
-
Get pricing information for a specific graph database.
|
|
142
|
-
|
|
143
|
-
Args:
|
|
144
|
-
graph_id (str): Graph database ID
|
|
145
|
-
authorization (Union[None, Unset, str]):
|
|
146
|
-
auth_token (Union[None, Unset, str]):
|
|
147
|
-
|
|
148
|
-
Raises:
|
|
149
|
-
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
150
|
-
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
151
|
-
|
|
152
|
-
Returns:
|
|
153
|
-
Response[Union[Any, HTTPValidationError]]
|
|
154
|
-
"""
|
|
155
|
-
|
|
156
|
-
kwargs = _get_kwargs(
|
|
157
|
-
graph_id=graph_id,
|
|
158
|
-
authorization=authorization,
|
|
159
|
-
auth_token=auth_token,
|
|
160
|
-
)
|
|
161
|
-
|
|
162
|
-
response = await client.get_async_httpx_client().request(**kwargs)
|
|
163
|
-
|
|
164
|
-
return _build_response(client=client, response=response)
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
async def asyncio(
|
|
168
|
-
graph_id: str,
|
|
169
|
-
*,
|
|
170
|
-
client: AuthenticatedClient,
|
|
171
|
-
authorization: Union[None, Unset, str] = UNSET,
|
|
172
|
-
auth_token: Union[None, Unset, str] = UNSET,
|
|
173
|
-
) -> Optional[Union[Any, HTTPValidationError]]:
|
|
174
|
-
"""Get Graph Pricing Info
|
|
175
|
-
|
|
176
|
-
Get pricing information for a specific graph database.
|
|
177
|
-
|
|
178
|
-
Args:
|
|
179
|
-
graph_id (str): Graph database ID
|
|
180
|
-
authorization (Union[None, Unset, str]):
|
|
181
|
-
auth_token (Union[None, Unset, str]):
|
|
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[Any, HTTPValidationError]
|
|
189
|
-
"""
|
|
190
|
-
|
|
191
|
-
return (
|
|
192
|
-
await asyncio_detailed(
|
|
193
|
-
graph_id=graph_id,
|
|
194
|
-
client=client,
|
|
195
|
-
authorization=authorization,
|
|
196
|
-
auth_token=auth_token,
|
|
197
|
-
)
|
|
198
|
-
).parsed
|
robosystems_client/api/billing/get_graph_subscription_v1_graph_id_billing_subscription_get.py
DELETED
|
@@ -1,198 +0,0 @@
|
|
|
1
|
-
from http import HTTPStatus
|
|
2
|
-
from typing import Any, Optional, Union
|
|
3
|
-
|
|
4
|
-
import httpx
|
|
5
|
-
|
|
6
|
-
from ... import errors
|
|
7
|
-
from ...client import AuthenticatedClient, Client
|
|
8
|
-
from ...models.http_validation_error import HTTPValidationError
|
|
9
|
-
from ...types import UNSET, Response, Unset
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
def _get_kwargs(
|
|
13
|
-
graph_id: str,
|
|
14
|
-
*,
|
|
15
|
-
authorization: Union[None, Unset, str] = UNSET,
|
|
16
|
-
auth_token: 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
|
-
cookies = {}
|
|
23
|
-
if auth_token is not UNSET:
|
|
24
|
-
cookies["auth-token"] = auth_token
|
|
25
|
-
|
|
26
|
-
_kwargs: dict[str, Any] = {
|
|
27
|
-
"method": "get",
|
|
28
|
-
"url": f"/v1/{graph_id}/billing/subscription",
|
|
29
|
-
"cookies": cookies,
|
|
30
|
-
}
|
|
31
|
-
|
|
32
|
-
_kwargs["headers"] = headers
|
|
33
|
-
return _kwargs
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
def _parse_response(
|
|
37
|
-
*, client: Union[AuthenticatedClient, Client], response: httpx.Response
|
|
38
|
-
) -> Optional[Union[Any, HTTPValidationError]]:
|
|
39
|
-
if response.status_code == 200:
|
|
40
|
-
response_200 = response.json()
|
|
41
|
-
return response_200
|
|
42
|
-
if response.status_code == 422:
|
|
43
|
-
response_422 = HTTPValidationError.from_dict(response.json())
|
|
44
|
-
|
|
45
|
-
return response_422
|
|
46
|
-
if client.raise_on_unexpected_status:
|
|
47
|
-
raise errors.UnexpectedStatus(response.status_code, response.content)
|
|
48
|
-
else:
|
|
49
|
-
return None
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
def _build_response(
|
|
53
|
-
*, client: Union[AuthenticatedClient, Client], response: httpx.Response
|
|
54
|
-
) -> Response[Union[Any, HTTPValidationError]]:
|
|
55
|
-
return Response(
|
|
56
|
-
status_code=HTTPStatus(response.status_code),
|
|
57
|
-
content=response.content,
|
|
58
|
-
headers=response.headers,
|
|
59
|
-
parsed=_parse_response(client=client, response=response),
|
|
60
|
-
)
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
def sync_detailed(
|
|
64
|
-
graph_id: str,
|
|
65
|
-
*,
|
|
66
|
-
client: AuthenticatedClient,
|
|
67
|
-
authorization: Union[None, Unset, str] = UNSET,
|
|
68
|
-
auth_token: Union[None, Unset, str] = UNSET,
|
|
69
|
-
) -> Response[Union[Any, HTTPValidationError]]:
|
|
70
|
-
"""Get Graph Subscription
|
|
71
|
-
|
|
72
|
-
Get current subscription for a graph database.
|
|
73
|
-
|
|
74
|
-
Args:
|
|
75
|
-
graph_id (str): Graph database ID
|
|
76
|
-
authorization (Union[None, Unset, str]):
|
|
77
|
-
auth_token (Union[None, Unset, str]):
|
|
78
|
-
|
|
79
|
-
Raises:
|
|
80
|
-
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
81
|
-
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
82
|
-
|
|
83
|
-
Returns:
|
|
84
|
-
Response[Union[Any, HTTPValidationError]]
|
|
85
|
-
"""
|
|
86
|
-
|
|
87
|
-
kwargs = _get_kwargs(
|
|
88
|
-
graph_id=graph_id,
|
|
89
|
-
authorization=authorization,
|
|
90
|
-
auth_token=auth_token,
|
|
91
|
-
)
|
|
92
|
-
|
|
93
|
-
response = client.get_httpx_client().request(
|
|
94
|
-
**kwargs,
|
|
95
|
-
)
|
|
96
|
-
|
|
97
|
-
return _build_response(client=client, response=response)
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
def sync(
|
|
101
|
-
graph_id: str,
|
|
102
|
-
*,
|
|
103
|
-
client: AuthenticatedClient,
|
|
104
|
-
authorization: Union[None, Unset, str] = UNSET,
|
|
105
|
-
auth_token: Union[None, Unset, str] = UNSET,
|
|
106
|
-
) -> Optional[Union[Any, HTTPValidationError]]:
|
|
107
|
-
"""Get Graph Subscription
|
|
108
|
-
|
|
109
|
-
Get current subscription for a graph database.
|
|
110
|
-
|
|
111
|
-
Args:
|
|
112
|
-
graph_id (str): Graph database ID
|
|
113
|
-
authorization (Union[None, Unset, str]):
|
|
114
|
-
auth_token (Union[None, Unset, str]):
|
|
115
|
-
|
|
116
|
-
Raises:
|
|
117
|
-
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
118
|
-
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
119
|
-
|
|
120
|
-
Returns:
|
|
121
|
-
Union[Any, HTTPValidationError]
|
|
122
|
-
"""
|
|
123
|
-
|
|
124
|
-
return sync_detailed(
|
|
125
|
-
graph_id=graph_id,
|
|
126
|
-
client=client,
|
|
127
|
-
authorization=authorization,
|
|
128
|
-
auth_token=auth_token,
|
|
129
|
-
).parsed
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
async def asyncio_detailed(
|
|
133
|
-
graph_id: str,
|
|
134
|
-
*,
|
|
135
|
-
client: AuthenticatedClient,
|
|
136
|
-
authorization: Union[None, Unset, str] = UNSET,
|
|
137
|
-
auth_token: Union[None, Unset, str] = UNSET,
|
|
138
|
-
) -> Response[Union[Any, HTTPValidationError]]:
|
|
139
|
-
"""Get Graph Subscription
|
|
140
|
-
|
|
141
|
-
Get current subscription for a graph database.
|
|
142
|
-
|
|
143
|
-
Args:
|
|
144
|
-
graph_id (str): Graph database ID
|
|
145
|
-
authorization (Union[None, Unset, str]):
|
|
146
|
-
auth_token (Union[None, Unset, str]):
|
|
147
|
-
|
|
148
|
-
Raises:
|
|
149
|
-
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
150
|
-
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
151
|
-
|
|
152
|
-
Returns:
|
|
153
|
-
Response[Union[Any, HTTPValidationError]]
|
|
154
|
-
"""
|
|
155
|
-
|
|
156
|
-
kwargs = _get_kwargs(
|
|
157
|
-
graph_id=graph_id,
|
|
158
|
-
authorization=authorization,
|
|
159
|
-
auth_token=auth_token,
|
|
160
|
-
)
|
|
161
|
-
|
|
162
|
-
response = await client.get_async_httpx_client().request(**kwargs)
|
|
163
|
-
|
|
164
|
-
return _build_response(client=client, response=response)
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
async def asyncio(
|
|
168
|
-
graph_id: str,
|
|
169
|
-
*,
|
|
170
|
-
client: AuthenticatedClient,
|
|
171
|
-
authorization: Union[None, Unset, str] = UNSET,
|
|
172
|
-
auth_token: Union[None, Unset, str] = UNSET,
|
|
173
|
-
) -> Optional[Union[Any, HTTPValidationError]]:
|
|
174
|
-
"""Get Graph Subscription
|
|
175
|
-
|
|
176
|
-
Get current subscription for a graph database.
|
|
177
|
-
|
|
178
|
-
Args:
|
|
179
|
-
graph_id (str): Graph database ID
|
|
180
|
-
authorization (Union[None, Unset, str]):
|
|
181
|
-
auth_token (Union[None, Unset, str]):
|
|
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[Any, HTTPValidationError]
|
|
189
|
-
"""
|
|
190
|
-
|
|
191
|
-
return (
|
|
192
|
-
await asyncio_detailed(
|
|
193
|
-
graph_id=graph_id,
|
|
194
|
-
client=client,
|
|
195
|
-
authorization=authorization,
|
|
196
|
-
auth_token=auth_token,
|
|
197
|
-
)
|
|
198
|
-
).parsed
|