@newfold/huapi-js 1.560.0 → 1.568.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.4.0"
11
11
  },
12
12
  "module": "dist/index.ts",
13
- "version": "1.560.0",
13
+ "version": "1.568.0",
14
14
  "sideEffects": false,
15
15
  "main": "./src/index.js",
16
16
  "types": "./src/index.d.ts",
package/src/index.d.ts CHANGED
@@ -3,12 +3,12 @@
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.560.0
6
+ * OpenAPI spec version: 1.568.0
7
7
  */
8
8
  import axios from 'axios';
9
9
  import type { AxiosRequestConfig, AxiosResponse, AxiosError } from 'axios';
10
10
  import type { UseQueryOptions, UseMutationOptions, UseQueryResult, QueryKey } from '@tanstack/react-query';
11
- import type { CodeguardBackupList200, CodeguardBackupListParams, CodeguardBackupCreate200, CodeguardBackupCreateBody, CodeguardBackupDownload200, CodeguardBackupDownloadBody, CodeguardBackupRestore200, CodeguardBackupRestoreBody, CodeguardDatabaseList200, CodeguardDatabaseBackupList200, CodeguardDatabaseBackupListParams, CodeguardDatabaseBackupCreate200, CodeguardDatabaseBackupCreateBody, CodeguardDatabaseBackupRestore200, CodeguardDatabaseBackupRestoreBody, CodeguardLoginLink200, CodeguardPlanInfo200, CodeguardWebsiteList200, CodeguardWebsiteBackupList200, CodeguardWebsiteBackupListParams, CodeguardWebsiteBackupCreate200, CodeguardWebsiteBackupCreateBody, CodeguardWebsiteBackupRestore200, CodeguardWebsiteBackupRestoreBody, AddonsSitelockSso200, AddonsCloudflare200, AddonsInfo200, AddonsSpamexpertsSso200, HostingAccount200, HostingAddons200, HostingAddonsParams, HostingAdvancedServer200, HostingAdvancedServerStatus200, HostingAdvancedServerStatusBody, HostingAdvancedPassword200, HostingAdvancedPasswordBody, HostingAdvancedSsoWhm200, HostingAdvancedSystemConsole200, HostingCapabilities200, AddonCloudflare200, AddonCloudflareBody, ListCrons200, AddCron200, AddCron400, AddCronBody, UpdateCron200, UpdateCronBody, Cron200, CronBody, DbAdd200, DbAddBody, Db200, DbBody, DbList200, DbUsage200, DbUserPrivsGet200, DbUserPrivsGetParams, DbUserAdd200, DbUserAddBody, DbUserDelete200, DbUserDeleteBody, DbUserList200, Domains200, DomainsParams, HostingEcommerceInfo200, HostingFtpList200, HostingFtpAdd200, HostingFtpAddBody, HostingFtpUpdate200, HostingFtpUpdateBody, HostingFtp200, HostingFtpBody, HostingInfo200, HostingInfoDiskUsage200, HostingLead200, HostingLead400, HostingLeadParams, HostingMigrationStatus200, HostingMigrations200, HostingMigrationsBody, HostingMigrationsCheck200, HostingMigrationsCheckParams, HostingMigrationsEvent200, HostingMigrationsEventBody, HostingMigrationInfo200, HostingMigrationInfoParams, HostingMigrationSiteScanStatus200, HostingMigrationSiteScanStatusParams, HostingNameservers200, HostingOnboardingData200, HostingOnboardingDataUpdate200, HostingOnboardingDataUpdateBody, HostingResellerSsoWhm200, HostingShellToggle200, HostingShellToggleBody, HostingShellInfo200, HostingSites200, HostingSiteAdd200, HostingSiteAddBody, HostingSshInfo200, SshKeyFetch200, SshKeyFetchParams, SshKeyImport200, SshKeyImportBody, SshKeyList200, SshKey200, SshKeyBody, SshKeyGenerate200, SshKeyGenerateBody, Sso200, SsoParams, SitesList200, SitesInfo200, SiteUpdate200, SiteUpdate400, SiteUpdateBody, Site200, SitesAutoupdatesResponse, SitesAutoupdatesUpdateBody, SitesBackups200, SitesHasBackups200, SitesBackupsCodeguard200, SitesBackupsDetails200, JetpackBackupStatus200, SiteAddonCloudflare200, SiteAddonCloudflare400, SitesDns200, SitesDnsParams, SitesDomain200, SitesDomainUrl200, SitesDomainUrlBody, SitePendingDomainDelete200, SitesPerformanceCachepurge200, SitesPerformanceCachepurgeBody, SitesPerformanceEnduranceCacheLevelStatus200, SitesPerformanceEnduranceCacheLevel200, SitesPerformanceEnduranceCacheLevelBody, SitesPerformanceEndurancePageCache200, SitePlugins200, SitePluginsAutoupdate200, SitePluginsAutoupdateBody, SitePluginsToggle200, SitePluginsToggleBody, SitePluginsUpdate200, SitePluginsUpdateBody, ResetSite200, SitesSecurityCheckCore200, SitesSecurityResetCoreFiles200, SitesSecurityHttpsRedirectionStatus200, SitesSecurityHttpsEnableDisableSsl200, SitesSecurityHttpsEnableDisableSslBody, SitesSecuritySitelock200, SitesSecuritySslAcme200, SitesSecuritySslStatus200, SiteSettingsAutoupdatePlugins200, SitesSettingsAutoupdates200, SitesSettingsAutoupdatesCore200, SitesSettingsAutoupdatesCoreBody, SitesSettingsAutoupdatesTheme200, SitesSettingsAutoupdatesThemeBody, SitesSettingsComingSoon200, SitesSettingsComingSoonToggle200, SitesSettingsComingSoonToggleBody, SitesSettingsDebug200, SitesSettingsDebugToggle200, SitesSettingsDebugToggleBody, SitesSettingsPhpVersionUpdate200, SitesSettingsPhpVersionUpdateBody, SitesSettingsPhpVersions200, SitesSsl200, SitesSso200, SitesSsoParams, SiteStatus200, SiteUsers200, SitesVersion200, HostingSitesV2200, SshKeyListV2200 } from './index.schemas';
11
+ import type { CodeguardBackupList200, CodeguardBackupListParams, CodeguardBackupCreate200, CodeguardBackupCreateBody, CodeguardBackupDownload200, CodeguardBackupDownloadBody, CodeguardBackupRestore200, CodeguardBackupRestoreBody, CodeguardDatabaseList200, CodeguardDatabaseBackupList200, CodeguardDatabaseBackupListParams, CodeguardDatabaseBackupCreate200, CodeguardDatabaseBackupCreateBody, CodeguardDatabaseBackupRestore200, CodeguardDatabaseBackupRestoreBody, CodeguardLoginLink200, CodeguardPlanInfo200, CodeguardWebsiteList200, CodeguardWebsiteBackupList200, CodeguardWebsiteBackupListParams, CodeguardWebsiteBackupCreate200, CodeguardWebsiteBackupCreateBody, CodeguardWebsiteBackupRestore200, CodeguardWebsiteBackupRestoreBody, AddonsSitelockSso200, AddonsCloudflare200, AddonsInfo200, AddonsSpamexpertsSso200, HostingAccount200, HostingAddons200, HostingAddonsParams, HostingAdvancedServer200, HostingAdvancedServerStatus200, HostingAdvancedServerStatusBody, HostingAdvancedPassword200, HostingAdvancedPasswordBody, HostingAdvancedSsoWhm200, HostingAdvancedSystemConsole200, HostingCapabilities200, AddonCloudflare200, AddonCloudflareBody, ListCrons200, AddCron200, AddCron400, AddCronBody, UpdateCron200, UpdateCronBody, Cron200, CronBody, DbAdd200, DbAddBody, Db200, DbBody, DbList200, DbUsage200, DbUserPrivsGet200, DbUserPrivsGetParams, DbUserAdd200, DbUserAddBody, DbUserDelete200, DbUserDeleteBody, DbUserList200, Domains200, DomainsParams, HostingEcommerceInfo200, HostingFtpList200, HostingFtpAdd200, HostingFtpAddBody, HostingFtpUpdate200, HostingFtpUpdateBody, HostingFtp200, HostingFtpBody, HostingInfo200, HostingInfoDiskUsage200, HostingLead200, HostingLead400, HostingLeadParams, HostingMigrationStatus200, HostingMigrations200, HostingMigrationsBody, HostingMigrationsCheck200, HostingMigrationsCheckParams, HostingMigrationsEvent200, HostingMigrationsEventBody, HostingMigrationInfo200, HostingMigrationInfoParams, HostingMigrationSiteScanStatus200, HostingMigrationSiteScanStatusParams, HostingNameservers200, HostingOnboardingData200, HostingOnboardingDataUpdate200, HostingOnboardingDataUpdateBody, HostingResellerSsoWhm200, HostingShellToggle200, HostingShellToggleBody, HostingShellInfo200, HostingSites200, HostingSiteAdd200, HostingSiteAddBody, HostingSshInfo200, SshKeyFetch200, SshKeyFetchParams, SshKeyImport200, SshKeyImportBody, SshKeyList200, SshKey200, SshKeyBody, SshKeyGenerate200, SshKeyGenerateBody, Sso200, SsoParams, SitesList200, SitesInfo200, SiteUpdate200, SiteUpdate400, SiteUpdateBody, Site200, SitesAutoupdatesResponse, SitesAutoupdatesUpdateBody, SitesBackups200, SitesHasBackups200, SitesBackupsCodeguard200, SitesBackupsDetails200, JetpackBackupStatus200, SiteAddonCloudflare200, SiteAddonCloudflare400, SitesDns200, SitesDnsParams, SitesDomain200, SitesDomainUrl200, SitesDomainUrlBody, SitePendingDomainDelete200, SitesPerformanceCachepurge200, SitesPerformanceCachepurgeBody, SitesPerformanceEnduranceCacheLevelStatus200, SitesPerformanceEnduranceCacheLevel200, SitesPerformanceEnduranceCacheLevelBody, SitesPerformanceEndurancePageCache200, SitePlugins200, SitePluginsAutoupdate200, SitePluginsAutoupdateBody, SitePluginsToggle200, SitePluginsToggleBody, SitePluginsUpdate200, SitePluginsUpdateBody, ResetSite200, SitesSecurityCheckCore200, SitesSecurityResetCoreFiles200, SitesSecurityHttpsRedirectionStatus200, SitesSecurityHttpsEnableDisableSsl200, SitesSecurityHttpsEnableDisableSslBody, SitesSecuritySitelock200, SitesSecuritySslAcme200, SitesSecuritySslStatus200, SiteSettingsAutoupdatePlugins200, SitesSettingsAutoupdates200, SitesSettingsAutoupdatesCore200, SitesSettingsAutoupdatesCoreBody, SitesSettingsAutoupdatesTheme200, SitesSettingsAutoupdatesThemeBody, SitesSettingsComingSoon200, SitesSettingsComingSoonToggle200, SitesSettingsComingSoonToggleBody, SitesSettingsDebug200, SitesSettingsDebugToggle200, SitesSettingsDebugToggleBody, SitesSettingsPhpVersionUpdate200, SitesSettingsPhpVersionUpdateBody, SitesSettingsPhpVersions200, SitesSsl200, SitesSso200, SitesSsoParams, SiteStatus200, SiteUsers200, SitesVersion200, HostingNameserversV2200, HostingSitesV2200, SshKeyListV2200 } from './index.schemas';
12
12
  declare type AwaitedInput<T> = PromiseLike<T> | T;
