@newfold/huapi-js 2.1286.0 → 2.1288.0

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 CHANGED
@@ -10,7 +10,7 @@
10
10
  "tslib": "2.7.0"
11
11
  },
12
12
  "module": "dist/index.ts",
13
- "version": "2.1286.0",
13
+ "version": "2.1288.0",
14
14
  "sideEffects": false,
15
15
  "main": "./src/index.js",
16
16
  "types": "./src/index.d.ts",
package/src/index.d.ts CHANGED
@@ -1,7 +1,7 @@
1
1
  import type { DefinedInitialDataOptions, DefinedUseInfiniteQueryResult, DefinedUseQueryResult, InfiniteData, QueryKey, UndefinedInitialDataOptions, UseInfiniteQueryOptions, UseInfiniteQueryResult, UseMutationOptions, UseMutationResult, UseQueryOptions, UseQueryResult } from '@tanstack/react-query';
2
2
  import axios from 'axios';
3
3
  import type { AxiosError, AxiosRequestConfig, AxiosResponse } from 'axios';
4
- import type { AccountEventList200, AccountEventListParams, AccountHostingList200, AccountPublicKey200, AccountPublicKey404, AccountPublicKeyCreate200, AccountPublicKeyCreate409, AccountPublicKeyCreateBody, AccountPublicKeyDelete200, AccountPublicKeyDelete404, AccountPublicKeyToggle200, AccountPublicKeyToggle409, AccountPublicKeyToggleBody, AccountPublicKeys200, ActivityLog200, ActivityLogParams, AddCron200, AddCron400, AddCronBody, AddHostingRedirects200, AddHostingRedirectsBody, AddIndex200, AddIndexBody, AddPrivacy200, AddPrivacyBody, AddSiteIpaddress200, AddSiteIpaddressBody, AddonCloudflare200, AddonCloudflareBody, AddonsCloudflare200, AddonsInfo200, AddonsJetpackValidate200, AddonsSitelockSso200, AddonsSitelockSsoV2200, AddonsSitelockSsoV2Params, AddonsSpamexpertsSso200, BackupCreateV2200, BackupCreateV2Body, BackupDownloadV2200, BackupDownloadV2Body, BackupInitiate200, BackupInitiateBody, BackupList200, BackupListParams, BackupListV2200, BackupRestoreV2200, BackupRestoreV2Body, BackupStatus200, BackupStatusParams, BackupStatusV2200, BackupStatusV2Params, BackupsJetpackBackup200, CodeguardBackupCreate200, CodeguardBackupCreateBody, CodeguardBackupDownload200, CodeguardBackupDownloadBody, CodeguardBackupList200, CodeguardBackupListParams, CodeguardBackupRestore200, CodeguardBackupRestoreBody, CodeguardDatabaseBackupCreate200, CodeguardDatabaseBackupCreateBody, CodeguardDatabaseBackupList200, CodeguardDatabaseBackupListParams, CodeguardDatabaseBackupRestore200, CodeguardDatabaseBackupRestoreBody, CodeguardDatabaseList200, CodeguardLoginLink200, CodeguardPlanInfo200, CodeguardWebsiteBackupCreate200, CodeguardWebsiteBackupCreateBody, CodeguardWebsiteBackupList200, CodeguardWebsiteBackupListParams, CodeguardWebsiteBackupRestore200, CodeguardWebsiteBackupRestoreBody, CodeguardWebsiteList200, CreatePhpInfo200, Cron200, CronBody, Db200, DbAdd200, DbAddBody, DbBody, DbCheckDatabase200, DbCheckDatabaseBody, DbList200, DbListV2200, DbMultipleUserDatabase200, DbMultipleUserDatabaseBody, DbUsage200, DbUserAdd200, DbUserAddBody, DbUserDelete200, DbUserDeleteBody, DbUserList200, DbUserPasswordSet200, DbUserPasswordSetBody, DbUserPrivsGet200, DbUserPrivsGetParams, DbUserPrivsSet200, DbUserPrivsSetBody, DbUserRename200, DbUserRenameBody, DirectoryPrivacy200, DirectoryPrivacyParams, DomainCertInstall200, DomainCertInstallBody, DomainCertUninstall200, DomainCertUpdate200, DomainCertUpdateBody, DomainCerts200, DomainDnsExport200, DomainDnsExportParams, DomainDnsImport200, DomainDnsImportBody, DomainDnsImportParams, DomainDnseditor200, DomainDnseditorAdd200, DomainDnseditorAddBody, DomainDnseditorBody, DomainDnseditorEdit200, DomainDnseditorEditBody, DomainDnseditorList200Item, DomainDnszoneReset200, DomainInfo200, DomainUnassign200, DomainZoneeditorUrl200, Domains200, DomainsParams, EditPrivacy200, EditPrivacyBody, HostingAccount200, HostingAddons200, HostingAddonsParams, HostingAdvancedDns200, HostingAdvancedDnsParams, HostingAdvancedDnsUpdate200, HostingAdvancedDnsUpdateBody, HostingAdvancedDomainServices200, HostingAdvancedDomainServicesBody, HostingAdvancedDomainServicesCheck200, HostingAdvancedPassword200, HostingAdvancedPasswordBody, HostingAdvancedServer200, HostingAdvancedServerStatus200, HostingAdvancedServerStatusBody, HostingAdvancedSsoWhm200, HostingAdvancedSystemConsole200, HostingCapabilities200, HostingDbAuthorizedHosts200, HostingDbAuthorizedHostsAdd200, HostingDbAuthorizedHostsAddBody, HostingDbAuthorizedHostsDelete200, HostingDbAuthorizedHostsDeleteBody, HostingDbAuthorizedHostsUpdate200, HostingDbAuthorizedHostsUpdateBody, HostingDomainAssign200, HostingDomainAssignBody, HostingDomainAvailability200, HostingDomainAvailabilityParams, HostingDomainsUnassign200, HostingDomainsUnassignBody, HostingDomainsUnassignV2200, HostingDomainsUnassignV2Body, HostingEcommerceInfo200, HostingFixownership200, HostingFtp200, HostingFtpAdd200, HostingFtpAddBody, HostingFtpBody, HostingFtpList200, HostingFtpUpdate200, HostingFtpUpdateBody, HostingInfo200, HostingInfoDiskUsage200, HostingLead200, HostingLead400, HostingLeadParams, HostingMigrationInfo200, HostingMigrationInfoParams, HostingMigrationSiteScanStatus200, HostingMigrationSiteScanStatusParams, HostingMigrationStatus200, HostingMigrations200, HostingMigrationsBody, HostingMigrationsCheck200, HostingMigrationsCheckParams, HostingMigrationsEvent200, HostingMigrationsEventBody, HostingNameservers200, HostingNameserversV2200, HostingOnboardingData200, HostingOnboardingDataUpdate200, HostingOnboardingDataUpdateBody, HostingRedirect200, HostingRedirectBody, HostingRedirects200Item, HostingRedirectsV2200Item, HostingResellerSsoWhm200, HostingShellInfo200, HostingShellToggle200, HostingShellToggleBody, HostingSiteAdd200, HostingSiteAddBody, HostingSiteAddV2200, HostingSiteAddV2Body, HostingSitesV2200, HostingSitesV2Params, HostingSshInfo200, HostingVisitors200, HostingVisitorsParams, HotlinkconfigAdd200, HotlinkconfigAddBody, HotlinkconfigDelete200, HotlinkconfigDeleteBody, HotlinkconfigDetails200, HotlinkconfigDetailsParams, Index200, IndexBody, JetpackBackupStatus200, ListCrons200, ListFiles200, ListFilesParams, ListFilesV2200, ListFilesV2Params, ListIndex200, ListIndexParams, PasswordGenerate200, PasswordScore200, PasswordScoreParams, PhpErrors200, PhpErrorsParams, Privacy200, PrivacyBody, PrivacyUser200, PrivacyUserBody, RepairDatabase200, RepairDatabaseBody, ResetSite200, ResetSiteBody, Site200, SiteAddonCloudflare200, SiteAddonCloudflare400, SiteBody, SiteInfoResponseModelV2, SiteIpaddress200, SiteIpaddressBody, SiteIpaddressList200Item, SiteMalwareStatus200, SitePendingDomainDelete200, SitePluginUpdate200, SitePluginUpdateBody, SitePlugins200, SitePluginsAutoupdate200, SitePluginsAutoupdateBody, SitePluginsParams, SitePluginsToggle200, SitePluginsToggleBody, SitePluginsUpdate200, SitePluginsUpdateBody, SiteQualityMetrics200, SiteQualityMetricsParams, SiteStatus200, SiteUpdate200, SiteUpdate400, SiteUpdateBody, SiteUsers200, SitesAccessLogs200, SitesAccessLogsDownloadParams, SitesAccessLogsParams, SitesAutoupdatesResponse, SitesAutoupdatesUpdateBody, SitesBackups200, SitesBackupsCodeguard200, SitesBackupsDetails200, SitesBatch200, SitesBatchBody, SitesDatabaseInfo200, SitesDatabasePasswordsync200, SitesDns200, SitesDnsParams, SitesDomain200, SitesDomainParams, SitesDomainUrl200, SitesDomainUrlBody, SitesDomainsCreate200, SitesDomainsCreateBody, SitesDomainsV2200, SitesDomainsV2Params, SitesErrorLogs200, SitesErrorLogsDownloadParams, SitesErrorLogsParams, SitesHasBackups200, SitesInfo200, SitesListV2200, SitesListV3200, SitesListV3Params, SitesMetricDimensions200, SitesMetricDimensionsParams, SitesMetricsDimensionAveraged200, SitesMetricsDimensionAveragedParams, SitesPerformanceCachepurge200, SitesPerformanceCachepurgeBody, SitesPerformanceEdgecache200, SitesPerformanceEdgecacheBody, SitesPerformanceEnduranceCacheLevel200, SitesPerformanceEnduranceCacheLevelBody, SitesPerformanceEnduranceCacheLevelStatus200, SitesPerformanceEndurancePageCache200, SitesSecurityBundle200, SitesSecurityCheckCore200, SitesSecurityHttpsEnableDisableSsl200, SitesSecurityHttpsEnableDisableSslBody, SitesSecurityHttpsRedirectionStatus200, SitesSecurityResetCoreFiles200, SitesSecuritySitelock200, SitesSecuritySitelockParams, SitesSecuritySitelockV2200, SitesSecuritySitelockV2Params, SitesSecuritySslAcme200, SitesSecuritySslStatus200, SitesSecuritySslStatusParams, SitesSettingsComingSoon200, SitesSettingsComingSoonToggle200, SitesSettingsComingSoonToggleBody, SitesSettingsDebug200, SitesSettingsDebugToggle200, SitesSettingsDebugToggleBody, SitesSettingsPhpVersionUpdate200, SitesSettingsPhpVersionUpdateBody, SitesSettingsPhpVersions200, SitesSshUserCreate200, SitesSshUserCreateBody, SitesSshUserDelete200, SitesSshUserDeleteBody, SitesSshUserList200, SitesSshUserListV2200, SitesSshUserUpdate200, SitesSshUserUpdateBody, SitesSsl200, SitesSso200, SitesSsoParams, SitesVersion200, SshKey200, SshKeyBody, SshKeyFetch200, SshKeyFetchParams, SshKeyGenerate200, SshKeyGenerateBody, SshKeyImport200, SshKeyImportBody, SshKeyImportV2200, SshKeyImportV2Body, SshKeyImportV3200, SshKeyImportV3Body, SshKeyList200, SshKeyListV2200, SshKeyListV3200, SshKeyListV4200, SshKeyV2200, SshKeyV2Body, Sso200, SsoParams, StagingSitePromote200, StagingSitePromote409, StagingSitePromoteBody, UpdateCron200, UpdateCronBody, WebzaiSso200, WeeblySso200 } from './index.schemas';
4
+ import type { AccountEventList200, AccountEventListParams, AccountHostingList200, AccountPublicKey200, AccountPublicKey404, AccountPublicKeyCreate200, AccountPublicKeyCreate409, AccountPublicKeyCreateBody, AccountPublicKeyDelete200, AccountPublicKeyDelete404, AccountPublicKeyToggle200, AccountPublicKeyToggle409, AccountPublicKeyToggleBody, AccountPublicKeys200, ActivityLog200, ActivityLogParams, AddCron200, AddCron400, AddCronBody, AddHostingRedirects200, AddHostingRedirectsBody, AddIndex200, AddIndexBody, AddPrivacy200, AddPrivacyBody, AddSiteIpaddress200, AddSiteIpaddressBody, AddonCloudflare200, AddonCloudflareBody, AddonsCloudflare200, AddonsInfo200, AddonsJetpackValidate200, AddonsSitelockSso200, AddonsSitelockSsoV2200, AddonsSitelockSsoV2Params, AddonsSpamexpertsSso200, BackupCreateV2200, BackupCreateV2Body, BackupDownloadV2200, BackupDownloadV2Body, BackupInitiate200, BackupInitiateBody, BackupList200, BackupListParams, BackupListV2200, BackupRestoreV2200, BackupRestoreV2Body, BackupStatus200, BackupStatusParams, BackupStatusV2200, BackupStatusV2Params, BackupsJetpackBackup200, CodeguardBackupCreate200, CodeguardBackupCreateBody, CodeguardBackupDownload200, CodeguardBackupDownloadBody, CodeguardBackupList200, CodeguardBackupListParams, CodeguardBackupRestore200, CodeguardBackupRestoreBody, CodeguardDatabaseBackupCreate200, CodeguardDatabaseBackupCreateBody, CodeguardDatabaseBackupList200, CodeguardDatabaseBackupListParams, CodeguardDatabaseBackupRestore200, CodeguardDatabaseBackupRestoreBody, CodeguardDatabaseList200, CodeguardLoginLink200, CodeguardPlanInfo200, CodeguardWebsiteBackupCreate200, CodeguardWebsiteBackupCreateBody, CodeguardWebsiteBackupList200, CodeguardWebsiteBackupListParams, CodeguardWebsiteBackupRestore200, CodeguardWebsiteBackupRestoreBody, CodeguardWebsiteList200, CreatePhpInfo200, Cron200, CronBody, Db200, DbAdd200, DbAddBody, DbBody, DbCheckDatabase200, DbCheckDatabaseBody, DbList200, DbListV2200, DbMultipleUserDatabase200, DbMultipleUserDatabaseBody, DbUsage200, DbUserAdd200, DbUserAddBody, DbUserDelete200, DbUserDeleteBody, DbUserList200, DbUserPasswordSet200, DbUserPasswordSetBody, DbUserPrivsGet200, DbUserPrivsGetParams, DbUserPrivsSet200, DbUserPrivsSetBody, DbUserRename200, DbUserRenameBody, DirectoryPrivacy200, DirectoryPrivacyParams, DomainCertInstall200, DomainCertInstallBody, DomainCertUninstall200, DomainCertUpdate200, DomainCertUpdateBody, DomainCerts200, DomainDnsExport200, DomainDnsExportParams, DomainDnsImport200, DomainDnsImportBody, DomainDnsImportParams, DomainDnseditor200, DomainDnseditorAdd200, DomainDnseditorAddBody, DomainDnseditorBody, DomainDnseditorEdit200, DomainDnseditorEditBody, DomainDnseditorList200Item, DomainDnszoneReset200, DomainInfo200, DomainUnassign200, DomainZoneeditorUrl200, Domains200, DomainsParams, EditPrivacy200, EditPrivacyBody, HostingAccount200, HostingAddons200, HostingAddonsParams, HostingAdvancedDns200, HostingAdvancedDnsParams, HostingAdvancedDnsUpdate200, HostingAdvancedDnsUpdateBody, HostingAdvancedDomainServices200, HostingAdvancedDomainServicesBody, HostingAdvancedDomainServicesCheck200, HostingAdvancedPassword200, HostingAdvancedPasswordBody, HostingAdvancedServer200, HostingAdvancedServerStatus200, HostingAdvancedServerStatusBody, HostingAdvancedSsoWhm200, HostingAdvancedSystemConsole200, HostingCapabilities200, HostingDbAuthorizedHosts200, HostingDbAuthorizedHostsAdd200, HostingDbAuthorizedHostsAddBody, HostingDbAuthorizedHostsDelete200, HostingDbAuthorizedHostsDeleteBody, HostingDbAuthorizedHostsUpdate200, HostingDbAuthorizedHostsUpdateBody, HostingDomainAssign200, HostingDomainAssignBody, HostingDomainAvailability200, HostingDomainAvailabilityParams, HostingDomainsUnassign200, HostingDomainsUnassignBody, HostingDomainsUnassignV2200, HostingDomainsUnassignV2Body, HostingEcommerceInfo200, HostingEmailAdd200, HostingEmailAdd400, HostingEmailAdd403, HostingEmailAdd409, HostingEmailAdd512, HostingEmailAddBody, HostingEmailDelete200, HostingEmailDeleteParams, HostingEmailList200, HostingFixownership200, HostingFtp200, HostingFtpAdd200, HostingFtpAddBody, HostingFtpBody, HostingFtpList200, HostingFtpUpdate200, HostingFtpUpdateBody, HostingInfo200, HostingInfoDiskUsage200, HostingLead200, HostingLead400, HostingLeadParams, HostingMigrationInfo200, HostingMigrationInfoParams, HostingMigrationSiteScanStatus200, HostingMigrationSiteScanStatusParams, HostingMigrationStatus200, HostingMigrations200, HostingMigrationsBody, HostingMigrationsCheck200, HostingMigrationsCheckParams, HostingMigrationsEvent200, HostingMigrationsEventBody, HostingNameservers200, HostingNameserversV2200, HostingOnboardingData200, HostingOnboardingDataUpdate200, HostingOnboardingDataUpdateBody, HostingRedirect200, HostingRedirectBody, HostingRedirects200Item, HostingRedirectsV2200Item, HostingResellerSsoWhm200, HostingShellInfo200, HostingShellToggle200, HostingShellToggleBody, HostingSiteAdd200, HostingSiteAddBody, HostingSiteAddV2200, HostingSiteAddV2Body, HostingSitesV2200, HostingSitesV2Params, HostingSshInfo200, HostingVisitors200, HostingVisitorsParams, HotlinkconfigAdd200, HotlinkconfigAddBody, HotlinkconfigDelete200, HotlinkconfigDeleteBody, HotlinkconfigDetails200, HotlinkconfigDetailsParams, Index200, IndexBody, JetpackBackupStatus200, ListCrons200, ListFiles200, ListFilesParams, ListFilesV2200, ListFilesV2Params, ListIndex200, ListIndexParams, PasswordGenerate200, PasswordScore200, PasswordScoreParams, PhpErrors200, PhpErrorsParams, Privacy200, PrivacyBody, PrivacyUser200, PrivacyUserBody, RepairDatabase200, RepairDatabaseBody, ResetSite200, ResetSiteBody, Site200, SiteAddonCloudflare200, SiteAddonCloudflare400, SiteBody, SiteInfoResponseModelV2, SiteIpaddress200, SiteIpaddressBody, SiteIpaddressList200Item, SiteMalwareStatus200, SitePendingDomainDelete200, SitePluginUpdate200, SitePluginUpdateBody, SitePlugins200, SitePluginsAutoupdate200, SitePluginsAutoupdateBody, SitePluginsParams, SitePluginsToggle200, SitePluginsToggleBody, SitePluginsUpdate200, SitePluginsUpdateBody, SiteQualityMetrics200, SiteQualityMetricsParams, SiteStatus200, SiteUpdate200, SiteUpdate400, SiteUpdateBody, SiteUsers200, SitesAccessLogs200, SitesAccessLogsDownloadParams, SitesAccessLogsParams, SitesAutoupdatesResponse, SitesAutoupdatesUpdateBody, SitesBackups200, SitesBackupsCodeguard200, SitesBackupsDetails200, SitesBatch200, SitesBatchBody, SitesDatabaseInfo200, SitesDatabasePasswordsync200, SitesDns200, SitesDnsParams, SitesDomain200, SitesDomainParams, SitesDomainUrl200, SitesDomainUrlBody, SitesDomainsCreate200, SitesDomainsCreateBody, SitesDomainsV2200, SitesDomainsV2Params, SitesErrorLogs200, SitesErrorLogsDownloadParams, SitesErrorLogsParams, SitesHasBackups200, SitesInfo200, SitesListV2200, SitesListV3200, SitesListV3Params, SitesMetricDimensions200, SitesMetricDimensionsParams, SitesMetricsDimensionAveraged200, SitesMetricsDimensionAveragedParams, SitesPerformanceCachepurge200, SitesPerformanceCachepurgeBody, SitesPerformanceEdgecache200, SitesPerformanceEdgecacheBody, SitesPerformanceEnduranceCacheLevel200, SitesPerformanceEnduranceCacheLevelBody, SitesPerformanceEnduranceCacheLevelStatus200, SitesPerformanceEndurancePageCache200, SitesSecurityBundle200, SitesSecurityCheckCore200, SitesSecurityHttpsEnableDisableSsl200, SitesSecurityHttpsEnableDisableSslBody, SitesSecurityHttpsRedirectionStatus200, SitesSecurityResetCoreFiles200, SitesSecuritySitelock200, SitesSecuritySitelockParams, SitesSecuritySitelockV2200, SitesSecuritySitelockV2Params, SitesSecuritySslAcme200, SitesSecuritySslStatus200, SitesSecuritySslStatusParams, SitesSettingsComingSoon200, SitesSettingsComingSoonToggle200, SitesSettingsComingSoonToggleBody, SitesSettingsDebug200, SitesSettingsDebugToggle200, SitesSettingsDebugToggleBody, SitesSettingsPhpVersionUpdate200, SitesSettingsPhpVersionUpdateBody, SitesSettingsPhpVersions200, SitesSshUserCreate200, SitesSshUserCreateBody, SitesSshUserDelete200, SitesSshUserDeleteBody, SitesSshUserList200, SitesSshUserListV2200, SitesSshUserUpdate200, SitesSshUserUpdateBody, SitesSsl200, SitesSso200, SitesSsoParams, SitesVersion200, SshKey200, SshKeyBody, SshKeyFetch200, SshKeyFetchParams, SshKeyGenerate200, SshKeyGenerateBody, SshKeyImport200, SshKeyImportBody, SshKeyImportV2200, SshKeyImportV2Body, SshKeyImportV3200, SshKeyImportV3Body, SshKeyList200, SshKeyListV2200, SshKeyListV3200, SshKeyListV4200, SshKeyV2200, SshKeyV2Body, Sso200, SsoParams, StagingSitePromote200, StagingSitePromote409, StagingSitePromoteBody, UpdateCron200, UpdateCronBody, WebzaiSso200, WeeblySso200 } from './index.schemas';
5
5
  declare type AwaitedInput<T> = PromiseLike<T> | T;
