@robosystems/client 0.1.15 → 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.
Files changed (66) hide show
  1. package/package.json +48 -6
  2. package/sdk/client/client.gen.d.ts +2 -0
  3. package/sdk/client/client.gen.js +153 -0
  4. package/sdk/client/client.gen.ts +200 -0
  5. package/sdk/client/index.d.ts +7 -0
  6. package/sdk/client/index.js +15 -0
  7. package/sdk/client/index.ts +25 -0
  8. package/sdk/client/types.gen.d.ts +122 -0
  9. package/sdk/client/types.gen.js +4 -0
  10. package/sdk/client/types.gen.ts +233 -0
  11. package/sdk/client/utils.gen.d.ts +45 -0
  12. package/sdk/client/utils.gen.js +296 -0
  13. package/sdk/client/utils.gen.ts +419 -0
  14. package/sdk/client.gen.d.ts +12 -0
  15. package/sdk/client.gen.js +8 -0
  16. package/sdk/client.gen.ts +18 -0
  17. package/sdk/core/auth.gen.d.ts +18 -0
  18. package/sdk/core/auth.gen.js +18 -0
  19. package/sdk/core/auth.gen.ts +42 -0
  20. package/sdk/core/bodySerializer.gen.d.ts +17 -0
  21. package/sdk/core/bodySerializer.gen.js +57 -0
  22. package/sdk/core/bodySerializer.gen.ts +90 -0
  23. package/sdk/core/params.gen.d.ts +33 -0
  24. package/sdk/core/params.gen.js +92 -0
  25. package/sdk/core/params.gen.ts +153 -0
  26. package/sdk/core/pathSerializer.gen.d.ts +33 -0
  27. package/sdk/core/pathSerializer.gen.js +123 -0
  28. package/sdk/core/pathSerializer.gen.ts +181 -0
  29. package/sdk/core/types.gen.d.ts +78 -0
  30. package/sdk/core/types.gen.js +4 -0
  31. package/sdk/core/types.gen.ts +121 -0
  32. package/sdk/index.d.ts +2 -0
  33. package/sdk/index.js +19 -0
  34. package/sdk/index.ts +3 -0
  35. package/sdk/sdk.gen.d.ts +1269 -0
  36. package/sdk/sdk.gen.js +2664 -0
  37. package/sdk/sdk.gen.ts +2677 -0
  38. package/sdk/types.gen.d.ts +6265 -0
  39. package/sdk/types.gen.js +3 -0
  40. package/sdk/types.gen.ts +6784 -0
  41. package/sdk-extensions/OperationClient.d.ts +64 -0
  42. package/sdk-extensions/OperationClient.js +251 -0
  43. package/sdk-extensions/OperationClient.ts +322 -0
  44. package/sdk-extensions/QueryClient.d.ts +50 -0
  45. package/sdk-extensions/QueryClient.js +190 -0
  46. package/sdk-extensions/QueryClient.ts +283 -0
  47. package/sdk-extensions/README.md +672 -0
  48. package/sdk-extensions/SSEClient.d.ts +48 -0
  49. package/sdk-extensions/SSEClient.js +148 -0
  50. package/sdk-extensions/SSEClient.ts +189 -0
  51. package/sdk-extensions/config.d.ts +32 -0
  52. package/sdk-extensions/config.js +74 -0
  53. package/sdk-extensions/config.ts +91 -0
  54. package/sdk-extensions/hooks.d.ts +110 -0
  55. package/sdk-extensions/hooks.js +371 -0
  56. package/sdk-extensions/hooks.ts +438 -0
  57. package/sdk-extensions/index.d.ts +46 -0
  58. package/sdk-extensions/index.js +110 -0
  59. package/sdk-extensions/index.ts +123 -0
  60. package/sdk.gen.d.ts +128 -2
  61. package/sdk.gen.js +216 -2
  62. package/sdk.gen.ts +216 -2
  63. package/types.gen.d.ts +573 -4
  64. package/types.gen.ts +606 -4
  65. package/openapi-ts.config.js +0 -9
  66. package/prepare.js +0 -220
