@robosystems/client 0.2.9 → 0.2.10
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/package.json +1 -1
- package/sdk/sdk.gen.d.ts +85 -1
- package/sdk/sdk.gen.js +237 -1
- package/sdk/sdk.gen.ts +237 -1
- package/sdk/types.gen.d.ts +524 -0
- package/sdk/types.gen.ts +574 -0
- package/sdk.gen.d.ts +85 -1
- package/sdk.gen.js +237 -1
- package/sdk.gen.ts +237 -1
- package/types.gen.d.ts +524 -0
- package/types.gen.ts +574 -0
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, GetCurrentAuthUserData, GetCurrentAuthUserResponses, GetCurrentAuthUserErrors, RefreshAuthSessionData, RefreshAuthSessionResponses, RefreshAuthSessionErrors, ResendVerificationEmailData, ResendVerificationEmailResponses, ResendVerificationEmailErrors, VerifyEmailData, VerifyEmailResponses, VerifyEmailErrors, GetPasswordPolicyData, GetPasswordPolicyResponses, CheckPasswordStrengthData, CheckPasswordStrengthResponses, CheckPasswordStrengthErrors, ForgotPasswordData, ForgotPasswordResponses, ForgotPasswordErrors, ValidateResetTokenData, ValidateResetTokenResponses, ValidateResetTokenErrors, ResetPasswordData, ResetPasswordResponses, ResetPasswordErrors, GenerateSsoTokenData, GenerateSsoTokenResponses, GenerateSsoTokenErrors, SsoTokenExchangeData, SsoTokenExchangeResponses, SsoTokenExchangeErrors, CompleteSsoAuthData, CompleteSsoAuthResponses, CompleteSsoAuthErrors, GetCaptchaConfigData, GetCaptchaConfigResponses, GetServiceStatusData, GetServiceStatusResponses, GetCurrentUserData, GetCurrentUserResponses, UpdateUserData, UpdateUserResponses, UpdateUserErrors, UpdateUserPasswordData, UpdateUserPasswordResponses, UpdateUserPasswordErrors, ListUserApiKeysData, ListUserApiKeysResponses, CreateUserApiKeyData, CreateUserApiKeyResponses, CreateUserApiKeyErrors, RevokeUserApiKeyData, RevokeUserApiKeyResponses, RevokeUserApiKeyErrors, UpdateUserApiKeyData, UpdateUserApiKeyResponses, UpdateUserApiKeyErrors, GetUserLimitsData, GetUserLimitsResponses, ListConnectionsData, ListConnectionsResponses, ListConnectionsErrors, CreateConnectionData, CreateConnectionResponses, CreateConnectionErrors, GetConnectionOptionsData, GetConnectionOptionsResponses, GetConnectionOptionsErrors, ExchangeLinkTokenData, ExchangeLinkTokenResponses, ExchangeLinkTokenErrors, CreateLinkTokenData, CreateLinkTokenResponses, CreateLinkTokenErrors, InitOAuthData, InitOAuthResponses, InitOAuthErrors, OauthCallbackData, OauthCallbackResponses, OauthCallbackErrors, DeleteConnectionData, DeleteConnectionResponses, DeleteConnectionErrors, GetConnectionData, GetConnectionResponses, GetConnectionErrors, SyncConnectionData, SyncConnectionResponses, SyncConnectionErrors, AutoSelectAgentData, AutoSelectAgentResponses, AutoSelectAgentErrors, ExecuteSpecificAgentData, ExecuteSpecificAgentResponses, ExecuteSpecificAgentErrors, BatchProcessQueriesData, BatchProcessQueriesResponses, BatchProcessQueriesErrors, ListAgentsData, ListAgentsResponses, ListAgentsErrors, GetAgentMetadataData, GetAgentMetadataResponses, GetAgentMetadataErrors, RecommendAgentData, RecommendAgentResponses, RecommendAgentErrors, ListMcpToolsData, ListMcpToolsResponses, ListMcpToolsErrors, CallMcpToolData, CallMcpToolResponses, CallMcpToolErrors, ListBackupsData, ListBackupsResponses, ListBackupsErrors, CreateBackupData, CreateBackupResponses, CreateBackupErrors, GetBackupDownloadUrlData, GetBackupDownloadUrlResponses, GetBackupDownloadUrlErrors, RestoreBackupData, RestoreBackupResponses, RestoreBackupErrors, GetBackupStatsData, GetBackupStatsResponses, GetBackupStatsErrors, GetGraphMetricsData, GetGraphMetricsResponses, GetGraphMetricsErrors, GetGraphUsageAnalyticsData, GetGraphUsageAnalyticsResponses, GetGraphUsageAnalyticsErrors, ExecuteCypherQueryData, ExecuteCypherQueryResponses, ExecuteCypherQueryErrors, GetGraphSchemaData, GetGraphSchemaResponses, GetGraphSchemaErrors, ExportGraphSchemaData, ExportGraphSchemaResponses, ExportGraphSchemaErrors, ValidateSchemaData, ValidateSchemaResponses, ValidateSchemaErrors, GetCreditSummaryData, GetCreditSummaryResponses, GetCreditSummaryErrors, ListCreditTransactionsData, ListCreditTransactionsResponses, ListCreditTransactionsErrors, CheckCreditBalanceData, CheckCreditBalanceResponses, CheckCreditBalanceErrors, GetStorageUsageData, GetStorageUsageResponses, GetStorageUsageErrors, CheckStorageLimitsData, CheckStorageLimitsResponses, CheckStorageLimitsErrors, GetDatabaseHealthData, GetDatabaseHealthResponses, GetDatabaseHealthErrors, GetDatabaseInfoData, GetDatabaseInfoResponses, GetDatabaseInfoErrors, GetGraphLimitsData, GetGraphLimitsResponses, GetGraphLimitsErrors, ListSubgraphsData, ListSubgraphsResponses, ListSubgraphsErrors, CreateSubgraphData, CreateSubgraphResponses, CreateSubgraphErrors, DeleteSubgraphData, DeleteSubgraphResponses, DeleteSubgraphErrors, GetSubgraphInfoData, GetSubgraphInfoResponses, GetSubgraphInfoErrors, GetSubgraphQuotaData, GetSubgraphQuotaResponses, GetSubgraphQuotaErrors, CancelSubscriptionData, CancelSubscriptionResponses, CancelSubscriptionErrors, GetGraphSubscriptionData, GetGraphSubscriptionResponses, GetGraphSubscriptionErrors, CreateRepositorySubscriptionData, CreateRepositorySubscriptionResponses, CreateRepositorySubscriptionErrors, UpgradeSubscriptionData, UpgradeSubscriptionResponses, UpgradeSubscriptionErrors, ListTablesData, ListTablesResponses, ListTablesErrors, ListTableFilesData, ListTableFilesResponses, ListTableFilesErrors, GetUploadUrlData, GetUploadUrlResponses, GetUploadUrlErrors, DeleteFileData, DeleteFileResponses, DeleteFileErrors, GetFileInfoData, GetFileInfoResponses, GetFileInfoErrors, UpdateFileStatusData, UpdateFileStatusResponses, UpdateFileStatusErrors, IngestTablesData, IngestTablesResponses, IngestTablesErrors, QueryTablesData, QueryTablesResponses, QueryTablesErrors, GetGraphsData, GetGraphsResponses, GetGraphsErrors, CreateGraphData, CreateGraphResponses, CreateGraphErrors, GetAvailableExtensionsData, GetAvailableExtensionsResponses, GetAvailableExtensionsErrors, GetAvailableGraphTiersData, GetAvailableGraphTiersResponses, GetAvailableGraphTiersErrors, SelectGraphData, SelectGraphResponses, SelectGraphErrors, 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, GetCurrentAuthUserData, GetCurrentAuthUserResponses, GetCurrentAuthUserErrors, RefreshAuthSessionData, RefreshAuthSessionResponses, RefreshAuthSessionErrors, ResendVerificationEmailData, ResendVerificationEmailResponses, ResendVerificationEmailErrors, VerifyEmailData, VerifyEmailResponses, VerifyEmailErrors, GetPasswordPolicyData, GetPasswordPolicyResponses, CheckPasswordStrengthData, CheckPasswordStrengthResponses, CheckPasswordStrengthErrors, ForgotPasswordData, ForgotPasswordResponses, ForgotPasswordErrors, ValidateResetTokenData, ValidateResetTokenResponses, ValidateResetTokenErrors, ResetPasswordData, ResetPasswordResponses, ResetPasswordErrors, GenerateSsoTokenData, GenerateSsoTokenResponses, GenerateSsoTokenErrors, SsoTokenExchangeData, SsoTokenExchangeResponses, SsoTokenExchangeErrors, CompleteSsoAuthData, CompleteSsoAuthResponses, CompleteSsoAuthErrors, GetCaptchaConfigData, GetCaptchaConfigResponses, GetServiceStatusData, GetServiceStatusResponses, GetCurrentUserData, GetCurrentUserResponses, UpdateUserData, UpdateUserResponses, UpdateUserErrors, UpdateUserPasswordData, UpdateUserPasswordResponses, UpdateUserPasswordErrors, ListUserApiKeysData, ListUserApiKeysResponses, CreateUserApiKeyData, CreateUserApiKeyResponses, CreateUserApiKeyErrors, RevokeUserApiKeyData, RevokeUserApiKeyResponses, RevokeUserApiKeyErrors, UpdateUserApiKeyData, UpdateUserApiKeyResponses, UpdateUserApiKeyErrors, GetUserLimitsData, GetUserLimitsResponses, ListConnectionsData, ListConnectionsResponses, ListConnectionsErrors, CreateConnectionData, CreateConnectionResponses, CreateConnectionErrors, GetConnectionOptionsData, GetConnectionOptionsResponses, GetConnectionOptionsErrors, ExchangeLinkTokenData, ExchangeLinkTokenResponses, ExchangeLinkTokenErrors, CreateLinkTokenData, CreateLinkTokenResponses, CreateLinkTokenErrors, InitOAuthData, InitOAuthResponses, InitOAuthErrors, OauthCallbackData, OauthCallbackResponses, OauthCallbackErrors, DeleteConnectionData, DeleteConnectionResponses, DeleteConnectionErrors, GetConnectionData, GetConnectionResponses, GetConnectionErrors, SyncConnectionData, SyncConnectionResponses, SyncConnectionErrors, AutoSelectAgentData, AutoSelectAgentResponses, AutoSelectAgentErrors, ExecuteSpecificAgentData, ExecuteSpecificAgentResponses, ExecuteSpecificAgentErrors, BatchProcessQueriesData, BatchProcessQueriesResponses, BatchProcessQueriesErrors, ListAgentsData, ListAgentsResponses, ListAgentsErrors, GetAgentMetadataData, GetAgentMetadataResponses, GetAgentMetadataErrors, RecommendAgentData, RecommendAgentResponses, RecommendAgentErrors, ListMcpToolsData, ListMcpToolsResponses, ListMcpToolsErrors, CallMcpToolData, CallMcpToolResponses, CallMcpToolErrors, ListBackupsData, ListBackupsResponses, ListBackupsErrors, CreateBackupData, CreateBackupResponses, CreateBackupErrors, GetBackupDownloadUrlData, GetBackupDownloadUrlResponses, GetBackupDownloadUrlErrors, RestoreBackupData, RestoreBackupResponses, RestoreBackupErrors, GetBackupStatsData, GetBackupStatsResponses, GetBackupStatsErrors, GetGraphMetricsData, GetGraphMetricsResponses, GetGraphMetricsErrors, GetGraphUsageAnalyticsData, GetGraphUsageAnalyticsResponses, GetGraphUsageAnalyticsErrors, ExecuteCypherQueryData, ExecuteCypherQueryResponses, ExecuteCypherQueryErrors, GetGraphSchemaData, GetGraphSchemaResponses, GetGraphSchemaErrors, ExportGraphSchemaData, ExportGraphSchemaResponses, ExportGraphSchemaErrors, ValidateSchemaData, ValidateSchemaResponses, ValidateSchemaErrors, GetCreditSummaryData, GetCreditSummaryResponses, GetCreditSummaryErrors, ListCreditTransactionsData, ListCreditTransactionsResponses, ListCreditTransactionsErrors, CheckCreditBalanceData, CheckCreditBalanceResponses, CheckCreditBalanceErrors, GetStorageUsageData, GetStorageUsageResponses, GetStorageUsageErrors, CheckStorageLimitsData, CheckStorageLimitsResponses, CheckStorageLimitsErrors, GetDatabaseHealthData, GetDatabaseHealthResponses, GetDatabaseHealthErrors, GetDatabaseInfoData, GetDatabaseInfoResponses, GetDatabaseInfoErrors, GetGraphLimitsData, GetGraphLimitsResponses, GetGraphLimitsErrors, ListSubgraphsData, ListSubgraphsResponses, ListSubgraphsErrors, CreateSubgraphData, CreateSubgraphResponses, CreateSubgraphErrors, DeleteSubgraphData, DeleteSubgraphResponses, DeleteSubgraphErrors, GetSubgraphInfoData, GetSubgraphInfoResponses, GetSubgraphInfoErrors, GetSubgraphQuotaData, GetSubgraphQuotaResponses, GetSubgraphQuotaErrors, CancelSubscriptionData, CancelSubscriptionResponses, CancelSubscriptionErrors, GetGraphSubscriptionData, GetGraphSubscriptionResponses, GetGraphSubscriptionErrors, CreateRepositorySubscriptionData, CreateRepositorySubscriptionResponses, CreateRepositorySubscriptionErrors, UpgradeSubscriptionData, UpgradeSubscriptionResponses, UpgradeSubscriptionErrors, ListTablesData, ListTablesResponses, ListTablesErrors, ListTableFilesData, ListTableFilesResponses, ListTableFilesErrors, GetUploadUrlData, GetUploadUrlResponses, GetUploadUrlErrors, DeleteFileData, DeleteFileResponses, DeleteFileErrors, GetFileInfoData, GetFileInfoResponses, GetFileInfoErrors, UpdateFileStatusData, UpdateFileStatusResponses, UpdateFileStatusErrors, IngestTablesData, IngestTablesResponses, IngestTablesErrors, QueryTablesData, QueryTablesResponses, QueryTablesErrors, GetGraphsData, GetGraphsResponses, GetGraphsErrors, CreateGraphData, CreateGraphResponses, CreateGraphErrors, GetAvailableExtensionsData, GetAvailableExtensionsResponses, GetAvailableExtensionsErrors, GetAvailableGraphTiersData, GetAvailableGraphTiersResponses, GetAvailableGraphTiersErrors, SelectGraphData, SelectGraphResponses, SelectGraphErrors, GetServiceOfferingsData, GetServiceOfferingsResponses, GetServiceOfferingsErrors, StreamOperationEventsData, StreamOperationEventsResponses, StreamOperationEventsErrors, GetOperationStatusData, GetOperationStatusResponses, GetOperationStatusErrors, CancelOperationData, CancelOperationResponses, CancelOperationErrors, CreateCheckoutSessionData, CreateCheckoutSessionResponses, CreateCheckoutSessionErrors, GetCheckoutStatusData, GetCheckoutStatusResponses, GetCheckoutStatusErrors, GetBillingCustomerData, GetBillingCustomerResponses, UpdatePaymentMethodData, UpdatePaymentMethodResponses, UpdatePaymentMethodErrors, ListInvoicesData, ListInvoicesResponses, ListInvoicesErrors, GetUpcomingInvoiceData, GetUpcomingInvoiceResponses, ListSubscriptionsData, ListSubscriptionsResponses, GetSubscriptionData, GetSubscriptionResponses, GetSubscriptionErrors, CancelSubscription2Data, CancelSubscription2Responses, CancelSubscription2Errors } 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
|
|
@@ -1799,3 +1799,87 @@ export declare const getOperationStatus: <ThrowOnError extends boolean = false>(
|
|
|
1799
1799
|
* **No credits are consumed for cancellation requests.**
|
|
1800
1800
|
*/
|
|
1801
1801
|
export declare const cancelOperation: <ThrowOnError extends boolean = false>(options: Options<CancelOperationData, ThrowOnError>) => import("./client").RequestResult<CancelOperationResponses, CancelOperationErrors, ThrowOnError, "fields">;
|
|
1802
|
+
/**
|
|
1803
|
+
* Create Payment Checkout Session
|
|
1804
|
+
* Create a Stripe checkout session for collecting payment method.
|
|
1805
|
+
*
|
|
1806
|
+
* This endpoint is used when a user needs to add a payment method before
|
|
1807
|
+
* provisioning resources. It creates a pending subscription and redirects
|
|
1808
|
+
* the user to Stripe Checkout to collect payment details.
|
|
1809
|
+
*
|
|
1810
|
+
* **Flow:**
|
|
1811
|
+
* 1. User tries to create a graph but has no payment method
|
|
1812
|
+
* 2. Frontend calls this endpoint with graph configuration
|
|
1813
|
+
* 3. Backend creates a subscription in PENDING_PAYMENT status
|
|
1814
|
+
* 4. Returns Stripe Checkout URL
|
|
1815
|
+
* 5. User completes payment on Stripe
|
|
1816
|
+
* 6. Webhook activates subscription and provisions resource
|
|
1817
|
+
*
|
|
1818
|
+
* **Enterprise customers** (with invoice_billing_enabled) should not call this endpoint.
|
|
1819
|
+
*/
|
|
1820
|
+
export declare const createCheckoutSession: <ThrowOnError extends boolean = false>(options: Options<CreateCheckoutSessionData, ThrowOnError>) => import("./client").RequestResult<CreateCheckoutSessionResponses, CreateCheckoutSessionErrors, ThrowOnError, "fields">;
|
|
1821
|
+
/**
|
|
1822
|
+
* Get Checkout Session Status
|
|
1823
|
+
* Poll the status of a checkout session.
|
|
1824
|
+
*
|
|
1825
|
+
* Frontend should poll this endpoint after user returns from Stripe Checkout
|
|
1826
|
+
* to determine when the resource is ready.
|
|
1827
|
+
*
|
|
1828
|
+
* **Status Values:**
|
|
1829
|
+
* - `pending_payment`: Waiting for payment to complete
|
|
1830
|
+
* - `provisioning`: Payment confirmed, resource being created
|
|
1831
|
+
* - `completed`: Resource is ready (resource_id will be set)
|
|
1832
|
+
* - `failed`: Something went wrong (error field will be set)
|
|
1833
|
+
*
|
|
1834
|
+
* **When status is 'completed':**
|
|
1835
|
+
* - For graphs: `resource_id` will be the graph_id, and `operation_id` can be used to monitor SSE progress
|
|
1836
|
+
* - For repositories: `resource_id` will be the repository name and access is immediately available
|
|
1837
|
+
*/
|
|
1838
|
+
export declare const getCheckoutStatus: <ThrowOnError extends boolean = false>(options: Options<GetCheckoutStatusData, ThrowOnError>) => import("./client").RequestResult<GetCheckoutStatusResponses, GetCheckoutStatusErrors, ThrowOnError, "fields">;
|
|
1839
|
+
/**
|
|
1840
|
+
* Get Customer Info
|
|
1841
|
+
* Get billing customer information including payment methods on file.
|
|
1842
|
+
*
|
|
1843
|
+
* Returns customer details, payment methods, and whether invoice billing is enabled.
|
|
1844
|
+
*/
|
|
1845
|
+
export declare const getBillingCustomer: <ThrowOnError extends boolean = false>(options?: Options<GetBillingCustomerData, ThrowOnError>) => import("./client").RequestResult<GetBillingCustomerResponses, unknown, ThrowOnError, "fields">;
|
|
1846
|
+
/**
|
|
1847
|
+
* Update Default Payment Method
|
|
1848
|
+
* Update the default payment method for the customer.
|
|
1849
|
+
*
|
|
1850
|
+
* This changes which payment method will be used for future subscription charges.
|
|
1851
|
+
*/
|
|
1852
|
+
export declare const updatePaymentMethod: <ThrowOnError extends boolean = false>(options: Options<UpdatePaymentMethodData, ThrowOnError>) => import("./client").RequestResult<UpdatePaymentMethodResponses, UpdatePaymentMethodErrors, ThrowOnError, "fields">;
|
|
1853
|
+
/**
|
|
1854
|
+
* List Invoices
|
|
1855
|
+
* List payment history and invoices.
|
|
1856
|
+
*
|
|
1857
|
+
* Returns past invoices with payment status, amounts, and line items.
|
|
1858
|
+
*/
|
|
1859
|
+
export declare const listInvoices: <ThrowOnError extends boolean = false>(options?: Options<ListInvoicesData, ThrowOnError>) => import("./client").RequestResult<ListInvoicesResponses, ListInvoicesErrors, ThrowOnError, "fields">;
|
|
1860
|
+
/**
|
|
1861
|
+
* Get Upcoming Invoice
|
|
1862
|
+
* Get preview of the next invoice.
|
|
1863
|
+
*
|
|
1864
|
+
* Returns estimated charges for the next billing period.
|
|
1865
|
+
*/
|
|
1866
|
+
export declare const getUpcomingInvoice: <ThrowOnError extends boolean = false>(options?: Options<GetUpcomingInvoiceData, ThrowOnError>) => import("./client").RequestResult<GetUpcomingInvoiceResponses, unknown, ThrowOnError, "fields">;
|
|
1867
|
+
/**
|
|
1868
|
+
* List All Subscriptions
|
|
1869
|
+
* List all active and past subscriptions for the user.
|
|
1870
|
+
*
|
|
1871
|
+
* Includes both graph and repository subscriptions with their status, pricing, and billing information.
|
|
1872
|
+
*/
|
|
1873
|
+
export declare const listSubscriptions: <ThrowOnError extends boolean = false>(options?: Options<ListSubscriptionsData, ThrowOnError>) => import("./client").RequestResult<ListSubscriptionsResponses, unknown, ThrowOnError, "fields">;
|
|
1874
|
+
/**
|
|
1875
|
+
* Get Subscription Details
|
|
1876
|
+
* Get detailed information about a specific subscription.
|
|
1877
|
+
*/
|
|
1878
|
+
export declare const getSubscription: <ThrowOnError extends boolean = false>(options: Options<GetSubscriptionData, ThrowOnError>) => import("./client").RequestResult<GetSubscriptionResponses, GetSubscriptionErrors, ThrowOnError, "fields">;
|
|
1879
|
+
/**
|
|
1880
|
+
* Cancel Subscription
|
|
1881
|
+
* Cancel a subscription.
|
|
1882
|
+
*
|
|
1883
|
+
* The subscription will remain active until the end of the current billing period.
|
|
1884
|
+
*/
|
|
1885
|
+
export declare const cancelSubscription2: <ThrowOnError extends boolean = false>(options: Options<CancelSubscription2Data, ThrowOnError>) => import("./client").RequestResult<CancelSubscription2Responses, CancelSubscription2Errors, ThrowOnError, "fields">;
|
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.getGraphUsageAnalytics = exports.getGraphMetrics = exports.getBackupStats = exports.restoreBackup = exports.getBackupDownloadUrl = exports.createBackup = exports.listBackups = exports.callMcpTool = exports.listMcpTools = exports.recommendAgent = exports.getAgentMetadata = exports.listAgents = exports.batchProcessQueries = exports.executeSpecificAgent = exports.autoSelectAgent = exports.syncConnection = exports.getConnection = exports.deleteConnection = exports.oauthCallback = exports.initOAuth = exports.createLinkToken = exports.exchangeLinkToken = exports.getConnectionOptions = exports.createConnection = exports.listConnections = exports.getUserLimits = exports.updateUserApiKey = exports.revokeUserApiKey = exports.createUserApiKey = exports.listUserApiKeys = exports.updateUserPassword = exports.updateUser = exports.getCurrentUser = exports.getServiceStatus = exports.getCaptchaConfig = exports.completeSsoAuth = exports.ssoTokenExchange = 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.selectGraph = exports.getAvailableGraphTiers = exports.getAvailableExtensions = exports.createGraph = exports.getGraphs = exports.queryTables = exports.ingestTables = exports.updateFileStatus = exports.getFileInfo = exports.deleteFile = exports.getUploadUrl = exports.listTableFiles = exports.listTables = exports.upgradeSubscription = exports.createRepositorySubscription = exports.getGraphSubscription = exports.cancelSubscription = 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.validateSchema = exports.exportGraphSchema = exports.getGraphSchema = exports.executeCypherQuery = void 0;
|
|
5
|
+
exports.cancelSubscription2 = exports.getSubscription = exports.listSubscriptions = exports.getUpcomingInvoice = exports.listInvoices = exports.updatePaymentMethod = exports.getBillingCustomer = exports.getCheckoutStatus = exports.createCheckoutSession = exports.cancelOperation = exports.getOperationStatus = exports.streamOperationEvents = exports.getServiceOfferings = exports.selectGraph = exports.getAvailableGraphTiers = exports.getAvailableExtensions = exports.createGraph = exports.getGraphs = exports.queryTables = exports.ingestTables = exports.updateFileStatus = exports.getFileInfo = exports.deleteFile = exports.getUploadUrl = exports.listTableFiles = exports.listTables = exports.upgradeSubscription = exports.createRepositorySubscription = exports.getGraphSubscription = exports.cancelSubscription = 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.validateSchema = exports.exportGraphSchema = exports.getGraphSchema = exports.executeCypherQuery = void 0;
|
|
6
6
|
const client_gen_1 = require("./client.gen");
|
|
7
7
|
/**
|
|
8
8
|
* Register New User
|
|
@@ -3162,3 +3162,239 @@ const cancelOperation = (options) => {
|
|
|
3162
3162
|
});
|
|
3163
3163
|
};
|
|
3164
3164
|
exports.cancelOperation = cancelOperation;
|
|
3165
|
+
/**
|
|
3166
|
+
* Create Payment Checkout Session
|
|
3167
|
+
* Create a Stripe checkout session for collecting payment method.
|
|
3168
|
+
*
|
|
3169
|
+
* This endpoint is used when a user needs to add a payment method before
|
|
3170
|
+
* provisioning resources. It creates a pending subscription and redirects
|
|
3171
|
+
* the user to Stripe Checkout to collect payment details.
|
|
3172
|
+
*
|
|
3173
|
+
* **Flow:**
|
|
3174
|
+
* 1. User tries to create a graph but has no payment method
|
|
3175
|
+
* 2. Frontend calls this endpoint with graph configuration
|
|
3176
|
+
* 3. Backend creates a subscription in PENDING_PAYMENT status
|
|
3177
|
+
* 4. Returns Stripe Checkout URL
|
|
3178
|
+
* 5. User completes payment on Stripe
|
|
3179
|
+
* 6. Webhook activates subscription and provisions resource
|
|
3180
|
+
*
|
|
3181
|
+
* **Enterprise customers** (with invoice_billing_enabled) should not call this endpoint.
|
|
3182
|
+
*/
|
|
3183
|
+
const createCheckoutSession = (options) => {
|
|
3184
|
+
return (options.client ?? client_gen_1.client).post({
|
|
3185
|
+
security: [
|
|
3186
|
+
{
|
|
3187
|
+
name: 'X-API-Key',
|
|
3188
|
+
type: 'apiKey'
|
|
3189
|
+
},
|
|
3190
|
+
{
|
|
3191
|
+
scheme: 'bearer',
|
|
3192
|
+
type: 'http'
|
|
3193
|
+
}
|
|
3194
|
+
],
|
|
3195
|
+
url: '/v1/billing/checkout',
|
|
3196
|
+
...options,
|
|
3197
|
+
headers: {
|
|
3198
|
+
'Content-Type': 'application/json',
|
|
3199
|
+
...options.headers
|
|
3200
|
+
}
|
|
3201
|
+
});
|
|
3202
|
+
};
|
|
3203
|
+
exports.createCheckoutSession = createCheckoutSession;
|
|
3204
|
+
/**
|
|
3205
|
+
* Get Checkout Session Status
|
|
3206
|
+
* Poll the status of a checkout session.
|
|
3207
|
+
*
|
|
3208
|
+
* Frontend should poll this endpoint after user returns from Stripe Checkout
|
|
3209
|
+
* to determine when the resource is ready.
|
|
3210
|
+
*
|
|
3211
|
+
* **Status Values:**
|
|
3212
|
+
* - `pending_payment`: Waiting for payment to complete
|
|
3213
|
+
* - `provisioning`: Payment confirmed, resource being created
|
|
3214
|
+
* - `completed`: Resource is ready (resource_id will be set)
|
|
3215
|
+
* - `failed`: Something went wrong (error field will be set)
|
|
3216
|
+
*
|
|
3217
|
+
* **When status is 'completed':**
|
|
3218
|
+
* - For graphs: `resource_id` will be the graph_id, and `operation_id` can be used to monitor SSE progress
|
|
3219
|
+
* - For repositories: `resource_id` will be the repository name and access is immediately available
|
|
3220
|
+
*/
|
|
3221
|
+
const getCheckoutStatus = (options) => {
|
|
3222
|
+
return (options.client ?? client_gen_1.client).get({
|
|
3223
|
+
security: [
|
|
3224
|
+
{
|
|
3225
|
+
name: 'X-API-Key',
|
|
3226
|
+
type: 'apiKey'
|
|
3227
|
+
},
|
|
3228
|
+
{
|
|
3229
|
+
scheme: 'bearer',
|
|
3230
|
+
type: 'http'
|
|
3231
|
+
}
|
|
3232
|
+
],
|
|
3233
|
+
url: '/v1/billing/checkout/{session_id}/status',
|
|
3234
|
+
...options
|
|
3235
|
+
});
|
|
3236
|
+
};
|
|
3237
|
+
exports.getCheckoutStatus = getCheckoutStatus;
|
|
3238
|
+
/**
|
|
3239
|
+
* Get Customer Info
|
|
3240
|
+
* Get billing customer information including payment methods on file.
|
|
3241
|
+
*
|
|
3242
|
+
* Returns customer details, payment methods, and whether invoice billing is enabled.
|
|
3243
|
+
*/
|
|
3244
|
+
const getBillingCustomer = (options) => {
|
|
3245
|
+
return (options?.client ?? client_gen_1.client).get({
|
|
3246
|
+
security: [
|
|
3247
|
+
{
|
|
3248
|
+
name: 'X-API-Key',
|
|
3249
|
+
type: 'apiKey'
|
|
3250
|
+
},
|
|
3251
|
+
{
|
|
3252
|
+
scheme: 'bearer',
|
|
3253
|
+
type: 'http'
|
|
3254
|
+
}
|
|
3255
|
+
],
|
|
3256
|
+
url: '/v1/billing/customer',
|
|
3257
|
+
...options
|
|
3258
|
+
});
|
|
3259
|
+
};
|
|
3260
|
+
exports.getBillingCustomer = getBillingCustomer;
|
|
3261
|
+
/**
|
|
3262
|
+
* Update Default Payment Method
|
|
3263
|
+
* Update the default payment method for the customer.
|
|
3264
|
+
*
|
|
3265
|
+
* This changes which payment method will be used for future subscription charges.
|
|
3266
|
+
*/
|
|
3267
|
+
const updatePaymentMethod = (options) => {
|
|
3268
|
+
return (options.client ?? client_gen_1.client).post({
|
|
3269
|
+
security: [
|
|
3270
|
+
{
|
|
3271
|
+
name: 'X-API-Key',
|
|
3272
|
+
type: 'apiKey'
|
|
3273
|
+
},
|
|
3274
|
+
{
|
|
3275
|
+
scheme: 'bearer',
|
|
3276
|
+
type: 'http'
|
|
3277
|
+
}
|
|
3278
|
+
],
|
|
3279
|
+
url: '/v1/billing/customer/payment-method',
|
|
3280
|
+
...options,
|
|
3281
|
+
headers: {
|
|
3282
|
+
'Content-Type': 'application/json',
|
|
3283
|
+
...options.headers
|
|
3284
|
+
}
|
|
3285
|
+
});
|
|
3286
|
+
};
|
|
3287
|
+
exports.updatePaymentMethod = updatePaymentMethod;
|
|
3288
|
+
/**
|
|
3289
|
+
* List Invoices
|
|
3290
|
+
* List payment history and invoices.
|
|
3291
|
+
*
|
|
3292
|
+
* Returns past invoices with payment status, amounts, and line items.
|
|
3293
|
+
*/
|
|
3294
|
+
const listInvoices = (options) => {
|
|
3295
|
+
return (options?.client ?? client_gen_1.client).get({
|
|
3296
|
+
security: [
|
|
3297
|
+
{
|
|
3298
|
+
name: 'X-API-Key',
|
|
3299
|
+
type: 'apiKey'
|
|
3300
|
+
},
|
|
3301
|
+
{
|
|
3302
|
+
scheme: 'bearer',
|
|
3303
|
+
type: 'http'
|
|
3304
|
+
}
|
|
3305
|
+
],
|
|
3306
|
+
url: '/v1/billing/invoices',
|
|
3307
|
+
...options
|
|
3308
|
+
});
|
|
3309
|
+
};
|
|
3310
|
+
exports.listInvoices = listInvoices;
|
|
3311
|
+
/**
|
|
3312
|
+
* Get Upcoming Invoice
|
|
3313
|
+
* Get preview of the next invoice.
|
|
3314
|
+
*
|
|
3315
|
+
* Returns estimated charges for the next billing period.
|
|
3316
|
+
*/
|
|
3317
|
+
const getUpcomingInvoice = (options) => {
|
|
3318
|
+
return (options?.client ?? client_gen_1.client).get({
|
|
3319
|
+
security: [
|
|
3320
|
+
{
|
|
3321
|
+
name: 'X-API-Key',
|
|
3322
|
+
type: 'apiKey'
|
|
3323
|
+
},
|
|
3324
|
+
{
|
|
3325
|
+
scheme: 'bearer',
|
|
3326
|
+
type: 'http'
|
|
3327
|
+
}
|
|
3328
|
+
],
|
|
3329
|
+
url: '/v1/billing/invoices/upcoming',
|
|
3330
|
+
...options
|
|
3331
|
+
});
|
|
3332
|
+
};
|
|
3333
|
+
exports.getUpcomingInvoice = getUpcomingInvoice;
|
|
3334
|
+
/**
|
|
3335
|
+
* List All Subscriptions
|
|
3336
|
+
* List all active and past subscriptions for the user.
|
|
3337
|
+
*
|
|
3338
|
+
* Includes both graph and repository subscriptions with their status, pricing, and billing information.
|
|
3339
|
+
*/
|
|
3340
|
+
const listSubscriptions = (options) => {
|
|
3341
|
+
return (options?.client ?? client_gen_1.client).get({
|
|
3342
|
+
security: [
|
|
3343
|
+
{
|
|
3344
|
+
name: 'X-API-Key',
|
|
3345
|
+
type: 'apiKey'
|
|
3346
|
+
},
|
|
3347
|
+
{
|
|
3348
|
+
scheme: 'bearer',
|
|
3349
|
+
type: 'http'
|
|
3350
|
+
}
|
|
3351
|
+
],
|
|
3352
|
+
url: '/v1/billing/subscriptions',
|
|
3353
|
+
...options
|
|
3354
|
+
});
|
|
3355
|
+
};
|
|
3356
|
+
exports.listSubscriptions = listSubscriptions;
|
|
3357
|
+
/**
|
|
3358
|
+
* Get Subscription Details
|
|
3359
|
+
* Get detailed information about a specific subscription.
|
|
3360
|
+
*/
|
|
3361
|
+
const getSubscription = (options) => {
|
|
3362
|
+
return (options.client ?? client_gen_1.client).get({
|
|
3363
|
+
security: [
|
|
3364
|
+
{
|
|
3365
|
+
name: 'X-API-Key',
|
|
3366
|
+
type: 'apiKey'
|
|
3367
|
+
},
|
|
3368
|
+
{
|
|
3369
|
+
scheme: 'bearer',
|
|
3370
|
+
type: 'http'
|
|
3371
|
+
}
|
|
3372
|
+
],
|
|
3373
|
+
url: '/v1/billing/subscriptions/{subscription_id}',
|
|
3374
|
+
...options
|
|
3375
|
+
});
|
|
3376
|
+
};
|
|
3377
|
+
exports.getSubscription = getSubscription;
|
|
3378
|
+
/**
|
|
3379
|
+
* Cancel Subscription
|
|
3380
|
+
* Cancel a subscription.
|
|
3381
|
+
*
|
|
3382
|
+
* The subscription will remain active until the end of the current billing period.
|
|
3383
|
+
*/
|
|
3384
|
+
const cancelSubscription2 = (options) => {
|
|
3385
|
+
return (options.client ?? client_gen_1.client).post({
|
|
3386
|
+
security: [
|
|
3387
|
+
{
|
|
3388
|
+
name: 'X-API-Key',
|
|
3389
|
+
type: 'apiKey'
|
|
3390
|
+
},
|
|
3391
|
+
{
|
|
3392
|
+
scheme: 'bearer',
|
|
3393
|
+
type: 'http'
|
|
3394
|
+
}
|
|
3395
|
+
],
|
|
3396
|
+
url: '/v1/billing/subscriptions/{subscription_id}/cancel',
|
|
3397
|
+
...options
|
|
3398
|
+
});
|
|
3399
|
+
};
|
|
3400
|
+
exports.cancelSubscription2 = cancelSubscription2;
|
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, GetCurrentAuthUserData, GetCurrentAuthUserResponses, GetCurrentAuthUserErrors, RefreshAuthSessionData, RefreshAuthSessionResponses, RefreshAuthSessionErrors, ResendVerificationEmailData, ResendVerificationEmailResponses, ResendVerificationEmailErrors, VerifyEmailData, VerifyEmailResponses, VerifyEmailErrors, GetPasswordPolicyData, GetPasswordPolicyResponses, CheckPasswordStrengthData, CheckPasswordStrengthResponses, CheckPasswordStrengthErrors, ForgotPasswordData, ForgotPasswordResponses, ForgotPasswordErrors, ValidateResetTokenData, ValidateResetTokenResponses, ValidateResetTokenErrors, ResetPasswordData, ResetPasswordResponses, ResetPasswordErrors, GenerateSsoTokenData, GenerateSsoTokenResponses, GenerateSsoTokenErrors, SsoTokenExchangeData, SsoTokenExchangeResponses, SsoTokenExchangeErrors, CompleteSsoAuthData, CompleteSsoAuthResponses, CompleteSsoAuthErrors, GetCaptchaConfigData, GetCaptchaConfigResponses, GetServiceStatusData, GetServiceStatusResponses, GetCurrentUserData, GetCurrentUserResponses, UpdateUserData, UpdateUserResponses, UpdateUserErrors, UpdateUserPasswordData, UpdateUserPasswordResponses, UpdateUserPasswordErrors, ListUserApiKeysData, ListUserApiKeysResponses, CreateUserApiKeyData, CreateUserApiKeyResponses, CreateUserApiKeyErrors, RevokeUserApiKeyData, RevokeUserApiKeyResponses, RevokeUserApiKeyErrors, UpdateUserApiKeyData, UpdateUserApiKeyResponses, UpdateUserApiKeyErrors, GetUserLimitsData, GetUserLimitsResponses, ListConnectionsData, ListConnectionsResponses, ListConnectionsErrors, CreateConnectionData, CreateConnectionResponses, CreateConnectionErrors, GetConnectionOptionsData, GetConnectionOptionsResponses, GetConnectionOptionsErrors, ExchangeLinkTokenData, ExchangeLinkTokenResponses, ExchangeLinkTokenErrors, CreateLinkTokenData, CreateLinkTokenResponses, CreateLinkTokenErrors, InitOAuthData, InitOAuthResponses, InitOAuthErrors, OauthCallbackData, OauthCallbackResponses, OauthCallbackErrors, DeleteConnectionData, DeleteConnectionResponses, DeleteConnectionErrors, GetConnectionData, GetConnectionResponses, GetConnectionErrors, SyncConnectionData, SyncConnectionResponses, SyncConnectionErrors, AutoSelectAgentData, AutoSelectAgentResponses, AutoSelectAgentErrors, ExecuteSpecificAgentData, ExecuteSpecificAgentResponses, ExecuteSpecificAgentErrors, BatchProcessQueriesData, BatchProcessQueriesResponses, BatchProcessQueriesErrors, ListAgentsData, ListAgentsResponses, ListAgentsErrors, GetAgentMetadataData, GetAgentMetadataResponses, GetAgentMetadataErrors, RecommendAgentData, RecommendAgentResponses, RecommendAgentErrors, ListMcpToolsData, ListMcpToolsResponses, ListMcpToolsErrors, CallMcpToolData, CallMcpToolResponses, CallMcpToolErrors, ListBackupsData, ListBackupsResponses, ListBackupsErrors, CreateBackupData, CreateBackupResponses, CreateBackupErrors, GetBackupDownloadUrlData, GetBackupDownloadUrlResponses, GetBackupDownloadUrlErrors, RestoreBackupData, RestoreBackupResponses, RestoreBackupErrors, GetBackupStatsData, GetBackupStatsResponses, GetBackupStatsErrors, GetGraphMetricsData, GetGraphMetricsResponses, GetGraphMetricsErrors, GetGraphUsageAnalyticsData, GetGraphUsageAnalyticsResponses, GetGraphUsageAnalyticsErrors, ExecuteCypherQueryData, ExecuteCypherQueryResponses, ExecuteCypherQueryErrors, GetGraphSchemaData, GetGraphSchemaResponses, GetGraphSchemaErrors, ExportGraphSchemaData, ExportGraphSchemaResponses, ExportGraphSchemaErrors, ValidateSchemaData, ValidateSchemaResponses, ValidateSchemaErrors, GetCreditSummaryData, GetCreditSummaryResponses, GetCreditSummaryErrors, ListCreditTransactionsData, ListCreditTransactionsResponses, ListCreditTransactionsErrors, CheckCreditBalanceData, CheckCreditBalanceResponses, CheckCreditBalanceErrors, GetStorageUsageData, GetStorageUsageResponses, GetStorageUsageErrors, CheckStorageLimitsData, CheckStorageLimitsResponses, CheckStorageLimitsErrors, GetDatabaseHealthData, GetDatabaseHealthResponses, GetDatabaseHealthErrors, GetDatabaseInfoData, GetDatabaseInfoResponses, GetDatabaseInfoErrors, GetGraphLimitsData, GetGraphLimitsResponses, GetGraphLimitsErrors, ListSubgraphsData, ListSubgraphsResponses, ListSubgraphsErrors, CreateSubgraphData, CreateSubgraphResponses, CreateSubgraphErrors, DeleteSubgraphData, DeleteSubgraphResponses, DeleteSubgraphErrors, GetSubgraphInfoData, GetSubgraphInfoResponses, GetSubgraphInfoErrors, GetSubgraphQuotaData, GetSubgraphQuotaResponses, GetSubgraphQuotaErrors, CancelSubscriptionData, CancelSubscriptionResponses, CancelSubscriptionErrors, GetGraphSubscriptionData, GetGraphSubscriptionResponses, GetGraphSubscriptionErrors, CreateRepositorySubscriptionData, CreateRepositorySubscriptionResponses, CreateRepositorySubscriptionErrors, UpgradeSubscriptionData, UpgradeSubscriptionResponses, UpgradeSubscriptionErrors, ListTablesData, ListTablesResponses, ListTablesErrors, ListTableFilesData, ListTableFilesResponses, ListTableFilesErrors, GetUploadUrlData, GetUploadUrlResponses, GetUploadUrlErrors, DeleteFileData, DeleteFileResponses, DeleteFileErrors, GetFileInfoData, GetFileInfoResponses, GetFileInfoErrors, UpdateFileStatusData, UpdateFileStatusResponses, UpdateFileStatusErrors, IngestTablesData, IngestTablesResponses, IngestTablesErrors, QueryTablesData, QueryTablesResponses, QueryTablesErrors, GetGraphsData, GetGraphsResponses, GetGraphsErrors, CreateGraphData, CreateGraphResponses, CreateGraphErrors, GetAvailableExtensionsData, GetAvailableExtensionsResponses, GetAvailableExtensionsErrors, GetAvailableGraphTiersData, GetAvailableGraphTiersResponses, GetAvailableGraphTiersErrors, SelectGraphData, SelectGraphResponses, SelectGraphErrors, GetServiceOfferingsData, GetServiceOfferingsResponses, GetServiceOfferingsErrors, StreamOperationEventsData, StreamOperationEventsResponses, StreamOperationEventsErrors, GetOperationStatusData, GetOperationStatusResponses, GetOperationStatusErrors, CancelOperationData, CancelOperationResponses, CancelOperationErrors } from './types.gen';
|
|
4
|
+
import type { RegisterUserData, RegisterUserResponses, RegisterUserErrors, LoginUserData, LoginUserResponses, LoginUserErrors, LogoutUserData, LogoutUserResponses, GetCurrentAuthUserData, GetCurrentAuthUserResponses, GetCurrentAuthUserErrors, RefreshAuthSessionData, RefreshAuthSessionResponses, RefreshAuthSessionErrors, ResendVerificationEmailData, ResendVerificationEmailResponses, ResendVerificationEmailErrors, VerifyEmailData, VerifyEmailResponses, VerifyEmailErrors, GetPasswordPolicyData, GetPasswordPolicyResponses, CheckPasswordStrengthData, CheckPasswordStrengthResponses, CheckPasswordStrengthErrors, ForgotPasswordData, ForgotPasswordResponses, ForgotPasswordErrors, ValidateResetTokenData, ValidateResetTokenResponses, ValidateResetTokenErrors, ResetPasswordData, ResetPasswordResponses, ResetPasswordErrors, GenerateSsoTokenData, GenerateSsoTokenResponses, GenerateSsoTokenErrors, SsoTokenExchangeData, SsoTokenExchangeResponses, SsoTokenExchangeErrors, CompleteSsoAuthData, CompleteSsoAuthResponses, CompleteSsoAuthErrors, GetCaptchaConfigData, GetCaptchaConfigResponses, GetServiceStatusData, GetServiceStatusResponses, GetCurrentUserData, GetCurrentUserResponses, UpdateUserData, UpdateUserResponses, UpdateUserErrors, UpdateUserPasswordData, UpdateUserPasswordResponses, UpdateUserPasswordErrors, ListUserApiKeysData, ListUserApiKeysResponses, CreateUserApiKeyData, CreateUserApiKeyResponses, CreateUserApiKeyErrors, RevokeUserApiKeyData, RevokeUserApiKeyResponses, RevokeUserApiKeyErrors, UpdateUserApiKeyData, UpdateUserApiKeyResponses, UpdateUserApiKeyErrors, GetUserLimitsData, GetUserLimitsResponses, ListConnectionsData, ListConnectionsResponses, ListConnectionsErrors, CreateConnectionData, CreateConnectionResponses, CreateConnectionErrors, GetConnectionOptionsData, GetConnectionOptionsResponses, GetConnectionOptionsErrors, ExchangeLinkTokenData, ExchangeLinkTokenResponses, ExchangeLinkTokenErrors, CreateLinkTokenData, CreateLinkTokenResponses, CreateLinkTokenErrors, InitOAuthData, InitOAuthResponses, InitOAuthErrors, OauthCallbackData, OauthCallbackResponses, OauthCallbackErrors, DeleteConnectionData, DeleteConnectionResponses, DeleteConnectionErrors, GetConnectionData, GetConnectionResponses, GetConnectionErrors, SyncConnectionData, SyncConnectionResponses, SyncConnectionErrors, AutoSelectAgentData, AutoSelectAgentResponses, AutoSelectAgentErrors, ExecuteSpecificAgentData, ExecuteSpecificAgentResponses, ExecuteSpecificAgentErrors, BatchProcessQueriesData, BatchProcessQueriesResponses, BatchProcessQueriesErrors, ListAgentsData, ListAgentsResponses, ListAgentsErrors, GetAgentMetadataData, GetAgentMetadataResponses, GetAgentMetadataErrors, RecommendAgentData, RecommendAgentResponses, RecommendAgentErrors, ListMcpToolsData, ListMcpToolsResponses, ListMcpToolsErrors, CallMcpToolData, CallMcpToolResponses, CallMcpToolErrors, ListBackupsData, ListBackupsResponses, ListBackupsErrors, CreateBackupData, CreateBackupResponses, CreateBackupErrors, GetBackupDownloadUrlData, GetBackupDownloadUrlResponses, GetBackupDownloadUrlErrors, RestoreBackupData, RestoreBackupResponses, RestoreBackupErrors, GetBackupStatsData, GetBackupStatsResponses, GetBackupStatsErrors, GetGraphMetricsData, GetGraphMetricsResponses, GetGraphMetricsErrors, GetGraphUsageAnalyticsData, GetGraphUsageAnalyticsResponses, GetGraphUsageAnalyticsErrors, ExecuteCypherQueryData, ExecuteCypherQueryResponses, ExecuteCypherQueryErrors, GetGraphSchemaData, GetGraphSchemaResponses, GetGraphSchemaErrors, ExportGraphSchemaData, ExportGraphSchemaResponses, ExportGraphSchemaErrors, ValidateSchemaData, ValidateSchemaResponses, ValidateSchemaErrors, GetCreditSummaryData, GetCreditSummaryResponses, GetCreditSummaryErrors, ListCreditTransactionsData, ListCreditTransactionsResponses, ListCreditTransactionsErrors, CheckCreditBalanceData, CheckCreditBalanceResponses, CheckCreditBalanceErrors, GetStorageUsageData, GetStorageUsageResponses, GetStorageUsageErrors, CheckStorageLimitsData, CheckStorageLimitsResponses, CheckStorageLimitsErrors, GetDatabaseHealthData, GetDatabaseHealthResponses, GetDatabaseHealthErrors, GetDatabaseInfoData, GetDatabaseInfoResponses, GetDatabaseInfoErrors, GetGraphLimitsData, GetGraphLimitsResponses, GetGraphLimitsErrors, ListSubgraphsData, ListSubgraphsResponses, ListSubgraphsErrors, CreateSubgraphData, CreateSubgraphResponses, CreateSubgraphErrors, DeleteSubgraphData, DeleteSubgraphResponses, DeleteSubgraphErrors, GetSubgraphInfoData, GetSubgraphInfoResponses, GetSubgraphInfoErrors, GetSubgraphQuotaData, GetSubgraphQuotaResponses, GetSubgraphQuotaErrors, CancelSubscriptionData, CancelSubscriptionResponses, CancelSubscriptionErrors, GetGraphSubscriptionData, GetGraphSubscriptionResponses, GetGraphSubscriptionErrors, CreateRepositorySubscriptionData, CreateRepositorySubscriptionResponses, CreateRepositorySubscriptionErrors, UpgradeSubscriptionData, UpgradeSubscriptionResponses, UpgradeSubscriptionErrors, ListTablesData, ListTablesResponses, ListTablesErrors, ListTableFilesData, ListTableFilesResponses, ListTableFilesErrors, GetUploadUrlData, GetUploadUrlResponses, GetUploadUrlErrors, DeleteFileData, DeleteFileResponses, DeleteFileErrors, GetFileInfoData, GetFileInfoResponses, GetFileInfoErrors, UpdateFileStatusData, UpdateFileStatusResponses, UpdateFileStatusErrors, IngestTablesData, IngestTablesResponses, IngestTablesErrors, QueryTablesData, QueryTablesResponses, QueryTablesErrors, GetGraphsData, GetGraphsResponses, GetGraphsErrors, CreateGraphData, CreateGraphResponses, CreateGraphErrors, GetAvailableExtensionsData, GetAvailableExtensionsResponses, GetAvailableExtensionsErrors, GetAvailableGraphTiersData, GetAvailableGraphTiersResponses, GetAvailableGraphTiersErrors, SelectGraphData, SelectGraphResponses, SelectGraphErrors, GetServiceOfferingsData, GetServiceOfferingsResponses, GetServiceOfferingsErrors, StreamOperationEventsData, StreamOperationEventsResponses, StreamOperationEventsErrors, GetOperationStatusData, GetOperationStatusResponses, GetOperationStatusErrors, CancelOperationData, CancelOperationResponses, CancelOperationErrors, CreateCheckoutSessionData, CreateCheckoutSessionResponses, CreateCheckoutSessionErrors, GetCheckoutStatusData, GetCheckoutStatusResponses, GetCheckoutStatusErrors, GetBillingCustomerData, GetBillingCustomerResponses, UpdatePaymentMethodData, UpdatePaymentMethodResponses, UpdatePaymentMethodErrors, ListInvoicesData, ListInvoicesResponses, ListInvoicesErrors, GetUpcomingInvoiceData, GetUpcomingInvoiceResponses, ListSubscriptionsData, ListSubscriptionsResponses, GetSubscriptionData, GetSubscriptionResponses, GetSubscriptionErrors, CancelSubscription2Data, CancelSubscription2Responses, CancelSubscription2Errors } 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> & {
|
|
@@ -3174,4 +3174,240 @@ export const cancelOperation = <ThrowOnError extends boolean = false>(options: O
|
|
|
3174
3174
|
url: '/v1/operations/{operation_id}',
|
|
3175
3175
|
...options
|
|
3176
3176
|
});
|
|
3177
|
+
};
|
|
3178
|
+
|
|
3179
|
+
/**
|
|
3180
|
+
* Create Payment Checkout Session
|
|
3181
|
+
* Create a Stripe checkout session for collecting payment method.
|
|
3182
|
+
*
|
|
3183
|
+
* This endpoint is used when a user needs to add a payment method before
|
|
3184
|
+
* provisioning resources. It creates a pending subscription and redirects
|
|
3185
|
+
* the user to Stripe Checkout to collect payment details.
|
|
3186
|
+
*
|
|
3187
|
+
* **Flow:**
|
|
3188
|
+
* 1. User tries to create a graph but has no payment method
|
|
3189
|
+
* 2. Frontend calls this endpoint with graph configuration
|
|
3190
|
+
* 3. Backend creates a subscription in PENDING_PAYMENT status
|
|
3191
|
+
* 4. Returns Stripe Checkout URL
|
|
3192
|
+
* 5. User completes payment on Stripe
|
|
3193
|
+
* 6. Webhook activates subscription and provisions resource
|
|
3194
|
+
*
|
|
3195
|
+
* **Enterprise customers** (with invoice_billing_enabled) should not call this endpoint.
|
|
3196
|
+
*/
|
|
3197
|
+
export const createCheckoutSession = <ThrowOnError extends boolean = false>(options: Options<CreateCheckoutSessionData, ThrowOnError>) => {
|
|
3198
|
+
return (options.client ?? _heyApiClient).post<CreateCheckoutSessionResponses, CreateCheckoutSessionErrors, ThrowOnError>({
|
|
3199
|
+
security: [
|
|
3200
|
+
{
|
|
3201
|
+
name: 'X-API-Key',
|
|
3202
|
+
type: 'apiKey'
|
|
3203
|
+
},
|
|
3204
|
+
{
|
|
3205
|
+
scheme: 'bearer',
|
|
3206
|
+
type: 'http'
|
|
3207
|
+
}
|
|
3208
|
+
],
|
|
3209
|
+
url: '/v1/billing/checkout',
|
|
3210
|
+
...options,
|
|
3211
|
+
headers: {
|
|
3212
|
+
'Content-Type': 'application/json',
|
|
3213
|
+
...options.headers
|
|
3214
|
+
}
|
|
3215
|
+
});
|
|
3216
|
+
};
|
|
3217
|
+
|
|
3218
|
+
/**
|
|
3219
|
+
* Get Checkout Session Status
|
|
3220
|
+
* Poll the status of a checkout session.
|
|
3221
|
+
*
|
|
3222
|
+
* Frontend should poll this endpoint after user returns from Stripe Checkout
|
|
3223
|
+
* to determine when the resource is ready.
|
|
3224
|
+
*
|
|
3225
|
+
* **Status Values:**
|
|
3226
|
+
* - `pending_payment`: Waiting for payment to complete
|
|
3227
|
+
* - `provisioning`: Payment confirmed, resource being created
|
|
3228
|
+
* - `completed`: Resource is ready (resource_id will be set)
|
|
3229
|
+
* - `failed`: Something went wrong (error field will be set)
|
|
3230
|
+
*
|
|
3231
|
+
* **When status is 'completed':**
|
|
3232
|
+
* - For graphs: `resource_id` will be the graph_id, and `operation_id` can be used to monitor SSE progress
|
|
3233
|
+
* - For repositories: `resource_id` will be the repository name and access is immediately available
|
|
3234
|
+
*/
|
|
3235
|
+
export const getCheckoutStatus = <ThrowOnError extends boolean = false>(options: Options<GetCheckoutStatusData, ThrowOnError>) => {
|
|
3236
|
+
return (options.client ?? _heyApiClient).get<GetCheckoutStatusResponses, GetCheckoutStatusErrors, ThrowOnError>({
|
|
3237
|
+
security: [
|
|
3238
|
+
{
|
|
3239
|
+
name: 'X-API-Key',
|
|
3240
|
+
type: 'apiKey'
|
|
3241
|
+
},
|
|
3242
|
+
{
|
|
3243
|
+
scheme: 'bearer',
|
|
3244
|
+
type: 'http'
|
|
3245
|
+
}
|
|
3246
|
+
],
|
|
3247
|
+
url: '/v1/billing/checkout/{session_id}/status',
|
|
3248
|
+
...options
|
|
3249
|
+
});
|
|
3250
|
+
};
|
|
3251
|
+
|
|
3252
|
+
/**
|
|
3253
|
+
* Get Customer Info
|
|
3254
|
+
* Get billing customer information including payment methods on file.
|
|
3255
|
+
*
|
|
3256
|
+
* Returns customer details, payment methods, and whether invoice billing is enabled.
|
|
3257
|
+
*/
|
|
3258
|
+
export const getBillingCustomer = <ThrowOnError extends boolean = false>(options?: Options<GetBillingCustomerData, ThrowOnError>) => {
|
|
3259
|
+
return (options?.client ?? _heyApiClient).get<GetBillingCustomerResponses, unknown, ThrowOnError>({
|
|
3260
|
+
security: [
|
|
3261
|
+
{
|
|
3262
|
+
name: 'X-API-Key',
|
|
3263
|
+
type: 'apiKey'
|
|
3264
|
+
},
|
|
3265
|
+
{
|
|
3266
|
+
scheme: 'bearer',
|
|
3267
|
+
type: 'http'
|
|
3268
|
+
}
|
|
3269
|
+
],
|
|
3270
|
+
url: '/v1/billing/customer',
|
|
3271
|
+
...options
|
|
3272
|
+
});
|
|
3273
|
+
};
|
|
3274
|
+
|
|
3275
|
+
/**
|
|
3276
|
+
* Update Default Payment Method
|
|
3277
|
+
* Update the default payment method for the customer.
|
|
3278
|
+
*
|
|
3279
|
+
* This changes which payment method will be used for future subscription charges.
|
|
3280
|
+
*/
|
|
3281
|
+
export const updatePaymentMethod = <ThrowOnError extends boolean = false>(options: Options<UpdatePaymentMethodData, ThrowOnError>) => {
|
|
3282
|
+
return (options.client ?? _heyApiClient).post<UpdatePaymentMethodResponses, UpdatePaymentMethodErrors, ThrowOnError>({
|
|
3283
|
+
security: [
|
|
3284
|
+
{
|
|
3285
|
+
name: 'X-API-Key',
|
|
3286
|
+
type: 'apiKey'
|
|
3287
|
+
},
|
|
3288
|
+
{
|
|
3289
|
+
scheme: 'bearer',
|
|
3290
|
+
type: 'http'
|
|
3291
|
+
}
|
|
3292
|
+
],
|
|
3293
|
+
url: '/v1/billing/customer/payment-method',
|
|
3294
|
+
...options,
|
|
3295
|
+
headers: {
|
|
3296
|
+
'Content-Type': 'application/json',
|
|
3297
|
+
...options.headers
|
|
3298
|
+
}
|
|
3299
|
+
});
|
|
3300
|
+
};
|
|
3301
|
+
|
|
3302
|
+
/**
|
|
3303
|
+
* List Invoices
|
|
3304
|
+
* List payment history and invoices.
|
|
3305
|
+
*
|
|
3306
|
+
* Returns past invoices with payment status, amounts, and line items.
|
|
3307
|
+
*/
|
|
3308
|
+
export const listInvoices = <ThrowOnError extends boolean = false>(options?: Options<ListInvoicesData, ThrowOnError>) => {
|
|
3309
|
+
return (options?.client ?? _heyApiClient).get<ListInvoicesResponses, ListInvoicesErrors, ThrowOnError>({
|
|
3310
|
+
security: [
|
|
3311
|
+
{
|
|
3312
|
+
name: 'X-API-Key',
|
|
3313
|
+
type: 'apiKey'
|
|
3314
|
+
},
|
|
3315
|
+
{
|
|
3316
|
+
scheme: 'bearer',
|
|
3317
|
+
type: 'http'
|
|
3318
|
+
}
|
|
3319
|
+
],
|
|
3320
|
+
url: '/v1/billing/invoices',
|
|
3321
|
+
...options
|
|
3322
|
+
});
|
|
3323
|
+
};
|
|
3324
|
+
|
|
3325
|
+
/**
|
|
3326
|
+
* Get Upcoming Invoice
|
|
3327
|
+
* Get preview of the next invoice.
|
|
3328
|
+
*
|
|
3329
|
+
* Returns estimated charges for the next billing period.
|
|
3330
|
+
*/
|
|
3331
|
+
export const getUpcomingInvoice = <ThrowOnError extends boolean = false>(options?: Options<GetUpcomingInvoiceData, ThrowOnError>) => {
|
|
3332
|
+
return (options?.client ?? _heyApiClient).get<GetUpcomingInvoiceResponses, unknown, ThrowOnError>({
|
|
3333
|
+
security: [
|
|
3334
|
+
{
|
|
3335
|
+
name: 'X-API-Key',
|
|
3336
|
+
type: 'apiKey'
|
|
3337
|
+
},
|
|
3338
|
+
{
|
|
3339
|
+
scheme: 'bearer',
|
|
3340
|
+
type: 'http'
|
|
3341
|
+
}
|
|
3342
|
+
],
|
|
3343
|
+
url: '/v1/billing/invoices/upcoming',
|
|
3344
|
+
...options
|
|
3345
|
+
});
|
|
3346
|
+
};
|
|
3347
|
+
|
|
3348
|
+
/**
|
|
3349
|
+
* List All Subscriptions
|
|
3350
|
+
* List all active and past subscriptions for the user.
|
|
3351
|
+
*
|
|
3352
|
+
* Includes both graph and repository subscriptions with their status, pricing, and billing information.
|
|
3353
|
+
*/
|
|
3354
|
+
export const listSubscriptions = <ThrowOnError extends boolean = false>(options?: Options<ListSubscriptionsData, ThrowOnError>) => {
|
|
3355
|
+
return (options?.client ?? _heyApiClient).get<ListSubscriptionsResponses, unknown, ThrowOnError>({
|
|
3356
|
+
security: [
|
|
3357
|
+
{
|
|
3358
|
+
name: 'X-API-Key',
|
|
3359
|
+
type: 'apiKey'
|
|
3360
|
+
},
|
|
3361
|
+
{
|
|
3362
|
+
scheme: 'bearer',
|
|
3363
|
+
type: 'http'
|
|
3364
|
+
}
|
|
3365
|
+
],
|
|
3366
|
+
url: '/v1/billing/subscriptions',
|
|
3367
|
+
...options
|
|
3368
|
+
});
|
|
3369
|
+
};
|
|
3370
|
+
|
|
3371
|
+
/**
|
|
3372
|
+
* Get Subscription Details
|
|
3373
|
+
* Get detailed information about a specific subscription.
|
|
3374
|
+
*/
|
|
3375
|
+
export const getSubscription = <ThrowOnError extends boolean = false>(options: Options<GetSubscriptionData, ThrowOnError>) => {
|
|
3376
|
+
return (options.client ?? _heyApiClient).get<GetSubscriptionResponses, GetSubscriptionErrors, ThrowOnError>({
|
|
3377
|
+
security: [
|
|
3378
|
+
{
|
|
3379
|
+
name: 'X-API-Key',
|
|
3380
|
+
type: 'apiKey'
|
|
3381
|
+
},
|
|
3382
|
+
{
|
|
3383
|
+
scheme: 'bearer',
|
|
3384
|
+
type: 'http'
|
|
3385
|
+
}
|
|
3386
|
+
],
|
|
3387
|
+
url: '/v1/billing/subscriptions/{subscription_id}',
|
|
3388
|
+
...options
|
|
3389
|
+
});
|
|
3390
|
+
};
|
|
3391
|
+
|
|
3392
|
+
/**
|
|
3393
|
+
* Cancel Subscription
|
|
3394
|
+
* Cancel a subscription.
|
|
3395
|
+
*
|
|
3396
|
+
* The subscription will remain active until the end of the current billing period.
|
|
3397
|
+
*/
|
|
3398
|
+
export const cancelSubscription2 = <ThrowOnError extends boolean = false>(options: Options<CancelSubscription2Data, ThrowOnError>) => {
|
|
3399
|
+
return (options.client ?? _heyApiClient).post<CancelSubscription2Responses, CancelSubscription2Errors, ThrowOnError>({
|
|
3400
|
+
security: [
|
|
3401
|
+
{
|
|
3402
|
+
name: 'X-API-Key',
|
|
3403
|
+
type: 'apiKey'
|
|
3404
|
+
},
|
|
3405
|
+
{
|
|
3406
|
+
scheme: 'bearer',
|
|
3407
|
+
type: 'http'
|
|
3408
|
+
}
|
|
3409
|
+
],
|
|
3410
|
+
url: '/v1/billing/subscriptions/{subscription_id}/cancel',
|
|
3411
|
+
...options
|
|
3412
|
+
});
|
|
3177
3413
|
};
|