@wix/auto_sdk_forms_submissions 1.0.27 → 1.0.28
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/{internal/cjs/src/forms-v4-submission-submissions.universal.d.ts → cjs/forms-v4-submission-submissions.universal-Q3Bs_Jbt.d.ts} +1534 -1205
- package/build/cjs/index.d.ts +327 -1
- package/build/cjs/index.js +2974 -15
- package/build/cjs/index.js.map +1 -1
- package/build/cjs/index.typings.d.ts +28 -1
- package/build/cjs/index.typings.js +2605 -15
- package/build/cjs/index.typings.js.map +1 -1
- package/build/cjs/meta.d.ts +1043 -1
- package/build/cjs/meta.js +1277 -15
- package/build/cjs/meta.js.map +1 -1
- package/build/{internal/es/src/forms-v4-submission-submissions.universal.d.ts → es/forms-v4-submission-submissions.universal-Q3Bs_Jbt.d.mts} +1534 -1205
- package/build/es/index.d.mts +327 -0
- package/build/es/index.mjs +2815 -0
- package/build/es/index.mjs.map +1 -0
- package/build/es/index.typings.d.mts +28 -0
- package/build/es/index.typings.mjs +2453 -0
- package/build/es/index.typings.mjs.map +1 -0
- package/build/es/meta.d.mts +1043 -0
- package/build/es/meta.mjs +1228 -0
- package/build/es/meta.mjs.map +1 -0
- package/build/{cjs/src/forms-v4-submission-submissions.universal.d.ts → internal/cjs/forms-v4-submission-submissions.universal-ILKHqisa.d.ts} +1561 -1170
- package/build/internal/cjs/index.d.ts +349 -1
- package/build/internal/cjs/index.js +2974 -15
- package/build/internal/cjs/index.js.map +1 -1
- package/build/internal/cjs/index.typings.d.ts +28 -1
- package/build/internal/cjs/index.typings.js +2605 -15
- package/build/internal/cjs/index.typings.js.map +1 -1
- package/build/internal/cjs/meta.d.ts +1043 -1
- package/build/internal/cjs/meta.js +1277 -15
- package/build/internal/cjs/meta.js.map +1 -1
- package/build/{es/src/forms-v4-submission-submissions.universal.d.ts → internal/es/forms-v4-submission-submissions.universal-ILKHqisa.d.mts} +1561 -1170
- package/build/internal/es/index.d.mts +349 -0
- package/build/internal/es/index.mjs +2815 -0
- package/build/internal/es/index.mjs.map +1 -0
- package/build/internal/es/index.typings.d.mts +28 -0
- package/build/internal/es/index.typings.mjs +2453 -0
- package/build/internal/es/index.typings.mjs.map +1 -0
- package/build/internal/es/meta.d.mts +1043 -0
- package/build/internal/es/meta.mjs +1228 -0
- package/build/internal/es/meta.mjs.map +1 -0
- package/package.json +12 -10
- package/build/cjs/src/forms-v4-submission-submissions.context.d.ts +0 -65
- package/build/cjs/src/forms-v4-submission-submissions.context.js +0 -170
- package/build/cjs/src/forms-v4-submission-submissions.context.js.map +0 -1
- package/build/cjs/src/forms-v4-submission-submissions.http.d.ts +0 -126
- package/build/cjs/src/forms-v4-submission-submissions.http.js +0 -849
- package/build/cjs/src/forms-v4-submission-submissions.http.js.map +0 -1
- package/build/cjs/src/forms-v4-submission-submissions.meta.d.ts +0 -58
- package/build/cjs/src/forms-v4-submission-submissions.meta.js +0 -522
- package/build/cjs/src/forms-v4-submission-submissions.meta.js.map +0 -1
- package/build/cjs/src/forms-v4-submission-submissions.public.d.ts +0 -268
- package/build/cjs/src/forms-v4-submission-submissions.public.js +0 -332
- package/build/cjs/src/forms-v4-submission-submissions.public.js.map +0 -1
- package/build/cjs/src/forms-v4-submission-submissions.types.d.ts +0 -6288
- package/build/cjs/src/forms-v4-submission-submissions.types.js +0 -961
- package/build/cjs/src/forms-v4-submission-submissions.types.js.map +0 -1
- package/build/cjs/src/forms-v4-submission-submissions.universal.js +0 -2217
- package/build/cjs/src/forms-v4-submission-submissions.universal.js.map +0 -1
- package/build/es/index.d.ts +0 -1
- package/build/es/index.js +0 -2
- package/build/es/index.js.map +0 -1
- package/build/es/index.typings.d.ts +0 -1
- package/build/es/index.typings.js +0 -2
- package/build/es/index.typings.js.map +0 -1
- package/build/es/meta.d.ts +0 -1
- package/build/es/meta.js +0 -2
- package/build/es/meta.js.map +0 -1
- package/build/es/src/forms-v4-submission-submissions.context.d.ts +0 -65
- package/build/es/src/forms-v4-submission-submissions.context.js +0 -69
- package/build/es/src/forms-v4-submission-submissions.context.js.map +0 -1
- package/build/es/src/forms-v4-submission-submissions.http.d.ts +0 -126
- package/build/es/src/forms-v4-submission-submissions.http.js +0 -820
- package/build/es/src/forms-v4-submission-submissions.http.js.map +0 -1
- package/build/es/src/forms-v4-submission-submissions.meta.d.ts +0 -58
- package/build/es/src/forms-v4-submission-submissions.meta.js +0 -470
- package/build/es/src/forms-v4-submission-submissions.meta.js.map +0 -1
- package/build/es/src/forms-v4-submission-submissions.public.d.ts +0 -268
- package/build/es/src/forms-v4-submission-submissions.public.js +0 -205
- package/build/es/src/forms-v4-submission-submissions.public.js.map +0 -1
- package/build/es/src/forms-v4-submission-submissions.types.d.ts +0 -6288
- package/build/es/src/forms-v4-submission-submissions.types.js +0 -957
- package/build/es/src/forms-v4-submission-submissions.types.js.map +0 -1
- package/build/es/src/forms-v4-submission-submissions.universal.js +0 -2163
- package/build/es/src/forms-v4-submission-submissions.universal.js.map +0 -1
- package/build/internal/cjs/src/forms-v4-submission-submissions.context.d.ts +0 -69
- package/build/internal/cjs/src/forms-v4-submission-submissions.context.js +0 -170
- package/build/internal/cjs/src/forms-v4-submission-submissions.context.js.map +0 -1
- package/build/internal/cjs/src/forms-v4-submission-submissions.http.d.ts +0 -126
- package/build/internal/cjs/src/forms-v4-submission-submissions.http.js +0 -849
- package/build/internal/cjs/src/forms-v4-submission-submissions.http.js.map +0 -1
- package/build/internal/cjs/src/forms-v4-submission-submissions.meta.d.ts +0 -58
- package/build/internal/cjs/src/forms-v4-submission-submissions.meta.js +0 -522
- package/build/internal/cjs/src/forms-v4-submission-submissions.meta.js.map +0 -1
- package/build/internal/cjs/src/forms-v4-submission-submissions.public.d.ts +0 -286
- package/build/internal/cjs/src/forms-v4-submission-submissions.public.js +0 -332
- package/build/internal/cjs/src/forms-v4-submission-submissions.public.js.map +0 -1
- package/build/internal/cjs/src/forms-v4-submission-submissions.types.d.ts +0 -6288
- package/build/internal/cjs/src/forms-v4-submission-submissions.types.js +0 -961
- package/build/internal/cjs/src/forms-v4-submission-submissions.types.js.map +0 -1
- package/build/internal/cjs/src/forms-v4-submission-submissions.universal.js +0 -2217
- package/build/internal/cjs/src/forms-v4-submission-submissions.universal.js.map +0 -1
- package/build/internal/es/index.d.ts +0 -1
- package/build/internal/es/index.js +0 -2
- package/build/internal/es/index.js.map +0 -1
- package/build/internal/es/index.typings.d.ts +0 -1
- package/build/internal/es/index.typings.js +0 -2
- package/build/internal/es/index.typings.js.map +0 -1
- package/build/internal/es/meta.d.ts +0 -1
- package/build/internal/es/meta.js +0 -2
- package/build/internal/es/meta.js.map +0 -1
- package/build/internal/es/src/forms-v4-submission-submissions.context.d.ts +0 -69
- package/build/internal/es/src/forms-v4-submission-submissions.context.js +0 -69
- package/build/internal/es/src/forms-v4-submission-submissions.context.js.map +0 -1
- package/build/internal/es/src/forms-v4-submission-submissions.http.d.ts +0 -126
- package/build/internal/es/src/forms-v4-submission-submissions.http.js +0 -820
- package/build/internal/es/src/forms-v4-submission-submissions.http.js.map +0 -1
- package/build/internal/es/src/forms-v4-submission-submissions.meta.d.ts +0 -58
- package/build/internal/es/src/forms-v4-submission-submissions.meta.js +0 -470
- package/build/internal/es/src/forms-v4-submission-submissions.meta.js.map +0 -1
- package/build/internal/es/src/forms-v4-submission-submissions.public.d.ts +0 -286
- package/build/internal/es/src/forms-v4-submission-submissions.public.js +0 -205
- package/build/internal/es/src/forms-v4-submission-submissions.public.js.map +0 -1
- package/build/internal/es/src/forms-v4-submission-submissions.types.d.ts +0 -6288
- package/build/internal/es/src/forms-v4-submission-submissions.types.js +0 -957
- package/build/internal/es/src/forms-v4-submission-submissions.types.js.map +0 -1
- package/build/internal/es/src/forms-v4-submission-submissions.universal.js +0 -2163
- package/build/internal/es/src/forms-v4-submission-submissions.universal.js.map +0 -1
|
@@ -0,0 +1,1043 @@
|
|
|
1
|
+
import { gL as UpsertContactFromSubmissionRequest$1, a as UpsertContactFromSubmissionResponse$1, gN as CreateSubmissionRequest$1, gO as CreateSubmissionResponse$1, h0 as GetSubmissionRequest$1, h1 as GetSubmissionResponse$1, h4 as UpdateSubmissionRequest$1, h5 as UpdateSubmissionResponse$1, h6 as ConfirmSubmissionRequest$1, f as ConfirmSubmissionResponse$1, h7 as DeleteSubmissionRequest$1, h8 as DeleteSubmissionResponse$1, h9 as BulkDeleteSubmissionRequest$1, g as BulkDeleteSubmissionResponse$1, hb as RestoreSubmissionFromTrashBinRequest$1, R as RestoreSubmissionFromTrashBinResponse$1, hc as RemoveSubmissionFromTrashBinRequest$1, hd as RemoveSubmissionFromTrashBinResponse$1, he as BulkRemoveSubmissionFromTrashBinRequest$1, i as BulkRemoveSubmissionFromTrashBinResponse$1, hg as ListDeletedSubmissionsRequest$1, j as ListDeletedSubmissionsResponse$1, hk as GetDeletedSubmissionRequest$1, G as GetDeletedSubmissionResponse$1, hl as QuerySubmissionRequest$1, l as QuerySubmissionResponse$1, ho as SearchSubmissionsByNamespaceRequest$1, S as SearchSubmissionsByNamespaceResponse$1, hu as QuerySubmissionsByNamespaceRequest$1, hv as QuerySubmissionsByNamespaceResponse$1, hy as CountSubmissionsByFilterRequest$1, q as CountSubmissionsByFilterResponse$1, hA as CountSubmissionsRequest$1, s as CountSubmissionsResponse$1, hB as CountDeletedSubmissionsRequest$1, u as CountDeletedSubmissionsResponse$1, hD as GetMediaUploadURLRequest$1, v as GetMediaUploadURLResponse$1, hE as BulkMarkSubmissionsAsSeenRequest$1, hF as BulkMarkSubmissionsAsSeenResponse$1, hG as GetSubmissionDownloadUrlRequest$1, w as GetSubmissionDownloadUrlResponse$1, hK as GetFormattedSubmissionRequest$1, x as GetFormattedSubmissionResponse$1, hP as UpdateExtendedFieldsRequest$1, z as UpdateExtendedFieldsResponse$1, hQ as BulkUpdateFormSubmissionTagsRequest$1, hR as BulkUpdateFormSubmissionTagsResponse$1, hT as BulkUpdateFormSubmissionTagsByFilterRequest$1, hU as BulkUpdateFormSubmissionTagsByFilterResponse$1, hV as ValidateFormSubmissionRequest$1, A as ValidateFormSubmissionResponse$1 } from './forms-v4-submission-submissions.universal-Q3Bs_Jbt.mjs';
|
|
2
|
+
import '@wix/sdk-types';
|
|
3
|
+
|
|
4
|
+
/** Form submission that was created or retrieved. */
|
|
5
|
+
interface FormSubmission {
|
|
6
|
+
/**
|
|
7
|
+
* Submission ID.
|
|
8
|
+
* @format GUID
|
|
9
|
+
* @readonly
|
|
10
|
+
*/
|
|
11
|
+
id?: string | null;
|
|
12
|
+
/**
|
|
13
|
+
* ID of the form which the submission belongs to.
|
|
14
|
+
* @format GUID
|
|
15
|
+
* @immutable
|
|
16
|
+
*/
|
|
17
|
+
formId?: string;
|
|
18
|
+
/**
|
|
19
|
+
* The app which the form submissions belong to. For example, the namespace for the Wix Forms app is `wix.form_app.form`. Call `Get Submission` to retrieve the namespace.
|
|
20
|
+
* @minLength 10
|
|
21
|
+
* @maxLength 50
|
|
22
|
+
* @readonly
|
|
23
|
+
*/
|
|
24
|
+
namespace?: string;
|
|
25
|
+
/** Status of the submission. */
|
|
26
|
+
status?: SubmissionStatusWithLiterals;
|
|
27
|
+
/** Submission values where `key` is the form field and `value` is the data submitted for the given field. */
|
|
28
|
+
submissions?: Record<string, any>;
|
|
29
|
+
/**
|
|
30
|
+
* Date and time the form submission was created.
|
|
31
|
+
* @immutable
|
|
32
|
+
*/
|
|
33
|
+
createdDate?: Date | null;
|
|
34
|
+
/**
|
|
35
|
+
* Date and time the form submission was updated.
|
|
36
|
+
* @readonly
|
|
37
|
+
*/
|
|
38
|
+
updatedDate?: Date | null;
|
|
39
|
+
/**
|
|
40
|
+
* Revision number, which increments by 1 each time the form submission is updated. To prevent conflicting changes, the existing revision must be used when updating a form submission.
|
|
41
|
+
* @readonly
|
|
42
|
+
*/
|
|
43
|
+
revision?: string | null;
|
|
44
|
+
/**
|
|
45
|
+
* ID of the visitor that submitted the form.
|
|
46
|
+
* @readonly
|
|
47
|
+
*/
|
|
48
|
+
submitter?: Submitter;
|
|
49
|
+
/** Whether a site owner marked a submission as "seen". */
|
|
50
|
+
seen?: boolean;
|
|
51
|
+
/** Data extension object that holds users' and apps' fields. */
|
|
52
|
+
extendedFields?: ExtendedFields;
|
|
53
|
+
/**
|
|
54
|
+
* Order details. <br>
|
|
55
|
+
* <b>Note</b>: This object is only applicable when submitting a form in the Wix Payments app.
|
|
56
|
+
*/
|
|
57
|
+
orderDetails?: OrderDetails;
|
|
58
|
+
/**
|
|
59
|
+
* Contact ID of a site visitor who created the submission.
|
|
60
|
+
* @format GUID
|
|
61
|
+
* @immutable
|
|
62
|
+
*/
|
|
63
|
+
contactId?: string | null;
|
|
64
|
+
/**
|
|
65
|
+
* Authorized viewer ID.
|
|
66
|
+
* @format GUID
|
|
67
|
+
* @immutable
|
|
68
|
+
*/
|
|
69
|
+
accessRestriction?: string | null;
|
|
70
|
+
/** Tag IDs collections associated with the current entity. */
|
|
71
|
+
tags?: PublicTags;
|
|
72
|
+
}
|
|
73
|
+
declare enum SubmissionStatus {
|
|
74
|
+
UNKNOWN_SUBMISSION_STATUS = "UNKNOWN_SUBMISSION_STATUS",
|
|
75
|
+
/** A submission is created, but has not yet been recorded in the Wix Forms collection. */
|
|
76
|
+
PENDING = "PENDING",
|
|
77
|
+
/** A submission is recorded in the Wix Forms collection. */
|
|
78
|
+
CONFIRMED = "CONFIRMED",
|
|
79
|
+
/** A form submission requiring payment is created. */
|
|
80
|
+
PAYMENT_WAITING = "PAYMENT_WAITING",
|
|
81
|
+
/** An order of a form submission is canceled. */
|
|
82
|
+
PAYMENT_CANCELED = "PAYMENT_CANCELED"
|
|
83
|
+
}
|
|
84
|
+
/** @enumType */
|
|
85
|
+
type SubmissionStatusWithLiterals = SubmissionStatus | 'UNKNOWN_SUBMISSION_STATUS' | 'PENDING' | 'CONFIRMED' | 'PAYMENT_WAITING' | 'PAYMENT_CANCELED';
|
|
86
|
+
interface Submitter extends SubmitterSubmitterOneOf {
|
|
87
|
+
/**
|
|
88
|
+
* Member ID.
|
|
89
|
+
* @format GUID
|
|
90
|
+
*/
|
|
91
|
+
memberId?: string | null;
|
|
92
|
+
/**
|
|
93
|
+
* Visitor ID.
|
|
94
|
+
* @format GUID
|
|
95
|
+
*/
|
|
96
|
+
visitorId?: string | null;
|
|
97
|
+
/**
|
|
98
|
+
* Application ID.
|
|
99
|
+
* @maxLength 36
|
|
100
|
+
*/
|
|
101
|
+
applicationId?: string | null;
|
|
102
|
+
/**
|
|
103
|
+
* User ID.
|
|
104
|
+
* @format GUID
|
|
105
|
+
*/
|
|
106
|
+
userId?: string | null;
|
|
107
|
+
}
|
|
108
|
+
/** @oneof */
|
|
109
|
+
interface SubmitterSubmitterOneOf {
|
|
110
|
+
/**
|
|
111
|
+
* Member ID.
|
|
112
|
+
* @format GUID
|
|
113
|
+
*/
|
|
114
|
+
memberId?: string | null;
|
|
115
|
+
/**
|
|
116
|
+
* Visitor ID.
|
|
117
|
+
* @format GUID
|
|
118
|
+
*/
|
|
119
|
+
visitorId?: string | null;
|
|
120
|
+
/**
|
|
121
|
+
* Application ID.
|
|
122
|
+
* @maxLength 36
|
|
123
|
+
*/
|
|
124
|
+
applicationId?: string | null;
|
|
125
|
+
/**
|
|
126
|
+
* User ID.
|
|
127
|
+
* @format GUID
|
|
128
|
+
*/
|
|
129
|
+
userId?: string | null;
|
|
130
|
+
}
|
|
131
|
+
interface ExtendedFields {
|
|
132
|
+
/**
|
|
133
|
+
* Extended field data. Each key corresponds to the namespace of the app that created the extended fields.
|
|
134
|
+
* The value of each key is structured according to the schema defined when the extended fields were configured.
|
|
135
|
+
*
|
|
136
|
+
* You can only access fields for which you have the appropriate permissions.
|
|
137
|
+
*
|
|
138
|
+
* Learn more about [extended fields](https://dev.wix.com/docs/rest/articles/getting-started/extended-fields).
|
|
139
|
+
*/
|
|
140
|
+
namespaces?: Record<string, Record<string, any>>;
|
|
141
|
+
}
|
|
142
|
+
interface OrderDetails {
|
|
143
|
+
/**
|
|
144
|
+
* ID of the order related to submission (only applicable if a form has payments).
|
|
145
|
+
* @format GUID
|
|
146
|
+
* @readonly
|
|
147
|
+
*/
|
|
148
|
+
orderId?: string | null;
|
|
149
|
+
/**
|
|
150
|
+
* Order number.
|
|
151
|
+
* @readonly
|
|
152
|
+
*/
|
|
153
|
+
number?: string | null;
|
|
154
|
+
/**
|
|
155
|
+
* Currency.
|
|
156
|
+
* @format CURRENCY
|
|
157
|
+
* @readonly
|
|
158
|
+
*/
|
|
159
|
+
currency?: string | null;
|
|
160
|
+
/**
|
|
161
|
+
* Item subtotal.
|
|
162
|
+
* @decimalValue options { gte:0.00, maxScale:2 }
|
|
163
|
+
* @readonly
|
|
164
|
+
*/
|
|
165
|
+
itemSubtotal?: string;
|
|
166
|
+
/**
|
|
167
|
+
* ID of the checkout related to submission (only applicable if a form has payments).
|
|
168
|
+
* @format GUID
|
|
169
|
+
* @readonly
|
|
170
|
+
*/
|
|
171
|
+
checkoutId?: string;
|
|
172
|
+
}
|
|
173
|
+
interface PublicTags {
|
|
174
|
+
/** Tags that are exposed to anyone who has access to the labeled entity itself, including site members and visitors. */
|
|
175
|
+
tags?: TagList;
|
|
176
|
+
}
|
|
177
|
+
interface TagList {
|
|
178
|
+
/**
|
|
179
|
+
* List of tag IDs
|
|
180
|
+
* @maxSize 100
|
|
181
|
+
* @maxLength 5
|
|
182
|
+
*/
|
|
183
|
+
tagIds?: string[];
|
|
184
|
+
}
|
|
185
|
+
interface UpsertContactFromSubmissionRequest {
|
|
186
|
+
/**
|
|
187
|
+
* Submission from which contact needs to be upserted.
|
|
188
|
+
* @format GUID
|
|
189
|
+
*/
|
|
190
|
+
submissionId: string;
|
|
191
|
+
/**
|
|
192
|
+
* Optional contact id to which submission should be mapped.
|
|
193
|
+
* @format GUID
|
|
194
|
+
*/
|
|
195
|
+
contactId?: string | null;
|
|
196
|
+
/** Indicates contact has verified primary email. */
|
|
197
|
+
emailVerified?: boolean;
|
|
198
|
+
}
|
|
199
|
+
interface UpsertContactFromSubmissionResponse {
|
|
200
|
+
/** Submit contact response. */
|
|
201
|
+
submitContactResponse?: SubmitContactResponse;
|
|
202
|
+
}
|
|
203
|
+
interface SubmitContactResponse {
|
|
204
|
+
/**
|
|
205
|
+
* ID of the contact that was found or created.
|
|
206
|
+
* @format GUID
|
|
207
|
+
*/
|
|
208
|
+
contactId?: string;
|
|
209
|
+
/**
|
|
210
|
+
* Identity type of the returned contact.
|
|
211
|
+
*
|
|
212
|
+
* - `CONTACT`: The returned contact ID belongs to a new or existing contact.
|
|
213
|
+
* - `MEMBER`: The returned contact ID belongs to the currently logged-in site member.
|
|
214
|
+
* - `NOT_AUTHENTICATED_MEMBER`: The returned contact ID belongs to a site member who is not currently logged in.
|
|
215
|
+
*/
|
|
216
|
+
identityType?: IdentityTypeWithLiterals;
|
|
217
|
+
/**
|
|
218
|
+
* Indicates whether the contact was just created or already existed.
|
|
219
|
+
*
|
|
220
|
+
* If the contact was just created, returns `true`.
|
|
221
|
+
* If it already existed, returns `false`.
|
|
222
|
+
*/
|
|
223
|
+
newContact?: boolean;
|
|
224
|
+
}
|
|
225
|
+
declare enum IdentityType {
|
|
226
|
+
UNKNOWN = "UNKNOWN",
|
|
227
|
+
/** Existing or new contact */
|
|
228
|
+
CONTACT = "CONTACT",
|
|
229
|
+
/** Member is logged in, matching logic skipped */
|
|
230
|
+
MEMBER = "MEMBER",
|
|
231
|
+
/** Matching contact is a member, Merge logic won't be applied */
|
|
232
|
+
NOT_AUTHENTICATED_MEMBER = "NOT_AUTHENTICATED_MEMBER"
|
|
233
|
+
}
|
|
234
|
+
/** @enumType */
|
|
235
|
+
type IdentityTypeWithLiterals = IdentityType | 'UNKNOWN' | 'CONTACT' | 'MEMBER' | 'NOT_AUTHENTICATED_MEMBER';
|
|
236
|
+
interface CreateSubmissionRequest {
|
|
237
|
+
/** Submission to create. */
|
|
238
|
+
submission: FormSubmission;
|
|
239
|
+
/**
|
|
240
|
+
* Captcha token.
|
|
241
|
+
* @minLength 1
|
|
242
|
+
* @maxLength 3000
|
|
243
|
+
*/
|
|
244
|
+
captchaToken?: string | null;
|
|
245
|
+
}
|
|
246
|
+
interface CreateSubmissionResponse {
|
|
247
|
+
/** The created submission. */
|
|
248
|
+
submission?: FormSubmission;
|
|
249
|
+
}
|
|
250
|
+
interface ItemMetadata {
|
|
251
|
+
/**
|
|
252
|
+
* Item ID. Should always be available, unless it's impossible (for example, when failing to create an item).
|
|
253
|
+
* @format GUID
|
|
254
|
+
*/
|
|
255
|
+
id?: string | null;
|
|
256
|
+
/** Index of the item within the request array. Allows for correlation between request and response items. */
|
|
257
|
+
originalIndex?: number;
|
|
258
|
+
/** Whether the requested action was successful for this item. When `false`, the `error` field is populated. */
|
|
259
|
+
success?: boolean;
|
|
260
|
+
/** Details about the error in case of failure. */
|
|
261
|
+
error?: ApplicationError;
|
|
262
|
+
}
|
|
263
|
+
interface ApplicationError {
|
|
264
|
+
/** Error code. */
|
|
265
|
+
code?: string;
|
|
266
|
+
/** Description of the error. */
|
|
267
|
+
description?: string;
|
|
268
|
+
/** Data related to the error. */
|
|
269
|
+
data?: Record<string, any> | null;
|
|
270
|
+
}
|
|
271
|
+
interface BulkActionMetadata {
|
|
272
|
+
/** Number of items that were successfully processed. */
|
|
273
|
+
totalSuccesses?: number;
|
|
274
|
+
/** Number of items that couldn't be processed. */
|
|
275
|
+
totalFailures?: number;
|
|
276
|
+
/** Number of failures without details because detailed failure threshold was exceeded. */
|
|
277
|
+
undetailedFailures?: number;
|
|
278
|
+
}
|
|
279
|
+
interface GetSubmissionRequest {
|
|
280
|
+
/**
|
|
281
|
+
* ID of the submission to retrieve.
|
|
282
|
+
* @format GUID
|
|
283
|
+
*/
|
|
284
|
+
submissionId: string;
|
|
285
|
+
}
|
|
286
|
+
interface GetSubmissionResponse {
|
|
287
|
+
/** The retrieved submission. */
|
|
288
|
+
submission?: FormSubmission;
|
|
289
|
+
}
|
|
290
|
+
interface UpdateSubmissionRequest {
|
|
291
|
+
/** Submission to update. */
|
|
292
|
+
submission: FormSubmission;
|
|
293
|
+
}
|
|
294
|
+
interface UpdateSubmissionResponse {
|
|
295
|
+
/** The updated submission. */
|
|
296
|
+
submission?: FormSubmission;
|
|
297
|
+
}
|
|
298
|
+
interface ConfirmSubmissionRequest {
|
|
299
|
+
/**
|
|
300
|
+
* Submission ID to confirm.
|
|
301
|
+
* @format GUID
|
|
302
|
+
*/
|
|
303
|
+
submissionId: string;
|
|
304
|
+
}
|
|
305
|
+
interface ConfirmSubmissionResponse {
|
|
306
|
+
/** The confirmed submission. */
|
|
307
|
+
submission?: FormSubmission;
|
|
308
|
+
}
|
|
309
|
+
interface DeleteSubmissionRequest {
|
|
310
|
+
/**
|
|
311
|
+
* ID of the submission to delete.
|
|
312
|
+
* @format GUID
|
|
313
|
+
*/
|
|
314
|
+
submissionId: string;
|
|
315
|
+
/**
|
|
316
|
+
* Whether to permanently delete a submission bypassing the trash bin.
|
|
317
|
+
*
|
|
318
|
+
* Default: `false`
|
|
319
|
+
*/
|
|
320
|
+
permanent?: boolean;
|
|
321
|
+
/** Whether to preserve files, associated with the submission. If the value is `false`, then the files are deleted after 210 days. */
|
|
322
|
+
preserveFiles?: boolean;
|
|
323
|
+
}
|
|
324
|
+
interface DeleteSubmissionResponse {
|
|
325
|
+
}
|
|
326
|
+
interface BulkDeleteSubmissionRequest {
|
|
327
|
+
/**
|
|
328
|
+
* Form ID.
|
|
329
|
+
* @format GUID
|
|
330
|
+
*/
|
|
331
|
+
formId: string;
|
|
332
|
+
/**
|
|
333
|
+
* Submission ids.
|
|
334
|
+
* @minSize 1
|
|
335
|
+
* @maxSize 100
|
|
336
|
+
* @format GUID
|
|
337
|
+
*/
|
|
338
|
+
submissionIds?: string[];
|
|
339
|
+
/**
|
|
340
|
+
* Delete submission bypassing trash-bin
|
|
341
|
+
* Default: false
|
|
342
|
+
*/
|
|
343
|
+
permanent?: boolean;
|
|
344
|
+
/** Preserve files. */
|
|
345
|
+
preserveFiles?: boolean;
|
|
346
|
+
}
|
|
347
|
+
interface BulkDeleteSubmissionResponse {
|
|
348
|
+
/**
|
|
349
|
+
* Results of bulk submission delete
|
|
350
|
+
* @minSize 1
|
|
351
|
+
* @maxSize 100
|
|
352
|
+
*/
|
|
353
|
+
results?: BulkDeleteSubmissionResult[];
|
|
354
|
+
/** Metadata of request */
|
|
355
|
+
bulkActionMetadata?: BulkActionMetadata;
|
|
356
|
+
}
|
|
357
|
+
interface BulkDeleteSubmissionResult {
|
|
358
|
+
/** Deleted item metadata */
|
|
359
|
+
itemMetadata?: ItemMetadata;
|
|
360
|
+
}
|
|
361
|
+
interface RestoreSubmissionFromTrashBinRequest {
|
|
362
|
+
/**
|
|
363
|
+
* ID of the submission to restore.
|
|
364
|
+
* @format GUID
|
|
365
|
+
*/
|
|
366
|
+
submissionId: string;
|
|
367
|
+
}
|
|
368
|
+
interface RestoreSubmissionFromTrashBinResponse {
|
|
369
|
+
/** The restored submission. */
|
|
370
|
+
submission?: FormSubmission;
|
|
371
|
+
}
|
|
372
|
+
interface RemoveSubmissionFromTrashBinRequest {
|
|
373
|
+
/**
|
|
374
|
+
* ID of the submission to restore.
|
|
375
|
+
* @format GUID
|
|
376
|
+
*/
|
|
377
|
+
submissionId: string;
|
|
378
|
+
}
|
|
379
|
+
interface RemoveSubmissionFromTrashBinResponse {
|
|
380
|
+
}
|
|
381
|
+
interface BulkRemoveSubmissionFromTrashBinRequest {
|
|
382
|
+
/**
|
|
383
|
+
* Form ID.
|
|
384
|
+
* @format GUID
|
|
385
|
+
*/
|
|
386
|
+
formId: string;
|
|
387
|
+
/**
|
|
388
|
+
* Submission ids.
|
|
389
|
+
* @minSize 1
|
|
390
|
+
* @maxSize 100
|
|
391
|
+
* @format GUID
|
|
392
|
+
*/
|
|
393
|
+
submissionIds?: string[];
|
|
394
|
+
}
|
|
395
|
+
interface BulkRemoveSubmissionFromTrashBinResponse {
|
|
396
|
+
/**
|
|
397
|
+
* Results of bulk submission removal from trash
|
|
398
|
+
* @maxSize 100
|
|
399
|
+
*/
|
|
400
|
+
results?: BulkRemoveSubmissionFromTrashBinResult[];
|
|
401
|
+
/** Metadata of request */
|
|
402
|
+
bulkActionMetadata?: BulkActionMetadata;
|
|
403
|
+
}
|
|
404
|
+
interface BulkRemoveSubmissionFromTrashBinResult {
|
|
405
|
+
/** Deleted item metadata */
|
|
406
|
+
itemMetadata?: ItemMetadata;
|
|
407
|
+
}
|
|
408
|
+
interface ListDeletedSubmissionsRequest {
|
|
409
|
+
/**
|
|
410
|
+
* Form ID.
|
|
411
|
+
* @format GUID
|
|
412
|
+
*/
|
|
413
|
+
formId: string;
|
|
414
|
+
/**
|
|
415
|
+
* Submission ids.
|
|
416
|
+
* @maxSize 10
|
|
417
|
+
* @format GUID
|
|
418
|
+
*/
|
|
419
|
+
submissionIds?: string[];
|
|
420
|
+
/** Cursor token pointing to a page of results. Not used in the first request. Following requests use the cursor token and not filter or `order`. */
|
|
421
|
+
paging?: CursorPaging;
|
|
422
|
+
/**
|
|
423
|
+
* List of statuses of submissions which should be returned
|
|
424
|
+
* Default: CONFIRMED
|
|
425
|
+
* @maxSize 4
|
|
426
|
+
*/
|
|
427
|
+
statuses?: SubmissionStatusWithLiterals[];
|
|
428
|
+
}
|
|
429
|
+
interface CursorPaging {
|
|
430
|
+
/**
|
|
431
|
+
* Number of items to load.
|
|
432
|
+
* @max 100
|
|
433
|
+
*/
|
|
434
|
+
limit?: number | null;
|
|
435
|
+
/**
|
|
436
|
+
* Pointer to the next or previous page in the list of results.
|
|
437
|
+
*
|
|
438
|
+
* You can get the relevant cursor token
|
|
439
|
+
* from the `pagingMetadata` object in the previous call's response.
|
|
440
|
+
* Not relevant for the first request.
|
|
441
|
+
* @maxLength 16000
|
|
442
|
+
*/
|
|
443
|
+
cursor?: string | null;
|
|
444
|
+
}
|
|
445
|
+
interface ListDeletedSubmissionsResponse {
|
|
446
|
+
/** The retrieved Submissions. */
|
|
447
|
+
submissions?: FormSubmission[];
|
|
448
|
+
/** Paging metadata. */
|
|
449
|
+
pagingMetadata?: CursorPagingMetadata;
|
|
450
|
+
}
|
|
451
|
+
interface CursorPagingMetadata {
|
|
452
|
+
/** Number of items returned in the response. */
|
|
453
|
+
count?: number | null;
|
|
454
|
+
/** Offset that was requested. */
|
|
455
|
+
cursors?: Cursors;
|
|
456
|
+
/**
|
|
457
|
+
* Indicates if there are more results after the current page.
|
|
458
|
+
* If `true`, another page of results can be retrieved.
|
|
459
|
+
* If `false`, this is the last page.
|
|
460
|
+
*/
|
|
461
|
+
hasNext?: boolean | null;
|
|
462
|
+
}
|
|
463
|
+
interface Cursors {
|
|
464
|
+
/**
|
|
465
|
+
* Cursor pointing to next page in the list of results.
|
|
466
|
+
* @maxLength 16000
|
|
467
|
+
*/
|
|
468
|
+
next?: string | null;
|
|
469
|
+
/**
|
|
470
|
+
* Cursor pointing to previous page in the list of results.
|
|
471
|
+
* @maxLength 16000
|
|
472
|
+
*/
|
|
473
|
+
prev?: string | null;
|
|
474
|
+
}
|
|
475
|
+
interface GetDeletedSubmissionRequest {
|
|
476
|
+
/**
|
|
477
|
+
* Submission id.
|
|
478
|
+
* @format GUID
|
|
479
|
+
*/
|
|
480
|
+
submissionId: string;
|
|
481
|
+
}
|
|
482
|
+
interface GetDeletedSubmissionResponse {
|
|
483
|
+
/** The retrieved Submission. */
|
|
484
|
+
submission?: FormSubmission;
|
|
485
|
+
}
|
|
486
|
+
interface QuerySubmissionRequest {
|
|
487
|
+
/** Query options. */
|
|
488
|
+
query: CursorQuery;
|
|
489
|
+
/** Whether to return only your own submissions. If `false`, returns all submissions based on query filters. */
|
|
490
|
+
onlyYourOwn?: boolean;
|
|
491
|
+
}
|
|
492
|
+
interface CursorQuery extends CursorQueryPagingMethodOneOf {
|
|
493
|
+
/** Cursor token pointing to a page of results. Not used in the first request. Following requests use the cursor token and not `filter` or `sort`. */
|
|
494
|
+
cursorPaging?: CursorPaging;
|
|
495
|
+
/**
|
|
496
|
+
* Filter object in the following format:
|
|
497
|
+
* `"filter" : {
|
|
498
|
+
* "fieldName1": "value1",
|
|
499
|
+
* "fieldName2":{"$operator":"value2"}
|
|
500
|
+
* }`
|
|
501
|
+
* Example of operators: `$eq`, `$ne`, `$lt`, `$lte`, `$gt`, `$gte`, `$in`, `$hasSome`, `$hasAll`, `$startsWith`, `$contains`
|
|
502
|
+
*/
|
|
503
|
+
filter?: Record<string, any> | null;
|
|
504
|
+
/**
|
|
505
|
+
* Sort object in the following format:
|
|
506
|
+
* `[{"fieldName":"sortField1","order":"ASC"},{"fieldName":"sortField2","order":"DESC"}]`
|
|
507
|
+
* @maxSize 3
|
|
508
|
+
*/
|
|
509
|
+
sort?: Sorting[];
|
|
510
|
+
}
|
|
511
|
+
/** @oneof */
|
|
512
|
+
interface CursorQueryPagingMethodOneOf {
|
|
513
|
+
/** Cursor token pointing to a page of results. Not used in the first request. Following requests use the cursor token and not `filter` or `sort`. */
|
|
514
|
+
cursorPaging?: CursorPaging;
|
|
515
|
+
}
|
|
516
|
+
interface Sorting {
|
|
517
|
+
/**
|
|
518
|
+
* Name of the field to sort by.
|
|
519
|
+
* @maxLength 512
|
|
520
|
+
*/
|
|
521
|
+
fieldName?: string;
|
|
522
|
+
/** Sort order. */
|
|
523
|
+
order?: SortOrderWithLiterals;
|
|
524
|
+
}
|
|
525
|
+
declare enum SortOrder {
|
|
526
|
+
ASC = "ASC",
|
|
527
|
+
DESC = "DESC"
|
|
528
|
+
}
|
|
529
|
+
/** @enumType */
|
|
530
|
+
type SortOrderWithLiterals = SortOrder | 'ASC' | 'DESC';
|
|
531
|
+
interface QuerySubmissionResponse {
|
|
532
|
+
/** The retrieved submissions. */
|
|
533
|
+
submissions?: FormSubmission[];
|
|
534
|
+
/** Paging metadata. */
|
|
535
|
+
metadata?: CursorPagingMetadata;
|
|
536
|
+
}
|
|
537
|
+
interface SearchSubmissionsByNamespaceRequest {
|
|
538
|
+
/** Query options. */
|
|
539
|
+
search: CursorSearch;
|
|
540
|
+
}
|
|
541
|
+
interface CursorSearch extends CursorSearchPagingMethodOneOf {
|
|
542
|
+
/**
|
|
543
|
+
* Cursor pointing to page of results.
|
|
544
|
+
* When requesting 'cursor_paging.cursor', no `filter`, `sort` or `search` can be provided.
|
|
545
|
+
*/
|
|
546
|
+
cursorPaging?: CursorPaging;
|
|
547
|
+
/** A filter object. See documentation [here](https://bo.wix.com/wix-docs/rnd/platformization-guidelines/api-query-language#platformization-guidelines_api-query-language_defining-in-protobuf) */
|
|
548
|
+
filter?: Record<string, any> | null;
|
|
549
|
+
/**
|
|
550
|
+
* Sort object in the form [{"fieldName":"sortField1"},{"fieldName":"sortField2","direction":"DESC"}]
|
|
551
|
+
* @maxSize 10
|
|
552
|
+
*/
|
|
553
|
+
sort?: Sorting[];
|
|
554
|
+
/** Free text to match in searchable fields */
|
|
555
|
+
search?: SearchDetails;
|
|
556
|
+
}
|
|
557
|
+
/** @oneof */
|
|
558
|
+
interface CursorSearchPagingMethodOneOf {
|
|
559
|
+
/**
|
|
560
|
+
* Cursor pointing to page of results.
|
|
561
|
+
* When requesting 'cursor_paging.cursor', no `filter`, `sort` or `search` can be provided.
|
|
562
|
+
*/
|
|
563
|
+
cursorPaging?: CursorPaging;
|
|
564
|
+
}
|
|
565
|
+
interface SearchDetails {
|
|
566
|
+
/** Defines how separate search terms in `expression` are combined */
|
|
567
|
+
mode?: ModeWithLiterals;
|
|
568
|
+
/**
|
|
569
|
+
* Search term or expression
|
|
570
|
+
* @maxLength 100
|
|
571
|
+
*/
|
|
572
|
+
expression?: string | null;
|
|
573
|
+
/** Flag if should use auto fuzzy search (allowing typos by a managed proximity algorithm) */
|
|
574
|
+
fuzzy?: boolean;
|
|
575
|
+
}
|
|
576
|
+
declare enum Mode {
|
|
577
|
+
/** Any of the search terms must be present */
|
|
578
|
+
OR = "OR",
|
|
579
|
+
/** All search terms must be present */
|
|
580
|
+
AND = "AND"
|
|
581
|
+
}
|
|
582
|
+
/** @enumType */
|
|
583
|
+
type ModeWithLiterals = Mode | 'OR' | 'AND';
|
|
584
|
+
interface SearchSubmissionsByNamespaceResponse {
|
|
585
|
+
/** The retrieved Submissions. */
|
|
586
|
+
submissions?: FormSubmission[];
|
|
587
|
+
/** Paging metadata. */
|
|
588
|
+
metadata?: CursorPagingMetadata;
|
|
589
|
+
}
|
|
590
|
+
interface QuerySubmissionsByNamespaceRequest {
|
|
591
|
+
/** Query options. */
|
|
592
|
+
query: CursorQuery;
|
|
593
|
+
/** Whether to return only your own submissions. If `false`, returns all submissions based on query filters. */
|
|
594
|
+
onlyYourOwn?: boolean;
|
|
595
|
+
}
|
|
596
|
+
interface QuerySubmissionsByNamespaceResponse {
|
|
597
|
+
/** The retrieved Submissions. */
|
|
598
|
+
submissions?: FormSubmission[];
|
|
599
|
+
/** Paging metadata. */
|
|
600
|
+
metadata?: CursorPagingMetadata;
|
|
601
|
+
}
|
|
602
|
+
interface CountSubmissionsByFilterRequest {
|
|
603
|
+
/** A filter object. Must filter by namespace. */
|
|
604
|
+
filter: Record<string, any> | null;
|
|
605
|
+
/** Free text to match in searchable fields. */
|
|
606
|
+
search?: SearchDetails;
|
|
607
|
+
}
|
|
608
|
+
interface CountSubmissionsByFilterResponse {
|
|
609
|
+
/** Forms submission count. */
|
|
610
|
+
formsSubmissionsCount?: FormSubmissionsCount[];
|
|
611
|
+
}
|
|
612
|
+
interface FormSubmissionsCount {
|
|
613
|
+
/**
|
|
614
|
+
* Form ID.
|
|
615
|
+
* @format GUID
|
|
616
|
+
*/
|
|
617
|
+
formId?: string;
|
|
618
|
+
/** Total number of submissions. */
|
|
619
|
+
totalCount?: number;
|
|
620
|
+
/** Number of submissions that haven't yet been seen by site Extensions with manage submission permissions. */
|
|
621
|
+
unseenCount?: number;
|
|
622
|
+
}
|
|
623
|
+
interface CountSubmissionsRequest {
|
|
624
|
+
/**
|
|
625
|
+
* Form IDs.
|
|
626
|
+
* @format GUID
|
|
627
|
+
* @minSize 1
|
|
628
|
+
* @maxSize 100
|
|
629
|
+
*/
|
|
630
|
+
formIds: string[];
|
|
631
|
+
/**
|
|
632
|
+
* Identifies the app which the form submissions belong to. For example, the namespace for the Wix Forms App is `"wix.form_app.form"`. The namespace of a submission can be retrieved using the Get Submission endpoint.
|
|
633
|
+
* @minLength 10
|
|
634
|
+
* @maxLength 50
|
|
635
|
+
*/
|
|
636
|
+
namespace: string;
|
|
637
|
+
/**
|
|
638
|
+
* List of statuses of submissions which should be taken into count
|
|
639
|
+
* Default: CONFIRMED, PAYMENT_WAITING, PAYMENT_CANCELED
|
|
640
|
+
* @maxSize 4
|
|
641
|
+
*/
|
|
642
|
+
statuses?: SubmissionStatusWithLiterals[];
|
|
643
|
+
}
|
|
644
|
+
interface CountSubmissionsResponse {
|
|
645
|
+
/** Forms submission count. */
|
|
646
|
+
formsSubmissionsCount?: FormSubmissionsCount[];
|
|
647
|
+
}
|
|
648
|
+
interface CountDeletedSubmissionsRequest {
|
|
649
|
+
/**
|
|
650
|
+
* Form IDs.
|
|
651
|
+
* @format GUID
|
|
652
|
+
* @minSize 1
|
|
653
|
+
* @maxSize 100
|
|
654
|
+
*/
|
|
655
|
+
formIds: string[];
|
|
656
|
+
/**
|
|
657
|
+
* Identifies the app which the form submissions belong to. For example, the namespace for the Wix Forms App is `"wix.form_app.form"`. The namespace of a submission can be retrieved using the Get Submission endpoint.
|
|
658
|
+
* @minLength 10
|
|
659
|
+
* @maxLength 50
|
|
660
|
+
*/
|
|
661
|
+
namespace: string;
|
|
662
|
+
/**
|
|
663
|
+
* List of statuses of submissions which should be taken into count
|
|
664
|
+
* Default: CONFIRMED, PAYMENT_WAITING, PAYMENT_CANCELED
|
|
665
|
+
* @maxSize 4
|
|
666
|
+
*/
|
|
667
|
+
statuses?: SubmissionStatusWithLiterals[];
|
|
668
|
+
}
|
|
669
|
+
interface CountDeletedSubmissionsResponse {
|
|
670
|
+
/** Forms submission count. */
|
|
671
|
+
formsDeletedSubmissionsCount?: FormDeletedSubmissionsCount[];
|
|
672
|
+
}
|
|
673
|
+
interface FormDeletedSubmissionsCount {
|
|
674
|
+
/**
|
|
675
|
+
* Form ID.
|
|
676
|
+
* @format GUID
|
|
677
|
+
*/
|
|
678
|
+
formId?: string;
|
|
679
|
+
/** Total number of submissions. */
|
|
680
|
+
totalCount?: number;
|
|
681
|
+
}
|
|
682
|
+
interface GetMediaUploadURLRequest {
|
|
683
|
+
/**
|
|
684
|
+
* Form ID.
|
|
685
|
+
* @format GUID
|
|
686
|
+
*/
|
|
687
|
+
formId: string;
|
|
688
|
+
/**
|
|
689
|
+
* Name of file to upload.
|
|
690
|
+
* @maxLength 300
|
|
691
|
+
*/
|
|
692
|
+
filename: string;
|
|
693
|
+
/**
|
|
694
|
+
* [Mime type](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/MIME_types#) of file to upload.
|
|
695
|
+
*
|
|
696
|
+
* For example, `'image/png'`
|
|
697
|
+
* @maxLength 100
|
|
698
|
+
*/
|
|
699
|
+
mimeType: string;
|
|
700
|
+
}
|
|
701
|
+
interface GetMediaUploadURLResponse {
|
|
702
|
+
/**
|
|
703
|
+
* Url to upload file.
|
|
704
|
+
* @maxLength 500
|
|
705
|
+
*/
|
|
706
|
+
uploadUrl?: string;
|
|
707
|
+
}
|
|
708
|
+
interface BulkMarkSubmissionsAsSeenRequest {
|
|
709
|
+
/**
|
|
710
|
+
* Submission IDs to mark as seen.
|
|
711
|
+
* @format GUID
|
|
712
|
+
* @minSize 1
|
|
713
|
+
* @maxSize 100
|
|
714
|
+
*/
|
|
715
|
+
ids: string[];
|
|
716
|
+
/**
|
|
717
|
+
* ID of the form which the submissions belongs to.
|
|
718
|
+
* @format GUID
|
|
719
|
+
*/
|
|
720
|
+
formId: string;
|
|
721
|
+
}
|
|
722
|
+
interface BulkMarkSubmissionsAsSeenResponse {
|
|
723
|
+
}
|
|
724
|
+
interface GetSubmissionDownloadUrlRequest {
|
|
725
|
+
/**
|
|
726
|
+
* Submission ID.
|
|
727
|
+
* @format GUID
|
|
728
|
+
*/
|
|
729
|
+
submissionId: string;
|
|
730
|
+
}
|
|
731
|
+
interface GetSubmissionDownloadUrlResponse {
|
|
732
|
+
/** The retrieved submission document. */
|
|
733
|
+
document?: SubmissionDocument;
|
|
734
|
+
}
|
|
735
|
+
interface SubmissionDocument extends SubmissionDocumentDocumentOneOf {
|
|
736
|
+
/** Data of ready to download document */
|
|
737
|
+
readyDetails?: DocumentReady;
|
|
738
|
+
/**
|
|
739
|
+
* Document ID.
|
|
740
|
+
* @readonly
|
|
741
|
+
* @maxLength 50
|
|
742
|
+
*/
|
|
743
|
+
id?: string | null;
|
|
744
|
+
/** Document status. */
|
|
745
|
+
status?: StatusWithLiterals;
|
|
746
|
+
}
|
|
747
|
+
/** @oneof */
|
|
748
|
+
interface SubmissionDocumentDocumentOneOf {
|
|
749
|
+
/** Data of ready to download document */
|
|
750
|
+
readyDetails?: DocumentReady;
|
|
751
|
+
}
|
|
752
|
+
declare enum Status {
|
|
753
|
+
UNKNOWN_STATUS = "UNKNOWN_STATUS",
|
|
754
|
+
READY = "READY",
|
|
755
|
+
PENDING = "PENDING",
|
|
756
|
+
FAILED = "FAILED"
|
|
757
|
+
}
|
|
758
|
+
/** @enumType */
|
|
759
|
+
type StatusWithLiterals = Status | 'UNKNOWN_STATUS' | 'READY' | 'PENDING' | 'FAILED';
|
|
760
|
+
interface DocumentReady {
|
|
761
|
+
/**
|
|
762
|
+
* Document download URL.
|
|
763
|
+
* @readonly
|
|
764
|
+
* @maxLength 300
|
|
765
|
+
*/
|
|
766
|
+
downloadUrl?: string;
|
|
767
|
+
}
|
|
768
|
+
interface GetFormattedSubmissionRequest {
|
|
769
|
+
/**
|
|
770
|
+
* Submission ID.
|
|
771
|
+
* @format GUID
|
|
772
|
+
*/
|
|
773
|
+
submissionId: string;
|
|
774
|
+
}
|
|
775
|
+
interface GetFormattedSubmissionResponse {
|
|
776
|
+
/**
|
|
777
|
+
* Submission ID.
|
|
778
|
+
* @format GUID
|
|
779
|
+
*/
|
|
780
|
+
submissionId?: string;
|
|
781
|
+
/**
|
|
782
|
+
* Ordered by form layout list of field submissions.
|
|
783
|
+
* @maxSize 100
|
|
784
|
+
*/
|
|
785
|
+
submissions?: FormattedSubmission[];
|
|
786
|
+
}
|
|
787
|
+
interface FormattedSubmission {
|
|
788
|
+
/**
|
|
789
|
+
* Label of form field
|
|
790
|
+
* @maxLength 500
|
|
791
|
+
*/
|
|
792
|
+
label?: string | null;
|
|
793
|
+
/**
|
|
794
|
+
* Key of the submission, and target of a form field
|
|
795
|
+
* @maxLength 200
|
|
796
|
+
*/
|
|
797
|
+
key?: string;
|
|
798
|
+
/**
|
|
799
|
+
* Value of the submission, formatted as a string
|
|
800
|
+
* @maxLength 500
|
|
801
|
+
*/
|
|
802
|
+
value?: string;
|
|
803
|
+
/**
|
|
804
|
+
* Id of the form field
|
|
805
|
+
* @format GUID
|
|
806
|
+
*/
|
|
807
|
+
fieldId?: string;
|
|
808
|
+
}
|
|
809
|
+
interface UpdateExtendedFieldsRequest {
|
|
810
|
+
/** ID of the entity to update. */
|
|
811
|
+
id: string;
|
|
812
|
+
/** Identifier for the app whose extended fields are being updated. */
|
|
813
|
+
namespace: string;
|
|
814
|
+
/** Data to update. Structured according to the [schema](https://dev.wix.com/docs/rest/articles/getting-started/extended-fields#json-schema-for-extended-fields) defined when the extended fields were configured. */
|
|
815
|
+
namespaceData: Record<string, any> | null;
|
|
816
|
+
}
|
|
817
|
+
interface UpdateExtendedFieldsResponse {
|
|
818
|
+
/**
|
|
819
|
+
* namespace that was updated
|
|
820
|
+
* @minLength 10
|
|
821
|
+
* @maxLength 50
|
|
822
|
+
*/
|
|
823
|
+
namespace?: string;
|
|
824
|
+
/** only data from UpdateExtendedFieldsRequest namespace_data */
|
|
825
|
+
namespaceData?: Record<string, any> | null;
|
|
826
|
+
}
|
|
827
|
+
interface BulkUpdateFormSubmissionTagsRequest {
|
|
828
|
+
/**
|
|
829
|
+
* Submission IDs to update tags for.
|
|
830
|
+
* @format GUID
|
|
831
|
+
* @minSize 1
|
|
832
|
+
* @maxSize 100
|
|
833
|
+
*/
|
|
834
|
+
submissionIds: string[];
|
|
835
|
+
/** Tags to be added to submissions */
|
|
836
|
+
assignTags?: PublicTags;
|
|
837
|
+
/** Tags to be removed from submissions */
|
|
838
|
+
unassignTags?: PublicTags;
|
|
839
|
+
}
|
|
840
|
+
interface BulkUpdateFormSubmissionTagsResponse {
|
|
841
|
+
/**
|
|
842
|
+
* Updated submissions with results
|
|
843
|
+
* @minSize 1
|
|
844
|
+
* @maxSize 100
|
|
845
|
+
*/
|
|
846
|
+
results?: BulkUpdateFormSubmissionTagsResult[];
|
|
847
|
+
/** Metadata of request */
|
|
848
|
+
bulkActionMetadata?: BulkActionMetadata;
|
|
849
|
+
}
|
|
850
|
+
interface BulkUpdateFormSubmissionTagsResult {
|
|
851
|
+
/** Updated item metadata */
|
|
852
|
+
itemMetadata?: ItemMetadata;
|
|
853
|
+
}
|
|
854
|
+
interface BulkUpdateFormSubmissionTagsByFilterRequest {
|
|
855
|
+
/** Filter to select the submission to update */
|
|
856
|
+
filter: Record<string, any> | null;
|
|
857
|
+
/** Tags to be added to submissions */
|
|
858
|
+
assignTags?: PublicTags;
|
|
859
|
+
/** Tags to be removed from submissions */
|
|
860
|
+
unassignTags?: PublicTags;
|
|
861
|
+
}
|
|
862
|
+
interface BulkUpdateFormSubmissionTagsByFilterResponse {
|
|
863
|
+
/**
|
|
864
|
+
* Job id for the bulk update operation
|
|
865
|
+
* @format GUID
|
|
866
|
+
*/
|
|
867
|
+
jobId?: string;
|
|
868
|
+
}
|
|
869
|
+
interface ValidateFormSubmissionRequest {
|
|
870
|
+
/** Submission to validate. */
|
|
871
|
+
submission: FormSubmission;
|
|
872
|
+
/** Optional metadata passed to SPI implementer, allowing clients to include additional business-specific data. */
|
|
873
|
+
additionalMetadata?: Record<string, any> | null;
|
|
874
|
+
/**
|
|
875
|
+
* List of field targets/keys to validate, in case when only several fields should to be validated.
|
|
876
|
+
* If empty, all form fields be validated
|
|
877
|
+
* @maxSize 200
|
|
878
|
+
* @maxLength 200
|
|
879
|
+
*/
|
|
880
|
+
fieldsToValidate?: string[];
|
|
881
|
+
}
|
|
882
|
+
interface ValidateFormSubmissionResponse {
|
|
883
|
+
/**
|
|
884
|
+
* Flag indicating if the submission is valid
|
|
885
|
+
* Default: true
|
|
886
|
+
*/
|
|
887
|
+
valid?: boolean | null;
|
|
888
|
+
/**
|
|
889
|
+
* Submission validation violations
|
|
890
|
+
* @maxSize 100
|
|
891
|
+
*/
|
|
892
|
+
violationErrors?: FieldViolation[];
|
|
893
|
+
}
|
|
894
|
+
interface FieldViolation extends FieldViolationErrorDataOneOf {
|
|
895
|
+
/** Validation errors */
|
|
896
|
+
submissionValidationErrors?: SubmissionValidationErrors;
|
|
897
|
+
/**
|
|
898
|
+
* Name of violated entity
|
|
899
|
+
* @maxLength 50
|
|
900
|
+
*/
|
|
901
|
+
name?: string;
|
|
902
|
+
/**
|
|
903
|
+
* Description of the error
|
|
904
|
+
* @maxLength 512
|
|
905
|
+
*/
|
|
906
|
+
description?: string;
|
|
907
|
+
/**
|
|
908
|
+
* Rule name
|
|
909
|
+
* @maxLength 50
|
|
910
|
+
*/
|
|
911
|
+
ruleName?: string;
|
|
912
|
+
}
|
|
913
|
+
/** @oneof */
|
|
914
|
+
interface FieldViolationErrorDataOneOf {
|
|
915
|
+
/** Validation errors */
|
|
916
|
+
submissionValidationErrors?: SubmissionValidationErrors;
|
|
917
|
+
}
|
|
918
|
+
interface SubmissionValidationErrors {
|
|
919
|
+
/**
|
|
920
|
+
* Submission validation errors.
|
|
921
|
+
* @maxSize 100
|
|
922
|
+
*/
|
|
923
|
+
errors?: SubmissionValidationError[];
|
|
924
|
+
}
|
|
925
|
+
interface SubmissionValidationError extends SubmissionValidationErrorErrorMessageOneOf {
|
|
926
|
+
/** Predefined error type. */
|
|
927
|
+
errorType?: SubmissionErrorTypeWithLiterals;
|
|
928
|
+
/**
|
|
929
|
+
* Custom error message. The message is displayed instead of an error type.
|
|
930
|
+
* @maxLength 500
|
|
931
|
+
*/
|
|
932
|
+
customErrorMessage?: string;
|
|
933
|
+
/**
|
|
934
|
+
* Path indicating the source of the error, such as `form.fields.target`.
|
|
935
|
+
* @maxLength 500
|
|
936
|
+
*/
|
|
937
|
+
errorPath?: string;
|
|
938
|
+
/** Additional error parameters. */
|
|
939
|
+
params?: Record<string, any> | null;
|
|
940
|
+
}
|
|
941
|
+
/** @oneof */
|
|
942
|
+
interface SubmissionValidationErrorErrorMessageOneOf {
|
|
943
|
+
/** Predefined error type. */
|
|
944
|
+
errorType?: SubmissionErrorTypeWithLiterals;
|
|
945
|
+
/**
|
|
946
|
+
* Custom error message. The message is displayed instead of an error type.
|
|
947
|
+
* @maxLength 500
|
|
948
|
+
*/
|
|
949
|
+
customErrorMessage?: string;
|
|
950
|
+
}
|
|
951
|
+
declare enum SubmissionErrorType {
|
|
952
|
+
/** Error is unknown or unsuitable for any of the options below. */
|
|
953
|
+
UNKNOWN_ERROR = "UNKNOWN_ERROR",
|
|
954
|
+
/** Type of submitted value is incorrect. */
|
|
955
|
+
TYPE_ERROR = "TYPE_ERROR",
|
|
956
|
+
/** Value is required to be provided. */
|
|
957
|
+
REQUIRED_VALUE_ERROR = "REQUIRED_VALUE_ERROR",
|
|
958
|
+
/** Value contains additional properties not expected in schema. */
|
|
959
|
+
UNKNOWN_VALUE_ERROR = "UNKNOWN_VALUE_ERROR",
|
|
960
|
+
/** Text value exceeds max length. */
|
|
961
|
+
MAX_LENGTH_ERROR = "MAX_LENGTH_ERROR",
|
|
962
|
+
/** Text value does not reach min length. */
|
|
963
|
+
MIN_LENGTH_ERROR = "MIN_LENGTH_ERROR",
|
|
964
|
+
/** Text value is not applicable for expected pattern. */
|
|
965
|
+
PATTERN_ERROR = "PATTERN_ERROR",
|
|
966
|
+
/** Text value is not applicable for expected format. */
|
|
967
|
+
FORMAT_ERROR = "FORMAT_ERROR",
|
|
968
|
+
/** Number value is too big. */
|
|
969
|
+
MAX_VALUE_ERROR = "MAX_VALUE_ERROR",
|
|
970
|
+
/** Number value is too small. */
|
|
971
|
+
MIN_VALUE_ERROR = "MIN_VALUE_ERROR",
|
|
972
|
+
/** Number value is not a multiple of expected number. */
|
|
973
|
+
MULTIPLE_OF_VALUE_ERROR = "MULTIPLE_OF_VALUE_ERROR",
|
|
974
|
+
/** Array value has too many items. */
|
|
975
|
+
MIN_ITEMS_ERROR = "MIN_ITEMS_ERROR",
|
|
976
|
+
/** Array value has not enough items. */
|
|
977
|
+
MAX_ITEMS_ERROR = "MAX_ITEMS_ERROR",
|
|
978
|
+
/** Value is not in the list of allowed values. */
|
|
979
|
+
NOT_ALLOWED_VALUE_ERROR = "NOT_ALLOWED_VALUE_ERROR",
|
|
980
|
+
/** Submitted form is disabled. */
|
|
981
|
+
DISABLED_FORM_ERROR = "DISABLED_FORM_ERROR"
|
|
982
|
+
}
|
|
983
|
+
/** @enumType */
|
|
984
|
+
type SubmissionErrorTypeWithLiterals = SubmissionErrorType | 'UNKNOWN_ERROR' | 'TYPE_ERROR' | 'REQUIRED_VALUE_ERROR' | 'UNKNOWN_VALUE_ERROR' | 'MAX_LENGTH_ERROR' | 'MIN_LENGTH_ERROR' | 'PATTERN_ERROR' | 'FORMAT_ERROR' | 'MAX_VALUE_ERROR' | 'MIN_VALUE_ERROR' | 'MULTIPLE_OF_VALUE_ERROR' | 'MIN_ITEMS_ERROR' | 'MAX_ITEMS_ERROR' | 'NOT_ALLOWED_VALUE_ERROR' | 'DISABLED_FORM_ERROR';
|
|
985
|
+
|
|
986
|
+
type __PublicMethodMetaInfo<K = string, M = unknown, T = unknown, S = unknown, Q = unknown, R = unknown> = {
|
|
987
|
+
getUrl: (context: any) => string;
|
|
988
|
+
httpMethod: K;
|
|
989
|
+
path: string;
|
|
990
|
+
pathParams: M;
|
|
991
|
+
__requestType: T;
|
|
992
|
+
__originalRequestType: S;
|
|
993
|
+
__responseType: Q;
|
|
994
|
+
__originalResponseType: R;
|
|
995
|
+
};
|
|
996
|
+
declare function upsertContactFromSubmission(): __PublicMethodMetaInfo<'POST', {}, UpsertContactFromSubmissionRequest$1, UpsertContactFromSubmissionRequest, UpsertContactFromSubmissionResponse$1, UpsertContactFromSubmissionResponse>;
|
|
997
|
+
declare function createSubmission(): __PublicMethodMetaInfo<'POST', {}, CreateSubmissionRequest$1, CreateSubmissionRequest, CreateSubmissionResponse$1, CreateSubmissionResponse>;
|
|
998
|
+
declare function getSubmission(): __PublicMethodMetaInfo<'GET', {
|
|
999
|
+
submissionId: string;
|
|
1000
|
+
}, GetSubmissionRequest$1, GetSubmissionRequest, GetSubmissionResponse$1, GetSubmissionResponse>;
|
|
1001
|
+
declare function updateSubmission(): __PublicMethodMetaInfo<'PATCH', {
|
|
1002
|
+
submissionId: string;
|
|
1003
|
+
}, UpdateSubmissionRequest$1, UpdateSubmissionRequest, UpdateSubmissionResponse$1, UpdateSubmissionResponse>;
|
|
1004
|
+
declare function confirmSubmission(): __PublicMethodMetaInfo<'POST', {
|
|
1005
|
+
submissionId: string;
|
|
1006
|
+
}, ConfirmSubmissionRequest$1, ConfirmSubmissionRequest, ConfirmSubmissionResponse$1, ConfirmSubmissionResponse>;
|
|
1007
|
+
declare function deleteSubmission(): __PublicMethodMetaInfo<'DELETE', {
|
|
1008
|
+
submissionId: string;
|
|
1009
|
+
}, DeleteSubmissionRequest$1, DeleteSubmissionRequest, DeleteSubmissionResponse$1, DeleteSubmissionResponse>;
|
|
1010
|
+
declare function bulkDeleteSubmission(): __PublicMethodMetaInfo<'POST', {}, BulkDeleteSubmissionRequest$1, BulkDeleteSubmissionRequest, BulkDeleteSubmissionResponse$1, BulkDeleteSubmissionResponse>;
|
|
1011
|
+
declare function restoreSubmissionFromTrashBin(): __PublicMethodMetaInfo<'POST', {
|
|
1012
|
+
submissionId: string;
|
|
1013
|
+
}, RestoreSubmissionFromTrashBinRequest$1, RestoreSubmissionFromTrashBinRequest, RestoreSubmissionFromTrashBinResponse$1, RestoreSubmissionFromTrashBinResponse>;
|
|
1014
|
+
declare function removeSubmissionFromTrashBin(): __PublicMethodMetaInfo<'DELETE', {
|
|
1015
|
+
submissionId: string;
|
|
1016
|
+
}, RemoveSubmissionFromTrashBinRequest$1, RemoveSubmissionFromTrashBinRequest, RemoveSubmissionFromTrashBinResponse$1, RemoveSubmissionFromTrashBinResponse>;
|
|
1017
|
+
declare function bulkRemoveSubmissionFromTrashBin(): __PublicMethodMetaInfo<'POST', {}, BulkRemoveSubmissionFromTrashBinRequest$1, BulkRemoveSubmissionFromTrashBinRequest, BulkRemoveSubmissionFromTrashBinResponse$1, BulkRemoveSubmissionFromTrashBinResponse>;
|
|
1018
|
+
declare function listDeletedSubmissions(): __PublicMethodMetaInfo<'GET', {}, ListDeletedSubmissionsRequest$1, ListDeletedSubmissionsRequest, ListDeletedSubmissionsResponse$1, ListDeletedSubmissionsResponse>;
|
|
1019
|
+
declare function getDeletedSubmission(): __PublicMethodMetaInfo<'GET', {
|
|
1020
|
+
submissionId: string;
|
|
1021
|
+
}, GetDeletedSubmissionRequest$1, GetDeletedSubmissionRequest, GetDeletedSubmissionResponse$1, GetDeletedSubmissionResponse>;
|
|
1022
|
+
declare function querySubmission(): __PublicMethodMetaInfo<'POST', {}, QuerySubmissionRequest$1, QuerySubmissionRequest, QuerySubmissionResponse$1, QuerySubmissionResponse>;
|
|
1023
|
+
declare function searchSubmissionsByNamespace(): __PublicMethodMetaInfo<'POST', {}, SearchSubmissionsByNamespaceRequest$1, SearchSubmissionsByNamespaceRequest, SearchSubmissionsByNamespaceResponse$1, SearchSubmissionsByNamespaceResponse>;
|
|
1024
|
+
declare function querySubmissionsByNamespace(): __PublicMethodMetaInfo<'POST', {}, QuerySubmissionsByNamespaceRequest$1, QuerySubmissionsByNamespaceRequest, QuerySubmissionsByNamespaceResponse$1, QuerySubmissionsByNamespaceResponse>;
|
|
1025
|
+
declare function countSubmissionsByFilter(): __PublicMethodMetaInfo<'POST', {}, CountSubmissionsByFilterRequest$1, CountSubmissionsByFilterRequest, CountSubmissionsByFilterResponse$1, CountSubmissionsByFilterResponse>;
|
|
1026
|
+
declare function countSubmissions(): __PublicMethodMetaInfo<'POST', {}, CountSubmissionsRequest$1, CountSubmissionsRequest, CountSubmissionsResponse$1, CountSubmissionsResponse>;
|
|
1027
|
+
declare function countDeletedSubmissions(): __PublicMethodMetaInfo<'POST', {}, CountDeletedSubmissionsRequest$1, CountDeletedSubmissionsRequest, CountDeletedSubmissionsResponse$1, CountDeletedSubmissionsResponse>;
|
|
1028
|
+
declare function getMediaUploadUrl(): __PublicMethodMetaInfo<'POST', {}, GetMediaUploadURLRequest$1, GetMediaUploadURLRequest, GetMediaUploadURLResponse$1, GetMediaUploadURLResponse>;
|
|
1029
|
+
declare function bulkMarkSubmissionsAsSeen(): __PublicMethodMetaInfo<'POST', {}, BulkMarkSubmissionsAsSeenRequest$1, BulkMarkSubmissionsAsSeenRequest, BulkMarkSubmissionsAsSeenResponse$1, BulkMarkSubmissionsAsSeenResponse>;
|
|
1030
|
+
declare function getSubmissionDownloadUrl(): __PublicMethodMetaInfo<'GET', {
|
|
1031
|
+
submissionId: string;
|
|
1032
|
+
}, GetSubmissionDownloadUrlRequest$1, GetSubmissionDownloadUrlRequest, GetSubmissionDownloadUrlResponse$1, GetSubmissionDownloadUrlResponse>;
|
|
1033
|
+
declare function getFormattedSubmission(): __PublicMethodMetaInfo<'GET', {
|
|
1034
|
+
submissionId: string;
|
|
1035
|
+
}, GetFormattedSubmissionRequest$1, GetFormattedSubmissionRequest, GetFormattedSubmissionResponse$1, GetFormattedSubmissionResponse>;
|
|
1036
|
+
declare function updateExtendedFields(): __PublicMethodMetaInfo<'POST', {
|
|
1037
|
+
id: string;
|
|
1038
|
+
}, UpdateExtendedFieldsRequest$1, UpdateExtendedFieldsRequest, UpdateExtendedFieldsResponse$1, UpdateExtendedFieldsResponse>;
|
|
1039
|
+
declare function bulkUpdateFormSubmissionTags(): __PublicMethodMetaInfo<'POST', {}, BulkUpdateFormSubmissionTagsRequest$1, BulkUpdateFormSubmissionTagsRequest, BulkUpdateFormSubmissionTagsResponse$1, BulkUpdateFormSubmissionTagsResponse>;
|
|
1040
|
+
declare function bulkUpdateFormSubmissionTagsByFilter(): __PublicMethodMetaInfo<'POST', {}, BulkUpdateFormSubmissionTagsByFilterRequest$1, BulkUpdateFormSubmissionTagsByFilterRequest, BulkUpdateFormSubmissionTagsByFilterResponse$1, BulkUpdateFormSubmissionTagsByFilterResponse>;
|
|
1041
|
+
declare function validateFormSubmission(): __PublicMethodMetaInfo<'POST', {}, ValidateFormSubmissionRequest$1, ValidateFormSubmissionRequest, ValidateFormSubmissionResponse$1, ValidateFormSubmissionResponse>;
|
|
1042
|
+
|
|
1043
|
+
export { type __PublicMethodMetaInfo, bulkDeleteSubmission, bulkMarkSubmissionsAsSeen, bulkRemoveSubmissionFromTrashBin, bulkUpdateFormSubmissionTags, bulkUpdateFormSubmissionTagsByFilter, confirmSubmission, countDeletedSubmissions, countSubmissions, countSubmissionsByFilter, createSubmission, deleteSubmission, getDeletedSubmission, getFormattedSubmission, getMediaUploadUrl, getSubmission, getSubmissionDownloadUrl, listDeletedSubmissions, querySubmission, querySubmissionsByNamespace, removeSubmissionFromTrashBin, restoreSubmissionFromTrashBin, searchSubmissionsByNamespace, updateExtendedFields, updateSubmission, upsertContactFromSubmission, validateFormSubmission };
|