@@ -0,0 +1,123 @@
1
+ /**
2
+ * RoboSystems SDK Extensions
3
+ * Enhanced clients with SSE support for the RoboSystems API
4
+ */
5
+
6
+ import { client } from '../sdk/client.gen'
7
+ import { OperationClient } from './OperationClient'
8
+ import { QueryClient } from './QueryClient'
9
+ import { SSEClient } from './SSEClient'
10
+
11
+ export interface RoboSystemsExtensionConfig {
12
+ baseUrl?: string
13
+ credentials?: 'include' | 'same-origin' | 'omit'
14
+ maxRetries?: number
15
+ retryDelay?: number
16
+ }
17
+
18
+ export class RoboSystemsExtensions {
19
+ public readonly query: QueryClient
20
+ public readonly operations: OperationClient
21
+ private config: Required<RoboSystemsExtensionConfig>
22
+
23
+ constructor(config: RoboSystemsExtensionConfig = {}) {
24
+ // Get base URL from SDK client config or use provided/default
25
+ const sdkConfig = client.getConfig()
26
+
27
+ this.config = {
28
+ baseUrl: config.baseUrl || sdkConfig.baseUrl || 'http://localhost:8000',
29
+ credentials: config.credentials || 'include',
30
+ maxRetries: config.maxRetries || 5,
31
+ retryDelay: config.retryDelay || 1000,
32
+ }
33
+
34
+ this.query = new QueryClient({
35
+ baseUrl: this.config.baseUrl,
36
+ credentials: this.config.credentials,
37
+ })
38
+
39
+ this.operations = new OperationClient({
40
+ baseUrl: this.config.baseUrl,
41
+ credentials: this.config.credentials,
42
+ })
43
+ }
44
+
45
+ /**
46
+ * Convenience method to monitor any operation
47
+ */
48
+ async monitorOperation(operationId: string, onProgress?: (progress: any) => void): Promise<any> {
49
+ return this.operations.monitorOperation(operationId, { onProgress })
50
+ }
51
+
52
+ /**
53
+ * Create custom SSE client for advanced use cases
54
+ */
55
+ createSSEClient(): SSEClient {
56
+ return new SSEClient({
57
+ baseUrl: this.config.baseUrl,
58
+ credentials: this.config.credentials,
59
+ maxRetries: this.config.maxRetries,
60
+ retryDelay: this.config.retryDelay,
61
+ })
62
+ }
63
+
64
+ /**
65
+ * Clean up all active connections
66
+ */
67
+ close(): void {
68
+ this.query.close()
69
+ this.operations.closeAll()
70
+ }
71
+ }
72
+
73
+ // Export all types and classes
74
+ export * from './OperationClient'
75
+ export * from './QueryClient'
76
+ export * from './SSEClient'
77
+ export { OperationClient, QueryClient, SSEClient }
78
+
79
+ // Export React hooks
80
+ export {
81
+ useMultipleOperations,
82
+ useOperation,
83
+ useQuery,
84
+ useSDKClients,
85
+ useStreamingQuery,
86
+ } from './hooks'
87
+
88
+ // Lazy initialization of default instance
89
+ let _extensions: RoboSystemsExtensions | null = null
90
+
91
+ function getExtensions(): RoboSystemsExtensions {
92
+ if (!_extensions) {
93
+ _extensions = new RoboSystemsExtensions()
94
+ }
95
+ return _extensions
96
+ }
97
+
98
+ export const extensions = {
99
+ get query() {
100
+ return getExtensions().query
101
+ },
102
+ get operations() {
103
+ return getExtensions().operations
104
+ },
105
+ monitorOperation: (operationId: string, onProgress?: (progress: any) => void) =>
106
+ getExtensions().monitorOperation(operationId, onProgress),
107
+ createSSEClient: () => getExtensions().createSSEClient(),
108
+ close: () => getExtensions().close(),
109
+ }
110
+
111
+ // Export convenience functions that use the default instance
112
+ export const monitorOperation = (operationId: string, onProgress?: (progress: any) => void) =>
113
+ getExtensions().monitorOperation(operationId, onProgress)
114
+
115
+ export const executeQuery = (graphId: string, query: string, parameters?: Record<string, any>) =>
116
+ getExtensions().query.query(graphId, query, parameters)
117
+
118
+ export const streamQuery = (
119
+ graphId: string,
120
+ query: string,
121
+ parameters?: Record<string, any>,
122
+ chunkSize?: number
123
+ ) => getExtensions().query.streamQuery(graphId, query, parameters, chunkSize)
package/sdk.gen.d.ts CHANGED
@@ -1,5 +1,5 @@
1
1
  import type { Options as ClientOptions, TDataShape, Client } from './client';
