@wix/auto_sdk_stores_collections 1.0.10 → 1.0.12

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 (119) hide show
  1. package/build/cjs/index.d.ts +34 -1
  2. package/build/cjs/index.js +325 -15
  3. package/build/cjs/index.js.map +1 -1
  4. package/build/cjs/meta.d.ts +228 -1
  5. package/build/cjs/meta.js +238 -15
  6. package/build/cjs/meta.js.map +1 -1
  7. package/build/cjs/{src/stores-catalog-v1-collection-collections.universal.d.ts → stores-catalog-v1-collection-collections.universal-DXVGSHC4.d.ts} +31 -57
  8. package/build/es/index.d.mts +34 -0
  9. package/build/es/index.mjs +300 -0
  10. package/build/es/index.mjs.map +1 -0
  11. package/build/es/{src/stores-catalog-v1-collection-collections.types.d.ts → meta.d.mts} +45 -81
  12. package/build/es/meta.mjs +212 -0
  13. package/build/es/meta.mjs.map +1 -0
  14. package/build/es/{src/stores-catalog-v1-collection-collections.universal.d.ts → stores-catalog-v1-collection-collections.universal-DXVGSHC4.d.mts} +31 -57
  15. package/build/internal/cjs/index.d.ts +34 -1
  16. package/build/internal/cjs/index.js +325 -15
  17. package/build/internal/cjs/index.js.map +1 -1
  18. package/build/internal/cjs/meta.d.ts +228 -1
  19. package/build/internal/cjs/meta.js +238 -15
  20. package/build/internal/cjs/meta.js.map +1 -1
  21. package/build/internal/cjs/{src/stores-catalog-v1-collection-collections.universal.d.ts → stores-catalog-v1-collection-collections.universal-BdGGTv5j.d.ts} +31 -57
  22. package/build/internal/es/index.d.mts +34 -0
  23. package/build/internal/es/index.mjs +300 -0
  24. package/build/internal/es/index.mjs.map +1 -0
  25. package/build/{cjs/src/stores-catalog-v1-collection-collections.types.d.ts → internal/es/meta.d.mts} +45 -81
  26. package/build/internal/es/meta.mjs +212 -0
  27. package/build/internal/es/meta.mjs.map +1 -0
  28. package/build/internal/es/{src/stores-catalog-v1-collection-collections.universal.d.ts → stores-catalog-v1-collection-collections.universal-BdGGTv5j.d.mts} +31 -57
  29. package/package.json +9 -8
  30. package/build/cjs/index.typings.d.ts +0 -1
  31. package/build/cjs/index.typings.js +0 -18
  32. package/build/cjs/index.typings.js.map +0 -1
  33. package/build/cjs/src/stores-catalog-v1-collection-collections.context.d.ts +0 -7
  34. package/build/cjs/src/stores-catalog-v1-collection-collections.context.js +0 -12
  35. package/build/cjs/src/stores-catalog-v1-collection-collections.context.js.map +0 -1
  36. package/build/cjs/src/stores-catalog-v1-collection-collections.http.d.ts +0 -10
  37. package/build/cjs/src/stores-catalog-v1-collection-collections.http.js +0 -162
  38. package/build/cjs/src/stores-catalog-v1-collection-collections.http.js.map +0 -1
  39. package/build/cjs/src/stores-catalog-v1-collection-collections.meta.d.ts +0 -19
  40. package/build/cjs/src/stores-catalog-v1-collection-collections.meta.js +0 -85
  41. package/build/cjs/src/stores-catalog-v1-collection-collections.meta.js.map +0 -1
  42. package/build/cjs/src/stores-catalog-v1-collection-collections.public.d.ts +0 -30
  43. package/build/cjs/src/stores-catalog-v1-collection-collections.public.js +0 -27
  44. package/build/cjs/src/stores-catalog-v1-collection-collections.public.js.map +0 -1
  45. package/build/cjs/src/stores-catalog-v1-collection-collections.types.js +0 -23
  46. package/build/cjs/src/stores-catalog-v1-collection-collections.types.js.map +0 -1
  47. package/build/cjs/src/stores-catalog-v1-collection-collections.universal.js +0 -160
  48. package/build/cjs/src/stores-catalog-v1-collection-collections.universal.js.map +0 -1
  49. package/build/es/index.d.ts +0 -1
  50. package/build/es/index.js +0 -2
  51. package/build/es/index.js.map +0 -1
  52. package/build/es/index.typings.d.ts +0 -1
  53. package/build/es/index.typings.js +0 -2
  54. package/build/es/index.typings.js.map +0 -1
  55. package/build/es/meta.d.ts +0 -1
  56. package/build/es/meta.js +0 -2
  57. package/build/es/meta.js.map +0 -1
  58. package/build/es/src/stores-catalog-v1-collection-collections.context.d.ts +0 -7
  59. package/build/es/src/stores-catalog-v1-collection-collections.context.js +0 -7
  60. package/build/es/src/stores-catalog-v1-collection-collections.context.js.map +0 -1
  61. package/build/es/src/stores-catalog-v1-collection-collections.http.d.ts +0 -10
  62. package/build/es/src/stores-catalog-v1-collection-collections.http.js +0 -156
  63. package/build/es/src/stores-catalog-v1-collection-collections.http.js.map +0 -1
  64. package/build/es/src/stores-catalog-v1-collection-collections.meta.d.ts +0 -19
  65. package/build/es/src/stores-catalog-v1-collection-collections.meta.js +0 -56
  66. package/build/es/src/stores-catalog-v1-collection-collections.meta.js.map +0 -1
  67. package/build/es/src/stores-catalog-v1-collection-collections.public.d.ts +0 -30
  68. package/build/es/src/stores-catalog-v1-collection-collections.public.js +0 -19
  69. package/build/es/src/stores-catalog-v1-collection-collections.public.js.map +0 -1
  70. package/build/es/src/stores-catalog-v1-collection-collections.types.js +0 -20
  71. package/build/es/src/stores-catalog-v1-collection-collections.types.js.map +0 -1
  72. package/build/es/src/stores-catalog-v1-collection-collections.universal.js +0 -131
  73. package/build/es/src/stores-catalog-v1-collection-collections.universal.js.map +0 -1
  74. package/build/internal/cjs/index.typings.d.ts +0 -1
  75. package/build/internal/cjs/index.typings.js +0 -18
  76. package/build/internal/cjs/index.typings.js.map +0 -1
  77. package/build/internal/cjs/src/stores-catalog-v1-collection-collections.context.d.ts +0 -7
  78. package/build/internal/cjs/src/stores-catalog-v1-collection-collections.context.js +0 -12
  79. package/build/internal/cjs/src/stores-catalog-v1-collection-collections.context.js.map +0 -1
  80. package/build/internal/cjs/src/stores-catalog-v1-collection-collections.http.d.ts +0 -10
  81. package/build/internal/cjs/src/stores-catalog-v1-collection-collections.http.js +0 -162
  82. package/build/internal/cjs/src/stores-catalog-v1-collection-collections.http.js.map +0 -1
  83. package/build/internal/cjs/src/stores-catalog-v1-collection-collections.meta.d.ts +0 -19
  84. package/build/internal/cjs/src/stores-catalog-v1-collection-collections.meta.js +0 -85
  85. package/build/internal/cjs/src/stores-catalog-v1-collection-collections.meta.js.map +0 -1
  86. package/build/internal/cjs/src/stores-catalog-v1-collection-collections.public.d.ts +0 -30
  87. package/build/internal/cjs/src/stores-catalog-v1-collection-collections.public.js +0 -27
  88. package/build/internal/cjs/src/stores-catalog-v1-collection-collections.public.js.map +0 -1
  89. package/build/internal/cjs/src/stores-catalog-v1-collection-collections.types.d.ts +0 -264
  90. package/build/internal/cjs/src/stores-catalog-v1-collection-collections.types.js +0 -23
  91. package/build/internal/cjs/src/stores-catalog-v1-collection-collections.types.js.map +0 -1
  92. package/build/internal/cjs/src/stores-catalog-v1-collection-collections.universal.js +0 -160
  93. package/build/internal/cjs/src/stores-catalog-v1-collection-collections.universal.js.map +0 -1
  94. package/build/internal/es/index.d.ts +0 -1
  95. package/build/internal/es/index.js +0 -2
  96. package/build/internal/es/index.js.map +0 -1
  97. package/build/internal/es/index.typings.d.ts +0 -1
  98. package/build/internal/es/index.typings.js +0 -2
  99. package/build/internal/es/index.typings.js.map +0 -1
  100. package/build/internal/es/meta.d.ts +0 -1
  101. package/build/internal/es/meta.js +0 -2
  102. package/build/internal/es/meta.js.map +0 -1
  103. package/build/internal/es/src/stores-catalog-v1-collection-collections.context.d.ts +0 -7
  104. package/build/internal/es/src/stores-catalog-v1-collection-collections.context.js +0 -7
  105. package/build/internal/es/src/stores-catalog-v1-collection-collections.context.js.map +0 -1
  106. package/build/internal/es/src/stores-catalog-v1-collection-collections.http.d.ts +0 -10
  107. package/build/internal/es/src/stores-catalog-v1-collection-collections.http.js +0 -156
  108. package/build/internal/es/src/stores-catalog-v1-collection-collections.http.js.map +0 -1
  109. package/build/internal/es/src/stores-catalog-v1-collection-collections.meta.d.ts +0 -19
  110. package/build/internal/es/src/stores-catalog-v1-collection-collections.meta.js +0 -56
  111. package/build/internal/es/src/stores-catalog-v1-collection-collections.meta.js.map +0 -1
  112. package/build/internal/es/src/stores-catalog-v1-collection-collections.public.d.ts +0 -30
  113. package/build/internal/es/src/stores-catalog-v1-collection-collections.public.js +0 -19
  114. package/build/internal/es/src/stores-catalog-v1-collection-collections.public.js.map +0 -1
  115. package/build/internal/es/src/stores-catalog-v1-collection-collections.types.d.ts +0 -264
  116. package/build/internal/es/src/stores-catalog-v1-collection-collections.types.js +0 -20
  117. package/build/internal/es/src/stores-catalog-v1-collection-collections.types.js.map +0 -1
  118. package/build/internal/es/src/stores-catalog-v1-collection-collections.universal.js +0 -131
  119. package/build/internal/es/src/stores-catalog-v1-collection-collections.universal.js.map +0 -1
