@wix/auto_sdk_faq_question-entry 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.
- package/build/cjs/index.d.ts +1 -0
- package/build/cjs/index.js +18 -0
- package/build/cjs/index.js.map +1 -0
- package/build/cjs/index.typings.d.ts +1 -0
- package/build/cjs/index.typings.js +18 -0
- package/build/cjs/index.typings.js.map +1 -0
- package/build/cjs/meta.d.ts +1 -0
- package/build/cjs/meta.js +18 -0
- package/build/cjs/meta.js.map +1 -0
- package/build/cjs/src/faq-question-entry-v2-question-entry-question-entry.context.d.ts +24 -0
- package/build/cjs/src/faq-question-entry-v2-question-entry-question-entry.context.js +63 -0
- package/build/cjs/src/faq-question-entry-v2-question-entry-question-entry.context.js.map +1 -0
- package/build/cjs/src/faq-question-entry-v2-question-entry-question-entry.http.d.ts +42 -0
- package/build/cjs/src/faq-question-entry-v2-question-entry-question-entry.http.js +1054 -0
- package/build/cjs/src/faq-question-entry-v2-question-entry-question-entry.http.js.map +1 -0
- package/build/cjs/src/faq-question-entry-v2-question-entry-question-entry.meta.d.ts +32 -0
- package/build/cjs/src/faq-question-entry-v2-question-entry-question-entry.meta.js +218 -0
- package/build/cjs/src/faq-question-entry-v2-question-entry-question-entry.meta.js.map +1 -0
- package/build/cjs/src/faq-question-entry-v2-question-entry-question-entry.public.d.ts +101 -0
- package/build/cjs/src/faq-question-entry-v2-question-entry-question-entry.public.js +248 -0
- package/build/cjs/src/faq-question-entry-v2-question-entry-question-entry.public.js.map +1 -0
- package/build/cjs/src/faq-question-entry-v2-question-entry-question-entry.types.d.ts +2012 -0
- package/build/cjs/src/faq-question-entry-v2-question-entry-question-entry.types.js +343 -0
- package/build/cjs/src/faq-question-entry-v2-question-entry-question-entry.types.js.map +1 -0
- package/build/cjs/src/faq-question-entry-v2-question-entry-question-entry.universal.d.ts +2372 -0
- package/build/cjs/src/faq-question-entry-v2-question-entry-question-entry.universal.js +795 -0
- package/build/cjs/src/faq-question-entry-v2-question-entry-question-entry.universal.js.map +1 -0
- package/build/es/index.d.ts +1 -0
- package/build/es/index.js +2 -0
- package/build/es/index.js.map +1 -0
- package/build/es/index.typings.d.ts +1 -0
- package/build/es/index.typings.js +2 -0
- package/build/es/index.typings.js.map +1 -0
- package/build/es/meta.d.ts +1 -0
- package/build/es/meta.js +2 -0
- package/build/es/meta.js.map +1 -0
- package/build/es/package.json +3 -0
- package/build/es/src/faq-question-entry-v2-question-entry-question-entry.context.d.ts +24 -0
- package/build/es/src/faq-question-entry-v2-question-entry-question-entry.context.js +24 -0
- package/build/es/src/faq-question-entry-v2-question-entry-question-entry.context.js.map +1 -0
- package/build/es/src/faq-question-entry-v2-question-entry-question-entry.http.d.ts +42 -0
- package/build/es/src/faq-question-entry-v2-question-entry-question-entry.http.js +1041 -0
- package/build/es/src/faq-question-entry-v2-question-entry-question-entry.http.js.map +1 -0
- package/build/es/src/faq-question-entry-v2-question-entry-question-entry.meta.d.ts +32 -0
- package/build/es/src/faq-question-entry-v2-question-entry-question-entry.meta.js +182 -0
- package/build/es/src/faq-question-entry-v2-question-entry-question-entry.meta.js.map +1 -0
- package/build/es/src/faq-question-entry-v2-question-entry-question-entry.public.d.ts +101 -0
- package/build/es/src/faq-question-entry-v2-question-entry-question-entry.public.js +199 -0
- package/build/es/src/faq-question-entry-v2-question-entry-question-entry.public.js.map +1 -0
- package/build/es/src/faq-question-entry-v2-question-entry-question-entry.types.d.ts +2012 -0
- package/build/es/src/faq-question-entry-v2-question-entry-question-entry.types.js +340 -0
- package/build/es/src/faq-question-entry-v2-question-entry-question-entry.types.js.map +1 -0
- package/build/es/src/faq-question-entry-v2-question-entry-question-entry.universal.d.ts +2372 -0
- package/build/es/src/faq-question-entry-v2-question-entry-question-entry.universal.js +759 -0
- package/build/es/src/faq-question-entry-v2-question-entry-question-entry.universal.js.map +1 -0
- package/build/internal/cjs/index.d.ts +1 -0
- package/build/internal/cjs/index.js +18 -0
- package/build/internal/cjs/index.js.map +1 -0
- package/build/internal/cjs/index.typings.d.ts +1 -0
- package/build/internal/cjs/index.typings.js +18 -0
- package/build/internal/cjs/index.typings.js.map +1 -0
- package/build/internal/cjs/meta.d.ts +1 -0
- package/build/internal/cjs/meta.js +18 -0
- package/build/internal/cjs/meta.js.map +1 -0
- package/build/internal/cjs/src/faq-question-entry-v2-question-entry-question-entry.context.d.ts +24 -0
- package/build/internal/cjs/src/faq-question-entry-v2-question-entry-question-entry.context.js +63 -0
- package/build/internal/cjs/src/faq-question-entry-v2-question-entry-question-entry.context.js.map +1 -0
- package/build/internal/cjs/src/faq-question-entry-v2-question-entry-question-entry.http.d.ts +42 -0
- package/build/internal/cjs/src/faq-question-entry-v2-question-entry-question-entry.http.js +1054 -0
- package/build/internal/cjs/src/faq-question-entry-v2-question-entry-question-entry.http.js.map +1 -0
- package/build/internal/cjs/src/faq-question-entry-v2-question-entry-question-entry.meta.d.ts +32 -0
- package/build/internal/cjs/src/faq-question-entry-v2-question-entry-question-entry.meta.js +218 -0
- package/build/internal/cjs/src/faq-question-entry-v2-question-entry-question-entry.meta.js.map +1 -0
- package/build/internal/cjs/src/faq-question-entry-v2-question-entry-question-entry.public.d.ts +101 -0
- package/build/internal/cjs/src/faq-question-entry-v2-question-entry-question-entry.public.js +248 -0
- package/build/internal/cjs/src/faq-question-entry-v2-question-entry-question-entry.public.js.map +1 -0
- package/build/internal/cjs/src/faq-question-entry-v2-question-entry-question-entry.types.d.ts +2012 -0
- package/build/internal/cjs/src/faq-question-entry-v2-question-entry-question-entry.types.js +343 -0
- package/build/internal/cjs/src/faq-question-entry-v2-question-entry-question-entry.types.js.map +1 -0
- package/build/internal/cjs/src/faq-question-entry-v2-question-entry-question-entry.universal.d.ts +2372 -0
- package/build/internal/cjs/src/faq-question-entry-v2-question-entry-question-entry.universal.js +795 -0
- package/build/internal/cjs/src/faq-question-entry-v2-question-entry-question-entry.universal.js.map +1 -0
- package/build/internal/es/index.d.ts +1 -0
- package/build/internal/es/index.js +2 -0
- package/build/internal/es/index.js.map +1 -0
- package/build/internal/es/index.typings.d.ts +1 -0
- package/build/internal/es/index.typings.js +2 -0
- package/build/internal/es/index.typings.js.map +1 -0
- package/build/internal/es/meta.d.ts +1 -0
- package/build/internal/es/meta.js +2 -0
- package/build/internal/es/meta.js.map +1 -0
- package/build/internal/es/src/faq-question-entry-v2-question-entry-question-entry.context.d.ts +24 -0
- package/build/internal/es/src/faq-question-entry-v2-question-entry-question-entry.context.js +24 -0
- package/build/internal/es/src/faq-question-entry-v2-question-entry-question-entry.context.js.map +1 -0
- package/build/internal/es/src/faq-question-entry-v2-question-entry-question-entry.http.d.ts +42 -0
- package/build/internal/es/src/faq-question-entry-v2-question-entry-question-entry.http.js +1041 -0
- package/build/internal/es/src/faq-question-entry-v2-question-entry-question-entry.http.js.map +1 -0
- package/build/internal/es/src/faq-question-entry-v2-question-entry-question-entry.meta.d.ts +32 -0
- package/build/internal/es/src/faq-question-entry-v2-question-entry-question-entry.meta.js +182 -0
- package/build/internal/es/src/faq-question-entry-v2-question-entry-question-entry.meta.js.map +1 -0
- package/build/internal/es/src/faq-question-entry-v2-question-entry-question-entry.public.d.ts +101 -0
- package/build/internal/es/src/faq-question-entry-v2-question-entry-question-entry.public.js +199 -0
- package/build/internal/es/src/faq-question-entry-v2-question-entry-question-entry.public.js.map +1 -0
- package/build/internal/es/src/faq-question-entry-v2-question-entry-question-entry.types.d.ts +2012 -0
- package/build/internal/es/src/faq-question-entry-v2-question-entry-question-entry.types.js +340 -0
- package/build/internal/es/src/faq-question-entry-v2-question-entry-question-entry.types.js.map +1 -0
- package/build/internal/es/src/faq-question-entry-v2-question-entry-question-entry.universal.d.ts +2372 -0
- package/build/internal/es/src/faq-question-entry-v2-question-entry-question-entry.universal.js +759 -0
- package/build/internal/es/src/faq-question-entry-v2-question-entry-question-entry.universal.js.map +1 -0
- package/meta/package.json +3 -0
- package/package.json +52 -0
package/build/internal/cjs/src/faq-question-entry-v2-question-entry-question-entry.universal.js
ADDED
|
@@ -0,0 +1,795 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
+
}) : function(o, v) {
|
|
16
|
+
o["default"] = v;
|
|
17
|
+
});
|
|
18
|
+
var __importStar = (this && this.__importStar) || function (mod) {
|
|
19
|
+
if (mod && mod.__esModule) return mod;
|
|
20
|
+
var result = {};
|
|
21
|
+
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
22
|
+
__setModuleDefault(result, mod);
|
|
23
|
+
return result;
|
|
24
|
+
};
|
|
25
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
26
|
+
exports.bulkUpdateQuestionEntry = exports.setQuestionEntryLabels = exports.updateExtendedFields = exports.bulkDeleteQuestionEntry = exports.queryQuestionEntries = exports.listQuestionEntries = exports.deleteQuestionEntry = exports.updateQuestionEntry = exports.getQuestionEntry = exports.createQuestionEntry = exports.WebhookIdentityType = exports.QueryQuestionEntriesRequestFieldSet = exports.QueryQuestionEntriesRequestContentFormat = exports.SortOrder = exports.FieldSet = exports.ContentFormat = exports.QuestionStatus = exports.NullValue = exports.VerticalAlignment = exports.Direction = exports.InitialExpandedItems = exports.AppType = exports.FontType = exports.DecorationType = exports.BackgroundType = exports.PollLayoutDirection = exports.PollLayoutType = exports.VoteRole = exports.ViewRole = exports.MapType = exports.Source = exports.GIFType = exports.ThumbnailsAlignment = exports.Crop = exports.Orientation = exports.LayoutType = exports.ViewMode = exports.Alignment = exports.Width = exports.LineStyle = exports.TextAlignment = exports.Target = exports.Type = exports.PluginContainerDataAlignment = exports.WidthType = exports.NodeType = void 0;
|
|
27
|
+
const transform_error_1 = require("@wix/sdk-runtime/transform-error");
|
|
28
|
+
const query_builder_1 = require("@wix/sdk-runtime/query-builder");
|
|
29
|
+
const rename_all_nested_keys_1 = require("@wix/sdk-runtime/rename-all-nested-keys");
|
|
30
|
+
const ambassadorWixFaqQuestionEntryV2QuestionEntry = __importStar(require("./faq-question-entry-v2-question-entry-question-entry.http.js"));
|
|
31
|
+
var NodeType;
|
|
32
|
+
(function (NodeType) {
|
|
33
|
+
NodeType["PARAGRAPH"] = "PARAGRAPH";
|
|
34
|
+
NodeType["TEXT"] = "TEXT";
|
|
35
|
+
NodeType["HEADING"] = "HEADING";
|
|
36
|
+
NodeType["BULLETED_LIST"] = "BULLETED_LIST";
|
|
37
|
+
NodeType["ORDERED_LIST"] = "ORDERED_LIST";
|
|
38
|
+
NodeType["LIST_ITEM"] = "LIST_ITEM";
|
|
39
|
+
NodeType["BLOCKQUOTE"] = "BLOCKQUOTE";
|
|
40
|
+
NodeType["CODE_BLOCK"] = "CODE_BLOCK";
|
|
41
|
+
NodeType["VIDEO"] = "VIDEO";
|
|
42
|
+
NodeType["DIVIDER"] = "DIVIDER";
|
|
43
|
+
NodeType["FILE"] = "FILE";
|
|
44
|
+
NodeType["GALLERY"] = "GALLERY";
|
|
45
|
+
NodeType["GIF"] = "GIF";
|
|
46
|
+
NodeType["HTML"] = "HTML";
|
|
47
|
+
NodeType["IMAGE"] = "IMAGE";
|
|
48
|
+
NodeType["LINK_PREVIEW"] = "LINK_PREVIEW";
|
|
49
|
+
/** @deprecated */
|
|
50
|
+
NodeType["MAP"] = "MAP";
|
|
51
|
+
NodeType["POLL"] = "POLL";
|
|
52
|
+
NodeType["APP_EMBED"] = "APP_EMBED";
|
|
53
|
+
NodeType["BUTTON"] = "BUTTON";
|
|
54
|
+
NodeType["COLLAPSIBLE_LIST"] = "COLLAPSIBLE_LIST";
|
|
55
|
+
NodeType["TABLE"] = "TABLE";
|
|
56
|
+
NodeType["EMBED"] = "EMBED";
|
|
57
|
+
NodeType["COLLAPSIBLE_ITEM"] = "COLLAPSIBLE_ITEM";
|
|
58
|
+
NodeType["COLLAPSIBLE_ITEM_TITLE"] = "COLLAPSIBLE_ITEM_TITLE";
|
|
59
|
+
NodeType["COLLAPSIBLE_ITEM_BODY"] = "COLLAPSIBLE_ITEM_BODY";
|
|
60
|
+
NodeType["TABLE_CELL"] = "TABLE_CELL";
|
|
61
|
+
NodeType["TABLE_ROW"] = "TABLE_ROW";
|
|
62
|
+
NodeType["EXTERNAL"] = "EXTERNAL";
|
|
63
|
+
NodeType["AUDIO"] = "AUDIO";
|
|
64
|
+
NodeType["CAPTION"] = "CAPTION";
|
|
65
|
+
NodeType["LAYOUT"] = "LAYOUT";
|
|
66
|
+
NodeType["LAYOUT_CELL"] = "LAYOUT_CELL";
|
|
67
|
+
})(NodeType || (exports.NodeType = NodeType = {}));
|
|
68
|
+
var WidthType;
|
|
69
|
+
(function (WidthType) {
|
|
70
|
+
/** Width matches the content width */
|
|
71
|
+
WidthType["CONTENT"] = "CONTENT";
|
|
72
|
+
/** Small Width */
|
|
73
|
+
WidthType["SMALL"] = "SMALL";
|
|
74
|
+
/** Width will match the original asset width */
|
|
75
|
+
WidthType["ORIGINAL"] = "ORIGINAL";
|
|
76
|
+
/** coast-to-coast display */
|
|
77
|
+
WidthType["FULL_WIDTH"] = "FULL_WIDTH";
|
|
78
|
+
})(WidthType || (exports.WidthType = WidthType = {}));
|
|
79
|
+
var PluginContainerDataAlignment;
|
|
80
|
+
(function (PluginContainerDataAlignment) {
|
|
81
|
+
/** Center Alignment */
|
|
82
|
+
PluginContainerDataAlignment["CENTER"] = "CENTER";
|
|
83
|
+
/** Left Alignment */
|
|
84
|
+
PluginContainerDataAlignment["LEFT"] = "LEFT";
|
|
85
|
+
/** Right Alignment */
|
|
86
|
+
PluginContainerDataAlignment["RIGHT"] = "RIGHT";
|
|
87
|
+
})(PluginContainerDataAlignment || (exports.PluginContainerDataAlignment = PluginContainerDataAlignment = {}));
|
|
88
|
+
var Type;
|
|
89
|
+
(function (Type) {
|
|
90
|
+
/** Regular link button */
|
|
91
|
+
Type["LINK"] = "LINK";
|
|
92
|
+
/** Triggers custom action that is defined in plugin configuration by the consumer */
|
|
93
|
+
Type["ACTION"] = "ACTION";
|
|
94
|
+
})(Type || (exports.Type = Type = {}));
|
|
95
|
+
var Target;
|
|
96
|
+
(function (Target) {
|
|
97
|
+
/** Opens the linked document in the same frame as it was clicked (this is default) */
|
|
98
|
+
Target["SELF"] = "SELF";
|
|
99
|
+
/** Opens the linked document in a new window or tab */
|
|
100
|
+
Target["BLANK"] = "BLANK";
|
|
101
|
+
/** Opens the linked document in the parent frame */
|
|
102
|
+
Target["PARENT"] = "PARENT";
|
|
103
|
+
/** Opens the linked document in the full body of the window */
|
|
104
|
+
Target["TOP"] = "TOP";
|
|
105
|
+
})(Target || (exports.Target = Target = {}));
|
|
106
|
+
var TextAlignment;
|
|
107
|
+
(function (TextAlignment) {
|
|
108
|
+
/** browser default, eqivalent to `initial` */
|
|
109
|
+
TextAlignment["AUTO"] = "AUTO";
|
|
110
|
+
/** Left align */
|
|
111
|
+
TextAlignment["LEFT"] = "LEFT";
|
|
112
|
+
/** Right align */
|
|
113
|
+
TextAlignment["RIGHT"] = "RIGHT";
|
|
114
|
+
/** Center align */
|
|
115
|
+
TextAlignment["CENTER"] = "CENTER";
|
|
116
|
+
/** Text is spaced to line up its left and right edges to the left and right edges of the line box, except for the last line */
|
|
117
|
+
TextAlignment["JUSTIFY"] = "JUSTIFY";
|
|
118
|
+
})(TextAlignment || (exports.TextAlignment = TextAlignment = {}));
|
|
119
|
+
var LineStyle;
|
|
120
|
+
(function (LineStyle) {
|
|
121
|
+
/** Single Line */
|
|
122
|
+
LineStyle["SINGLE"] = "SINGLE";
|
|
123
|
+
/** Double Line */
|
|
124
|
+
LineStyle["DOUBLE"] = "DOUBLE";
|
|
125
|
+
/** Dashed Line */
|
|
126
|
+
LineStyle["DASHED"] = "DASHED";
|
|
127
|
+
/** Dotted Line */
|
|
128
|
+
LineStyle["DOTTED"] = "DOTTED";
|
|
129
|
+
})(LineStyle || (exports.LineStyle = LineStyle = {}));
|
|
130
|
+
var Width;
|
|
131
|
+
(function (Width) {
|
|
132
|
+
/** Large line */
|
|
133
|
+
Width["LARGE"] = "LARGE";
|
|
134
|
+
/** Medium line */
|
|
135
|
+
Width["MEDIUM"] = "MEDIUM";
|
|
136
|
+
/** Small line */
|
|
137
|
+
Width["SMALL"] = "SMALL";
|
|
138
|
+
})(Width || (exports.Width = Width = {}));
|
|
139
|
+
var Alignment;
|
|
140
|
+
(function (Alignment) {
|
|
141
|
+
/** Center alignment */
|
|
142
|
+
Alignment["CENTER"] = "CENTER";
|
|
143
|
+
/** Left alignment */
|
|
144
|
+
Alignment["LEFT"] = "LEFT";
|
|
145
|
+
/** Right alignment */
|
|
146
|
+
Alignment["RIGHT"] = "RIGHT";
|
|
147
|
+
})(Alignment || (exports.Alignment = Alignment = {}));
|
|
148
|
+
var ViewMode;
|
|
149
|
+
(function (ViewMode) {
|
|
150
|
+
/** No PDF view */
|
|
151
|
+
ViewMode["NONE"] = "NONE";
|
|
152
|
+
/** Full PDF view */
|
|
153
|
+
ViewMode["FULL"] = "FULL";
|
|
154
|
+
/** Mini PDF view */
|
|
155
|
+
ViewMode["MINI"] = "MINI";
|
|
156
|
+
})(ViewMode || (exports.ViewMode = ViewMode = {}));
|
|
157
|
+
var LayoutType;
|
|
158
|
+
(function (LayoutType) {
|
|
159
|
+
/** Collage type */
|
|
160
|
+
LayoutType["COLLAGE"] = "COLLAGE";
|
|
161
|
+
/** Masonry type */
|
|
162
|
+
LayoutType["MASONRY"] = "MASONRY";
|
|
163
|
+
/** Grid type */
|
|
164
|
+
LayoutType["GRID"] = "GRID";
|
|
165
|
+
/** Thumbnail type */
|
|
166
|
+
LayoutType["THUMBNAIL"] = "THUMBNAIL";
|
|
167
|
+
/** Slider type */
|
|
168
|
+
LayoutType["SLIDER"] = "SLIDER";
|
|
169
|
+
/** Slideshow type */
|
|
170
|
+
LayoutType["SLIDESHOW"] = "SLIDESHOW";
|
|
171
|
+
/** Panorama type */
|
|
172
|
+
LayoutType["PANORAMA"] = "PANORAMA";
|
|
173
|
+
/** Column type */
|
|
174
|
+
LayoutType["COLUMN"] = "COLUMN";
|
|
175
|
+
/** Magic type */
|
|
176
|
+
LayoutType["MAGIC"] = "MAGIC";
|
|
177
|
+
/** Fullsize images type */
|
|
178
|
+
LayoutType["FULLSIZE"] = "FULLSIZE";
|
|
179
|
+
})(LayoutType || (exports.LayoutType = LayoutType = {}));
|
|
180
|
+
var Orientation;
|
|
181
|
+
(function (Orientation) {
|
|
182
|
+
/** Rows Orientation */
|
|
183
|
+
Orientation["ROWS"] = "ROWS";
|
|
184
|
+
/** Columns Orientation */
|
|
185
|
+
Orientation["COLUMNS"] = "COLUMNS";
|
|
186
|
+
})(Orientation || (exports.Orientation = Orientation = {}));
|
|
187
|
+
var Crop;
|
|
188
|
+
(function (Crop) {
|
|
189
|
+
/** Crop to fill */
|
|
190
|
+
Crop["FILL"] = "FILL";
|
|
191
|
+
/** Crop to fit */
|
|
192
|
+
Crop["FIT"] = "FIT";
|
|
193
|
+
})(Crop || (exports.Crop = Crop = {}));
|
|
194
|
+
var ThumbnailsAlignment;
|
|
195
|
+
(function (ThumbnailsAlignment) {
|
|
196
|
+
/** Top alignment */
|
|
197
|
+
ThumbnailsAlignment["TOP"] = "TOP";
|
|
198
|
+
/** Right alignment */
|
|
199
|
+
ThumbnailsAlignment["RIGHT"] = "RIGHT";
|
|
200
|
+
/** Bottom alignment */
|
|
201
|
+
ThumbnailsAlignment["BOTTOM"] = "BOTTOM";
|
|
202
|
+
/** Left alignment */
|
|
203
|
+
ThumbnailsAlignment["LEFT"] = "LEFT";
|
|
204
|
+
/** No thumbnail */
|
|
205
|
+
ThumbnailsAlignment["NONE"] = "NONE";
|
|
206
|
+
})(ThumbnailsAlignment || (exports.ThumbnailsAlignment = ThumbnailsAlignment = {}));
|
|
207
|
+
var GIFType;
|
|
208
|
+
(function (GIFType) {
|
|
209
|
+
GIFType["NORMAL"] = "NORMAL";
|
|
210
|
+
GIFType["STICKER"] = "STICKER";
|
|
211
|
+
})(GIFType || (exports.GIFType = GIFType = {}));
|
|
212
|
+
var Source;
|
|
213
|
+
(function (Source) {
|
|
214
|
+
Source["HTML"] = "HTML";
|
|
215
|
+
Source["ADSENSE"] = "ADSENSE";
|
|
216
|
+
})(Source || (exports.Source = Source = {}));
|
|
217
|
+
var MapType;
|
|
218
|
+
(function (MapType) {
|
|
219
|
+
/** Roadmap map type */
|
|
220
|
+
MapType["ROADMAP"] = "ROADMAP";
|
|
221
|
+
/** Satellite map type */
|
|
222
|
+
MapType["SATELITE"] = "SATELITE";
|
|
223
|
+
/** Hybrid map type */
|
|
224
|
+
MapType["HYBRID"] = "HYBRID";
|
|
225
|
+
/** Terrain map type */
|
|
226
|
+
MapType["TERRAIN"] = "TERRAIN";
|
|
227
|
+
})(MapType || (exports.MapType = MapType = {}));
|
|
228
|
+
var ViewRole;
|
|
229
|
+
(function (ViewRole) {
|
|
230
|
+
/** Only Poll creator can view the results */
|
|
231
|
+
ViewRole["CREATOR"] = "CREATOR";
|
|
232
|
+
/** Anyone who voted can see the results */
|
|
233
|
+
ViewRole["VOTERS"] = "VOTERS";
|
|
234
|
+
/** Anyone can see the results, even if one didn't vote */
|
|
235
|
+
ViewRole["EVERYONE"] = "EVERYONE";
|
|
236
|
+
})(ViewRole || (exports.ViewRole = ViewRole = {}));
|
|
237
|
+
var VoteRole;
|
|
238
|
+
(function (VoteRole) {
|
|
239
|
+
/** Logged in member */
|
|
240
|
+
VoteRole["SITE_MEMBERS"] = "SITE_MEMBERS";
|
|
241
|
+
/** Anyone */
|
|
242
|
+
VoteRole["ALL"] = "ALL";
|
|
243
|
+
})(VoteRole || (exports.VoteRole = VoteRole = {}));
|
|
244
|
+
var PollLayoutType;
|
|
245
|
+
(function (PollLayoutType) {
|
|
246
|
+
/** List */
|
|
247
|
+
PollLayoutType["LIST"] = "LIST";
|
|
248
|
+
/** Grid */
|
|
249
|
+
PollLayoutType["GRID"] = "GRID";
|
|
250
|
+
})(PollLayoutType || (exports.PollLayoutType = PollLayoutType = {}));
|
|
251
|
+
var PollLayoutDirection;
|
|
252
|
+
(function (PollLayoutDirection) {
|
|
253
|
+
/** Left-to-right */
|
|
254
|
+
PollLayoutDirection["LTR"] = "LTR";
|
|
255
|
+
/** Right-to-left */
|
|
256
|
+
PollLayoutDirection["RTL"] = "RTL";
|
|
257
|
+
})(PollLayoutDirection || (exports.PollLayoutDirection = PollLayoutDirection = {}));
|
|
258
|
+
var BackgroundType;
|
|
259
|
+
(function (BackgroundType) {
|
|
260
|
+
/** Color background type */
|
|
261
|
+
BackgroundType["COLOR"] = "COLOR";
|
|
262
|
+
/** Image background type */
|
|
263
|
+
BackgroundType["IMAGE"] = "IMAGE";
|
|
264
|
+
/** Gradiant background type */
|
|
265
|
+
BackgroundType["GRADIENT"] = "GRADIENT";
|
|
266
|
+
})(BackgroundType || (exports.BackgroundType = BackgroundType = {}));
|
|
267
|
+
var DecorationType;
|
|
268
|
+
(function (DecorationType) {
|
|
269
|
+
DecorationType["BOLD"] = "BOLD";
|
|
270
|
+
DecorationType["ITALIC"] = "ITALIC";
|
|
271
|
+
DecorationType["UNDERLINE"] = "UNDERLINE";
|
|
272
|
+
DecorationType["SPOILER"] = "SPOILER";
|
|
273
|
+
DecorationType["ANCHOR"] = "ANCHOR";
|
|
274
|
+
DecorationType["MENTION"] = "MENTION";
|
|
275
|
+
DecorationType["LINK"] = "LINK";
|
|
276
|
+
DecorationType["COLOR"] = "COLOR";
|
|
277
|
+
DecorationType["FONT_SIZE"] = "FONT_SIZE";
|
|
278
|
+
DecorationType["EXTERNAL"] = "EXTERNAL";
|
|
279
|
+
})(DecorationType || (exports.DecorationType = DecorationType = {}));
|
|
280
|
+
var FontType;
|
|
281
|
+
(function (FontType) {
|
|
282
|
+
FontType["PX"] = "PX";
|
|
283
|
+
FontType["EM"] = "EM";
|
|
284
|
+
})(FontType || (exports.FontType = FontType = {}));
|
|
285
|
+
var AppType;
|
|
286
|
+
(function (AppType) {
|
|
287
|
+
AppType["PRODUCT"] = "PRODUCT";
|
|
288
|
+
AppType["EVENT"] = "EVENT";
|
|
289
|
+
AppType["BOOKING"] = "BOOKING";
|
|
290
|
+
})(AppType || (exports.AppType = AppType = {}));
|
|
291
|
+
var InitialExpandedItems;
|
|
292
|
+
(function (InitialExpandedItems) {
|
|
293
|
+
/** First item will be expended initally */
|
|
294
|
+
InitialExpandedItems["FIRST"] = "FIRST";
|
|
295
|
+
/** All items will expended initally */
|
|
296
|
+
InitialExpandedItems["ALL"] = "ALL";
|
|
297
|
+
/** All items collapsed initally */
|
|
298
|
+
InitialExpandedItems["NONE"] = "NONE";
|
|
299
|
+
})(InitialExpandedItems || (exports.InitialExpandedItems = InitialExpandedItems = {}));
|
|
300
|
+
var Direction;
|
|
301
|
+
(function (Direction) {
|
|
302
|
+
/** Left-to-right */
|
|
303
|
+
Direction["LTR"] = "LTR";
|
|
304
|
+
/** Right-to-left */
|
|
305
|
+
Direction["RTL"] = "RTL";
|
|
306
|
+
})(Direction || (exports.Direction = Direction = {}));
|
|
307
|
+
var VerticalAlignment;
|
|
308
|
+
(function (VerticalAlignment) {
|
|
309
|
+
/** Top alignment */
|
|
310
|
+
VerticalAlignment["TOP"] = "TOP";
|
|
311
|
+
/** Middle alignment */
|
|
312
|
+
VerticalAlignment["MIDDLE"] = "MIDDLE";
|
|
313
|
+
/** Bottom alignment */
|
|
314
|
+
VerticalAlignment["BOTTOM"] = "BOTTOM";
|
|
315
|
+
})(VerticalAlignment || (exports.VerticalAlignment = VerticalAlignment = {}));
|
|
316
|
+
/**
|
|
317
|
+
* `NullValue` is a singleton enumeration to represent the null value for the
|
|
318
|
+
* `Value` type union.
|
|
319
|
+
*
|
|
320
|
+
* The JSON representation for `NullValue` is JSON `null`.
|
|
321
|
+
*/
|
|
322
|
+
var NullValue;
|
|
323
|
+
(function (NullValue) {
|
|
324
|
+
/** Null value. */
|
|
325
|
+
NullValue["NULL_VALUE"] = "NULL_VALUE";
|
|
326
|
+
})(NullValue || (exports.NullValue = NullValue = {}));
|
|
327
|
+
var QuestionStatus;
|
|
328
|
+
(function (QuestionStatus) {
|
|
329
|
+
QuestionStatus["UNKNOWN"] = "UNKNOWN";
|
|
330
|
+
QuestionStatus["VISIBLE"] = "VISIBLE";
|
|
331
|
+
QuestionStatus["HIDDEN"] = "HIDDEN";
|
|
332
|
+
})(QuestionStatus || (exports.QuestionStatus = QuestionStatus = {}));
|
|
333
|
+
var ContentFormat;
|
|
334
|
+
(function (ContentFormat) {
|
|
335
|
+
ContentFormat["DRAFTJS"] = "DRAFTJS";
|
|
336
|
+
ContentFormat["PLAIN_TEXT"] = "PLAIN_TEXT";
|
|
337
|
+
ContentFormat["RICH_CONTENT"] = "RICH_CONTENT";
|
|
338
|
+
})(ContentFormat || (exports.ContentFormat = ContentFormat = {}));
|
|
339
|
+
var FieldSet;
|
|
340
|
+
(function (FieldSet) {
|
|
341
|
+
FieldSet["UNKNOWN"] = "UNKNOWN";
|
|
342
|
+
/** Include `share_link` fields inside question entries. */
|
|
343
|
+
FieldSet["SHARE_LINKS"] = "SHARE_LINKS";
|
|
344
|
+
})(FieldSet || (exports.FieldSet = FieldSet = {}));
|
|
345
|
+
var SortOrder;
|
|
346
|
+
(function (SortOrder) {
|
|
347
|
+
SortOrder["ASC"] = "ASC";
|
|
348
|
+
SortOrder["DESC"] = "DESC";
|
|
349
|
+
})(SortOrder || (exports.SortOrder = SortOrder = {}));
|
|
350
|
+
var QueryQuestionEntriesRequestContentFormat;
|
|
351
|
+
(function (QueryQuestionEntriesRequestContentFormat) {
|
|
352
|
+
QueryQuestionEntriesRequestContentFormat["DRAFTJS"] = "DRAFTJS";
|
|
353
|
+
QueryQuestionEntriesRequestContentFormat["PLAIN_TEXT"] = "PLAIN_TEXT";
|
|
354
|
+
QueryQuestionEntriesRequestContentFormat["RICH_CONTENT"] = "RICH_CONTENT";
|
|
355
|
+
})(QueryQuestionEntriesRequestContentFormat || (exports.QueryQuestionEntriesRequestContentFormat = QueryQuestionEntriesRequestContentFormat = {}));
|
|
356
|
+
var QueryQuestionEntriesRequestFieldSet;
|
|
357
|
+
(function (QueryQuestionEntriesRequestFieldSet) {
|
|
358
|
+
QueryQuestionEntriesRequestFieldSet["UNKNOWN"] = "UNKNOWN";
|
|
359
|
+
/** Include `share_link` fields inside question entries. */
|
|
360
|
+
QueryQuestionEntriesRequestFieldSet["SHARE_LINKS"] = "SHARE_LINKS";
|
|
361
|
+
})(QueryQuestionEntriesRequestFieldSet || (exports.QueryQuestionEntriesRequestFieldSet = QueryQuestionEntriesRequestFieldSet = {}));
|
|
362
|
+
var WebhookIdentityType;
|
|
363
|
+
(function (WebhookIdentityType) {
|
|
364
|
+
WebhookIdentityType["UNKNOWN"] = "UNKNOWN";
|
|
365
|
+
WebhookIdentityType["ANONYMOUS_VISITOR"] = "ANONYMOUS_VISITOR";
|
|
366
|
+
WebhookIdentityType["MEMBER"] = "MEMBER";
|
|
367
|
+
WebhookIdentityType["WIX_USER"] = "WIX_USER";
|
|
368
|
+
WebhookIdentityType["APP"] = "APP";
|
|
369
|
+
})(WebhookIdentityType || (exports.WebhookIdentityType = WebhookIdentityType = {}));
|
|
370
|
+
/**
|
|
371
|
+
* Creates a new QuestionEntry.
|
|
372
|
+
* @param questionEntry - QuestionEntry to be created.
|
|
373
|
+
* @public
|
|
374
|
+
* @requiredField questionEntry
|
|
375
|
+
* @requiredField questionEntry.question
|
|
376
|
+
* @permissionId FAQ.CREATE_QUESTION
|
|
377
|
+
* @permissionScope Manage FAQ
|
|
378
|
+
* @permissionScopeId SCOPE.DC-LABS.MANAGE-FAQ
|
|
379
|
+
* @applicableIdentity APP
|
|
380
|
+
* @returns The created QuestionEntry.
|
|
381
|
+
* @fqn wix.faq.questionentry.v2.QuestionEntryService.CreateQuestionEntry
|
|
382
|
+
*/
|
|
383
|
+
async function createQuestionEntry(questionEntry) {
|
|
384
|
+
// @ts-ignore
|
|
385
|
+
const { httpClient, sideEffects } = arguments[1];
|
|
386
|
+
const payload = (0, rename_all_nested_keys_1.renameKeysFromSDKRequestToRESTRequest)({
|
|
387
|
+
questionEntry: questionEntry,
|
|
388
|
+
});
|
|
389
|
+
const reqOpts = ambassadorWixFaqQuestionEntryV2QuestionEntry.createQuestionEntry(payload);
|
|
390
|
+
sideEffects?.onSiteCall?.();
|
|
391
|
+
try {
|
|
392
|
+
const result = await httpClient.request(reqOpts);
|
|
393
|
+
sideEffects?.onSuccess?.(result);
|
|
394
|
+
return (0, rename_all_nested_keys_1.renameKeysFromRESTResponseToSDKResponse)(result.data)?.questionEntry;
|
|
395
|
+
}
|
|
396
|
+
catch (err) {
|
|
397
|
+
const transformedError = (0, transform_error_1.transformError)(err, {
|
|
398
|
+
spreadPathsToArguments: {},
|
|
399
|
+
explicitPathsToArguments: { questionEntry: '$[0]' },
|
|
400
|
+
singleArgumentUnchanged: false,
|
|
401
|
+
}, ['questionEntry']);
|
|
402
|
+
sideEffects?.onError?.(err);
|
|
403
|
+
throw transformedError;
|
|
404
|
+
}
|
|
405
|
+
}
|
|
406
|
+
exports.createQuestionEntry = createQuestionEntry;
|
|
407
|
+
/**
|
|
408
|
+
* Retrieves a single QuestionEntry by id.
|
|
409
|
+
* @param questionEntryId - ID of the QuestionEntry to retrieve.
|
|
410
|
+
* @public
|
|
411
|
+
* @requiredField questionEntryId
|
|
412
|
+
* @permissionId FAQ.READ_QUESTIONS
|
|
413
|
+
* @permissionScope Manage FAQ
|
|
414
|
+
* @permissionScopeId SCOPE.DC-LABS.MANAGE-FAQ
|
|
415
|
+
* @permissionScope Read FAQ
|
|
416
|
+
* @permissionScopeId SCOPE.DC-LABS.READ-FAQ
|
|
417
|
+
* @applicableIdentity APP
|
|
418
|
+
* @applicableIdentity VISITOR
|
|
419
|
+
* @returns The requested QuestionEntry.
|
|
420
|
+
* @fqn wix.faq.questionentry.v2.QuestionEntryService.GetQuestionEntry
|
|
421
|
+
*/
|
|
422
|
+
async function getQuestionEntry(questionEntryId) {
|
|
423
|
+
// @ts-ignore
|
|
424
|
+
const { httpClient, sideEffects } = arguments[1];
|
|
425
|
+
const payload = (0, rename_all_nested_keys_1.renameKeysFromSDKRequestToRESTRequest)({
|
|
426
|
+
questionEntryId: questionEntryId,
|
|
427
|
+
});
|
|
428
|
+
const reqOpts = ambassadorWixFaqQuestionEntryV2QuestionEntry.getQuestionEntry(payload);
|
|
429
|
+
sideEffects?.onSiteCall?.();
|
|
430
|
+
try {
|
|
431
|
+
const result = await httpClient.request(reqOpts);
|
|
432
|
+
sideEffects?.onSuccess?.(result);
|
|
433
|
+
return (0, rename_all_nested_keys_1.renameKeysFromRESTResponseToSDKResponse)(result.data)?.questionEntry;
|
|
434
|
+
}
|
|
435
|
+
catch (err) {
|
|
436
|
+
const transformedError = (0, transform_error_1.transformError)(err, {
|
|
437
|
+
spreadPathsToArguments: {},
|
|
438
|
+
explicitPathsToArguments: { questionEntryId: '$[0]' },
|
|
439
|
+
singleArgumentUnchanged: false,
|
|
440
|
+
}, ['questionEntryId']);
|
|
441
|
+
sideEffects?.onError?.(err);
|
|
442
|
+
throw transformedError;
|
|
443
|
+
}
|
|
444
|
+
}
|
|
445
|
+
exports.getQuestionEntry = getQuestionEntry;
|
|
446
|
+
/**
|
|
447
|
+
* Updates a QuestionEntry, replaces the previous version.
|
|
448
|
+
*
|
|
449
|
+
* Each time the QuestionEntry is updated `revision` increments by 1.
|
|
450
|
+
* The current `revision` must be passed when updating the QuestionEntry.
|
|
451
|
+
* This ensures you're working with the latest QuestionEntry and prevents unintended overwrites.
|
|
452
|
+
* @param _id - QuestionEntry ID.
|
|
453
|
+
* @public
|
|
454
|
+
* @requiredField _id
|
|
455
|
+
* @requiredField questionEntry
|
|
456
|
+
* @requiredField questionEntry.revision
|
|
457
|
+
* @permissionId FAQ.UPDATE_QUESTION
|
|
458
|
+
* @permissionScope Manage FAQ
|
|
459
|
+
* @permissionScopeId SCOPE.DC-LABS.MANAGE-FAQ
|
|
460
|
+
* @applicableIdentity APP
|
|
461
|
+
* @returns Updated QuestionEntry.
|
|
462
|
+
* @fqn wix.faq.questionentry.v2.QuestionEntryService.UpdateQuestionEntry
|
|
463
|
+
*/
|
|
464
|
+
async function updateQuestionEntry(_id, questionEntry) {
|
|
465
|
+
// @ts-ignore
|
|
466
|
+
const { httpClient, sideEffects } = arguments[2];
|
|
467
|
+
const payload = (0, rename_all_nested_keys_1.renameKeysFromSDKRequestToRESTRequest)({
|
|
468
|
+
questionEntry: { ...questionEntry, id: _id },
|
|
469
|
+
});
|
|
470
|
+
const reqOpts = ambassadorWixFaqQuestionEntryV2QuestionEntry.updateQuestionEntry(payload);
|
|
471
|
+
sideEffects?.onSiteCall?.();
|
|
472
|
+
try {
|
|
473
|
+
const result = await httpClient.request(reqOpts);
|
|
474
|
+
sideEffects?.onSuccess?.(result);
|
|
475
|
+
return (0, rename_all_nested_keys_1.renameKeysFromRESTResponseToSDKResponse)(result.data)?.questionEntry;
|
|
476
|
+
}
|
|
477
|
+
catch (err) {
|
|
478
|
+
const transformedError = (0, transform_error_1.transformError)(err, {
|
|
479
|
+
spreadPathsToArguments: { questionEntry: '$[1]' },
|
|
480
|
+
explicitPathsToArguments: { 'questionEntry.id': '$[0]' },
|
|
481
|
+
singleArgumentUnchanged: false,
|
|
482
|
+
}, ['_id', 'questionEntry']);
|
|
483
|
+
sideEffects?.onError?.(err);
|
|
484
|
+
throw transformedError;
|
|
485
|
+
}
|
|
486
|
+
}
|
|
487
|
+
exports.updateQuestionEntry = updateQuestionEntry;
|
|
488
|
+
/**
|
|
489
|
+
* Deletes a QuestionEntry.
|
|
490
|
+
* Deleting a QuestionEntry permanently removes them from the QuestionEntry List.
|
|
491
|
+
* @param questionEntryId - Id of the QuestionEntry to delete.
|
|
492
|
+
* @public
|
|
493
|
+
* @requiredField questionEntryId
|
|
494
|
+
* @permissionId FAQ.DELETE_QUESTION
|
|
495
|
+
* @permissionScope Manage FAQ
|
|
496
|
+
* @permissionScopeId SCOPE.DC-LABS.MANAGE-FAQ
|
|
497
|
+
* @applicableIdentity APP
|
|
498
|
+
* @fqn wix.faq.questionentry.v2.QuestionEntryService.DeleteQuestionEntry
|
|
499
|
+
*/
|
|
500
|
+
async function deleteQuestionEntry(questionEntryId) {
|
|
501
|
+
// @ts-ignore
|
|
502
|
+
const { httpClient, sideEffects } = arguments[1];
|
|
503
|
+
const payload = (0, rename_all_nested_keys_1.renameKeysFromSDKRequestToRESTRequest)({
|
|
504
|
+
questionEntryId: questionEntryId,
|
|
505
|
+
});
|
|
506
|
+
const reqOpts = ambassadorWixFaqQuestionEntryV2QuestionEntry.deleteQuestionEntry(payload);
|
|
507
|
+
sideEffects?.onSiteCall?.();
|
|
508
|
+
try {
|
|
509
|
+
const result = await httpClient.request(reqOpts);
|
|
510
|
+
sideEffects?.onSuccess?.(result);
|
|
511
|
+
}
|
|
512
|
+
catch (err) {
|
|
513
|
+
const transformedError = (0, transform_error_1.transformError)(err, {
|
|
514
|
+
spreadPathsToArguments: {},
|
|
515
|
+
explicitPathsToArguments: { questionEntryId: '$[0]' },
|
|
516
|
+
singleArgumentUnchanged: false,
|
|
517
|
+
}, ['questionEntryId']);
|
|
518
|
+
sideEffects?.onError?.(err);
|
|
519
|
+
throw transformedError;
|
|
520
|
+
}
|
|
521
|
+
}
|
|
522
|
+
exports.deleteQuestionEntry = deleteQuestionEntry;
|
|
523
|
+
/**
|
|
524
|
+
* Retrieves up to 100 question entries, given the provided filtering, paging, and sorting.
|
|
525
|
+
* Use the `fieldSet` parameter to set whether sharing links are included in the response.
|
|
526
|
+
* @public
|
|
527
|
+
* @permissionId FAQ.READ_QUESTIONS
|
|
528
|
+
* @permissionScope Manage FAQ
|
|
529
|
+
* @permissionScopeId SCOPE.DC-LABS.MANAGE-FAQ
|
|
530
|
+
* @permissionScope Read FAQ
|
|
531
|
+
* @permissionScopeId SCOPE.DC-LABS.READ-FAQ
|
|
532
|
+
* @applicableIdentity APP
|
|
533
|
+
* @applicableIdentity VISITOR
|
|
534
|
+
* @fqn wix.faq.questionentry.v2.QuestionEntryService.ListQuestionEntries
|
|
535
|
+
*/
|
|
536
|
+
async function listQuestionEntries(options) {
|
|
537
|
+
// @ts-ignore
|
|
538
|
+
const { httpClient, sideEffects } = arguments[1];
|
|
539
|
+
const payload = (0, rename_all_nested_keys_1.renameKeysFromSDKRequestToRESTRequest)({
|
|
540
|
+
categoryId: options?.categoryId,
|
|
541
|
+
questionEntryIds: options?.questionEntryIds,
|
|
542
|
+
questionEntryLabel: options?.questionEntryLabel,
|
|
543
|
+
paging: options?.paging,
|
|
544
|
+
contentFormat: options?.contentFormat,
|
|
545
|
+
fieldSet: options?.fieldSet,
|
|
546
|
+
});
|
|
547
|
+
const reqOpts = ambassadorWixFaqQuestionEntryV2QuestionEntry.listQuestionEntries(payload);
|
|
548
|
+
sideEffects?.onSiteCall?.();
|
|
549
|
+
try {
|
|
550
|
+
const result = await httpClient.request(reqOpts);
|
|
551
|
+
sideEffects?.onSuccess?.(result);
|
|
552
|
+
return (0, rename_all_nested_keys_1.renameKeysFromRESTResponseToSDKResponse)(result.data);
|
|
553
|
+
}
|
|
554
|
+
catch (err) {
|
|
555
|
+
const transformedError = (0, transform_error_1.transformError)(err, {
|
|
556
|
+
spreadPathsToArguments: {},
|
|
557
|
+
explicitPathsToArguments: {
|
|
558
|
+
categoryId: '$[0].categoryId',
|
|
559
|
+
questionEntryIds: '$[0].questionEntryIds',
|
|
560
|
+
questionEntryLabel: '$[0].questionEntryLabel',
|
|
561
|
+
paging: '$[0].paging',
|
|
562
|
+
contentFormat: '$[0].contentFormat',
|
|
563
|
+
fieldSet: '$[0].fieldSet',
|
|
564
|
+
},
|
|
565
|
+
singleArgumentUnchanged: false,
|
|
566
|
+
}, ['options']);
|
|
567
|
+
sideEffects?.onError?.(err);
|
|
568
|
+
throw transformedError;
|
|
569
|
+
}
|
|
570
|
+
}
|
|
571
|
+
exports.listQuestionEntries = listQuestionEntries;
|
|
572
|
+
/**
|
|
573
|
+
* Retrieves a list of QuestionEntries, given the provided [paging, filtering, and sorting].
|
|
574
|
+
* @public
|
|
575
|
+
* @permissionScope Manage FAQ
|
|
576
|
+
* @permissionScopeId SCOPE.DC-LABS.MANAGE-FAQ
|
|
577
|
+
* @permissionScope Read FAQ
|
|
578
|
+
* @permissionScopeId SCOPE.DC-LABS.READ-FAQ
|
|
579
|
+
* @permissionId FAQ.READ_QUESTIONS
|
|
580
|
+
* @applicableIdentity APP
|
|
581
|
+
* @applicableIdentity VISITOR
|
|
582
|
+
* @fqn wix.faq.questionentry.v2.QuestionEntryService.QueryQuestionEntries
|
|
583
|
+
*/
|
|
584
|
+
function queryQuestionEntries(options) {
|
|
585
|
+
// @ts-ignore
|
|
586
|
+
const { httpClient, sideEffects } = arguments[1];
|
|
587
|
+
return (0, query_builder_1.queryBuilder)({
|
|
588
|
+
func: async (payload) => {
|
|
589
|
+
const reqOpts = ambassadorWixFaqQuestionEntryV2QuestionEntry.queryQuestionEntries({
|
|
590
|
+
...payload,
|
|
591
|
+
...(options ?? {}),
|
|
592
|
+
});
|
|
593
|
+
sideEffects?.onSiteCall?.();
|
|
594
|
+
try {
|
|
595
|
+
const result = await httpClient.request(reqOpts);
|
|
596
|
+
sideEffects?.onSuccess?.(result);
|
|
597
|
+
return result;
|
|
598
|
+
}
|
|
599
|
+
catch (err) {
|
|
600
|
+
sideEffects?.onError?.(err);
|
|
601
|
+
throw err;
|
|
602
|
+
}
|
|
603
|
+
},
|
|
604
|
+
requestTransformer: (query) => {
|
|
605
|
+
const args = [query, options];
|
|
606
|
+
return (0, rename_all_nested_keys_1.renameKeysFromSDKRequestToRESTRequest)({
|
|
607
|
+
...args?.[1],
|
|
608
|
+
query: args?.[0],
|
|
609
|
+
});
|
|
610
|
+
},
|
|
611
|
+
responseTransformer: ({ data, }) => {
|
|
612
|
+
const transformedData = (0, rename_all_nested_keys_1.renameKeysFromRESTResponseToSDKResponse)(data);
|
|
613
|
+
return {
|
|
614
|
+
items: transformedData?.questionEntries,
|
|
615
|
+
pagingMetadata: transformedData?.pagingMetadata,
|
|
616
|
+
};
|
|
617
|
+
},
|
|
618
|
+
errorTransformer: (err) => {
|
|
619
|
+
const transformedError = (0, transform_error_1.transformError)(err, {
|
|
620
|
+
spreadPathsToArguments: {},
|
|
621
|
+
explicitPathsToArguments: { query: '$[0]' },
|
|
622
|
+
singleArgumentUnchanged: false,
|
|
623
|
+
});
|
|
624
|
+
throw transformedError;
|
|
625
|
+
},
|
|
626
|
+
pagingMethod: 'CURSOR',
|
|
627
|
+
transformationPaths: {},
|
|
628
|
+
});
|
|
629
|
+
}
|
|
630
|
+
exports.queryQuestionEntries = queryQuestionEntries;
|
|
631
|
+
/**
|
|
632
|
+
* Deletes multiple QuestionEntries in a single request. Works synchronously.
|
|
633
|
+
* @param questionEntryIds - QuestionEntry ids to be deleted.
|
|
634
|
+
* @public
|
|
635
|
+
* @requiredField questionEntryIds
|
|
636
|
+
* @permissionId FAQ.DELETE_QUESTION
|
|
637
|
+
* @permissionScope Manage FAQ
|
|
638
|
+
* @permissionScopeId SCOPE.DC-LABS.MANAGE-FAQ
|
|
639
|
+
* @applicableIdentity APP
|
|
640
|
+
* @fqn wix.faq.questionentry.v2.QuestionEntryService.BulkDeleteQuestionEntry
|
|
641
|
+
*/
|
|
642
|
+
async function bulkDeleteQuestionEntry(questionEntryIds) {
|
|
643
|
+
// @ts-ignore
|
|
644
|
+
const { httpClient, sideEffects } = arguments[1];
|
|
645
|
+
const payload = (0, rename_all_nested_keys_1.renameKeysFromSDKRequestToRESTRequest)({
|
|
646
|
+
questionEntryIds: questionEntryIds,
|
|
647
|
+
});
|
|
648
|
+
const reqOpts = ambassadorWixFaqQuestionEntryV2QuestionEntry.bulkDeleteQuestionEntry(payload);
|
|
649
|
+
sideEffects?.onSiteCall?.();
|
|
650
|
+
try {
|
|
651
|
+
const result = await httpClient.request(reqOpts);
|
|
652
|
+
sideEffects?.onSuccess?.(result);
|
|
653
|
+
return (0, rename_all_nested_keys_1.renameKeysFromRESTResponseToSDKResponse)(result.data);
|
|
654
|
+
}
|
|
655
|
+
catch (err) {
|
|
656
|
+
const transformedError = (0, transform_error_1.transformError)(err, {
|
|
657
|
+
spreadPathsToArguments: {},
|
|
658
|
+
explicitPathsToArguments: { questionEntryIds: '$[0]' },
|
|
659
|
+
singleArgumentUnchanged: false,
|
|
660
|
+
}, ['questionEntryIds']);
|
|
661
|
+
sideEffects?.onError?.(err);
|
|
662
|
+
throw transformedError;
|
|
663
|
+
}
|
|
664
|
+
}
|
|
665
|
+
exports.bulkDeleteQuestionEntry = bulkDeleteQuestionEntry;
|
|
666
|
+
/**
|
|
667
|
+
* Updates extended fields of a QuestionEntry without incrementing revision
|
|
668
|
+
* @param _id - ID of the entity to update.
|
|
669
|
+
* @param namespace - Identifier for the app whose extended fields are being updated.
|
|
670
|
+
* @public
|
|
671
|
+
* @requiredField _id
|
|
672
|
+
* @requiredField namespace
|
|
673
|
+
* @requiredField options
|
|
674
|
+
* @requiredField options.namespaceData
|
|
675
|
+
* @permissionId FAQ.UPDATE_QUESTION
|
|
676
|
+
* @permissionScope Manage FAQ
|
|
677
|
+
* @permissionScopeId SCOPE.DC-LABS.MANAGE-FAQ
|
|
678
|
+
* @applicableIdentity APP
|
|
679
|
+
* @fqn wix.faq.questionentry.v2.QuestionEntryService.UpdateExtendedFields
|
|
680
|
+
*/
|
|
681
|
+
async function updateExtendedFields(_id, namespace, options) {
|
|
682
|
+
// @ts-ignore
|
|
683
|
+
const { httpClient, sideEffects } = arguments[3];
|
|
684
|
+
const payload = (0, rename_all_nested_keys_1.renameKeysFromSDKRequestToRESTRequest)({
|
|
685
|
+
id: _id,
|
|
686
|
+
namespace: namespace,
|
|
687
|
+
namespaceData: options?.namespaceData,
|
|
688
|
+
});
|
|
689
|
+
const reqOpts = ambassadorWixFaqQuestionEntryV2QuestionEntry.updateExtendedFields(payload);
|
|
690
|
+
sideEffects?.onSiteCall?.();
|
|
691
|
+
try {
|
|
692
|
+
const result = await httpClient.request(reqOpts);
|
|
693
|
+
sideEffects?.onSuccess?.(result);
|
|
694
|
+
return (0, rename_all_nested_keys_1.renameKeysFromRESTResponseToSDKResponse)(result.data);
|
|
695
|
+
}
|
|
696
|
+
catch (err) {
|
|
697
|
+
const transformedError = (0, transform_error_1.transformError)(err, {
|
|
698
|
+
spreadPathsToArguments: {},
|
|
699
|
+
explicitPathsToArguments: {
|
|
700
|
+
id: '$[0]',
|
|
701
|
+
namespace: '$[1]',
|
|
702
|
+
namespaceData: '$[2].namespaceData',
|
|
703
|
+
},
|
|
704
|
+
singleArgumentUnchanged: false,
|
|
705
|
+
}, ['_id', 'namespace', 'options']);
|
|
706
|
+
sideEffects?.onError?.(err);
|
|
707
|
+
throw transformedError;
|
|
708
|
+
}
|
|
709
|
+
}
|
|
710
|
+
exports.updateExtendedFields = updateExtendedFields;
|
|
711
|
+
/**
|
|
712
|
+
* Adds or updates a question entry's labels. Replaces existing labels.
|
|
713
|
+
* Note: If 'labels' field is empty in the request, it will clear all existing labels for the question entry.
|
|
714
|
+
* @param questionEntryId - ID of question entry to add labels to.
|
|
715
|
+
* @public
|
|
716
|
+
* @requiredField questionEntryId
|
|
717
|
+
* @permissionId FAQ.SET_QUESTION_LABEL
|
|
718
|
+
* @permissionScope Manage FAQ
|
|
719
|
+
* @permissionScopeId SCOPE.DC-LABS.MANAGE-FAQ
|
|
720
|
+
* @applicableIdentity APP
|
|
721
|
+
* @fqn wix.faq.questionentry.v2.QuestionEntryService.SetQuestionEntryLabels
|
|
722
|
+
*/
|
|
723
|
+
async function setQuestionEntryLabels(questionEntryId, options) {
|
|
724
|
+
// @ts-ignore
|
|
725
|
+
const { httpClient, sideEffects } = arguments[2];
|
|
726
|
+
const payload = (0, rename_all_nested_keys_1.renameKeysFromSDKRequestToRESTRequest)({
|
|
727
|
+
questionEntryId: questionEntryId,
|
|
728
|
+
labels: options?.labels,
|
|
729
|
+
});
|
|
730
|
+
const reqOpts = ambassadorWixFaqQuestionEntryV2QuestionEntry.setQuestionEntryLabels(payload);
|
|
731
|
+
sideEffects?.onSiteCall?.();
|
|
732
|
+
try {
|
|
733
|
+
const result = await httpClient.request(reqOpts);
|
|
734
|
+
sideEffects?.onSuccess?.(result);
|
|
735
|
+
return (0, rename_all_nested_keys_1.renameKeysFromRESTResponseToSDKResponse)(result.data);
|
|
736
|
+
}
|
|
737
|
+
catch (err) {
|
|
738
|
+
const transformedError = (0, transform_error_1.transformError)(err, {
|
|
739
|
+
spreadPathsToArguments: {},
|
|
740
|
+
explicitPathsToArguments: {
|
|
741
|
+
questionEntryId: '$[0]',
|
|
742
|
+
labels: '$[1].labels',
|
|
743
|
+
},
|
|
744
|
+
singleArgumentUnchanged: false,
|
|
745
|
+
}, ['questionEntryId', 'options']);
|
|
746
|
+
sideEffects?.onError?.(err);
|
|
747
|
+
throw transformedError;
|
|
748
|
+
}
|
|
749
|
+
}
|
|
750
|
+
exports.setQuestionEntryLabels = setQuestionEntryLabels;
|
|
751
|
+
/**
|
|
752
|
+
* Updates multiple question entries'.
|
|
753
|
+
* This method replace the following bulk methods from the previous service:
|
|
754
|
+
* 1. updateQuestionsVisibility - Updates multiple question entries' visibility within their categories
|
|
755
|
+
* 2. bulkSetQuestionStatus - Updates multiple question entries' statuses.
|
|
756
|
+
* 3. bulkUpdateLabelOrder - Updates a question entry's labels order.
|
|
757
|
+
* @public
|
|
758
|
+
* @requiredField options.questionEntries.questionEntry
|
|
759
|
+
* @requiredField options.questionEntries.questionEntry._id
|
|
760
|
+
* @requiredField options.questionEntries.questionEntry.revision
|
|
761
|
+
* @permissionId FAQ.UPDATE_QUESTION
|
|
762
|
+
* @permissionScope Manage FAQ
|
|
763
|
+
* @permissionScopeId SCOPE.DC-LABS.MANAGE-FAQ
|
|
764
|
+
* @applicableIdentity APP
|
|
765
|
+
* @fqn wix.faq.questionentry.v2.QuestionEntryService.BulkUpdateQuestionEntry
|
|
766
|
+
*/
|
|
767
|
+
async function bulkUpdateQuestionEntry(options) {
|
|
768
|
+
// @ts-ignore
|
|
769
|
+
const { httpClient, sideEffects } = arguments[1];
|
|
770
|
+
const payload = (0, rename_all_nested_keys_1.renameKeysFromSDKRequestToRESTRequest)({
|
|
771
|
+
questionEntries: options?.questionEntries,
|
|
772
|
+
returnFullEntity: options?.returnFullEntity,
|
|
773
|
+
});
|
|
774
|
+
const reqOpts = ambassadorWixFaqQuestionEntryV2QuestionEntry.bulkUpdateQuestionEntry(payload);
|
|
775
|
+
sideEffects?.onSiteCall?.();
|
|
776
|
+
try {
|
|
777
|
+
const result = await httpClient.request(reqOpts);
|
|
778
|
+
sideEffects?.onSuccess?.(result);
|
|
779
|
+
return (0, rename_all_nested_keys_1.renameKeysFromRESTResponseToSDKResponse)(result.data);
|
|
780
|
+
}
|
|
781
|
+
catch (err) {
|
|
782
|
+
const transformedError = (0, transform_error_1.transformError)(err, {
|
|
783
|
+
spreadPathsToArguments: {},
|
|
784
|
+
explicitPathsToArguments: {
|
|
785
|
+
questionEntries: '$[0].questionEntries',
|
|
786
|
+
returnFullEntity: '$[0].returnFullEntity',
|
|
787
|
+
},
|
|
788
|
+
singleArgumentUnchanged: false,
|
|
789
|
+
}, ['options']);
|
|
790
|
+
sideEffects?.onError?.(err);
|
|
791
|
+
throw transformedError;
|
|
792
|
+
}
|
|
793
|
+
}
|
|
794
|
+
exports.bulkUpdateQuestionEntry = bulkUpdateQuestionEntry;
|
|
795
|
+
//# sourceMappingURL=faq-question-entry-v2-question-entry-question-entry.universal.js.map
|