2
- 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, CreateGraphData, CreateGraphResponses, CreateGraphErrors, GetAvailableExtensionsData, GetAvailableExtensionsResponses, GetServiceOfferingsData, GetServiceOfferingsResponses, GetServiceOfferingsErrors, StreamOperationEventsData, StreamOperationEventsResponses, StreamOperationEventsErrors, GetOperationStatusData, GetOperationStatusResponses, GetOperationStatusErrors, CancelOperationData, CancelOperationResponses, CancelOperationErrors } from './types.gen';
2
+ 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';
3
3
  export type Options<TData extends TDataShape = TDataShape, ThrowOnError extends boolean = boolean> = ClientOptions<TData, ThrowOnError> & {
4
4
  /**
5
5
  * You can provide a client instance returned by `createClient()` instead of
@@ -443,7 +443,7 @@ export declare const oauthCallback: <ThrowOnError extends boolean = false>(optio
443
443
  *
444
444
  * **Credit Consumption:**
445
445
  * - AI operations consume credits based on actual token usage
446
- * - Claude 4 Opus: ~15 credits per 1K input tokens, ~75 credits per 1K output tokens
446
+ * - Claude 4/4.1 Opus: ~15 credits per 1K input tokens, ~75 credits per 1K output tokens
447
447
  * - Claude 4 Sonnet: ~3 credits per 1K input tokens, ~15 credits per 1K output tokens
448
448
  * - Credits are consumed after operation completes based on actual usage
449
449
  *
@@ -991,6 +991,132 @@ export declare const getDatabaseHealth: <ThrowOnError extends boolean = false>(o
991
991
  * This endpoint provides essential database information for capacity planning and monitoring.
992
992
  */
993
993
  export declare const getDatabaseInfo: <ThrowOnError extends boolean = false>(options: Options<GetDatabaseInfoData, ThrowOnError>) => import("./client").RequestResult<GetDatabaseInfoResponses, GetDatabaseInfoErrors, ThrowOnError, "fields">;
994
+ /**
995
+ * List Subgraphs
996
+ * List all subgraphs for a parent graph.
997
+ *
998
+ * **Requirements:**
999
+ * - User must have at least read access to parent graph
1000
+ *
1001
+ * **Response includes:**
1002
+ * - List of all subgraphs with metadata
1003
+ * - Current usage vs limits
1004
+ * - Size and statistics per subgraph
1005
+ * - Creation timestamps
1006
+ *
1007
+ * **Filtering:**
1008
+ * Currently returns all subgraphs. Future versions will support:
1009
+ * - Filtering by status
1010
+ * - Filtering by creation date
1011
+ * - Pagination for large lists
1012
+ */
1013
+ export declare const listSubgraphs: <ThrowOnError extends boolean = false>(options: Options<ListSubgraphsData, ThrowOnError>) => import("./client").RequestResult<ListSubgraphsResponses, ListSubgraphsErrors, ThrowOnError, "fields">;
1014
+ /**
1015
+ * Create New Subgraph
1016
+ * Create a new subgraph database under an Enterprise or Premium parent graph.
1017
+ *
1018
+ * **Requirements:**
1019
+ * - Parent graph must be Enterprise or Premium tier
1020
+ * - User must have admin access to parent graph
1021
+ * - Subgraph name must be unique within parent
1022
+ * - Subgraph name must be alphanumeric (1-20 chars)
1023
+ *
1024
+ * **Subgraph Benefits:**
1025
+ * - Shares parent's infrastructure (no additional cost)
1026
+ * - Inherits parent's credit pool
1027
+ * - Isolated database on same instance
1028
+ * - Full Kuzu database capabilities
1029
+ *
1030
+ * **Use Cases:**
1031
+ * - Separate environments (dev/staging/prod)
1032
+ * - Department-specific data isolation
1033
+ * - Multi-tenant applications
1034
+ * - Testing and experimentation
1035
+ *
1036
+ * **Schema Inheritance:**
1037
+ * - Subgraphs can use parent's schema or custom extensions
1038
+ * - Extensions are additive only
1039
+ * - Base schema always included
1040
+ *
1041
+ * **Limits:**
1042
+ * - Standard: Not supported (0 subgraphs)
1043
+ * - Enterprise: Configurable limit (default: 10 subgraphs)
1044
+ * - Premium: Unlimited subgraphs
1045
+ * - Limits are defined in deployment configuration
1046
+ *
1047
+ * **Response includes:**
1048
+ * - `graph_id`: Full subgraph identifier
1049
+ * - `parent_graph_id`: Parent graph ID
1050
+ * - `subgraph_name`: Short name within parent
1051
+ * - `status`: Creation status
1052
+ */
1053
+ export declare const createSubgraph: <ThrowOnError extends boolean = false>(options: Options<CreateSubgraphData, ThrowOnError>) => import("./client").RequestResult<CreateSubgraphResponses, CreateSubgraphErrors, ThrowOnError, "fields">;
1054
+ /**
1055
+ * Delete Subgraph
1056
+ * Delete a subgraph database.
1057
+ *
1058
+ * **Requirements:**
1059
+ * - Must be a valid subgraph (not parent graph)
1060
+ * - User must have admin access to parent graph
1061
+ * - Optional backup before deletion
1062
+ *
1063
+ * **Deletion Options:**
1064
+ * - `force`: Delete even if contains data
1065
+ * - `backup_first`: Create backup before deletion
1066
+ *
1067
+ * **Warning:**
1068
+ * Deletion is permanent unless backup is created.
1069
+ * All data in the subgraph will be lost.
1070
+ *
1071
+ * **Backup Location:**
1072
+ * If backup requested, stored in S3 at:
1073
+ * `s3://robosystems-backups/{instance_id}/{database_name}_{timestamp}.backup`
1074
+ */
1075
+ export declare const deleteSubgraph: <ThrowOnError extends boolean = false>(options: Options<DeleteSubgraphData, ThrowOnError>) => import("./client").RequestResult<DeleteSubgraphResponses, DeleteSubgraphErrors, ThrowOnError, "fields">;
1076
+ /**
1077
+ * Get Subgraph Quota
1078
+ * Get subgraph quota and usage information for a parent graph.
1079
+ *
1080
+ * **Shows:**
1081
+ * - Current subgraph count
1082
+ * - Maximum allowed subgraphs per tier
1083
+ * - Remaining capacity
1084
+ * - Total size usage across all subgraphs
1085
+ *
1086
+ * **Tier Limits:**
1087
+ * - Standard: 0 subgraphs (not supported)
1088
+ * - Enterprise: Configurable limit (default: 10 subgraphs)
1089
+ * - Premium: Unlimited subgraphs
1090
+ * - Limits are defined in deployment configuration
1091
+ *
1092
+ * **Size Tracking:**
1093
+ * Provides aggregate size metrics when available.
1094
+ * Individual subgraph sizes shown in list endpoint.
1095
+ */
1096
+ export declare const getSubgraphQuota: <ThrowOnError extends boolean = false>(options: Options<GetSubgraphQuotaData, ThrowOnError>) => import("./client").RequestResult<GetSubgraphQuotaResponses, GetSubgraphQuotaErrors, ThrowOnError, "fields">;
1097
+ /**
1098
+ * Get Subgraph Details
1099
+ * Get detailed information about a specific subgraph.
1100
+ *
1101
+ * **Requirements:**
1102
+ * - User must have read access to parent graph
1103
+ *
1104
+ * **Response includes:**
1105
+ * - Full subgraph metadata
1106
+ * - Database statistics (nodes, edges)
1107
+ * - Size information
1108
+ * - Schema configuration
1109
+ * - Creation/modification timestamps
1110
+ * - Last access time (when available)
1111
+ *
1112
+ * **Statistics:**
1113
+ * Real-time statistics queried from Kuzu:
1114
+ * - Node count
1115
+ * - Edge count
1116
+ * - Database size on disk
1117
+ * - Schema information
1118
+ */
1119
+ export declare const getSubgraphInfo: <ThrowOnError extends boolean = false>(options: Options<GetSubgraphInfoData, ThrowOnError>) => import("./client").RequestResult<GetSubgraphInfoResponses, GetSubgraphInfoErrors, ThrowOnError, "fields">;
994
1120
  /**
995
1121
  * Create New Graph Database
996
1122
  * Create a new graph database with specified schema and optionally an initial entity.
package/sdk.gen.js CHANGED
@@ -2,7 +2,7 @@
2
2
  // This file is auto-generated by @hey-api/openapi-ts
3
3
  Object.defineProperty(exports, "__esModule", { value: true });
4
4
  exports.listBackups = exports.createBackup = exports.callMcpTool = exports.listMcpTools = exports.queryFinancialAgent = exports.oauthCallback = exports.initOAuth = exports.exchangeLinkToken = exports.createLinkToken = exports.syncConnection = exports.getConnection = exports.deleteConnection = exports.createConnection = exports.listConnections = exports.getConnectionOptions = exports.getRepositoryCredits = exports.getSharedRepositoryCredits = exports.cancelSharedRepositorySubscription = exports.upgradeSharedRepositorySubscription = exports.subscribeToSharedRepository = exports.getUserSharedSubscriptions = exports.getDetailedUserAnalytics = exports.getUserUsageOverview = exports.getAllSharedRepositoryLimits = exports.getSharedRepositoryLimits = exports.getUserUsage = exports.getUserLimits = exports.updateUserApiKey = exports.revokeUserApiKey = exports.createUserApiKey = exports.listUserApiKeys = exports.updateUserPassword = exports.getAllCreditSummaries = exports.selectUserGraph = exports.getUserGraphs = exports.updateUser = exports.getCurrentUser = exports.getServiceStatus = exports.checkPasswordStrength = exports.getPasswordPolicy = exports.getCaptchaConfig = exports.completeSsoAuth = exports.ssoTokenExchange = exports.ssoLogin = exports.generateSsoToken = exports.refreshSession = exports.getCurrentAuthUser = exports.logoutUser = exports.loginUser = exports.registerUser = void 0;
5
- exports.cancelOperation = exports.getOperationStatus = exports.streamOperationEvents = exports.getServiceOfferings = exports.getAvailableExtensions = exports.createGraph = exports.getDatabaseInfo = exports.getDatabaseHealth = exports.checkStorageLimits = exports.getStorageUsage = exports.checkCreditBalance = exports.listCreditTransactions = exports.getCreditSummary = exports.getCreditBillingInfoV1GraphIdBillingCreditsGet = exports.getAvailableSubscriptionPlansV1GraphIdBillingAvailablePlansGet = exports.getGraphSubscriptionV1GraphIdBillingSubscriptionGet = exports.upgradeGraphSubscriptionV1GraphIdBillingSubscriptionUpgradePost = exports.getGraphPricingInfoV1GraphIdBillingPricingGet = exports.getGraphUsageDetails = exports.getGraphBillingHistory = exports.getGraphMonthlyBill = exports.getCurrentGraphBill = exports.listSchemaExtensions = exports.exportGraphSchema = exports.validateSchema = exports.getGraphSchemaInfo = exports.executeCypherQuery = exports.getGraphUsageStats = exports.getGraphMetrics = exports.getBackupDownloadUrl = exports.kuzuBackupHealth = exports.getBackupStats = exports.restoreBackup = exports.exportBackup = void 0;
5
+ exports.cancelOperation = exports.getOperationStatus = exports.streamOperationEvents = exports.getServiceOfferings = exports.getAvailableExtensions = exports.createGraph = exports.getSubgraphInfo = exports.getSubgraphQuota = exports.deleteSubgraph = exports.createSubgraph = exports.listSubgraphs = exports.getDatabaseInfo = exports.getDatabaseHealth = exports.checkStorageLimits = exports.getStorageUsage = exports.checkCreditBalance = exports.listCreditTransactions = exports.getCreditSummary = exports.getCreditBillingInfoV1GraphIdBillingCreditsGet = exports.getAvailableSubscriptionPlansV1GraphIdBillingAvailablePlansGet = exports.getGraphSubscriptionV1GraphIdBillingSubscriptionGet = exports.upgradeGraphSubscriptionV1GraphIdBillingSubscriptionUpgradePost = exports.getGraphPricingInfoV1GraphIdBillingPricingGet = exports.getGraphUsageDetails = exports.getGraphBillingHistory = exports.getGraphMonthlyBill = exports.getCurrentGraphBill = exports.listSchemaExtensions = exports.exportGraphSchema = exports.validateSchema = exports.getGraphSchemaInfo = exports.executeCypherQuery = exports.getGraphUsageStats = exports.getGraphMetrics = exports.getBackupDownloadUrl = exports.kuzuBackupHealth = exports.getBackupStats = exports.restoreBackup = exports.exportBackup = void 0;
6
6
  const client_gen_1 = require("./client.gen");
7
7
  /**
8
8
  * Register New User
@@ -1096,7 +1096,7 @@ exports.oauthCallback = oauthCallback;
1096
1096
  *
1097
1097
  * **Credit Consumption:**
1098
1098
  * - AI operations consume credits based on actual token usage
1099
- * - Claude 4 Opus: ~15 credits per 1K input tokens, ~75 credits per 1K output tokens
1099
+ * - Claude 4/4.1 Opus: ~15 credits per 1K input tokens, ~75 credits per 1K output tokens
1100
1100
  * - Claude 4 Sonnet: ~3 credits per 1K input tokens, ~15 credits per 1K output tokens
1101
1101
  * - Credits are consumed after operation completes based on actual usage
1102
1102
  *
@@ -2208,6 +2208,220 @@ const getDatabaseInfo = (options) => {
2208
2208
  });
2209
2209
  };
2210
2210
  exports.getDatabaseInfo = getDatabaseInfo;
2211
+ /**
2212
+ * List Subgraphs
2213
+ * List all subgraphs for a parent graph.
2214
+ *
2215
+ * **Requirements:**
2216
+ * - User must have at least read access to parent graph
2217
+ *
2218
+ * **Response includes:**
2219
+ * - List of all subgraphs with metadata
2220
+ * - Current usage vs limits
2221
+ * - Size and statistics per subgraph
2222
+ * - Creation timestamps
2223
+ *
2224
+ * **Filtering:**
2225
+ * Currently returns all subgraphs. Future versions will support:
2226
+ * - Filtering by status
2227
+ * - Filtering by creation date
2228
+ * - Pagination for large lists
2229
+ */
2230
+ const listSubgraphs = (options) => {
2231
+ return (options.client ?? client_gen_1.client).get({
2232
+ security: [
2233
+ {
2234
+ name: 'X-API-Key',
2235
+ type: 'apiKey'
2236
+ },
2237
+ {
2238
+ scheme: 'bearer',
2239
+ type: 'http'
2240
+ }
2241
+ ],
2242
+ url: '/v1/{graph_id}/subgraphs',
2243
+ ...options
2244
+ });
2245
+ };
2246
+ exports.listSubgraphs = listSubgraphs;
2247
+ /**
2248
+ * Create New Subgraph
2249
+ * Create a new subgraph database under an Enterprise or Premium parent graph.
2250
+ *
2251
+ * **Requirements:**
2252
+ * - Parent graph must be Enterprise or Premium tier
2253
+ * - User must have admin access to parent graph
2254
+ * - Subgraph name must be unique within parent
2255
+ * - Subgraph name must be alphanumeric (1-20 chars)
2256
+ *
2257
+ * **Subgraph Benefits:**
2258
+ * - Shares parent's infrastructure (no additional cost)
2259
+ * - Inherits parent's credit pool
2260
+ * - Isolated database on same instance
2261
+ * - Full Kuzu database capabilities
2262
+ *
2263
+ * **Use Cases:**
2264
+ * - Separate environments (dev/staging/prod)
2265
+ * - Department-specific data isolation
2266
+ * - Multi-tenant applications
2267
+ * - Testing and experimentation
2268
+ *
2269
+ * **Schema Inheritance:**
2270
+ * - Subgraphs can use parent's schema or custom extensions
2271
+ * - Extensions are additive only
2272
+ * - Base schema always included
2273
+ *
2274
+ * **Limits:**
2275
+ * - Standard: Not supported (0 subgraphs)
2276
+ * - Enterprise: Configurable limit (default: 10 subgraphs)
2277
+ * - Premium: Unlimited subgraphs
2278
+ * - Limits are defined in deployment configuration
2279
+ *
2280
+ * **Response includes:**
2281
+ * - `graph_id`: Full subgraph identifier
2282
+ * - `parent_graph_id`: Parent graph ID
2283
+ * - `subgraph_name`: Short name within parent
2284
+ * - `status`: Creation status
2285
+ */
2286
+ const createSubgraph = (options) => {
2287
+ return (options.client ?? client_gen_1.client).post({
2288
+ security: [
2289
+ {
2290
+ name: 'X-API-Key',
2291
+ type: 'apiKey'
2292
+ },
2293
+ {
2294
+ scheme: 'bearer',
2295
+ type: 'http'
2296
+ }
2297
+ ],
2298
+ url: '/v1/{graph_id}/subgraphs',
2299
+ ...options,
2300
+ headers: {
2301
+ 'Content-Type': 'application/json',
2302
+ ...options.headers
2303
+ }
2304
+ });
2305
+ };
2306
+ exports.createSubgraph = createSubgraph;
2307
+ /**
2308
+ * Delete Subgraph
2309
+ * Delete a subgraph database.
2310
+ *
2311
+ * **Requirements:**
2312
+ * - Must be a valid subgraph (not parent graph)
2313
+ * - User must have admin access to parent graph
2314
+ * - Optional backup before deletion
2315
+ *
2316
+ * **Deletion Options:**
2317
+ * - `force`: Delete even if contains data
2318
+ * - `backup_first`: Create backup before deletion
2319
+ *
2320
+ * **Warning:**
2321
+ * Deletion is permanent unless backup is created.
2322
+ * All data in the subgraph will be lost.
2323
+ *
2324
+ * **Backup Location:**
2325
+ * If backup requested, stored in S3 at:
2326
+ * `s3://robosystems-backups/{instance_id}/{database_name}_{timestamp}.backup`
2327
+ */
2328
+ const deleteSubgraph = (options) => {
2329
+ return (options.client ?? client_gen_1.client).delete({
2330
+ security: [
2331
+ {
2332
+ name: 'X-API-Key',
2333
+ type: 'apiKey'
2334
+ },
2335
+ {
2336
+ scheme: 'bearer',
2337
+ type: 'http'
2338
+ }
2339
+ ],
2340
+ url: '/v1/{graph_id}/subgraphs/{subgraph_name}',
2341
+ ...options,
2342
+ headers: {
2343
+ 'Content-Type': 'application/json',
2344
+ ...options.headers
2345
+ }
2346
+ });
2347
+ };
2348
+ exports.deleteSubgraph = deleteSubgraph;
2349
+ /**
2350
+ * Get Subgraph Quota
2351
+ * Get subgraph quota and usage information for a parent graph.
2352
+ *
2353
+ * **Shows:**
2354
+ * - Current subgraph count
2355
+ * - Maximum allowed subgraphs per tier
2356
+ * - Remaining capacity
2357
+ * - Total size usage across all subgraphs
2358
+ *
2359
+ * **Tier Limits:**
2360
+ * - Standard: 0 subgraphs (not supported)
2361
+ * - Enterprise: Configurable limit (default: 10 subgraphs)
2362
+ * - Premium: Unlimited subgraphs
2363
+ * - Limits are defined in deployment configuration
2364
+ *
2365
+ * **Size Tracking:**
2366
+ * Provides aggregate size metrics when available.
2367
+ * Individual subgraph sizes shown in list endpoint.
2368
+ */
2369
+ const getSubgraphQuota = (options) => {
2370
+ return (options.client ?? client_gen_1.client).get({
2371
+ security: [
2372
+ {
2373
+ name: 'X-API-Key',
2374
+ type: 'apiKey'
2375
+ },
2376
+ {
2377
+ scheme: 'bearer',
2378
+ type: 'http'
2379
+ }
2380
+ ],
2381
+ url: '/v1/{graph_id}/subgraphs/quota',
2382
+ ...options
2383
+ });
2384
+ };
2385
+ exports.getSubgraphQuota = getSubgraphQuota;
2386
+ /**
2387
+ * Get Subgraph Details
2388
+ * Get detailed information about a specific subgraph.
2389
+ *
2390
+ * **Requirements:**
2391
+ * - User must have read access to parent graph
2392
+ *
2393
+ * **Response includes:**
2394
+ * - Full subgraph metadata
2395
+ * - Database statistics (nodes, edges)
2396
+ * - Size information
2397
+ * - Schema configuration
2398
+ * - Creation/modification timestamps
2399
+ * - Last access time (when available)
2400
+ *
2401
+ * **Statistics:**
2402
+ * Real-time statistics queried from Kuzu:
2403
+ * - Node count
2404
+ * - Edge count
2405
+ * - Database size on disk
2406
+ * - Schema information
2407
+ */
2408
+ const getSubgraphInfo = (options) => {
2409
+ return (options.client ?? client_gen_1.client).get({
2410
+ security: [
2411
+ {
2412
+ name: 'X-API-Key',
2413
+ type: 'apiKey'
2414
+ },
2415
+ {
2416
+ scheme: 'bearer',
2417
+ type: 'http'
2418
+ }
2419
+ ],
2420
+ url: '/v1/{graph_id}/subgraphs/{subgraph_name}/info',
2421
+ ...options
2422
+ });
2423
+ };
2424
+ exports.getSubgraphInfo = getSubgraphInfo;
2211
2425
  /**
2212
2426
  * Create New Graph Database
2213
2427
  * Create a new graph database with specified schema and optionally an initial entity.