@@ -1,156 +0,0 @@
1
- import { toURLSearchParams } from '@wix/sdk-runtime/rest-modules';
2
- import { transformRESTTimestampToSDKTimestamp } from '@wix/sdk-runtime/transformations/timestamp';
3
- import { transformPaths } from '@wix/sdk-runtime/transformations/transform-paths';
4
- import { resolveUrl } from '@wix/sdk-runtime/rest-modules';
5
- function resolveWixCatalogApiV2CollectionReadApiUrl(opts) {
6
- const domainToMappings = {
7
- 'api._api_base_domain_': [
8
- {
9
- srcPath: '/wix-ecommerce-catalog-reader-web',
10
- destPath: '',
11
- },
12
- ],
13
- 'manage._base_domain_': [
14
- {
15
- srcPath: '/wix-ecommerce-catalog-reader-web',
16
- destPath: '',
17
- },
18
- ],
19
- 'www.wixapis.com': [
20
- {
21
- srcPath: '/stores-reader/v2/collections',
22
- destPath: '/v2/collections',
23
- },
24
- {
25
- srcPath: '/stores-reader/v2/inventoryItems',
26
- destPath: '/v2/inventoryItems',
27
- },
28
- ],
29
- 'www._base_domain_': [
30
- {
31
- srcPath: '/wix-ecommerce-catalog-reader-web',
32
- destPath: '',
33
- },
34
- ],
35
- 'editor._base_domain_': [
36
- {
37
- srcPath: '/_api/wix-ecommerce-catalog-reader-web',
38
- destPath: '',
39
- },
40
- ],
41
- 'blocks._base_domain_': [
42
- {
43
- srcPath: '/_api/wix-ecommerce-catalog-reader-web',
44
- destPath: '',
45
- },
46
- ],
47
- 'create.editorx': [
48
- {
49
- srcPath: '/_api/wix-ecommerce-catalog-reader-web',
50
- destPath: '',
51
- },
52
- ],
53
- _: [
54
- {
55
- srcPath: '/stores-reader/v2/inventoryItems',
56
- destPath: '/v2/inventoryItems',
57
- },
58
- {
59
- srcPath: '/stores-reader/v2/collections',
60
- destPath: '/v2/collections',
61
- },
62
- ],
63
- };
64
- return resolveUrl(Object.assign(opts, { domainToMappings }));
65
- }
66
- const PACKAGE_NAME = '@wix/auto_sdk_stores_collections';
67
- /**
68
- * Retrieves a list of up to 100 collections, given the provided paging, sorting and filtering.
69
- * See [Stores Pagination](https://dev.wix.com/api/rest/wix-stores/pagination) for more information.
70
- */
71
- export function queryCollections(payload) {
72
- function __queryCollections({ host }) {
73
- const metadata = {
74
- entityFqdn: 'wix.stores.catalog.v1.collection',
75
- method: 'POST',
76
- methodFqn: 'wix.catalog.api.v2.CollectionReadApi.QueryCollections',
77
- packageName: PACKAGE_NAME,
78
- url: resolveWixCatalogApiV2CollectionReadApiUrl({
79
- protoPath: '/v2/collections/query',
80
- data: payload,
81
- host,
82
- }),
83
- data: payload,
84
- transformResponse: (payload) => transformPaths(payload, [
85
- {
86
- transformFn: transformRESTTimestampToSDKTimestamp,
87
- paths: [{ path: 'collections.lastUpdated' }],
88
- },
89
- ]),
90
- fallback: [
91
- {
92
- method: 'POST',
93
- url: resolveWixCatalogApiV2CollectionReadApiUrl({
94
- protoPath: '/v2/collections/query',
95
- data: payload,
96
- host,
97
- }),
98
- data: payload,
99
- },
100
- ],
101
- };
102
- return metadata;
103
- }
104
- return __queryCollections;
105
- }
106
- /** Retrieves a collection with the provided ID. */
107
- export function getCollection(payload) {
108
- function __getCollection({ host }) {
109
- const metadata = {
110
- entityFqdn: 'wix.stores.catalog.v1.collection',
111
- method: 'GET',
112
- methodFqn: 'wix.catalog.api.v2.CollectionReadApi.GetCollection',
113
- packageName: PACKAGE_NAME,
114
- url: resolveWixCatalogApiV2CollectionReadApiUrl({
115
- protoPath: '/v2/collections/{id}',
116
- data: payload,
117
- host,
118
- }),
119
- params: toURLSearchParams(payload),
120
- transformResponse: (payload) => transformPaths(payload, [
121
- {
122
- transformFn: transformRESTTimestampToSDKTimestamp,
123
- paths: [{ path: 'collection.lastUpdated' }],
124
- },
125
- ]),
126
- };
127
- return metadata;
128
- }
129
- return __getCollection;
130
- }
131
- /** Retrieves a collection with the provided slug. */
132
- export function getCollectionBySlug(payload) {
133
- function __getCollectionBySlug({ host }) {
134
- const metadata = {
135
- entityFqdn: 'wix.stores.catalog.v1.collection',
136
- method: 'GET',
137
- methodFqn: 'wix.catalog.api.v2.CollectionReadApi.GetCollectionBySlug',
138
- packageName: PACKAGE_NAME,
139
- url: resolveWixCatalogApiV2CollectionReadApiUrl({
140
- protoPath: '/v2/collections/slug/{slug}',
141
- data: payload,
142
- host,
143
- }),
144
- params: toURLSearchParams(payload),
145
- transformResponse: (payload) => transformPaths(payload, [
146
- {
147
- transformFn: transformRESTTimestampToSDKTimestamp,
148
- paths: [{ path: 'collection.lastUpdated' }],
149
- },
150
- ]),
151
- };
152
- return metadata;
153
- }
154
- return __getCollectionBySlug;
155
- }
156
- //# sourceMappingURL=stores-catalog-v1-collection-collections.http.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"stores-catalog-v1-collection-collections.http.js","sourceRoot":"","sources":["../../../../src/stores-catalog-v1-collection-collections.http.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,MAAM,+BAA+B,CAAC;AAClE,OAAO,EAAE,oCAAoC,EAAE,MAAM,4CAA4C,CAAC;AAClG,OAAO,EAAE,cAAc,EAAE,MAAM,kDAAkD,CAAC;AAClF,OAAO,EAAE,UAAU,EAAE,MAAM,+BAA+B,CAAC;AAI3D,SAAS,0CAA0C,CACjD,IAA8C;IAE9C,MAAM,gBAAgB,GAAG;QACvB,uBAAuB,EAAE;YACvB;gBACE,OAAO,EAAE,mCAAmC;gBAC5C,QAAQ,EAAE,EAAE;aACb;SACF;QACD,sBAAsB,EAAE;YACtB;gBACE,OAAO,EAAE,mCAAmC;gBAC5C,QAAQ,EAAE,EAAE;aACb;SACF;QACD,iBAAiB,EAAE;YACjB;gBACE,OAAO,EAAE,+BAA+B;gBACxC,QAAQ,EAAE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B,GAAG,EAAE,0CAA0C,CAAC;gBAC9C,SAAS,EAAE,6BAA6B;gBACxC,IAAI,EAAE,OAAO;gBACb,IAAI;aACL,CAAC;YACF,MAAM,EAAE,iBAAiB,CAAC,OAAO,CAAC;YAClC,iBAAiB,EAAE,CAAC,OAAY,EAAE,EAAE,CAClC,cAAc,CAAC,OAAO,EAAE;gBACtB;oBACE,WAAW,EAAE,oCAAoC;oBACjD,KAAK,EAAE,CAAC,EAAE,IAAI,EAAE,wBAAwB,EAAE,CAAC;iBAC5C;aACF,CAAC;SACL,CAAC;QAEF,OAAO,QAAQ,CAAC;IAClB,CAAC;IAED,OAAO,qBAAqB,CAAC;AAC/B,CAAC"}
@@ -1,19 +0,0 @@
1
- import * as ambassadorWixStoresCatalogV1CollectionTypes from './stores-catalog-v1-collection-collections.types.js';
2
- import * as ambassadorWixStoresCatalogV1CollectionUniversalTypes from './stores-catalog-v1-collection-collections.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 queryCollections(): __PublicMethodMetaInfo<'GET', {}, ambassadorWixStoresCatalogV1CollectionUniversalTypes.QueryCollectionsRequest, ambassadorWixStoresCatalogV1CollectionTypes.QueryCollectionsRequest, ambassadorWixStoresCatalogV1CollectionUniversalTypes.QueryCollectionsResponse, ambassadorWixStoresCatalogV1CollectionTypes.QueryCollectionsResponse>;
14
- export declare function getCollection(): __PublicMethodMetaInfo<'GET', {
15
- id: string;
16
- }, ambassadorWixStoresCatalogV1CollectionUniversalTypes.GetCollectionRequest, ambassadorWixStoresCatalogV1CollectionTypes.GetCollectionRequest, ambassadorWixStoresCatalogV1CollectionUniversalTypes.GetCollectionResponse, ambassadorWixStoresCatalogV1CollectionTypes.GetCollectionResponse>;
17
- export declare function getCollectionBySlug(): __PublicMethodMetaInfo<'GET', {
18
- slug: string;
19
- }, ambassadorWixStoresCatalogV1CollectionUniversalTypes.GetCollectionBySlugRequest, ambassadorWixStoresCatalogV1CollectionTypes.GetCollectionBySlugRequest, ambassadorWixStoresCatalogV1CollectionUniversalTypes.GetCollectionBySlugResponse, ambassadorWixStoresCatalogV1CollectionTypes.GetCollectionBySlugResponse>;
@@ -1,56 +0,0 @@
1
- import * as ambassadorWixStoresCatalogV1Collection from './stores-catalog-v1-collection-collections.http.js';
2
- export function queryCollections() {
3
- const payload = {};
4
- const getRequestOptions = ambassadorWixStoresCatalogV1Collection.queryCollections(payload);
5
- const getUrl = (context) => {
6
- const { url } = getRequestOptions(context);
7
- return url;
8
- };
9
- return {
10
- getUrl,
11
- httpMethod: 'GET',
12
- path: '/v2/collections/query',
13
- pathParams: {},
14
- __requestType: null,
15
- __originalRequestType: null,
16
- __responseType: null,
17
- __originalResponseType: null,
18
- };
19
- }
20
- export function getCollection() {
21
- const payload = { id: ':id' };
22
- const getRequestOptions = ambassadorWixStoresCatalogV1Collection.getCollection(payload);
23
- const getUrl = (context) => {
24
- const { url } = getRequestOptions(context);
25
- return url;
26
- };
27
- return {
28
- getUrl,
29
- httpMethod: 'GET',
30
- path: '/v2/collections/{id}',
31
- pathParams: { id: 'id' },
32
- __requestType: null,
33
- __originalRequestType: null,
34
- __responseType: null,
35
- __originalResponseType: null,
36
- };
37
- }
38
- export function getCollectionBySlug() {
39
- const payload = { slug: ':slug' };
40
- const getRequestOptions = ambassadorWixStoresCatalogV1Collection.getCollectionBySlug(payload);
41
- const getUrl = (context) => {
42
- const { url } = getRequestOptions(context);
43
- return url;
44
- };
45
- return {
46
- getUrl,
47
- httpMethod: 'GET',
48
- path: '/v2/collections/slug/{slug}',
49
- pathParams: { slug: 'slug' },
50
- __requestType: null,
51
- __originalRequestType: null,
52
- __responseType: null,
53
- __originalResponseType: null,
54
- };
55
- }
56
- //# sourceMappingURL=stores-catalog-v1-collection-collections.meta.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"stores-catalog-v1-collection-collections.meta.js","sourceRoot":"","sources":["../../../../src/stores-catalog-v1-collection-collections.meta.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,sCAAsC,MAAM,oDAAoD,CAAC;AAsB7G,MAAM,UAAU,gBAAgB;IAQ9B,MAAM,OAAO,GAAG,EAAS,CAAC;IAE1B,MAAM,iBAAiB,GACrB,sCAAsC,CAAC,gBAAgB,CAAC,OAAO,CAAC,CAAC;IAEnE,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,uBAAuB;QAC7B,UAAU,EAAE,EAAE;QACd,aAAa,EAAE,IAAW;QAC1B,qBAAqB,EAAE,IAAW;QAClC,cAAc,EAAE,IAAW;QAC3B,sBAAsB,EAAE,IAAW;KACpC,CAAC;AACJ,CAAC;AAED,MAAM,UAAU,aAAa;IAQ3B,MAAM,OAAO,GAAG,EAAE,EAAE,EAAE,KAAK,EAAS,CAAC;IAErC,MAAM,iBAAiB,GACrB,sCAAsC,CAAC,aAAa,CAAC,OAAO,CAAC,CAAC;IAEhE,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,sBAAsB;QAC5B,UAAU,EAAE,EAAE,EAAE,EAAE,IAAI,EAAE;QACxB,aAAa,EAAE,IAAW;QAC1B,qBAAqB,EAAE,IAAW;QAClC,cAAc,EAAE,IAAW;QAC3B,sBAAsB,EAAE,IAAW;KACpC,CAAC;AACJ,CAAC;AAED,MAAM,UAAU,mBAAmB;IAQjC,MAAM,OAAO,GAAG,EAAE,IAAI,EAAE,OAAO,EAAS,CAAC;IAEzC,MAAM,iBAAiB,GACrB,sCAAsC,CAAC,mBAAmB,CAAC,OAAO,CAAC,CAAC;IAEtE,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,6BAA6B;QACnC,UAAU,EAAE,EAAE,IAAI,EAAE,MAAM,EAAE;QAC5B,aAAa,EAAE,IAAW;QAC1B,qBAAqB,EAAE,IAAW;QAClC,cAAc,EAAE,IAAW;QAC3B,sBAAsB,EAAE,IAAW;KACpC,CAAC;AACJ,CAAC"}
@@ -1,30 +0,0 @@
1
- import { HttpClient } from '@wix/sdk-types';
2
- import { Collection, CollectionsQueryBuilder, GetCollectionBySlugResponse } from './stores-catalog-v1-collection-collections.universal.js';
3
- export declare const __metadata: {
4
- PACKAGE_NAME: string;
5
- };
6
- export declare function queryCollections(httpClient: HttpClient): QueryCollectionsSignature;
7
- interface QueryCollectionsSignature {
8
- /**
9
- * Retrieves a list of up to 100 collections, given the provided paging, sorting and filtering.
10
- * See [Stores Pagination](https://dev.wix.com/api/rest/wix-stores/pagination) for more information.
11
- */
12
- (): CollectionsQueryBuilder;
13
- }
14
- export declare function getCollection(httpClient: HttpClient): GetCollectionSignature;
15
- interface GetCollectionSignature {
16
- /**
17
- * Retrieves a collection with the provided ID.
18
- * @param - Requested collection ID.
19
- */
20
- (_id: string): Promise<Collection>;
21
- }
22
- export declare function getCollectionBySlug(httpClient: HttpClient): GetCollectionBySlugSignature;
23
- interface GetCollectionBySlugSignature {
24
- /**
25
- * Retrieves a collection with the provided slug.
26
- * @param - Slug of the collection to retrieve.
27
- */
28
- (slug: string): Promise<GetCollectionBySlugResponse>;
29
- }
30
- export { Collection, CollectionsQueryBuilder, CollectionsQueryResult, CursorPaging, Cursors, GetCollectionBySlugRequest, GetCollectionBySlugResponse, GetCollectionRequest, GetCollectionResponse, Keyword, Media, MediaItem, MediaItemItemOneOf, MediaItemType, MediaItemUrlAndSize, MediaItemVideo, PlatformPaging, PlatformPagingMetadata, PlatformQuery, PlatformQueryPagingMethodOneOf, QueryCollectionsRequest, QueryCollectionsResponse, SeoSchema, Settings, SortOrder, Sorting, Tag, } from './stores-catalog-v1-collection-collections.universal.js';
@@ -1,19 +0,0 @@
1
- import { getCollection as universalGetCollection, getCollectionBySlug as universalGetCollectionBySlug, queryCollections as universalQueryCollections, } from './stores-catalog-v1-collection-collections.universal.js';
2
- export const __metadata = { PACKAGE_NAME: '@wix/stores' };
3
- export function queryCollections(httpClient) {
4
- return () => universalQueryCollections(
5
- // @ts-ignore
6
- { httpClient });
7
- }
8
- export function getCollection(httpClient) {
9
- return (_id) => universalGetCollection(_id,
10
- // @ts-ignore
11
- { httpClient });
12
- }
13
- export function getCollectionBySlug(httpClient) {
14
- return (slug) => universalGetCollectionBySlug(slug,
15
- // @ts-ignore
16
- { httpClient });
17
- }
18
- export { MediaItemType, SortOrder, } from './stores-catalog-v1-collection-collections.universal.js';
19
- //# sourceMappingURL=stores-catalog-v1-collection-collections.public.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"stores-catalog-v1-collection-collections.public.js","sourceRoot":"","sources":["../../../../src/stores-catalog-v1-collection-collections.public.ts"],"names":[],"mappings":"AACA,OAAO,EAIL,aAAa,IAAI,sBAAsB,EACvC,mBAAmB,IAAI,4BAA4B,EACnD,gBAAgB,IAAI,yBAAyB,GAC9C,MAAM,yDAAyD,CAAC;AAEjE,MAAM,CAAC,MAAM,UAAU,GAAG,EAAE,YAAY,EAAE,aAAa,EAAE,CAAC;AAE1D,MAAM,UAAU,gBAAgB,CAC9B,UAAsB;IAEtB,OAAO,GAAG,EAAE,CACV,yBAAyB;IACvB,aAAa;IACb,EAAE,UAAU,EAAE,CACf,CAAC;AACN,CAAC;AAUD,MAAM,UAAU,aAAa,CAAC,UAAsB;IAClD,OAAO,CAAC,GAAW,EAAE,EAAE,CACrB,sBAAsB,CACpB,GAAG;IACH,aAAa;IACb,EAAE,UAAU,EAAE,CACf,CAAC;AACN,CAAC;AAUD,MAAM,UAAU,mBAAmB,CACjC,UAAsB;IAEtB,OAAO,CAAC,IAAY,EAAE,EAAE,CACtB,4BAA4B,CAC1B,IAAI;IACJ,aAAa;IACb,EAAE,UAAU,EAAE,CACf,CAAC;AACN,CAAC;AAUD,OAAO,EAcL,aAAa,EAWb,SAAS,GAGV,MAAM,yDAAyD,CAAC"}
@@ -1,264 +0,0 @@
1
- export interface Collection {
2
- /**
3
- * Collection ID (generated automatically by the catalog).
4
- * @minLength 35
5
- * @maxLength 36
6
- * @readonly
7
- */
8
- id?: string | null;
9
- /**
10
- * Collection name.
11
- * @minLength 1
12
- * @maxLength 50
13
- */
14
- name?: string | null;
15
- /**
16
- * Media items (images, videos etc) associated with this collection. Read only.
17
- * @readonly
18
- */
19
- media?: Media;
20
- /**
21
- * Number of products in the collection. Read only.
22
- * @readonly
23
- */
24
- numberOfProducts?: number;
25
- /**
26
- * Collection description.
27
- * @maxLength 600
28
- */
29
- description?: string | null;
30
- /**
31
- * Collection slug.
32
- * @minLength 1
33
- * @maxLength 100
34
- */
35
- slug?: string | null;
36
- /** Collection visibility. Only impacts dynamic pages, no impact on static pages. Default: `true`. */
37
- visible?: boolean | null;
38
- }
39
- export interface Media {
40
- /** Primary media (image, video etc) associated with this product. */
41
- mainMedia?: MediaItem;
42
- /** Media (images, videos etc) associated with this product. */
43
- items?: MediaItem[];
44
- }
45
- export interface MediaItem extends MediaItemItemOneOf {
46
- /** Image data (URL, size). */
47
- image?: MediaItemUrlAndSize;
48
- /** Video data (URL, size). */
49
- video?: MediaItemVideo;
50
- /** Media item thumbnail details. */
51
- thumbnail?: MediaItemUrlAndSize;
52
- /** Media item type (image, video, etc.). */
53
- mediaType?: MediaItemTypeWithLiterals;
54
- /** Media item title. */
55
- title?: string;
56
- /** Media ID (for example, `"nsplsh_306d666a123a4a74306459~mv2_d_4517_2992_s_4_2.jpg"`). */
57
- id?: string;
58
- }
59
- /** @oneof */
60
- export interface MediaItemItemOneOf {
61
- /** Image data (URL, size). */
62
- image?: MediaItemUrlAndSize;
63
- /** Video data (URL, size). */
64
- video?: MediaItemVideo;
65
- }
66
- export interface MediaItemUrlAndSize {
67
- /**
68
- * Media item URL.
69
- * @format WEB_URL
70
- */
71
- url?: string;
72
- /** Media item width. */
73
- width?: number;
74
- /** Media item height. */
75
- height?: number;
76
- /** Media format (mp4, png, etc.). */
77
- format?: string | null;
78
- /** Alt text. This text will be shown in case the image is not available. */
79
- altText?: string | null;
80
- }
81
- export declare enum MediaItemType {
82
- unspecified_media_item_type = "unspecified_media_item_type",
83
- /** Image media type. */
84
- image = "image",
85
- /** Video media type. */
86
- video = "video",
87
- /** Audio media type. */
88
- audio = "audio",
89
- /** Document media type. */
90
- document = "document",
91
- /** Zip media type. */
92
- zip = "zip"
93
- }
94
- /** @enumType */
95
- export type MediaItemTypeWithLiterals = MediaItemType | 'unspecified_media_item_type' | 'image' | 'video' | 'audio' | 'document' | 'zip';
96
- export interface MediaItemVideo {
97
- /** Data (URL, size) about each resolution for which this video is available. */
98
- files?: MediaItemUrlAndSize[];
99
- /** ID of an image taken from the video. Used primarily for Wix Search indexing. For example, `"nsplsh_306d666a123a4a74306459~mv2_d_4517_2992_s_4_2.jpg"`. */
100
- stillFrameMediaId?: string;
101
- }
102
- /**
103
- * The SEO schema object contains data about different types of meta tags. It makes sure that the information about your page is presented properly to search engines.
104
- * The search engines use this information for ranking purposes, or to display snippets in the search results.
105
- * This data will override other sources of tags (for example patterns) and will be included in the <head> section of the HTML document, while not being displayed on the page itself.
106
- */
107
- export interface SeoSchema {
108
- /** SEO tag information. */
109
- tags?: Tag[];
110
- /** SEO general settings. */
111
- settings?: Settings;
112
- }
113
- export interface Keyword {
114
- /** Keyword value. */
115
- term?: string;
116
- /** Whether the keyword is the main focus keyword. */
117
- isMain?: boolean;
118
- /**
119
- * The source that added the keyword terms to the SEO settings.
120
- * @maxLength 1000
121
- */
122
- origin?: string | null;
123
- }
124
- export interface Tag {
125
- /**
126
- * SEO tag type.
127
- *
128
- *
129
- * Supported values: `title`, `meta`, `script`, `link`.
130
- */
131
- type?: string;
132
- /**
133
- * A `{"key": "value"}` pair object where each SEO tag property (`"name"`, `"content"`, `"rel"`, `"href"`) contains a value.
134
- * For example: `{"name": "description", "content": "the description itself"}`.
135
- */
136
- props?: Record<string, any> | null;
137
- /** SEO tag meta data. For example, `{"height": 300, "width": 240}`. */
138
- meta?: Record<string, any> | null;
139
- /** SEO tag inner content. For example, `<title> inner content </title>`. */
140
- children?: string;
141
- /** Whether the tag is a custom tag. */
142
- custom?: boolean;
143
- /** Whether the tag is disabled. */
144
- disabled?: boolean;
145
- }
146
- export interface Settings {
147
- /**
148
- * Whether the Auto Redirect feature, which creates `301 redirects` on a slug change, is enabled.
149
- *
150
- *
151
- * Default: `false` (Auto Redirect is enabled.)
152
- */
153
- preventAutoRedirect?: boolean;
154
- /**
155
- * User-selected keyword terms for a specific page.
156
- * @maxSize 5
157
- */
158
- keywords?: Keyword[];
159
- }
160
- export interface QueryCollectionsRequest {
161
- query?: PlatformQuery;
162
- }
163
- export interface PlatformQuery extends PlatformQueryPagingMethodOneOf {
164
- /** Pointer to page of results using offset. Cannot be used together with `cursorPaging`. */
165
- paging?: PlatformPaging;
166
- /** Cursor pointing to page of results. Cannot be used together with `paging`. `cursorPaging.cursor` can not be used together with `filter` or `sort`. */
167
- cursorPaging?: CursorPaging;
168
- /** Filter object. */
169
- filter?: Record<string, any> | null;
170
- /** Sorting options. For example, `[{"fieldName":"sortField1"},{"fieldName":"sortField2","direction":"DESC"}]`. */
171
- sort?: Sorting[];
172
- }
173
- /** @oneof */
174
- export interface PlatformQueryPagingMethodOneOf {
175
- /** Pointer to page of results using offset. Cannot be used together with `cursorPaging`. */
176
- paging?: PlatformPaging;
177
- /** Cursor pointing to page of results. Cannot be used together with `paging`. `cursorPaging.cursor` can not be used together with `filter` or `sort`. */
178
- cursorPaging?: CursorPaging;
179
- }
180
- export interface Sorting {
181
- /**
182
- * Name of the field to sort by.
183
- * @maxLength 512
184
- */
185
- fieldName?: string;
186
- /** Sort order. */
187
- order?: SortOrderWithLiterals;
188
- }
189
- export declare enum SortOrder {
190
- ASC = "ASC",
191
- DESC = "DESC"
192
- }
193
- /** @enumType */
194
- export type SortOrderWithLiterals = SortOrder | 'ASC' | 'DESC';
195
- export interface PlatformPaging {
196
- /**
197
- * Number of items to load.
198
- * @max 100
199
- */
200
- limit?: number | null;
201
- /** Number of items to skip in the current sort order. */
202
- offset?: number | null;
203
- }
204
- export interface CursorPaging {
205
- /**
206
- * Maximum number of items to return in the results.
207
- * @max 100
208
- */
209
- limit?: number | null;
210
- /**
211
- * Pointer to the next or previous page in the list of results.
212
- *
213
- * Pass the relevant cursor token from the `pagingMetadata` object in the previous call's response.
214
- * Not relevant for the first request.
215
- * @maxLength 16000
216
- */
217
- cursor?: string | null;
218
- }
219
- export interface QueryCollectionsResponse {
220
- /** @maxSize 100 */
221
- collections?: Collection[];
222
- metadata?: PlatformPagingMetadata;
223
- }
224
- export interface PlatformPagingMetadata {
225
- /** The number of items returned in this response. */
226
- count?: number | null;
227
- /** The offset which was requested. Returned if offset paging was used. */
228
- offset?: number | null;
229
- /** The total number of items that match the query. Returned if offset paging was used. */
230
- total?: number | null;
231
- /** Cursors to navigate through result pages. Returned if cursor paging was used. */
232
- cursors?: Cursors;
233
- }
234
- export interface Cursors {
235
- /**
236
- * Cursor string pointing to the next page in the list of results.
237
- * @maxLength 16000
238
- */
239
- next?: string | null;
240
- /**
241
- * Cursor pointing to the previous page in the list of results.
242
- * @maxLength 16000
243
- */
244
- prev?: string | null;
245
- }
246
- export interface GetCollectionRequest {
247
- /** Requested collection ID. */
248
- id: string;
249
- }
250
- export interface GetCollectionResponse {
251
- collection?: Collection;
252
- }
253
- export interface GetCollectionBySlugRequest {
254
- /**
255
- * Slug of the collection to retrieve.
256
- * @minLength 1
257
- * @maxLength 100
258
- */
259
- slug: string;
260
- }
261
- export interface GetCollectionBySlugResponse {
262
- /** The requested collection. */
263
- collection?: Collection;
264
- }
@@ -1,20 +0,0 @@
1
- export var MediaItemType;
2
- (function (MediaItemType) {
3
- MediaItemType["unspecified_media_item_type"] = "unspecified_media_item_type";
4
- /** Image media type. */
5
- MediaItemType["image"] = "image";
6
- /** Video media type. */
7
- MediaItemType["video"] = "video";
8
- /** Audio media type. */
9
- MediaItemType["audio"] = "audio";
10
- /** Document media type. */
11
- MediaItemType["document"] = "document";
12
- /** Zip media type. */
13
- MediaItemType["zip"] = "zip";
14
- })(MediaItemType || (MediaItemType = {}));
15
- export var SortOrder;
16
- (function (SortOrder) {
17
- SortOrder["ASC"] = "ASC";
18
- SortOrder["DESC"] = "DESC";
19
- })(SortOrder || (SortOrder = {}));
20
- //# sourceMappingURL=stores-catalog-v1-collection-collections.types.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"stores-catalog-v1-collection-collections.types.js","sourceRoot":"","sources":["../../../../src/stores-catalog-v1-collection-collections.types.ts"],"names":[],"mappings":"AAqFA,MAAM,CAAN,IAAY,aAYX;AAZD,WAAY,aAAa;IACvB,4EAA2D,CAAA;IAC3D,wBAAwB;IACxB,gCAAe,CAAA;IACf,wBAAwB;IACxB,gCAAe,CAAA;IACf,wBAAwB;IACxB,gCAAe,CAAA;IACf,2BAA2B;IAC3B,sCAAqB,CAAA;IACrB,sBAAsB;IACtB,4BAAW,CAAA;AACb,CAAC,EAZW,aAAa,KAAb,aAAa,QAYxB;AAkHD,MAAM,CAAN,IAAY,SAGX;AAHD,WAAY,SAAS;IACnB,wBAAW,CAAA;IACX,0BAAa,CAAA;AACf,CAAC,EAHW,SAAS,KAAT,SAAS,QAGpB"}