@newfold/huapi-js 2.1253.0 → 2.1262.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 +1 -1
- package/src/index.d.ts +161 -4
- package/src/index.js +119 -1
- package/src/index.msw.d.ts +11 -1
- package/src/index.msw.js +61 -1
- package/src/index.schemas.d.ts +113 -20
package/package.json
CHANGED
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, 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, Index200, IndexBody, JetpackBackupStatus200, ListCrons200, ListFiles200, ListFilesParams, ListFilesV2200, ListFilesV2Params, ListIndex200, ListIndexParams, 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, 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, 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, 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
|
/**
|
|
@@ -1428,6 +1428,69 @@ export declare function useHostingAddons<TData = Awaited<ReturnType<typeof hosti
|
|
|
1428
1428
|
}): UseQueryResult<TData, TError> & {
|
|
1429
1429
|
queryKey: QueryKey;
|
|
1430
1430
|
};
|
|
1431
|
+
/**
|
|
1432
|
+
* Checks for dns already exists
|
|
1433
|
+
* @summary advanced hosting dns check
|
|
1434
|
+
*/
|
|
1435
|
+
export declare const hostingAdvancedDns: (hostingId: string, params: HostingAdvancedDnsParams, options?: AxiosRequestConfig) => Promise<AxiosResponse<HostingAdvancedDns200>>;
|
|
1436
|
+
export declare const getHostingAdvancedDnsQueryKey: (hostingId: string, params: HostingAdvancedDnsParams) => readonly [`/v1/hosting/${string}/advanced/dns`, ...HostingAdvancedDnsParams[]];
|
|
1437
|
+
export declare const getHostingAdvancedDnsQueryOptions: <TData = AxiosResponse<HostingAdvancedDns200, any>, TError = AxiosError<unknown, any>>(hostingId: string, params: HostingAdvancedDnsParams, options?: {
|
|
1438
|
+
query?: Partial<UseQueryOptions<AxiosResponse<HostingAdvancedDns200, any>, TError, TData, QueryKey>> | undefined;
|
|
1439
|
+
axios?: AxiosRequestConfig<any> | undefined;
|
|
1440
|
+
} | undefined) => UseQueryOptions<AxiosResponse<HostingAdvancedDns200, any>, TError, TData, QueryKey> & {
|
|
1441
|
+
queryKey: QueryKey;
|
|
1442
|
+
};
|
|
1443
|
+
export declare type HostingAdvancedDnsQueryResult = NonNullable<Awaited<ReturnType<typeof hostingAdvancedDns>>>;
|
|
1444
|
+
export declare type HostingAdvancedDnsQueryError = AxiosError<unknown>;
|
|
1445
|
+
export declare function useHostingAdvancedDns<TData = Awaited<ReturnType<typeof hostingAdvancedDns>>, TError = AxiosError<unknown>>(hostingId: string, params: HostingAdvancedDnsParams, options: {
|
|
1446
|
+
query: Partial<UseQueryOptions<Awaited<ReturnType<typeof hostingAdvancedDns>>, TError, TData>> & Pick<DefinedInitialDataOptions<Awaited<ReturnType<typeof hostingAdvancedDns>>, TError, TData>, 'initialData'>;
|
|
1447
|
+
axios?: AxiosRequestConfig;
|
|
1448
|
+
}): DefinedUseQueryResult<TData, TError> & {
|
|
1449
|
+
queryKey: QueryKey;
|
|
1450
|
+
};
|
|
1451
|
+
export declare function useHostingAdvancedDns<TData = Awaited<ReturnType<typeof hostingAdvancedDns>>, TError = AxiosError<unknown>>(hostingId: string, params: HostingAdvancedDnsParams, options?: {
|
|
1452
|
+
query?: Partial<UseQueryOptions<Awaited<ReturnType<typeof hostingAdvancedDns>>, TError, TData>> & Pick<UndefinedInitialDataOptions<Awaited<ReturnType<typeof hostingAdvancedDns>>, TError, TData>, 'initialData'>;
|
|
1453
|
+
axios?: AxiosRequestConfig;
|
|
1454
|
+
}): UseQueryResult<TData, TError> & {
|
|
1455
|
+
queryKey: QueryKey;
|
|
1456
|
+
};
|
|
1457
|
+
export declare function useHostingAdvancedDns<TData = Awaited<ReturnType<typeof hostingAdvancedDns>>, TError = AxiosError<unknown>>(hostingId: string, params: HostingAdvancedDnsParams, options?: {
|
|
1458
|
+
query?: Partial<UseQueryOptions<Awaited<ReturnType<typeof hostingAdvancedDns>>, TError, TData>>;
|
|
1459
|
+
axios?: AxiosRequestConfig;
|
|
1460
|
+
}): UseQueryResult<TData, TError> & {
|
|
1461
|
+
queryKey: QueryKey;
|
|
1462
|
+
};
|
|
1463
|
+
/**
|
|
1464
|
+
* Update DNS Zone Info if it doesnt exists
|
|
1465
|
+
* @summary advanced hosting dns zone update
|
|
1466
|
+
*/
|
|
1467
|
+
export declare const hostingAdvancedDnsUpdate: (hostingId: string, hostingAdvancedDnsUpdateBody: HostingAdvancedDnsUpdateBody, options?: AxiosRequestConfig) => Promise<AxiosResponse<HostingAdvancedDnsUpdate200>>;
|
|
1468
|
+
export declare const getHostingAdvancedDnsUpdateMutationOptions: <TError = AxiosError<unknown, any>, TContext = unknown>(options?: {
|
|
1469
|
+
mutation?: UseMutationOptions<AxiosResponse<HostingAdvancedDnsUpdate200, any>, TError, {
|
|
1470
|
+
hostingId: string;
|
|
1471
|
+
data: HostingAdvancedDnsUpdateBody;
|
|
1472
|
+
}, TContext> | undefined;
|
|
1473
|
+
axios?: AxiosRequestConfig<any> | undefined;
|
|
1474
|
+
} | undefined) => UseMutationOptions<AxiosResponse<HostingAdvancedDnsUpdate200, any>, TError, {
|
|
1475
|
+
hostingId: string;
|
|
1476
|
+
data: HostingAdvancedDnsUpdateBody;
|
|
1477
|
+
}, TContext>;
|
|
1478
|
+
export declare type HostingAdvancedDnsUpdateMutationResult = NonNullable<Awaited<ReturnType<typeof hostingAdvancedDnsUpdate>>>;
|
|
1479
|
+
export declare type HostingAdvancedDnsUpdateMutationBody = HostingAdvancedDnsUpdateBody;
|
|
1480
|
+
export declare type HostingAdvancedDnsUpdateMutationError = AxiosError<unknown>;
|
|
1481
|
+
/**
|
|
1482
|
+
* @summary advanced hosting dns zone update
|
|
1483
|
+
*/
|
|
1484
|
+
export declare const useHostingAdvancedDnsUpdate: <TError = AxiosError<unknown, any>, TContext = unknown>(options?: {
|
|
1485
|
+
mutation?: UseMutationOptions<AxiosResponse<HostingAdvancedDnsUpdate200, any>, TError, {
|
|
1486
|
+
hostingId: string;
|
|
1487
|
+
data: HostingAdvancedDnsUpdateBody;
|
|
1488
|
+
}, TContext> | undefined;
|
|
1489
|
+
axios?: AxiosRequestConfig<any> | undefined;
|
|
1490
|
+
} | undefined) => UseMutationResult<AxiosResponse<HostingAdvancedDnsUpdate200, any>, TError, {
|
|
1491
|
+
hostingId: string;
|
|
1492
|
+
data: HostingAdvancedDnsUpdateBody;
|
|
1493
|
+
}, TContext>;
|
|
1431
1494
|
/**
|
|
1432
1495
|
* To check for the domain services configuration
|
|
1433
1496
|
* @summary Domain services configuration check
|
|
@@ -2968,6 +3031,100 @@ export declare const useHostingFtp: <TError = AxiosError<unknown, any>, TContext
|
|
|
2968
3031
|
hostingId: number;
|
|
2969
3032
|
data: HostingFtpBody;
|
|
2970
3033
|
}, TContext>;
|
|
3034
|
+
/**
|
|
3035
|
+
* Hotlink configuration details
|
|
3036
|
+
* @summary Hotlink configuration details
|
|
3037
|
+
*/
|
|
3038
|
+
export declare const hotlinkconfigDetails: (hostingId: string, params: HotlinkconfigDetailsParams, options?: AxiosRequestConfig) => Promise<AxiosResponse<HotlinkconfigDetails200>>;
|
|
3039
|
+
export declare const getHotlinkconfigDetailsQueryKey: (hostingId: string, params: HotlinkconfigDetailsParams) => readonly [`/v1/hosting/${string}/hotlinkconfig`, ...HotlinkconfigDetailsParams[]];
|
|
3040
|
+
export declare const getHotlinkconfigDetailsQueryOptions: <TData = AxiosResponse<HotlinkconfigDetails200, any>, TError = AxiosError<unknown, any>>(hostingId: string, params: HotlinkconfigDetailsParams, options?: {
|
|
3041
|
+
query?: Partial<UseQueryOptions<AxiosResponse<HotlinkconfigDetails200, any>, TError, TData, QueryKey>> | undefined;
|
|
3042
|
+
axios?: AxiosRequestConfig<any> | undefined;
|
|
3043
|
+
} | undefined) => UseQueryOptions<AxiosResponse<HotlinkconfigDetails200, any>, TError, TData, QueryKey> & {
|
|
3044
|
+
queryKey: QueryKey;
|
|
3045
|
+
};
|
|
3046
|
+
export declare type HotlinkconfigDetailsQueryResult = NonNullable<Awaited<ReturnType<typeof hotlinkconfigDetails>>>;
|
|
3047
|
+
export declare type HotlinkconfigDetailsQueryError = AxiosError<unknown>;
|
|
3048
|
+
export declare function useHotlinkconfigDetails<TData = Awaited<ReturnType<typeof hotlinkconfigDetails>>, TError = AxiosError<unknown>>(hostingId: string, params: HotlinkconfigDetailsParams, options: {
|
|
3049
|
+
query: Partial<UseQueryOptions<Awaited<ReturnType<typeof hotlinkconfigDetails>>, TError, TData>> & Pick<DefinedInitialDataOptions<Awaited<ReturnType<typeof hotlinkconfigDetails>>, TError, TData>, 'initialData'>;
|
|
3050
|
+
axios?: AxiosRequestConfig;
|
|
3051
|
+
}): DefinedUseQueryResult<TData, TError> & {
|
|
3052
|
+
queryKey: QueryKey;
|
|
3053
|
+
};
|
|
3054
|
+
export declare function useHotlinkconfigDetails<TData = Awaited<ReturnType<typeof hotlinkconfigDetails>>, TError = AxiosError<unknown>>(hostingId: string, params: HotlinkconfigDetailsParams, options?: {
|
|
3055
|
+
query?: Partial<UseQueryOptions<Awaited<ReturnType<typeof hotlinkconfigDetails>>, TError, TData>> & Pick<UndefinedInitialDataOptions<Awaited<ReturnType<typeof hotlinkconfigDetails>>, TError, TData>, 'initialData'>;
|
|
3056
|
+
axios?: AxiosRequestConfig;
|
|
3057
|
+
}): UseQueryResult<TData, TError> & {
|
|
3058
|
+
queryKey: QueryKey;
|
|
3059
|
+
};
|
|
3060
|
+
export declare function useHotlinkconfigDetails<TData = Awaited<ReturnType<typeof hotlinkconfigDetails>>, TError = AxiosError<unknown>>(hostingId: string, params: HotlinkconfigDetailsParams, options?: {
|
|
3061
|
+
query?: Partial<UseQueryOptions<Awaited<ReturnType<typeof hotlinkconfigDetails>>, TError, TData>>;
|
|
3062
|
+
axios?: AxiosRequestConfig;
|
|
3063
|
+
}): UseQueryResult<TData, TError> & {
|
|
3064
|
+
queryKey: QueryKey;
|
|
3065
|
+
};
|
|
3066
|
+
/**
|
|
3067
|
+
* Add/Update hotlink configuration
|
|
3068
|
+
* @summary Add/Update hotlink configuration
|
|
3069
|
+
*/
|
|
3070
|
+
export declare const hotlinkconfigAdd: (hostingId: string, hotlinkconfigAddBody: HotlinkconfigAddBody, options?: AxiosRequestConfig) => Promise<AxiosResponse<HotlinkconfigAdd200>>;
|
|
3071
|
+
export declare const getHotlinkconfigAddMutationOptions: <TError = AxiosError<unknown, any>, TContext = unknown>(options?: {
|
|
3072
|
+
mutation?: UseMutationOptions<AxiosResponse<HotlinkconfigAdd200, any>, TError, {
|
|
3073
|
+
hostingId: string;
|
|
3074
|
+
data: HotlinkconfigAddBody;
|
|
3075
|
+
}, TContext> | undefined;
|
|
3076
|
+
axios?: AxiosRequestConfig<any> | undefined;
|
|
3077
|
+
} | undefined) => UseMutationOptions<AxiosResponse<HotlinkconfigAdd200, any>, TError, {
|
|
3078
|
+
hostingId: string;
|
|
3079
|
+
data: HotlinkconfigAddBody;
|
|
3080
|
+
}, TContext>;
|
|
3081
|
+
export declare type HotlinkconfigAddMutationResult = NonNullable<Awaited<ReturnType<typeof hotlinkconfigAdd>>>;
|
|
3082
|
+
export declare type HotlinkconfigAddMutationBody = HotlinkconfigAddBody;
|
|
3083
|
+
export declare type HotlinkconfigAddMutationError = AxiosError<unknown>;
|
|
3084
|
+
/**
|
|
3085
|
+
* @summary Add/Update hotlink configuration
|
|
3086
|
+
*/
|
|
3087
|
+
export declare const useHotlinkconfigAdd: <TError = AxiosError<unknown, any>, TContext = unknown>(options?: {
|
|
3088
|
+
mutation?: UseMutationOptions<AxiosResponse<HotlinkconfigAdd200, any>, TError, {
|
|
3089
|
+
hostingId: string;
|
|
3090
|
+
data: HotlinkconfigAddBody;
|
|
3091
|
+
}, TContext> | undefined;
|
|
3092
|
+
axios?: AxiosRequestConfig<any> | undefined;
|
|
3093
|
+
} | undefined) => UseMutationResult<AxiosResponse<HotlinkconfigAdd200, any>, TError, {
|
|
3094
|
+
hostingId: string;
|
|
3095
|
+
data: HotlinkconfigAddBody;
|
|
3096
|
+
}, TContext>;
|
|
3097
|
+
/**
|
|
3098
|
+
* Delete hotlink configuration
|
|
3099
|
+
* @summary Delete hotlink configuration
|
|
3100
|
+
*/
|
|
3101
|
+
export declare const hotlinkconfigDelete: (hostingId: string, hotlinkconfigDeleteBody: HotlinkconfigDeleteBody, options?: AxiosRequestConfig) => Promise<AxiosResponse<HotlinkconfigDelete200>>;
|
|
3102
|
+
export declare const getHotlinkconfigDeleteMutationOptions: <TError = AxiosError<unknown, any>, TContext = unknown>(options?: {
|
|
3103
|
+
mutation?: UseMutationOptions<AxiosResponse<HotlinkconfigDelete200, any>, TError, {
|
|
3104
|
+
hostingId: string;
|
|
3105
|
+
data: HotlinkconfigDeleteBody;
|
|
3106
|
+
}, TContext> | undefined;
|
|
3107
|
+
axios?: AxiosRequestConfig<any> | undefined;
|
|
3108
|
+
} | undefined) => UseMutationOptions<AxiosResponse<HotlinkconfigDelete200, any>, TError, {
|
|
3109
|
+
hostingId: string;
|
|
3110
|
+
data: HotlinkconfigDeleteBody;
|
|
3111
|
+
}, TContext>;
|
|
3112
|
+
export declare type HotlinkconfigDeleteMutationResult = NonNullable<Awaited<ReturnType<typeof hotlinkconfigDelete>>>;
|
|
3113
|
+
export declare type HotlinkconfigDeleteMutationBody = HotlinkconfigDeleteBody;
|
|
3114
|
+
export declare type HotlinkconfigDeleteMutationError = AxiosError<unknown>;
|
|
3115
|
+
/**
|
|
3116
|
+
* @summary Delete hotlink configuration
|
|
3117
|
+
*/
|
|
3118
|
+
export declare const useHotlinkconfigDelete: <TError = AxiosError<unknown, any>, TContext = unknown>(options?: {
|
|
3119
|
+
mutation?: UseMutationOptions<AxiosResponse<HotlinkconfigDelete200, any>, TError, {
|
|
3120
|
+
hostingId: string;
|
|
3121
|
+
data: HotlinkconfigDeleteBody;
|
|
3122
|
+
}, TContext> | undefined;
|
|
3123
|
+
axios?: AxiosRequestConfig<any> | undefined;
|
|
3124
|
+
} | undefined) => UseMutationResult<AxiosResponse<HotlinkconfigDelete200, any>, TError, {
|
|
3125
|
+
hostingId: string;
|
|
3126
|
+
data: HotlinkconfigDeleteBody;
|
|
3127
|
+
}, TContext>;
|
|
2971
3128
|
/**
|
|
2972
3129
|
* List indexed files/folders
|
|
2973
3130
|
* @summary List indexed files/folders
|
|
@@ -5925,7 +6082,7 @@ export declare function useSitesSso<TData = Awaited<ReturnType<typeof sitesSso>>
|
|
|
5925
6082
|
* @summary Staging site promotion
|
|
5926
6083
|
*/
|
|
5927
6084
|
export declare const stagingSitePromote: (siteId: number, stagingSitePromoteBody: StagingSitePromoteBody, options?: AxiosRequestConfig) => Promise<AxiosResponse<StagingSitePromote200>>;
|
|
5928
|
-
export declare const getStagingSitePromoteMutationOptions: <TError = AxiosError<
|
|
6085
|
+
export declare const getStagingSitePromoteMutationOptions: <TError = AxiosError<StagingSitePromote409, any>, TContext = unknown>(options?: {
|
|
5929
6086
|
mutation?: UseMutationOptions<AxiosResponse<StagingSitePromote200, any>, TError, {
|
|
5930
6087
|
siteId: number;
|
|
5931
6088
|
data: StagingSitePromoteBody;
|
|
@@ -5937,11 +6094,11 @@ export declare const getStagingSitePromoteMutationOptions: <TError = AxiosError<
|
|
|
5937
6094
|
}, TContext>;
|
|
5938
6095
|
export declare type StagingSitePromoteMutationResult = NonNullable<Awaited<ReturnType<typeof stagingSitePromote>>>;
|
|
5939
6096
|
export declare type StagingSitePromoteMutationBody = StagingSitePromoteBody;
|
|
5940
|
-
export declare type StagingSitePromoteMutationError = AxiosError<
|
|
6097
|
+
export declare type StagingSitePromoteMutationError = AxiosError<StagingSitePromote409>;
|
|
5941
6098
|
/**
|
|
5942
6099
|
* @summary Staging site promotion
|
|
5943
6100
|
*/
|
|
5944
|
-
export declare const useStagingSitePromote: <TError = AxiosError<
|
|
6101
|
+
export declare const useStagingSitePromote: <TError = AxiosError<StagingSitePromote409, any>, TContext = unknown>(options?: {
|
|
5945
6102
|
mutation?: UseMutationOptions<AxiosResponse<StagingSitePromote200, any>, TError, {
|
|
5946
6103
|
siteId: number;
|
|
5947
6104
|
data: StagingSitePromoteBody;
|
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.
|
|
6
|
+
* OpenAPI spec version: 1.1262.0
|
|
7
7
|
*/
|
|
8
8
|
import { useInfiniteQuery, useMutation, useQuery } from '@tanstack/react-query';
|
|
9
9
|
import axios from 'axios';
|
|
@@ -1125,6 +1125,54 @@ export function useHostingAddons(hostingId, params, options) {
|
|
|
1125
1125
|
query.queryKey = queryOptions.queryKey;
|
|
1126
1126
|
return query;
|
|
1127
1127
|
}
|
|
1128
|
+
/**
|
|
1129
|
+
* Checks for dns already exists
|
|
1130
|
+
* @summary advanced hosting dns check
|
|
1131
|
+
*/
|
|
1132
|
+
export const hostingAdvancedDns = (hostingId, params, options) => {
|
|
1133
|
+
return axios.get(`/v1/hosting/${hostingId}/advanced/dns`, Object.assign(Object.assign({}, options), { params: Object.assign(Object.assign({}, params), options === null || options === void 0 ? void 0 : options.params) }));
|
|
1134
|
+
};
|
|
1135
|
+
export const getHostingAdvancedDnsQueryKey = (hostingId, params) => {
|
|
1136
|
+
return [`/v1/hosting/${hostingId}/advanced/dns`, ...(params ? [params] : [])];
|
|
1137
|
+
};
|
|
1138
|
+
export const getHostingAdvancedDnsQueryOptions = (hostingId, params, options) => {
|
|
1139
|
+
var _a;
|
|
1140
|
+
const { query: queryOptions, axios: axiosOptions } = options !== null && options !== void 0 ? options : {};
|
|
1141
|
+
const queryKey = (_a = queryOptions === null || queryOptions === void 0 ? void 0 : queryOptions.queryKey) !== null && _a !== void 0 ? _a : getHostingAdvancedDnsQueryKey(hostingId, params);
|
|
1142
|
+
const queryFn = ({ signal }) => hostingAdvancedDns(hostingId, params, Object.assign({ signal }, axiosOptions));
|
|
1143
|
+
return Object.assign({ queryKey, queryFn, enabled: !!(hostingId) }, queryOptions);
|
|
1144
|
+
};
|
|
1145
|
+
/**
|
|
1146
|
+
* @summary advanced hosting dns check
|
|
1147
|
+
*/
|
|
1148
|
+
export function useHostingAdvancedDns(hostingId, params, options) {
|
|
1149
|
+
const queryOptions = getHostingAdvancedDnsQueryOptions(hostingId, params, options);
|
|
1150
|
+
const query = useQuery(queryOptions);
|
|
1151
|
+
query.queryKey = queryOptions.queryKey;
|
|
1152
|
+
return query;
|
|
1153
|
+
}
|
|
1154
|
+
/**
|
|
1155
|
+
* Update DNS Zone Info if it doesnt exists
|
|
1156
|
+
* @summary advanced hosting dns zone update
|
|
1157
|
+
*/
|
|
1158
|
+
export const hostingAdvancedDnsUpdate = (hostingId, hostingAdvancedDnsUpdateBody, options) => {
|
|
1159
|
+
return axios.post(`/v1/hosting/${hostingId}/advanced/dns`, hostingAdvancedDnsUpdateBody, options);
|
|
1160
|
+
};
|
|
1161
|
+
export const getHostingAdvancedDnsUpdateMutationOptions = (options) => {
|
|
1162
|
+
const { mutation: mutationOptions, axios: axiosOptions } = options !== null && options !== void 0 ? options : {};
|
|
1163
|
+
const mutationFn = (props) => {
|
|
1164
|
+
const { hostingId, data } = props !== null && props !== void 0 ? props : {};
|
|
1165
|
+
return hostingAdvancedDnsUpdate(hostingId, data, axiosOptions);
|
|
1166
|
+
};
|
|
1167
|
+
return Object.assign({ mutationFn }, mutationOptions);
|
|
1168
|
+
};
|
|
1169
|
+
/**
|
|
1170
|
+
* @summary advanced hosting dns zone update
|
|
1171
|
+
*/
|
|
1172
|
+
export const useHostingAdvancedDnsUpdate = (options) => {
|
|
1173
|
+
const mutationOptions = getHostingAdvancedDnsUpdateMutationOptions(options);
|
|
1174
|
+
return useMutation(mutationOptions);
|
|
1175
|
+
};
|
|
1128
1176
|
/**
|
|
1129
1177
|
* To check for the domain services configuration
|
|
1130
1178
|
* @summary Domain services configuration check
|
|
@@ -2283,6 +2331,76 @@ export const useHostingFtp = (options) => {
|
|
|
2283
2331
|
const mutationOptions = getHostingFtpMutationOptions(options);
|
|
2284
2332
|
return useMutation(mutationOptions);
|
|
2285
2333
|
};
|
|
2334
|
+
/**
|
|
2335
|
+
* Hotlink configuration details
|
|
2336
|
+
* @summary Hotlink configuration details
|
|
2337
|
+
*/
|
|
2338
|
+
export const hotlinkconfigDetails = (hostingId, params, options) => {
|
|
2339
|
+
return axios.get(`/v1/hosting/${hostingId}/hotlinkconfig`, Object.assign(Object.assign({}, options), { params: Object.assign(Object.assign({}, params), options === null || options === void 0 ? void 0 : options.params) }));
|
|
2340
|
+
};
|
|
2341
|
+
export const getHotlinkconfigDetailsQueryKey = (hostingId, params) => {
|
|
2342
|
+
return [`/v1/hosting/${hostingId}/hotlinkconfig`, ...(params ? [params] : [])];
|
|
2343
|
+
};
|
|
2344
|
+
export const getHotlinkconfigDetailsQueryOptions = (hostingId, params, options) => {
|
|
2345
|
+
var _a;
|
|
2346
|
+
const { query: queryOptions, axios: axiosOptions } = options !== null && options !== void 0 ? options : {};
|
|
2347
|
+
const queryKey = (_a = queryOptions === null || queryOptions === void 0 ? void 0 : queryOptions.queryKey) !== null && _a !== void 0 ? _a : getHotlinkconfigDetailsQueryKey(hostingId, params);
|
|
2348
|
+
const queryFn = ({ signal }) => hotlinkconfigDetails(hostingId, params, Object.assign({ signal }, axiosOptions));
|
|
2349
|
+
return Object.assign({ queryKey, queryFn, enabled: !!(hostingId) }, queryOptions);
|
|
2350
|
+
};
|
|
2351
|
+
/**
|
|
2352
|
+
* @summary Hotlink configuration details
|
|
2353
|
+
*/
|
|
2354
|
+
export function useHotlinkconfigDetails(hostingId, params, options) {
|
|
2355
|
+
const queryOptions = getHotlinkconfigDetailsQueryOptions(hostingId, params, options);
|
|
2356
|
+
const query = useQuery(queryOptions);
|
|
2357
|
+
query.queryKey = queryOptions.queryKey;
|
|
2358
|
+
return query;
|
|
2359
|
+
}
|
|
2360
|
+
/**
|
|
2361
|
+
* Add/Update hotlink configuration
|
|
2362
|
+
* @summary Add/Update hotlink configuration
|
|
2363
|
+
*/
|
|
2364
|
+
export const hotlinkconfigAdd = (hostingId, hotlinkconfigAddBody, options) => {
|
|
2365
|
+
return axios.post(`/v1/hosting/${hostingId}/hotlinkconfig`, hotlinkconfigAddBody, options);
|
|
2366
|
+
};
|
|
2367
|
+
export const getHotlinkconfigAddMutationOptions = (options) => {
|
|
2368
|
+
const { mutation: mutationOptions, axios: axiosOptions } = options !== null && options !== void 0 ? options : {};
|
|
2369
|
+
const mutationFn = (props) => {
|
|
2370
|
+
const { hostingId, data } = props !== null && props !== void 0 ? props : {};
|
|
2371
|
+
return hotlinkconfigAdd(hostingId, data, axiosOptions);
|
|
2372
|
+
};
|
|
2373
|
+
return Object.assign({ mutationFn }, mutationOptions);
|
|
2374
|
+
};
|
|
2375
|
+
/**
|
|
2376
|
+
* @summary Add/Update hotlink configuration
|
|
2377
|
+
*/
|
|
2378
|
+
export const useHotlinkconfigAdd = (options) => {
|
|
2379
|
+
const mutationOptions = getHotlinkconfigAddMutationOptions(options);
|
|
2380
|
+
return useMutation(mutationOptions);
|
|
2381
|
+
};
|
|
2382
|
+
/**
|
|
2383
|
+
* Delete hotlink configuration
|
|
2384
|
+
* @summary Delete hotlink configuration
|
|
2385
|
+
*/
|
|
2386
|
+
export const hotlinkconfigDelete = (hostingId, hotlinkconfigDeleteBody, options) => {
|
|
2387
|
+
return axios.delete(`/v1/hosting/${hostingId}/hotlinkconfig`, Object.assign({ data: hotlinkconfigDeleteBody }, options));
|
|
2388
|
+
};
|
|
2389
|
+
export const getHotlinkconfigDeleteMutationOptions = (options) => {
|
|
2390
|
+
const { mutation: mutationOptions, axios: axiosOptions } = options !== null && options !== void 0 ? options : {};
|
|
2391
|
+
const mutationFn = (props) => {
|
|
2392
|
+
const { hostingId, data } = props !== null && props !== void 0 ? props : {};
|
|
2393
|
+
return hotlinkconfigDelete(hostingId, data, axiosOptions);
|
|
2394
|
+
};
|
|
2395
|
+
return Object.assign({ mutationFn }, mutationOptions);
|
|
2396
|
+
};
|
|
2397
|
+
/**
|
|
2398
|
+
* @summary Delete hotlink configuration
|
|
2399
|
+
*/
|
|
2400
|
+
export const useHotlinkconfigDelete = (options) => {
|
|
2401
|
+
const mutationOptions = getHotlinkconfigDeleteMutationOptions(options);
|
|
2402
|
+
return useMutation(mutationOptions);
|
|
2403
|
+
};
|
|
2286
2404
|
/**
|
|
2287
2405
|
* List indexed files/folders
|
|
2288
2406
|
* @summary List indexed files/folders
|
package/src/index.msw.d.ts
CHANGED
|
@@ -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, 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, Index200, JetpackBackupStatus200, ListCrons200, ListFiles200, ListFilesV2200, ListIndex200, 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, 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, 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;
|
|
@@ -46,6 +46,8 @@ export declare const getDomainZoneeditorUrlResponseMock: (overrideResponse?: Par
|
|
|
46
46
|
export declare const getHostingAccountResponseMock: (overrideResponse?: Partial<HostingAccount200>) => HostingAccount200;
|
|
47
47
|
export declare const getActivityLogResponseMock: (overrideResponse?: Partial<ActivityLog200>) => ActivityLog200;
|
|
48
48
|
export declare const getHostingAddonsResponseMock: (overrideResponse?: Partial<HostingAddons200>) => HostingAddons200;
|
|
49
|
+
export declare const getHostingAdvancedDnsResponseMock: (overrideResponse?: Partial<HostingAdvancedDns200>) => HostingAdvancedDns200;
|
|
50
|
+
export declare const getHostingAdvancedDnsUpdateResponseMock: (overrideResponse?: Partial<HostingAdvancedDnsUpdate200>) => HostingAdvancedDnsUpdate200;
|
|
49
51
|
export declare const getHostingAdvancedDomainServicesCheckResponseMock: (overrideResponse?: Partial<HostingAdvancedDomainServicesCheck200>) => HostingAdvancedDomainServicesCheck200;
|
|
50
52
|
export declare const getHostingAdvancedDomainServicesResponseMock: (overrideResponse?: Partial<HostingAdvancedDomainServices200>) => HostingAdvancedDomainServices200;
|
|
51
53
|
export declare const getHostingAdvancedServerResponseMock: (overrideResponse?: Partial<HostingAdvancedServer200>) => HostingAdvancedServer200;
|
|
@@ -95,6 +97,9 @@ export declare const getHostingFtpListResponseMock: (overrideResponse?: Partial<
|
|
|
95
97
|
export declare const getHostingFtpAddResponseMock: (overrideResponse?: Partial<HostingFtpAdd200>) => HostingFtpAdd200;
|
|
96
98
|
export declare const getHostingFtpUpdateResponseMock: (overrideResponse?: Partial<HostingFtpUpdate200>) => HostingFtpUpdate200;
|
|
97
99
|
export declare const getHostingFtpResponseMock: (overrideResponse?: Partial<HostingFtp200>) => HostingFtp200;
|
|
100
|
+
export declare const getHotlinkconfigDetailsResponseMock: (overrideResponse?: Partial<HotlinkconfigDetails200>) => HotlinkconfigDetails200;
|
|
101
|
+
export declare const getHotlinkconfigAddResponseMock: (overrideResponse?: Partial<HotlinkconfigAdd200>) => HotlinkconfigAdd200;
|
|
102
|
+
export declare const getHotlinkconfigDeleteResponseMock: (overrideResponse?: Partial<HotlinkconfigDelete200>) => HotlinkconfigDelete200;
|
|
98
103
|
export declare const getListIndexResponseMock: (overrideResponse?: Partial<ListIndex200>) => ListIndex200;
|
|
99
104
|
export declare const getAddIndexResponseMock: (overrideResponse?: Partial<AddIndex200>) => AddIndex200;
|
|
100
105
|
export declare const getIndexResponseMock: (overrideResponse?: Partial<Index200>) => Index200;
|
|
@@ -261,6 +266,8 @@ export declare const getDomainZoneeditorUrlMockHandler: (overrideResponse?: Doma
|
|
|
261
266
|
export declare const getHostingAccountMockHandler: (overrideResponse?: HostingAccount200 | ((info: Parameters<Parameters<typeof http.get>[1]>[0]) => Promise<HostingAccount200> | HostingAccount200) | undefined) => import("msw/lib/core/handlers/HttpHandler").HttpHandler;
|
|
262
267
|
export declare const getActivityLogMockHandler: (overrideResponse?: ActivityLog200 | ((info: Parameters<Parameters<typeof http.get>[1]>[0]) => Promise<ActivityLog200> | ActivityLog200) | undefined) => import("msw/lib/core/handlers/HttpHandler").HttpHandler;
|
|
263
268
|
export declare const getHostingAddonsMockHandler: (overrideResponse?: HostingAddons200 | ((info: Parameters<Parameters<typeof http.get>[1]>[0]) => Promise<HostingAddons200> | HostingAddons200) | undefined) => import("msw/lib/core/handlers/HttpHandler").HttpHandler;
|
|
269
|
+
export declare const getHostingAdvancedDnsMockHandler: (overrideResponse?: HostingAdvancedDns200 | ((info: Parameters<Parameters<typeof http.get>[1]>[0]) => Promise<HostingAdvancedDns200> | HostingAdvancedDns200) | undefined) => import("msw/lib/core/handlers/HttpHandler").HttpHandler;
|
|
270
|
+
export declare const getHostingAdvancedDnsUpdateMockHandler: (overrideResponse?: HostingAdvancedDnsUpdate200 | ((info: Parameters<Parameters<typeof http.post>[1]>[0]) => Promise<HostingAdvancedDnsUpdate200> | HostingAdvancedDnsUpdate200) | undefined) => import("msw/lib/core/handlers/HttpHandler").HttpHandler;
|
|
264
271
|
export declare const getHostingAdvancedDomainServicesCheckMockHandler: (overrideResponse?: HostingAdvancedDomainServicesCheck200 | ((info: Parameters<Parameters<typeof http.get>[1]>[0]) => Promise<HostingAdvancedDomainServicesCheck200> | HostingAdvancedDomainServicesCheck200) | undefined) => import("msw/lib/core/handlers/HttpHandler").HttpHandler;
|
|
265
272
|
export declare const getHostingAdvancedDomainServicesMockHandler: (overrideResponse?: HostingAdvancedDomainServices200 | ((info: Parameters<Parameters<typeof http.post>[1]>[0]) => Promise<HostingAdvancedDomainServices200> | HostingAdvancedDomainServices200) | undefined) => import("msw/lib/core/handlers/HttpHandler").HttpHandler;
|
|
266
273
|
export declare const getHostingAdvancedServerMockHandler: (overrideResponse?: HostingAdvancedServer200 | ((info: Parameters<Parameters<typeof http.get>[1]>[0]) => Promise<HostingAdvancedServer200> | HostingAdvancedServer200) | undefined) => import("msw/lib/core/handlers/HttpHandler").HttpHandler;
|
|
@@ -310,6 +317,9 @@ export declare const getHostingFtpListMockHandler: (overrideResponse?: HostingFt
|
|
|
310
317
|
export declare const getHostingFtpAddMockHandler: (overrideResponse?: HostingFtpAdd200 | ((info: Parameters<Parameters<typeof http.post>[1]>[0]) => Promise<HostingFtpAdd200> | HostingFtpAdd200) | undefined) => import("msw/lib/core/handlers/HttpHandler").HttpHandler;
|
|
311
318
|
export declare const getHostingFtpUpdateMockHandler: (overrideResponse?: HostingFtpUpdate200 | ((info: Parameters<Parameters<typeof http.put>[1]>[0]) => Promise<HostingFtpUpdate200> | HostingFtpUpdate200) | undefined) => import("msw/lib/core/handlers/HttpHandler").HttpHandler;
|
|
312
319
|
export declare const getHostingFtpMockHandler: (overrideResponse?: HostingFtp200 | ((info: Parameters<Parameters<typeof http.delete>[1]>[0]) => Promise<HostingFtp200> | HostingFtp200) | undefined) => import("msw/lib/core/handlers/HttpHandler").HttpHandler;
|
|
320
|
+
export declare const getHotlinkconfigDetailsMockHandler: (overrideResponse?: HotlinkconfigDetails200 | ((info: Parameters<Parameters<typeof http.get>[1]>[0]) => Promise<HotlinkconfigDetails200> | HotlinkconfigDetails200) | undefined) => import("msw/lib/core/handlers/HttpHandler").HttpHandler;
|
|
321
|
+
export declare const getHotlinkconfigAddMockHandler: (overrideResponse?: HotlinkconfigAdd200 | ((info: Parameters<Parameters<typeof http.post>[1]>[0]) => Promise<HotlinkconfigAdd200> | HotlinkconfigAdd200) | undefined) => import("msw/lib/core/handlers/HttpHandler").HttpHandler;
|
|
322
|
+
export declare const getHotlinkconfigDeleteMockHandler: (overrideResponse?: HotlinkconfigDelete200 | ((info: Parameters<Parameters<typeof http.delete>[1]>[0]) => Promise<HotlinkconfigDelete200> | HotlinkconfigDelete200) | undefined) => import("msw/lib/core/handlers/HttpHandler").HttpHandler;
|
|
313
323
|
export declare const getListIndexMockHandler: (overrideResponse?: ListIndex200 | ((info: Parameters<Parameters<typeof http.get>[1]>[0]) => Promise<ListIndex200> | ListIndex200) | undefined) => import("msw/lib/core/handlers/HttpHandler").HttpHandler;
|
|
314
324
|
export declare const getAddIndexMockHandler: (overrideResponse?: AddIndex200 | ((info: Parameters<Parameters<typeof http.post>[1]>[0]) => Promise<AddIndex200> | AddIndex200) | undefined) => import("msw/lib/core/handlers/HttpHandler").HttpHandler;
|
|
315
325
|
export declare const getIndexMockHandler: (overrideResponse?: Index200 | ((info: Parameters<Parameters<typeof http.delete>[1]>[0]) => Promise<Index200> | Index200) | 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.
|
|
7
|
+
* OpenAPI spec version: 1.1262.0
|
|
8
8
|
*/
|
|
9
9
|
import { faker } from '@faker-js/faker';
|
|
10
10
|
import { HttpResponse, delay, http } from 'msw';
|
|
@@ -56,6 +56,8 @@ export const getActivityLogResponseMock = (overrideResponse = {}) => (Object.ass
|
|
|
56
56
|
export const getHostingAddonsResponseMock = (overrideResponse = {}) => (Object.assign({ rows: faker.helpers.arrayElement([Array.from({ length: faker.number.int({ min: 1, max: 10 }) }, (_, i) => i + 1).map(() => ({ back_reference: faker.helpers.arrayElement([faker.helpers.arrayElement([faker.word.sample(), null]), undefined]), id: faker.helpers.arrayElement([faker.word.sample(), undefined]), meta: faker.helpers.arrayElement([{
|
|
57
57
|
[faker.string.alphanumeric(5)]: faker.helpers.arrayElement([faker.word.sample(), faker.number.int({ min: undefined, max: undefined }), faker.datatype.boolean()])
|
|
58
58
|
}, undefined]), ssh_hostname: faker.helpers.arrayElement([faker.helpers.arrayElement([faker.word.sample(), null]), undefined]), status: faker.helpers.arrayElement([faker.word.sample(), undefined]), status_user: faker.helpers.arrayElement([faker.word.sample(), undefined]), subtype: faker.helpers.arrayElement([faker.word.sample(), undefined]), type: faker.helpers.arrayElement([faker.word.sample(), undefined]) })), undefined]) }, overrideResponse));
|
|
59
|
+
export const getHostingAdvancedDnsResponseMock = (overrideResponse = {}) => (Object.assign({ dns: faker.helpers.arrayElement([Array.from({ length: faker.number.int({ min: 1, max: 10 }) }, (_, i) => i + 1).map(() => ({ content: faker.helpers.arrayElement([faker.helpers.arrayElement([faker.word.sample(), null]), undefined]), name: faker.helpers.arrayElement([faker.helpers.arrayElement([faker.word.sample(), null]), undefined]), ttl: faker.helpers.arrayElement([faker.helpers.arrayElement([faker.number.int({ min: undefined, max: undefined }), null]), undefined]), type: faker.helpers.arrayElement([faker.helpers.arrayElement([faker.word.sample(), null]), undefined]) })), undefined]) }, overrideResponse));
|
|
60
|
+
export const getHostingAdvancedDnsUpdateResponseMock = (overrideResponse = {}) => (Object.assign({}, overrideResponse));
|
|
59
61
|
export const getHostingAdvancedDomainServicesCheckResponseMock = (overrideResponse = {}) => (Object.assign({ configure_domain_services: faker.helpers.arrayElement([faker.number.int({ min: undefined, max: undefined }), undefined]) }, overrideResponse));
|
|
60
62
|
export const getHostingAdvancedDomainServicesResponseMock = (overrideResponse = {}) => (Object.assign({ success: faker.helpers.arrayElement([faker.number.int({ min: undefined, max: undefined }), undefined]) }, overrideResponse));
|
|
61
63
|
export const getHostingAdvancedServerResponseMock = (overrideResponse = {}) => (Object.assign({ actions: faker.helpers.arrayElement([{}, undefined]), hostname: faker.helpers.arrayElement([faker.word.sample(), undefined]), ips: faker.helpers.arrayElement([{ other_ips: faker.helpers.arrayElement([Array.from({ length: faker.number.int({ min: 1, max: 10 }) }, (_, i) => i + 1).map(() => (faker.word.sample())), undefined]), primary_ip: faker.helpers.arrayElement([faker.word.sample(), undefined]) }, undefined]), os_name: faker.helpers.arrayElement([faker.word.sample(), undefined]), os_version: faker.helpers.arrayElement([faker.word.sample(), undefined]), status: faker.helpers.arrayElement([faker.word.sample(), undefined]), uptime: faker.helpers.arrayElement([faker.word.sample(), undefined]), uptime_seconds: faker.helpers.arrayElement([faker.number.int({ min: undefined, max: undefined }), undefined]) }, overrideResponse));
|
|
@@ -105,6 +107,9 @@ export const getHostingFtpListResponseMock = (overrideResponse = {}) => (Object.
|
|
|
105
107
|
export const getHostingFtpAddResponseMock = (overrideResponse = {}) => (Object.assign({ pass: faker.helpers.arrayElement([faker.word.sample(), undefined]), user: faker.helpers.arrayElement([faker.word.sample(), undefined]) }, overrideResponse));
|
|
106
108
|
export const getHostingFtpUpdateResponseMock = (overrideResponse = {}) => (Object.assign({ status: faker.helpers.arrayElement([faker.number.int({ min: undefined, max: undefined }), undefined]) }, overrideResponse));
|
|
107
109
|
export const getHostingFtpResponseMock = (overrideResponse = {}) => (Object.assign({ status: faker.helpers.arrayElement([faker.number.int({ min: undefined, max: undefined }), undefined]), user: faker.helpers.arrayElement([faker.word.sample(), undefined]) }, overrideResponse));
|
|
110
|
+
export const getHotlinkconfigDetailsResponseMock = (overrideResponse = {}) => (Object.assign({ direct_request: faker.helpers.arrayElement([faker.number.int({ min: undefined, max: undefined }), undefined]), file_types: faker.helpers.arrayElement([Array.from({ length: faker.number.int({ min: 1, max: 10 }) }, (_, i) => i + 1).map(() => (faker.word.sample())), undefined]), protocol_type: faker.helpers.arrayElement([faker.word.sample(), undefined]), redirect_url: faker.helpers.arrayElement([faker.word.sample(), undefined]) }, overrideResponse));
|
|
111
|
+
export const getHotlinkconfigAddResponseMock = (overrideResponse = {}) => (Object.assign({}, overrideResponse));
|
|
112
|
+
export const getHotlinkconfigDeleteResponseMock = (overrideResponse = {}) => (Object.assign({}, overrideResponse));
|
|
108
113
|
export const getListIndexResponseMock = (overrideResponse = {}) => (Object.assign({ indexes: faker.helpers.arrayElement([Array.from({ length: faker.number.int({ min: 1, max: 10 }) }, (_, i) => i + 1).map(() => ({ index_options: faker.helpers.arrayElement([Array.from({ length: faker.number.int({ min: 1, max: 10 }) }, (_, i) => i + 1).map(() => (faker.word.sample())), undefined]), path: faker.helpers.arrayElement([faker.word.sample(), undefined]), status: faker.helpers.arrayElement([faker.word.sample(), undefined]), type: faker.helpers.arrayElement([faker.word.sample(), undefined]) })), undefined]) }, overrideResponse));
|
|
109
114
|
export const getAddIndexResponseMock = (overrideResponse = {}) => (Object.assign({ file: faker.helpers.arrayElement([faker.word.sample(), undefined]), status: faker.helpers.arrayElement([faker.word.sample(), undefined]) }, overrideResponse));
|
|
110
115
|
export const getIndexResponseMock = (overrideResponse = {}) => (Object.assign({ file: faker.helpers.arrayElement([faker.word.sample(), undefined]), success: faker.helpers.arrayElement([faker.number.int({ min: undefined, max: undefined }), undefined]) }, overrideResponse));
|
|
@@ -705,6 +710,26 @@ export const getHostingAddonsMockHandler = (overrideResponse) => {
|
|
|
705
710
|
});
|
|
706
711
|
}));
|
|
707
712
|
};
|
|
713
|
+
export const getHostingAdvancedDnsMockHandler = (overrideResponse) => {
|
|
714
|
+
return http.get('*/v1/hosting/:hostingId/advanced/dns', (info) => __awaiter(void 0, void 0, void 0, function* () {
|
|
715
|
+
yield delay(1000);
|
|
716
|
+
return new HttpResponse(JSON.stringify(overrideResponse !== undefined
|
|
717
|
+
? (typeof overrideResponse === "function" ? yield overrideResponse(info) : overrideResponse)
|
|
718
|
+
: getHostingAdvancedDnsResponseMock()), { status: 200,
|
|
719
|
+
headers: { 'Content-Type': 'application/json' }
|
|
720
|
+
});
|
|
721
|
+
}));
|
|
722
|
+
};
|
|
723
|
+
export const getHostingAdvancedDnsUpdateMockHandler = (overrideResponse) => {
|
|
724
|
+
return http.post('*/v1/hosting/:hostingId/advanced/dns', (info) => __awaiter(void 0, void 0, void 0, function* () {
|
|
725
|
+
yield delay(1000);
|
|
726
|
+
return new HttpResponse(JSON.stringify(overrideResponse !== undefined
|
|
727
|
+
? (typeof overrideResponse === "function" ? yield overrideResponse(info) : overrideResponse)
|
|
728
|
+
: getHostingAdvancedDnsUpdateResponseMock()), { status: 200,
|
|
729
|
+
headers: { 'Content-Type': 'application/json' }
|
|
730
|
+
});
|
|
731
|
+
}));
|
|
732
|
+
};
|
|
708
733
|
export const getHostingAdvancedDomainServicesCheckMockHandler = (overrideResponse) => {
|
|
709
734
|
return http.get('*/v1/hosting/:hostingId/advanced/domain/services', (info) => __awaiter(void 0, void 0, void 0, function* () {
|
|
710
735
|
yield delay(1000);
|
|
@@ -1195,6 +1220,36 @@ export const getHostingFtpMockHandler = (overrideResponse) => {
|
|
|
1195
1220
|
});
|
|
1196
1221
|
}));
|
|
1197
1222
|
};
|
|
1223
|
+
export const getHotlinkconfigDetailsMockHandler = (overrideResponse) => {
|
|
1224
|
+
return http.get('*/v1/hosting/:hostingId/hotlinkconfig', (info) => __awaiter(void 0, void 0, void 0, function* () {
|
|
1225
|
+
yield delay(1000);
|
|
1226
|
+
return new HttpResponse(JSON.stringify(overrideResponse !== undefined
|
|
1227
|
+
? (typeof overrideResponse === "function" ? yield overrideResponse(info) : overrideResponse)
|
|
1228
|
+
: getHotlinkconfigDetailsResponseMock()), { status: 200,
|
|
1229
|
+
headers: { 'Content-Type': 'application/json' }
|
|
1230
|
+
});
|
|
1231
|
+
}));
|
|
1232
|
+
};
|
|
1233
|
+
export const getHotlinkconfigAddMockHandler = (overrideResponse) => {
|
|
1234
|
+
return http.post('*/v1/hosting/:hostingId/hotlinkconfig', (info) => __awaiter(void 0, void 0, void 0, function* () {
|
|
1235
|
+
yield delay(1000);
|
|
1236
|
+
return new HttpResponse(JSON.stringify(overrideResponse !== undefined
|
|
1237
|
+
? (typeof overrideResponse === "function" ? yield overrideResponse(info) : overrideResponse)
|
|
1238
|
+
: getHotlinkconfigAddResponseMock()), { status: 200,
|
|
1239
|
+
headers: { 'Content-Type': 'application/json' }
|
|
1240
|
+
});
|
|
1241
|
+
}));
|
|
1242
|
+
};
|
|
1243
|
+
export const getHotlinkconfigDeleteMockHandler = (overrideResponse) => {
|
|
1244
|
+
return http.delete('*/v1/hosting/:hostingId/hotlinkconfig', (info) => __awaiter(void 0, void 0, void 0, function* () {
|
|
1245
|
+
yield delay(1000);
|
|
1246
|
+
return new HttpResponse(JSON.stringify(overrideResponse !== undefined
|
|
1247
|
+
? (typeof overrideResponse === "function" ? yield overrideResponse(info) : overrideResponse)
|
|
1248
|
+
: getHotlinkconfigDeleteResponseMock()), { status: 200,
|
|
1249
|
+
headers: { 'Content-Type': 'application/json' }
|
|
1250
|
+
});
|
|
1251
|
+
}));
|
|
1252
|
+
};
|
|
1198
1253
|
export const getListIndexMockHandler = (overrideResponse) => {
|
|
1199
1254
|
return http.get('*/v1/hosting/:hostingId/index', (info) => __awaiter(void 0, void 0, void 0, function* () {
|
|
1200
1255
|
yield delay(1000);
|
|
@@ -2462,6 +2517,8 @@ export const getHostingUAPIMock = () => [
|
|
|
2462
2517
|
getHostingAccountMockHandler(),
|
|
2463
2518
|
getActivityLogMockHandler(),
|
|
2464
2519
|
getHostingAddonsMockHandler(),
|
|
2520
|
+
getHostingAdvancedDnsMockHandler(),
|
|
2521
|
+
getHostingAdvancedDnsUpdateMockHandler(),
|
|
2465
2522
|
getHostingAdvancedDomainServicesCheckMockHandler(),
|
|
2466
2523
|
getHostingAdvancedDomainServicesMockHandler(),
|
|
2467
2524
|
getHostingAdvancedServerMockHandler(),
|
|
@@ -2511,6 +2568,9 @@ export const getHostingUAPIMock = () => [
|
|
|
2511
2568
|
getHostingFtpAddMockHandler(),
|
|
2512
2569
|
getHostingFtpUpdateMockHandler(),
|
|
2513
2570
|
getHostingFtpMockHandler(),
|
|
2571
|
+
getHotlinkconfigDetailsMockHandler(),
|
|
2572
|
+
getHotlinkconfigAddMockHandler(),
|
|
2573
|
+
getHotlinkconfigDeleteMockHandler(),
|
|
2514
2574
|
getListIndexMockHandler(),
|
|
2515
2575
|
getAddIndexMockHandler(),
|
|
2516
2576
|
getIndexMockHandler(),
|
package/src/index.schemas.d.ts
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.
|
|
6
|
+
* OpenAPI spec version: 1.1262.0
|
|
7
7
|
*/
|
|
8
8
|
export declare type SshKeyListV4200RowsItem = {
|
|
9
9
|
authorize?: boolean;
|
|
@@ -203,6 +203,17 @@ 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
|
+
};
|
|
206
217
|
/**
|
|
207
218
|
* @nullable
|
|
208
219
|
*/
|
|
@@ -358,17 +369,6 @@ export declare type SitesListV2200ItemsItem = {
|
|
|
358
369
|
*/
|
|
359
370
|
version_ptr?: string | null;
|
|
360
371
|
};
|
|
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;
|
|
@@ -794,6 +794,45 @@ export declare type SiteStatus200 = {
|
|
|
794
794
|
pending_url?: string;
|
|
795
795
|
url?: string;
|
|
796
796
|
};
|
|
797
|
+
export declare type StagingSitePromote409DetailsLimitsItem = {
|
|
798
|
+
/**
|
|
799
|
+
* Respective limit that exceeded.
|
|
800
|
+
* @nullable
|
|
801
|
+
*/
|
|
802
|
+
limit?: string | null;
|
|
803
|
+
/**
|
|
804
|
+
* maximum limit allowed.
|
|
805
|
+
* @nullable
|
|
806
|
+
*/
|
|
807
|
+
max?: string | null;
|
|
808
|
+
/**
|
|
809
|
+
* site Id where the respective limit is exceeded.
|
|
810
|
+
* @nullable
|
|
811
|
+
*/
|
|
812
|
+
site_id?: string | null;
|
|
813
|
+
/**
|
|
814
|
+
* Type of limit exceeded.
|
|
815
|
+
* @nullable
|
|
816
|
+
*/
|
|
817
|
+
type?: string | null;
|
|
818
|
+
/**
|
|
819
|
+
* current usage.
|
|
820
|
+
* @nullable
|
|
821
|
+
*/
|
|
822
|
+
used?: number | null;
|
|
823
|
+
};
|
|
824
|
+
/**
|
|
825
|
+
* @nullable
|
|
826
|
+
*/
|
|
827
|
+
export declare type StagingSitePromote409Details = {
|
|
828
|
+
limits?: StagingSitePromote409DetailsLimitsItem[];
|
|
829
|
+
} | null;
|
|
830
|
+
export declare type StagingSitePromote409 = {
|
|
831
|
+
/** @nullable */
|
|
832
|
+
details?: StagingSitePromote409Details;
|
|
833
|
+
/** @nullable */
|
|
834
|
+
error?: string | null;
|
|
835
|
+
};
|
|
797
836
|
export declare type StagingSitePromote200 = {
|
|
798
837
|
/** @nullable */
|
|
799
838
|
job_id?: number | null;
|
|
@@ -2326,6 +2365,31 @@ export declare type ListIndex200 = {
|
|
|
2326
2365
|
export declare type ListIndexParams = {
|
|
2327
2366
|
path?: string;
|
|
2328
2367
|
};
|
|
2368
|
+
export declare type HotlinkconfigDelete200 = {
|
|
2369
|
+
[key: string]: unknown;
|
|
2370
|
+
};
|
|
2371
|
+
export declare type HotlinkconfigDeleteBody = {
|
|
2372
|
+
docpath: string;
|
|
2373
|
+
};
|
|
2374
|
+
export declare type HotlinkconfigAdd200 = {
|
|
2375
|
+
[key: string]: unknown;
|
|
2376
|
+
};
|
|
2377
|
+
export declare type HotlinkconfigAddBody = {
|
|
2378
|
+
direct_request: number;
|
|
2379
|
+
docpath: string;
|
|
2380
|
+
file_types: string[];
|
|
2381
|
+
protocol_type: string;
|
|
2382
|
+
redirect_url?: string;
|
|
2383
|
+
};
|
|
2384
|
+
export declare type HotlinkconfigDetails200 = {
|
|
2385
|
+
direct_request?: number;
|
|
2386
|
+
file_types?: string[];
|
|
2387
|
+
protocol_type?: string;
|
|
2388
|
+
redirect_url?: string;
|
|
2389
|
+
};
|
|
2390
|
+
export declare type HotlinkconfigDetailsParams = {
|
|
2391
|
+
docpath: string;
|
|
2392
|
+
};
|
|
2329
2393
|
export declare type HostingFtp200 = {
|
|
2330
2394
|
status?: number;
|
|
2331
2395
|
/** Username */
|
|
@@ -3009,6 +3073,35 @@ export declare type HostingAdvancedDomainServicesBody = {
|
|
|
3009
3073
|
export declare type HostingAdvancedDomainServicesCheck200 = {
|
|
3010
3074
|
configure_domain_services?: number;
|
|
3011
3075
|
};
|
|
3076
|
+
export declare type HostingAdvancedDnsUpdate200 = {
|
|
3077
|
+
[key: string]: unknown;
|
|
3078
|
+
};
|
|
3079
|
+
export declare type HostingAdvancedDnsUpdateBody = {
|
|
3080
|
+
/** Domain name */
|
|
3081
|
+
domain: string;
|
|
3082
|
+
/** Server Hostname */
|
|
3083
|
+
hostname: string;
|
|
3084
|
+
/** Server IP */
|
|
3085
|
+
server_ip: string;
|
|
3086
|
+
};
|
|
3087
|
+
export declare type HostingAdvancedDns200DnsItem = {
|
|
3088
|
+
/** @nullable */
|
|
3089
|
+
content?: string | null;
|
|
3090
|
+
/** @nullable */
|
|
3091
|
+
name?: string | null;
|
|
3092
|
+
/** @nullable */
|
|
3093
|
+
ttl?: number | null;
|
|
3094
|
+
/** @nullable */
|
|
3095
|
+
type?: string | null;
|
|
3096
|
+
};
|
|
3097
|
+
export declare type HostingAdvancedDns200 = {
|
|
3098
|
+
dns?: HostingAdvancedDns200DnsItem[];
|
|
3099
|
+
};
|
|
3100
|
+
export declare type HostingAdvancedDnsParams = {
|
|
3101
|
+
hostname: string;
|
|
3102
|
+
domain: string;
|
|
3103
|
+
dns_with_us?: number;
|
|
3104
|
+
};
|
|
3012
3105
|
export declare type HostingAddons200RowsItemMeta = {
|
|
3013
3106
|
[key: string]: string | number | boolean;
|
|
3014
3107
|
};
|
|
@@ -3086,14 +3179,6 @@ export declare type HostingAccount200ResourcesStorage = {
|
|
|
3086
3179
|
/** @nullable */
|
|
3087
3180
|
used?: number | null;
|
|
3088
3181
|
};
|
|
3089
|
-
/**
|
|
3090
|
-
* @nullable
|
|
3091
|
-
*/
|
|
3092
|
-
export declare type HostingAccount200Resources = {
|
|
3093
|
-
staging?: HostingAccount200ResourcesStaging;
|
|
3094
|
-
storage?: HostingAccount200ResourcesStorage;
|
|
3095
|
-
workers?: HostingAccount200ResourcesWorkers;
|
|
3096
|
-
} | null;
|
|
3097
3182
|
export declare type HostingAccount200ResourcesStagingWorkers = {
|
|
3098
3183
|
/** @nullable */
|
|
3099
3184
|
available?: number | null;
|
|
@@ -3115,6 +3200,14 @@ export declare type HostingAccount200ResourcesStaging = {
|
|
|
3115
3200
|
storage?: HostingAccount200ResourcesStagingStorage;
|
|
3116
3201
|
workers?: HostingAccount200ResourcesStagingWorkers;
|
|
3117
3202
|
};
|
|
3203
|
+
/**
|
|
3204
|
+
* @nullable
|
|
3205
|
+
*/
|
|
3206
|
+
export declare type HostingAccount200Resources = {
|
|
3207
|
+
staging?: HostingAccount200ResourcesStaging;
|
|
3208
|
+
storage?: HostingAccount200ResourcesStorage;
|
|
3209
|
+
workers?: HostingAccount200ResourcesWorkers;
|
|
3210
|
+
} | null;
|
|
3118
3211
|
export declare type HostingAccount200Billing = {
|
|
3119
3212
|
prod_code?: string;
|
|
3120
3213
|
product_name?: string;
|