13
13
  declare type Awaited<O> = O extends AwaitedInput<infer T> ? T : never;
14
14
  /**
@@ -802,7 +802,8 @@ export declare const useHostingMigrations: <TError = AxiosError<unknown, any>, T
802
802
  }, TContext>;
803
803
  /**
804
804
  * Checks if Migration ID exists, indicating the site migration is in progress or completed
805
- * @summary Migration ID check
805
+ * @deprecated
806
+ * @summary Deprecated Migration ID check
806
807
  */
807
808
  export declare const hostingMigrationsCheck: (hostingId: number, params: HostingMigrationsCheckParams, options?: AxiosRequestConfig) => Promise<AxiosResponse<HostingMigrationsCheck200>>;
808
809
  export declare const getHostingMigrationsCheckQueryKey: (hostingId: number, params: HostingMigrationsCheckParams) => (string | HostingMigrationsCheckParams)[];
@@ -862,6 +863,7 @@ export declare const useHostingMigrationSiteScanStatus: <TData = AxiosResponse<H
862
863
  };
863
864
  /**
864
865
  * Returns the hosting brand nameservers
866
+ * @deprecated
865
867
  * @summary hosting nameservers
866
868
  */
867
869
  export declare const hostingNameservers: (hostingId: number, options?: AxiosRequestConfig) => Promise<AxiosResponse<HostingNameservers200>>;
