@wix/auto_sdk_domains_domain-suggestions 1.0.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.
Files changed (111) hide show
  1. package/build/cjs/index.d.ts +1 -0
  2. package/build/cjs/index.js +18 -0
  3. package/build/cjs/index.js.map +1 -0
  4. package/build/cjs/index.typings.d.ts +1 -0
  5. package/build/cjs/index.typings.js +18 -0
  6. package/build/cjs/index.typings.js.map +1 -0
  7. package/build/cjs/meta.d.ts +1 -0
  8. package/build/cjs/meta.js +18 -0
  9. package/build/cjs/meta.js.map +1 -0
  10. package/build/cjs/src/premium-domains-v2-suggestion-domain-suggestions.context.d.ts +4 -0
  11. package/build/cjs/src/premium-domains-v2-suggestion-domain-suggestions.context.js +7 -0
  12. package/build/cjs/src/premium-domains-v2-suggestion-domain-suggestions.context.js.map +1 -0
  13. package/build/cjs/src/premium-domains-v2-suggestion-domain-suggestions.http.d.ts +11 -0
  14. package/build/cjs/src/premium-domains-v2-suggestion-domain-suggestions.http.js +72 -0
  15. package/build/cjs/src/premium-domains-v2-suggestion-domain-suggestions.http.js.map +1 -0
  16. package/build/cjs/src/premium-domains-v2-suggestion-domain-suggestions.meta.d.ts +13 -0
  17. package/build/cjs/src/premium-domains-v2-suggestion-domain-suggestions.meta.js +47 -0
  18. package/build/cjs/src/premium-domains-v2-suggestion-domain-suggestions.meta.js.map +1 -0
  19. package/build/cjs/src/premium-domains-v2-suggestion-domain-suggestions.public.d.ts +24 -0
  20. package/build/cjs/src/premium-domains-v2-suggestion-domain-suggestions.public.js +12 -0
  21. package/build/cjs/src/premium-domains-v2-suggestion-domain-suggestions.public.js.map +1 -0
  22. package/build/cjs/src/premium-domains-v2-suggestion-domain-suggestions.types.d.ts +102 -0
  23. package/build/cjs/src/premium-domains-v2-suggestion-domain-suggestions.types.js +3 -0
  24. package/build/cjs/src/premium-domains-v2-suggestion-domain-suggestions.types.js.map +1 -0
  25. package/build/cjs/src/premium-domains-v2-suggestion-domain-suggestions.universal.d.ts +160 -0
  26. package/build/cjs/src/premium-domains-v2-suggestion-domain-suggestions.universal.js +82 -0
  27. package/build/cjs/src/premium-domains-v2-suggestion-domain-suggestions.universal.js.map +1 -0
  28. package/build/es/index.d.ts +1 -0
  29. package/build/es/index.js +2 -0
  30. package/build/es/index.js.map +1 -0
  31. package/build/es/index.typings.d.ts +1 -0
  32. package/build/es/index.typings.js +2 -0
  33. package/build/es/index.typings.js.map +1 -0
  34. package/build/es/meta.d.ts +1 -0
  35. package/build/es/meta.js +2 -0
  36. package/build/es/meta.js.map +1 -0
  37. package/build/es/package.json +3 -0
  38. package/build/es/src/premium-domains-v2-suggestion-domain-suggestions.context.d.ts +4 -0
  39. package/build/es/src/premium-domains-v2-suggestion-domain-suggestions.context.js +4 -0
  40. package/build/es/src/premium-domains-v2-suggestion-domain-suggestions.context.js.map +1 -0
  41. package/build/es/src/premium-domains-v2-suggestion-domain-suggestions.http.d.ts +11 -0
  42. package/build/es/src/premium-domains-v2-suggestion-domain-suggestions.http.js +68 -0
  43. package/build/es/src/premium-domains-v2-suggestion-domain-suggestions.http.js.map +1 -0
  44. package/build/es/src/premium-domains-v2-suggestion-domain-suggestions.meta.d.ts +13 -0
  45. package/build/es/src/premium-domains-v2-suggestion-domain-suggestions.meta.js +20 -0
  46. package/build/es/src/premium-domains-v2-suggestion-domain-suggestions.meta.js.map +1 -0
  47. package/build/es/src/premium-domains-v2-suggestion-domain-suggestions.public.d.ts +24 -0
  48. package/build/es/src/premium-domains-v2-suggestion-domain-suggestions.public.js +8 -0
  49. package/build/es/src/premium-domains-v2-suggestion-domain-suggestions.public.js.map +1 -0
  50. package/build/es/src/premium-domains-v2-suggestion-domain-suggestions.types.d.ts +102 -0
  51. package/build/es/src/premium-domains-v2-suggestion-domain-suggestions.types.js +2 -0
  52. package/build/es/src/premium-domains-v2-suggestion-domain-suggestions.types.js.map +1 -0
  53. package/build/es/src/premium-domains-v2-suggestion-domain-suggestions.universal.d.ts +160 -0
  54. package/build/es/src/premium-domains-v2-suggestion-domain-suggestions.universal.js +55 -0
  55. package/build/es/src/premium-domains-v2-suggestion-domain-suggestions.universal.js.map +1 -0
  56. package/build/internal/cjs/index.d.ts +1 -0
  57. package/build/internal/cjs/index.js +18 -0
  58. package/build/internal/cjs/index.js.map +1 -0
  59. package/build/internal/cjs/index.typings.d.ts +1 -0
  60. package/build/internal/cjs/index.typings.js +18 -0
  61. package/build/internal/cjs/index.typings.js.map +1 -0
  62. package/build/internal/cjs/meta.d.ts +1 -0
  63. package/build/internal/cjs/meta.js +18 -0
  64. package/build/internal/cjs/meta.js.map +1 -0
  65. package/build/internal/cjs/src/premium-domains-v2-suggestion-domain-suggestions.context.d.ts +4 -0
  66. package/build/internal/cjs/src/premium-domains-v2-suggestion-domain-suggestions.context.js +7 -0
  67. package/build/internal/cjs/src/premium-domains-v2-suggestion-domain-suggestions.context.js.map +1 -0
  68. package/build/internal/cjs/src/premium-domains-v2-suggestion-domain-suggestions.http.d.ts +11 -0
  69. package/build/internal/cjs/src/premium-domains-v2-suggestion-domain-suggestions.http.js +72 -0
  70. package/build/internal/cjs/src/premium-domains-v2-suggestion-domain-suggestions.http.js.map +1 -0
  71. package/build/internal/cjs/src/premium-domains-v2-suggestion-domain-suggestions.meta.d.ts +13 -0
  72. package/build/internal/cjs/src/premium-domains-v2-suggestion-domain-suggestions.meta.js +47 -0
  73. package/build/internal/cjs/src/premium-domains-v2-suggestion-domain-suggestions.meta.js.map +1 -0
  74. package/build/internal/cjs/src/premium-domains-v2-suggestion-domain-suggestions.public.d.ts +24 -0
  75. package/build/internal/cjs/src/premium-domains-v2-suggestion-domain-suggestions.public.js +12 -0
  76. package/build/internal/cjs/src/premium-domains-v2-suggestion-domain-suggestions.public.js.map +1 -0
  77. package/build/internal/cjs/src/premium-domains-v2-suggestion-domain-suggestions.types.d.ts +102 -0
  78. package/build/internal/cjs/src/premium-domains-v2-suggestion-domain-suggestions.types.js +3 -0
  79. package/build/internal/cjs/src/premium-domains-v2-suggestion-domain-suggestions.types.js.map +1 -0
  80. package/build/internal/cjs/src/premium-domains-v2-suggestion-domain-suggestions.universal.d.ts +160 -0
  81. package/build/internal/cjs/src/premium-domains-v2-suggestion-domain-suggestions.universal.js +82 -0
  82. package/build/internal/cjs/src/premium-domains-v2-suggestion-domain-suggestions.universal.js.map +1 -0
  83. package/build/internal/es/index.d.ts +1 -0
  84. package/build/internal/es/index.js +2 -0
  85. package/build/internal/es/index.js.map +1 -0
  86. package/build/internal/es/index.typings.d.ts +1 -0
  87. package/build/internal/es/index.typings.js +2 -0
  88. package/build/internal/es/index.typings.js.map +1 -0
  89. package/build/internal/es/meta.d.ts +1 -0
  90. package/build/internal/es/meta.js +2 -0
  91. package/build/internal/es/meta.js.map +1 -0
  92. package/build/internal/es/src/premium-domains-v2-suggestion-domain-suggestions.context.d.ts +4 -0
  93. package/build/internal/es/src/premium-domains-v2-suggestion-domain-suggestions.context.js +4 -0
  94. package/build/internal/es/src/premium-domains-v2-suggestion-domain-suggestions.context.js.map +1 -0
  95. package/build/internal/es/src/premium-domains-v2-suggestion-domain-suggestions.http.d.ts +11 -0
  96. package/build/internal/es/src/premium-domains-v2-suggestion-domain-suggestions.http.js +68 -0
  97. package/build/internal/es/src/premium-domains-v2-suggestion-domain-suggestions.http.js.map +1 -0
  98. package/build/internal/es/src/premium-domains-v2-suggestion-domain-suggestions.meta.d.ts +13 -0
  99. package/build/internal/es/src/premium-domains-v2-suggestion-domain-suggestions.meta.js +20 -0
  100. package/build/internal/es/src/premium-domains-v2-suggestion-domain-suggestions.meta.js.map +1 -0
  101. package/build/internal/es/src/premium-domains-v2-suggestion-domain-suggestions.public.d.ts +24 -0
  102. package/build/internal/es/src/premium-domains-v2-suggestion-domain-suggestions.public.js +8 -0
  103. package/build/internal/es/src/premium-domains-v2-suggestion-domain-suggestions.public.js.map +1 -0
  104. package/build/internal/es/src/premium-domains-v2-suggestion-domain-suggestions.types.d.ts +102 -0
  105. package/build/internal/es/src/premium-domains-v2-suggestion-domain-suggestions.types.js +2 -0
  106. package/build/internal/es/src/premium-domains-v2-suggestion-domain-suggestions.types.js.map +1 -0
  107. package/build/internal/es/src/premium-domains-v2-suggestion-domain-suggestions.universal.d.ts +160 -0
  108. package/build/internal/es/src/premium-domains-v2-suggestion-domain-suggestions.universal.js +55 -0
  109. package/build/internal/es/src/premium-domains-v2-suggestion-domain-suggestions.universal.js.map +1 -0
  110. package/meta/package.json +3 -0
  111. package/package.json +52 -0
