@wix/auto_sdk_standalone-forms_standalone-forms 1.0.1 → 1.0.2
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 +51 -24
- package/build/cjs/index.js.map +1 -1
- package/build/cjs/index.typings.d.ts +103 -59
- package/build/cjs/index.typings.js.map +1 -1
- package/build/cjs/meta.d.ts +47 -32
- package/build/cjs/meta.js.map +1 -1
- package/build/es/index.d.mts +51 -24
- package/build/es/index.mjs.map +1 -1
- package/build/es/index.typings.d.mts +103 -59
- package/build/es/index.typings.mjs.map +1 -1
- package/build/es/meta.d.mts +47 -32
- package/build/es/meta.mjs.map +1 -1
- package/build/internal/cjs/index.d.ts +51 -24
- package/build/internal/cjs/index.typings.d.ts +103 -59
- package/build/internal/cjs/meta.d.ts +47 -32
- package/build/internal/es/index.d.mts +51 -24
- package/build/internal/es/index.typings.d.mts +103 -59
- package/build/internal/es/meta.d.mts +47 -32
- package/package.json +2 -2
|
@@ -1,27 +1,32 @@
|
|
|
1
1
|
import { NonNullablePaths } from '@wix/sdk-types';
|
|
2
2
|
|
|
3
|
+
/**
|
|
4
|
+
* A standalone form marks a [form](https://dev.wix.com/docs/api-reference/crm/forms/form-schemas/introduction) as standalone, so responders can reach it at its own public URL
|
|
5
|
+
* instead of on a Wix site.
|
|
6
|
+
*
|
|
7
|
+
* A form doesn't indicate whether it's standalone. A standalone form that references the form is what makes it
|
|
8
|
+
* standalone.
|
|
9
|
+
*/
|
|
3
10
|
interface StandaloneForm {
|
|
4
11
|
/**
|
|
5
|
-
* Standalone form ID.
|
|
12
|
+
* Standalone form ID.
|
|
6
13
|
*
|
|
7
|
-
*
|
|
14
|
+
* Used in the standalone form's public URL. See `accountSlug` for the URL format.
|
|
8
15
|
* @maxLength 36
|
|
9
16
|
* @readonly
|
|
10
17
|
*/
|
|
11
18
|
_id?: string | null;
|
|
12
19
|
/**
|
|
13
|
-
* ID of the form
|
|
20
|
+
* ID of the [form](https://dev.wix.com/docs/api-reference/crm/forms/form-schemas/introduction) that the standalone form marks as standalone.
|
|
14
21
|
*
|
|
15
|
-
*
|
|
16
|
-
* record that references it is what makes the form standalone.
|
|
22
|
+
* The form must exist before you create the standalone form.
|
|
17
23
|
* @format GUID
|
|
18
24
|
*/
|
|
19
25
|
formId?: string | null;
|
|
20
26
|
/**
|
|
21
|
-
* ID of the
|
|
27
|
+
* ID of the site that owns the standalone form.
|
|
22
28
|
*
|
|
23
|
-
*
|
|
24
|
-
* meta site is stored explicitly in this field. Set from the calling context when the form is created.
|
|
29
|
+
* Set to the site your request is authorized for when the standalone form is created.
|
|
25
30
|
* @format GUID
|
|
26
31
|
* @readonly
|
|
27
32
|
*/
|
|
@@ -37,10 +42,13 @@ interface StandaloneForm {
|
|
|
37
42
|
*/
|
|
38
43
|
_updatedDate?: Date | null;
|
|
39
44
|
/**
|
|
40
|
-
* Account slug of the site owner,
|
|
45
|
+
* Account slug of the site owner, used in the standalone form's public URL.
|
|
41
46
|
*
|
|
42
|
-
*
|
|
43
|
-
*
|
|
47
|
+
* The standalone form's public URL is:
|
|
48
|
+
* - `https://{accountSlug}.wixforms.com/f/{id}` when `accountSlug` is set.
|
|
49
|
+
* - `https://www.wixforms.com/f/{id}` when `accountSlug` is empty.
|
|
50
|
+
*
|
|
51
|
+
* Set when the standalone form is created and doesn't change afterward.
|
|
44
52
|
* @maxLength 50
|
|
45
53
|
* @readonly
|
|
46
54
|
*/
|
|
@@ -50,38 +58,38 @@ interface GetOrCreateFormStandaloneMetaSiteRequest {
|
|
|
50
58
|
}
|
|
51
59
|
interface GetOrCreateFormStandaloneMetaSiteResponse {
|
|
52
60
|
/**
|
|
53
|
-
*
|
|
61
|
+
* Meta site ID.
|
|
54
62
|
* @format GUID
|
|
55
63
|
*/
|
|
56
64
|
metaSiteId?: string;
|
|
57
65
|
}
|
|
58
66
|
interface CreateStandaloneFormRequest {
|
|
59
|
-
/** Standalone form */
|
|
67
|
+
/** Standalone form to create. */
|
|
60
68
|
standaloneForm: StandaloneForm;
|
|
61
69
|
}
|
|
62
70
|
interface CreateStandaloneFormResponse {
|
|
63
|
-
/**
|
|
71
|
+
/** Created standalone form. */
|
|
64
72
|
standaloneForm?: StandaloneForm;
|
|
65
73
|
}
|
|
66
74
|
interface GetStandaloneFormRequest {
|
|
67
75
|
/**
|
|
68
|
-
*
|
|
76
|
+
* ID of the standalone form to retrieve.
|
|
69
77
|
* @maxLength 36
|
|
70
78
|
*/
|
|
71
79
|
standaloneFormId: string;
|
|
72
80
|
}
|
|
73
81
|
interface GetStandaloneFormResponse {
|
|
74
|
-
/**
|
|
82
|
+
/** Retrieved standalone form. */
|
|
75
83
|
standaloneForm?: StandaloneForm;
|
|
76
84
|
}
|
|
77
85
|
interface DeleteStandaloneFormRequest {
|
|
78
86
|
/**
|
|
79
|
-
*
|
|
87
|
+
* ID of the standalone form to delete.
|
|
80
88
|
* @maxLength 36
|
|
81
89
|
*/
|
|
82
90
|
standaloneFormId: string;
|
|
83
91
|
/**
|
|
84
|
-
* Whether to permanently delete
|
|
92
|
+
* Whether to permanently delete the standalone form instead of moving it to the trash bin.
|
|
85
93
|
*
|
|
86
94
|
* Default: `false`
|
|
87
95
|
*/
|
|
@@ -91,7 +99,7 @@ interface DeleteStandaloneFormResponse {
|
|
|
91
99
|
}
|
|
92
100
|
interface RemoveStandaloneFormFromTrashBinRequest {
|
|
93
101
|
/**
|
|
94
|
-
*
|
|
102
|
+
* ID of the standalone form to permanently delete.
|
|
95
103
|
* @maxLength 36
|
|
96
104
|
*/
|
|
97
105
|
standaloneFormId: string;
|
|
@@ -100,34 +108,36 @@ interface RemoveStandaloneFormFromTrashBinResponse {
|
|
|
100
108
|
}
|
|
101
109
|
interface RestoreStandaloneFormFromTrashBinRequest {
|
|
102
110
|
/**
|
|
103
|
-
*
|
|
111
|
+
* ID of the standalone form to restore.
|
|
104
112
|
* @maxLength 36
|
|
105
113
|
*/
|
|
106
114
|
standaloneFormId: string;
|
|
107
115
|
}
|
|
108
116
|
interface RestoreStandaloneFormFromTrashBinResponse {
|
|
109
|
-
/**
|
|
117
|
+
/** Restored standalone form. */
|
|
110
118
|
standaloneForm?: StandaloneForm;
|
|
111
119
|
}
|
|
112
120
|
interface GetDeletedStandaloneFormRequest {
|
|
113
121
|
/**
|
|
114
|
-
*
|
|
122
|
+
* ID of the standalone form to retrieve from the trash bin.
|
|
115
123
|
* @maxLength 36
|
|
116
124
|
*/
|
|
117
125
|
standaloneFormId: string;
|
|
118
126
|
}
|
|
119
127
|
interface GetDeletedStandaloneFormResponse {
|
|
120
|
-
/**
|
|
128
|
+
/** Retrieved standalone form. */
|
|
121
129
|
standaloneForm?: StandaloneForm;
|
|
122
130
|
}
|
|
123
131
|
interface ListDeletedStandaloneFormsRequest {
|
|
124
132
|
/**
|
|
125
|
-
*
|
|
133
|
+
* IDs of the standalone forms to retrieve from the trash bin.
|
|
134
|
+
*
|
|
135
|
+
* Default: All standalone forms in the trash bin.
|
|
126
136
|
* @maxSize 100
|
|
127
137
|
* @maxLength 36
|
|
128
138
|
*/
|
|
129
139
|
standaloneFormIds?: string[];
|
|
130
|
-
/** Cursor
|
|
140
|
+
/** Cursor paging options. */
|
|
131
141
|
paging?: CursorPaging;
|
|
132
142
|
}
|
|
133
143
|
interface CursorPaging {
|
|
@@ -148,11 +158,11 @@ interface CursorPaging {
|
|
|
148
158
|
}
|
|
149
159
|
interface ListDeletedStandaloneFormsResponse {
|
|
150
160
|
/**
|
|
151
|
-
*
|
|
161
|
+
* Retrieved standalone forms.
|
|
152
162
|
* @maxSize 100
|
|
153
163
|
*/
|
|
154
164
|
standaloneForms?: StandaloneForm[];
|
|
155
|
-
/**
|
|
165
|
+
/** Paging metadata. */
|
|
156
166
|
pagingMetadata?: CursorPagingMetadata;
|
|
157
167
|
}
|
|
158
168
|
interface CursorPagingMetadata {
|
|
@@ -180,7 +190,7 @@ interface Cursors {
|
|
|
180
190
|
prev?: string | null;
|
|
181
191
|
}
|
|
182
192
|
interface QueryStandaloneFormsRequest {
|
|
183
|
-
/**
|
|
193
|
+
/** Query options. See [API Query Language](https://dev.wix.com/docs/api-reference/articles/work-with-wix-apis/data-retrieval/about-the-wix-api-query-language) for more information. */
|
|
184
194
|
query: CursorQuery;
|
|
185
195
|
}
|
|
186
196
|
interface CursorQuery extends CursorQueryPagingMethodOneOf {
|
|
@@ -224,21 +234,26 @@ declare enum SortOrder {
|
|
|
224
234
|
type SortOrderWithLiterals = SortOrder | 'ASC' | 'DESC';
|
|
225
235
|
interface QueryStandaloneFormsResponse {
|
|
226
236
|
/**
|
|
227
|
-
*
|
|
237
|
+
* Retrieved standalone forms.
|
|
228
238
|
* @maxSize 100
|
|
229
239
|
*/
|
|
230
240
|
standaloneForms?: StandaloneForm[];
|
|
231
|
-
/**
|
|
241
|
+
/** Paging metadata. */
|
|
232
242
|
metadata?: CursorPagingMetadata;
|
|
233
243
|
}
|
|
234
244
|
interface GetSitePropertiesRequest {
|
|
235
245
|
}
|
|
236
246
|
interface GetSitePropertiesResponse {
|
|
237
|
-
/**
|
|
247
|
+
/** Site's currency and locale. */
|
|
238
248
|
siteProperties?: StandaloneMetaSiteProperties;
|
|
239
249
|
}
|
|
250
|
+
/** Currency and locale settings of a site. */
|
|
240
251
|
interface StandaloneMetaSiteProperties {
|
|
241
|
-
/**
|
|
252
|
+
/**
|
|
253
|
+
* Three-letter currency code in [ISO-4217 alphabetic](https://en.wikipedia.org/wiki/ISO_4217#Active_codes) format.
|
|
254
|
+
*
|
|
255
|
+
* Empty if the site's payment currency isn't set.
|
|
256
|
+
*/
|
|
242
257
|
paymentCurrency?: string | null;
|
|
243
258
|
/**
|
|
244
259
|
* Two-letter language code in [ISO 639-1 alpha-2](https://en.wikipedia.org/wiki/List_of_ISO_639-1_codes) format.
|
|
@@ -1264,41 +1279,51 @@ type GetSitePropertiesApplicationErrors = {
|
|
|
1264
1279
|
data?: Record<string, any>;
|
|
1265
1280
|
};
|
|
1266
1281
|
/**
|
|
1267
|
-
*
|
|
1268
|
-
*
|
|
1282
|
+
* Creates a standalone form, which marks a form as standalone so responders can reach it at its own public URL.
|
|
1283
|
+
*
|
|
1284
|
+
* The form must already exist. Create it with [Create Form](https://dev.wix.com/docs/api-reference/crm/forms/form-schemas/create-form) first. The standalone form is owned by
|
|
1285
|
+
* the site your request is authorized for. Each form can be marked standalone once per site.
|
|
1269
1286
|
*
|
|
1270
|
-
* The
|
|
1271
|
-
*
|
|
1272
|
-
*
|
|
1287
|
+
* The response includes the `id` and `accountSlug` that make up the standalone form's public URL.
|
|
1288
|
+
*
|
|
1289
|
+
* To stop hosting the form as standalone, call [Delete Standalone Form](https://dev.wix.com/docs/api-reference/crm/forms/standalone-form-v1/delete-standalone-form).
|
|
1290
|
+
* @param standaloneForm - Standalone form to create.
|
|
1273
1291
|
* @public
|
|
1274
1292
|
* @documentationMaturity preview
|
|
1275
1293
|
* @requiredField standaloneForm
|
|
1276
1294
|
* @requiredField standaloneForm.formId
|
|
1277
1295
|
* @permissionId WIX_FORMS.STANDALONE_FORM_CREATE
|
|
1278
1296
|
* @applicableIdentity APP
|
|
1279
|
-
* @returns
|
|
1297
|
+
* @returns Created standalone form.
|
|
1280
1298
|
* @fqn wix.forms.v1.FormStandaloneService.CreateStandaloneForm
|
|
1281
1299
|
*/
|
|
1282
1300
|
declare function createStandaloneForm(standaloneForm: NonNullablePaths<StandaloneForm, `formId`, 0>): Promise<StandaloneForm & {
|
|
1283
1301
|
__applicationErrorsType?: CreateStandaloneFormApplicationErrors;
|
|
1284
1302
|
}>;
|
|
1285
1303
|
/**
|
|
1286
|
-
* Retrieves a standalone form
|
|
1287
|
-
*
|
|
1304
|
+
* Retrieves a standalone form.
|
|
1305
|
+
*
|
|
1306
|
+
* To retrieve the form's fields and settings, pass the returned `formId` to [Get Form](https://dev.wix.com/docs/api-reference/crm/forms/form-schemas/get-form).
|
|
1307
|
+
* @param standaloneFormId - ID of the standalone form to retrieve.
|
|
1288
1308
|
* @public
|
|
1289
1309
|
* @documentationMaturity preview
|
|
1290
1310
|
* @requiredField standaloneFormId
|
|
1291
1311
|
* @permissionId WIX_FORMS.STANDALONE_FORM_READ
|
|
1292
1312
|
* @applicableIdentity APP
|
|
1293
|
-
* @returns
|
|
1313
|
+
* @returns Retrieved standalone form.
|
|
1294
1314
|
* @fqn wix.forms.v1.FormStandaloneService.GetStandaloneForm
|
|
1295
1315
|
*/
|
|
1296
1316
|
declare function getStandaloneForm(standaloneFormId: string): Promise<StandaloneForm>;
|
|
1297
1317
|
/**
|
|
1298
|
-
* Deletes a standalone form
|
|
1318
|
+
* Deletes a standalone form.
|
|
1319
|
+
*
|
|
1320
|
+
* Deleting a standalone form means the form is no longer standalone. The form itself isn't deleted.
|
|
1299
1321
|
*
|
|
1300
|
-
* By default the
|
|
1301
|
-
*
|
|
1322
|
+
* By default, the standalone form is moved to the trash bin. From there, you can restore it with
|
|
1323
|
+
* [Restore Standalone Form From Trash Bin](https://dev.wix.com/docs/api-reference/crm/forms/standalone-form-v1/restore-standalone-form-from-trash-bin) or permanently delete it with
|
|
1324
|
+
* [Remove Standalone Form From Trash Bin](https://dev.wix.com/docs/api-reference/crm/forms/standalone-form-v1/remove-standalone-form-from-trash-bin). To permanently delete the standalone form right away, set
|
|
1325
|
+
* `permanent` to `true`.
|
|
1326
|
+
* @param standaloneFormId - ID of the standalone form to delete.
|
|
1302
1327
|
* @public
|
|
1303
1328
|
* @documentationMaturity preview
|
|
1304
1329
|
* @requiredField standaloneFormId
|
|
@@ -1309,15 +1334,17 @@ declare function getStandaloneForm(standaloneFormId: string): Promise<Standalone
|
|
|
1309
1334
|
declare function deleteStandaloneForm(standaloneFormId: string, options?: DeleteStandaloneFormOptions): Promise<void>;
|
|
1310
1335
|
interface DeleteStandaloneFormOptions {
|
|
1311
1336
|
/**
|
|
1312
|
-
* Whether to permanently delete
|
|
1337
|
+
* Whether to permanently delete the standalone form instead of moving it to the trash bin.
|
|
1313
1338
|
*
|
|
1314
1339
|
* Default: `false`
|
|
1315
1340
|
*/
|
|
1316
1341
|
permanent?: boolean;
|
|
1317
1342
|
}
|
|
1318
1343
|
/**
|
|
1319
|
-
* Permanently deletes a standalone form
|
|
1320
|
-
*
|
|
1344
|
+
* Permanently deletes a standalone form from the trash bin.
|
|
1345
|
+
*
|
|
1346
|
+
* To move a standalone form to the trash bin, call [Delete Standalone Form](https://dev.wix.com/docs/api-reference/crm/forms/standalone-form-v1/delete-standalone-form).
|
|
1347
|
+
* @param standaloneFormId - ID of the standalone form to permanently delete.
|
|
1321
1348
|
* @public
|
|
1322
1349
|
* @documentationMaturity preview
|
|
1323
1350
|
* @requiredField standaloneFormId
|
|
@@ -1327,8 +1354,10 @@ interface DeleteStandaloneFormOptions {
|
|
|
1327
1354
|
*/
|
|
1328
1355
|
declare function removeStandaloneFormFromTrashBin(standaloneFormId: string): Promise<void>;
|
|
1329
1356
|
/**
|
|
1330
|
-
* Restores a standalone form
|
|
1331
|
-
*
|
|
1357
|
+
* Restores a standalone form from the trash bin.
|
|
1358
|
+
*
|
|
1359
|
+
* The restored standalone form keeps its `id` and `accountSlug`, so its public URL works again.
|
|
1360
|
+
* @param standaloneFormId - ID of the standalone form to restore.
|
|
1332
1361
|
* @public
|
|
1333
1362
|
* @documentationMaturity preview
|
|
1334
1363
|
* @requiredField standaloneFormId
|
|
@@ -1338,8 +1367,8 @@ declare function removeStandaloneFormFromTrashBin(standaloneFormId: string): Pro
|
|
|
1338
1367
|
*/
|
|
1339
1368
|
declare function restoreStandaloneFormFromTrashBin(standaloneFormId: string): Promise<RestoreStandaloneFormFromTrashBinResponse>;
|
|
1340
1369
|
/**
|
|
1341
|
-
* Retrieves a standalone form
|
|
1342
|
-
* @param standaloneFormId -
|
|
1370
|
+
* Retrieves a standalone form from the trash bin.
|
|
1371
|
+
* @param standaloneFormId - ID of the standalone form to retrieve from the trash bin.
|
|
1343
1372
|
* @public
|
|
1344
1373
|
* @documentationMaturity preview
|
|
1345
1374
|
* @requiredField standaloneFormId
|
|
@@ -1349,7 +1378,9 @@ declare function restoreStandaloneFormFromTrashBin(standaloneFormId: string): Pr
|
|
|
1349
1378
|
*/
|
|
1350
1379
|
declare function getDeletedStandaloneForm(standaloneFormId: string): Promise<GetDeletedStandaloneFormResponse>;
|
|
1351
1380
|
/**
|
|
1352
|
-
* Retrieves a list of standalone
|
|
1381
|
+
* Retrieves a list of standalone forms in the trash bin.
|
|
1382
|
+
*
|
|
1383
|
+
* To retrieve specific standalone forms, specify their IDs in `standaloneFormIds`.
|
|
1353
1384
|
* @public
|
|
1354
1385
|
* @documentationMaturity preview
|
|
1355
1386
|
* @permissionId WIX_FORMS.STANDALONE_FORM_READ
|
|
@@ -1359,19 +1390,31 @@ declare function getDeletedStandaloneForm(standaloneFormId: string): Promise<Get
|
|
|
1359
1390
|
declare function listDeletedStandaloneForms(options?: ListDeletedStandaloneFormsOptions): Promise<NonNullablePaths<ListDeletedStandaloneFormsResponse, `standaloneForms`, 0>>;
|
|
1360
1391
|
interface ListDeletedStandaloneFormsOptions {
|
|
1361
1392
|
/**
|
|
1362
|
-
*
|
|
1393
|
+
* IDs of the standalone forms to retrieve from the trash bin.
|
|
1394
|
+
*
|
|
1395
|
+
* Default: All standalone forms in the trash bin.
|
|
1363
1396
|
* @maxSize 100
|
|
1364
1397
|
* @maxLength 36
|
|
1365
1398
|
*/
|
|
1366
1399
|
standaloneFormIds?: string[];
|
|
1367
|
-
/** Cursor
|
|
1400
|
+
/** Cursor paging options. */
|
|
1368
1401
|
paging?: CursorPaging;
|
|
1369
1402
|
}
|
|
1370
1403
|
/**
|
|
1371
|
-
* Retrieves a list of standalone forms, given the provided
|
|
1404
|
+
* Retrieves a list of up to 100 standalone forms, given the provided paging, filtering, and sorting.
|
|
1405
|
+
*
|
|
1406
|
+
* Query Standalone Forms runs with these defaults, which you can override:
|
|
1407
|
+
*
|
|
1408
|
+
* - `createdDate` is sorted in `DESC` order
|
|
1409
|
+
* - `cursorPaging.limit` is `50`
|
|
1410
|
+
*
|
|
1411
|
+
* Supported properties for filtering and sorting: `id`, `formId`, `metaSiteId`, `createdDate`, `updatedDate`.
|
|
1372
1412
|
*
|
|
1373
|
-
*
|
|
1374
|
-
*
|
|
1413
|
+
* To learn about working with Query methods, see
|
|
1414
|
+
* [API Query Language](https://dev.wix.com/docs/api-reference/articles/work-with-wix-apis/data-retrieval/about-the-wix-api-query-language),
|
|
1415
|
+
* [Sorting and Paging](https://dev.wix.com/docs/api-reference/articles/work-with-wix-apis/data-retrieval/about-sorting-and-paging),
|
|
1416
|
+
* and [Field Projection](https://dev.wix.com/docs/api-reference/articles/work-with-wix-apis/data-retrieval/about-field-projection).
|
|
1417
|
+
* @param query - Query options. See [API Query Language](https://dev.wix.com/docs/api-reference/articles/work-with-wix-apis/data-retrieval/about-the-wix-api-query-language) for more information.
|
|
1375
1418
|
* @public
|
|
1376
1419
|
* @documentationMaturity preview
|
|
1377
1420
|
* @requiredField query
|
|
@@ -1381,9 +1424,10 @@ interface ListDeletedStandaloneFormsOptions {
|
|
|
1381
1424
|
*/
|
|
1382
1425
|
declare function queryStandaloneForms(query: CursorQuery): Promise<NonNullablePaths<QueryStandaloneFormsResponse, `standaloneForms`, 0>>;
|
|
1383
1426
|
/**
|
|
1384
|
-
*
|
|
1427
|
+
* Retrieves the currency and locale of the site your request is authorized for.
|
|
1385
1428
|
*
|
|
1386
|
-
*
|
|
1429
|
+
* Use these values to display prices and labels correctly when you render a standalone form. Results may be cached,
|
|
1430
|
+
* so recent changes to the site's settings might not appear right away.
|
|
1387
1431
|
* @public
|
|
1388
1432
|
* @documentationMaturity preview
|
|
1389
1433
|
* @permissionId WIX_FORMS.STANDALONE_FORM_READ
|
|
@@ -1,28 +1,33 @@
|
|
|
1
1
|
import { CreateStandaloneFormRequest as CreateStandaloneFormRequest$1, CreateStandaloneFormResponse as CreateStandaloneFormResponse$1, GetStandaloneFormRequest as GetStandaloneFormRequest$1, GetStandaloneFormResponse as GetStandaloneFormResponse$1, DeleteStandaloneFormRequest as DeleteStandaloneFormRequest$1, DeleteStandaloneFormResponse as DeleteStandaloneFormResponse$1, RemoveStandaloneFormFromTrashBinRequest as RemoveStandaloneFormFromTrashBinRequest$1, RemoveStandaloneFormFromTrashBinResponse as RemoveStandaloneFormFromTrashBinResponse$1, RestoreStandaloneFormFromTrashBinRequest as RestoreStandaloneFormFromTrashBinRequest$1, RestoreStandaloneFormFromTrashBinResponse as RestoreStandaloneFormFromTrashBinResponse$1, GetDeletedStandaloneFormRequest as GetDeletedStandaloneFormRequest$1, GetDeletedStandaloneFormResponse as GetDeletedStandaloneFormResponse$1, ListDeletedStandaloneFormsRequest as ListDeletedStandaloneFormsRequest$1, ListDeletedStandaloneFormsResponse as ListDeletedStandaloneFormsResponse$1, QueryStandaloneFormsRequest as QueryStandaloneFormsRequest$1, QueryStandaloneFormsResponse as QueryStandaloneFormsResponse$1, GetSitePropertiesRequest as GetSitePropertiesRequest$1, GetSitePropertiesResponse as GetSitePropertiesResponse$1 } from './index.typings.js';
|
|
2
2
|
import '@wix/sdk-types';
|
|
3
3
|
|
|
4
|
+
/**
|
|
5
|
+
* A standalone form marks a [form](https://dev.wix.com/docs/api-reference/crm/forms/form-schemas/introduction) as standalone, so responders can reach it at its own public URL
|
|
6
|
+
* instead of on a Wix site.
|
|
7
|
+
*
|
|
8
|
+
* A form doesn't indicate whether it's standalone. A standalone form that references the form is what makes it
|
|
9
|
+
* standalone.
|
|
10
|
+
*/
|
|
4
11
|
interface StandaloneForm {
|
|
5
12
|
/**
|
|
6
|
-
* Standalone form ID.
|
|
13
|
+
* Standalone form ID.
|
|
7
14
|
*
|
|
8
|
-
*
|
|
15
|
+
* Used in the standalone form's public URL. See `accountSlug` for the URL format.
|
|
9
16
|
* @maxLength 36
|
|
10
17
|
* @readonly
|
|
11
18
|
*/
|
|
12
19
|
id?: string | null;
|
|
13
20
|
/**
|
|
14
|
-
* ID of the form
|
|
21
|
+
* ID of the [form](https://dev.wix.com/docs/api-reference/crm/forms/form-schemas/introduction) that the standalone form marks as standalone.
|
|
15
22
|
*
|
|
16
|
-
*
|
|
17
|
-
* record that references it is what makes the form standalone.
|
|
23
|
+
* The form must exist before you create the standalone form.
|
|
18
24
|
* @format GUID
|
|
19
25
|
*/
|
|
20
26
|
formId?: string | null;
|
|
21
27
|
/**
|
|
22
|
-
* ID of the
|
|
28
|
+
* ID of the site that owns the standalone form.
|
|
23
29
|
*
|
|
24
|
-
*
|
|
25
|
-
* meta site is stored explicitly in this field. Set from the calling context when the form is created.
|
|
30
|
+
* Set to the site your request is authorized for when the standalone form is created.
|
|
26
31
|
* @format GUID
|
|
27
32
|
* @readonly
|
|
28
33
|
*/
|
|
@@ -38,10 +43,13 @@ interface StandaloneForm {
|
|
|
38
43
|
*/
|
|
39
44
|
updatedDate?: Date | null;
|
|
40
45
|
/**
|
|
41
|
-
* Account slug of the site owner,
|
|
46
|
+
* Account slug of the site owner, used in the standalone form's public URL.
|
|
42
47
|
*
|
|
43
|
-
*
|
|
44
|
-
*
|
|
48
|
+
* The standalone form's public URL is:
|
|
49
|
+
* - `https://{accountSlug}.wixforms.com/f/{id}` when `accountSlug` is set.
|
|
50
|
+
* - `https://www.wixforms.com/f/{id}` when `accountSlug` is empty.
|
|
51
|
+
*
|
|
52
|
+
* Set when the standalone form is created and doesn't change afterward.
|
|
45
53
|
* @maxLength 50
|
|
46
54
|
* @readonly
|
|
47
55
|
*/
|
|
@@ -51,38 +59,38 @@ interface GetOrCreateFormStandaloneMetaSiteRequest {
|
|
|
51
59
|
}
|
|
52
60
|
interface GetOrCreateFormStandaloneMetaSiteResponse {
|
|
53
61
|
/**
|
|
54
|
-
*
|
|
62
|
+
* Meta site ID.
|
|
55
63
|
* @format GUID
|
|
56
64
|
*/
|
|
57
65
|
metaSiteId?: string;
|
|
58
66
|
}
|
|
59
67
|
interface CreateStandaloneFormRequest {
|
|
60
|
-
/** Standalone form */
|
|
68
|
+
/** Standalone form to create. */
|
|
61
69
|
standaloneForm: StandaloneForm;
|
|
62
70
|
}
|
|
63
71
|
interface CreateStandaloneFormResponse {
|
|
64
|
-
/**
|
|
72
|
+
/** Created standalone form. */
|
|
65
73
|
standaloneForm?: StandaloneForm;
|
|
66
74
|
}
|
|
67
75
|
interface GetStandaloneFormRequest {
|
|
68
76
|
/**
|
|
69
|
-
*
|
|
77
|
+
* ID of the standalone form to retrieve.
|
|
70
78
|
* @maxLength 36
|
|
71
79
|
*/
|
|
72
80
|
standaloneFormId: string;
|
|
73
81
|
}
|
|
74
82
|
interface GetStandaloneFormResponse {
|
|
75
|
-
/**
|
|
83
|
+
/** Retrieved standalone form. */
|
|
76
84
|
standaloneForm?: StandaloneForm;
|
|
77
85
|
}
|
|
78
86
|
interface DeleteStandaloneFormRequest {
|
|
79
87
|
/**
|
|
80
|
-
*
|
|
88
|
+
* ID of the standalone form to delete.
|
|
81
89
|
* @maxLength 36
|
|
82
90
|
*/
|
|
83
91
|
standaloneFormId: string;
|
|
84
92
|
/**
|
|
85
|
-
* Whether to permanently delete
|
|
93
|
+
* Whether to permanently delete the standalone form instead of moving it to the trash bin.
|
|
86
94
|
*
|
|
87
95
|
* Default: `false`
|
|
88
96
|
*/
|
|
@@ -92,7 +100,7 @@ interface DeleteStandaloneFormResponse {
|
|
|
92
100
|
}
|
|
93
101
|
interface RemoveStandaloneFormFromTrashBinRequest {
|
|
94
102
|
/**
|
|
95
|
-
*
|
|
103
|
+
* ID of the standalone form to permanently delete.
|
|
96
104
|
* @maxLength 36
|
|
97
105
|
*/
|
|
98
106
|
standaloneFormId: string;
|
|
@@ -101,34 +109,36 @@ interface RemoveStandaloneFormFromTrashBinResponse {
|
|
|
101
109
|
}
|
|
102
110
|
interface RestoreStandaloneFormFromTrashBinRequest {
|
|
103
111
|
/**
|
|
104
|
-
*
|
|
112
|
+
* ID of the standalone form to restore.
|
|
105
113
|
* @maxLength 36
|
|
106
114
|
*/
|
|
107
115
|
standaloneFormId: string;
|
|
108
116
|
}
|
|
109
117
|
interface RestoreStandaloneFormFromTrashBinResponse {
|
|
110
|
-
/**
|
|
118
|
+
/** Restored standalone form. */
|
|
111
119
|
standaloneForm?: StandaloneForm;
|
|
112
120
|
}
|
|
113
121
|
interface GetDeletedStandaloneFormRequest {
|
|
114
122
|
/**
|
|
115
|
-
*
|
|
123
|
+
* ID of the standalone form to retrieve from the trash bin.
|
|
116
124
|
* @maxLength 36
|
|
117
125
|
*/
|
|
118
126
|
standaloneFormId: string;
|
|
119
127
|
}
|
|
120
128
|
interface GetDeletedStandaloneFormResponse {
|
|
121
|
-
/**
|
|
129
|
+
/** Retrieved standalone form. */
|
|
122
130
|
standaloneForm?: StandaloneForm;
|
|
123
131
|
}
|
|
124
132
|
interface ListDeletedStandaloneFormsRequest {
|
|
125
133
|
/**
|
|
126
|
-
*
|
|
134
|
+
* IDs of the standalone forms to retrieve from the trash bin.
|
|
135
|
+
*
|
|
136
|
+
* Default: All standalone forms in the trash bin.
|
|
127
137
|
* @maxSize 100
|
|
128
138
|
* @maxLength 36
|
|
129
139
|
*/
|
|
130
140
|
standaloneFormIds?: string[];
|
|
131
|
-
/** Cursor
|
|
141
|
+
/** Cursor paging options. */
|
|
132
142
|
paging?: CursorPaging;
|
|
133
143
|
}
|
|
134
144
|
interface CursorPaging {
|
|
@@ -149,11 +159,11 @@ interface CursorPaging {
|
|
|
149
159
|
}
|
|
150
160
|
interface ListDeletedStandaloneFormsResponse {
|
|
151
161
|
/**
|
|
152
|
-
*
|
|
162
|
+
* Retrieved standalone forms.
|
|
153
163
|
* @maxSize 100
|
|
154
164
|
*/
|
|
155
165
|
standaloneForms?: StandaloneForm[];
|
|
156
|
-
/**
|
|
166
|
+
/** Paging metadata. */
|
|
157
167
|
pagingMetadata?: CursorPagingMetadata;
|
|
158
168
|
}
|
|
159
169
|
interface CursorPagingMetadata {
|
|
@@ -181,7 +191,7 @@ interface Cursors {
|
|
|
181
191
|
prev?: string | null;
|
|
182
192
|
}
|
|
183
193
|
interface QueryStandaloneFormsRequest {
|
|
184
|
-
/**
|
|
194
|
+
/** Query options. See [API Query Language](https://dev.wix.com/docs/api-reference/articles/work-with-wix-apis/data-retrieval/about-the-wix-api-query-language) for more information. */
|
|
185
195
|
query: CursorQuery;
|
|
186
196
|
}
|
|
187
197
|
interface CursorQuery extends CursorQueryPagingMethodOneOf {
|
|
@@ -225,21 +235,26 @@ declare enum SortOrder {
|
|
|
225
235
|
type SortOrderWithLiterals = SortOrder | 'ASC' | 'DESC';
|
|
226
236
|
interface QueryStandaloneFormsResponse {
|
|
227
237
|
/**
|
|
228
|
-
*
|
|
238
|
+
* Retrieved standalone forms.
|
|
229
239
|
* @maxSize 100
|
|
230
240
|
*/
|
|
231
241
|
standaloneForms?: StandaloneForm[];
|
|
232
|
-
/**
|
|
242
|
+
/** Paging metadata. */
|
|
233
243
|
metadata?: CursorPagingMetadata;
|
|
234
244
|
}
|
|
235
245
|
interface GetSitePropertiesRequest {
|
|
236
246
|
}
|
|
237
247
|
interface GetSitePropertiesResponse {
|
|
238
|
-
/**
|
|
248
|
+
/** Site's currency and locale. */
|
|
239
249
|
siteProperties?: StandaloneMetaSiteProperties;
|
|
240
250
|
}
|
|
251
|
+
/** Currency and locale settings of a site. */
|
|
241
252
|
interface StandaloneMetaSiteProperties {
|
|
242
|
-
/**
|
|
253
|
+
/**
|
|
254
|
+
* Three-letter currency code in [ISO-4217 alphabetic](https://en.wikipedia.org/wiki/ISO_4217#Active_codes) format.
|
|
255
|
+
*
|
|
256
|
+
* Empty if the site's payment currency isn't set.
|
|
257
|
+
*/
|
|
243
258
|
paymentCurrency?: string | null;
|
|
244
259
|
/**
|
|
245
260
|
* Two-letter language code in [ISO 639-1 alpha-2](https://en.wikipedia.org/wiki/List_of_ISO_639-1_codes) format.
|