robosystems-client 0.2.3__py3-none-any.whl → 0.2.5__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/auth_response.py +40 -0
- 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.5.dist-info}/METADATA +2 -4
- {robosystems_client-0.2.3.dist-info → robosystems_client-0.2.5.dist-info}/RECORD +104 -103
- {robosystems_client-0.2.3.dist-info → robosystems_client-0.2.5.dist-info}/WHEEL +0 -0
- {robosystems_client-0.2.3.dist-info → robosystems_client-0.2.5.dist-info}/licenses/LICENSE +0 -0
|
@@ -5,49 +5,27 @@ import httpx
|
|
|
5
5
|
|
|
6
6
|
from ... import errors
|
|
7
7
|
from ...client import AuthenticatedClient, Client
|
|
8
|
-
from ...models.get_graph_schema_response_getgraphschema import (
|
|
9
|
-
GetGraphSchemaResponseGetgraphschema,
|
|
10
|
-
)
|
|
11
8
|
from ...models.http_validation_error import HTTPValidationError
|
|
12
|
-
from ...
|
|
9
|
+
from ...models.schema_info_response import SchemaInfoResponse
|
|
10
|
+
from ...types import Response
|
|
13
11
|
|
|
14
12
|
|
|
15
13
|
def _get_kwargs(
|
|
16
14
|
graph_id: str,
|
|
17
|
-
*,
|
|
18
|
-
token: Union[None, Unset, str] = UNSET,
|
|
19
|
-
authorization: Union[None, Unset, str] = UNSET,
|
|
20
15
|
) -> 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
16
|
_kwargs: dict[str, Any] = {
|
|
37
17
|
"method": "get",
|
|
38
18
|
"url": f"/v1/graphs/{graph_id}/schema",
|
|
39
|
-
"params": params,
|
|
40
19
|
}
|
|
41
20
|
|
|
42
|
-
_kwargs["headers"] = headers
|
|
43
21
|
return _kwargs
|
|
44
22
|
|
|
45
23
|
|
|
46
24
|
def _parse_response(
|
|
47
25
|
*, client: Union[AuthenticatedClient, Client], response: httpx.Response
|
|
48
|
-
) -> Optional[Union[Any,
|
|
26
|
+
) -> Optional[Union[Any, HTTPValidationError, SchemaInfoResponse]]:
|
|
49
27
|
if response.status_code == 200:
|
|
50
|
-
response_200 =
|
|
28
|
+
response_200 = SchemaInfoResponse.from_dict(response.json())
|
|
51
29
|
|
|
52
30
|
return response_200
|
|
53
31
|
|
|
@@ -64,6 +42,10 @@ def _parse_response(
|
|
|
64
42
|
response_500 = cast(Any, None)
|
|
65
43
|
return response_500
|
|
66
44
|
|
|
45
|
+
if response.status_code == 504:
|
|
46
|
+
response_504 = cast(Any, None)
|
|
47
|
+
return response_504
|
|
48
|
+
|
|
67
49
|
if client.raise_on_unexpected_status:
|
|
68
50
|
raise errors.UnexpectedStatus(response.status_code, response.content)
|
|
69
51
|
else:
|
|
@@ -72,7 +54,7 @@ def _parse_response(
|
|
|
72
54
|
|
|
73
55
|
def _build_response(
|
|
74
56
|
*, client: Union[AuthenticatedClient, Client], response: httpx.Response
|
|
75
|
-
) -> Response[Union[Any,
|
|
57
|
+
) -> Response[Union[Any, HTTPValidationError, SchemaInfoResponse]]:
|
|
76
58
|
return Response(
|
|
77
59
|
status_code=HTTPStatus(response.status_code),
|
|
78
60
|
content=response.content,
|
|
@@ -85,40 +67,59 @@ def sync_detailed(
|
|
|
85
67
|
graph_id: str,
|
|
86
68
|
*,
|
|
87
69
|
client: AuthenticatedClient,
|
|
88
|
-
|
|
89
|
-
authorization: Union[None, Unset, str] = UNSET,
|
|
90
|
-
) -> Response[Union[Any, GetGraphSchemaResponseGetgraphschema, HTTPValidationError]]:
|
|
70
|
+
) -> Response[Union[Any, HTTPValidationError, SchemaInfoResponse]]:
|
|
91
71
|
"""Get Runtime Graph Schema
|
|
92
72
|
|
|
93
73
|
Get runtime schema information for the specified graph database.
|
|
94
74
|
|
|
95
|
-
|
|
75
|
+
## What This Returns
|
|
76
|
+
|
|
77
|
+
This endpoint inspects the **actual current state** of the graph database and returns:
|
|
96
78
|
- **Node Labels**: All node types currently in the database
|
|
97
79
|
- **Relationship Types**: All relationship types currently in the database
|
|
98
|
-
- **Node Properties**: Properties
|
|
80
|
+
- **Node Properties**: Properties discovered from actual data (up to 10 properties per node type)
|
|
81
|
+
|
|
82
|
+
## Runtime vs Declared Schema
|
|
99
83
|
|
|
100
|
-
|
|
101
|
-
|
|
84
|
+
**Use this endpoint** (`/schema`) when you need to know:
|
|
85
|
+
- What data is ACTUALLY in the database right now
|
|
86
|
+
- What properties exist on real nodes
|
|
87
|
+
- What relationships have been created
|
|
88
|
+
- Current database structure for querying
|
|
89
|
+
|
|
90
|
+
**Use `/schema/export` instead** when you need:
|
|
91
|
+
- The original schema definition used to create the graph
|
|
92
|
+
- Schema in a specific format (JSON, YAML, Cypher DDL)
|
|
93
|
+
- Schema for documentation or version control
|
|
94
|
+
- Schema to replicate in another graph
|
|
95
|
+
|
|
96
|
+
## Example Use Cases
|
|
97
|
+
|
|
98
|
+
- **Building queries**: See what node labels and properties exist to write accurate Cypher
|
|
99
|
+
- **Data exploration**: Discover what's in an unfamiliar graph
|
|
100
|
+
- **Schema drift detection**: Compare runtime vs declared schema
|
|
101
|
+
- **API integration**: Dynamically adapt to current graph structure
|
|
102
|
+
|
|
103
|
+
## Performance Note
|
|
104
|
+
|
|
105
|
+
Property discovery is limited to 10 properties per node type for performance.
|
|
106
|
+
For complete schema definitions, use `/schema/export`.
|
|
102
107
|
|
|
103
108
|
This operation is included - no credit consumption required.
|
|
104
109
|
|
|
105
110
|
Args:
|
|
106
|
-
graph_id (str):
|
|
107
|
-
token (Union[None, Unset, str]): JWT token for SSE authentication
|
|
108
|
-
authorization (Union[None, Unset, str]):
|
|
111
|
+
graph_id (str):
|
|
109
112
|
|
|
110
113
|
Raises:
|
|
111
114
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
112
115
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
113
116
|
|
|
114
117
|
Returns:
|
|
115
|
-
Response[Union[Any,
|
|
118
|
+
Response[Union[Any, HTTPValidationError, SchemaInfoResponse]]
|
|
116
119
|
"""
|
|
117
120
|
|
|
118
121
|
kwargs = _get_kwargs(
|
|
119
122
|
graph_id=graph_id,
|
|
120
|
-
token=token,
|
|
121
|
-
authorization=authorization,
|
|
122
123
|
)
|
|
123
124
|
|
|
124
125
|
response = client.get_httpx_client().request(
|
|
@@ -132,41 +133,60 @@ def sync(
|
|
|
132
133
|
graph_id: str,
|
|
133
134
|
*,
|
|
134
135
|
client: AuthenticatedClient,
|
|
135
|
-
|
|
136
|
-
authorization: Union[None, Unset, str] = UNSET,
|
|
137
|
-
) -> Optional[Union[Any, GetGraphSchemaResponseGetgraphschema, HTTPValidationError]]:
|
|
136
|
+
) -> Optional[Union[Any, HTTPValidationError, SchemaInfoResponse]]:
|
|
138
137
|
"""Get Runtime Graph Schema
|
|
139
138
|
|
|
140
139
|
Get runtime schema information for the specified graph database.
|
|
141
140
|
|
|
142
|
-
|
|
141
|
+
## What This Returns
|
|
142
|
+
|
|
143
|
+
This endpoint inspects the **actual current state** of the graph database and returns:
|
|
143
144
|
- **Node Labels**: All node types currently in the database
|
|
144
145
|
- **Relationship Types**: All relationship types currently in the database
|
|
145
|
-
- **Node Properties**: Properties
|
|
146
|
+
- **Node Properties**: Properties discovered from actual data (up to 10 properties per node type)
|
|
147
|
+
|
|
148
|
+
## Runtime vs Declared Schema
|
|
149
|
+
|
|
150
|
+
**Use this endpoint** (`/schema`) when you need to know:
|
|
151
|
+
- What data is ACTUALLY in the database right now
|
|
152
|
+
- What properties exist on real nodes
|
|
153
|
+
- What relationships have been created
|
|
154
|
+
- Current database structure for querying
|
|
155
|
+
|
|
156
|
+
**Use `/schema/export` instead** when you need:
|
|
157
|
+
- The original schema definition used to create the graph
|
|
158
|
+
- Schema in a specific format (JSON, YAML, Cypher DDL)
|
|
159
|
+
- Schema for documentation or version control
|
|
160
|
+
- Schema to replicate in another graph
|
|
146
161
|
|
|
147
|
-
|
|
148
|
-
|
|
162
|
+
## Example Use Cases
|
|
163
|
+
|
|
164
|
+
- **Building queries**: See what node labels and properties exist to write accurate Cypher
|
|
165
|
+
- **Data exploration**: Discover what's in an unfamiliar graph
|
|
166
|
+
- **Schema drift detection**: Compare runtime vs declared schema
|
|
167
|
+
- **API integration**: Dynamically adapt to current graph structure
|
|
168
|
+
|
|
169
|
+
## Performance Note
|
|
170
|
+
|
|
171
|
+
Property discovery is limited to 10 properties per node type for performance.
|
|
172
|
+
For complete schema definitions, use `/schema/export`.
|
|
149
173
|
|
|
150
174
|
This operation is included - no credit consumption required.
|
|
151
175
|
|
|
152
176
|
Args:
|
|
153
|
-
graph_id (str):
|
|
154
|
-
token (Union[None, Unset, str]): JWT token for SSE authentication
|
|
155
|
-
authorization (Union[None, Unset, str]):
|
|
177
|
+
graph_id (str):
|
|
156
178
|
|
|
157
179
|
Raises:
|
|
158
180
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
159
181
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
160
182
|
|
|
161
183
|
Returns:
|
|
162
|
-
Union[Any,
|
|
184
|
+
Union[Any, HTTPValidationError, SchemaInfoResponse]
|
|
163
185
|
"""
|
|
164
186
|
|
|
165
187
|
return sync_detailed(
|
|
166
188
|
graph_id=graph_id,
|
|
167
189
|
client=client,
|
|
168
|
-
token=token,
|
|
169
|
-
authorization=authorization,
|
|
170
190
|
).parsed
|
|
171
191
|
|
|
172
192
|
|
|
@@ -174,40 +194,59 @@ async def asyncio_detailed(
|
|
|
174
194
|
graph_id: str,
|
|
175
195
|
*,
|
|
176
196
|
client: AuthenticatedClient,
|
|
177
|
-
|
|
178
|
-
authorization: Union[None, Unset, str] = UNSET,
|
|
179
|
-
) -> Response[Union[Any, GetGraphSchemaResponseGetgraphschema, HTTPValidationError]]:
|
|
197
|
+
) -> Response[Union[Any, HTTPValidationError, SchemaInfoResponse]]:
|
|
180
198
|
"""Get Runtime Graph Schema
|
|
181
199
|
|
|
182
200
|
Get runtime schema information for the specified graph database.
|
|
183
201
|
|
|
184
|
-
|
|
202
|
+
## What This Returns
|
|
203
|
+
|
|
204
|
+
This endpoint inspects the **actual current state** of the graph database and returns:
|
|
185
205
|
- **Node Labels**: All node types currently in the database
|
|
186
206
|
- **Relationship Types**: All relationship types currently in the database
|
|
187
|
-
- **Node Properties**: Properties
|
|
207
|
+
- **Node Properties**: Properties discovered from actual data (up to 10 properties per node type)
|
|
208
|
+
|
|
209
|
+
## Runtime vs Declared Schema
|
|
210
|
+
|
|
211
|
+
**Use this endpoint** (`/schema`) when you need to know:
|
|
212
|
+
- What data is ACTUALLY in the database right now
|
|
213
|
+
- What properties exist on real nodes
|
|
214
|
+
- What relationships have been created
|
|
215
|
+
- Current database structure for querying
|
|
216
|
+
|
|
217
|
+
**Use `/schema/export` instead** when you need:
|
|
218
|
+
- The original schema definition used to create the graph
|
|
219
|
+
- Schema in a specific format (JSON, YAML, Cypher DDL)
|
|
220
|
+
- Schema for documentation or version control
|
|
221
|
+
- Schema to replicate in another graph
|
|
222
|
+
|
|
223
|
+
## Example Use Cases
|
|
224
|
+
|
|
225
|
+
- **Building queries**: See what node labels and properties exist to write accurate Cypher
|
|
226
|
+
- **Data exploration**: Discover what's in an unfamiliar graph
|
|
227
|
+
- **Schema drift detection**: Compare runtime vs declared schema
|
|
228
|
+
- **API integration**: Dynamically adapt to current graph structure
|
|
188
229
|
|
|
189
|
-
|
|
190
|
-
|
|
230
|
+
## Performance Note
|
|
231
|
+
|
|
232
|
+
Property discovery is limited to 10 properties per node type for performance.
|
|
233
|
+
For complete schema definitions, use `/schema/export`.
|
|
191
234
|
|
|
192
235
|
This operation is included - no credit consumption required.
|
|
193
236
|
|
|
194
237
|
Args:
|
|
195
|
-
graph_id (str):
|
|
196
|
-
token (Union[None, Unset, str]): JWT token for SSE authentication
|
|
197
|
-
authorization (Union[None, Unset, str]):
|
|
238
|
+
graph_id (str):
|
|
198
239
|
|
|
199
240
|
Raises:
|
|
200
241
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
201
242
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
202
243
|
|
|
203
244
|
Returns:
|
|
204
|
-
Response[Union[Any,
|
|
245
|
+
Response[Union[Any, HTTPValidationError, SchemaInfoResponse]]
|
|
205
246
|
"""
|
|
206
247
|
|
|
207
248
|
kwargs = _get_kwargs(
|
|
208
249
|
graph_id=graph_id,
|
|
209
|
-
token=token,
|
|
210
|
-
authorization=authorization,
|
|
211
250
|
)
|
|
212
251
|
|
|
213
252
|
response = await client.get_async_httpx_client().request(**kwargs)
|
|
@@ -219,41 +258,60 @@ async def asyncio(
|
|
|
219
258
|
graph_id: str,
|
|
220
259
|
*,
|
|
221
260
|
client: AuthenticatedClient,
|
|
222
|
-
|
|
223
|
-
authorization: Union[None, Unset, str] = UNSET,
|
|
224
|
-
) -> Optional[Union[Any, GetGraphSchemaResponseGetgraphschema, HTTPValidationError]]:
|
|
261
|
+
) -> Optional[Union[Any, HTTPValidationError, SchemaInfoResponse]]:
|
|
225
262
|
"""Get Runtime Graph Schema
|
|
226
263
|
|
|
227
264
|
Get runtime schema information for the specified graph database.
|
|
228
265
|
|
|
229
|
-
|
|
266
|
+
## What This Returns
|
|
267
|
+
|
|
268
|
+
This endpoint inspects the **actual current state** of the graph database and returns:
|
|
230
269
|
- **Node Labels**: All node types currently in the database
|
|
231
270
|
- **Relationship Types**: All relationship types currently in the database
|
|
232
|
-
- **Node Properties**: Properties
|
|
271
|
+
- **Node Properties**: Properties discovered from actual data (up to 10 properties per node type)
|
|
272
|
+
|
|
273
|
+
## Runtime vs Declared Schema
|
|
274
|
+
|
|
275
|
+
**Use this endpoint** (`/schema`) when you need to know:
|
|
276
|
+
- What data is ACTUALLY in the database right now
|
|
277
|
+
- What properties exist on real nodes
|
|
278
|
+
- What relationships have been created
|
|
279
|
+
- Current database structure for querying
|
|
280
|
+
|
|
281
|
+
**Use `/schema/export` instead** when you need:
|
|
282
|
+
- The original schema definition used to create the graph
|
|
283
|
+
- Schema in a specific format (JSON, YAML, Cypher DDL)
|
|
284
|
+
- Schema for documentation or version control
|
|
285
|
+
- Schema to replicate in another graph
|
|
286
|
+
|
|
287
|
+
## Example Use Cases
|
|
288
|
+
|
|
289
|
+
- **Building queries**: See what node labels and properties exist to write accurate Cypher
|
|
290
|
+
- **Data exploration**: Discover what's in an unfamiliar graph
|
|
291
|
+
- **Schema drift detection**: Compare runtime vs declared schema
|
|
292
|
+
- **API integration**: Dynamically adapt to current graph structure
|
|
293
|
+
|
|
294
|
+
## Performance Note
|
|
233
295
|
|
|
234
|
-
|
|
235
|
-
For
|
|
296
|
+
Property discovery is limited to 10 properties per node type for performance.
|
|
297
|
+
For complete schema definitions, use `/schema/export`.
|
|
236
298
|
|
|
237
299
|
This operation is included - no credit consumption required.
|
|
238
300
|
|
|
239
301
|
Args:
|
|
240
|
-
graph_id (str):
|
|
241
|
-
token (Union[None, Unset, str]): JWT token for SSE authentication
|
|
242
|
-
authorization (Union[None, Unset, str]):
|
|
302
|
+
graph_id (str):
|
|
243
303
|
|
|
244
304
|
Raises:
|
|
245
305
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
246
306
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
247
307
|
|
|
248
308
|
Returns:
|
|
249
|
-
Union[Any,
|
|
309
|
+
Union[Any, HTTPValidationError, SchemaInfoResponse]
|
|
250
310
|
"""
|
|
251
311
|
|
|
252
312
|
return (
|
|
253
313
|
await asyncio_detailed(
|
|
254
314
|
graph_id=graph_id,
|
|
255
315
|
client=client,
|
|
256
|
-
token=token,
|
|
257
|
-
authorization=authorization,
|
|
258
316
|
)
|
|
259
317
|
).parsed
|
|
@@ -8,35 +8,19 @@ from ...client import AuthenticatedClient, Client
|
|
|
8
8
|
from ...models.error_response import ErrorResponse
|
|
9
9
|
from ...models.schema_validation_request import SchemaValidationRequest
|
|
10
10
|
from ...models.schema_validation_response import SchemaValidationResponse
|
|
11
|
-
from ...types import
|
|
11
|
+
from ...types import Response
|
|
12
12
|
|
|
13
13
|
|
|
14
14
|
def _get_kwargs(
|
|
15
15
|
graph_id: str,
|
|
16
16
|
*,
|
|
17
17
|
body: SchemaValidationRequest,
|
|
18
|
-
token: Union[None, Unset, str] = UNSET,
|
|
19
|
-
authorization: Union[None, Unset, str] = UNSET,
|
|
20
18
|
) -> dict[str, Any]:
|
|
21
19
|
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
20
|
|
|
36
21
|
_kwargs: dict[str, Any] = {
|
|
37
22
|
"method": "post",
|
|
38
23
|
"url": f"/v1/graphs/{graph_id}/schema/validate",
|
|
39
|
-
"params": params,
|
|
40
24
|
}
|
|
41
25
|
|
|
42
26
|
_kwargs["json"] = body.to_dict()
|
|
@@ -97,8 +81,6 @@ def sync_detailed(
|
|
|
97
81
|
*,
|
|
98
82
|
client: AuthenticatedClient,
|
|
99
83
|
body: SchemaValidationRequest,
|
|
100
|
-
token: Union[None, Unset, str] = UNSET,
|
|
101
|
-
authorization: Union[None, Unset, str] = UNSET,
|
|
102
84
|
) -> Response[Union[ErrorResponse, SchemaValidationResponse]]:
|
|
103
85
|
"""Validate Schema
|
|
104
86
|
|
|
@@ -126,9 +108,7 @@ def sync_detailed(
|
|
|
126
108
|
This operation is included - no credit consumption required.
|
|
127
109
|
|
|
128
110
|
Args:
|
|
129
|
-
graph_id (str):
|
|
130
|
-
token (Union[None, Unset, str]): JWT token for SSE authentication
|
|
131
|
-
authorization (Union[None, Unset, str]):
|
|
111
|
+
graph_id (str):
|
|
132
112
|
body (SchemaValidationRequest): Request model for schema validation.
|
|
133
113
|
|
|
134
114
|
Raises:
|
|
@@ -142,8 +122,6 @@ def sync_detailed(
|
|
|
142
122
|
kwargs = _get_kwargs(
|
|
143
123
|
graph_id=graph_id,
|
|
144
124
|
body=body,
|
|
145
|
-
token=token,
|
|
146
|
-
authorization=authorization,
|
|
147
125
|
)
|
|
148
126
|
|
|
149
127
|
response = client.get_httpx_client().request(
|
|
@@ -158,8 +136,6 @@ def sync(
|
|
|
158
136
|
*,
|
|
159
137
|
client: AuthenticatedClient,
|
|
160
138
|
body: SchemaValidationRequest,
|
|
161
|
-
token: Union[None, Unset, str] = UNSET,
|
|
162
|
-
authorization: Union[None, Unset, str] = UNSET,
|
|
163
139
|
) -> Optional[Union[ErrorResponse, SchemaValidationResponse]]:
|
|
164
140
|
"""Validate Schema
|
|
165
141
|
|
|
@@ -187,9 +163,7 @@ def sync(
|
|
|
187
163
|
This operation is included - no credit consumption required.
|
|
188
164
|
|
|
189
165
|
Args:
|
|
190
|
-
graph_id (str):
|
|
191
|
-
token (Union[None, Unset, str]): JWT token for SSE authentication
|
|
192
|
-
authorization (Union[None, Unset, str]):
|
|
166
|
+
graph_id (str):
|
|
193
167
|
body (SchemaValidationRequest): Request model for schema validation.
|
|
194
168
|
|
|
195
169
|
Raises:
|
|
@@ -204,8 +178,6 @@ def sync(
|
|
|
204
178
|
graph_id=graph_id,
|
|
205
179
|
client=client,
|
|
206
180
|
body=body,
|
|
207
|
-
token=token,
|
|
208
|
-
authorization=authorization,
|
|
209
181
|
).parsed
|
|
210
182
|
|
|
211
183
|
|
|
@@ -214,8 +186,6 @@ async def asyncio_detailed(
|
|
|
214
186
|
*,
|
|
215
187
|
client: AuthenticatedClient,
|
|
216
188
|
body: SchemaValidationRequest,
|
|
217
|
-
token: Union[None, Unset, str] = UNSET,
|
|
218
|
-
authorization: Union[None, Unset, str] = UNSET,
|
|
219
189
|
) -> Response[Union[ErrorResponse, SchemaValidationResponse]]:
|
|
220
190
|
"""Validate Schema
|
|
221
191
|
|
|
@@ -243,9 +213,7 @@ async def asyncio_detailed(
|
|
|
243
213
|
This operation is included - no credit consumption required.
|
|
244
214
|
|
|
245
215
|
Args:
|
|
246
|
-
graph_id (str):
|
|
247
|
-
token (Union[None, Unset, str]): JWT token for SSE authentication
|
|
248
|
-
authorization (Union[None, Unset, str]):
|
|
216
|
+
graph_id (str):
|
|
249
217
|
body (SchemaValidationRequest): Request model for schema validation.
|
|
250
218
|
|
|
251
219
|
Raises:
|
|
@@ -259,8 +227,6 @@ async def asyncio_detailed(
|
|
|
259
227
|
kwargs = _get_kwargs(
|
|
260
228
|
graph_id=graph_id,
|
|
261
229
|
body=body,
|
|
262
|
-
token=token,
|
|
263
|
-
authorization=authorization,
|
|
264
230
|
)
|
|
265
231
|
|
|
266
232
|
response = await client.get_async_httpx_client().request(**kwargs)
|
|
@@ -273,8 +239,6 @@ async def asyncio(
|
|
|
273
239
|
*,
|
|
274
240
|
client: AuthenticatedClient,
|
|
275
241
|
body: SchemaValidationRequest,
|
|
276
|
-
token: Union[None, Unset, str] = UNSET,
|
|
277
|
-
authorization: Union[None, Unset, str] = UNSET,
|
|
278
242
|
) -> Optional[Union[ErrorResponse, SchemaValidationResponse]]:
|
|
279
243
|
"""Validate Schema
|
|
280
244
|
|
|
@@ -302,9 +266,7 @@ async def asyncio(
|
|
|
302
266
|
This operation is included - no credit consumption required.
|
|
303
267
|
|
|
304
268
|
Args:
|
|
305
|
-
graph_id (str):
|
|
306
|
-
token (Union[None, Unset, str]): JWT token for SSE authentication
|
|
307
|
-
authorization (Union[None, Unset, str]):
|
|
269
|
+
graph_id (str):
|
|
308
270
|
body (SchemaValidationRequest): Request model for schema validation.
|
|
309
271
|
|
|
310
272
|
Raises:
|
|
@@ -320,7 +282,5 @@ async def asyncio(
|
|
|
320
282
|
graph_id=graph_id,
|
|
321
283
|
client=client,
|
|
322
284
|
body=body,
|
|
323
|
-
token=token,
|
|
324
|
-
authorization=authorization,
|
|
325
285
|
)
|
|
326
286
|
).parsed
|
|
@@ -8,35 +8,19 @@ from ...client import AuthenticatedClient, Client
|
|
|
8
8
|
from ...models.create_subgraph_request import CreateSubgraphRequest
|
|
9
9
|
from ...models.http_validation_error import HTTPValidationError
|
|
10
10
|
from ...models.subgraph_response import SubgraphResponse
|
|
11
|
-
from ...types import
|
|
11
|
+
from ...types import Response
|
|
12
12
|
|
|
13
13
|
|
|
14
14
|
def _get_kwargs(
|
|
15
15
|
graph_id: str,
|
|
16
16
|
*,
|
|
17
17
|
body: CreateSubgraphRequest,
|
|
18
|
-
token: Union[None, Unset, str] = UNSET,
|
|
19
|
-
authorization: Union[None, Unset, str] = UNSET,
|
|
20
18
|
) -> dict[str, Any]:
|
|
21
19
|
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
20
|
|
|
36
21
|
_kwargs: dict[str, Any] = {
|
|
37
22
|
"method": "post",
|
|
38
23
|
"url": f"/v1/graphs/{graph_id}/subgraphs",
|
|
39
|
-
"params": params,
|
|
40
24
|
}
|
|
41
25
|
|
|
42
26
|
_kwargs["json"] = body.to_dict()
|
|
@@ -82,8 +66,6 @@ def sync_detailed(
|
|
|
82
66
|
*,
|
|
83
67
|
client: AuthenticatedClient,
|
|
84
68
|
body: CreateSubgraphRequest,
|
|
85
|
-
token: Union[None, Unset, str] = UNSET,
|
|
86
|
-
authorization: Union[None, Unset, str] = UNSET,
|
|
87
69
|
) -> Response[Union[HTTPValidationError, SubgraphResponse]]:
|
|
88
70
|
"""Create Subgraph
|
|
89
71
|
|
|
@@ -101,9 +83,7 @@ def sync_detailed(
|
|
|
101
83
|
- Created subgraph details including its unique ID
|
|
102
84
|
|
|
103
85
|
Args:
|
|
104
|
-
graph_id (str):
|
|
105
|
-
token (Union[None, Unset, str]): JWT token for SSE authentication
|
|
106
|
-
authorization (Union[None, Unset, str]):
|
|
86
|
+
graph_id (str):
|
|
107
87
|
body (CreateSubgraphRequest): Request model for creating a subgraph.
|
|
108
88
|
|
|
109
89
|
Raises:
|
|
@@ -117,8 +97,6 @@ def sync_detailed(
|
|
|
117
97
|
kwargs = _get_kwargs(
|
|
118
98
|
graph_id=graph_id,
|
|
119
99
|
body=body,
|
|
120
|
-
token=token,
|
|
121
|
-
authorization=authorization,
|
|
122
100
|
)
|
|
123
101
|
|
|
124
102
|
response = client.get_httpx_client().request(
|
|
@@ -133,8 +111,6 @@ def sync(
|
|
|
133
111
|
*,
|
|
134
112
|
client: AuthenticatedClient,
|
|
135
113
|
body: CreateSubgraphRequest,
|
|
136
|
-
token: Union[None, Unset, str] = UNSET,
|
|
137
|
-
authorization: Union[None, Unset, str] = UNSET,
|
|
138
114
|
) -> Optional[Union[HTTPValidationError, SubgraphResponse]]:
|
|
139
115
|
"""Create Subgraph
|
|
140
116
|
|
|
@@ -152,9 +128,7 @@ def sync(
|
|
|
152
128
|
- Created subgraph details including its unique ID
|
|
153
129
|
|
|
154
130
|
Args:
|
|
155
|
-
graph_id (str):
|
|
156
|
-
token (Union[None, Unset, str]): JWT token for SSE authentication
|
|
157
|
-
authorization (Union[None, Unset, str]):
|
|
131
|
+
graph_id (str):
|
|
158
132
|
body (CreateSubgraphRequest): Request model for creating a subgraph.
|
|
159
133
|
|
|
160
134
|
Raises:
|
|
@@ -169,8 +143,6 @@ def sync(
|
|
|
169
143
|
graph_id=graph_id,
|
|
170
144
|
client=client,
|
|
171
145
|
body=body,
|
|
172
|
-
token=token,
|
|
173
|
-
authorization=authorization,
|
|
174
146
|
).parsed
|
|
175
147
|
|
|
176
148
|
|
|
@@ -179,8 +151,6 @@ async def asyncio_detailed(
|
|
|
179
151
|
*,
|
|
180
152
|
client: AuthenticatedClient,
|
|
181
153
|
body: CreateSubgraphRequest,
|
|
182
|
-
token: Union[None, Unset, str] = UNSET,
|
|
183
|
-
authorization: Union[None, Unset, str] = UNSET,
|
|
184
154
|
) -> Response[Union[HTTPValidationError, SubgraphResponse]]:
|
|
185
155
|
"""Create Subgraph
|
|
186
156
|
|
|
@@ -198,9 +168,7 @@ async def asyncio_detailed(
|
|
|
198
168
|
- Created subgraph details including its unique ID
|
|
199
169
|
|
|
200
170
|
Args:
|
|
201
|
-
graph_id (str):
|
|
202
|
-
token (Union[None, Unset, str]): JWT token for SSE authentication
|
|
203
|
-
authorization (Union[None, Unset, str]):
|
|
171
|
+
graph_id (str):
|
|
204
172
|
body (CreateSubgraphRequest): Request model for creating a subgraph.
|
|
205
173
|
|
|
206
174
|
Raises:
|
|
@@ -214,8 +182,6 @@ async def asyncio_detailed(
|
|
|
214
182
|
kwargs = _get_kwargs(
|
|
215
183
|
graph_id=graph_id,
|
|
216
184
|
body=body,
|
|
217
|
-
token=token,
|
|
218
|
-
authorization=authorization,
|
|
219
185
|
)
|
|
220
186
|
|
|
221
187
|
response = await client.get_async_httpx_client().request(**kwargs)
|
|
@@ -228,8 +194,6 @@ async def asyncio(
|
|
|
228
194
|
*,
|
|
229
195
|
client: AuthenticatedClient,
|
|
230
196
|
body: CreateSubgraphRequest,
|
|
231
|
-
token: Union[None, Unset, str] = UNSET,
|
|
232
|
-
authorization: Union[None, Unset, str] = UNSET,
|
|
233
197
|
) -> Optional[Union[HTTPValidationError, SubgraphResponse]]:
|
|
234
198
|
"""Create Subgraph
|
|
235
199
|
|
|
@@ -247,9 +211,7 @@ async def asyncio(
|
|
|
247
211
|
- Created subgraph details including its unique ID
|
|
248
212
|
|
|
249
213
|
Args:
|
|
250
|
-
graph_id (str):
|
|
251
|
-
token (Union[None, Unset, str]): JWT token for SSE authentication
|
|
252
|
-
authorization (Union[None, Unset, str]):
|
|
214
|
+
graph_id (str):
|
|
253
215
|
body (CreateSubgraphRequest): Request model for creating a subgraph.
|
|
254
216
|
|
|
255
217
|
Raises:
|
|
@@ -265,7 +227,5 @@ async def asyncio(
|
|
|
265
227
|
graph_id=graph_id,
|
|
266
228
|
client=client,
|
|
267
229
|
body=body,
|
|
268
|
-
token=token,
|
|
269
|
-
authorization=authorization,
|
|
270
230
|
)
|
|
271
231
|
).parsed
|