@@ -0,0 +1,68 @@
1
+ import { toURLSearchParams } from '@wix/sdk-runtime/rest-modules';
2
+ import { resolveUrl } from '@wix/sdk-runtime/rest-modules';
3
+ function resolveComWixpressPremiumDomainSearchSuggestV2DomainSearchServiceUrl(opts) {
4
+ const domainToMappings = {
5
+ 'www._base_domain_': [
6
+ {
7
+ srcPath: '/domain-search/v2',
8
+ destPath: '/v2',
9
+ },
10
+ {
11
+ srcPath: '/v2/suggest-domains',
12
+ destPath: '/v2/suggest-domains',
13
+ },
14
+ ],
15
+ 'manage._base_domain_': [
16
+ {
17
+ srcPath: '/v2/check-domain-availability',
18
+ destPath: '/v2/check-domain-availability',
19
+ },
20
+ {
21
+ srcPath: '/v2/suggest-domains',
22
+ destPath: '/v2/suggest-domains',
23
+ },
24
+ ],
25
+ 'premium._base_domain_': [
26
+ {
27
+ srcPath: '/v2/check-domain-availability',
28
+ destPath: '/v2/check-domain-availability',
29
+ },
30
+ {
31
+ srcPath: '/v2/suggest-domains',
32
+ destPath: '/v2/suggest-domains',
33
+ },
34
+ ],
35
+ 'www.wixapis.com': [
36
+ {
37
+ srcPath: '/domain-search/v2',
38
+ destPath: '/v2',
39
+ },
40
+ ],
41
+ };
42
+ return resolveUrl(Object.assign(opts, { domainToMappings }));
43
+ }
44
+ const PACKAGE_NAME = '@wix/auto_sdk_domains_domain-suggestions';
45
+ /**
46
+ * Suggests domains that are available for purchase, based on the provided query input.
47
+ *
48
+ * You may use this endpoint to get inspired and then call [Check Domain Availability()](/domainAvailability/check-domain-availability) to check whether a specific variation of the suggestions is also available for purchsase.
49
+ *
50
+ * The `tlds` must not include the dot. For example, `com` and not `.com`.
51
+ *
52
+ * > **Important:** This call requires an account level API key and cannot be authenticated with the standard authorization header.
53
+ */
54
+ export function suggestDomains(payload) {
55
+ function __suggestDomains({ host }) {
56
+ const metadata = {
57
+ entityFqdn: 'wix.premium.domains.v2.suggestion',
58
+ method: 'GET',
59
+ methodFqn: 'com.wixpress.premium.domain.search.suggest.v2.DomainSearchService.SuggestDomains',
60
+ packageName: PACKAGE_NAME,
61
+ url: resolveComWixpressPremiumDomainSearchSuggestV2DomainSearchServiceUrl({ protoPath: '/v2/suggest-domains', data: payload, host }),
62
+ params: toURLSearchParams(payload),
63
+ };
64
+ return metadata;
65
+ }
66
+ return __suggestDomains;
67
+ }
68
+ //# sourceMappingURL=premium-domains-v2-suggestion-domain-suggestions.http.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"premium-domains-v2-suggestion-domain-suggestions.http.js","sourceRoot":"","sources":["../../../../src/premium-domains-v2-suggestion-domain-suggestions.http.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,MAAM,+BAA+B,CAAC;AAClE,OAAO,EAAE,UAAU,EAAE,MAAM,+BAA+B,CAAC;AAI3D,SAAS,oEAAoE,CAC3E,IAA8C;IAE9C,MAAM,gBAAgB,GAAG;QACvB,mBAAmB,EAAE;YACnB;gBACE,OAAO,EAAE,mBAAmB;gBAC5B,QAAQ,EAAE,KAAK;aAChB;YACD;gBACE,OAAO,EAAE,qBAAqB;gBAC9B,QAAQ,EAAE,qBAAqB;aAChC;SACF;QACD,sBAAsB,EAAE;YACtB;gBACE,OAAO,EAAE,+BAA+B;gBACxC,QAAQ,EAAE,+BAA+B;aAC1C;YACD;gBACE,OAAO,EAAE,qBAAqB;gBAC9B,QAAQ,EAAE,qBAAqB;aAChC;SACF;QACD,uBAAuB,EAAE;YACvB;gBACE,OAAO,EAAE,+BAA+B;gBACxC,QAAQ,EAAE,+BAA+B;aAC1C;YACD;gBACE,OAAO,EAAE,qBAAqB;gBAC9B,QAAQ,EAAE,qBAAqB;aAChC;SACF;QACD,iBAAiB,EAAE;YACjB;gBACE,OAAO,EAAE,mBAAmB;gBAC5B,QAAQ,EAAE,KAAK;aAChB;SACF;KACF,CAAC;IAEF,OAAO,UAAU,CAAC,MAAM,CAAC,MAAM,CAAC,IAAI,EAAE,EAAE,gBAAgB,EAAE,CAAC,CAAC,CAAC;AAC/D,CAAC;AAED,MAAM,YAAY,GAAG,0CAA0C,CAAC;AAEhE;;;;;;;;GAQG;AACH,MAAM,UAAU,cAAc,CAAC,OAAe;IAC5C,SAAS,gBAAgB,CAAC,EAAE,IAAI,EAAO;QACrC,MAAM,QAAQ,GAAG;YACf,UAAU,EAAE,mCAAmC;YAC/C,MAAM,EAAE,KAAY;YACpB,SAAS,EACP,kFAAkF;YACpF,WAAW,EAAE,YAAY;YACzB,GAAG,EAAE,oEAAoE,CACvE,EAAE,SAAS,EAAE,qBAAqB,EAAE,IAAI,EAAE,OAAO,EAAE,IAAI,EAAE,CAC1D;YACD,MAAM,EAAE,iBAAiB,CAAC,OAAO,CAAC;SACnC,CAAC;QAEF,OAAO,QAAQ,CAAC;IAClB,CAAC;IAED,OAAO,gBAAgB,CAAC;AAC1B,CAAC"}
@@ -0,0 +1,13 @@
1
+ import * as ambassadorWixPremiumDomainsV2SuggestionTypes from './premium-domains-v2-suggestion-domain-suggestions.types.js';
2
+ import * as ambassadorWixPremiumDomainsV2SuggestionUniversalTypes from './premium-domains-v2-suggestion-domain-suggestions.universal.js';
3
+ export type __PublicMethodMetaInfo<K = string, M = unknown, T = unknown, S = unknown, Q = unknown, R = unknown> = {
4
+ getUrl: (context: any) => string;
5
+ httpMethod: K;
6
+ path: string;
7
+ pathParams: M;
8
+ __requestType: T;
9
+ __originalRequestType: S;
10
+ __responseType: Q;
11
+ __originalResponseType: R;
12
+ };
13
+ export declare function suggestDomains(): __PublicMethodMetaInfo<'GET', {}, ambassadorWixPremiumDomainsV2SuggestionUniversalTypes.SuggestDomainsRequest, ambassadorWixPremiumDomainsV2SuggestionTypes.SuggestDomainsRequest, ambassadorWixPremiumDomainsV2SuggestionUniversalTypes.SuggestDomainsResponse & ambassadorWixPremiumDomainsV2SuggestionUniversalTypes.SuggestDomainsResponseNonNullableFields, ambassadorWixPremiumDomainsV2SuggestionTypes.SuggestDomainsResponse & ambassadorWixPremiumDomainsV2SuggestionTypes.SuggestDomainsResponseNonNullableFields>;
@@ -0,0 +1,20 @@
1
+ import * as ambassadorWixPremiumDomainsV2Suggestion from './premium-domains-v2-suggestion-domain-suggestions.http.js';
2
+ export function suggestDomains() {
3
+ const payload = {};
4
+ const getRequestOptions = ambassadorWixPremiumDomainsV2Suggestion.suggestDomains(payload);
5
+ const getUrl = (context) => {
6
+ const { url } = getRequestOptions(context);
7
+ return url;
8
+ };
9
+ return {
10
+ getUrl,
11
+ httpMethod: 'GET',
12
+ path: '/v2/suggest-domains',
13
+ pathParams: {},
14
+ __requestType: null,
15
+ __originalRequestType: null,
16
+ __responseType: null,
17
+ __originalResponseType: null,
18
+ };
19
+ }
20
+ //# sourceMappingURL=premium-domains-v2-suggestion-domain-suggestions.meta.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"premium-domains-v2-suggestion-domain-suggestions.meta.js","sourceRoot":"","sources":["../../../../src/premium-domains-v2-suggestion-domain-suggestions.meta.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,uCAAuC,MAAM,4DAA4D,CAAC;AAsBtH,MAAM,UAAU,cAAc;IAU5B,MAAM,OAAO,GAAG,EAAS,CAAC;IAE1B,MAAM,iBAAiB,GACrB,uCAAuC,CAAC,cAAc,CAAC,OAAO,CAAC,CAAC;IAElE,MAAM,MAAM,GAAG,CAAC,OAAY,EAAU,EAAE;QACtC,MAAM,EAAE,GAAG,EAAE,GAAG,iBAAiB,CAAC,OAAO,CAAC,CAAC;QAC3C,OAAO,GAAI,CAAC;IACd,CAAC,CAAC;IAEF,OAAO;QACL,MAAM;QACN,UAAU,EAAE,KAAK;QACjB,IAAI,EAAE,qBAAqB;QAC3B,UAAU,EAAE,EAAE;QACd,aAAa,EAAE,IAAW;QAC1B,qBAAqB,EAAE,IAAW;QAClC,cAAc,EAAE,IAAW;QAC3B,sBAAsB,EAAE,IAAW;KACpC,CAAC;AACJ,CAAC"}
@@ -0,0 +1,24 @@
1
+ import { HttpClient } from '@wix/sdk-types';
2
+ import { SuggestDomainsOptions, SuggestDomainsResponse, SuggestDomainsResponseNonNullableFields } from './premium-domains-v2-suggestion-domain-suggestions.universal.js';
3
+ export declare const __metadata: {
4
+ PACKAGE_NAME: string;
5
+ };
6
+ export declare function suggestDomains(httpClient: HttpClient): SuggestDomainsSignature;
7
+ interface SuggestDomainsSignature {
8
+ /**
9
+ * Suggests domains that are available for purchase, based on the provided query input.
10
+ *
11
+ * You may use this endpoint to get inspired and then call [Check Domain Availability()](/domainAvailability/check-domain-availability) to check whether a specific variation of the suggestions is also available for purchsase.
12
+ *
13
+ * The `tlds` must not include the dot. For example, `com` and not `.com`.
14
+ *
15
+ * > **Important:** This call requires an account level API key and cannot be authenticated with the standard authorization header.
16
+ * @param - Input to base your domain suggestions on. May include
17
+ * letters, numbers, spaces, dots, and hyphens. Must not include the TLD.
18
+ *
19
+ * Min: 3 characters
20
+ * Max: 100 characters
21
+ */
22
+ (query: string, options?: SuggestDomainsOptions | undefined): Promise<SuggestDomainsResponse & SuggestDomainsResponseNonNullableFields>;
23
+ }
24
+ export { CursorPaging, CursorPagingMetadata, Cursors, DomainSuggestion, SuggestDomainsOptions, SuggestDomainsRequest, SuggestDomainsResponse, SuggestDomainsResponseNonNullableFields, } from './premium-domains-v2-suggestion-domain-suggestions.universal.js';
@@ -0,0 +1,8 @@
1
+ import { suggestDomains as universalSuggestDomains, } from './premium-domains-v2-suggestion-domain-suggestions.universal.js';
2
+ export const __metadata = { PACKAGE_NAME: '@wix/domains' };
3
+ export function suggestDomains(httpClient) {
4
+ return (query, options) => universalSuggestDomains(query, options,
5
+ // @ts-ignore
6
+ { httpClient });
7
+ }
8
+ //# sourceMappingURL=premium-domains-v2-suggestion-domain-suggestions.public.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"premium-domains-v2-suggestion-domain-suggestions.public.js","sourceRoot":"","sources":["../../../../src/premium-domains-v2-suggestion-domain-suggestions.public.ts"],"names":[],"mappings":"AACA,OAAO,EAIL,cAAc,IAAI,uBAAuB,GAC1C,MAAM,iEAAiE,CAAC;AAEzE,MAAM,CAAC,MAAM,UAAU,GAAG,EAAE,YAAY,EAAE,cAAc,EAAE,CAAC;AAE3D,MAAM,UAAU,cAAc,CAC5B,UAAsB;IAEtB,OAAO,CAAC,KAAa,EAAE,OAA+B,EAAE,EAAE,CACxD,uBAAuB,CACrB,KAAK,EACL,OAAO;IACP,aAAa;IACb,EAAE,UAAU,EAAE,CACf,CAAC;AACN,CAAC"}
@@ -0,0 +1,102 @@
1
+ export interface DomainSuggestion {
2
+ /** Suggested domain name including TLD. */
3
+ domain?: string;
4
+ /** Whether the domain has a higher price due to its perceived value or demand. */
5
+ premium?: boolean;
6
+ }
7
+ export interface SuggestDomainsRequest {
8
+ /**
9
+ * Input to base your domain suggestions on. May include
10
+ * letters, numbers, spaces, dots, and hyphens. Must not include the TLD.
11
+ *
12
+ * Min: 3 characters
13
+ * Max: 100 characters
14
+ */
15
+ query: string;
16
+ /**
17
+ * [Top-level domains](https://en.wikipedia.org/wiki/Top-level_domain). Must
18
+ * not include the dot. For example, `com`, not `.com`. Not all TLDs can be
19
+ * connected to Wix sites. Supported TLDS include `com`, `net`, and `org`.
20
+ * Contact the [Wix B2B sales team](mailto:bizdev@wix.com) for more
21
+ * information.
22
+ *
23
+ * Max: 10 TLDs
24
+ */
25
+ tlds?: string[];
26
+ /**
27
+ * Number of domain suggestions to return. __Deprecated__: This field will be
28
+ * removed on March 1, 2025. Use `paging.limit` instead.
29
+ *
30
+ * Min: `1`
31
+ * Max: `20`
32
+ * Default: `10`
33
+ * @deprecated Number of domain suggestions to return. __Deprecated__: This field will be
34
+ * removed on March 1, 2025. Use `paging.limit` instead.
35
+ *
36
+ * Min: `1`
37
+ * Max: `20`
38
+ * Default: `10`
39
+ * @replacedBy paging.limit
40
+ * @targetRemovalDate 2025-03-01
41
+ */
42
+ limit?: number | null;
43
+ /** Cursor paging options. */
44
+ paging?: CursorPaging;
45
+ /**
46
+ * Maximum number of characters for the domain name, excluding the TLD.
47
+ *
48
+ * Min: `3`
49
+ * Max: `63`
50
+ * Default: `63`
51
+ */
52
+ maxLength?: number | null;
53
+ }
54
+ export interface CursorPaging {
55
+ /**
56
+ * Maximum number of domains to return in the results.
57
+ *
58
+ * Min: `0`
59
+ * Max: `20`
60
+ */
61
+ limit?: number | null;
62
+ /**
63
+ * Pointer to the next or previous page in the list of results.
64
+ *
65
+ * You can get the relevant cursor token
66
+ * from the `pagingMetadata` object in the previous call's response.
67
+ * Not relevant for the first request.
68
+ */
69
+ cursor?: string | null;
70
+ }
71
+ export interface SuggestDomainsResponse {
72
+ /** List of suggested available domains. */
73
+ suggestions?: DomainSuggestion[];
74
+ /** Metadata about the returned list of suggested domains. */
75
+ pagingMetadata?: CursorPagingMetadata;
76
+ }
77
+ export interface CursorPagingMetadata {
78
+ /** Number of domains returned in the response. */
79
+ count?: number | null;
80
+ /** Cursors to navigate through the result pages using `next` and `prev`. Returned if cursor paging is used. */
81
+ cursors?: Cursors;
82
+ /**
83
+ * Indicates if there are more results after the current page.
84
+ * If `true`, another page of results can be retrieved.
85
+ * If `false`, this is the last page.
86
+ */
87
+ hasNext?: boolean | null;
88
+ }
89
+ export interface Cursors {
90
+ /** Cursor pointing to next page in the list of results. */
91
+ next?: string | null;
92
+ /** Cursor pointing to previous page in the list of results. */
93
+ prev?: string | null;
94
+ }
95
+ interface DomainSuggestionNonNullableFields {
96
+ domain: string;
97
+ premium: boolean;
98
+ }
99
+ export interface SuggestDomainsResponseNonNullableFields {
100
+ suggestions: DomainSuggestionNonNullableFields[];
101
+ }
102
+ export {};
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=premium-domains-v2-suggestion-domain-suggestions.types.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"premium-domains-v2-suggestion-domain-suggestions.types.js","sourceRoot":"","sources":["../../../../src/premium-domains-v2-suggestion-domain-suggestions.types.ts"],"names":[],"mappings":""}
@@ -0,0 +1,160 @@
1
+ export interface DomainSuggestion {
2
+ /** Suggested domain name including TLD. */
3
+ domain?: string;
4
+ /** Whether the domain has a higher price due to its perceived value or demand. */
5
+ premium?: boolean;
6
+ }
7
+ export interface SuggestDomainsRequest {
8
+ /**
9
+ * Input to base your domain suggestions on. May include
10
+ * letters, numbers, spaces, dots, and hyphens. Must not include the TLD.
11
+ *
12
+ * Min: 3 characters
13
+ * Max: 100 characters
14
+ */
15
+ query: string;
16
+ /**
17
+ * [Top-level domains](https://en.wikipedia.org/wiki/Top-level_domain). Must
18
+ * not include the dot. For example, `com`, not `.com`. Not all TLDs can be
19
+ * connected to Wix sites. Supported TLDS include `com`, `net`, and `org`.
20
+ * Contact the [Wix B2B sales team](mailto:bizdev@wix.com) for more
21
+ * information.
22
+ *
23
+ * Max: 10 TLDs
24
+ */
25
+ tlds?: string[];
26
+ /**
27
+ * Number of domain suggestions to return. __Deprecated__: This field will be
28
+ * removed on March 1, 2025. Use `paging.limit` instead.
29
+ *
30
+ * Min: `1`
31
+ * Max: `20`
32
+ * Default: `10`
33
+ * @deprecated Number of domain suggestions to return. __Deprecated__: This field will be
34
+ * removed on March 1, 2025. Use `paging.limit` instead.
35
+ *
36
+ * Min: `1`
37
+ * Max: `20`
38
+ * Default: `10`
39
+ * @replacedBy paging.limit
40
+ * @targetRemovalDate 2025-03-01
41
+ */
42
+ limit?: number | null;
43
+ /** Cursor paging options. */
44
+ paging?: CursorPaging;
45
+ /**
46
+ * Maximum number of characters for the domain name, excluding the TLD.
47
+ *
48
+ * Min: `3`
49
+ * Max: `63`
50
+ * Default: `63`
51
+ */
52
+ maxLength?: number | null;
53
+ }
54
+ export interface CursorPaging {
55
+ /**
56
+ * Maximum number of domains to return in the results.
57
+ *
58
+ * Min: `0`
59
+ * Max: `20`
60
+ */
61
+ limit?: number | null;
62
+ /**
63
+ * Pointer to the next or previous page in the list of results.
64
+ *
65
+ * You can get the relevant cursor token
66
+ * from the `pagingMetadata` object in the previous call's response.
67
+ * Not relevant for the first request.
68
+ */
69
+ cursor?: string | null;
70
+ }
71
+ export interface SuggestDomainsResponse {
72
+ /** List of suggested available domains. */
73
+ suggestions?: DomainSuggestion[];
74
+ /** Metadata about the returned list of suggested domains. */
75
+ pagingMetadata?: CursorPagingMetadata;
76
+ }
77
+ export interface CursorPagingMetadata {
78
+ /** Number of domains returned in the response. */
79
+ count?: number | null;
80
+ /** Cursors to navigate through the result pages using `next` and `prev`. Returned if cursor paging is used. */
81
+ cursors?: Cursors;
82
+ /**
83
+ * Indicates if there are more results after the current page.
84
+ * If `true`, another page of results can be retrieved.
85
+ * If `false`, this is the last page.
86
+ */
87
+ hasNext?: boolean | null;
88
+ }
89
+ export interface Cursors {
90
+ /** Cursor pointing to next page in the list of results. */
91
+ next?: string | null;
92
+ /** Cursor pointing to previous page in the list of results. */
93
+ prev?: string | null;
94
+ }
95
+ interface DomainSuggestionNonNullableFields {
96
+ domain: string;
97
+ premium: boolean;
98
+ }
99
+ export interface SuggestDomainsResponseNonNullableFields {
100
+ suggestions: DomainSuggestionNonNullableFields[];
101
+ }
102
+ /**
103
+ * Suggests domains that are available for purchase, based on the provided query input.
104
+ *
105
+ * You may use this endpoint to get inspired and then call [Check Domain Availability()](/domainAvailability/check-domain-availability) to check whether a specific variation of the suggestions is also available for purchsase.
106
+ *
107
+ * The `tlds` must not include the dot. For example, `com` and not `.com`.
108
+ *
109
+ * > **Important:** This call requires an account level API key and cannot be authenticated with the standard authorization header.
110
+ * @param query - Input to base your domain suggestions on. May include
111
+ * letters, numbers, spaces, dots, and hyphens. Must not include the TLD.
112
+ *
113
+ * Min: 3 characters
114
+ * Max: 100 characters
115
+ * @public
116
+ * @requiredField query
117
+ * @permissionId DOMAINS.PUBLIC_API_PERMISSION
118
+ * @fqn com.wixpress.premium.domain.search.suggest.v2.DomainSearchService.SuggestDomains
119
+ */
120
+ export declare function suggestDomains(query: string, options?: SuggestDomainsOptions): Promise<SuggestDomainsResponse & SuggestDomainsResponseNonNullableFields>;
121
+ export interface SuggestDomainsOptions {
122
+ /**
123
+ * [Top-level domains](https://en.wikipedia.org/wiki/Top-level_domain). Must
124
+ * not include the dot. For example, `com`, not `.com`. Not all TLDs can be
125
+ * connected to Wix sites. Supported TLDS include `com`, `net`, and `org`.
126
+ * Contact the [Wix B2B sales team](mailto:bizdev@wix.com) for more
127
+ * information.
128
+ *
129
+ * Max: 10 TLDs
130
+ */
131
+ tlds?: string[];
132
+ /**
133
+ * Number of domain suggestions to return. __Deprecated__: This field will be
134
+ * removed on March 1, 2025. Use `paging.limit` instead.
135
+ *
136
+ * Min: `1`
137
+ * Max: `20`
138
+ * Default: `10`
139
+ * @deprecated Number of domain suggestions to return. __Deprecated__: This field will be
140
+ * removed on March 1, 2025. Use `paging.limit` instead.
141
+ *
142
+ * Min: `1`
143
+ * Max: `20`
144
+ * Default: `10`
145
+ * @replacedBy paging.limit
146
+ * @targetRemovalDate 2025-03-01
147
+ */
148
+ limit?: number | null;
149
+ /** Cursor paging options. */
150
+ paging?: CursorPaging;
151
+ /**
152
+ * Maximum number of characters for the domain name, excluding the TLD.
153
+ *
154
+ * Min: `3`
155
+ * Max: `63`
156
+ * Default: `63`
157
+ */
158
+ maxLength?: number | null;
159
+ }
160
+ export {};
@@ -0,0 +1,55 @@
1
+ import { transformError as sdkTransformError } from '@wix/sdk-runtime/transform-error';
2
+ import { renameKeysFromSDKRequestToRESTRequest, renameKeysFromRESTResponseToSDKResponse, } from '@wix/sdk-runtime/rename-all-nested-keys';
3
+ import * as ambassadorWixPremiumDomainsV2Suggestion from './premium-domains-v2-suggestion-domain-suggestions.http.js';
4
+ /**
5
+ * Suggests domains that are available for purchase, based on the provided query input.
6
+ *
7
+ * You may use this endpoint to get inspired and then call [Check Domain Availability()](/domainAvailability/check-domain-availability) to check whether a specific variation of the suggestions is also available for purchsase.
8
+ *
9
+ * The `tlds` must not include the dot. For example, `com` and not `.com`.
10
+ *
11
+ * > **Important:** This call requires an account level API key and cannot be authenticated with the standard authorization header.
12
+ * @param query - Input to base your domain suggestions on. May include
13
+ * letters, numbers, spaces, dots, and hyphens. Must not include the TLD.
14
+ *
15
+ * Min: 3 characters
16
+ * Max: 100 characters
17
+ * @public
18
+ * @requiredField query
19
+ * @permissionId DOMAINS.PUBLIC_API_PERMISSION
20
+ * @fqn com.wixpress.premium.domain.search.suggest.v2.DomainSearchService.SuggestDomains
21
+ */
22
+ export async function suggestDomains(query, options) {
23
+ // @ts-ignore
24
+ const { httpClient, sideEffects } = arguments[2];
25
+ const payload = renameKeysFromSDKRequestToRESTRequest({
26
+ query: query,
27
+ tlds: options?.tlds,
28
+ limit: options?.limit,
29
+ paging: options?.paging,
30
+ maxLength: options?.maxLength,
31
+ });
32
+ const reqOpts = ambassadorWixPremiumDomainsV2Suggestion.suggestDomains(payload);
33
+ sideEffects?.onSiteCall?.();
34
+ try {
35
+ const result = await httpClient.request(reqOpts);
36
+ sideEffects?.onSuccess?.(result);
37
+ return renameKeysFromRESTResponseToSDKResponse(result.data);
38
+ }
39
+ catch (err) {
40
+ const transformedError = sdkTransformError(err, {
41
+ spreadPathsToArguments: {},
42
+ explicitPathsToArguments: {
43
+ query: '$[0]',
44
+ tlds: '$[1].tlds',
45
+ limit: '$[1].limit',
46
+ paging: '$[1].paging',
47
+ maxLength: '$[1].maxLength',
48
+ },
49
+ singleArgumentUnchanged: false,
50
+ }, ['query', 'options']);
51
+ sideEffects?.onError?.(err);
52
+ throw transformedError;
53
+ }
54
+ }
55
+ //# sourceMappingURL=premium-domains-v2-suggestion-domain-suggestions.universal.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"premium-domains-v2-suggestion-domain-suggestions.universal.js","sourceRoot":"","sources":["../../../../src/premium-domains-v2-suggestion-domain-suggestions.universal.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,IAAI,iBAAiB,EAAE,MAAM,kCAAkC,CAAC;AACvF,OAAO,EACL,qCAAqC,EACrC,uCAAuC,GACxC,MAAM,yCAAyC,CAAC;AAEjD,OAAO,KAAK,uCAAuC,MAAM,4DAA4D,CAAC;AA+GtH;;;;;;;;;;;;;;;;;GAiBG;AACH,MAAM,CAAC,KAAK,UAAU,cAAc,CAClC,KAAa,EACb,OAA+B;IAE/B,aAAa;IACb,MAAM,EAAE,UAAU,EAAE,WAAW,EAAE,GAAG,SAAS,CAAC,CAAC,CAG9C,CAAC;IAEF,MAAM,OAAO,GAAG,qCAAqC,CAAC;QACpD,KAAK,EAAE,KAAK;QACZ,IAAI,EAAE,OAAO,EAAE,IAAI;QACnB,KAAK,EAAE,OAAO,EAAE,KAAK;QACrB,MAAM,EAAE,OAAO,EAAE,MAAM;QACvB,SAAS,EAAE,OAAO,EAAE,SAAS;KAC9B,CAAC,CAAC;IAEH,MAAM,OAAO,GACX,uCAAuC,CAAC,cAAc,CAAC,OAAO,CAAC,CAAC;IAElE,WAAW,EAAE,UAAU,EAAE,EAAE,CAAC;IAC5B,IAAI,CAAC;QACH,MAAM,MAAM,GAAG,MAAM,UAAU,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC;QACjD,WAAW,EAAE,SAAS,EAAE,CAAC,MAAM,CAAC,CAAC;QAEjC,OAAO,uCAAuC,CAAC,MAAM,CAAC,IAAI,CAAE,CAAC;IAC/D,CAAC;IAAC,OAAO,GAAQ,EAAE,CAAC;QAClB,MAAM,gBAAgB,GAAG,iBAAiB,CACxC,GAAG,EACH;YACE,sBAAsB,EAAE,EAAE;YAC1B,wBAAwB,EAAE;gBACxB,KAAK,EAAE,MAAM;gBACb,IAAI,EAAE,WAAW;gBACjB,KAAK,EAAE,YAAY;gBACnB,MAAM,EAAE,aAAa;gBACrB,SAAS,EAAE,gBAAgB;aAC5B;YACD,uBAAuB,EAAE,KAAK;SAC/B,EACD,CAAC,OAAO,EAAE,SAAS,CAAC,CACrB,CAAC;QACF,WAAW,EAAE,OAAO,EAAE,CAAC,GAAG,CAAC,CAAC;QAE5B,MAAM,gBAAgB,CAAC;IACzB,CAAC;AACH,CAAC"}
@@ -0,0 +1,3 @@
1
+ {
2
+ "main": "../build/cjs/meta.js"
3
+ }
package/package.json ADDED
@@ -0,0 +1,52 @@
1
+ {
2
+ "name": "@wix/auto_sdk_domains_domain-suggestions",
3
+ "version": "1.0.0",
4
+ "publishConfig": {
5
+ "registry": "https://registry.npmjs.org/",
6
+ "access": "public"
7
+ },
8
+ "keywords": [],
9
+ "sideEffects": false,
10
+ "main": "./build/cjs/index.js",
11
+ "types": "./build/es/index.d.ts",
12
+ "exports": {
13
+ ".": {
14
+ "import": "./build/es/index.js",
15
+ "require": "./build/cjs/index.js",
16
+ "types": "./build/es/index.d.ts"
17
+ },
18
+ "./package.json": "./package.json",
19
+ "./meta": {
20
+ "import": "./build/es/meta.js",
21
+ "require": "./build/cjs/meta.js",
22
+ "types": "./build/es/meta.d.ts"
23
+ }
24
+ },
25
+ "files": [
26
+ "build",
27
+ "meta",
28
+ "service-plugins"
29
+ ],
30
+ "dependencies": {
31
+ "@wix/sdk-runtime": "^0.3.35",
32
+ "@wix/sdk-types": "^1.12.4"
33
+ },
34
+ "devDependencies": {
35
+ "typescript": "^5.3.2"
36
+ },
37
+ "scripts": {
38
+ "build": "tsc -b tsconfig.json tsconfig.esm.json tsconfig.internal.json tsconfig.internal.esm.json",
39
+ "test": ":"
40
+ },
41
+ "wix": {
42
+ "artifact": {
43
+ "artifactId": "auto-sdk-domains-domain-suggestions",
44
+ "groupId": "com.wixpress.public-sdk-dependencies"
45
+ },
46
+ "sdkDependency": {
47
+ "fqdnNamespace": "domainSuggestions",
48
+ "fqdn": "wix.premium.domains.v2.suggestion"
49
+ }
50
+ },
51
+ "falconPackageHash": "708c2efea60deec88740a9d17b3218c81bfc18766fbaa4ac82d119fb"
52
+ }