6
6
  declare type Awaited<O> = O extends AwaitedInput<infer T> ? T : never;
7
7
  /**
@@ -2847,6 +2847,99 @@ export declare function useHostingEcommerceInfo<TData = Awaited<ReturnType<typeo
2847
2847
  }): UseQueryResult<TData, TError> & {
2848
2848
  queryKey: QueryKey;
2849
2849
  };
2850
+ /**
2851
+ * Use to add a new email box, domainalias, alias, forwarder, discard, pipe or list
2852
+ * @summary email add
2853
+ */
2854
+ export declare const hostingEmailAdd: (hostingId: string, hostingEmailAddBody: HostingEmailAddBody, options?: AxiosRequestConfig) => Promise<AxiosResponse<HostingEmailAdd200>>;
2855
+ export declare const getHostingEmailAddMutationOptions: <TError = AxiosError<HostingEmailAdd512 | HostingEmailAdd409 | HostingEmailAdd403 | HostingEmailAdd400, any>, TContext = unknown>(options?: {
2856
+ mutation?: UseMutationOptions<AxiosResponse<HostingEmailAdd200, any>, TError, {
2857
+ hostingId: string;
2858
+ data: HostingEmailAddBody;
2859
+ }, TContext> | undefined;
2860
+ axios?: AxiosRequestConfig<any> | undefined;
2861
+ } | undefined) => UseMutationOptions<AxiosResponse<HostingEmailAdd200, any>, TError, {
2862
+ hostingId: string;
2863
+ data: HostingEmailAddBody;
2864
+ }, TContext>;
2865
+ export declare type HostingEmailAddMutationResult = NonNullable<Awaited<ReturnType<typeof hostingEmailAdd>>>;
2866
+ export declare type HostingEmailAddMutationBody = HostingEmailAddBody;
2867
+ export declare type HostingEmailAddMutationError = AxiosError<HostingEmailAdd400 | HostingEmailAdd403 | HostingEmailAdd409 | HostingEmailAdd512>;
2868
+ /**
2869
+ * @summary email add
2870
+ */
2871
+ export declare const useHostingEmailAdd: <TError = AxiosError<HostingEmailAdd512 | HostingEmailAdd409 | HostingEmailAdd403 | HostingEmailAdd400, any>, TContext = unknown>(options?: {
2872
+ mutation?: UseMutationOptions<AxiosResponse<HostingEmailAdd200, any>, TError, {
2873
+ hostingId: string;
2874
+ data: HostingEmailAddBody;
2875
+ }, TContext> | undefined;
2876
+ axios?: AxiosRequestConfig<any> | undefined;
2877
+ } | undefined) => UseMutationResult<AxiosResponse<HostingEmailAdd200, any>, TError, {
2878
+ hostingId: string;
2879
+ data: HostingEmailAddBody;
2880
+ }, TContext>;
2881
+ /**
2882
+ * Lists existing email resources by type
2883
+ * @summary email delete
2884
+ */
2885
+ export declare const hostingEmailDelete: (hostingId: string, params: HostingEmailDeleteParams, options?: AxiosRequestConfig) => Promise<AxiosResponse<HostingEmailDelete200>>;
2886
+ export declare const getHostingEmailDeleteMutationOptions: <TError = AxiosError<unknown, any>, TContext = unknown>(options?: {
2887
+ mutation?: UseMutationOptions<AxiosResponse<HostingEmailDelete200, any>, TError, {
2888
+ hostingId: string;
2889
+ params: HostingEmailDeleteParams;
2890
+ }, TContext> | undefined;
2891
+ axios?: AxiosRequestConfig<any> | undefined;
2892
+ } | undefined) => UseMutationOptions<AxiosResponse<HostingEmailDelete200, any>, TError, {
2893
+ hostingId: string;
2894
+ params: HostingEmailDeleteParams;
2895
+ }, TContext>;
2896
+ export declare type HostingEmailDeleteMutationResult = NonNullable<Awaited<ReturnType<typeof hostingEmailDelete>>>;
2897
+ export declare type HostingEmailDeleteMutationError = AxiosError<unknown>;
2898
+ /**
2899
+ * @summary email delete
2900
+ */
2901
+ export declare const useHostingEmailDelete: <TError = AxiosError<unknown, any>, TContext = unknown>(options?: {
2902
+ mutation?: UseMutationOptions<AxiosResponse<HostingEmailDelete200, any>, TError, {
2903
+ hostingId: string;
2904
+ params: HostingEmailDeleteParams;
2905
+ }, TContext> | undefined;
2906
+ axios?: AxiosRequestConfig<any> | undefined;
2907
+ } | undefined) => UseMutationResult<AxiosResponse<HostingEmailDelete200, any>, TError, {
2908
+ hostingId: string;
2909
+ params: HostingEmailDeleteParams;
2910
+ }, TContext>;
2911
+ /**
2912
+ * Lists existing email resources by type
2913
+ * @summary email list
2914
+ */
2915
+ export declare const hostingEmailList: (hostingId: string, options?: AxiosRequestConfig) => Promise<AxiosResponse<HostingEmailList200>>;
2916
+ export declare const getHostingEmailListQueryKey: (hostingId: string) => readonly [`/v1/hosting/${string}/emails`];
2917
+ export declare const getHostingEmailListQueryOptions: <TData = AxiosResponse<HostingEmailList200, any>, TError = AxiosError<unknown, any>>(hostingId: string, options?: {
2918
+ query?: Partial<UseQueryOptions<AxiosResponse<HostingEmailList200, any>, TError, TData, QueryKey>> | undefined;
2919
+ axios?: AxiosRequestConfig<any> | undefined;
2920
+ } | undefined) => UseQueryOptions<AxiosResponse<HostingEmailList200, any>, TError, TData, QueryKey> & {
2921
+ queryKey: QueryKey;
2922
+ };
2923
+ export declare type HostingEmailListQueryResult = NonNullable<Awaited<ReturnType<typeof hostingEmailList>>>;
2924
+ export declare type HostingEmailListQueryError = AxiosError<unknown>;
2925
+ export declare function useHostingEmailList<TData = Awaited<ReturnType<typeof hostingEmailList>>, TError = AxiosError<unknown>>(hostingId: string, options: {
2926
+ query: Partial<UseQueryOptions<Awaited<ReturnType<typeof hostingEmailList>>, TError, TData>> & Pick<DefinedInitialDataOptions<Awaited<ReturnType<typeof hostingEmailList>>, TError, TData>, 'initialData'>;
2927
+ axios?: AxiosRequestConfig;
2928
+ }): DefinedUseQueryResult<TData, TError> & {
2929
+ queryKey: QueryKey;
2930
+ };
2931
+ export declare function useHostingEmailList<TData = Awaited<ReturnType<typeof hostingEmailList>>, TError = AxiosError<unknown>>(hostingId: string, options?: {
2932
+ query?: Partial<UseQueryOptions<Awaited<ReturnType<typeof hostingEmailList>>, TError, TData>> & Pick<UndefinedInitialDataOptions<Awaited<ReturnType<typeof hostingEmailList>>, TError, TData>, 'initialData'>;
2933
+ axios?: AxiosRequestConfig;
2934
+ }): UseQueryResult<TData, TError> & {
2935
+ queryKey: QueryKey;
2936
+ };
2937
+ export declare function useHostingEmailList<TData = Awaited<ReturnType<typeof hostingEmailList>>, TError = AxiosError<unknown>>(hostingId: string, options?: {
2938
+ query?: Partial<UseQueryOptions<Awaited<ReturnType<typeof hostingEmailList>>, TError, TData>>;
2939
+ axios?: AxiosRequestConfig;
2940
+ }): UseQueryResult<TData, TError> & {
2941
+ queryKey: QueryKey;
2942
+ };
2850
2943
  /**
2851
2944
  * List files under the given directory
2852
2945
  * @deprecated
package/src/index.js CHANGED
@@ -3,7 +3,7 @@
3
3
  * Do not edit manually.
4
4
  * Hosting UAPI
5
5
  * Hosting UAPI is an API to expose Hosting, Addons, and Site functionality to a customer-facing Front End such as (Account Manager).
6
- * OpenAPI spec version: 1.1286.0
6
+ * OpenAPI spec version: 1.1288.0
7
7
  */