@@ -1822,6 +1824,20 @@ export declare const useSitesVersion: <TData = AxiosResponse<SitesVersion200, an
1822
1824
  } | undefined) => UseQueryResult<TData, TError> & {
1823
1825
  queryKey: QueryKey;
1824
1826
  };
1827
+ /**
1828
+ * Returns the hosting server nameservers information
1829
+ * @summary hosting server nameservers info
1830
+ */
1831
+ export declare const hostingNameserversV2: (hostingId: number, options?: AxiosRequestConfig) => Promise<AxiosResponse<HostingNameserversV2200>>;
1832
+ export declare const getHostingNameserversV2QueryKey: (hostingId: number) => string[];
1833
+ export declare type HostingNameserversV2QueryResult = NonNullable<Awaited<ReturnType<typeof hostingNameserversV2>>>;
1834
+ export declare type HostingNameserversV2QueryError = AxiosError<unknown>;
1835
+ export declare const useHostingNameserversV2: <TData = AxiosResponse<HostingNameserversV2200, any>, TError = AxiosError<unknown, any>>(hostingId: number, options?: {
1836
+ query?: UseQueryOptions<AxiosResponse<HostingNameserversV2200, any>, TError, TData, QueryKey> | undefined;
1837
+ axios?: AxiosRequestConfig<any> | undefined;
1838
+ } | undefined) => UseQueryResult<TData, TError> & {
1839
+ queryKey: QueryKey;
1840
+ };
1825
1841
  /**
1826
1842
  * Returns a list of sites.
1827
1843
  * @summary sites list v2
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.560.0
6
+ * OpenAPI spec version: 1.568.0
7
7
  */
