@robosystems/client 0.1.14 → 0.1.16
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.
- package/README.md +3 -5
- package/package.json +49 -7
- package/sdk/client/client.gen.d.ts +2 -0
- package/sdk/client/client.gen.js +153 -0
- package/sdk/client/client.gen.ts +200 -0
- package/sdk/client/index.d.ts +7 -0
- package/sdk/client/index.js +15 -0
- package/sdk/client/index.ts +25 -0
- package/sdk/client/types.gen.d.ts +122 -0
- package/sdk/client/types.gen.js +4 -0
- package/sdk/client/types.gen.ts +233 -0
- package/sdk/client/utils.gen.d.ts +45 -0
- package/sdk/client/utils.gen.js +296 -0
- package/sdk/client/utils.gen.ts +419 -0
- package/sdk/client.gen.d.ts +12 -0
- package/sdk/client.gen.js +8 -0
- package/sdk/client.gen.ts +18 -0
- package/sdk/core/auth.gen.d.ts +18 -0
- package/sdk/core/auth.gen.js +18 -0
- package/sdk/core/auth.gen.ts +42 -0
- package/sdk/core/bodySerializer.gen.d.ts +17 -0
- package/sdk/core/bodySerializer.gen.js +57 -0
- package/sdk/core/bodySerializer.gen.ts +90 -0
- package/sdk/core/params.gen.d.ts +33 -0
- package/sdk/core/params.gen.js +92 -0
- package/sdk/core/params.gen.ts +153 -0
- package/sdk/core/pathSerializer.gen.d.ts +33 -0
- package/sdk/core/pathSerializer.gen.js +123 -0
- package/sdk/core/pathSerializer.gen.ts +181 -0
- package/sdk/core/types.gen.d.ts +78 -0
- package/sdk/core/types.gen.js +4 -0
- package/sdk/core/types.gen.ts +121 -0
- package/sdk/index.d.ts +2 -0
- package/sdk/index.js +19 -0
- package/sdk/index.ts +3 -0
- package/sdk/sdk.gen.d.ts +1269 -0
- package/sdk/sdk.gen.js +2664 -0
- package/sdk/sdk.gen.ts +2677 -0
- package/sdk/types.gen.d.ts +6265 -0
- package/sdk/types.gen.js +3 -0
- package/sdk/types.gen.ts +6784 -0
- package/sdk-extensions/OperationClient.d.ts +64 -0
- package/sdk-extensions/OperationClient.js +251 -0
- package/sdk-extensions/OperationClient.ts +322 -0
- package/sdk-extensions/QueryClient.d.ts +50 -0
- package/sdk-extensions/QueryClient.js +190 -0
- package/sdk-extensions/QueryClient.ts +283 -0
- package/sdk-extensions/README.md +672 -0
- package/sdk-extensions/SSEClient.d.ts +48 -0
- package/sdk-extensions/SSEClient.js +148 -0
- package/sdk-extensions/SSEClient.ts +189 -0
- package/sdk-extensions/config.d.ts +32 -0
- package/sdk-extensions/config.js +74 -0
- package/sdk-extensions/config.ts +91 -0
- package/sdk-extensions/hooks.d.ts +110 -0
- package/sdk-extensions/hooks.js +371 -0
- package/sdk-extensions/hooks.ts +438 -0
- package/sdk-extensions/index.d.ts +46 -0
- package/sdk-extensions/index.js +110 -0
- package/sdk-extensions/index.ts +123 -0
- package/sdk.gen.d.ts +172 -48
- package/sdk.gen.js +297 -69
- package/sdk.gen.ts +296 -68
- package/types.gen.d.ts +647 -94
- package/types.gen.ts +727 -134
- package/openapi-ts.config.js +0 -9
- package/prepare.js +0 -221
package/sdk.gen.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
// This file is auto-generated by @hey-api/openapi-ts
|
|
2
2
|
|
|
3
3
|
import type { Options as ClientOptions, TDataShape, Client } from './client';
|
|
4
|
-
import type { RegisterUserData, RegisterUserResponses, RegisterUserErrors, LoginUserData, LoginUserResponses, LoginUserErrors, LogoutUserData, LogoutUserResponses, LogoutUserErrors, GetCurrentAuthUserData, GetCurrentAuthUserResponses, GetCurrentAuthUserErrors, RefreshSessionData, RefreshSessionResponses, RefreshSessionErrors, GenerateSsoTokenData, GenerateSsoTokenResponses, GenerateSsoTokenErrors, SsoLoginData, SsoLoginResponses, SsoLoginErrors, SsoTokenExchangeData, SsoTokenExchangeResponses, SsoTokenExchangeErrors, CompleteSsoAuthData, CompleteSsoAuthResponses, CompleteSsoAuthErrors, GetCaptchaConfigData, GetCaptchaConfigResponses, GetPasswordPolicyData, GetPasswordPolicyResponses, CheckPasswordStrengthData, CheckPasswordStrengthResponses, CheckPasswordStrengthErrors, GetServiceStatusData, GetServiceStatusResponses,
|
|
4
|
+
import type { RegisterUserData, RegisterUserResponses, RegisterUserErrors, LoginUserData, LoginUserResponses, LoginUserErrors, LogoutUserData, LogoutUserResponses, LogoutUserErrors, GetCurrentAuthUserData, GetCurrentAuthUserResponses, GetCurrentAuthUserErrors, RefreshSessionData, RefreshSessionResponses, RefreshSessionErrors, GenerateSsoTokenData, GenerateSsoTokenResponses, GenerateSsoTokenErrors, SsoLoginData, SsoLoginResponses, SsoLoginErrors, SsoTokenExchangeData, SsoTokenExchangeResponses, SsoTokenExchangeErrors, CompleteSsoAuthData, CompleteSsoAuthResponses, CompleteSsoAuthErrors, GetCaptchaConfigData, GetCaptchaConfigResponses, GetPasswordPolicyData, GetPasswordPolicyResponses, CheckPasswordStrengthData, CheckPasswordStrengthResponses, CheckPasswordStrengthErrors, GetServiceStatusData, GetServiceStatusResponses, GetCurrentUserData, GetCurrentUserResponses, GetCurrentUserErrors, UpdateUserData, UpdateUserResponses, UpdateUserErrors, GetUserGraphsData, GetUserGraphsResponses, GetUserGraphsErrors, SelectUserGraphData, SelectUserGraphResponses, SelectUserGraphErrors, GetAllCreditSummariesData, GetAllCreditSummariesResponses, GetAllCreditSummariesErrors, UpdateUserPasswordData, UpdateUserPasswordResponses, UpdateUserPasswordErrors, ListUserApiKeysData, ListUserApiKeysResponses, ListUserApiKeysErrors, CreateUserApiKeyData, CreateUserApiKeyResponses, CreateUserApiKeyErrors, RevokeUserApiKeyData, RevokeUserApiKeyResponses, RevokeUserApiKeyErrors, UpdateUserApiKeyData, UpdateUserApiKeyResponses, UpdateUserApiKeyErrors, GetUserLimitsData, GetUserLimitsResponses, GetUserLimitsErrors, GetUserUsageData, GetUserUsageResponses, GetUserUsageErrors, GetSharedRepositoryLimitsData, GetSharedRepositoryLimitsResponses, GetSharedRepositoryLimitsErrors, GetAllSharedRepositoryLimitsData, GetAllSharedRepositoryLimitsResponses, GetAllSharedRepositoryLimitsErrors, GetUserUsageOverviewData, GetUserUsageOverviewResponses, GetUserUsageOverviewErrors, GetDetailedUserAnalyticsData, GetDetailedUserAnalyticsResponses, GetDetailedUserAnalyticsErrors, GetUserSharedSubscriptionsData, GetUserSharedSubscriptionsResponses, GetUserSharedSubscriptionsErrors, SubscribeToSharedRepositoryData, SubscribeToSharedRepositoryResponses, SubscribeToSharedRepositoryErrors, UpgradeSharedRepositorySubscriptionData, UpgradeSharedRepositorySubscriptionResponses, UpgradeSharedRepositorySubscriptionErrors, CancelSharedRepositorySubscriptionData, CancelSharedRepositorySubscriptionResponses, CancelSharedRepositorySubscriptionErrors, GetSharedRepositoryCreditsData, GetSharedRepositoryCreditsResponses, GetSharedRepositoryCreditsErrors, GetRepositoryCreditsData, GetRepositoryCreditsResponses, GetRepositoryCreditsErrors, GetConnectionOptionsData, GetConnectionOptionsResponses, GetConnectionOptionsErrors, ListConnectionsData, ListConnectionsResponses, ListConnectionsErrors, CreateConnectionData, CreateConnectionResponses, CreateConnectionErrors, DeleteConnectionData, DeleteConnectionResponses, DeleteConnectionErrors, GetConnectionData, GetConnectionResponses, GetConnectionErrors, SyncConnectionData, SyncConnectionResponses, SyncConnectionErrors, CreateLinkTokenData, CreateLinkTokenResponses, CreateLinkTokenErrors, ExchangeLinkTokenData, ExchangeLinkTokenResponses, ExchangeLinkTokenErrors, InitOAuthData, InitOAuthResponses, InitOAuthErrors, OauthCallbackData, OauthCallbackResponses, OauthCallbackErrors, QueryFinancialAgentData, QueryFinancialAgentResponses, QueryFinancialAgentErrors, ListMcpToolsData, ListMcpToolsResponses, ListMcpToolsErrors, CallMcpToolData, CallMcpToolResponses, CallMcpToolErrors, CreateBackupData, CreateBackupResponses, CreateBackupErrors, ListBackupsData, ListBackupsResponses, ListBackupsErrors, ExportBackupData, ExportBackupResponses, ExportBackupErrors, RestoreBackupData, RestoreBackupResponses, RestoreBackupErrors, GetBackupStatsData, GetBackupStatsResponses, GetBackupStatsErrors, KuzuBackupHealthData, KuzuBackupHealthResponses, KuzuBackupHealthErrors, GetBackupDownloadUrlData, GetBackupDownloadUrlResponses, GetBackupDownloadUrlErrors, GetGraphMetricsData, GetGraphMetricsResponses, GetGraphMetricsErrors, GetGraphUsageStatsData, GetGraphUsageStatsResponses, GetGraphUsageStatsErrors, ExecuteCypherQueryData, ExecuteCypherQueryResponses, ExecuteCypherQueryErrors, GetGraphSchemaInfoData, GetGraphSchemaInfoResponses, GetGraphSchemaInfoErrors, ValidateSchemaData, ValidateSchemaResponses, ValidateSchemaErrors, ExportGraphSchemaData, ExportGraphSchemaResponses, ExportGraphSchemaErrors, ListSchemaExtensionsData, ListSchemaExtensionsResponses, ListSchemaExtensionsErrors, GetCurrentGraphBillData, GetCurrentGraphBillResponses, GetCurrentGraphBillErrors, GetGraphMonthlyBillData, GetGraphMonthlyBillResponses, GetGraphMonthlyBillErrors, GetGraphBillingHistoryData, GetGraphBillingHistoryResponses, GetGraphBillingHistoryErrors, GetGraphUsageDetailsData, GetGraphUsageDetailsResponses, GetGraphUsageDetailsErrors, GetGraphPricingInfoV1GraphIdBillingPricingGetData, GetGraphPricingInfoV1GraphIdBillingPricingGetResponses, GetGraphPricingInfoV1GraphIdBillingPricingGetErrors, UpgradeGraphSubscriptionV1GraphIdBillingSubscriptionUpgradePostData, UpgradeGraphSubscriptionV1GraphIdBillingSubscriptionUpgradePostResponses, UpgradeGraphSubscriptionV1GraphIdBillingSubscriptionUpgradePostErrors, GetGraphSubscriptionV1GraphIdBillingSubscriptionGetData, GetGraphSubscriptionV1GraphIdBillingSubscriptionGetResponses, GetGraphSubscriptionV1GraphIdBillingSubscriptionGetErrors, GetAvailableSubscriptionPlansV1GraphIdBillingAvailablePlansGetData, GetAvailableSubscriptionPlansV1GraphIdBillingAvailablePlansGetResponses, GetAvailableSubscriptionPlansV1GraphIdBillingAvailablePlansGetErrors, GetCreditBillingInfoV1GraphIdBillingCreditsGetData, GetCreditBillingInfoV1GraphIdBillingCreditsGetResponses, GetCreditBillingInfoV1GraphIdBillingCreditsGetErrors, GetCreditSummaryData, GetCreditSummaryResponses, GetCreditSummaryErrors, ListCreditTransactionsData, ListCreditTransactionsResponses, ListCreditTransactionsErrors, CheckCreditBalanceData, CheckCreditBalanceResponses, CheckCreditBalanceErrors, GetStorageUsageData, GetStorageUsageResponses, GetStorageUsageErrors, CheckStorageLimitsData, CheckStorageLimitsResponses, CheckStorageLimitsErrors, GetDatabaseHealthData, GetDatabaseHealthResponses, GetDatabaseHealthErrors, GetDatabaseInfoData, GetDatabaseInfoResponses, GetDatabaseInfoErrors, ListSubgraphsData, ListSubgraphsResponses, ListSubgraphsErrors, CreateSubgraphData, CreateSubgraphResponses, CreateSubgraphErrors, DeleteSubgraphData, DeleteSubgraphResponses, DeleteSubgraphErrors, GetSubgraphQuotaData, GetSubgraphQuotaResponses, GetSubgraphQuotaErrors, GetSubgraphInfoData, GetSubgraphInfoResponses, GetSubgraphInfoErrors, CreateGraphData, CreateGraphResponses, CreateGraphErrors, GetAvailableExtensionsData, GetAvailableExtensionsResponses, GetServiceOfferingsData, GetServiceOfferingsResponses, GetServiceOfferingsErrors, StreamOperationEventsData, StreamOperationEventsResponses, StreamOperationEventsErrors, GetOperationStatusData, GetOperationStatusResponses, GetOperationStatusErrors, CancelOperationData, CancelOperationResponses, CancelOperationErrors } from './types.gen';
|
|
5
5
|
import { client as _heyApiClient } from './client.gen';
|
|
6
6
|
|
|
7
7
|
export type Options<TData extends TDataShape = TDataShape, ThrowOnError extends boolean = boolean> = ClientOptions<TData, ThrowOnError> & {
|
|
@@ -185,27 +185,6 @@ export const getServiceStatus = <ThrowOnError extends boolean = false>(options?:
|
|
|
185
185
|
});
|
|
186
186
|
};
|
|
187
187
|
|
|
188
|
-
/**
|
|
189
|
-
* MCP System Health Check
|
|
190
|
-
* Basic health check for MCP system components
|
|
191
|
-
*/
|
|
192
|
-
export const getMcpHealth = <ThrowOnError extends boolean = false>(options?: Options<GetMcpHealthData, ThrowOnError>) => {
|
|
193
|
-
return (options?.client ?? _heyApiClient).get<GetMcpHealthResponses, unknown, ThrowOnError>({
|
|
194
|
-
security: [
|
|
195
|
-
{
|
|
196
|
-
name: 'X-API-Key',
|
|
197
|
-
type: 'apiKey'
|
|
198
|
-
},
|
|
199
|
-
{
|
|
200
|
-
scheme: 'bearer',
|
|
201
|
-
type: 'http'
|
|
202
|
-
}
|
|
203
|
-
],
|
|
204
|
-
url: '/v1/mcp/health',
|
|
205
|
-
...options
|
|
206
|
-
});
|
|
207
|
-
};
|
|
208
|
-
|
|
209
188
|
/**
|
|
210
189
|
* Get Current User
|
|
211
190
|
* Returns information about the currently authenticated user.
|
|
@@ -289,7 +268,7 @@ export const selectUserGraph = <ThrowOnError extends boolean = false>(options: O
|
|
|
289
268
|
type: 'http'
|
|
290
269
|
}
|
|
291
270
|
],
|
|
292
|
-
url: '/v1/user/graphs/
|
|
271
|
+
url: '/v1/user/graphs/{graph_id}/select',
|
|
293
272
|
...options
|
|
294
273
|
});
|
|
295
274
|
};
|
|
@@ -480,6 +459,56 @@ export const getUserUsage = <ThrowOnError extends boolean = false>(options?: Opt
|
|
|
480
459
|
});
|
|
481
460
|
};
|
|
482
461
|
|
|
462
|
+
/**
|
|
463
|
+
* Get shared repository rate limit status
|
|
464
|
+
* Get current rate limit status and usage for a shared repository.
|
|
465
|
+
*
|
|
466
|
+
* Returns:
|
|
467
|
+
* - Current usage across different time windows
|
|
468
|
+
* - Rate limits based on subscription tier
|
|
469
|
+
* - Remaining quota
|
|
470
|
+
* - Reset times
|
|
471
|
+
*
|
|
472
|
+
* Note: All queries are FREE - this only shows rate limit status.
|
|
473
|
+
*/
|
|
474
|
+
export const getSharedRepositoryLimits = <ThrowOnError extends boolean = false>(options: Options<GetSharedRepositoryLimitsData, ThrowOnError>) => {
|
|
475
|
+
return (options.client ?? _heyApiClient).get<GetSharedRepositoryLimitsResponses, GetSharedRepositoryLimitsErrors, ThrowOnError>({
|
|
476
|
+
security: [
|
|
477
|
+
{
|
|
478
|
+
name: 'X-API-Key',
|
|
479
|
+
type: 'apiKey'
|
|
480
|
+
},
|
|
481
|
+
{
|
|
482
|
+
scheme: 'bearer',
|
|
483
|
+
type: 'http'
|
|
484
|
+
}
|
|
485
|
+
],
|
|
486
|
+
url: '/v1/user/limits/shared-repositories/{repository}',
|
|
487
|
+
...options
|
|
488
|
+
});
|
|
489
|
+
};
|
|
490
|
+
|
|
491
|
+
/**
|
|
492
|
+
* Get all shared repository limits
|
|
493
|
+
* Get rate limit status for all shared repositories the user has access to.
|
|
494
|
+
*/
|
|
495
|
+
export const getAllSharedRepositoryLimits = <ThrowOnError extends boolean = false>(options?: Options<GetAllSharedRepositoryLimitsData, ThrowOnError>) => {
|
|
496
|
+
return (options?.client ?? _heyApiClient).get<GetAllSharedRepositoryLimitsResponses, GetAllSharedRepositoryLimitsErrors, ThrowOnError>({
|
|
497
|
+
security: [
|
|
498
|
+
{
|
|
499
|
+
name: 'X-API-Key',
|
|
500
|
+
type: 'apiKey'
|
|
501
|
+
},
|
|
502
|
+
{
|
|
503
|
+
scheme: 'bearer',
|
|
504
|
+
type: 'http'
|
|
505
|
+
}
|
|
506
|
+
],
|
|
507
|
+
url: '/v1/user/limits/shared-repositories/summary',
|
|
508
|
+
...options
|
|
509
|
+
});
|
|
510
|
+
};
|
|
511
|
+
|
|
483
512
|
/**
|
|
484
513
|
* Get User Usage Overview
|
|
485
514
|
* Get a high-level overview of usage statistics for the current user.
|
|
@@ -637,7 +666,7 @@ export const getSharedRepositoryCredits = <ThrowOnError extends boolean = false>
|
|
|
637
666
|
|
|
638
667
|
/**
|
|
639
668
|
* Get Repository Credits
|
|
640
|
-
* Get credit balance for a specific shared repository
|
|
669
|
+
* Get credit balance for a specific shared repository
|
|
641
670
|
*/
|
|
642
671
|
export const getRepositoryCredits = <ThrowOnError extends boolean = false>(options: Options<GetRepositoryCreditsData, ThrowOnError>) => {
|
|
643
672
|
return (options.client ?? _heyApiClient).get<GetRepositoryCreditsResponses, GetRepositoryCreditsErrors, ThrowOnError>({
|
|
@@ -651,7 +680,7 @@ export const getRepositoryCredits = <ThrowOnError extends boolean = false>(optio
|
|
|
651
680
|
type: 'http'
|
|
652
681
|
}
|
|
653
682
|
],
|
|
654
|
-
url: '/v1/user/subscriptions/shared-repositories/credits/{
|
|
683
|
+
url: '/v1/user/subscriptions/shared-repositories/credits/{repository}',
|
|
655
684
|
...options
|
|
656
685
|
});
|
|
657
686
|
};
|
|
@@ -751,10 +780,8 @@ export const listConnections = <ThrowOnError extends boolean = false>(options: O
|
|
|
751
780
|
* - User completes bank authentication
|
|
752
781
|
* - Exchange public token for access
|
|
753
782
|
*
|
|
754
|
-
*
|
|
755
|
-
* -
|
|
756
|
-
* - Multiplied by graph tier
|
|
757
|
-
* - Additional credits consumed during data sync
|
|
783
|
+
* Note:
|
|
784
|
+
* This operation is FREE - no credit consumption required.
|
|
758
785
|
*/
|
|
759
786
|
export const createConnection = <ThrowOnError extends boolean = false>(options: Options<CreateConnectionData, ThrowOnError>) => {
|
|
760
787
|
return (options.client ?? _heyApiClient).post<CreateConnectionResponses, CreateConnectionErrors, ThrowOnError>({
|
|
@@ -787,9 +814,8 @@ export const createConnection = <ThrowOnError extends boolean = false>(options:
|
|
|
787
814
|
* - Performs provider-specific cleanup
|
|
788
815
|
* - Revokes stored credentials
|
|
789
816
|
*
|
|
790
|
-
*
|
|
791
|
-
* -
|
|
792
|
-
* - Multiplied by graph tier
|
|
817
|
+
* Note:
|
|
818
|
+
* This operation is FREE - no credit consumption required.
|
|
793
819
|
*
|
|
794
820
|
* Only users with admin role can delete connections.
|
|
795
821
|
*/
|
|
@@ -862,10 +888,8 @@ export const getConnection = <ThrowOnError extends boolean = false>(options: Opt
|
|
|
862
888
|
* - Updates account balances
|
|
863
889
|
* - Categorizes new transactions
|
|
864
890
|
*
|
|
865
|
-
*
|
|
866
|
-
* -
|
|
867
|
-
* - Multiplied by graph tier
|
|
868
|
-
* - Additional credits may be consumed during processing
|
|
891
|
+
* Note:
|
|
892
|
+
* This operation is FREE - no credit consumption required.
|
|
869
893
|
*
|
|
870
894
|
* Returns a task ID for monitoring sync progress.
|
|
871
895
|
*/
|
|
@@ -1085,10 +1109,10 @@ export const oauthCallback = <ThrowOnError extends boolean = false>(options: Opt
|
|
|
1085
1109
|
* - Fallback to status polling endpoint if SSE unavailable
|
|
1086
1110
|
*
|
|
1087
1111
|
* **Credit Consumption:**
|
|
1088
|
-
* -
|
|
1089
|
-
* -
|
|
1090
|
-
* -
|
|
1091
|
-
* -
|
|
1112
|
+
* - AI operations consume credits based on actual token usage
|
|
1113
|
+
* - Claude 4/4.1 Opus: ~15 credits per 1K input tokens, ~75 credits per 1K output tokens
|
|
1114
|
+
* - Claude 4 Sonnet: ~3 credits per 1K input tokens, ~15 credits per 1K output tokens
|
|
1115
|
+
* - Credits are consumed after operation completes based on actual usage
|
|
1092
1116
|
*
|
|
1093
1117
|
* The agent automatically determines query complexity or you can force extended analysis.
|
|
1094
1118
|
*/
|
|
@@ -1182,11 +1206,8 @@ export const listMcpTools = <ThrowOnError extends boolean = false>(options: Opti
|
|
|
1182
1206
|
* - `408 Request Timeout`: Tool execution exceeded timeout
|
|
1183
1207
|
* - Clients should implement exponential backoff on errors
|
|
1184
1208
|
*
|
|
1185
|
-
* **
|
|
1186
|
-
*
|
|
1187
|
-
* - Schema tools: 5-10 credits
|
|
1188
|
-
* - Query tools: 10-50 credits (based on complexity)
|
|
1189
|
-
* - Multiplied by graph tier
|
|
1209
|
+
* **Note:**
|
|
1210
|
+
* MCP tool calls are currently FREE and do not consume credits.
|
|
1190
1211
|
*/
|
|
1191
1212
|
export const callMcpTool = <ThrowOnError extends boolean = false>(options: Options<CallMcpToolData, ThrowOnError>) => {
|
|
1192
1213
|
return (options.client ?? _heyApiClient).post<CallMcpToolResponses, CallMcpToolErrors, ThrowOnError>({
|
|
@@ -1445,7 +1466,7 @@ export const getBackupDownloadUrl = <ThrowOnError extends boolean = false>(optio
|
|
|
1445
1466
|
type: 'http'
|
|
1446
1467
|
}
|
|
1447
1468
|
],
|
|
1448
|
-
url: '/v1/{graph_id}/backup/{backup_id}/download
|
|
1469
|
+
url: '/v1/{graph_id}/backup/{backup_id}/download',
|
|
1449
1470
|
...options
|
|
1450
1471
|
});
|
|
1451
1472
|
};
|
|
@@ -1467,9 +1488,8 @@ export const getBackupDownloadUrl = <ThrowOnError extends boolean = false>(optio
|
|
|
1467
1488
|
* - Capacity planning
|
|
1468
1489
|
* - Performance optimization
|
|
1469
1490
|
*
|
|
1470
|
-
*
|
|
1471
|
-
* -
|
|
1472
|
-
* - Multiplied by graph tier (standard=1x, enterprise=2x, premium=4x)
|
|
1491
|
+
* Note:
|
|
1492
|
+
* This operation is FREE - no credit consumption required.
|
|
1473
1493
|
*/
|
|
1474
1494
|
export const getGraphMetrics = <ThrowOnError extends boolean = false>(options: Options<GetGraphMetricsData, ThrowOnError>) => {
|
|
1475
1495
|
return (options.client ?? _heyApiClient).get<GetGraphMetricsResponses, GetGraphMetricsErrors, ThrowOnError>({
|
|
@@ -1511,9 +1531,8 @@ export const getGraphMetrics = <ThrowOnError extends boolean = false>(options: O
|
|
|
1511
1531
|
* - Usage trend analysis
|
|
1512
1532
|
* - Performance tuning
|
|
1513
1533
|
*
|
|
1514
|
-
*
|
|
1515
|
-
* -
|
|
1516
|
-
* - Multiplied by graph tier
|
|
1534
|
+
* Note:
|
|
1535
|
+
* This operation is FREE - no credit consumption required.
|
|
1517
1536
|
*/
|
|
1518
1537
|
export const getGraphUsageStats = <ThrowOnError extends boolean = false>(options: Options<GetGraphUsageStatsData, ThrowOnError>) => {
|
|
1519
1538
|
return (options.client ?? _heyApiClient).get<GetGraphUsageStatsResponses, GetGraphUsageStatsErrors, ThrowOnError>({
|
|
@@ -1545,7 +1564,7 @@ export const getGraphUsageStats = <ThrowOnError extends boolean = false>(options
|
|
|
1545
1564
|
* **Response Modes:**
|
|
1546
1565
|
* - `auto` (default): Intelligent automatic selection
|
|
1547
1566
|
* - `sync`: Force synchronous JSON response (best for testing)
|
|
1548
|
-
* - `async`: Force queued response with polling
|
|
1567
|
+
* - `async`: Force queued response with SSE monitoring endpoints (no polling needed)
|
|
1549
1568
|
* - `stream`: Force streaming response (SSE or NDJSON)
|
|
1550
1569
|
*
|
|
1551
1570
|
* **Client Detection:**
|
|
@@ -1568,19 +1587,19 @@ export const getGraphUsageStats = <ThrowOnError extends boolean = false>(options
|
|
|
1568
1587
|
*
|
|
1569
1588
|
* **Queue Management:**
|
|
1570
1589
|
* - Automatic queuing under high load
|
|
1571
|
-
* -
|
|
1590
|
+
* - Real-time monitoring via SSE events (no polling needed)
|
|
1572
1591
|
* - Priority based on subscription tier
|
|
1573
|
-
* - Queue position updates via SSE
|
|
1592
|
+
* - Queue position and progress updates pushed via SSE
|
|
1593
|
+
* - Connect to returned `/v1/operations/{id}/stream` endpoint for updates
|
|
1574
1594
|
*
|
|
1575
1595
|
* **Error Handling:**
|
|
1576
1596
|
* - `429 Too Many Requests`: Rate limit or connection limit exceeded
|
|
1577
1597
|
* - `503 Service Unavailable`: Circuit breaker open or SSE disabled
|
|
1578
1598
|
* - Clients should implement exponential backoff
|
|
1579
1599
|
*
|
|
1580
|
-
* **
|
|
1581
|
-
*
|
|
1582
|
-
*
|
|
1583
|
-
* - Queue position based on subscription tier
|
|
1600
|
+
* **Note:**
|
|
1601
|
+
* Query operations are FREE - no credit consumption required.
|
|
1602
|
+
* Queue position is based on subscription tier for priority.
|
|
1584
1603
|
*/
|
|
1585
1604
|
export const executeCypherQuery = <ThrowOnError extends boolean = false>(options: Options<ExecuteCypherQueryData, ThrowOnError>) => {
|
|
1586
1605
|
return (options.client ?? _heyApiClient).post<ExecuteCypherQueryResponses, ExecuteCypherQueryErrors, ThrowOnError>({
|
|
@@ -1615,10 +1634,7 @@ export const executeCypherQuery = <ThrowOnError extends boolean = false>(options
|
|
|
1615
1634
|
* This is different from custom schema management - it shows what actually exists in the database,
|
|
1616
1635
|
* useful for understanding the current graph structure before writing queries.
|
|
1617
1636
|
*
|
|
1618
|
-
*
|
|
1619
|
-
* - Base cost: 2.0 credits
|
|
1620
|
-
* - Multiplied by graph tier (standard=1x, enterprise=2x, premium=4x)
|
|
1621
|
-
* - Schema information is cached for performance
|
|
1637
|
+
* This operation is FREE - no credit consumption required.
|
|
1622
1638
|
*/
|
|
1623
1639
|
export const getGraphSchemaInfo = <ThrowOnError extends boolean = false>(options: Options<GetGraphSchemaInfoData, ThrowOnError>) => {
|
|
1624
1640
|
return (options.client ?? _heyApiClient).get<GetGraphSchemaInfoResponses, GetGraphSchemaInfoErrors, ThrowOnError>({
|
|
@@ -1660,9 +1676,7 @@ export const getGraphSchemaInfo = <ThrowOnError extends boolean = false>(options
|
|
|
1660
1676
|
* - Performance problems
|
|
1661
1677
|
* - Naming conflicts
|
|
1662
1678
|
*
|
|
1663
|
-
*
|
|
1664
|
-
* - Base cost: 5.0 credits
|
|
1665
|
-
* - Multiplied by graph tier
|
|
1679
|
+
* This operation is FREE - no credit consumption required.
|
|
1666
1680
|
*/
|
|
1667
1681
|
export const validateSchema = <ThrowOnError extends boolean = false>(options: Options<ValidateSchemaData, ThrowOnError>) => {
|
|
1668
1682
|
return (options.client ?? _heyApiClient).post<ValidateSchemaResponses, ValidateSchemaErrors, ThrowOnError>({
|
|
@@ -2208,6 +2222,220 @@ export const getDatabaseInfo = <ThrowOnError extends boolean = false>(options: O
|
|
|
2208
2222
|
});
|
|
2209
2223
|
};
|
|
2210
2224
|
|
|
2225
|
+
/**
|
|
2226
|
+
* List Subgraphs
|
|
2227
|
+
* List all subgraphs for a parent graph.
|
|
2228
|
+
*
|
|
2229
|
+
* **Requirements:**
|
|
2230
|
+
* - User must have at least read access to parent graph
|
|
2231
|
+
*
|
|
2232
|
+
* **Response includes:**
|
|
2233
|
+
* - List of all subgraphs with metadata
|
|
2234
|
+
* - Current usage vs limits
|
|
2235
|
+
* - Size and statistics per subgraph
|
|
2236
|
+
* - Creation timestamps
|
|
2237
|
+
*
|
|
2238
|
+
* **Filtering:**
|
|
2239
|
+
* Currently returns all subgraphs. Future versions will support:
|
|
2240
|
+
* - Filtering by status
|
|
2241
|
+
* - Filtering by creation date
|
|
2242
|
+
* - Pagination for large lists
|
|
2243
|
+
*/
|
|
2244
|
+
export const listSubgraphs = <ThrowOnError extends boolean = false>(options: Options<ListSubgraphsData, ThrowOnError>) => {
|
|
2245
|
+
return (options.client ?? _heyApiClient).get<ListSubgraphsResponses, ListSubgraphsErrors, ThrowOnError>({
|
|
2246
|
+
security: [
|
|
2247
|
+
{
|
|
2248
|
+
name: 'X-API-Key',
|
|
2249
|
+
type: 'apiKey'
|
|
2250
|
+
},
|
|
2251
|
+
{
|
|
2252
|
+
scheme: 'bearer',
|
|
2253
|
+
type: 'http'
|
|
2254
|
+
}
|
|
2255
|
+
],
|
|
2256
|
+
url: '/v1/{graph_id}/subgraphs',
|
|
2257
|
+
...options
|
|
2258
|
+
});
|
|
2259
|
+
};
|
|
2260
|
+
|
|
2261
|
+
/**
|
|
2262
|
+
* Create New Subgraph
|
|
2263
|
+
* Create a new subgraph database under an Enterprise or Premium parent graph.
|
|
2264
|
+
*
|
|
2265
|
+
* **Requirements:**
|
|
2266
|
+
* - Parent graph must be Enterprise or Premium tier
|
|
2267
|
+
* - User must have admin access to parent graph
|
|
2268
|
+
* - Subgraph name must be unique within parent
|
|
2269
|
+
* - Subgraph name must be alphanumeric (1-20 chars)
|
|
2270
|
+
*
|
|
2271
|
+
* **Subgraph Benefits:**
|
|
2272
|
+
* - Shares parent's infrastructure (no additional cost)
|
|
2273
|
+
* - Inherits parent's credit pool
|
|
2274
|
+
* - Isolated database on same instance
|
|
2275
|
+
* - Full Kuzu database capabilities
|
|
2276
|
+
*
|
|
2277
|
+
* **Use Cases:**
|
|
2278
|
+
* - Separate environments (dev/staging/prod)
|
|
2279
|
+
* - Department-specific data isolation
|
|
2280
|
+
* - Multi-tenant applications
|
|
2281
|
+
* - Testing and experimentation
|
|
2282
|
+
*
|
|
2283
|
+
* **Schema Inheritance:**
|
|
2284
|
+
* - Subgraphs can use parent's schema or custom extensions
|
|
2285
|
+
* - Extensions are additive only
|
|
2286
|
+
* - Base schema always included
|
|
2287
|
+
*
|
|
2288
|
+
* **Limits:**
|
|
2289
|
+
* - Standard: Not supported (0 subgraphs)
|
|
2290
|
+
* - Enterprise: Configurable limit (default: 10 subgraphs)
|
|
2291
|
+
* - Premium: Unlimited subgraphs
|
|
2292
|
+
* - Limits are defined in deployment configuration
|
|
2293
|
+
*
|
|
2294
|
+
* **Response includes:**
|
|
2295
|
+
* - `graph_id`: Full subgraph identifier
|
|
2296
|
+
* - `parent_graph_id`: Parent graph ID
|
|
2297
|
+
* - `subgraph_name`: Short name within parent
|
|
2298
|
+
* - `status`: Creation status
|
|
2299
|
+
*/
|
|
2300
|
+
export const createSubgraph = <ThrowOnError extends boolean = false>(options: Options<CreateSubgraphData, ThrowOnError>) => {
|
|
2301
|
+
return (options.client ?? _heyApiClient).post<CreateSubgraphResponses, CreateSubgraphErrors, ThrowOnError>({
|
|
2302
|
+
security: [
|
|
2303
|
+
{
|
|
2304
|
+
name: 'X-API-Key',
|
|
2305
|
+
type: 'apiKey'
|
|
2306
|
+
},
|
|
2307
|
+
{
|
|
2308
|
+
scheme: 'bearer',
|
|
2309
|
+
type: 'http'
|
|
2310
|
+
}
|
|
2311
|
+
],
|
|
2312
|
+
url: '/v1/{graph_id}/subgraphs',
|
|
2313
|
+
...options,
|
|
2314
|
+
headers: {
|
|
2315
|
+
'Content-Type': 'application/json',
|
|
2316
|
+
...options.headers
|
|
2317
|
+
}
|
|
2318
|
+
});
|
|
2319
|
+
};
|
|
2320
|
+
|
|
2321
|
+
/**
|
|
2322
|
+
* Delete Subgraph
|
|
2323
|
+
* Delete a subgraph database.
|
|
2324
|
+
*
|
|
2325
|
+
* **Requirements:**
|
|
2326
|
+
* - Must be a valid subgraph (not parent graph)
|
|
2327
|
+
* - User must have admin access to parent graph
|
|
2328
|
+
* - Optional backup before deletion
|
|
2329
|
+
*
|
|
2330
|
+
* **Deletion Options:**
|
|
2331
|
+
* - `force`: Delete even if contains data
|
|
2332
|
+
* - `backup_first`: Create backup before deletion
|
|
2333
|
+
*
|
|
2334
|
+
* **Warning:**
|
|
2335
|
+
* Deletion is permanent unless backup is created.
|
|
2336
|
+
* All data in the subgraph will be lost.
|
|
2337
|
+
*
|
|
2338
|
+
* **Backup Location:**
|
|
2339
|
+
* If backup requested, stored in S3 at:
|
|
2340
|
+
* `s3://robosystems-backups/{instance_id}/{database_name}_{timestamp}.backup`
|
|
2341
|
+
*/
|
|
2342
|
+
export const deleteSubgraph = <ThrowOnError extends boolean = false>(options: Options<DeleteSubgraphData, ThrowOnError>) => {
|
|
2343
|
+
return (options.client ?? _heyApiClient).delete<DeleteSubgraphResponses, DeleteSubgraphErrors, ThrowOnError>({
|
|
2344
|
+
security: [
|
|
2345
|
+
{
|
|
2346
|
+
name: 'X-API-Key',
|
|
2347
|
+
type: 'apiKey'
|
|
2348
|
+
},
|
|
2349
|
+
{
|
|
2350
|
+
scheme: 'bearer',
|
|
2351
|
+
type: 'http'
|
|
2352
|
+
}
|
|
2353
|
+
],
|
|
2354
|
+
url: '/v1/{graph_id}/subgraphs/{subgraph_name}',
|
|
2355
|
+
...options,
|
|
2356
|
+
headers: {
|
|
2357
|
+
'Content-Type': 'application/json',
|
|
2358
|
+
...options.headers
|
|
2359
|
+
}
|
|
2360
|
+
});
|
|
2361
|
+
};
|
|
2362
|
+
|
|
2363
|
+
/**
|
|
2364
|
+
* Get Subgraph Quota
|
|
2365
|
+
* Get subgraph quota and usage information for a parent graph.
|
|
2366
|
+
*
|
|
2367
|
+
* **Shows:**
|
|
2368
|
+
* - Current subgraph count
|
|
2369
|
+
* - Maximum allowed subgraphs per tier
|
|
2370
|
+
* - Remaining capacity
|
|
2371
|
+
* - Total size usage across all subgraphs
|
|
2372
|
+
*
|
|
2373
|
+
* **Tier Limits:**
|
|
2374
|
+
* - Standard: 0 subgraphs (not supported)
|
|
2375
|
+
* - Enterprise: Configurable limit (default: 10 subgraphs)
|
|
2376
|
+
* - Premium: Unlimited subgraphs
|
|
2377
|
+
* - Limits are defined in deployment configuration
|
|
2378
|
+
*
|
|
2379
|
+
* **Size Tracking:**
|
|
2380
|
+
* Provides aggregate size metrics when available.
|
|
2381
|
+
* Individual subgraph sizes shown in list endpoint.
|
|
2382
|
+
*/
|
|
2383
|
+
export const getSubgraphQuota = <ThrowOnError extends boolean = false>(options: Options<GetSubgraphQuotaData, ThrowOnError>) => {
|
|
2384
|
+
return (options.client ?? _heyApiClient).get<GetSubgraphQuotaResponses, GetSubgraphQuotaErrors, ThrowOnError>({
|
|
2385
|
+
security: [
|
|
2386
|
+
{
|
|
2387
|
+
name: 'X-API-Key',
|
|
2388
|
+
type: 'apiKey'
|
|
2389
|
+
},
|
|
2390
|
+
{
|
|
2391
|
+
scheme: 'bearer',
|
|
2392
|
+
type: 'http'
|
|
2393
|
+
}
|
|
2394
|
+
],
|
|
2395
|
+
url: '/v1/{graph_id}/subgraphs/quota',
|
|
2396
|
+
...options
|
|
2397
|
+
});
|
|
2398
|
+
};
|
|
2399
|
+
|
|
2400
|
+
/**
|
|
2401
|
+
* Get Subgraph Details
|
|
2402
|
+
* Get detailed information about a specific subgraph.
|
|
2403
|
+
*
|
|
2404
|
+
* **Requirements:**
|
|
2405
|
+
* - User must have read access to parent graph
|
|
2406
|
+
*
|
|
2407
|
+
* **Response includes:**
|
|
2408
|
+
* - Full subgraph metadata
|
|
2409
|
+
* - Database statistics (nodes, edges)
|
|
2410
|
+
* - Size information
|
|
2411
|
+
* - Schema configuration
|
|
2412
|
+
* - Creation/modification timestamps
|
|
2413
|
+
* - Last access time (when available)
|
|
2414
|
+
*
|
|
2415
|
+
* **Statistics:**
|
|
2416
|
+
* Real-time statistics queried from Kuzu:
|
|
2417
|
+
* - Node count
|
|
2418
|
+
* - Edge count
|
|
2419
|
+
* - Database size on disk
|
|
2420
|
+
* - Schema information
|
|
2421
|
+
*/
|
|
2422
|
+
export const getSubgraphInfo = <ThrowOnError extends boolean = false>(options: Options<GetSubgraphInfoData, ThrowOnError>) => {
|
|
2423
|
+
return (options.client ?? _heyApiClient).get<GetSubgraphInfoResponses, GetSubgraphInfoErrors, ThrowOnError>({
|
|
2424
|
+
security: [
|
|
2425
|
+
{
|
|
2426
|
+
name: 'X-API-Key',
|
|
2427
|
+
type: 'apiKey'
|
|
2428
|
+
},
|
|
2429
|
+
{
|
|
2430
|
+
scheme: 'bearer',
|
|
2431
|
+
type: 'http'
|
|
2432
|
+
}
|
|
2433
|
+
],
|
|
2434
|
+
url: '/v1/{graph_id}/subgraphs/{subgraph_name}/info',
|
|
2435
|
+
...options
|
|
2436
|
+
});
|
|
2437
|
+
};
|
|
2438
|
+
|
|
2211
2439
|
/**
|
|
2212
2440
|
* Create New Graph Database
|
|
2213
2441
|
* Create a new graph database with specified schema and optionally an initial entity.
|
|
@@ -2288,7 +2516,7 @@ export const getAvailableExtensions = <ThrowOnError extends boolean = false>(opt
|
|
|
2288
2516
|
type: 'http'
|
|
2289
2517
|
}
|
|
2290
2518
|
],
|
|
2291
|
-
url: '/v1/create/graph/
|
|
2519
|
+
url: '/v1/create/graph/extensions',
|
|
2292
2520
|
...options
|
|
2293
2521
|
});
|
|
2294
2522
|
};
|
|
@@ -2302,7 +2530,7 @@ export const getAvailableExtensions = <ThrowOnError extends boolean = false>(opt
|
|
|
2302
2530
|
* applications to display subscription options.
|
|
2303
2531
|
*
|
|
2304
2532
|
* Includes:
|
|
2305
|
-
* - Graph subscription tiers (
|
|
2533
|
+
* - Graph subscription tiers (standard, enterprise, premium)
|
|
2306
2534
|
* - Shared repository subscriptions (SEC, industry, economic data)
|
|
2307
2535
|
* - Operation costs and credit information
|
|
2308
2536
|
* - Features and capabilities for each tier
|