8
8
  import { useInfiniteQuery, useMutation, useQuery } from '@tanstack/react-query';
9
9
  import axios from 'axios';
@@ -2189,6 +2189,76 @@ export function useHostingEcommerceInfo(hostingId, options) {
2189
2189
  query.queryKey = queryOptions.queryKey;
2190
2190
  return query;
2191
2191
  }
2192
+ /**
2193
+ * Use to add a new email box, domainalias, alias, forwarder, discard, pipe or list
2194
+ * @summary email add
2195
+ */
2196
+ export const hostingEmailAdd = (hostingId, hostingEmailAddBody, options) => {
2197
+ return axios.post(`/v1/hosting/${hostingId}/emails`, hostingEmailAddBody, options);
2198
+ };
2199
+ export const getHostingEmailAddMutationOptions = (options) => {
2200
+ const { mutation: mutationOptions, axios: axiosOptions } = options !== null && options !== void 0 ? options : {};
2201
+ const mutationFn = (props) => {
2202
+ const { hostingId, data } = props !== null && props !== void 0 ? props : {};
2203
+ return hostingEmailAdd(hostingId, data, axiosOptions);
2204
+ };
2205
+ return Object.assign({ mutationFn }, mutationOptions);
2206
+ };
2207
+ /**
2208
+ * @summary email add
2209
+ */
2210
+ export const useHostingEmailAdd = (options) => {
2211
+ const mutationOptions = getHostingEmailAddMutationOptions(options);
2212
+ return useMutation(mutationOptions);
2213
+ };
2214
+ /**
2215
+ * Lists existing email resources by type
2216
+ * @summary email delete
2217
+ */
2218
+ export const hostingEmailDelete = (hostingId, params, options) => {
2219
+ return axios.delete(`/v1/hosting/${hostingId}/emails`, Object.assign(Object.assign({}, options), { params: Object.assign(Object.assign({}, params), options === null || options === void 0 ? void 0 : options.params) }));
2220
+ };
2221
+ export const getHostingEmailDeleteMutationOptions = (options) => {
2222
+ const { mutation: mutationOptions, axios: axiosOptions } = options !== null && options !== void 0 ? options : {};
2223
+ const mutationFn = (props) => {
2224
+ const { hostingId, params } = props !== null && props !== void 0 ? props : {};
2225
+ return hostingEmailDelete(hostingId, params, axiosOptions);
2226
+ };
2227
+ return Object.assign({ mutationFn }, mutationOptions);
2228
+ };
2229
+ /**
2230
+ * @summary email delete
2231
+ */
2232
+ export const useHostingEmailDelete = (options) => {
2233
+ const mutationOptions = getHostingEmailDeleteMutationOptions(options);
2234
+ return useMutation(mutationOptions);
2235
+ };
2236
+ /**
2237
+ * Lists existing email resources by type
2238
+ * @summary email list
2239
+ */
2240
+ export const hostingEmailList = (hostingId, options) => {
2241
+ return axios.get(`/v1/hosting/${hostingId}/emails`, options);
2242
+ };
2243
+ export const getHostingEmailListQueryKey = (hostingId) => {
2244
+ return [`/v1/hosting/${hostingId}/emails`];
2245
+ };
2246
+ export const getHostingEmailListQueryOptions = (hostingId, options) => {
2247
+ var _a;
2248
+ const { query: queryOptions, axios: axiosOptions } = options !== null && options !== void 0 ? options : {};
2249
+ const queryKey = (_a = queryOptions === null || queryOptions === void 0 ? void 0 : queryOptions.queryKey) !== null && _a !== void 0 ? _a : getHostingEmailListQueryKey(hostingId);
2250
+ const queryFn = ({ signal }) => hostingEmailList(hostingId, Object.assign({ signal }, axiosOptions));
2251
+ return Object.assign({ queryKey, queryFn, enabled: !!(hostingId) }, queryOptions);
2252
+ };
2253
+ /**
2254
+ * @summary email list
2255
+ */
2256
+ export function useHostingEmailList(hostingId, options) {
2257
+ const queryOptions = getHostingEmailListQueryOptions(hostingId, options);
2258
+ const query = useQuery(queryOptions);
2259
+ query.queryKey = queryOptions.queryKey;
2260
+ return query;
2261
+ }
2192
2262
  /**
2193
2263
  * List files under the given directory
2194
2264
  * @deprecated
@@ -1,5 +1,5 @@
1
1
  import { http } from 'msw';
2
- import type { AccountEventList200, AccountHostingList200, AccountPublicKey200, AccountPublicKeyCreate200, AccountPublicKeyDelete200, AccountPublicKeyToggle200, AccountPublicKeys200, ActivityLog200, AddCron200, AddHostingRedirects200, AddIndex200, AddPrivacy200, AddSiteIpaddress200, AddonCloudflare200, AddonsCloudflare200, AddonsInfo200, AddonsJetpackValidate200, AddonsSitelockSso200, AddonsSitelockSsoV2200, AddonsSpamexpertsSso200, BackupCreateV2200, BackupDownloadV2200, BackupInitiate200, BackupList200, BackupListV2200, BackupRestoreV2200, BackupStatus200, BackupStatusV2200, BackupsJetpackBackup200, CodeguardBackupCreate200, CodeguardBackupDownload200, CodeguardBackupList200, CodeguardBackupRestore200, CodeguardDatabaseBackupCreate200, CodeguardDatabaseBackupList200, CodeguardDatabaseBackupRestore200, CodeguardDatabaseList200, CodeguardLoginLink200, CodeguardPlanInfo200, CodeguardWebsiteBackupCreate200, CodeguardWebsiteBackupList200, CodeguardWebsiteBackupRestore200, CodeguardWebsiteList200, CreatePhpInfo200, Cron200, Db200, DbAdd200, DbCheckDatabase200, DbList200, DbListV2200, DbMultipleUserDatabase200, DbUsage200, DbUserAdd200, DbUserDelete200, DbUserList200, DbUserPasswordSet200, DbUserPrivsGet200, DbUserPrivsSet200, DbUserRename200, DirectoryPrivacy200, DomainCertInstall200, DomainCertUninstall200, DomainCertUpdate200, DomainCerts200, DomainDnsExport200, DomainDnsImport200, DomainDnseditor200, DomainDnseditorAdd200, DomainDnseditorEdit200, DomainDnseditorList200Item, DomainDnszoneReset200, DomainInfo200, DomainUnassign200, DomainZoneeditorUrl200, Domains200, EditPrivacy200, HostingAccount200, HostingAddons200, HostingAdvancedDns200, HostingAdvancedDnsUpdate200, HostingAdvancedDomainServices200, HostingAdvancedDomainServicesCheck200, HostingAdvancedPassword200, HostingAdvancedServer200, HostingAdvancedServerStatus200, HostingAdvancedSsoWhm200, HostingAdvancedSystemConsole200, HostingCapabilities200, HostingDbAuthorizedHosts200, HostingDbAuthorizedHostsAdd200, HostingDbAuthorizedHostsDelete200, HostingDbAuthorizedHostsUpdate200, HostingDomainAssign200, HostingDomainAvailability200, HostingDomainsUnassign200, HostingDomainsUnassignV2200, HostingEcommerceInfo200, HostingFixownership200, HostingFtp200, HostingFtpAdd200, HostingFtpList200, HostingFtpUpdate200, HostingInfo200, HostingInfoDiskUsage200, HostingLead200, HostingMigrationInfo200, HostingMigrationSiteScanStatus200, HostingMigrationStatus200, HostingMigrations200, HostingMigrationsCheck200, HostingMigrationsEvent200, HostingNameservers200, HostingNameserversV2200, HostingOnboardingData200, HostingOnboardingDataUpdate200, HostingRedirect200, HostingRedirects200Item, HostingRedirectsV2200Item, HostingResellerSsoWhm200, HostingShellInfo200, HostingShellToggle200, HostingSiteAdd200, HostingSiteAddV2200, HostingSitesV2200, HostingSshInfo200, HostingVisitors200, HotlinkconfigAdd200, HotlinkconfigDelete200, HotlinkconfigDetails200, Index200, JetpackBackupStatus200, ListCrons200, ListFiles200, ListFilesV2200, ListIndex200, PasswordGenerate200, PasswordScore200, PhpErrors200, Privacy200, PrivacyUser200, RepairDatabase200, ResetSite200, Site200, SiteAddonCloudflare200, SiteInfoResponseModelV2, SiteIpaddress200, SiteIpaddressList200Item, SiteMalwareStatus200, SitePendingDomainDelete200, SitePluginUpdate200, SitePlugins200, SitePluginsAutoupdate200, SitePluginsToggle200, SitePluginsUpdate200, SiteQualityMetrics200, SiteStatus200, SiteUpdate200, SiteUsers200, SitesAccessLogs200, SitesAutoupdatesResponse, SitesBackups200, SitesBackupsCodeguard200, SitesBackupsDetails200, SitesBatch200, SitesDatabaseInfo200, SitesDatabasePasswordsync200, SitesDns200, SitesDomain200, SitesDomainUrl200, SitesDomainsCreate200, SitesDomainsV2200, SitesErrorLogs200, SitesHasBackups200, SitesInfo200, SitesListV2200, SitesListV3200, SitesMetricDimensions200, SitesMetricsDimensionAveraged200, SitesPerformanceCachepurge200, SitesPerformanceEdgecache200, SitesPerformanceEnduranceCacheLevel200, SitesPerformanceEnduranceCacheLevelStatus200, SitesPerformanceEndurancePageCache200, SitesSecurityBundle200, SitesSecurityCheckCore200, SitesSecurityHttpsEnableDisableSsl200, SitesSecurityHttpsRedirectionStatus200, SitesSecurityResetCoreFiles200, SitesSecuritySitelock200, SitesSecuritySitelockV2200, SitesSecuritySslAcme200, SitesSecuritySslStatus200, SitesSettingsComingSoon200, SitesSettingsComingSoonToggle200, SitesSettingsDebug200, SitesSettingsDebugToggle200, SitesSettingsPhpVersionUpdate200, SitesSettingsPhpVersions200, SitesSshUserCreate200, SitesSshUserDelete200, SitesSshUserList200, SitesSshUserListV2200, SitesSshUserUpdate200, SitesSsl200, SitesSso200, SitesVersion200, SshKey200, SshKeyFetch200, SshKeyGenerate200, SshKeyImport200, SshKeyImportV2200, SshKeyImportV3200, SshKeyList200, SshKeyListV2200, SshKeyListV3200, SshKeyListV4200, SshKeyV2200, Sso200, StagingSitePromote200, UpdateCron200, WebzaiSso200, WeeblySso200 } from './index.schemas';
2
+ import type { AccountEventList200, AccountHostingList200, AccountPublicKey200, AccountPublicKeyCreate200, AccountPublicKeyDelete200, AccountPublicKeyToggle200, AccountPublicKeys200, ActivityLog200, AddCron200, AddHostingRedirects200, AddIndex200, AddPrivacy200, AddSiteIpaddress200, AddonCloudflare200, AddonsCloudflare200, AddonsInfo200, AddonsJetpackValidate200, AddonsSitelockSso200, AddonsSitelockSsoV2200, AddonsSpamexpertsSso200, BackupCreateV2200, BackupDownloadV2200, BackupInitiate200, BackupList200, BackupListV2200, BackupRestoreV2200, BackupStatus200, BackupStatusV2200, BackupsJetpackBackup200, CodeguardBackupCreate200, CodeguardBackupDownload200, CodeguardBackupList200, CodeguardBackupRestore200, CodeguardDatabaseBackupCreate200, CodeguardDatabaseBackupList200, CodeguardDatabaseBackupRestore200, CodeguardDatabaseList200, CodeguardLoginLink200, CodeguardPlanInfo200, CodeguardWebsiteBackupCreate200, CodeguardWebsiteBackupList200, CodeguardWebsiteBackupRestore200, CodeguardWebsiteList200, CreatePhpInfo200, Cron200, Db200, DbAdd200, DbCheckDatabase200, DbList200, DbListV2200, DbMultipleUserDatabase200, DbUsage200, DbUserAdd200, DbUserDelete200, DbUserList200, DbUserPasswordSet200, DbUserPrivsGet200, DbUserPrivsSet200, DbUserRename200, DirectoryPrivacy200, DomainCertInstall200, DomainCertUninstall200, DomainCertUpdate200, DomainCerts200, DomainDnsExport200, DomainDnsImport200, DomainDnseditor200, DomainDnseditorAdd200, DomainDnseditorEdit200, DomainDnseditorList200Item, DomainDnszoneReset200, DomainInfo200, DomainUnassign200, DomainZoneeditorUrl200, Domains200, EditPrivacy200, HostingAccount200, HostingAddons200, HostingAdvancedDns200, HostingAdvancedDnsUpdate200, HostingAdvancedDomainServices200, HostingAdvancedDomainServicesCheck200, HostingAdvancedPassword200, HostingAdvancedServer200, HostingAdvancedServerStatus200, HostingAdvancedSsoWhm200, HostingAdvancedSystemConsole200, HostingCapabilities200, HostingDbAuthorizedHosts200, HostingDbAuthorizedHostsAdd200, HostingDbAuthorizedHostsDelete200, HostingDbAuthorizedHostsUpdate200, HostingDomainAssign200, HostingDomainAvailability200, HostingDomainsUnassign200, HostingDomainsUnassignV2200, HostingEcommerceInfo200, HostingEmailAdd200, HostingEmailDelete200, HostingEmailList200, HostingFixownership200, HostingFtp200, HostingFtpAdd200, HostingFtpList200, HostingFtpUpdate200, HostingInfo200, HostingInfoDiskUsage200, HostingLead200, HostingMigrationInfo200, HostingMigrationSiteScanStatus200, HostingMigrationStatus200, HostingMigrations200, HostingMigrationsCheck200, HostingMigrationsEvent200, HostingNameservers200, HostingNameserversV2200, HostingOnboardingData200, HostingOnboardingDataUpdate200, HostingRedirect200, HostingRedirects200Item, HostingRedirectsV2200Item, HostingResellerSsoWhm200, HostingShellInfo200, HostingShellToggle200, HostingSiteAdd200, HostingSiteAddV2200, HostingSitesV2200, HostingSshInfo200, HostingVisitors200, HotlinkconfigAdd200, HotlinkconfigDelete200, HotlinkconfigDetails200, Index200, JetpackBackupStatus200, ListCrons200, ListFiles200, ListFilesV2200, ListIndex200, PasswordGenerate200, PasswordScore200, PhpErrors200, Privacy200, PrivacyUser200, RepairDatabase200, ResetSite200, Site200, SiteAddonCloudflare200, SiteInfoResponseModelV2, SiteIpaddress200, SiteIpaddressList200Item, SiteMalwareStatus200, SitePendingDomainDelete200, SitePluginUpdate200, SitePlugins200, SitePluginsAutoupdate200, SitePluginsToggle200, SitePluginsUpdate200, SiteQualityMetrics200, SiteStatus200, SiteUpdate200, SiteUsers200, SitesAccessLogs200, SitesAutoupdatesResponse, SitesBackups200, SitesBackupsCodeguard200, SitesBackupsDetails200, SitesBatch200, SitesDatabaseInfo200, SitesDatabasePasswordsync200, SitesDns200, SitesDomain200, SitesDomainUrl200, SitesDomainsCreate200, SitesDomainsV2200, SitesErrorLogs200, SitesHasBackups200, SitesInfo200, SitesListV2200, SitesListV3200, SitesMetricDimensions200, SitesMetricsDimensionAveraged200, SitesPerformanceCachepurge200, SitesPerformanceEdgecache200, SitesPerformanceEnduranceCacheLevel200, SitesPerformanceEnduranceCacheLevelStatus200, SitesPerformanceEndurancePageCache200, SitesSecurityBundle200, SitesSecurityCheckCore200, SitesSecurityHttpsEnableDisableSsl200, SitesSecurityHttpsRedirectionStatus200, SitesSecurityResetCoreFiles200, SitesSecuritySitelock200, SitesSecuritySitelockV2200, SitesSecuritySslAcme200, SitesSecuritySslStatus200, SitesSettingsComingSoon200, SitesSettingsComingSoonToggle200, SitesSettingsDebug200, SitesSettingsDebugToggle200, SitesSettingsPhpVersionUpdate200, SitesSettingsPhpVersions200, SitesSshUserCreate200, SitesSshUserDelete200, SitesSshUserList200, SitesSshUserListV2200, SitesSshUserUpdate200, SitesSsl200, SitesSso200, SitesVersion200, SshKey200, SshKeyFetch200, SshKeyGenerate200, SshKeyImport200, SshKeyImportV2200, SshKeyImportV3200, SshKeyList200, SshKeyListV2200, SshKeyListV3200, SshKeyListV4200, SshKeyV2200, Sso200, StagingSitePromote200, UpdateCron200, WebzaiSso200, WeeblySso200 } from './index.schemas';
3
3
  export declare const getAccountEventListResponseMock: (overrideResponse?: Partial<AccountEventList200>) => AccountEventList200;
4
4
  export declare const getAccountHostingListResponseMock: (overrideResponse?: Partial<AccountHostingList200>) => AccountHostingList200;
5
5
  export declare const getAccountPublicKeysResponseMock: (overrideResponse?: Partial<AccountPublicKeys200>) => AccountPublicKeys200;
@@ -91,6 +91,9 @@ export declare const getDomainDnsExportResponseMock: (overrideResponse?: Partial
91
91
  export declare const getDomainDnsImportResponseMock: (overrideResponse?: Partial<DomainDnsImport200>) => DomainDnsImport200;
92
92
  export declare const getHostingDomainsUnassignResponseMock: (overrideResponse?: Partial<HostingDomainsUnassign200>) => HostingDomainsUnassign200;
93
93
  export declare const getHostingEcommerceInfoResponseMock: (overrideResponse?: Partial<HostingEcommerceInfo200>) => HostingEcommerceInfo200;
94
+ export declare const getHostingEmailAddResponseMock: (overrideResponse?: Partial<HostingEmailAdd200>) => HostingEmailAdd200;
95
+ export declare const getHostingEmailDeleteResponseMock: (overrideResponse?: Partial<HostingEmailDelete200>) => HostingEmailDelete200;
96
+ export declare const getHostingEmailListResponseMock: (overrideResponse?: Partial<HostingEmailList200>) => HostingEmailList200;
94
97
  export declare const getListFilesResponseMock: (overrideResponse?: Partial<ListFiles200>) => ListFiles200;
95
98
  export declare const getHostingFixownershipResponseMock: (overrideResponse?: Partial<HostingFixownership200>) => HostingFixownership200;
96
99
  export declare const getHostingFtpListResponseMock: (overrideResponse?: Partial<HostingFtpList200>) => HostingFtpList200;
@@ -314,6 +317,9 @@ export declare const getDomainDnsExportMockHandler: (overrideResponse?: DomainDn
314
317
  export declare const getDomainDnsImportMockHandler: (overrideResponse?: DomainDnsImport200 | ((info: Parameters<Parameters<typeof http.post>[1]>[0]) => Promise<DomainDnsImport200> | DomainDnsImport200) | undefined) => import("msw/lib/core/handlers/HttpHandler").HttpHandler;
315
318
  export declare const getHostingDomainsUnassignMockHandler: (overrideResponse?: HostingDomainsUnassign200 | ((info: Parameters<Parameters<typeof http.post>[1]>[0]) => Promise<HostingDomainsUnassign200> | HostingDomainsUnassign200) | undefined) => import("msw/lib/core/handlers/HttpHandler").HttpHandler;
316
319
  export declare const getHostingEcommerceInfoMockHandler: (overrideResponse?: HostingEcommerceInfo200 | ((info: Parameters<Parameters<typeof http.get>[1]>[0]) => Promise<HostingEcommerceInfo200> | HostingEcommerceInfo200) | undefined) => import("msw/lib/core/handlers/HttpHandler").HttpHandler;
320
+ export declare const getHostingEmailAddMockHandler: (overrideResponse?: HostingEmailAdd200 | ((info: Parameters<Parameters<typeof http.post>[1]>[0]) => Promise<HostingEmailAdd200> | HostingEmailAdd200) | undefined) => import("msw/lib/core/handlers/HttpHandler").HttpHandler;
321
+ export declare const getHostingEmailDeleteMockHandler: (overrideResponse?: HostingEmailDelete200 | ((info: Parameters<Parameters<typeof http.delete>[1]>[0]) => Promise<HostingEmailDelete200> | HostingEmailDelete200) | undefined) => import("msw/lib/core/handlers/HttpHandler").HttpHandler;
322
+ export declare const getHostingEmailListMockHandler: (overrideResponse?: HostingEmailList200 | ((info: Parameters<Parameters<typeof http.get>[1]>[0]) => Promise<HostingEmailList200> | HostingEmailList200) | undefined) => import("msw/lib/core/handlers/HttpHandler").HttpHandler;
317
323
  export declare const getListFilesMockHandler: (overrideResponse?: ListFiles200 | ((info: Parameters<Parameters<typeof http.get>[1]>[0]) => Promise<ListFiles200> | ListFiles200) | undefined) => import("msw/lib/core/handlers/HttpHandler").HttpHandler;
318
324
  export declare const getHostingFixownershipMockHandler: (overrideResponse?: HostingFixownership200 | ((info: Parameters<Parameters<typeof http.post>[1]>[0]) => Promise<HostingFixownership200> | HostingFixownership200) | undefined) => import("msw/lib/core/handlers/HttpHandler").HttpHandler;
319
325
  export declare const getHostingFtpListMockHandler: (overrideResponse?: HostingFtpList200 | ((info: Parameters<Parameters<typeof http.get>[1]>[0]) => Promise<HostingFtpList200> | HostingFtpList200) | undefined) => import("msw/lib/core/handlers/HttpHandler").HttpHandler;
package/src/index.msw.js CHANGED
@@ -4,7 +4,7 @@ import { __awaiter } from "tslib";
4
4
  * Do not edit manually.
5
5
  * Hosting UAPI
6
6
  * Hosting UAPI is an API to expose Hosting, Addons, and Site functionality to a customer-facing Front End such as (Account Manager).
7
- * OpenAPI spec version: 1.1286.0
7
+ * OpenAPI spec version: 1.1288.0
8
8
  */