8
8
  import axios from 'axios';
9
9
  import { useQuery, useMutation } from '@tanstack/react-query';
@@ -814,7 +814,8 @@ export const useHostingMigrations = (options) => {
814
814
  };
815
815
  /**
816
816
  * Checks if Migration ID exists, indicating the site migration is in progress or completed
817
- * @summary Migration ID check
817
+ * @deprecated
818
+ * @summary Deprecated Migration ID check
818
819
  */
819
820
  export const hostingMigrationsCheck = (hostingId, params, options) => {
820
821
  return axios.get(`/v1/hosting/${hostingId}/migrations/check`, Object.assign(Object.assign({}, options), { params: Object.assign(Object.assign({}, params), options === null || options === void 0 ? void 0 : options.params) }));
@@ -880,6 +881,7 @@ export const useHostingMigrationSiteScanStatus = (hostingId, params, options) =>
880
881
  };
881
882
  /**
882
883
  * Returns the hosting brand nameservers
884
+ * @deprecated
883
885
  * @summary hosting nameservers
884
886
  */
885
887
  export const hostingNameservers = (hostingId, options) => {
@@ -1882,6 +1884,23 @@ export const useSitesVersion = (siteId, options) => {
1882
1884
  query.queryKey = queryKey;
1883
1885
  return query;
1884
1886
  };
1887
+ /**
1888
+ * Returns the hosting server nameservers information
1889
+ * @summary hosting server nameservers info
1890
+ */
1891
+ export const hostingNameserversV2 = (hostingId, options) => {
1892
+ return axios.get(`/v2/hosting/${hostingId}/nameservers`, options);
1893
+ };
1894
+ export const getHostingNameserversV2QueryKey = (hostingId) => [`/v2/hosting/${hostingId}/nameservers`];
1895
+ export const useHostingNameserversV2 = (hostingId, options) => {
1896
+ var _a;
1897
+ const { query: queryOptions, axios: axiosOptions } = options !== null && options !== void 0 ? options : {};
1898
+ const queryKey = (_a = queryOptions === null || queryOptions === void 0 ? void 0 : queryOptions.queryKey) !== null && _a !== void 0 ? _a : getHostingNameserversV2QueryKey(hostingId);
1899
+ const queryFn = ({ signal }) => hostingNameserversV2(hostingId, Object.assign({ signal }, axiosOptions));
1900
+ const query = useQuery(Object.assign({ queryKey, queryFn, enabled: !!(hostingId) }, queryOptions));
1901
+ query.queryKey = queryKey;
1902
+ return query;
1903
+ };
1885
1904
  /**
1886
1905
  * Returns a list of sites.
1887
1906
  * @summary sites list v2
@@ -311,6 +311,7 @@ export declare const getHostingMigrationInfoMock: () => {
311
311
  hostname: string | undefined;
312
312
  feasible: string | undefined;
313
313
  incoming_domain: string | undefined;
314
+ is_valid_migration_id: boolean | undefined;
314
315
  };
315
316
  export declare const getHostingMigrationSiteScanStatusMock: () => {
316
317
  transferable: boolean | undefined;
@@ -652,6 +653,15 @@ export declare const getSitesVersionMock: () => {
652
653
  latest: string | undefined;
653
654
  update: boolean | undefined;
654
655
  };
656
+ export declare const getHostingNameserversV2Mock: () => {
657
+ id: number;
658
+ is_default: string | undefined;
659
+ brand: string;
660
+ hosts: {
661
+ host: string | undefined;
662
+ ips: string[] | undefined;
663
+ }[];
664
+ };
655
665
  export declare const getHostingSitesV2Mock: () => {
656
666
  total: number | undefined;
657
667
  page: number | undefined;
package/src/index.msw.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.560.0
6
+ * OpenAPI spec version: 1.568.0
7
7
  */
8
8
  import { rest } from 'msw';
9
9
  import { faker } from '@faker-js/faker';
@@ -59,7 +59,7 @@ export const getHostingMigrationStatusMock = () => ({ rows: faker.helpers.arrayE
59
59
  export const getHostingMigrationsMock = () => ({ success: faker.helpers.arrayElement([faker.datatype.boolean(), undefined]) });
60
60
  export const getHostingMigrationsCheckMock = () => ({ transferable: faker.helpers.arrayElement([faker.datatype.boolean(), undefined]), description: faker.helpers.arrayElement([faker.random.word(), undefined]) });
61
61
  export const getHostingMigrationsEventMock = () => ({ success: faker.helpers.arrayElement([faker.datatype.boolean(), undefined]) });
62
- export const getHostingMigrationInfoMock = () => ({ migration_id: faker.helpers.arrayElement([faker.random.word(), undefined]), domain: faker.helpers.arrayElement([faker.random.word(), undefined]), site_url: faker.helpers.arrayElement([faker.random.word(), undefined]), hostname: faker.helpers.arrayElement([faker.random.word(), undefined]), feasible: faker.helpers.arrayElement([faker.random.word(), undefined]), incoming_domain: faker.helpers.arrayElement([faker.random.word(), undefined]) });
62
+ export const getHostingMigrationInfoMock = () => ({ migration_id: faker.helpers.arrayElement([faker.random.word(), undefined]), domain: faker.helpers.arrayElement([faker.random.word(), undefined]), site_url: faker.helpers.arrayElement([faker.random.word(), undefined]), hostname: faker.helpers.arrayElement([faker.random.word(), undefined]), feasible: faker.helpers.arrayElement([faker.random.word(), undefined]), incoming_domain: faker.helpers.arrayElement([faker.random.word(), undefined]), is_valid_migration_id: faker.helpers.arrayElement([faker.datatype.boolean(), undefined]) });
63
63
  export const getHostingMigrationSiteScanStatusMock = () => ({ transferable: faker.helpers.arrayElement([faker.datatype.boolean(), undefined]), callback_url: faker.helpers.arrayElement([faker.random.word(), undefined]) });
64
64
  export const getHostingNameserversMock = () => ({ nameservers: Array.from({ length: faker.datatype.number({ min: 1, max: 10 }) }, (_, i) => i + 1).map(() => (faker.random.word())) });
65
65
  export const getHostingOnboardingDataMock = () => ({ completed: faker.helpers.arrayElement([faker.datatype.boolean(), undefined]) });
@@ -123,6 +123,7 @@ export const getSitesSsoMock = () => ({ sso: faker.helpers.arrayElement([faker.r
123
123
  export const getSiteStatusMock = () => ({ url: faker.helpers.arrayElement([faker.random.word(), undefined]), pending_url: faker.helpers.arrayElement([faker.random.word(), undefined]), cloudflare_ready: faker.helpers.arrayElement([faker.datatype.boolean(), undefined]) });
124
124
  export const getSiteUsersMock = () => ({ users: Array.from({ length: faker.datatype.number({ min: 1, max: 10 }) }, (_, i) => i + 1).map(() => ({ display_name: faker.helpers.arrayElement([faker.random.word(), undefined]), id: faker.datatype.number({ min: undefined, max: undefined }), meta: faker.helpers.arrayElement([{ maestro_web_pro: faker.helpers.arrayElement([faker.random.word(), undefined]), maestro_wpp_identifier: faker.helpers.arrayElement([faker.random.word(), undefined]) }, undefined]), post_count: faker.helpers.arrayElement([faker.datatype.number({ min: undefined, max: undefined }), undefined]), role: faker.random.word(), user_email: faker.random.word(), user_id: faker.datatype.number({ min: undefined, max: undefined }), user_login: faker.random.word(), user_nicename: faker.random.word() })) });
125
125
  export const getSitesVersionMock = () => ({ current: faker.helpers.arrayElement([faker.random.word(), undefined]), latest: faker.helpers.arrayElement([faker.random.word(), undefined]), update: faker.helpers.arrayElement([faker.datatype.boolean(), undefined]) });
126
+ export const getHostingNameserversV2Mock = () => ({ id: faker.datatype.number({ min: undefined, max: undefined }), is_default: faker.helpers.arrayElement([faker.random.word(), undefined]), brand: faker.random.word(), hosts: Array.from({ length: faker.datatype.number({ min: 1, max: 10 }) }, (_, i) => i + 1).map(() => ({ host: faker.helpers.arrayElement([faker.random.word(), undefined]), ips: faker.helpers.arrayElement([Array.from({ length: faker.datatype.number({ min: 1, max: 10 }) }, (_, i) => i + 1).map(() => (faker.random.word())), undefined]) })) });
126
127
  export const getHostingSitesV2Mock = () => ({ total: faker.helpers.arrayElement([faker.datatype.number({ min: undefined, max: undefined }), undefined]), page: faker.helpers.arrayElement([faker.datatype.number({ min: undefined, max: undefined }), undefined]), limit: faker.helpers.arrayElement([faker.datatype.number({ min: undefined, max: undefined }), undefined]), max_sites: faker.helpers.arrayElement([faker.helpers.arrayElement([faker.datatype.number({ min: undefined, max: undefined }), null]), undefined]), used_sites: faker.helpers.arrayElement([faker.datatype.number({ min: undefined, max: undefined }), undefined]), available_sites: faker.helpers.arrayElement([faker.helpers.arrayElement([faker.datatype.number({ min: undefined, max: undefined }), null]), undefined]), items: faker.helpers.arrayElement([Array.from({ length: faker.datatype.number({ min: 1, max: 10 }) }, (_, i) => i + 1).map(() => ({ id: faker.helpers.arrayElement([faker.random.word(), undefined]), name: faker.helpers.arrayElement([faker.random.word(), undefined]), url: faker.helpers.arrayElement([faker.random.word(), undefined]), docroot: faker.helpers.arrayElement([faker.random.word(), undefined]), status: faker.helpers.arrayElement([faker.random.word(), undefined]), type: faker.helpers.arrayElement([faker.random.word(), undefined]), pending_url: faker.helpers.arrayElement([faker.random.word(), undefined]), migration_id: faker.helpers.arrayElement([faker.random.word(), undefined]) })), undefined]) });
127
128
  export const getSshKeyListV2Mock = () => ({ rows: faker.helpers.arrayElement([Array.from({ length: faker.datatype.number({ min: 1, max: 10 }) }, (_, i) => i + 1).map(() => ({ name: faker.helpers.arrayElement([faker.random.word(), undefined]), type: faker.helpers.arrayElement([faker.random.word(), undefined]), mtime: faker.helpers.arrayElement([faker.random.word(), undefined]), key: faker.helpers.arrayElement([faker.random.word(), undefined]) })), undefined]) });
128
129
  export const getHostingUAPIMSW = () => [
@@ -358,6 +359,8 @@ export const getHostingUAPIMSW = () => [
358
359
  return res(ctx.delay(1000), ctx.status(200, 'Mocked status'), ctx.json(getSiteUsersMock()));
359
360
  }), rest.get('*/v1/sites/:siteId/version', (_req, res, ctx) => {
360
361
  return res(ctx.delay(1000), ctx.status(200, 'Mocked status'), ctx.json(getSitesVersionMock()));
362
+ }), rest.get('*/v2/hosting/:hostingId/nameservers', (_req, res, ctx) => {
363
+ return res(ctx.delay(1000), ctx.status(200, 'Mocked status'), ctx.json(getHostingNameserversV2Mock()));
361
364
  }), rest.get('*/v2/hosting/:hostingId/sites', (_req, res, ctx) => {
362
365
  return res(ctx.delay(1000), ctx.status(200, 'Mocked status'), ctx.json(getHostingSitesV2Mock()));
363
366
  }), rest.get('*/v2/hosting/:hostingId/ssh/keys', (_req, res, ctx) => {
@@ -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.560.0
6
+ * OpenAPI spec version: 1.568.0
7
7
  */
8
8
  export declare type SshKeyListV2200RowsItem = {
9
9
  name?: string;
@@ -36,6 +36,16 @@ export declare type HostingSitesV2200 = {
36
36
  available_sites?: number | null;
37
37
  items?: HostingSitesV2200ItemsItem[];
38
38
  };
39
+ export declare type HostingNameserversV2200HostsItem = {
40
+ host?: string;
41
+ ips?: string[];
42
+ };
43
+ export declare type HostingNameserversV2200 = {
44
+ id: number;
45
+ is_default?: string;
46
+ brand: string;
47
+ hosts: HostingNameserversV2200HostsItem[];
48
+ };
39
49
  export declare type SitesVersion200 = {
40
50
  current?: string;
41
51
  latest?: string;
@@ -602,6 +612,7 @@ export declare type HostingMigrationInfo200 = {
602
612
  hostname?: string;
603
613
  feasible?: string;
604
614
  incoming_domain?: string;
615
+ is_valid_migration_id?: boolean;
605
616
  };
606
617
  export declare type HostingMigrationInfoParams = {
607
618
  migration_id: string;