@livechat/developer-studio-api 2.3.41 → 2.3.42

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/dist/index.d.mts CHANGED
@@ -1,7 +1,10 @@
1
- import * as openai_resources_beta_threads_messages_messages from 'openai/resources/beta/threads/messages/messages';
2
1
  import * as axios from 'axios';
3
2
  import { AxiosRequestConfig } from 'axios';
4
3
 
4
+ interface NeonClientInstanceAuthorization {
5
+ token?: string;
6
+ }
7
+
5
8
  interface AppEventDto {
6
9
  name: string;
7
10
  aggregateName: string;
@@ -574,6 +577,54 @@ type GetVercelProjectsResult = VercelPaginatedResult & {
574
577
  projects: VercelProject[];
575
578
  };
576
579
 
580
+ interface NeonProjectDto {
581
+ project: {
582
+ id: string;
583
+ name: string;
584
+ created_at: string;
585
+ updated_at: string;
586
+ owner_id: string;
587
+ owner: {
588
+ email: string;
589
+ branches_limit: number;
590
+ subscription: "UNKNOWN" | "free" | "pro" | "direct_sales" | "aws_marketplace";
591
+ };
592
+ };
593
+ }
594
+ interface NeonProjectWithConnectionUriDto extends NeonProjectDto {
595
+ connection_uri: string;
596
+ branch: NeonProjectBranchDto[];
597
+ databases: NeonProjectDatabaseDto[];
598
+ }
599
+
600
+ interface NeonProjectBranchDto {
601
+ id: string;
602
+ project_id: string;
603
+ name: string;
604
+ current_state: "init" | "ready";
605
+ creation_source: string;
606
+ primary: boolean;
607
+ created_at: string;
608
+ updated_at: string;
609
+ }
610
+ interface NeonProjectDatabaseDto {
611
+ id: number;
612
+ branch_id: string;
613
+ name: string;
614
+ owner_name: string;
615
+ created_at: string;
616
+ updated_at: string;
617
+ }
618
+
619
+ interface NeonUser {
620
+ id: string;
621
+ type: string;
622
+ name: string;
623
+ email: string;
624
+ display_name: string;
625
+ default_organization_id: string;
626
+ }
627
+
577
628
  interface AccountDto {
578
629
  account_id: string;
579
630
  avatar: string;
@@ -1226,10 +1277,6 @@ interface CreateMonetizationPayload {
1226
1277
  payment: AddAppMonetizationData;
1227
1278
  }
1228
1279
 
1229
- interface AiAssistantRequest {
1230
- prompt: string;
1231
- }
1232
-
1233
1280
  interface PlatformAdapterClientInstanceAuthorization {
1234
1281
  platform?: {
1235
1282
  dps?: string;
@@ -1242,7 +1289,6 @@ interface PlatformAdapterClientInstanceAuthorization {
1242
1289
  vercel?: string;
1243
1290
  planetscale?: string;
1244
1291
  sentry?: string;
1245
- openai?: string;
1246
1292
  }
1247
1293
  type PlatformAdapterClientInstanceOptions = PlatformAdapterClientInstanceAuthorization & {
1248
1294
  ensureAuthorizationToken?: {
@@ -1254,7 +1300,6 @@ type PlatformAdapterClientInstanceOptions = PlatformAdapterClientInstanceAuthori
1254
1300
  vercel?: boolean;
1255
1301
  planetscale?: boolean;
1256
1302
  sentry?: boolean;
1257
- openai?: boolean;
1258
1303
  };
1259
1304
  };
1260
1305
  declare function getPlatformAdapterClientAuthorization(req: {
@@ -1274,7 +1319,6 @@ declare function initPlatformAdapterClientInstance(baseUrl?: string, tokens?: {
1274
1319
  vercel?: string;
1275
1320
  planetscale?: string;
1276
1321
  sentry?: string;
1277
- openai?: string;
1278
1322
  }): void;
1279
1323
  declare function updatePlatformAdapterClientInstance(tokens?: {
1280
1324
  platform?: {
@@ -1288,7 +1332,6 @@ declare function updatePlatformAdapterClientInstance(tokens?: {
1288
1332
  vercel?: string;
1289
1333
  planetscale?: string;
1290
1334
  sentry?: string;
1291
- openai?: string;
1292
1335
  }): void;
1293
1336
 
1294
1337
  interface ApplicationPaymentDto {
@@ -2203,9 +2246,6 @@ declare const api: {
2203
2246
  conductor: {
2204
2247
  request<TData>(config: axios.AxiosRequestConfig, authorization?: PlatformAdapterClientInstanceAuthorization | undefined): Promise<TData>;
2205
2248
  };
2206
- assistant: {
2207
- request(request: AiAssistantRequest, authorization?: PlatformAdapterClientInstanceAuthorization | undefined): Promise<openai_resources_beta_threads_messages_messages.ThreadMessage[]>;
2208
- };
2209
2249
  };
2210
2250
  dps: {
2211
2251
  applications: {
@@ -2528,6 +2568,20 @@ declare const api: {
2528
2568
  teamId: string;
2529
2569
  }>;
2530
2570
  };
2571
+ neon: {
2572
+ project: {
2573
+ branch: {
2574
+ getBranch(projectId: string, branchId: string, authorization?: NeonClientInstanceAuthorization | undefined): Promise<NeonProjectBranchDto>;
2575
+ };
2576
+ createProject(projectName: string, authorization?: NeonClientInstanceAuthorization | undefined): Promise<NeonProjectWithConnectionUriDto>;
2577
+ getProject(projectId: string, authorization?: NeonClientInstanceAuthorization | undefined): Promise<NeonProjectDto>;
2578
+ deleteProject(projectId: string, authorization?: NeonClientInstanceAuthorization | undefined): Promise<NeonProjectDto>;
2579
+ };
2580
+ user: {
2581
+ getUser(authorization?: NeonClientInstanceAuthorization | undefined): Promise<NeonUser>;
2582
+ };
2583
+ getToken(code: string, clientId: string, clientSecret: string, redirectUri: string): Promise<string>;
2584
+ };
2531
2585
  planetscale: {
2532
2586
  database: {
2533
2587
  password: {
@@ -2657,7 +2711,7 @@ declare const API_NOTIFICATIONS: {
2657
2711
  };
2658
2712
  };
2659
2713
 
2660
- type UnauthorizeApiErrorSource = "dps" | "github" | "vercel" | "netlify" | "sentry" | "planetscale" | "openai";
2714
+ type UnauthorizeApiErrorSource = "dps" | "github" | "vercel" | "netlify" | "sentry" | "neon" | "planetscale";
2661
2715
  interface ApiError {
2662
2716
  message: string;
2663
2717
  }
@@ -2671,4 +2725,4 @@ declare const serializerBase64: {
2671
2725
  deserialize<T_1>(message?: string): T_1 | undefined;
2672
2726
  };
2673
2727
 
2674
- export { API_NOTIFICATIONS, AccountDto, AddAppAuthorizationData, AddAppAuthorizationPayload, AddAppAuthorizationResult, AddAppMonetizationData, AddAppPropertiesData, AddAppWidgetsData, AgentDto, AiAssistantRequest, ApiError, AppDeployment, AppDeploymentBlock, AppDeploymentMode, AppDeploymentProvider, AppGitHubRepository, AppGitHubRepositoryConfig, AppGitLabRepository, AppInfrastructureBlocks, AppLoggerBlock, AppLoggerProvider, AppMonitoringCustomReport, AppMonitoringCustomReportDataDto, AppMonitoringEvent, AppMonitoringEventData, AppMonitoringEventsLog, AppMonitoringEventsLogItem, AppMonitoringEventsReportDto, AppMonitoringReportParams, AppMonitoringUptimeReportDto, AppNetlifyDeployment, AppNetlifyDeploymentConfig, AppPlanetScaleStorage, AppPlanetScaleStorageConfig, AppRepository, AppRepositoryBlock, AppRepositoryProvider, AppRepositoryTarget, AppResourceDto, AppSentryLogger, AppSentryLoggerConfig, AppStorage, AppStorageBlock, AppStorageProvider, AppVariable, AppVariableExternalProvider, AppVariableLocalProvider, AppVariableProvider, AppVariableStatus, AppVariableType, AppVercelDeployment, AppVercelDeploymentConfig, AppVercelStorage, AppVercelStorageConfig, ApplicationAutoReviewDto, ApplicationAutoReviewPayload, ApplicationBasicDetailsDto, ApplicationBenefitDto, ApplicationDto, ApplicationFeatureDto, ApplicationIconDto, ApplicationOverviewDto, ApplicationPaymentDto, ApplicationPropertyDto, ApplicationScreenshotDto, ApplicationTutorialAndSupportDto, ApplicationUsageOptionsDto, AuthorizeData, BillingAccountDto, BillingAccountInfoDto, BillingInvoiceDto, Category, ClientDto, ClientInfoDto, ClientScopeDto, ClientWithSecretDto, CreateAppOutput, CreateAppPayload, CreateAppResult, CreateAppStatus, CreateAppStepStatus, CreateApplicationAuthorizationPayload, CreateApplicationChatActionPayload, CreateApplicationPayload, CreateApplicationResponse, CreateApplicationSubmissionPayload, CreateAuthorizationPayload, CreateAuthorizationResponse, CreateClientPayload, CreateCreatorAppPayload, CreateCreatorAppResponse, CreateDeploymentAccessibilityPayload, CreateDeploymentAccessibilityResponse, CreateDeploymentPayload, CreateDeploymentResponse, CreateMonetizationPayload, CreatePropertiesPayload, CreateRepositoryPayload, CreateRepositoryResponse, CreateSeedPayload, CreateSeedResponse, CreateWidgetPayload, DeveloperLedgerParams, GetAppMonitoringCustomReportDataPayload, GetAppMonitoringEventsLogPayload, GetAppMonitoringEventsLogResponse, GetAppMonitoringEventsReportPayload, GetAppMonitoringUptimeReportPayload, GetPlanetScaleDatabasePasswordsResult, GetPlanetScaleDatabasesResult, GetPlanetScaleOrganizationsResult, GetTextPlatformDashboardReportParams, GetVercelProjectsResult, GitHubInstallation, GitHubRepository, GitHubRepositoryBranch, GitHubRepositoryHook, GitHubRepositoryKey, GitHubRepositorySeed, GithubClientInstanceAuthorization, GithubClientRequestOptions, LinkAppDeploymentData, LinkAppDeploymentNetlifyData, LinkAppDeploymentNetlifySiteData, LinkAppDeploymentPayload, LinkAppDeploymentResult, LinkAppDeploymentVercelData, LinkAppDeploymentVercelProjectData, LinkAppRepositoryData, LinkAppRepositoryGitHubData, LinkAppRepositoryGitLabData, LinkAppRepositoryPayload, LinkAppRepositoryResult, LinkAppSentryLoggerPayload, LinkAppStorageData, LinkAppStoragePayload, LinkAppStoragePlanetScaleData, LinkAppStoragePlanetScaleDatabaseData, LinkAppStorageVercelData, LiveChatClientInstanceAuthorization, LiveChatClientInstanceOptions, MyAccountDto, NetlifyAccount, NetlifyClientInstanceAuthorization, NetlifyClientInstanceOptions, NetlifyDeploy, NetlifyDeployKey, NetlifyEnv, NetlifySite, OrganizationDto, PatDto, PatScopeDto, PatWithSecretDto, PlanetScaleClientInstanceAuthorization, PlanetScaleClientInstanceOptions, PlanetScaleDatabase, PlanetScaleDatabasePassword, PlanetScaleOrganization, PlanetScalePaginatedResult, PlanetScalePagination, PlanetScaleUser, PlatformAccountsClientInstanceAuthorization, PlatformAccountsClientInstanceOptions, PlatformAdapterClientInstanceAuthorization, PlatformAdapterClientInstanceOptions, PlatformBillingClientInstanceAuthorization, PlatformBillingClientInstanceOptions, PlatformDpsClientInstanceAuthorization, PlatformDpsClientInstanceOptions, ProductDto, PropertiesDto, Property, PropertyAccessDto, PropertyAccessItemDto, PropertyDto, ResearchCustomerItemDto, ResearchCustomerLocationItemDto, ResearchDictionaryParams, ResearchMarketplaceItemDto, ResearchMarketplaceParams, ResearchTrafficItemDto, ResearchTrafficParams, ScopeDto, SeedAppRepositoryPayload, SeedAppRepositoryResult, SentryClientInstanceAuthorization, SentryClientInstanceOptions, SentryIntegration, SentryOrganization, SentryProject, SentryProjectIssue, SentryProjectIssueEvent, SentryProjectKey, SentryRepository, SentryTeam, ShortcutDto, SyncAppVariablePayload, TextClientInstanceAuthorization, TextClientInstanceOptions, TextPlatformDashboardCreditsDto, TextPlatformDashboardPaymentDto, TextPlatformDashboardReportDto, TextPlatformDashboardReportItemDto, UnauthorizeApiError, UnauthorizeApiErrorSource, UnlinkAppDeploymentPayload, UnlinkAppRepositoryPayload, UnlinkAppSentryLoggerPayload, UnlinkAppStoragePayload, UpdateAppInfrastructureBlocksPayload, UpdateApplicationChangelogPayload, UpdateApplicationChatActionPayload, UpdateApplicationDirectInstallUrlPayload, UpdateApplicationIconPayload, UpdateApplicationOnboardingPayload, UpdateApplicationProductPayload, UpdateApplicationWebhookPayload, UpdateApplicationWidgetDto, UpdateChatWebhookPayload, UpdateClientPayload, UpdateUserFeatures, UpdateUserIntegrations, UpsertAppResourcePayload, UpsertApplicationChatBoosterPayload, UserDto, UserGitHubIntegrationDto, UserIntegrationsDto, UserNetlifyIntegrationDto, UserPlanetScaleIntegrationDto, UserSentryIntegrationDto, UserVercelIntegrationDto, VercelClientInstanceAuthorization, VercelClientInstanceOptions, VercelDeploy, VercelNamespace, VercelPaginatedResult, VercelPagination, VercelProject, VercelProjectEnv, VercelRepository, VercelSearchRepositoryResponse, Webhook, WebhookDto, api, getAppAutoReviewPayload, getEmptyAppAutoReview, getGitHubClientAuthorization, getGithubClientRequestConfig, getLiveChatClientAuthorization, getLiveChatClientConfig, getNetlifyClientAuthorization, getNetlifyClientConfig, getPlanetScaleClientAuthorization, getPlanetScaleClientConfig, getPlatformAccountsClientAuthorization, getPlatformAccountsClientConfig, getPlatformAdapterClientAuthorization, getPlatformAdapterClientConfig, getPlatformBillingClientAuthorization, getPlatformBillingClientConfig, getPlatformDpsAdminClientAuthorization, getPlatformDpsClientAuthorization, getPlatformDpsClientConfig, getRegion, getSentryClientAuthorization, getSentryClientConfig, getTextClientAuthorization, getTextClientConfig, getVercelClientAuthorization, getVercelClientConfig, githubClientInstance, initApi, initGithubClientInstance, initLiveChatClientInstance, initNetlifyClientInstance, initPlanetScaleClientInstance, initPlatformAccountsClientInstance, initPlatformAdapterClientInstance, initPlatformBillingClientInstance, initPlatformDpsClientInstance, initSentryClientInstance, initTextClientInstance, initVercelClientInstance, livechatClientInstance, netlifyClientInstance, planetScaleClientInstance, platformAccountsClientInstance, platformAdapterClientInstance, platformBillingClientInstance, platformDpsClientInstance, sentryClientInstance, serializerBase64, textClientInstance, updateGithubClientInstance, updateNetlifyClientInstance, updatePlanetScaleClientInstance, updatePlatformAdapterClientInstance, updateSentryClientInstance, updateVercelClientInstance, vercelClientInstance };
2728
+ export { API_NOTIFICATIONS, AccountDto, AddAppAuthorizationData, AddAppAuthorizationPayload, AddAppAuthorizationResult, AddAppMonetizationData, AddAppPropertiesData, AddAppWidgetsData, AgentDto, ApiError, AppDeployment, AppDeploymentBlock, AppDeploymentMode, AppDeploymentProvider, AppGitHubRepository, AppGitHubRepositoryConfig, AppGitLabRepository, AppInfrastructureBlocks, AppLoggerBlock, AppLoggerProvider, AppMonitoringCustomReport, AppMonitoringCustomReportDataDto, AppMonitoringEvent, AppMonitoringEventData, AppMonitoringEventsLog, AppMonitoringEventsLogItem, AppMonitoringEventsReportDto, AppMonitoringReportParams, AppMonitoringUptimeReportDto, AppNetlifyDeployment, AppNetlifyDeploymentConfig, AppPlanetScaleStorage, AppPlanetScaleStorageConfig, AppRepository, AppRepositoryBlock, AppRepositoryProvider, AppRepositoryTarget, AppResourceDto, AppSentryLogger, AppSentryLoggerConfig, AppStorage, AppStorageBlock, AppStorageProvider, AppVariable, AppVariableExternalProvider, AppVariableLocalProvider, AppVariableProvider, AppVariableStatus, AppVariableType, AppVercelDeployment, AppVercelDeploymentConfig, AppVercelStorage, AppVercelStorageConfig, ApplicationAutoReviewDto, ApplicationAutoReviewPayload, ApplicationBasicDetailsDto, ApplicationBenefitDto, ApplicationDto, ApplicationFeatureDto, ApplicationIconDto, ApplicationOverviewDto, ApplicationPaymentDto, ApplicationPropertyDto, ApplicationScreenshotDto, ApplicationTutorialAndSupportDto, ApplicationUsageOptionsDto, AuthorizeData, BillingAccountDto, BillingAccountInfoDto, BillingInvoiceDto, Category, ClientDto, ClientInfoDto, ClientScopeDto, ClientWithSecretDto, CreateAppOutput, CreateAppPayload, CreateAppResult, CreateAppStatus, CreateAppStepStatus, CreateApplicationAuthorizationPayload, CreateApplicationChatActionPayload, CreateApplicationPayload, CreateApplicationResponse, CreateApplicationSubmissionPayload, CreateAuthorizationPayload, CreateAuthorizationResponse, CreateClientPayload, CreateCreatorAppPayload, CreateCreatorAppResponse, CreateDeploymentAccessibilityPayload, CreateDeploymentAccessibilityResponse, CreateDeploymentPayload, CreateDeploymentResponse, CreateMonetizationPayload, CreatePropertiesPayload, CreateRepositoryPayload, CreateRepositoryResponse, CreateSeedPayload, CreateSeedResponse, CreateWidgetPayload, DeveloperLedgerParams, GetAppMonitoringCustomReportDataPayload, GetAppMonitoringEventsLogPayload, GetAppMonitoringEventsLogResponse, GetAppMonitoringEventsReportPayload, GetAppMonitoringUptimeReportPayload, GetPlanetScaleDatabasePasswordsResult, GetPlanetScaleDatabasesResult, GetPlanetScaleOrganizationsResult, GetTextPlatformDashboardReportParams, GetVercelProjectsResult, GitHubInstallation, GitHubRepository, GitHubRepositoryBranch, GitHubRepositoryHook, GitHubRepositoryKey, GitHubRepositorySeed, GithubClientInstanceAuthorization, GithubClientRequestOptions, LinkAppDeploymentData, LinkAppDeploymentNetlifyData, LinkAppDeploymentNetlifySiteData, LinkAppDeploymentPayload, LinkAppDeploymentResult, LinkAppDeploymentVercelData, LinkAppDeploymentVercelProjectData, LinkAppRepositoryData, LinkAppRepositoryGitHubData, LinkAppRepositoryGitLabData, LinkAppRepositoryPayload, LinkAppRepositoryResult, LinkAppSentryLoggerPayload, LinkAppStorageData, LinkAppStoragePayload, LinkAppStoragePlanetScaleData, LinkAppStoragePlanetScaleDatabaseData, LinkAppStorageVercelData, LiveChatClientInstanceAuthorization, LiveChatClientInstanceOptions, MyAccountDto, NeonProjectBranchDto, NeonProjectDatabaseDto, NeonProjectDto, NeonProjectWithConnectionUriDto, NeonUser, NetlifyAccount, NetlifyClientInstanceAuthorization, NetlifyClientInstanceOptions, NetlifyDeploy, NetlifyDeployKey, NetlifyEnv, NetlifySite, OrganizationDto, PatDto, PatScopeDto, PatWithSecretDto, PlanetScaleClientInstanceAuthorization, PlanetScaleClientInstanceOptions, PlanetScaleDatabase, PlanetScaleDatabasePassword, PlanetScaleOrganization, PlanetScalePaginatedResult, PlanetScalePagination, PlanetScaleUser, PlatformAccountsClientInstanceAuthorization, PlatformAccountsClientInstanceOptions, PlatformAdapterClientInstanceAuthorization, PlatformAdapterClientInstanceOptions, PlatformBillingClientInstanceAuthorization, PlatformBillingClientInstanceOptions, PlatformDpsClientInstanceAuthorization, PlatformDpsClientInstanceOptions, ProductDto, PropertiesDto, Property, PropertyAccessDto, PropertyAccessItemDto, PropertyDto, ResearchCustomerItemDto, ResearchCustomerLocationItemDto, ResearchDictionaryParams, ResearchMarketplaceItemDto, ResearchMarketplaceParams, ResearchTrafficItemDto, ResearchTrafficParams, ScopeDto, SeedAppRepositoryPayload, SeedAppRepositoryResult, SentryClientInstanceAuthorization, SentryClientInstanceOptions, SentryIntegration, SentryOrganization, SentryProject, SentryProjectIssue, SentryProjectIssueEvent, SentryProjectKey, SentryRepository, SentryTeam, ShortcutDto, SyncAppVariablePayload, TextClientInstanceAuthorization, TextClientInstanceOptions, TextPlatformDashboardCreditsDto, TextPlatformDashboardPaymentDto, TextPlatformDashboardReportDto, TextPlatformDashboardReportItemDto, UnauthorizeApiError, UnauthorizeApiErrorSource, UnlinkAppDeploymentPayload, UnlinkAppRepositoryPayload, UnlinkAppSentryLoggerPayload, UnlinkAppStoragePayload, UpdateAppInfrastructureBlocksPayload, UpdateApplicationChangelogPayload, UpdateApplicationChatActionPayload, UpdateApplicationDirectInstallUrlPayload, UpdateApplicationIconPayload, UpdateApplicationOnboardingPayload, UpdateApplicationProductPayload, UpdateApplicationWebhookPayload, UpdateApplicationWidgetDto, UpdateChatWebhookPayload, UpdateClientPayload, UpdateUserFeatures, UpdateUserIntegrations, UpsertAppResourcePayload, UpsertApplicationChatBoosterPayload, UserDto, UserGitHubIntegrationDto, UserIntegrationsDto, UserNetlifyIntegrationDto, UserPlanetScaleIntegrationDto, UserSentryIntegrationDto, UserVercelIntegrationDto, VercelClientInstanceAuthorization, VercelClientInstanceOptions, VercelDeploy, VercelNamespace, VercelPaginatedResult, VercelPagination, VercelProject, VercelProjectEnv, VercelRepository, VercelSearchRepositoryResponse, Webhook, WebhookDto, api, getAppAutoReviewPayload, getEmptyAppAutoReview, getGitHubClientAuthorization, getGithubClientRequestConfig, getLiveChatClientAuthorization, getLiveChatClientConfig, getNetlifyClientAuthorization, getNetlifyClientConfig, getPlanetScaleClientAuthorization, getPlanetScaleClientConfig, getPlatformAccountsClientAuthorization, getPlatformAccountsClientConfig, getPlatformAdapterClientAuthorization, getPlatformAdapterClientConfig, getPlatformBillingClientAuthorization, getPlatformBillingClientConfig, getPlatformDpsAdminClientAuthorization, getPlatformDpsClientAuthorization, getPlatformDpsClientConfig, getRegion, getSentryClientAuthorization, getSentryClientConfig, getTextClientAuthorization, getTextClientConfig, getVercelClientAuthorization, getVercelClientConfig, githubClientInstance, initApi, initGithubClientInstance, initLiveChatClientInstance, initNetlifyClientInstance, initPlanetScaleClientInstance, initPlatformAccountsClientInstance, initPlatformAdapterClientInstance, initPlatformBillingClientInstance, initPlatformDpsClientInstance, initSentryClientInstance, initTextClientInstance, initVercelClientInstance, livechatClientInstance, netlifyClientInstance, planetScaleClientInstance, platformAccountsClientInstance, platformAdapterClientInstance, platformBillingClientInstance, platformDpsClientInstance, sentryClientInstance, serializerBase64, textClientInstance, updateGithubClientInstance, updateNetlifyClientInstance, updatePlanetScaleClientInstance, updatePlatformAdapterClientInstance, updateSentryClientInstance, updateVercelClientInstance, vercelClientInstance };
package/dist/index.d.ts CHANGED
@@ -1,7 +1,10 @@
1
- import * as openai_resources_beta_threads_messages_messages from 'openai/resources/beta/threads/messages/messages';
2
1
  import * as axios from 'axios';
3
2
  import { AxiosRequestConfig } from 'axios';
4
3
 
4
+ interface NeonClientInstanceAuthorization {
5
+ token?: string;
6
+ }
7
+
5
8
  interface AppEventDto {
6
9
  name: string;
7
10
  aggregateName: string;
@@ -574,6 +577,54 @@ type GetVercelProjectsResult = VercelPaginatedResult & {
574
577
  projects: VercelProject[];
575
578
  };
576
579
 
580
+ interface NeonProjectDto {
581
+ project: {
582
+ id: string;
583
+ name: string;
584
+ created_at: string;
585
+ updated_at: string;
586
+ owner_id: string;
587
+ owner: {
588
+ email: string;
589
+ branches_limit: number;
590
+ subscription: "UNKNOWN" | "free" | "pro" | "direct_sales" | "aws_marketplace";
591
+ };
592
+ };
593
+ }
594
+ interface NeonProjectWithConnectionUriDto extends NeonProjectDto {
595
+ connection_uri: string;
596
+ branch: NeonProjectBranchDto[];
597
+ databases: NeonProjectDatabaseDto[];
598
+ }
599
+
600
+ interface NeonProjectBranchDto {
601
+ id: string;
602
+ project_id: string;
603
+ name: string;
604
+ current_state: "init" | "ready";
605
+ creation_source: string;
606
+ primary: boolean;
607
+ created_at: string;
608
+ updated_at: string;
609
+ }
610
+ interface NeonProjectDatabaseDto {
611
+ id: number;
612
+ branch_id: string;
613
+ name: string;
614
+ owner_name: string;
615
+ created_at: string;
616
+ updated_at: string;
617
+ }
618
+
619
+ interface NeonUser {
620
+ id: string;
621
+ type: string;
622
+ name: string;
623
+ email: string;
624
+ display_name: string;
625
+ default_organization_id: string;
626
+ }
627
+
577
628
  interface AccountDto {
578
629
  account_id: string;
579
630
  avatar: string;
@@ -1226,10 +1277,6 @@ interface CreateMonetizationPayload {
1226
1277
  payment: AddAppMonetizationData;
1227
1278
  }
1228
1279
 
1229
- interface AiAssistantRequest {
1230
- prompt: string;
1231
- }
1232
-
1233
1280
  interface PlatformAdapterClientInstanceAuthorization {
1234
1281
  platform?: {
1235
1282
  dps?: string;
@@ -1242,7 +1289,6 @@ interface PlatformAdapterClientInstanceAuthorization {
1242
1289
  vercel?: string;
1243
1290
  planetscale?: string;
1244
1291
  sentry?: string;
1245
- openai?: string;
1246
1292
  }
1247
1293
  type PlatformAdapterClientInstanceOptions = PlatformAdapterClientInstanceAuthorization & {
1248
1294
  ensureAuthorizationToken?: {
@@ -1254,7 +1300,6 @@ type PlatformAdapterClientInstanceOptions = PlatformAdapterClientInstanceAuthori
1254
1300
  vercel?: boolean;
1255
1301
  planetscale?: boolean;
1256
1302
  sentry?: boolean;
1257
- openai?: boolean;
1258
1303
  };
1259
1304
  };
1260
1305
  declare function getPlatformAdapterClientAuthorization(req: {
@@ -1274,7 +1319,6 @@ declare function initPlatformAdapterClientInstance(baseUrl?: string, tokens?: {
1274
1319
  vercel?: string;
1275
1320
  planetscale?: string;
1276
1321
  sentry?: string;
1277
- openai?: string;
1278
1322
  }): void;
1279
1323
  declare function updatePlatformAdapterClientInstance(tokens?: {
1280
1324
  platform?: {
@@ -1288,7 +1332,6 @@ declare function updatePlatformAdapterClientInstance(tokens?: {
1288
1332
  vercel?: string;
1289
1333
  planetscale?: string;
1290
1334
  sentry?: string;
1291
- openai?: string;
1292
1335
  }): void;
1293
1336
 
1294
1337
  interface ApplicationPaymentDto {
@@ -2203,9 +2246,6 @@ declare const api: {
2203
2246
  conductor: {
2204
2247
  request<TData>(config: axios.AxiosRequestConfig, authorization?: PlatformAdapterClientInstanceAuthorization | undefined): Promise<TData>;
2205
2248
  };
2206
- assistant: {
2207
- request(request: AiAssistantRequest, authorization?: PlatformAdapterClientInstanceAuthorization | undefined): Promise<openai_resources_beta_threads_messages_messages.ThreadMessage[]>;
2208
- };
2209
2249
  };
2210
2250
  dps: {
2211
2251
  applications: {
@@ -2528,6 +2568,20 @@ declare const api: {
2528
2568
  teamId: string;
2529
2569
  }>;
2530
2570
  };
2571
+ neon: {
2572
+ project: {
2573
+ branch: {
2574
+ getBranch(projectId: string, branchId: string, authorization?: NeonClientInstanceAuthorization | undefined): Promise<NeonProjectBranchDto>;
2575
+ };
2576
+ createProject(projectName: string, authorization?: NeonClientInstanceAuthorization | undefined): Promise<NeonProjectWithConnectionUriDto>;
2577
+ getProject(projectId: string, authorization?: NeonClientInstanceAuthorization | undefined): Promise<NeonProjectDto>;
2578
+ deleteProject(projectId: string, authorization?: NeonClientInstanceAuthorization | undefined): Promise<NeonProjectDto>;
2579
+ };
2580
+ user: {
2581
+ getUser(authorization?: NeonClientInstanceAuthorization | undefined): Promise<NeonUser>;
2582
+ };
2583
+ getToken(code: string, clientId: string, clientSecret: string, redirectUri: string): Promise<string>;
2584
+ };
2531
2585
  planetscale: {
2532
2586
  database: {
2533
2587
  password: {
@@ -2657,7 +2711,7 @@ declare const API_NOTIFICATIONS: {
2657
2711
  };
2658
2712
  };
2659
2713
 
2660
- type UnauthorizeApiErrorSource = "dps" | "github" | "vercel" | "netlify" | "sentry" | "planetscale" | "openai";
2714
+ type UnauthorizeApiErrorSource = "dps" | "github" | "vercel" | "netlify" | "sentry" | "neon" | "planetscale";
2661
2715
  interface ApiError {
2662
2716
  message: string;
2663
2717
  }
@@ -2671,4 +2725,4 @@ declare const serializerBase64: {
2671
2725
  deserialize<T_1>(message?: string): T_1 | undefined;
2672
2726
  };
2673
2727
 
2674
- export { API_NOTIFICATIONS, AccountDto, AddAppAuthorizationData, AddAppAuthorizationPayload, AddAppAuthorizationResult, AddAppMonetizationData, AddAppPropertiesData, AddAppWidgetsData, AgentDto, AiAssistantRequest, ApiError, AppDeployment, AppDeploymentBlock, AppDeploymentMode, AppDeploymentProvider, AppGitHubRepository, AppGitHubRepositoryConfig, AppGitLabRepository, AppInfrastructureBlocks, AppLoggerBlock, AppLoggerProvider, AppMonitoringCustomReport, AppMonitoringCustomReportDataDto, AppMonitoringEvent, AppMonitoringEventData, AppMonitoringEventsLog, AppMonitoringEventsLogItem, AppMonitoringEventsReportDto, AppMonitoringReportParams, AppMonitoringUptimeReportDto, AppNetlifyDeployment, AppNetlifyDeploymentConfig, AppPlanetScaleStorage, AppPlanetScaleStorageConfig, AppRepository, AppRepositoryBlock, AppRepositoryProvider, AppRepositoryTarget, AppResourceDto, AppSentryLogger, AppSentryLoggerConfig, AppStorage, AppStorageBlock, AppStorageProvider, AppVariable, AppVariableExternalProvider, AppVariableLocalProvider, AppVariableProvider, AppVariableStatus, AppVariableType, AppVercelDeployment, AppVercelDeploymentConfig, AppVercelStorage, AppVercelStorageConfig, ApplicationAutoReviewDto, ApplicationAutoReviewPayload, ApplicationBasicDetailsDto, ApplicationBenefitDto, ApplicationDto, ApplicationFeatureDto, ApplicationIconDto, ApplicationOverviewDto, ApplicationPaymentDto, ApplicationPropertyDto, ApplicationScreenshotDto, ApplicationTutorialAndSupportDto, ApplicationUsageOptionsDto, AuthorizeData, BillingAccountDto, BillingAccountInfoDto, BillingInvoiceDto, Category, ClientDto, ClientInfoDto, ClientScopeDto, ClientWithSecretDto, CreateAppOutput, CreateAppPayload, CreateAppResult, CreateAppStatus, CreateAppStepStatus, CreateApplicationAuthorizationPayload, CreateApplicationChatActionPayload, CreateApplicationPayload, CreateApplicationResponse, CreateApplicationSubmissionPayload, CreateAuthorizationPayload, CreateAuthorizationResponse, CreateClientPayload, CreateCreatorAppPayload, CreateCreatorAppResponse, CreateDeploymentAccessibilityPayload, CreateDeploymentAccessibilityResponse, CreateDeploymentPayload, CreateDeploymentResponse, CreateMonetizationPayload, CreatePropertiesPayload, CreateRepositoryPayload, CreateRepositoryResponse, CreateSeedPayload, CreateSeedResponse, CreateWidgetPayload, DeveloperLedgerParams, GetAppMonitoringCustomReportDataPayload, GetAppMonitoringEventsLogPayload, GetAppMonitoringEventsLogResponse, GetAppMonitoringEventsReportPayload, GetAppMonitoringUptimeReportPayload, GetPlanetScaleDatabasePasswordsResult, GetPlanetScaleDatabasesResult, GetPlanetScaleOrganizationsResult, GetTextPlatformDashboardReportParams, GetVercelProjectsResult, GitHubInstallation, GitHubRepository, GitHubRepositoryBranch, GitHubRepositoryHook, GitHubRepositoryKey, GitHubRepositorySeed, GithubClientInstanceAuthorization, GithubClientRequestOptions, LinkAppDeploymentData, LinkAppDeploymentNetlifyData, LinkAppDeploymentNetlifySiteData, LinkAppDeploymentPayload, LinkAppDeploymentResult, LinkAppDeploymentVercelData, LinkAppDeploymentVercelProjectData, LinkAppRepositoryData, LinkAppRepositoryGitHubData, LinkAppRepositoryGitLabData, LinkAppRepositoryPayload, LinkAppRepositoryResult, LinkAppSentryLoggerPayload, LinkAppStorageData, LinkAppStoragePayload, LinkAppStoragePlanetScaleData, LinkAppStoragePlanetScaleDatabaseData, LinkAppStorageVercelData, LiveChatClientInstanceAuthorization, LiveChatClientInstanceOptions, MyAccountDto, NetlifyAccount, NetlifyClientInstanceAuthorization, NetlifyClientInstanceOptions, NetlifyDeploy, NetlifyDeployKey, NetlifyEnv, NetlifySite, OrganizationDto, PatDto, PatScopeDto, PatWithSecretDto, PlanetScaleClientInstanceAuthorization, PlanetScaleClientInstanceOptions, PlanetScaleDatabase, PlanetScaleDatabasePassword, PlanetScaleOrganization, PlanetScalePaginatedResult, PlanetScalePagination, PlanetScaleUser, PlatformAccountsClientInstanceAuthorization, PlatformAccountsClientInstanceOptions, PlatformAdapterClientInstanceAuthorization, PlatformAdapterClientInstanceOptions, PlatformBillingClientInstanceAuthorization, PlatformBillingClientInstanceOptions, PlatformDpsClientInstanceAuthorization, PlatformDpsClientInstanceOptions, ProductDto, PropertiesDto, Property, PropertyAccessDto, PropertyAccessItemDto, PropertyDto, ResearchCustomerItemDto, ResearchCustomerLocationItemDto, ResearchDictionaryParams, ResearchMarketplaceItemDto, ResearchMarketplaceParams, ResearchTrafficItemDto, ResearchTrafficParams, ScopeDto, SeedAppRepositoryPayload, SeedAppRepositoryResult, SentryClientInstanceAuthorization, SentryClientInstanceOptions, SentryIntegration, SentryOrganization, SentryProject, SentryProjectIssue, SentryProjectIssueEvent, SentryProjectKey, SentryRepository, SentryTeam, ShortcutDto, SyncAppVariablePayload, TextClientInstanceAuthorization, TextClientInstanceOptions, TextPlatformDashboardCreditsDto, TextPlatformDashboardPaymentDto, TextPlatformDashboardReportDto, TextPlatformDashboardReportItemDto, UnauthorizeApiError, UnauthorizeApiErrorSource, UnlinkAppDeploymentPayload, UnlinkAppRepositoryPayload, UnlinkAppSentryLoggerPayload, UnlinkAppStoragePayload, UpdateAppInfrastructureBlocksPayload, UpdateApplicationChangelogPayload, UpdateApplicationChatActionPayload, UpdateApplicationDirectInstallUrlPayload, UpdateApplicationIconPayload, UpdateApplicationOnboardingPayload, UpdateApplicationProductPayload, UpdateApplicationWebhookPayload, UpdateApplicationWidgetDto, UpdateChatWebhookPayload, UpdateClientPayload, UpdateUserFeatures, UpdateUserIntegrations, UpsertAppResourcePayload, UpsertApplicationChatBoosterPayload, UserDto, UserGitHubIntegrationDto, UserIntegrationsDto, UserNetlifyIntegrationDto, UserPlanetScaleIntegrationDto, UserSentryIntegrationDto, UserVercelIntegrationDto, VercelClientInstanceAuthorization, VercelClientInstanceOptions, VercelDeploy, VercelNamespace, VercelPaginatedResult, VercelPagination, VercelProject, VercelProjectEnv, VercelRepository, VercelSearchRepositoryResponse, Webhook, WebhookDto, api, getAppAutoReviewPayload, getEmptyAppAutoReview, getGitHubClientAuthorization, getGithubClientRequestConfig, getLiveChatClientAuthorization, getLiveChatClientConfig, getNetlifyClientAuthorization, getNetlifyClientConfig, getPlanetScaleClientAuthorization, getPlanetScaleClientConfig, getPlatformAccountsClientAuthorization, getPlatformAccountsClientConfig, getPlatformAdapterClientAuthorization, getPlatformAdapterClientConfig, getPlatformBillingClientAuthorization, getPlatformBillingClientConfig, getPlatformDpsAdminClientAuthorization, getPlatformDpsClientAuthorization, getPlatformDpsClientConfig, getRegion, getSentryClientAuthorization, getSentryClientConfig, getTextClientAuthorization, getTextClientConfig, getVercelClientAuthorization, getVercelClientConfig, githubClientInstance, initApi, initGithubClientInstance, initLiveChatClientInstance, initNetlifyClientInstance, initPlanetScaleClientInstance, initPlatformAccountsClientInstance, initPlatformAdapterClientInstance, initPlatformBillingClientInstance, initPlatformDpsClientInstance, initSentryClientInstance, initTextClientInstance, initVercelClientInstance, livechatClientInstance, netlifyClientInstance, planetScaleClientInstance, platformAccountsClientInstance, platformAdapterClientInstance, platformBillingClientInstance, platformDpsClientInstance, sentryClientInstance, serializerBase64, textClientInstance, updateGithubClientInstance, updateNetlifyClientInstance, updatePlanetScaleClientInstance, updatePlatformAdapterClientInstance, updateSentryClientInstance, updateVercelClientInstance, vercelClientInstance };
2728
+ export { API_NOTIFICATIONS, AccountDto, AddAppAuthorizationData, AddAppAuthorizationPayload, AddAppAuthorizationResult, AddAppMonetizationData, AddAppPropertiesData, AddAppWidgetsData, AgentDto, ApiError, AppDeployment, AppDeploymentBlock, AppDeploymentMode, AppDeploymentProvider, AppGitHubRepository, AppGitHubRepositoryConfig, AppGitLabRepository, AppInfrastructureBlocks, AppLoggerBlock, AppLoggerProvider, AppMonitoringCustomReport, AppMonitoringCustomReportDataDto, AppMonitoringEvent, AppMonitoringEventData, AppMonitoringEventsLog, AppMonitoringEventsLogItem, AppMonitoringEventsReportDto, AppMonitoringReportParams, AppMonitoringUptimeReportDto, AppNetlifyDeployment, AppNetlifyDeploymentConfig, AppPlanetScaleStorage, AppPlanetScaleStorageConfig, AppRepository, AppRepositoryBlock, AppRepositoryProvider, AppRepositoryTarget, AppResourceDto, AppSentryLogger, AppSentryLoggerConfig, AppStorage, AppStorageBlock, AppStorageProvider, AppVariable, AppVariableExternalProvider, AppVariableLocalProvider, AppVariableProvider, AppVariableStatus, AppVariableType, AppVercelDeployment, AppVercelDeploymentConfig, AppVercelStorage, AppVercelStorageConfig, ApplicationAutoReviewDto, ApplicationAutoReviewPayload, ApplicationBasicDetailsDto, ApplicationBenefitDto, ApplicationDto, ApplicationFeatureDto, ApplicationIconDto, ApplicationOverviewDto, ApplicationPaymentDto, ApplicationPropertyDto, ApplicationScreenshotDto, ApplicationTutorialAndSupportDto, ApplicationUsageOptionsDto, AuthorizeData, BillingAccountDto, BillingAccountInfoDto, BillingInvoiceDto, Category, ClientDto, ClientInfoDto, ClientScopeDto, ClientWithSecretDto, CreateAppOutput, CreateAppPayload, CreateAppResult, CreateAppStatus, CreateAppStepStatus, CreateApplicationAuthorizationPayload, CreateApplicationChatActionPayload, CreateApplicationPayload, CreateApplicationResponse, CreateApplicationSubmissionPayload, CreateAuthorizationPayload, CreateAuthorizationResponse, CreateClientPayload, CreateCreatorAppPayload, CreateCreatorAppResponse, CreateDeploymentAccessibilityPayload, CreateDeploymentAccessibilityResponse, CreateDeploymentPayload, CreateDeploymentResponse, CreateMonetizationPayload, CreatePropertiesPayload, CreateRepositoryPayload, CreateRepositoryResponse, CreateSeedPayload, CreateSeedResponse, CreateWidgetPayload, DeveloperLedgerParams, GetAppMonitoringCustomReportDataPayload, GetAppMonitoringEventsLogPayload, GetAppMonitoringEventsLogResponse, GetAppMonitoringEventsReportPayload, GetAppMonitoringUptimeReportPayload, GetPlanetScaleDatabasePasswordsResult, GetPlanetScaleDatabasesResult, GetPlanetScaleOrganizationsResult, GetTextPlatformDashboardReportParams, GetVercelProjectsResult, GitHubInstallation, GitHubRepository, GitHubRepositoryBranch, GitHubRepositoryHook, GitHubRepositoryKey, GitHubRepositorySeed, GithubClientInstanceAuthorization, GithubClientRequestOptions, LinkAppDeploymentData, LinkAppDeploymentNetlifyData, LinkAppDeploymentNetlifySiteData, LinkAppDeploymentPayload, LinkAppDeploymentResult, LinkAppDeploymentVercelData, LinkAppDeploymentVercelProjectData, LinkAppRepositoryData, LinkAppRepositoryGitHubData, LinkAppRepositoryGitLabData, LinkAppRepositoryPayload, LinkAppRepositoryResult, LinkAppSentryLoggerPayload, LinkAppStorageData, LinkAppStoragePayload, LinkAppStoragePlanetScaleData, LinkAppStoragePlanetScaleDatabaseData, LinkAppStorageVercelData, LiveChatClientInstanceAuthorization, LiveChatClientInstanceOptions, MyAccountDto, NeonProjectBranchDto, NeonProjectDatabaseDto, NeonProjectDto, NeonProjectWithConnectionUriDto, NeonUser, NetlifyAccount, NetlifyClientInstanceAuthorization, NetlifyClientInstanceOptions, NetlifyDeploy, NetlifyDeployKey, NetlifyEnv, NetlifySite, OrganizationDto, PatDto, PatScopeDto, PatWithSecretDto, PlanetScaleClientInstanceAuthorization, PlanetScaleClientInstanceOptions, PlanetScaleDatabase, PlanetScaleDatabasePassword, PlanetScaleOrganization, PlanetScalePaginatedResult, PlanetScalePagination, PlanetScaleUser, PlatformAccountsClientInstanceAuthorization, PlatformAccountsClientInstanceOptions, PlatformAdapterClientInstanceAuthorization, PlatformAdapterClientInstanceOptions, PlatformBillingClientInstanceAuthorization, PlatformBillingClientInstanceOptions, PlatformDpsClientInstanceAuthorization, PlatformDpsClientInstanceOptions, ProductDto, PropertiesDto, Property, PropertyAccessDto, PropertyAccessItemDto, PropertyDto, ResearchCustomerItemDto, ResearchCustomerLocationItemDto, ResearchDictionaryParams, ResearchMarketplaceItemDto, ResearchMarketplaceParams, ResearchTrafficItemDto, ResearchTrafficParams, ScopeDto, SeedAppRepositoryPayload, SeedAppRepositoryResult, SentryClientInstanceAuthorization, SentryClientInstanceOptions, SentryIntegration, SentryOrganization, SentryProject, SentryProjectIssue, SentryProjectIssueEvent, SentryProjectKey, SentryRepository, SentryTeam, ShortcutDto, SyncAppVariablePayload, TextClientInstanceAuthorization, TextClientInstanceOptions, TextPlatformDashboardCreditsDto, TextPlatformDashboardPaymentDto, TextPlatformDashboardReportDto, TextPlatformDashboardReportItemDto, UnauthorizeApiError, UnauthorizeApiErrorSource, UnlinkAppDeploymentPayload, UnlinkAppRepositoryPayload, UnlinkAppSentryLoggerPayload, UnlinkAppStoragePayload, UpdateAppInfrastructureBlocksPayload, UpdateApplicationChangelogPayload, UpdateApplicationChatActionPayload, UpdateApplicationDirectInstallUrlPayload, UpdateApplicationIconPayload, UpdateApplicationOnboardingPayload, UpdateApplicationProductPayload, UpdateApplicationWebhookPayload, UpdateApplicationWidgetDto, UpdateChatWebhookPayload, UpdateClientPayload, UpdateUserFeatures, UpdateUserIntegrations, UpsertAppResourcePayload, UpsertApplicationChatBoosterPayload, UserDto, UserGitHubIntegrationDto, UserIntegrationsDto, UserNetlifyIntegrationDto, UserPlanetScaleIntegrationDto, UserSentryIntegrationDto, UserVercelIntegrationDto, VercelClientInstanceAuthorization, VercelClientInstanceOptions, VercelDeploy, VercelNamespace, VercelPaginatedResult, VercelPagination, VercelProject, VercelProjectEnv, VercelRepository, VercelSearchRepositoryResponse, Webhook, WebhookDto, api, getAppAutoReviewPayload, getEmptyAppAutoReview, getGitHubClientAuthorization, getGithubClientRequestConfig, getLiveChatClientAuthorization, getLiveChatClientConfig, getNetlifyClientAuthorization, getNetlifyClientConfig, getPlanetScaleClientAuthorization, getPlanetScaleClientConfig, getPlatformAccountsClientAuthorization, getPlatformAccountsClientConfig, getPlatformAdapterClientAuthorization, getPlatformAdapterClientConfig, getPlatformBillingClientAuthorization, getPlatformBillingClientConfig, getPlatformDpsAdminClientAuthorization, getPlatformDpsClientAuthorization, getPlatformDpsClientConfig, getRegion, getSentryClientAuthorization, getSentryClientConfig, getTextClientAuthorization, getTextClientConfig, getVercelClientAuthorization, getVercelClientConfig, githubClientInstance, initApi, initGithubClientInstance, initLiveChatClientInstance, initNetlifyClientInstance, initPlanetScaleClientInstance, initPlatformAccountsClientInstance, initPlatformAdapterClientInstance, initPlatformBillingClientInstance, initPlatformDpsClientInstance, initSentryClientInstance, initTextClientInstance, initVercelClientInstance, livechatClientInstance, netlifyClientInstance, planetScaleClientInstance, platformAccountsClientInstance, platformAdapterClientInstance, platformBillingClientInstance, platformDpsClientInstance, sentryClientInstance, serializerBase64, textClientInstance, updateGithubClientInstance, updateNetlifyClientInstance, updatePlanetScaleClientInstance, updatePlatformAdapterClientInstance, updateSentryClientInstance, updateVercelClientInstance, vercelClientInstance };
package/dist/index.js CHANGED
@@ -2458,18 +2458,153 @@ var vercelApi = {
2458
2458
  }
2459
2459
  };
2460
2460
 
2461
+ // src/apis/integrations/neon/api.ts
2462
+ var import_axios11 = __toESM(require("axios"));
2463
+
2464
+ // src/apis/integrations/neon/instance.ts
2465
+ var import_axios10 = __toESM(require("axios"));
2466
+ var neonClientInstance = import_axios10.default.create({
2467
+ baseURL: "https://console.neon.tech/api/v2/"
2468
+ });
2469
+ neonClientInstance.interceptors.response.use(
2470
+ (r) => r,
2471
+ (error) => {
2472
+ var _a;
2473
+ if (import_axios10.default.isAxiosError(error)) {
2474
+ if (((_a = error.response) == null ? void 0 : _a.status) === 401) {
2475
+ throw new UnauthorizeApiError("neon");
2476
+ }
2477
+ }
2478
+ throw error;
2479
+ }
2480
+ );
2481
+ function getNeonClientConfig(options = {}) {
2482
+ const currentHeaders = neonClientInstance.defaults.headers;
2483
+ const defaultAuthorization = currentHeaders.Authorization;
2484
+ const headers = {
2485
+ authorization: defaultAuthorization != null ? defaultAuthorization : options.token ? `${options.token}` : void 0
2486
+ };
2487
+ if (options.ensureAuthorizationToken && !headers.authorization) {
2488
+ throw new UnauthorizeApiError("neon");
2489
+ }
2490
+ return {
2491
+ headers: __spreadValues({}, headers.authorization ? { Authorization: headers.authorization } : {})
2492
+ };
2493
+ }
2494
+
2495
+ // src/apis/integrations/neon/project/branch/api.ts
2496
+ var neonProjectBranchApi = {
2497
+ getBranch(projectId, branchId, authorization) {
2498
+ return __async(this, null, function* () {
2499
+ const response = yield neonClientInstance.get(
2500
+ `projects/${projectId}/branches/${branchId}`,
2501
+ getNeonClientConfig(__spreadValues({}, authorization))
2502
+ );
2503
+ return response.data;
2504
+ });
2505
+ }
2506
+ };
2507
+
2508
+ // src/apis/integrations/neon/project/api.ts
2509
+ var neonProjectApi = {
2510
+ branch: neonProjectBranchApi,
2511
+ createProject(projectName, authorization) {
2512
+ return __async(this, null, function* () {
2513
+ const response = yield neonClientInstance.post(
2514
+ `/projects`,
2515
+ {
2516
+ project: {
2517
+ name: projectName
2518
+ }
2519
+ },
2520
+ getNeonClientConfig(__spreadProps(__spreadValues({}, authorization), {
2521
+ ensureAuthorizationToken: true
2522
+ }))
2523
+ );
2524
+ return response.data;
2525
+ });
2526
+ },
2527
+ getProject(projectId, authorization) {
2528
+ return __async(this, null, function* () {
2529
+ const response = yield neonClientInstance.get(
2530
+ `/projects/${projectId}`,
2531
+ getNeonClientConfig(__spreadProps(__spreadValues({}, authorization), {
2532
+ ensureAuthorizationToken: true
2533
+ }))
2534
+ );
2535
+ return response.data;
2536
+ });
2537
+ },
2538
+ deleteProject(projectId, authorization) {
2539
+ return __async(this, null, function* () {
2540
+ const response = yield neonClientInstance.delete(
2541
+ `/projects/${projectId}`,
2542
+ getNeonClientConfig(__spreadProps(__spreadValues({}, authorization), {
2543
+ ensureAuthorizationToken: true
2544
+ }))
2545
+ );
2546
+ return response.data;
2547
+ });
2548
+ }
2549
+ };
2550
+
2551
+ // src/apis/integrations/neon/user/api.ts
2552
+ var neonUserApi = {
2553
+ getUser(authorization) {
2554
+ return __async(this, null, function* () {
2555
+ const response = yield neonClientInstance.get(
2556
+ `/users/me`,
2557
+ getNeonClientConfig(__spreadProps(__spreadValues({}, authorization), {
2558
+ ensureAuthorizationToken: true
2559
+ }))
2560
+ );
2561
+ return response.data;
2562
+ });
2563
+ }
2564
+ };
2565
+
2566
+ // src/apis/integrations/neon/api.ts
2567
+ var neonApi = {
2568
+ project: neonProjectApi,
2569
+ user: neonUserApi,
2570
+ getToken(code, clientId, clientSecret, redirectUri) {
2571
+ return __async(this, null, function* () {
2572
+ var _a;
2573
+ const data = new URLSearchParams({
2574
+ code,
2575
+ client_id: clientId,
2576
+ client_secret: clientSecret,
2577
+ redirect_uri: redirectUri,
2578
+ grant_type: "authorization_code"
2579
+ });
2580
+ const response = yield import_axios11.default.post(
2581
+ "https://oauth2.neon.tech/oauth2/token",
2582
+ data,
2583
+ {
2584
+ headers: {
2585
+ "Content-Type": "application/x-www-form-urlencoded"
2586
+ }
2587
+ }
2588
+ );
2589
+ const params = new URLSearchParams(response.data);
2590
+ return (_a = params.get("access_token")) != null ? _a : "";
2591
+ });
2592
+ }
2593
+ };
2594
+
2461
2595
  // src/apis/integrations/api.ts
2462
2596
  var integrationsApi = {
2463
2597
  github: gitHubApi,
2464
2598
  netlify: netlifyApi,
2465
2599
  vercel: vercelApi,
2600
+ neon: neonApi,
2466
2601
  planetscale: planetscaleApi,
2467
2602
  sentry: sentryApi,
2468
2603
  text: textApi
2469
2604
  };
2470
2605
 
2471
2606
  // src/apis/products/livechat/instance.ts
2472
- var import_axios10 = __toESM(require("axios"));
2607
+ var import_axios12 = __toESM(require("axios"));
2473
2608
  var REGION = {
2474
2609
  FRA: "fra",
2475
2610
  DAL: "dal",
@@ -2483,7 +2618,7 @@ var getRegion = (token) => {
2483
2618
  return region;
2484
2619
  }
2485
2620
  };
2486
- var livechatClientInstance = import_axios10.default.create({
2621
+ var livechatClientInstance = import_axios12.default.create({
2487
2622
  baseURL: "https://api.labs.livechatinc.com"
2488
2623
  });
2489
2624
  function getLiveChatClientAuthorization(req) {
@@ -2966,8 +3101,8 @@ var productsApi = {
2966
3101
  };
2967
3102
 
2968
3103
  // src/apis/platform/accounts/instance.ts
2969
- var import_axios11 = __toESM(require("axios"));
2970
- var platformAccountsClientInstance = import_axios11.default.create({
3104
+ var import_axios13 = __toESM(require("axios"));
3105
+ var platformAccountsClientInstance = import_axios13.default.create({
2971
3106
  baseURL: "https://accounts.labs.livechatinc.com"
2972
3107
  });
2973
3108
  function getPlatformAccountsClientAuthorization(req) {
@@ -3421,8 +3556,8 @@ var platformAccountsApi = {
3421
3556
  };
3422
3557
 
3423
3558
  // src/apis/platform/dps/instance.ts
3424
- var import_axios12 = __toESM(require("axios"));
3425
- var platformDpsClientInstance = import_axios12.default.create({
3559
+ var import_axios14 = __toESM(require("axios"));
3560
+ var platformDpsClientInstance = import_axios14.default.create({
3426
3561
  baseURL: "https://dev-platform.labs.livechatinc.com"
3427
3562
  });
3428
3563
  function getPlatformDpsClientAuthorization(req) {
@@ -4967,7 +5102,7 @@ var platformDpsApi = {
4967
5102
  };
4968
5103
 
4969
5104
  // src/apis/platform/adapter/instance.ts
4970
- var import_axios13 = __toESM(require("axios"));
5105
+ var import_axios15 = __toESM(require("axios"));
4971
5106
  var REGION2 = {
4972
5107
  FRA: "fra",
4973
5108
  DAL: "dal",
@@ -4993,11 +5128,10 @@ function getPlatformAdapterClientAuthorization(req) {
4993
5128
  netlify: req.headers["netlify-token"],
4994
5129
  vercel: req.headers["vercel-token"],
4995
5130
  planetscale: req.headers["planetscale-token"],
4996
- sentry: req.headers["sentry-token"],
4997
- openai: req.headers["openai-token"]
5131
+ sentry: req.headers["sentry-token"]
4998
5132
  };
4999
5133
  }
5000
- var platformAdapterClientInstance = import_axios13.default.create({
5134
+ var platformAdapterClientInstance = import_axios15.default.create({
5001
5135
  baseURL: "https://platform.labs.text.com/console-adapter/api",
5002
5136
  headers: {
5003
5137
  "Content-Type": "application/json"
@@ -5007,7 +5141,7 @@ platformAdapterClientInstance.interceptors.response.use(
5007
5141
  (r) => r,
5008
5142
  (error) => {
5009
5143
  var _a;
5010
- if (import_axios13.default.isAxiosError(error)) {
5144
+ if (import_axios15.default.isAxiosError(error)) {
5011
5145
  if (((_a = error.response) == null ? void 0 : _a.status) === 401) {
5012
5146
  const source = error.response.data.error.source;
5013
5147
  if (source) {
@@ -5019,7 +5153,7 @@ platformAdapterClientInstance.interceptors.response.use(
5019
5153
  }
5020
5154
  );
5021
5155
  function getPlatformAdapterClientConfig(options = {}) {
5022
- var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p, _q, _r, _s, _t;
5156
+ var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p, _q, _r;
5023
5157
  const currentHeaders = platformAdapterClientInstance.defaults.headers;
5024
5158
  const headers = {
5025
5159
  platform: {
@@ -5033,36 +5167,32 @@ function getPlatformAdapterClientConfig(options = {}) {
5033
5167
  netlify: (_g = currentHeaders["netlify-token"]) != null ? _g : options.netlify,
5034
5168
  vercel: (_h = currentHeaders["vercel-token"]) != null ? _h : options.vercel,
5035
5169
  planetscale: (_i = currentHeaders["planetscale-token"]) != null ? _i : options.planetscale,
5036
- sentry: (_j = currentHeaders["sentry-token"]) != null ? _j : options.sentry,
5037
- openai: (_k = currentHeaders["openai-token"]) != null ? _k : options.openai
5170
+ sentry: (_j = currentHeaders["sentry-token"]) != null ? _j : options.sentry
5038
5171
  }
5039
5172
  };
5040
5173
  if (currentHeaders["platform-dps-token"]) {
5041
- currentHeaders["X-Region"] = (_l = getRegion2(currentHeaders["platform-dps-token"])) != null ? _l : void 0;
5174
+ currentHeaders["X-Region"] = (_k = getRegion2(currentHeaders["platform-dps-token"])) != null ? _k : void 0;
5042
5175
  }
5043
- if (((_n = (_m = options.ensureAuthorizationToken) == null ? void 0 : _m.platform) == null ? void 0 : _n.dps) && !headers.platform.dps) {
5176
+ if (((_m = (_l = options.ensureAuthorizationToken) == null ? void 0 : _l.platform) == null ? void 0 : _m.dps) && !headers.platform.dps) {
5044
5177
  throw new UnauthorizeApiError("dps");
5045
5178
  }
5046
- if (((_o = options.ensureAuthorizationToken) == null ? void 0 : _o.github) && (!headers.integrations.github.app || !headers.integrations.github.oauth)) {
5179
+ if (((_n = options.ensureAuthorizationToken) == null ? void 0 : _n.github) && (!headers.integrations.github.app || !headers.integrations.github.oauth)) {
5047
5180
  throw new UnauthorizeApiError("github");
5048
5181
  }
5049
- if (((_p = options.ensureAuthorizationToken) == null ? void 0 : _p.vercel) && !headers.integrations.vercel) {
5182
+ if (((_o = options.ensureAuthorizationToken) == null ? void 0 : _o.vercel) && !headers.integrations.vercel) {
5050
5183
  throw new UnauthorizeApiError("vercel");
5051
5184
  }
5052
- if (((_q = options.ensureAuthorizationToken) == null ? void 0 : _q.netlify) && !headers.integrations.netlify) {
5185
+ if (((_p = options.ensureAuthorizationToken) == null ? void 0 : _p.netlify) && !headers.integrations.netlify) {
5053
5186
  throw new UnauthorizeApiError("netlify");
5054
5187
  }
5055
- if (((_r = options.ensureAuthorizationToken) == null ? void 0 : _r.planetscale) && !headers.integrations.planetscale) {
5188
+ if (((_q = options.ensureAuthorizationToken) == null ? void 0 : _q.planetscale) && !headers.integrations.planetscale) {
5056
5189
  throw new UnauthorizeApiError("planetscale");
5057
5190
  }
5058
- if (((_s = options.ensureAuthorizationToken) == null ? void 0 : _s.sentry) && !headers.integrations.sentry) {
5191
+ if (((_r = options.ensureAuthorizationToken) == null ? void 0 : _r.sentry) && !headers.integrations.sentry) {
5059
5192
  throw new UnauthorizeApiError("sentry");
5060
5193
  }
5061
- if (((_t = options.ensureAuthorizationToken) == null ? void 0 : _t.openai) && !headers.integrations.openai) {
5062
- throw new UnauthorizeApiError("openai");
5063
- }
5064
5194
  return {
5065
- headers: __spreadValues(__spreadValues(__spreadValues(__spreadValues(__spreadValues(__spreadValues(__spreadValues(__spreadValues({}, headers.platform.dps ? { "platform-dps-token": headers.platform.dps } : {}), headers.integrations.github.app ? { "github-app-token": headers.integrations.github.app } : {}), headers.integrations.github.oauth ? { "github-oauth-token": headers.integrations.github.oauth } : {}), headers.integrations.netlify ? { "netlify-token": headers.integrations.netlify } : {}), headers.integrations.vercel ? { "vercel-token": headers.integrations.vercel } : {}), headers.integrations.planetscale ? { "planetscale-token": headers.integrations.planetscale } : {}), headers.integrations.sentry ? { "sentry-token": headers.integrations.sentry } : {}), headers.integrations.openai ? { "openai-token": headers.integrations.openai } : {})
5195
+ headers: __spreadValues(__spreadValues(__spreadValues(__spreadValues(__spreadValues(__spreadValues(__spreadValues({}, headers.platform.dps ? { "platform-dps-token": headers.platform.dps } : {}), headers.integrations.github.app ? { "github-app-token": headers.integrations.github.app } : {}), headers.integrations.github.oauth ? { "github-oauth-token": headers.integrations.github.oauth } : {}), headers.integrations.netlify ? { "netlify-token": headers.integrations.netlify } : {}), headers.integrations.vercel ? { "vercel-token": headers.integrations.vercel } : {}), headers.integrations.planetscale ? { "planetscale-token": headers.integrations.planetscale } : {}), headers.integrations.sentry ? { "sentry-token": headers.integrations.sentry } : {})
5066
5196
  };
5067
5197
  }
5068
5198
  function initPlatformAdapterClientInstance(baseUrl, tokens) {
@@ -5103,9 +5233,6 @@ function updatePlatformAdapterClientInstance(tokens) {
5103
5233
  if (tokens == null ? void 0 : tokens.sentry) {
5104
5234
  headers["sentry-token"] = tokens.sentry;
5105
5235
  }
5106
- if (tokens == null ? void 0 : tokens.openai) {
5107
- headers["openai-token"] = tokens.openai;
5108
- }
5109
5236
  }
5110
5237
 
5111
5238
  // src/apis/platform/adapter/app/blocks/deployment/api.ts
@@ -5628,20 +5755,6 @@ var platformAdapterAppApi = {
5628
5755
  }
5629
5756
  };
5630
5757
 
5631
- // src/apis/platform/adapter/assistant/api.ts
5632
- var platformAdapterAssistantApi = {
5633
- request(request, authorization) {
5634
- return __async(this, null, function* () {
5635
- const response = yield platformAdapterClientInstance.post(
5636
- `/integrations/openai/assistant`,
5637
- request,
5638
- getPlatformAdapterClientConfig(authorization)
5639
- );
5640
- return response.data;
5641
- });
5642
- }
5643
- };
5644
-
5645
5758
  // src/apis/platform/adapter/conductor/api.ts
5646
5759
  var platformAdapterConductorApi = {
5647
5760
  request(config, authorization) {
@@ -5659,13 +5772,12 @@ var platformAdapterConductorApi = {
5659
5772
  // src/apis/platform/adapter/api.ts
5660
5773
  var platformAdapterApi = {
5661
5774
  app: platformAdapterAppApi,
5662
- conductor: platformAdapterConductorApi,
5663
- assistant: platformAdapterAssistantApi
5775
+ conductor: platformAdapterConductorApi
5664
5776
  };
5665
5777
 
5666
5778
  // src/apis/platform/billing/instance.ts
5667
- var import_axios14 = __toESM(require("axios"));
5668
- var platformBillingClientInstance = import_axios14.default.create({
5779
+ var import_axios16 = __toESM(require("axios"));
5780
+ var platformBillingClientInstance = import_axios16.default.create({
5669
5781
  baseURL: "https://billing.labs.livechatinc.com"
5670
5782
  });
5671
5783
  function getPlatformBillingClientAuthorization(req) {
package/dist/index.mjs CHANGED
@@ -2367,18 +2367,153 @@ var vercelApi = {
2367
2367
  }
2368
2368
  };
2369
2369
 
2370
+ // src/apis/integrations/neon/api.ts
2371
+ import axios11 from "axios";
2372
+
2373
+ // src/apis/integrations/neon/instance.ts
2374
+ import axios10 from "axios";
2375
+ var neonClientInstance = axios10.create({
2376
+ baseURL: "https://console.neon.tech/api/v2/"
2377
+ });
2378
+ neonClientInstance.interceptors.response.use(
2379
+ (r) => r,
2380
+ (error) => {
2381
+ var _a;
2382
+ if (axios10.isAxiosError(error)) {
2383
+ if (((_a = error.response) == null ? void 0 : _a.status) === 401) {
2384
+ throw new UnauthorizeApiError("neon");
2385
+ }
2386
+ }
2387
+ throw error;
2388
+ }
2389
+ );
2390
+ function getNeonClientConfig(options = {}) {
2391
+ const currentHeaders = neonClientInstance.defaults.headers;
2392
+ const defaultAuthorization = currentHeaders.Authorization;
2393
+ const headers = {
2394
+ authorization: defaultAuthorization != null ? defaultAuthorization : options.token ? `${options.token}` : void 0
2395
+ };
2396
+ if (options.ensureAuthorizationToken && !headers.authorization) {
2397
+ throw new UnauthorizeApiError("neon");
2398
+ }
2399
+ return {
2400
+ headers: __spreadValues({}, headers.authorization ? { Authorization: headers.authorization } : {})
2401
+ };
2402
+ }
2403
+
2404
+ // src/apis/integrations/neon/project/branch/api.ts
2405
+ var neonProjectBranchApi = {
2406
+ getBranch(projectId, branchId, authorization) {
2407
+ return __async(this, null, function* () {
2408
+ const response = yield neonClientInstance.get(
2409
+ `projects/${projectId}/branches/${branchId}`,
2410
+ getNeonClientConfig(__spreadValues({}, authorization))
2411
+ );
2412
+ return response.data;
2413
+ });
2414
+ }
2415
+ };
2416
+
2417
+ // src/apis/integrations/neon/project/api.ts
2418
+ var neonProjectApi = {
2419
+ branch: neonProjectBranchApi,
2420
+ createProject(projectName, authorization) {
2421
+ return __async(this, null, function* () {
2422
+ const response = yield neonClientInstance.post(
2423
+ `/projects`,
2424
+ {
2425
+ project: {
2426
+ name: projectName
2427
+ }
2428
+ },
2429
+ getNeonClientConfig(__spreadProps(__spreadValues({}, authorization), {
2430
+ ensureAuthorizationToken: true
2431
+ }))
2432
+ );
2433
+ return response.data;
2434
+ });
2435
+ },
2436
+ getProject(projectId, authorization) {
2437
+ return __async(this, null, function* () {
2438
+ const response = yield neonClientInstance.get(
2439
+ `/projects/${projectId}`,
2440
+ getNeonClientConfig(__spreadProps(__spreadValues({}, authorization), {
2441
+ ensureAuthorizationToken: true
2442
+ }))
2443
+ );
2444
+ return response.data;
2445
+ });
2446
+ },
2447
+ deleteProject(projectId, authorization) {
2448
+ return __async(this, null, function* () {
2449
+ const response = yield neonClientInstance.delete(
2450
+ `/projects/${projectId}`,
2451
+ getNeonClientConfig(__spreadProps(__spreadValues({}, authorization), {
2452
+ ensureAuthorizationToken: true
2453
+ }))
2454
+ );
2455
+ return response.data;
2456
+ });
2457
+ }
2458
+ };
2459
+
2460
+ // src/apis/integrations/neon/user/api.ts
2461
+ var neonUserApi = {
2462
+ getUser(authorization) {
2463
+ return __async(this, null, function* () {
2464
+ const response = yield neonClientInstance.get(
2465
+ `/users/me`,
2466
+ getNeonClientConfig(__spreadProps(__spreadValues({}, authorization), {
2467
+ ensureAuthorizationToken: true
2468
+ }))
2469
+ );
2470
+ return response.data;
2471
+ });
2472
+ }
2473
+ };
2474
+
2475
+ // src/apis/integrations/neon/api.ts
2476
+ var neonApi = {
2477
+ project: neonProjectApi,
2478
+ user: neonUserApi,
2479
+ getToken(code, clientId, clientSecret, redirectUri) {
2480
+ return __async(this, null, function* () {
2481
+ var _a;
2482
+ const data = new URLSearchParams({
2483
+ code,
2484
+ client_id: clientId,
2485
+ client_secret: clientSecret,
2486
+ redirect_uri: redirectUri,
2487
+ grant_type: "authorization_code"
2488
+ });
2489
+ const response = yield axios11.post(
2490
+ "https://oauth2.neon.tech/oauth2/token",
2491
+ data,
2492
+ {
2493
+ headers: {
2494
+ "Content-Type": "application/x-www-form-urlencoded"
2495
+ }
2496
+ }
2497
+ );
2498
+ const params = new URLSearchParams(response.data);
2499
+ return (_a = params.get("access_token")) != null ? _a : "";
2500
+ });
2501
+ }
2502
+ };
2503
+
2370
2504
  // src/apis/integrations/api.ts
2371
2505
  var integrationsApi = {
2372
2506
  github: gitHubApi,
2373
2507
  netlify: netlifyApi,
2374
2508
  vercel: vercelApi,
2509
+ neon: neonApi,
2375
2510
  planetscale: planetscaleApi,
2376
2511
  sentry: sentryApi,
2377
2512
  text: textApi
2378
2513
  };
2379
2514
 
2380
2515
  // src/apis/products/livechat/instance.ts
2381
- import axios10 from "axios";
2516
+ import axios12 from "axios";
2382
2517
  var REGION = {
2383
2518
  FRA: "fra",
2384
2519
  DAL: "dal",
@@ -2392,7 +2527,7 @@ var getRegion = (token) => {
2392
2527
  return region;
2393
2528
  }
2394
2529
  };
2395
- var livechatClientInstance = axios10.create({
2530
+ var livechatClientInstance = axios12.create({
2396
2531
  baseURL: "https://api.labs.livechatinc.com"
2397
2532
  });
2398
2533
  function getLiveChatClientAuthorization(req) {
@@ -2875,8 +3010,8 @@ var productsApi = {
2875
3010
  };
2876
3011
 
2877
3012
  // src/apis/platform/accounts/instance.ts
2878
- import axios11 from "axios";
2879
- var platformAccountsClientInstance = axios11.create({
3013
+ import axios13 from "axios";
3014
+ var platformAccountsClientInstance = axios13.create({
2880
3015
  baseURL: "https://accounts.labs.livechatinc.com"
2881
3016
  });
2882
3017
  function getPlatformAccountsClientAuthorization(req) {
@@ -3330,8 +3465,8 @@ var platformAccountsApi = {
3330
3465
  };
3331
3466
 
3332
3467
  // src/apis/platform/dps/instance.ts
3333
- import axios12 from "axios";
3334
- var platformDpsClientInstance = axios12.create({
3468
+ import axios14 from "axios";
3469
+ var platformDpsClientInstance = axios14.create({
3335
3470
  baseURL: "https://dev-platform.labs.livechatinc.com"
3336
3471
  });
3337
3472
  function getPlatformDpsClientAuthorization(req) {
@@ -4876,7 +5011,7 @@ var platformDpsApi = {
4876
5011
  };
4877
5012
 
4878
5013
  // src/apis/platform/adapter/instance.ts
4879
- import axios13 from "axios";
5014
+ import axios15 from "axios";
4880
5015
  var REGION2 = {
4881
5016
  FRA: "fra",
4882
5017
  DAL: "dal",
@@ -4902,11 +5037,10 @@ function getPlatformAdapterClientAuthorization(req) {
4902
5037
  netlify: req.headers["netlify-token"],
4903
5038
  vercel: req.headers["vercel-token"],
4904
5039
  planetscale: req.headers["planetscale-token"],
4905
- sentry: req.headers["sentry-token"],
4906
- openai: req.headers["openai-token"]
5040
+ sentry: req.headers["sentry-token"]
4907
5041
  };
4908
5042
  }
4909
- var platformAdapterClientInstance = axios13.create({
5043
+ var platformAdapterClientInstance = axios15.create({
4910
5044
  baseURL: "https://platform.labs.text.com/console-adapter/api",
4911
5045
  headers: {
4912
5046
  "Content-Type": "application/json"
@@ -4916,7 +5050,7 @@ platformAdapterClientInstance.interceptors.response.use(
4916
5050
  (r) => r,
4917
5051
  (error) => {
4918
5052
  var _a;
4919
- if (axios13.isAxiosError(error)) {
5053
+ if (axios15.isAxiosError(error)) {
4920
5054
  if (((_a = error.response) == null ? void 0 : _a.status) === 401) {
4921
5055
  const source = error.response.data.error.source;
4922
5056
  if (source) {
@@ -4928,7 +5062,7 @@ platformAdapterClientInstance.interceptors.response.use(
4928
5062
  }
4929
5063
  );
4930
5064
  function getPlatformAdapterClientConfig(options = {}) {
4931
- var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p, _q, _r, _s, _t;
5065
+ var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p, _q, _r;
4932
5066
  const currentHeaders = platformAdapterClientInstance.defaults.headers;
4933
5067
  const headers = {
4934
5068
  platform: {
@@ -4942,36 +5076,32 @@ function getPlatformAdapterClientConfig(options = {}) {
4942
5076
  netlify: (_g = currentHeaders["netlify-token"]) != null ? _g : options.netlify,
4943
5077
  vercel: (_h = currentHeaders["vercel-token"]) != null ? _h : options.vercel,
4944
5078
  planetscale: (_i = currentHeaders["planetscale-token"]) != null ? _i : options.planetscale,
4945
- sentry: (_j = currentHeaders["sentry-token"]) != null ? _j : options.sentry,
4946
- openai: (_k = currentHeaders["openai-token"]) != null ? _k : options.openai
5079
+ sentry: (_j = currentHeaders["sentry-token"]) != null ? _j : options.sentry
4947
5080
  }
4948
5081
  };
4949
5082
  if (currentHeaders["platform-dps-token"]) {
4950
- currentHeaders["X-Region"] = (_l = getRegion2(currentHeaders["platform-dps-token"])) != null ? _l : void 0;
5083
+ currentHeaders["X-Region"] = (_k = getRegion2(currentHeaders["platform-dps-token"])) != null ? _k : void 0;
4951
5084
  }
4952
- if (((_n = (_m = options.ensureAuthorizationToken) == null ? void 0 : _m.platform) == null ? void 0 : _n.dps) && !headers.platform.dps) {
5085
+ if (((_m = (_l = options.ensureAuthorizationToken) == null ? void 0 : _l.platform) == null ? void 0 : _m.dps) && !headers.platform.dps) {
4953
5086
  throw new UnauthorizeApiError("dps");
4954
5087
  }
4955
- if (((_o = options.ensureAuthorizationToken) == null ? void 0 : _o.github) && (!headers.integrations.github.app || !headers.integrations.github.oauth)) {
5088
+ if (((_n = options.ensureAuthorizationToken) == null ? void 0 : _n.github) && (!headers.integrations.github.app || !headers.integrations.github.oauth)) {
4956
5089
  throw new UnauthorizeApiError("github");
4957
5090
  }
4958
- if (((_p = options.ensureAuthorizationToken) == null ? void 0 : _p.vercel) && !headers.integrations.vercel) {
5091
+ if (((_o = options.ensureAuthorizationToken) == null ? void 0 : _o.vercel) && !headers.integrations.vercel) {
4959
5092
  throw new UnauthorizeApiError("vercel");
4960
5093
  }
4961
- if (((_q = options.ensureAuthorizationToken) == null ? void 0 : _q.netlify) && !headers.integrations.netlify) {
5094
+ if (((_p = options.ensureAuthorizationToken) == null ? void 0 : _p.netlify) && !headers.integrations.netlify) {
4962
5095
  throw new UnauthorizeApiError("netlify");
4963
5096
  }
4964
- if (((_r = options.ensureAuthorizationToken) == null ? void 0 : _r.planetscale) && !headers.integrations.planetscale) {
5097
+ if (((_q = options.ensureAuthorizationToken) == null ? void 0 : _q.planetscale) && !headers.integrations.planetscale) {
4965
5098
  throw new UnauthorizeApiError("planetscale");
4966
5099
  }
4967
- if (((_s = options.ensureAuthorizationToken) == null ? void 0 : _s.sentry) && !headers.integrations.sentry) {
5100
+ if (((_r = options.ensureAuthorizationToken) == null ? void 0 : _r.sentry) && !headers.integrations.sentry) {
4968
5101
  throw new UnauthorizeApiError("sentry");
4969
5102
  }
4970
- if (((_t = options.ensureAuthorizationToken) == null ? void 0 : _t.openai) && !headers.integrations.openai) {
4971
- throw new UnauthorizeApiError("openai");
4972
- }
4973
5103
  return {
4974
- headers: __spreadValues(__spreadValues(__spreadValues(__spreadValues(__spreadValues(__spreadValues(__spreadValues(__spreadValues({}, headers.platform.dps ? { "platform-dps-token": headers.platform.dps } : {}), headers.integrations.github.app ? { "github-app-token": headers.integrations.github.app } : {}), headers.integrations.github.oauth ? { "github-oauth-token": headers.integrations.github.oauth } : {}), headers.integrations.netlify ? { "netlify-token": headers.integrations.netlify } : {}), headers.integrations.vercel ? { "vercel-token": headers.integrations.vercel } : {}), headers.integrations.planetscale ? { "planetscale-token": headers.integrations.planetscale } : {}), headers.integrations.sentry ? { "sentry-token": headers.integrations.sentry } : {}), headers.integrations.openai ? { "openai-token": headers.integrations.openai } : {})
5104
+ headers: __spreadValues(__spreadValues(__spreadValues(__spreadValues(__spreadValues(__spreadValues(__spreadValues({}, headers.platform.dps ? { "platform-dps-token": headers.platform.dps } : {}), headers.integrations.github.app ? { "github-app-token": headers.integrations.github.app } : {}), headers.integrations.github.oauth ? { "github-oauth-token": headers.integrations.github.oauth } : {}), headers.integrations.netlify ? { "netlify-token": headers.integrations.netlify } : {}), headers.integrations.vercel ? { "vercel-token": headers.integrations.vercel } : {}), headers.integrations.planetscale ? { "planetscale-token": headers.integrations.planetscale } : {}), headers.integrations.sentry ? { "sentry-token": headers.integrations.sentry } : {})
4975
5105
  };
4976
5106
  }
4977
5107
  function initPlatformAdapterClientInstance(baseUrl, tokens) {
@@ -5012,9 +5142,6 @@ function updatePlatformAdapterClientInstance(tokens) {
5012
5142
  if (tokens == null ? void 0 : tokens.sentry) {
5013
5143
  headers["sentry-token"] = tokens.sentry;
5014
5144
  }
5015
- if (tokens == null ? void 0 : tokens.openai) {
5016
- headers["openai-token"] = tokens.openai;
5017
- }
5018
5145
  }
5019
5146
 
5020
5147
  // src/apis/platform/adapter/app/blocks/deployment/api.ts
@@ -5537,20 +5664,6 @@ var platformAdapterAppApi = {
5537
5664
  }
5538
5665
  };
5539
5666
 
5540
- // src/apis/platform/adapter/assistant/api.ts
5541
- var platformAdapterAssistantApi = {
5542
- request(request, authorization) {
5543
- return __async(this, null, function* () {
5544
- const response = yield platformAdapterClientInstance.post(
5545
- `/integrations/openai/assistant`,
5546
- request,
5547
- getPlatformAdapterClientConfig(authorization)
5548
- );
5549
- return response.data;
5550
- });
5551
- }
5552
- };
5553
-
5554
5667
  // src/apis/platform/adapter/conductor/api.ts
5555
5668
  var platformAdapterConductorApi = {
5556
5669
  request(config, authorization) {
@@ -5568,13 +5681,12 @@ var platformAdapterConductorApi = {
5568
5681
  // src/apis/platform/adapter/api.ts
5569
5682
  var platformAdapterApi = {
5570
5683
  app: platformAdapterAppApi,
5571
- conductor: platformAdapterConductorApi,
5572
- assistant: platformAdapterAssistantApi
5684
+ conductor: platformAdapterConductorApi
5573
5685
  };
5574
5686
 
5575
5687
  // src/apis/platform/billing/instance.ts
5576
- import axios14 from "axios";
5577
- var platformBillingClientInstance = axios14.create({
5688
+ import axios16 from "axios";
5689
+ var platformBillingClientInstance = axios16.create({
5578
5690
  baseURL: "https://billing.labs.livechatinc.com"
5579
5691
  });
5580
5692
  function getPlatformBillingClientAuthorization(req) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@livechat/developer-studio-api",
3
- "version": "2.3.41",
3
+ "version": "2.3.42",
4
4
  "description": "This project is API for LiveChat Developer Studio.",
5
5
  "main": "./dist/index.js",
6
6
  "types": "./dist/index.d.ts",
@@ -11,8 +11,7 @@
11
11
  "author": "",
12
12
  "license": "ISC",
13
13
  "dependencies": {
14
- "axios": "0.21.1",
15
- "openai": "^4.24.2"
14
+ "axios": "0.21.1"
16
15
  },
17
16
  "devDependencies": {
18
17
  "@types/node": "^17.0.12",