9
9
  import { faker } from '@faker-js/faker';
10
10
  import { HttpResponse, delay, http } from 'msw';
@@ -101,6 +101,9 @@ export const getDomainDnsExportResponseMock = (overrideResponse = {}) => (Object
101
101
  export const getDomainDnsImportResponseMock = (overrideResponse = {}) => (Object.assign({ success: faker.helpers.arrayElement([faker.datatype.boolean(), undefined]) }, overrideResponse));
102
102
  export const getHostingDomainsUnassignResponseMock = (overrideResponse = {}) => (Object.assign({ queued: faker.helpers.arrayElement([faker.datatype.boolean(), undefined]) }, overrideResponse));
103
103
  export const getHostingEcommerceInfoResponseMock = (overrideResponse = {}) => (Object.assign({ addon_id: faker.helpers.arrayElement([faker.number.int({ min: undefined, max: undefined }), undefined]), back_ref: faker.helpers.arrayElement([faker.word.sample(), undefined]), level: faker.helpers.arrayElement([faker.word.sample(), undefined]), name: faker.helpers.arrayElement([faker.word.sample(), undefined]), status: faker.helpers.arrayElement([faker.word.sample(), undefined]), subtype: faker.helpers.arrayElement([faker.helpers.arrayElement([faker.word.sample(), null]), undefined]), type: faker.helpers.arrayElement([faker.word.sample(), undefined]) }, overrideResponse));
104
+ export const getHostingEmailAddResponseMock = (overrideResponse = {}) => (Object.assign({ address: faker.helpers.arrayElement([faker.word.sample(), undefined]) }, overrideResponse));
105
+ export const getHostingEmailDeleteResponseMock = (overrideResponse = {}) => (Object.assign({}, overrideResponse));
106
+ export const getHostingEmailListResponseMock = (overrideResponse = {}) => (Object.assign({ rows: faker.helpers.arrayElement([Array.from({ length: faker.number.int({ min: 1, max: 10 }) }, (_, i) => i + 1).map(() => ({ address: faker.helpers.arrayElement([faker.word.sample(), undefined]), disk_used_kib: faker.helpers.arrayElement([faker.number.int({ min: undefined, max: undefined }), undefined]), files: faker.helpers.arrayElement([faker.number.int({ min: undefined, max: undefined }), undefined]), type: faker.helpers.arrayElement([faker.word.sample(), undefined]) })), undefined]) }, overrideResponse));
104
107
  export const getListFilesResponseMock = (overrideResponse = {}) => (Object.assign({ files: faker.helpers.arrayElement([Array.from({ length: faker.number.int({ min: 1, max: 10 }) }, (_, i) => i + 1).map(() => ({ file: faker.helpers.arrayElement([faker.word.sample(), undefined]), path: faker.helpers.arrayElement([faker.word.sample(), undefined]), size: faker.helpers.arrayElement([faker.number.int({ min: undefined, max: undefined }), undefined]), type: faker.helpers.arrayElement([faker.word.sample(), undefined]) })), undefined]) }, overrideResponse));
105
108
  export const getHostingFixownershipResponseMock = (overrideResponse = {}) => (Object.assign({ success: faker.helpers.arrayElement([faker.datatype.boolean(), undefined]) }, overrideResponse));
106
109
  export const getHostingFtpListResponseMock = (overrideResponse = {}) => (Object.assign({ ftp_accounts: faker.helpers.arrayElement([Array.from({ length: faker.number.int({ min: 1, max: 10 }) }, (_, i) => i + 1).map(() => ({ account: faker.helpers.arrayElement([faker.word.sample(), undefined]), domain: faker.helpers.arrayElement([faker.word.sample(), undefined]), homedir: faker.helpers.arrayElement([faker.word.sample(), undefined]), type: faker.helpers.arrayElement([faker.word.sample(), undefined]), user: faker.helpers.arrayElement([faker.word.sample(), undefined]) })), undefined]), server_name: faker.helpers.arrayElement([faker.word.sample(), undefined]), special_ftp_accounts: faker.helpers.arrayElement([Array.from({ length: faker.number.int({ min: 1, max: 10 }) }, (_, i) => i + 1).map(() => ({ account: faker.helpers.arrayElement([faker.word.sample(), undefined]), domain: faker.helpers.arrayElement([faker.word.sample(), undefined]), homedir: faker.helpers.arrayElement([faker.word.sample(), undefined]), type: faker.helpers.arrayElement([faker.word.sample(), undefined]), user: faker.helpers.arrayElement([faker.word.sample(), undefined]) })), undefined]) }, overrideResponse));
@@ -1163,6 +1166,36 @@ export const getHostingEcommerceInfoMockHandler = (overrideResponse) => {
1163
1166
  });
