@robosystems/client 0.1.19 → 0.1.21
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/LICENSE +1 -1
- package/README.md +10 -423
- package/bin/create-feature +58 -55
- package/client/utils.gen.js +14 -1
- package/client/utils.gen.ts +23 -2
- package/core/bodySerializer.gen.js +3 -0
- package/core/bodySerializer.gen.ts +2 -0
- package/package.json +3 -3
- package/sdk/client/utils.gen.js +14 -1
- package/sdk/client/utils.gen.ts +23 -2
- package/sdk/core/bodySerializer.gen.js +3 -0
- package/sdk/core/bodySerializer.gen.ts +2 -0
- package/sdk/sdk.gen.d.ts +192 -129
- package/sdk/sdk.gen.js +413 -216
- package/sdk/sdk.gen.ts +412 -215
- package/sdk/types.gen.d.ts +952 -252
- package/sdk/types.gen.ts +1016 -253
- package/sdk-extensions/README.md +2 -3
- package/sdk.gen.d.ts +192 -129
- package/sdk.gen.js +413 -216
- package/sdk.gen.ts +412 -215
- package/types.gen.d.ts +952 -252
- package/types.gen.ts +1016 -253
package/sdk.gen.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
// This file is auto-generated by @hey-api/openapi-ts
|
|
3
3
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
-
exports.
|
|
5
|
-
exports.cancelOperation = exports.getOperationStatus = exports.streamOperationEvents = exports.getServiceOfferings = exports.getAvailableExtensions = exports.createGraph = exports.copyDataToGraph = exports.getSubgraphQuota = exports.getSubgraphInfo = exports.deleteSubgraph = exports.createSubgraph = exports.listSubgraphs = exports.getGraphLimits = exports.getDatabaseInfo = exports.getDatabaseHealth = exports.checkStorageLimits = exports.getStorageUsage = exports.checkCreditBalance = exports.listCreditTransactions = exports.getCreditSummary = exports.getGraphMonthlyBill = exports.getGraphBillingHistory = exports.getGraphUsageDetails = exports.getCurrentGraphBill = exports.listSchemaExtensions = exports.exportGraphSchema = exports.validateSchema = exports.getGraphSchemaInfo = exports.executeCypherQuery = exports.getGraphUsageStats = exports.getGraphMetrics = exports.getBackupStats = exports.restoreBackup = exports.getBackupDownloadUrl = exports.exportBackup = void 0;
|
|
4
|
+
exports.getConnection = exports.deleteConnection = exports.createConnection = exports.listConnections = exports.oauthCallback = exports.initOAuth = exports.exchangeLinkToken = exports.createLinkToken = exports.syncConnection = exports.getConnectionOptions = exports.getRepositoryCredits = exports.getSharedRepositoryCredits = exports.cancelSharedRepositorySubscription = exports.upgradeSharedRepositorySubscription = exports.subscribeToSharedRepository = exports.getUserSharedSubscriptions = exports.getDetailedUserAnalytics = exports.getUserUsageOverview = exports.getSharedRepositoryLimits = exports.getAllSharedRepositoryLimits = 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.getCaptchaConfig = exports.completeSsoAuth = exports.ssoTokenExchange = exports.ssoLogin = exports.generateSsoToken = exports.resetPassword = exports.validateResetToken = exports.forgotPassword = exports.checkPasswordStrength = exports.getPasswordPolicy = exports.verifyEmail = exports.resendVerificationEmail = exports.refreshAuthSession = exports.getCurrentAuthUser = exports.logoutUser = exports.loginUser = exports.registerUser = void 0;
|
|
5
|
+
exports.cancelOperation = exports.getOperationStatus = exports.streamOperationEvents = exports.getServiceOfferings = exports.getAvailableExtensions = exports.createGraph = exports.copyDataToGraph = exports.getSubgraphQuota = exports.getSubgraphInfo = exports.deleteSubgraph = exports.createSubgraph = exports.listSubgraphs = exports.getGraphLimits = exports.getDatabaseInfo = exports.getDatabaseHealth = exports.checkStorageLimits = exports.getStorageUsage = exports.checkCreditBalance = exports.listCreditTransactions = exports.getCreditSummary = exports.getGraphMonthlyBill = exports.getGraphBillingHistory = exports.getGraphUsageDetails = exports.getCurrentGraphBill = exports.listSchemaExtensions = exports.exportGraphSchema = exports.validateSchema = exports.getGraphSchemaInfo = exports.executeCypherQuery = exports.getGraphUsageStats = exports.getGraphMetrics = exports.getBackupStats = exports.restoreBackup = exports.getBackupDownloadUrl = exports.exportBackup = exports.createBackup = exports.listBackups = exports.callMcpTool = exports.listMcpTools = exports.recommendAgent = exports.getAgentMetadata = exports.listAgents = exports.batchProcessQueries = exports.executeSpecificAgent = exports.autoSelectAgent = void 0;
|
|
6
6
|
const client_gen_1 = require("./client.gen");
|
|
7
7
|
/**
|
|
8
8
|
* Register New User
|
|
@@ -47,7 +47,7 @@ const logoutUser = (options) => {
|
|
|
47
47
|
exports.logoutUser = logoutUser;
|
|
48
48
|
/**
|
|
49
49
|
* Get Current User
|
|
50
|
-
* Get
|
|
50
|
+
* Get the currently authenticated user.
|
|
51
51
|
*/
|
|
52
52
|
const getCurrentAuthUser = (options) => {
|
|
53
53
|
return (options?.client ?? client_gen_1.client).get({
|
|
@@ -58,15 +58,108 @@ const getCurrentAuthUser = (options) => {
|
|
|
58
58
|
exports.getCurrentAuthUser = getCurrentAuthUser;
|
|
59
59
|
/**
|
|
60
60
|
* Refresh Session
|
|
61
|
-
* Refresh
|
|
61
|
+
* Refresh authentication session with a new JWT token.
|
|
62
62
|
*/
|
|
63
|
-
const
|
|
63
|
+
const refreshAuthSession = (options) => {
|
|
64
64
|
return (options?.client ?? client_gen_1.client).post({
|
|
65
65
|
url: '/v1/auth/refresh',
|
|
66
66
|
...options
|
|
67
67
|
});
|
|
68
68
|
};
|
|
69
|
-
exports.
|
|
69
|
+
exports.refreshAuthSession = refreshAuthSession;
|
|
70
|
+
/**
|
|
71
|
+
* Resend Email Verification
|
|
72
|
+
* Resend verification email to the authenticated user. Rate limited to 3 per hour.
|
|
73
|
+
*/
|
|
74
|
+
const resendVerificationEmail = (options) => {
|
|
75
|
+
return (options?.client ?? client_gen_1.client).post({
|
|
76
|
+
url: '/v1/auth/email/resend',
|
|
77
|
+
...options
|
|
78
|
+
});
|
|
79
|
+
};
|
|
80
|
+
exports.resendVerificationEmail = resendVerificationEmail;
|
|
81
|
+
/**
|
|
82
|
+
* Verify Email
|
|
83
|
+
* Verify email address with token from email link. Returns JWT for auto-login.
|
|
84
|
+
*/
|
|
85
|
+
const verifyEmail = (options) => {
|
|
86
|
+
return (options.client ?? client_gen_1.client).post({
|
|
87
|
+
url: '/v1/auth/email/verify',
|
|
88
|
+
...options,
|
|
89
|
+
headers: {
|
|
90
|
+
'Content-Type': 'application/json',
|
|
91
|
+
...options.headers
|
|
92
|
+
}
|
|
93
|
+
});
|
|
94
|
+
};
|
|
95
|
+
exports.verifyEmail = verifyEmail;
|
|
96
|
+
/**
|
|
97
|
+
* Get Password Policy
|
|
98
|
+
* Get current password policy requirements for frontend validation
|
|
99
|
+
*/
|
|
100
|
+
const getPasswordPolicy = (options) => {
|
|
101
|
+
return (options?.client ?? client_gen_1.client).get({
|
|
102
|
+
url: '/v1/auth/password/policy',
|
|
103
|
+
...options
|
|
104
|
+
});
|
|
105
|
+
};
|
|
106
|
+
exports.getPasswordPolicy = getPasswordPolicy;
|
|
107
|
+
/**
|
|
108
|
+
* Check Password Strength
|
|
109
|
+
* Check password strength and get validation feedback
|
|
110
|
+
*/
|
|
111
|
+
const checkPasswordStrength = (options) => {
|
|
112
|
+
return (options.client ?? client_gen_1.client).post({
|
|
113
|
+
url: '/v1/auth/password/check',
|
|
114
|
+
...options,
|
|
115
|
+
headers: {
|
|
116
|
+
'Content-Type': 'application/json',
|
|
117
|
+
...options.headers
|
|
118
|
+
}
|
|
119
|
+
});
|
|
120
|
+
};
|
|
121
|
+
exports.checkPasswordStrength = checkPasswordStrength;
|
|
122
|
+
/**
|
|
123
|
+
* Forgot Password
|
|
124
|
+
* Request password reset email. Always returns success to prevent email enumeration.
|
|
125
|
+
*/
|
|
126
|
+
const forgotPassword = (options) => {
|
|
127
|
+
return (options.client ?? client_gen_1.client).post({
|
|
128
|
+
url: '/v1/auth/password/forgot',
|
|
129
|
+
...options,
|
|
130
|
+
headers: {
|
|
131
|
+
'Content-Type': 'application/json',
|
|
132
|
+
...options.headers
|
|
133
|
+
}
|
|
134
|
+
});
|
|
135
|
+
};
|
|
136
|
+
exports.forgotPassword = forgotPassword;
|
|
137
|
+
/**
|
|
138
|
+
* Validate Reset Token
|
|
139
|
+
* Check if a password reset token is valid without consuming it.
|
|
140
|
+
*/
|
|
141
|
+
const validateResetToken = (options) => {
|
|
142
|
+
return (options.client ?? client_gen_1.client).get({
|
|
143
|
+
url: '/v1/auth/password/reset/validate',
|
|
144
|
+
...options
|
|
145
|
+
});
|
|
146
|
+
};
|
|
147
|
+
exports.validateResetToken = validateResetToken;
|
|
148
|
+
/**
|
|
149
|
+
* Reset Password
|
|
150
|
+
* Reset password with token from email. Returns JWT for auto-login.
|
|
151
|
+
*/
|
|
152
|
+
const resetPassword = (options) => {
|
|
153
|
+
return (options.client ?? client_gen_1.client).post({
|
|
154
|
+
url: '/v1/auth/password/reset',
|
|
155
|
+
...options,
|
|
156
|
+
headers: {
|
|
157
|
+
'Content-Type': 'application/json',
|
|
158
|
+
...options.headers
|
|
159
|
+
}
|
|
160
|
+
});
|
|
161
|
+
};
|
|
162
|
+
exports.resetPassword = resetPassword;
|
|
70
163
|
/**
|
|
71
164
|
* Generate SSO Token
|
|
72
165
|
* Generate a temporary SSO token for cross-app authentication.
|
|
@@ -123,32 +216,6 @@ const completeSsoAuth = (options) => {
|
|
|
123
216
|
});
|
|
124
217
|
};
|
|
125
218
|
exports.completeSsoAuth = completeSsoAuth;
|
|
126
|
-
/**
|
|
127
|
-
* Get Password Policy
|
|
128
|
-
* Get current password policy requirements for frontend validation
|
|
129
|
-
*/
|
|
130
|
-
const getPasswordPolicy = (options) => {
|
|
131
|
-
return (options?.client ?? client_gen_1.client).get({
|
|
132
|
-
url: '/v1/auth/password/policy',
|
|
133
|
-
...options
|
|
134
|
-
});
|
|
135
|
-
};
|
|
136
|
-
exports.getPasswordPolicy = getPasswordPolicy;
|
|
137
|
-
/**
|
|
138
|
-
* Check Password Strength
|
|
139
|
-
* Check password strength and get validation feedback
|
|
140
|
-
*/
|
|
141
|
-
const checkPasswordStrength = (options) => {
|
|
142
|
-
return (options.client ?? client_gen_1.client).post({
|
|
143
|
-
url: '/v1/auth/password/check',
|
|
144
|
-
...options,
|
|
145
|
-
headers: {
|
|
146
|
-
'Content-Type': 'application/json',
|
|
147
|
-
...options.headers
|
|
148
|
-
}
|
|
149
|
-
});
|
|
150
|
-
};
|
|
151
|
-
exports.checkPasswordStrength = checkPasswordStrength;
|
|
152
219
|
/**
|
|
153
220
|
* Get CAPTCHA Configuration
|
|
154
221
|
* Get CAPTCHA configuration including site key and whether CAPTCHA is required.
|
|
@@ -671,147 +738,6 @@ const getRepositoryCredits = (options) => {
|
|
|
671
738
|
});
|
|
672
739
|
};
|
|
673
740
|
exports.getRepositoryCredits = getRepositoryCredits;
|
|
674
|
-
/**
|
|
675
|
-
* List Connections
|
|
676
|
-
* List all data connections in the graph.
|
|
677
|
-
*
|
|
678
|
-
* Returns active and inactive connections with their current status.
|
|
679
|
-
* Connections can be filtered by:
|
|
680
|
-
* - **Entity**: Show connections for a specific entity
|
|
681
|
-
* - **Provider**: Filter by connection type (sec, quickbooks, plaid)
|
|
682
|
-
*
|
|
683
|
-
* Each connection shows:
|
|
684
|
-
* - Current sync status and health
|
|
685
|
-
* - Last successful sync timestamp
|
|
686
|
-
* - Configuration metadata
|
|
687
|
-
* - Error messages if any
|
|
688
|
-
*
|
|
689
|
-
* No credits are consumed for listing connections.
|
|
690
|
-
*/
|
|
691
|
-
const listConnections = (options) => {
|
|
692
|
-
return (options.client ?? client_gen_1.client).get({
|
|
693
|
-
security: [
|
|
694
|
-
{
|
|
695
|
-
name: 'X-API-Key',
|
|
696
|
-
type: 'apiKey'
|
|
697
|
-
},
|
|
698
|
-
{
|
|
699
|
-
scheme: 'bearer',
|
|
700
|
-
type: 'http'
|
|
701
|
-
}
|
|
702
|
-
],
|
|
703
|
-
url: '/v1/{graph_id}/connections',
|
|
704
|
-
...options
|
|
705
|
-
});
|
|
706
|
-
};
|
|
707
|
-
exports.listConnections = listConnections;
|
|
708
|
-
/**
|
|
709
|
-
* Create Connection
|
|
710
|
-
* Create a new data connection for external system integration.
|
|
711
|
-
*
|
|
712
|
-
* This endpoint initiates connections to external data sources:
|
|
713
|
-
*
|
|
714
|
-
* **SEC Connections**:
|
|
715
|
-
* - Provide entity CIK for automatic filing retrieval
|
|
716
|
-
* - No authentication needed
|
|
717
|
-
* - Begins immediate data sync
|
|
718
|
-
*
|
|
719
|
-
* **QuickBooks Connections**:
|
|
720
|
-
* - Returns OAuth URL for authorization
|
|
721
|
-
* - Requires admin permissions in QuickBooks
|
|
722
|
-
* - Complete with OAuth callback
|
|
723
|
-
*
|
|
724
|
-
* **Plaid Connections**:
|
|
725
|
-
* - Returns Plaid Link token
|
|
726
|
-
* - User completes bank authentication
|
|
727
|
-
* - Exchange public token for access
|
|
728
|
-
*
|
|
729
|
-
* Note:
|
|
730
|
-
* This operation is FREE - no credit consumption required.
|
|
731
|
-
*/
|
|
732
|
-
const createConnection = (options) => {
|
|
733
|
-
return (options.client ?? client_gen_1.client).post({
|
|
734
|
-
security: [
|
|
735
|
-
{
|
|
736
|
-
name: 'X-API-Key',
|
|
737
|
-
type: 'apiKey'
|
|
738
|
-
},
|
|
739
|
-
{
|
|
740
|
-
scheme: 'bearer',
|
|
741
|
-
type: 'http'
|
|
742
|
-
}
|
|
743
|
-
],
|
|
744
|
-
url: '/v1/{graph_id}/connections',
|
|
745
|
-
...options,
|
|
746
|
-
headers: {
|
|
747
|
-
'Content-Type': 'application/json',
|
|
748
|
-
...options.headers
|
|
749
|
-
}
|
|
750
|
-
});
|
|
751
|
-
};
|
|
752
|
-
exports.createConnection = createConnection;
|
|
753
|
-
/**
|
|
754
|
-
* Delete Connection
|
|
755
|
-
* Delete a data connection and clean up related resources.
|
|
756
|
-
*
|
|
757
|
-
* This operation:
|
|
758
|
-
* - Removes the connection configuration
|
|
759
|
-
* - Preserves any imported data in the graph
|
|
760
|
-
* - Performs provider-specific cleanup
|
|
761
|
-
* - Revokes stored credentials
|
|
762
|
-
*
|
|
763
|
-
* Note:
|
|
764
|
-
* This operation is FREE - no credit consumption required.
|
|
765
|
-
*
|
|
766
|
-
* Only users with admin role can delete connections.
|
|
767
|
-
*/
|
|
768
|
-
const deleteConnection = (options) => {
|
|
769
|
-
return (options.client ?? client_gen_1.client).delete({
|
|
770
|
-
security: [
|
|
771
|
-
{
|
|
772
|
-
name: 'X-API-Key',
|
|
773
|
-
type: 'apiKey'
|
|
774
|
-
},
|
|
775
|
-
{
|
|
776
|
-
scheme: 'bearer',
|
|
777
|
-
type: 'http'
|
|
778
|
-
}
|
|
779
|
-
],
|
|
780
|
-
url: '/v1/{graph_id}/connections/{connection_id}',
|
|
781
|
-
...options
|
|
782
|
-
});
|
|
783
|
-
};
|
|
784
|
-
exports.deleteConnection = deleteConnection;
|
|
785
|
-
/**
|
|
786
|
-
* Get Connection
|
|
787
|
-
* Get detailed information about a specific connection.
|
|
788
|
-
*
|
|
789
|
-
* Returns comprehensive connection details including:
|
|
790
|
-
* - Current status and health indicators
|
|
791
|
-
* - Authentication state
|
|
792
|
-
* - Sync history and statistics
|
|
793
|
-
* - Error details if any
|
|
794
|
-
* - Provider-specific metadata
|
|
795
|
-
*
|
|
796
|
-
* No credits are consumed for viewing connection details.
|
|
797
|
-
*/
|
|
798
|
-
const getConnection = (options) => {
|
|
799
|
-
return (options.client ?? client_gen_1.client).get({
|
|
800
|
-
security: [
|
|
801
|
-
{
|
|
802
|
-
name: 'X-API-Key',
|
|
803
|
-
type: 'apiKey'
|
|
804
|
-
},
|
|
805
|
-
{
|
|
806
|
-
scheme: 'bearer',
|
|
807
|
-
type: 'http'
|
|
808
|
-
}
|
|
809
|
-
],
|
|
810
|
-
url: '/v1/{graph_id}/connections/{connection_id}',
|
|
811
|
-
...options
|
|
812
|
-
});
|
|
813
|
-
};
|
|
814
|
-
exports.getConnection = getConnection;
|
|
815
741
|
/**
|
|
816
742
|
* List Connection Options
|
|
817
743
|
* Get metadata about all available data connection providers.
|
|
@@ -1024,7 +950,7 @@ exports.initOAuth = initOAuth;
|
|
|
1024
950
|
* - **QuickBooks**: Accounting data integration
|
|
1025
951
|
*
|
|
1026
952
|
* Security measures:
|
|
1027
|
-
* - State validation prevents
|
|
953
|
+
* - State validation prevents session hijacking
|
|
1028
954
|
* - User context is verified
|
|
1029
955
|
* - Tokens are encrypted before storage
|
|
1030
956
|
* - Full audit trail is maintained
|
|
@@ -1053,56 +979,159 @@ const oauthCallback = (options) => {
|
|
|
1053
979
|
};
|
|
1054
980
|
exports.oauthCallback = oauthCallback;
|
|
1055
981
|
/**
|
|
1056
|
-
*
|
|
1057
|
-
*
|
|
982
|
+
* List Connections
|
|
983
|
+
* List all data connections in the graph.
|
|
984
|
+
*
|
|
985
|
+
* Returns active and inactive connections with their current status.
|
|
986
|
+
* Connections can be filtered by:
|
|
987
|
+
* - **Entity**: Show connections for a specific entity
|
|
988
|
+
* - **Provider**: Filter by connection type (sec, quickbooks, plaid)
|
|
989
|
+
*
|
|
990
|
+
* Each connection shows:
|
|
991
|
+
* - Current sync status and health
|
|
992
|
+
* - Last successful sync timestamp
|
|
993
|
+
* - Configuration metadata
|
|
994
|
+
* - Error messages if any
|
|
995
|
+
*
|
|
996
|
+
* No credits are consumed for listing connections.
|
|
997
|
+
*/
|
|
998
|
+
const listConnections = (options) => {
|
|
999
|
+
return (options.client ?? client_gen_1.client).get({
|
|
1000
|
+
security: [
|
|
1001
|
+
{
|
|
1002
|
+
name: 'X-API-Key',
|
|
1003
|
+
type: 'apiKey'
|
|
1004
|
+
},
|
|
1005
|
+
{
|
|
1006
|
+
scheme: 'bearer',
|
|
1007
|
+
type: 'http'
|
|
1008
|
+
}
|
|
1009
|
+
],
|
|
1010
|
+
url: '/v1/{graph_id}/connections',
|
|
1011
|
+
...options
|
|
1012
|
+
});
|
|
1013
|
+
};
|
|
1014
|
+
exports.listConnections = listConnections;
|
|
1015
|
+
/**
|
|
1016
|
+
* Create Connection
|
|
1017
|
+
* Create a new data connection for external system integration.
|
|
1058
1018
|
*
|
|
1059
|
-
* This endpoint
|
|
1060
|
-
* - Analyze entity financial statements and SEC filings
|
|
1061
|
-
* - Review QuickBooks transactions and accounting data
|
|
1062
|
-
* - Perform multi-period trend analysis
|
|
1063
|
-
* - Generate insights from balance sheets and income statements
|
|
1064
|
-
* - Answer complex financial queries with contextual understanding
|
|
1019
|
+
* This endpoint initiates connections to external data sources:
|
|
1065
1020
|
*
|
|
1066
|
-
* **
|
|
1067
|
-
* -
|
|
1068
|
-
* -
|
|
1021
|
+
* **SEC Connections**:
|
|
1022
|
+
* - Provide entity CIK for automatic filing retrieval
|
|
1023
|
+
* - No authentication needed
|
|
1024
|
+
* - Begins immediate data sync
|
|
1069
1025
|
*
|
|
1070
|
-
* **
|
|
1071
|
-
*
|
|
1072
|
-
*
|
|
1073
|
-
*
|
|
1074
|
-
* eventSource.onmessage = (event) => {
|
|
1075
|
-
* const data = JSON.parse(event.data);
|
|
1076
|
-
* console.log('Analysis:', data.message);
|
|
1077
|
-
* };
|
|
1078
|
-
* ```
|
|
1026
|
+
* **QuickBooks Connections**:
|
|
1027
|
+
* - Returns OAuth URL for authorization
|
|
1028
|
+
* - Requires admin permissions in QuickBooks
|
|
1029
|
+
* - Complete with OAuth callback
|
|
1079
1030
|
*
|
|
1080
|
-
* **
|
|
1081
|
-
* -
|
|
1082
|
-
* -
|
|
1083
|
-
* -
|
|
1084
|
-
* - Graceful degradation with fallback to polling if SSE unavailable
|
|
1031
|
+
* **Plaid Connections**:
|
|
1032
|
+
* - Returns Plaid Link token
|
|
1033
|
+
* - User completes bank authentication
|
|
1034
|
+
* - Exchange public token for access
|
|
1085
1035
|
*
|
|
1086
|
-
*
|
|
1087
|
-
* -
|
|
1088
|
-
|
|
1089
|
-
|
|
1090
|
-
|
|
1036
|
+
* Note:
|
|
1037
|
+
* This operation is FREE - no credit consumption required.
|
|
1038
|
+
*/
|
|
1039
|
+
const createConnection = (options) => {
|
|
1040
|
+
return (options.client ?? client_gen_1.client).post({
|
|
1041
|
+
security: [
|
|
1042
|
+
{
|
|
1043
|
+
name: 'X-API-Key',
|
|
1044
|
+
type: 'apiKey'
|
|
1045
|
+
},
|
|
1046
|
+
{
|
|
1047
|
+
scheme: 'bearer',
|
|
1048
|
+
type: 'http'
|
|
1049
|
+
}
|
|
1050
|
+
],
|
|
1051
|
+
url: '/v1/{graph_id}/connections',
|
|
1052
|
+
...options,
|
|
1053
|
+
headers: {
|
|
1054
|
+
'Content-Type': 'application/json',
|
|
1055
|
+
...options.headers
|
|
1056
|
+
}
|
|
1057
|
+
});
|
|
1058
|
+
};
|
|
1059
|
+
exports.createConnection = createConnection;
|
|
1060
|
+
/**
|
|
1061
|
+
* Delete Connection
|
|
1062
|
+
* Delete a data connection and clean up related resources.
|
|
1091
1063
|
*
|
|
1092
|
-
*
|
|
1093
|
-
* -
|
|
1094
|
-
* -
|
|
1095
|
-
* -
|
|
1064
|
+
* This operation:
|
|
1065
|
+
* - Removes the connection configuration
|
|
1066
|
+
* - Preserves any imported data in the graph
|
|
1067
|
+
* - Performs provider-specific cleanup
|
|
1068
|
+
* - Revokes stored credentials
|
|
1096
1069
|
*
|
|
1097
|
-
*
|
|
1098
|
-
*
|
|
1099
|
-
*
|
|
1100
|
-
*
|
|
1101
|
-
|
|
1070
|
+
* Note:
|
|
1071
|
+
* This operation is FREE - no credit consumption required.
|
|
1072
|
+
*
|
|
1073
|
+
* Only users with admin role can delete connections.
|
|
1074
|
+
*/
|
|
1075
|
+
const deleteConnection = (options) => {
|
|
1076
|
+
return (options.client ?? client_gen_1.client).delete({
|
|
1077
|
+
security: [
|
|
1078
|
+
{
|
|
1079
|
+
name: 'X-API-Key',
|
|
1080
|
+
type: 'apiKey'
|
|
1081
|
+
},
|
|
1082
|
+
{
|
|
1083
|
+
scheme: 'bearer',
|
|
1084
|
+
type: 'http'
|
|
1085
|
+
}
|
|
1086
|
+
],
|
|
1087
|
+
url: '/v1/{graph_id}/connections/{connection_id}',
|
|
1088
|
+
...options
|
|
1089
|
+
});
|
|
1090
|
+
};
|
|
1091
|
+
exports.deleteConnection = deleteConnection;
|
|
1092
|
+
/**
|
|
1093
|
+
* Get Connection
|
|
1094
|
+
* Get detailed information about a specific connection.
|
|
1095
|
+
*
|
|
1096
|
+
* Returns comprehensive connection details including:
|
|
1097
|
+
* - Current status and health indicators
|
|
1098
|
+
* - Authentication state
|
|
1099
|
+
* - Sync history and statistics
|
|
1100
|
+
* - Error details if any
|
|
1101
|
+
* - Provider-specific metadata
|
|
1102
|
+
*
|
|
1103
|
+
* No credits are consumed for viewing connection details.
|
|
1104
|
+
*/
|
|
1105
|
+
const getConnection = (options) => {
|
|
1106
|
+
return (options.client ?? client_gen_1.client).get({
|
|
1107
|
+
security: [
|
|
1108
|
+
{
|
|
1109
|
+
name: 'X-API-Key',
|
|
1110
|
+
type: 'apiKey'
|
|
1111
|
+
},
|
|
1112
|
+
{
|
|
1113
|
+
scheme: 'bearer',
|
|
1114
|
+
type: 'http'
|
|
1115
|
+
}
|
|
1116
|
+
],
|
|
1117
|
+
url: '/v1/{graph_id}/connections/{connection_id}',
|
|
1118
|
+
...options
|
|
1119
|
+
});
|
|
1120
|
+
};
|
|
1121
|
+
exports.getConnection = getConnection;
|
|
1122
|
+
/**
|
|
1123
|
+
* Auto-select agent for query
|
|
1124
|
+
* Automatically select the best agent for your query.
|
|
1125
|
+
*
|
|
1126
|
+
* The orchestrator will:
|
|
1127
|
+
* 1. Enrich context with RAG if enabled
|
|
1128
|
+
* 2. Evaluate all available agents
|
|
1129
|
+
* 3. Select the best match based on confidence scores
|
|
1130
|
+
* 4. Execute the query with the selected agent
|
|
1102
1131
|
*
|
|
1103
|
-
*
|
|
1132
|
+
* Use this endpoint when you want the system to intelligently route your query.
|
|
1104
1133
|
*/
|
|
1105
|
-
const
|
|
1134
|
+
const autoSelectAgent = (options) => {
|
|
1106
1135
|
return (options.client ?? client_gen_1.client).post({
|
|
1107
1136
|
security: [
|
|
1108
1137
|
{
|
|
@@ -1122,7 +1151,175 @@ const queryFinancialAgent = (options) => {
|
|
|
1122
1151
|
}
|
|
1123
1152
|
});
|
|
1124
1153
|
};
|
|
1125
|
-
exports.
|
|
1154
|
+
exports.autoSelectAgent = autoSelectAgent;
|
|
1155
|
+
/**
|
|
1156
|
+
* Execute specific agent
|
|
1157
|
+
* Execute a specific agent type directly.
|
|
1158
|
+
*
|
|
1159
|
+
* Available agents:
|
|
1160
|
+
* - **financial**: Financial analysis, SEC filings, accounting data
|
|
1161
|
+
* - **research**: Deep research and comprehensive analysis
|
|
1162
|
+
* - **rag**: Fast retrieval without AI (no credits required)
|
|
1163
|
+
*
|
|
1164
|
+
* Use this endpoint when you know which agent you want to use.
|
|
1165
|
+
*/
|
|
1166
|
+
const executeSpecificAgent = (options) => {
|
|
1167
|
+
return (options.client ?? client_gen_1.client).post({
|
|
1168
|
+
security: [
|
|
1169
|
+
{
|
|
1170
|
+
name: 'X-API-Key',
|
|
1171
|
+
type: 'apiKey'
|
|
1172
|
+
},
|
|
1173
|
+
{
|
|
1174
|
+
scheme: 'bearer',
|
|
1175
|
+
type: 'http'
|
|
1176
|
+
}
|
|
1177
|
+
],
|
|
1178
|
+
url: '/v1/{graph_id}/agent/{agent_type}',
|
|
1179
|
+
...options,
|
|
1180
|
+
headers: {
|
|
1181
|
+
'Content-Type': 'application/json',
|
|
1182
|
+
...options.headers
|
|
1183
|
+
}
|
|
1184
|
+
});
|
|
1185
|
+
};
|
|
1186
|
+
exports.executeSpecificAgent = executeSpecificAgent;
|
|
1187
|
+
/**
|
|
1188
|
+
* Batch process multiple queries
|
|
1189
|
+
* Process multiple queries either sequentially or in parallel.
|
|
1190
|
+
*
|
|
1191
|
+
* **Features:**
|
|
1192
|
+
* - Process up to 10 queries in a single request
|
|
1193
|
+
* - Sequential or parallel execution modes
|
|
1194
|
+
* - Automatic error handling per query
|
|
1195
|
+
* - Credit checking before execution
|
|
1196
|
+
*
|
|
1197
|
+
* **Use Cases:**
|
|
1198
|
+
* - Bulk analysis of multiple entities
|
|
1199
|
+
* - Comparative analysis across queries
|
|
1200
|
+
* - Automated report generation
|
|
1201
|
+
*
|
|
1202
|
+
* Returns individual results for each query with execution metrics.
|
|
1203
|
+
*/
|
|
1204
|
+
const batchProcessQueries = (options) => {
|
|
1205
|
+
return (options.client ?? client_gen_1.client).post({
|
|
1206
|
+
security: [
|
|
1207
|
+
{
|
|
1208
|
+
name: 'X-API-Key',
|
|
1209
|
+
type: 'apiKey'
|
|
1210
|
+
},
|
|
1211
|
+
{
|
|
1212
|
+
scheme: 'bearer',
|
|
1213
|
+
type: 'http'
|
|
1214
|
+
}
|
|
1215
|
+
],
|
|
1216
|
+
url: '/v1/{graph_id}/agent/batch',
|
|
1217
|
+
...options,
|
|
1218
|
+
headers: {
|
|
1219
|
+
'Content-Type': 'application/json',
|
|
1220
|
+
...options.headers
|
|
1221
|
+
}
|
|
1222
|
+
});
|
|
1223
|
+
};
|
|
1224
|
+
exports.batchProcessQueries = batchProcessQueries;
|
|
1225
|
+
/**
|
|
1226
|
+
* List available agents
|
|
1227
|
+
* Get a comprehensive list of all available agents with their metadata.
|
|
1228
|
+
*
|
|
1229
|
+
* **Returns:**
|
|
1230
|
+
* - Agent types and names
|
|
1231
|
+
* - Capabilities and supported modes
|
|
1232
|
+
* - Version information
|
|
1233
|
+
* - Credit requirements
|
|
1234
|
+
*
|
|
1235
|
+
* Use the optional `capability` filter to find agents with specific capabilities.
|
|
1236
|
+
*/
|
|
1237
|
+
const listAgents = (options) => {
|
|
1238
|
+
return (options.client ?? client_gen_1.client).get({
|
|
1239
|
+
security: [
|
|
1240
|
+
{
|
|
1241
|
+
name: 'X-API-Key',
|
|
1242
|
+
type: 'apiKey'
|
|
1243
|
+
},
|
|
1244
|
+
{
|
|
1245
|
+
scheme: 'bearer',
|
|
1246
|
+
type: 'http'
|
|
1247
|
+
}
|
|
1248
|
+
],
|
|
1249
|
+
url: '/v1/{graph_id}/agent/list',
|
|
1250
|
+
...options
|
|
1251
|
+
});
|
|
1252
|
+
};
|
|
1253
|
+
exports.listAgents = listAgents;
|
|
1254
|
+
/**
|
|
1255
|
+
* Get agent metadata
|
|
1256
|
+
* Get comprehensive metadata for a specific agent type.
|
|
1257
|
+
*
|
|
1258
|
+
* **Returns:**
|
|
1259
|
+
* - Agent name and description
|
|
1260
|
+
* - Version information
|
|
1261
|
+
* - Supported capabilities and modes
|
|
1262
|
+
* - Credit requirements
|
|
1263
|
+
* - Author and tags
|
|
1264
|
+
* - Configuration options
|
|
1265
|
+
*
|
|
1266
|
+
* Use this to understand agent capabilities before execution.
|
|
1267
|
+
*/
|
|
1268
|
+
const getAgentMetadata = (options) => {
|
|
1269
|
+
return (options.client ?? client_gen_1.client).get({
|
|
1270
|
+
security: [
|
|
1271
|
+
{
|
|
1272
|
+
name: 'X-API-Key',
|
|
1273
|
+
type: 'apiKey'
|
|
1274
|
+
},
|
|
1275
|
+
{
|
|
1276
|
+
scheme: 'bearer',
|
|
1277
|
+
type: 'http'
|
|
1278
|
+
}
|
|
1279
|
+
],
|
|
1280
|
+
url: '/v1/{graph_id}/agent/{agent_type}/metadata',
|
|
1281
|
+
...options
|
|
1282
|
+
});
|
|
1283
|
+
};
|
|
1284
|
+
exports.getAgentMetadata = getAgentMetadata;
|
|
1285
|
+
/**
|
|
1286
|
+
* Get agent recommendations
|
|
1287
|
+
* Get intelligent agent recommendations for a specific query.
|
|
1288
|
+
*
|
|
1289
|
+
* **How it works:**
|
|
1290
|
+
* 1. Analyzes query content and structure
|
|
1291
|
+
* 2. Evaluates agent capabilities
|
|
1292
|
+
* 3. Calculates confidence scores
|
|
1293
|
+
* 4. Returns ranked recommendations
|
|
1294
|
+
*
|
|
1295
|
+
* **Use this when:**
|
|
1296
|
+
* - Unsure which agent to use
|
|
1297
|
+
* - Need to understand agent suitability
|
|
1298
|
+
* - Want confidence scores for decision making
|
|
1299
|
+
*
|
|
1300
|
+
* Returns top agents ranked by confidence with explanations.
|
|
1301
|
+
*/
|
|
1302
|
+
const recommendAgent = (options) => {
|
|
1303
|
+
return (options.client ?? client_gen_1.client).post({
|
|
1304
|
+
security: [
|
|
1305
|
+
{
|
|
1306
|
+
name: 'X-API-Key',
|
|
1307
|
+
type: 'apiKey'
|
|
1308
|
+
},
|
|
1309
|
+
{
|
|
1310
|
+
scheme: 'bearer',
|
|
1311
|
+
type: 'http'
|
|
1312
|
+
}
|
|
1313
|
+
],
|
|
1314
|
+
url: '/v1/{graph_id}/agent/recommend',
|
|
1315
|
+
...options,
|
|
1316
|
+
headers: {
|
|
1317
|
+
'Content-Type': 'application/json',
|
|
1318
|
+
...options.headers
|
|
1319
|
+
}
|
|
1320
|
+
});
|
|
1321
|
+
};
|
|
1322
|
+
exports.recommendAgent = recommendAgent;
|
|
1126
1323
|
/**
|
|
1127
1324
|
* List MCP Tools
|
|
1128
1325
|
* Get available Model Context Protocol tools for graph analysis.
|