1164
1167
  }));
1165
1168
  };
1169
+ export const getHostingEmailAddMockHandler = (overrideResponse) => {
1170
+ return http.post('*/v1/hosting/:hostingId/emails', (info) => __awaiter(void 0, void 0, void 0, function* () {
1171
+ yield delay(1000);
1172
+ return new HttpResponse(JSON.stringify(overrideResponse !== undefined
1173
+ ? (typeof overrideResponse === "function" ? yield overrideResponse(info) : overrideResponse)
1174
+ : getHostingEmailAddResponseMock()), { status: 200,
1175
+ headers: { 'Content-Type': 'application/json' }
1176
+ });
1177
+ }));
1178
+ };
1179
+ export const getHostingEmailDeleteMockHandler = (overrideResponse) => {
1180
+ return http.delete('*/v1/hosting/:hostingId/emails', (info) => __awaiter(void 0, void 0, void 0, function* () {
1181
+ yield delay(1000);
1182
+ return new HttpResponse(JSON.stringify(overrideResponse !== undefined
1183
+ ? (typeof overrideResponse === "function" ? yield overrideResponse(info) : overrideResponse)
1184
+ : getHostingEmailDeleteResponseMock()), { status: 200,
1185
+ headers: { 'Content-Type': 'application/json' }
1186
+ });
1187
+ }));
1188
+ };
1189
+ export const getHostingEmailListMockHandler = (overrideResponse) => {
1190
+ return http.get('*/v1/hosting/:hostingId/emails', (info) => __awaiter(void 0, void 0, void 0, function* () {
1191
+ yield delay(1000);
1192
+ return new HttpResponse(JSON.stringify(overrideResponse !== undefined
1193
+ ? (typeof overrideResponse === "function" ? yield overrideResponse(info) : overrideResponse)
1194
+ : getHostingEmailListResponseMock()), { status: 200,
1195
+ headers: { 'Content-Type': 'application/json' }
1196
+ });
1197
+ }));
1198
+ };
1166
1199
  export const getListFilesMockHandler = (overrideResponse) => {
1167
1200
  return http.get('*/v1/hosting/:hostingId/files', (info) => __awaiter(void 0, void 0, void 0, function* () {
1168
1201
  yield delay(1000);
@@ -2595,6 +2628,9 @@ export const getHostingUAPIMock = () => [
2595
2628
  getDomainDnsImportMockHandler(),
2596
2629
  getHostingDomainsUnassignMockHandler(),
2597
2630
  getHostingEcommerceInfoMockHandler(),
2631
+ getHostingEmailAddMockHandler(),
2632
+ getHostingEmailDeleteMockHandler(),
2633
+ getHostingEmailListMockHandler(),
2598
2634
  getListFilesMockHandler(),
2599
2635
  getHostingFixownershipMockHandler(),
2600
2636
  getHostingFtpListMockHandler(),
@@ -3,7 +3,7 @@
3
3
  * Do not edit manually.
4
4
  * Hosting UAPI
5
5
  * Hosting UAPI is an API to expose Hosting, Addons, and Site functionality to a customer-facing Front End such as (Account Manager).
6
- * OpenAPI spec version: 1.1286.0
6
+ * OpenAPI spec version: 1.1288.0
7
7
  */
8
8
  export declare type SshKeyListV4200RowsItem = {
9
9
  authorize?: boolean;
@@ -203,17 +203,6 @@ export declare type SitesDomainsV2200 = {
203
203
  export declare type SitesDomainsV2Params = {
204
204
  scan?: boolean;
205
205
  };
206
- export declare type SitesListV2200 = {
207
- items?: SitesListV2200ItemsItem[];
208
- /** page size */
209
- limit?: number;
210
- /** current page number */
211
- page?: number;
212
- /** total number of pages */
213
- pages?: number;
214
- /** total number of sites returned */
215
- total?: number;
216
- };
217
206
  /**
218
207
  * @nullable
219
208
  */
@@ -369,6 +358,17 @@ export declare type SitesListV2200ItemsItem = {
369
358
  */
370
359
  version_ptr?: string | null;
371
360
  };
361
+ export declare type SitesListV2200 = {
362
+ items?: SitesListV2200ItemsItem[];
363
+ /** page size */
364
+ limit?: number;
365
+ /** current page number */
366
+ page?: number;
367
+ /** total number of pages */
368
+ pages?: number;
369
+ /** total number of sites returned */
370
+ total?: number;
371
+ };
372
372
  export declare type SshKeyV2200 = {
373
373
  deleted?: number;
374
374
  key_name?: string;
@@ -2503,6 +2503,69 @@ export declare type ListFilesParams = {
2503
2503
  path: string;
2504
2504
  showdotfiles?: boolean;
2505
2505
  };
2506
+ export declare type HostingEmailList200RowsItem = {
2507
+ /** The email address */
2508
+ address?: string;
2509
+ /** The amount of disk space used by the email */
2510
+ disk_used_kib?: number;
2511
+ /** The number of files in the email */
2512
+ files?: number;
2513
+ /** The type of email */
2514
+ type?: string;
2515
+ };
2516
+ export declare type HostingEmailList200 = {
2517
+ /** List of email resources */
2518
+ rows?: HostingEmailList200RowsItem[];
2519
+ };
2520
+ export declare type HostingEmailDelete200 = {
2521
+ [key: string]: unknown;
2522
+ };
2523
+ export declare type HostingEmailDeleteParams = {
2524
+ address: string;
2525
+ };
2526
+ export declare type HostingEmailAdd512 = {
2527
+ /** Customer error code */
2528
+ error?: string;
2529
+ };
2530
+ export declare type HostingEmailAdd409 = {
2531
+ /** Customer error code */
2532
+ error?: string;
2533
+ };
2534
+ export declare type HostingEmailAdd403 = {
2535
+ /** Customer error code */
2536
+ error?: string;
2537
+ };
2538
+ export declare type HostingEmailAdd400 = {
2539
+ /** Customer error code */
2540
+ error?: string;
2541
+ };
2542
+ export declare type HostingEmailAdd200 = {
2543
+ /** The address that was created */
2544
+ address?: string;
2545
+ };
2546
+ /**
2547
+ * The type of email to add (defaults to 'box')
2548
+ */
2549
+ export declare type HostingEmailAddBodyType = typeof HostingEmailAddBodyType[keyof typeof HostingEmailAddBodyType];
2550
+ export declare const HostingEmailAddBodyType: {
2551
+ readonly box: "box";
2552
+ readonly domainalias: "domainalias";
2553
+ readonly alias: "alias";
2554
+ readonly forwarder: "forwarder";
2555
+ readonly discard: "discard";
2556
+ readonly pipe: "pipe";
2557
+ readonly list: "list";
2558
+ };
2559
+ export declare type HostingEmailAddBody = {
2560
+ /** The email address to add */
2561
+ address: string;
2562
+ /** The password for the email */
2563
+ password: string;
2564
+ /** The quota for the email (optional) (default: 0 = unlimited) */
2565
+ quota?: number;
2566
+ /** The type of email to add (defaults to 'box') */
2567
+ type?: HostingEmailAddBodyType;
2568
+ };
2506
2569
  /**
2507
2570
  * @nullable
2508
2571
  */
@@ -3164,23 +3227,6 @@ export declare type ActivityLog200 = {
3164
3227
  export declare type ActivityLogParams = {
3165
3228
  days?: number;
3166
3229
  };
3167
- export declare type HostingAccount200 = {
3168
- account_id?: string;
3169
- advanced?: boolean;
3170
- billing?: HostingAccount200Billing;
3171
- brand?: string;
3172
- id?: string;
3173
- panel?: string;
3174
- plan_key?: string;
3175
- platform?: string;
3176
- /** @nullable */
3177
- resources?: HostingAccount200Resources;
3178
- /** @nullable */
3179
- ssh_hostname?: string | null;
3180
- status?: string;
3181
- type?: string;
3182
- username?: string;
3183
- };
3184
3230
  export declare type HostingAccount200ResourcesWorkers = {
3185
3231
  /** @nullable */
3186
3232
  available?: number | null;
@@ -3198,6 +3244,31 @@ export declare type HostingAccount200ResourcesStorage = {
3198
3244
  /** @nullable */
3199
3245
  used?: number | null;
3200
3246
  };
3247
+ /**
3248
+ * @nullable
3249
+ */
3250
+ export declare type HostingAccount200Resources = {
3251
+ staging?: HostingAccount200ResourcesStaging;
3252
+ storage?: HostingAccount200ResourcesStorage;
3253
+ workers?: HostingAccount200ResourcesWorkers;
3254
+ } | null;
3255
+ export declare type HostingAccount200 = {
3256
+ account_id?: string;
3257
+ advanced?: boolean;
3258
+ billing?: HostingAccount200Billing;
3259
+ brand?: string;
3260
+ id?: string;
3261
+ panel?: string;
3262
+ plan_key?: string;
3263
+ platform?: string;
3264
+ /** @nullable */
3265
+ resources?: HostingAccount200Resources;
3266
+ /** @nullable */
3267
+ ssh_hostname?: string | null;
3268
+ status?: string;
3269
+ type?: string;
3270
+ username?: string;
3271
+ };
3201
3272
  export declare type HostingAccount200ResourcesStagingWorkers = {
3202
3273
  /** @nullable */
3203
3274
  available?: number | null;
@@ -3219,14 +3290,6 @@ export declare type HostingAccount200ResourcesStaging = {
3219
3290
  storage?: HostingAccount200ResourcesStagingStorage;
3220
3291
  workers?: HostingAccount200ResourcesStagingWorkers;
3221
3292
  };
3222
- /**
3223
- * @nullable
3224
- */
3225
- export declare type HostingAccount200Resources = {
3226
- staging?: HostingAccount200ResourcesStaging;
3227
- storage?: HostingAccount200ResourcesStorage;
3228
- workers?: HostingAccount200ResourcesWorkers;
3229
- } | null;
3230
3293
  export declare type HostingAccount200Billing = {
3231
3294
  prod_code?: string;
3232
3295
  product_name?: string;
@@ -3503,6 +3566,9 @@ export declare type AddonsInfo200 = {
3503
3566
  export declare type AddonsCloudflare200 = {
3504
3567
  status?: string;
3505
3568
  };
3569
+ export declare type BackupList200 = {
3570
+ home?: BackupList200HomeItem[];
3571
+ };
3506
3572
  export declare type BackupList200HomeItemBackupStatus = {
3507
3573
  /** @nullable */
3508
3574
  download_url?: string | null;
@@ -3514,9 +3580,6 @@ export declare type BackupList200HomeItem = {
3514
3580
  backup_status?: BackupList200HomeItemBackupStatus;
3515
3581
  time_created?: string;
3516
3582
  };
3517
- export declare type BackupList200 = {
3518
- home?: BackupList200HomeItem[];
3519
- };
3520
3583
  export declare type BackupListBackupType = typeof BackupListBackupType[keyof typeof BackupListBackupType];
3521
3584
  export declare const BackupListBackupType: {
3522
3585
  readonly full: "full";
@@ -159,6 +159,16 @@ export const HostingFtpUpdateBodyUserTypeSet = {
159
159
  quota: 'quota',
160
160
  };
161
161
  // eslint-disable-next-line @typescript-eslint/no-redeclare
162
+ export const HostingEmailAddBodyType = {
163
+ box: 'box',
164
+ domainalias: 'domainalias',
165
+ alias: 'alias',
166
+ forwarder: 'forwarder',
167
+ discard: 'discard',
168
+ pipe: 'pipe',
169
+ list: 'list',
170
+ };
171
+ // eslint-disable-next-line @typescript-eslint/no-redeclare
162
172
  export const DomainsType = {
163
173
  addon: 'addon',
164
174
  main: 'main',