@wix/auto_sdk_standalone-forms_standalone-forms 1.0.0 → 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 +54 -39
- package/build/cjs/index.js +15 -83
- package/build/cjs/index.js.map +1 -1
- package/build/cjs/index.typings.d.ts +103 -71
- package/build/cjs/index.typings.js +15 -76
- package/build/cjs/index.typings.js.map +1 -1
- package/build/cjs/meta.d.ts +49 -35
- package/build/cjs/meta.js +15 -71
- package/build/cjs/meta.js.map +1 -1
- package/build/es/index.d.mts +54 -39
- package/build/es/index.mjs +15 -82
- package/build/es/index.mjs.map +1 -1
- package/build/es/index.typings.d.mts +103 -71
- package/build/es/index.typings.mjs +15 -75
- package/build/es/index.typings.mjs.map +1 -1
- package/build/es/meta.d.mts +49 -35
- package/build/es/meta.mjs +15 -70
- package/build/es/meta.mjs.map +1 -1
- package/build/internal/cjs/index.d.ts +54 -39
- package/build/internal/cjs/index.typings.d.ts +103 -71
- package/build/internal/cjs/meta.d.ts +49 -35
- package/build/internal/es/index.d.mts +54 -39
- package/build/internal/es/index.typings.d.mts +103 -71
- package/build/internal/es/meta.d.mts +49 -35
- package/package.json +2 -2
package/build/cjs/index.d.ts
CHANGED
|
@@ -1,28 +1,20 @@
|
|
|
1
1
|
import { HttpClient, NonNullablePaths, MaybeContext, BuildRESTFunction } from '@wix/sdk-types';
|
|
2
|
-
import {
|
|
3
|
-
export { AccountInfo, ActionEvent, Address, AddressHint, Asset, BusinessSchedule, Categories, ChangeContext, ChangeContextPayloadOneOf, ConsentPolicy, CreateStandaloneFormRequest, CreateStandaloneFormResponse, CursorPaging, CursorPagingMetadata, CursorQueryPagingMethodOneOf, Cursors, DayOfWeek, DayOfWeekWithLiterals, DeleteContext, DeleteStandaloneFormRequest, DeleteStandaloneFormResponse, DeleteStatus, DeleteStatusWithLiterals, DomainEvent, DomainEventBodyOneOf, EditorlessAssigned, EditorlessUnassigned, Empty, EntityCreatedEvent, EntityDeletedEvent, EntityUpdatedEvent, GeoCoordinates, GetDeletedStandaloneFormRequest, GetOrCreateFormStandaloneMetaSiteRequest, GetSitePropertiesRequest, GetStandaloneFormRequest, GetStandaloneFormResponse, IdentificationData, IdentificationDataIdOneOf, ListDeletedStandaloneFormsRequest, Locale, MessageEnvelope, MetaSiteSpecialEvent, MetaSiteSpecialEventPayloadOneOf, Multilingual, Namespace, NamespaceChanged, NamespaceWithLiterals, OdeditorAssigned, OdeditorUnassigned, PicassoAssigned, PicassoUnassigned, PlacementType, PlacementTypeWithLiterals, Properties, PropertiesChange, QueryStandaloneFormsRequest, RemoveStandaloneFormFromTrashBinRequest, RemoveStandaloneFormFromTrashBinResponse, ResolutionMethod, ResolutionMethodWithLiterals, RestoreInfo, RestoreStandaloneFormFromTrashBinRequest, ServiceProvisioned, ServiceRemoved, SiteCloned, SiteCreated, SiteCreatedContext, SiteCreatedContextWithLiterals, SiteDeleted, SiteHardDeleted, SiteMarkedAsTemplate, SiteMarkedAsWixSite, SitePropertiesEvent, SitePropertiesNotification, SitePublished, SitePurgedExternally, SiteRenamed, SiteTransferred, SiteUndeleted, SiteUnpublished, SiteUrlChanged, SortOrder, SortOrderWithLiterals, Sorting, SpecialHourPeriod, StandaloneMetaSiteProperties, State, StateWithLiterals, StudioAssigned, StudioTwoAssigned, StudioTwoUnassigned, StudioUnassigned, SupportedLanguage, TimePeriod, Translation, UserDomainMediaDisabled, UserDomainMediaEnabled, V4SiteCreated, WebhookIdentityType, WebhookIdentityTypeWithLiterals, WixelAssigned, WixelUnassigned } from './index.typings.js';
|
|
2
|
+
import { StandaloneForm, CreateStandaloneFormApplicationErrors, DeleteStandaloneFormOptions, RestoreStandaloneFormFromTrashBinResponse, GetDeletedStandaloneFormResponse, ListDeletedStandaloneFormsOptions, ListDeletedStandaloneFormsResponse, CursorQuery, QueryStandaloneFormsResponse, GetSitePropertiesResponse, GetSitePropertiesApplicationErrors } from './index.typings.js';
|
|
3
|
+
export { AccountInfo, ActionEvent, Address, AddressHint, Asset, BusinessSchedule, Categories, ChangeContext, ChangeContextPayloadOneOf, ConsentPolicy, CreateStandaloneFormRequest, CreateStandaloneFormResponse, CursorPaging, CursorPagingMetadata, CursorQueryPagingMethodOneOf, Cursors, DayOfWeek, DayOfWeekWithLiterals, DeleteContext, DeleteStandaloneFormRequest, DeleteStandaloneFormResponse, DeleteStatus, DeleteStatusWithLiterals, DomainEvent, DomainEventBodyOneOf, EditorlessAssigned, EditorlessUnassigned, Empty, EntityCreatedEvent, EntityDeletedEvent, EntityUpdatedEvent, GeoCoordinates, GetDeletedStandaloneFormRequest, GetOrCreateFormStandaloneMetaSiteRequest, GetOrCreateFormStandaloneMetaSiteResponse, GetSitePropertiesRequest, GetStandaloneFormRequest, GetStandaloneFormResponse, IdentificationData, IdentificationDataIdOneOf, ListDeletedStandaloneFormsRequest, Locale, MessageEnvelope, MetaSiteSpecialEvent, MetaSiteSpecialEventPayloadOneOf, Multilingual, Namespace, NamespaceChanged, NamespaceWithLiterals, OdeditorAssigned, OdeditorUnassigned, PicassoAssigned, PicassoUnassigned, PlacementType, PlacementTypeWithLiterals, Properties, PropertiesChange, QueryStandaloneFormsRequest, RemoveStandaloneFormFromTrashBinRequest, RemoveStandaloneFormFromTrashBinResponse, ResolutionMethod, ResolutionMethodWithLiterals, RestoreInfo, RestoreStandaloneFormFromTrashBinRequest, ServiceProvisioned, ServiceRemoved, SiteCloned, SiteCreated, SiteCreatedContext, SiteCreatedContextWithLiterals, SiteDeleted, SiteHardDeleted, SiteMarkedAsTemplate, SiteMarkedAsWixSite, SitePropertiesEvent, SitePropertiesNotification, SitePublished, SitePurgedExternally, SiteRenamed, SiteTransferred, SiteUndeleted, SiteUnpublished, SiteUrlChanged, SortOrder, SortOrderWithLiterals, Sorting, SpecialHourPeriod, StandaloneMetaSiteProperties, State, StateWithLiterals, StudioAssigned, StudioTwoAssigned, StudioTwoUnassigned, StudioUnassigned, SupportedLanguage, TimePeriod, Translation, UserDomainMediaDisabled, UserDomainMediaEnabled, V4SiteCreated, WebhookIdentityType, WebhookIdentityTypeWithLiterals, WixelAssigned, WixelUnassigned } from './index.typings.js';
|
|
4
4
|
|
|
5
|
-
declare function getOrCreateFormStandaloneMetaSite$1(httpClient: HttpClient): GetOrCreateFormStandaloneMetaSiteSignature;
|
|
6
|
-
interface GetOrCreateFormStandaloneMetaSiteSignature {
|
|
7
|
-
/**
|
|
8
|
-
* Returns the standalone meta site owned by the caller's account, provisioning a new siteless
|
|
9
|
-
* meta site if one doesn't exist yet.
|
|
10
|
-
*
|
|
11
|
-
* Use this when the caller doesn't already have a meta site, for example when a form is built
|
|
12
|
-
* before the user becomes a Wix user. The returned meta site can then own standalone forms.
|
|
13
|
-
*/
|
|
14
|
-
(): Promise<NonNullablePaths<GetOrCreateFormStandaloneMetaSiteResponse, `metaSiteId`, 0>>;
|
|
15
|
-
}
|
|
16
5
|
declare function createStandaloneForm$1(httpClient: HttpClient): CreateStandaloneFormSignature;
|
|
17
6
|
interface CreateStandaloneFormSignature {
|
|
18
7
|
/**
|
|
19
|
-
*
|
|
20
|
-
* to the meta site that owns it.
|
|
8
|
+
* Creates a standalone form, which marks a form as standalone so responders can reach it at its own public URL.
|
|
21
9
|
*
|
|
22
|
-
* The form
|
|
23
|
-
*
|
|
24
|
-
*
|
|
25
|
-
*
|
|
10
|
+
* 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
|
|
11
|
+
* the site your request is authorized for. Each form can be marked standalone once per site.
|
|
12
|
+
*
|
|
13
|
+
* The response includes the `id` and `accountSlug` that make up the standalone form's public URL.
|
|
14
|
+
*
|
|
15
|
+
* 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).
|
|
16
|
+
* @param - Standalone form to create.
|
|
17
|
+
* @returns Created standalone form.
|
|
26
18
|
*/
|
|
27
19
|
(standaloneForm: NonNullablePaths<StandaloneForm, `formId`, 0>): Promise<StandaloneForm & {
|
|
28
20
|
__applicationErrorsType?: CreateStandaloneFormApplicationErrors;
|
|
@@ -31,76 +23,99 @@ interface CreateStandaloneFormSignature {
|
|
|
31
23
|
declare function getStandaloneForm$1(httpClient: HttpClient): GetStandaloneFormSignature;
|
|
32
24
|
interface GetStandaloneFormSignature {
|
|
33
25
|
/**
|
|
34
|
-
* Retrieves a standalone form
|
|
35
|
-
*
|
|
36
|
-
*
|
|
26
|
+
* Retrieves a standalone form.
|
|
27
|
+
*
|
|
28
|
+
* 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).
|
|
29
|
+
* @param - ID of the standalone form to retrieve.
|
|
30
|
+
* @returns Retrieved standalone form.
|
|
37
31
|
*/
|
|
38
32
|
(standaloneFormId: string): Promise<StandaloneForm>;
|
|
39
33
|
}
|
|
40
34
|
declare function deleteStandaloneForm$1(httpClient: HttpClient): DeleteStandaloneFormSignature;
|
|
41
35
|
interface DeleteStandaloneFormSignature {
|
|
42
36
|
/**
|
|
43
|
-
* Deletes a standalone form
|
|
37
|
+
* Deletes a standalone form.
|
|
44
38
|
*
|
|
45
|
-
*
|
|
46
|
-
*
|
|
39
|
+
* Deleting a standalone form means the form is no longer standalone. The form itself isn't deleted.
|
|
40
|
+
*
|
|
41
|
+
* By default, the standalone form is moved to the trash bin. From there, you can restore it with
|
|
42
|
+
* [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
|
|
43
|
+
* [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
|
|
44
|
+
* `permanent` to `true`.
|
|
45
|
+
* @param - ID of the standalone form to delete.
|
|
47
46
|
*/
|
|
48
47
|
(standaloneFormId: string, options?: DeleteStandaloneFormOptions): Promise<void>;
|
|
49
48
|
}
|
|
50
49
|
declare function removeStandaloneFormFromTrashBin$1(httpClient: HttpClient): RemoveStandaloneFormFromTrashBinSignature;
|
|
51
50
|
interface RemoveStandaloneFormFromTrashBinSignature {
|
|
52
51
|
/**
|
|
53
|
-
* Permanently deletes a standalone form
|
|
54
|
-
*
|
|
52
|
+
* Permanently deletes a standalone form from the trash bin.
|
|
53
|
+
*
|
|
54
|
+
* 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).
|
|
55
|
+
* @param - ID of the standalone form to permanently delete.
|
|
55
56
|
*/
|
|
56
57
|
(standaloneFormId: string): Promise<void>;
|
|
57
58
|
}
|
|
58
59
|
declare function restoreStandaloneFormFromTrashBin$1(httpClient: HttpClient): RestoreStandaloneFormFromTrashBinSignature;
|
|
59
60
|
interface RestoreStandaloneFormFromTrashBinSignature {
|
|
60
61
|
/**
|
|
61
|
-
* Restores a standalone form
|
|
62
|
-
*
|
|
62
|
+
* Restores a standalone form from the trash bin.
|
|
63
|
+
*
|
|
64
|
+
* The restored standalone form keeps its `id` and `accountSlug`, so its public URL works again.
|
|
65
|
+
* @param - ID of the standalone form to restore.
|
|
63
66
|
*/
|
|
64
67
|
(standaloneFormId: string): Promise<RestoreStandaloneFormFromTrashBinResponse>;
|
|
65
68
|
}
|
|
66
69
|
declare function getDeletedStandaloneForm$1(httpClient: HttpClient): GetDeletedStandaloneFormSignature;
|
|
67
70
|
interface GetDeletedStandaloneFormSignature {
|
|
68
71
|
/**
|
|
69
|
-
* Retrieves a standalone form
|
|
70
|
-
* @param -
|
|
72
|
+
* Retrieves a standalone form from the trash bin.
|
|
73
|
+
* @param - ID of the standalone form to retrieve from the trash bin.
|
|
71
74
|
*/
|
|
72
75
|
(standaloneFormId: string): Promise<GetDeletedStandaloneFormResponse>;
|
|
73
76
|
}
|
|
74
77
|
declare function listDeletedStandaloneForms$1(httpClient: HttpClient): ListDeletedStandaloneFormsSignature;
|
|
75
78
|
interface ListDeletedStandaloneFormsSignature {
|
|
76
79
|
/**
|
|
77
|
-
* Retrieves a list of standalone
|
|
80
|
+
* Retrieves a list of standalone forms in the trash bin.
|
|
81
|
+
*
|
|
82
|
+
* To retrieve specific standalone forms, specify their IDs in `standaloneFormIds`.
|
|
78
83
|
*/
|
|
79
84
|
(options?: ListDeletedStandaloneFormsOptions): Promise<NonNullablePaths<ListDeletedStandaloneFormsResponse, `standaloneForms`, 0>>;
|
|
80
85
|
}
|
|
81
86
|
declare function queryStandaloneForms$1(httpClient: HttpClient): QueryStandaloneFormsSignature;
|
|
82
87
|
interface QueryStandaloneFormsSignature {
|
|
83
88
|
/**
|
|
84
|
-
* Retrieves a list of standalone forms, given the provided
|
|
89
|
+
* Retrieves a list of up to 100 standalone forms, given the provided paging, filtering, and sorting.
|
|
90
|
+
*
|
|
91
|
+
* Query Standalone Forms runs with these defaults, which you can override:
|
|
92
|
+
*
|
|
93
|
+
* - `createdDate` is sorted in `DESC` order
|
|
94
|
+
* - `cursorPaging.limit` is `50`
|
|
95
|
+
*
|
|
96
|
+
* Supported properties for filtering and sorting: `id`, `formId`, `metaSiteId`, `createdDate`, `updatedDate`.
|
|
85
97
|
*
|
|
86
|
-
*
|
|
87
|
-
*
|
|
98
|
+
* To learn about working with Query methods, see
|
|
99
|
+
* [API Query Language](https://dev.wix.com/docs/api-reference/articles/work-with-wix-apis/data-retrieval/about-the-wix-api-query-language),
|
|
100
|
+
* [Sorting and Paging](https://dev.wix.com/docs/api-reference/articles/work-with-wix-apis/data-retrieval/about-sorting-and-paging),
|
|
101
|
+
* and [Field Projection](https://dev.wix.com/docs/api-reference/articles/work-with-wix-apis/data-retrieval/about-field-projection).
|
|
102
|
+
* @param - 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.
|
|
88
103
|
*/
|
|
89
104
|
(query: CursorQuery): Promise<NonNullablePaths<QueryStandaloneFormsResponse, `standaloneForms`, 0>>;
|
|
90
105
|
}
|
|
91
106
|
declare function getSiteProperties$1(httpClient: HttpClient): GetSitePropertiesSignature;
|
|
92
107
|
interface GetSitePropertiesSignature {
|
|
93
108
|
/**
|
|
94
|
-
*
|
|
109
|
+
* Retrieves the currency and locale of the site your request is authorized for.
|
|
95
110
|
*
|
|
96
|
-
*
|
|
111
|
+
* Use these values to display prices and labels correctly when you render a standalone form. Results may be cached,
|
|
112
|
+
* so recent changes to the site's settings might not appear right away.
|
|
97
113
|
*/
|
|
98
114
|
(): Promise<NonNullablePaths<GetSitePropertiesResponse, `siteProperties.localeLanguageCode` | `siteProperties.localeCountry`, 1> & {
|
|
99
115
|
__applicationErrorsType?: GetSitePropertiesApplicationErrors;
|
|
100
116
|
}>;
|
|
101
117
|
}
|
|
102
118
|
|
|
103
|
-
declare const getOrCreateFormStandaloneMetaSite: MaybeContext<BuildRESTFunction<typeof getOrCreateFormStandaloneMetaSite$1> & typeof getOrCreateFormStandaloneMetaSite$1>;
|
|
104
119
|
declare const createStandaloneForm: MaybeContext<BuildRESTFunction<typeof createStandaloneForm$1> & typeof createStandaloneForm$1>;
|
|
105
120
|
declare const getStandaloneForm: MaybeContext<BuildRESTFunction<typeof getStandaloneForm$1> & typeof getStandaloneForm$1>;
|
|
106
121
|
declare const deleteStandaloneForm: MaybeContext<BuildRESTFunction<typeof deleteStandaloneForm$1> & typeof deleteStandaloneForm$1>;
|
|
@@ -111,4 +126,4 @@ declare const listDeletedStandaloneForms: MaybeContext<BuildRESTFunction<typeof
|
|
|
111
126
|
declare const queryStandaloneForms: MaybeContext<BuildRESTFunction<typeof queryStandaloneForms$1> & typeof queryStandaloneForms$1>;
|
|
112
127
|
declare const getSiteProperties: MaybeContext<BuildRESTFunction<typeof getSiteProperties$1> & typeof getSiteProperties$1>;
|
|
113
128
|
|
|
114
|
-
export { CreateStandaloneFormApplicationErrors, CursorQuery, DeleteStandaloneFormOptions, GetDeletedStandaloneFormResponse,
|
|
129
|
+
export { CreateStandaloneFormApplicationErrors, CursorQuery, DeleteStandaloneFormOptions, GetDeletedStandaloneFormResponse, GetSitePropertiesApplicationErrors, GetSitePropertiesResponse, ListDeletedStandaloneFormsOptions, ListDeletedStandaloneFormsResponse, QueryStandaloneFormsResponse, RestoreStandaloneFormFromTrashBinResponse, StandaloneForm, createStandaloneForm, deleteStandaloneForm, getDeletedStandaloneForm, getSiteProperties, getStandaloneForm, listDeletedStandaloneForms, queryStandaloneForms, removeStandaloneFormFromTrashBin, restoreStandaloneFormFromTrashBin };
|
package/build/cjs/index.js
CHANGED
|
@@ -32,7 +32,6 @@ __export(index_exports, {
|
|
|
32
32
|
createStandaloneForm: () => createStandaloneForm4,
|
|
33
33
|
deleteStandaloneForm: () => deleteStandaloneForm4,
|
|
34
34
|
getDeletedStandaloneForm: () => getDeletedStandaloneForm4,
|
|
35
|
-
getOrCreateFormStandaloneMetaSite: () => getOrCreateFormStandaloneMetaSite4,
|
|
36
35
|
getSiteProperties: () => getSiteProperties4,
|
|
37
36
|
getStandaloneForm: () => getStandaloneForm4,
|
|
38
37
|
listDeletedStandaloneForms: () => listDeletedStandaloneForms4,
|
|
@@ -52,6 +51,14 @@ var import_timestamp = require("@wix/sdk-runtime/transformations/timestamp");
|
|
|
52
51
|
var import_timestamp2 = require("@wix/sdk-runtime/transformations/timestamp");
|
|
53
52
|
var import_transform_paths = require("@wix/sdk-runtime/transformations/transform-paths");
|
|
54
53
|
var import_rest_modules2 = require("@wix/sdk-runtime/rest-modules");
|
|
54
|
+
var TRANSFORM_PATHS_0 = [
|
|
55
|
+
{ path: "standaloneForm.createdDate" },
|
|
56
|
+
{ path: "standaloneForm.updatedDate" }
|
|
57
|
+
];
|
|
58
|
+
var TRANSFORM_PATHS_1 = [
|
|
59
|
+
{ path: "standaloneForms.createdDate" },
|
|
60
|
+
{ path: "standaloneForms.updatedDate" }
|
|
61
|
+
];
|
|
55
62
|
function resolveWixFormsV1FormStandaloneServiceUrl(opts) {
|
|
56
63
|
const domainToMappings = {
|
|
57
64
|
"manage._base_domain_": [
|
|
@@ -122,36 +129,12 @@ function resolveWixFormsV1FormStandaloneServiceUrl(opts) {
|
|
|
122
129
|
return (0, import_rest_modules2.resolveUrl)(Object.assign(opts, { domainToMappings }));
|
|
123
130
|
}
|
|
124
131
|
var PACKAGE_NAME = "@wix/auto_sdk_standalone-forms_standalone-forms";
|
|
125
|
-
function getOrCreateFormStandaloneMetaSite(payload) {
|
|
126
|
-
function __getOrCreateFormStandaloneMetaSite({ host }) {
|
|
127
|
-
const metadata = {
|
|
128
|
-
entityFqdn: "wix.forms.v1.standalone_form",
|
|
129
|
-
method: "GET",
|
|
130
|
-
methodFqn: "wix.forms.v1.FormStandaloneService.GetOrCreateFormStandaloneMetaSite",
|
|
131
|
-
packageName: PACKAGE_NAME,
|
|
132
|
-
migrationOptions: {
|
|
133
|
-
optInTransformResponse: true
|
|
134
|
-
},
|
|
135
|
-
url: resolveWixFormsV1FormStandaloneServiceUrl({
|
|
136
|
-
protoPath: "/v4/standalone-forms/metasite",
|
|
137
|
-
data: payload,
|
|
138
|
-
host
|
|
139
|
-
}),
|
|
140
|
-
params: (0, import_rest_modules.toURLSearchParams)(payload)
|
|
141
|
-
};
|
|
142
|
-
return metadata;
|
|
143
|
-
}
|
|
144
|
-
return __getOrCreateFormStandaloneMetaSite;
|
|
145
|
-
}
|
|
146
132
|
function createStandaloneForm(payload) {
|
|
147
133
|
function __createStandaloneForm({ host }) {
|
|
148
134
|
const serializedData = (0, import_transform_paths.transformPaths)(payload, [
|
|
149
135
|
{
|
|
150
136
|
transformFn: import_timestamp.transformSDKTimestampToRESTTimestamp,
|
|
151
|
-
paths:
|
|
152
|
-
{ path: "standaloneForm.createdDate" },
|
|
153
|
-
{ path: "standaloneForm.updatedDate" }
|
|
154
|
-
]
|
|
137
|
+
paths: TRANSFORM_PATHS_0
|
|
155
138
|
}
|
|
156
139
|
]);
|
|
157
140
|
const metadata = {
|
|
@@ -171,10 +154,7 @@ function createStandaloneForm(payload) {
|
|
|
171
154
|
transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
|
|
172
155
|
{
|
|
173
156
|
transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
|
|
174
|
-
paths:
|
|
175
|
-
{ path: "standaloneForm.createdDate" },
|
|
176
|
-
{ path: "standaloneForm.updatedDate" }
|
|
177
|
-
]
|
|
157
|
+
paths: TRANSFORM_PATHS_0
|
|
178
158
|
}
|
|
179
159
|
])
|
|
180
160
|
};
|
|
@@ -201,10 +181,7 @@ function getStandaloneForm(payload) {
|
|
|
201
181
|
transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
|
|
202
182
|
{
|
|
203
183
|
transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
|
|
204
|
-
paths:
|
|
205
|
-
{ path: "standaloneForm.createdDate" },
|
|
206
|
-
{ path: "standaloneForm.updatedDate" }
|
|
207
|
-
]
|
|
184
|
+
paths: TRANSFORM_PATHS_0
|
|
208
185
|
}
|
|
209
186
|
])
|
|
210
187
|
};
|
|
@@ -273,10 +250,7 @@ function restoreStandaloneFormFromTrashBin(payload) {
|
|
|
273
250
|
transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
|
|
274
251
|
{
|
|
275
252
|
transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
|
|
276
|
-
paths:
|
|
277
|
-
{ path: "standaloneForm.createdDate" },
|
|
278
|
-
{ path: "standaloneForm.updatedDate" }
|
|
279
|
-
]
|
|
253
|
+
paths: TRANSFORM_PATHS_0
|
|
280
254
|
}
|
|
281
255
|
])
|
|
282
256
|
};
|
|
@@ -303,10 +277,7 @@ function getDeletedStandaloneForm(payload) {
|
|
|
303
277
|
transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
|
|
304
278
|
{
|
|
305
279
|
transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
|
|
306
|
-
paths:
|
|
307
|
-
{ path: "standaloneForm.createdDate" },
|
|
308
|
-
{ path: "standaloneForm.updatedDate" }
|
|
309
|
-
]
|
|
280
|
+
paths: TRANSFORM_PATHS_0
|
|
310
281
|
}
|
|
311
282
|
])
|
|
312
283
|
};
|
|
@@ -333,10 +304,7 @@ function listDeletedStandaloneForms(payload) {
|
|
|
333
304
|
transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
|
|
334
305
|
{
|
|
335
306
|
transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
|
|
336
|
-
paths:
|
|
337
|
-
{ path: "standaloneForms.createdDate" },
|
|
338
|
-
{ path: "standaloneForms.updatedDate" }
|
|
339
|
-
]
|
|
307
|
+
paths: TRANSFORM_PATHS_1
|
|
340
308
|
}
|
|
341
309
|
])
|
|
342
310
|
};
|
|
@@ -363,10 +331,7 @@ function queryStandaloneForms(payload) {
|
|
|
363
331
|
transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
|
|
364
332
|
{
|
|
365
333
|
transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
|
|
366
|
-
paths:
|
|
367
|
-
{ path: "standaloneForms.createdDate" },
|
|
368
|
-
{ path: "standaloneForms.updatedDate" }
|
|
369
|
-
]
|
|
334
|
+
paths: TRANSFORM_PATHS_1
|
|
370
335
|
}
|
|
371
336
|
])
|
|
372
337
|
};
|
|
@@ -500,31 +465,6 @@ var WebhookIdentityType = /* @__PURE__ */ ((WebhookIdentityType2) => {
|
|
|
500
465
|
WebhookIdentityType2["APP"] = "APP";
|
|
501
466
|
return WebhookIdentityType2;
|
|
502
467
|
})(WebhookIdentityType || {});
|
|
503
|
-
async function getOrCreateFormStandaloneMetaSite2() {
|
|
504
|
-
const { httpClient, sideEffects } = arguments[0];
|
|
505
|
-
const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({});
|
|
506
|
-
const reqOpts = getOrCreateFormStandaloneMetaSite(
|
|
507
|
-
payload
|
|
508
|
-
);
|
|
509
|
-
sideEffects?.onSiteCall?.();
|
|
510
|
-
try {
|
|
511
|
-
const result = await httpClient.request(reqOpts);
|
|
512
|
-
sideEffects?.onSuccess?.(result);
|
|
513
|
-
return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(result.data);
|
|
514
|
-
} catch (err) {
|
|
515
|
-
const transformedError = (0, import_transform_error.transformError)(
|
|
516
|
-
err,
|
|
517
|
-
{
|
|
518
|
-
spreadPathsToArguments: {},
|
|
519
|
-
explicitPathsToArguments: {},
|
|
520
|
-
singleArgumentUnchanged: false
|
|
521
|
-
},
|
|
522
|
-
[]
|
|
523
|
-
);
|
|
524
|
-
sideEffects?.onError?.(err);
|
|
525
|
-
throw transformedError;
|
|
526
|
-
}
|
|
527
|
-
}
|
|
528
468
|
async function createStandaloneForm2(standaloneForm) {
|
|
529
469
|
const { httpClient, sideEffects } = arguments[1];
|
|
530
470
|
const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
|
|
@@ -758,12 +698,6 @@ async function getSiteProperties2() {
|
|
|
758
698
|
}
|
|
759
699
|
|
|
760
700
|
// src/forms-v1-standalone-form-standalone-forms.public.ts
|
|
761
|
-
function getOrCreateFormStandaloneMetaSite3(httpClient) {
|
|
762
|
-
return () => getOrCreateFormStandaloneMetaSite2(
|
|
763
|
-
// @ts-ignore
|
|
764
|
-
{ httpClient }
|
|
765
|
-
);
|
|
766
|
-
}
|
|
767
701
|
function createStandaloneForm3(httpClient) {
|
|
768
702
|
return (standaloneForm) => createStandaloneForm2(
|
|
769
703
|
standaloneForm,
|
|
@@ -830,7 +764,6 @@ function getSiteProperties3(httpClient) {
|
|
|
830
764
|
|
|
831
765
|
// src/forms-v1-standalone-form-standalone-forms.context.ts
|
|
832
766
|
var import_rest_modules3 = require("@wix/sdk-runtime/rest-modules");
|
|
833
|
-
var getOrCreateFormStandaloneMetaSite4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(getOrCreateFormStandaloneMetaSite3);
|
|
834
767
|
var createStandaloneForm4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(createStandaloneForm3);
|
|
835
768
|
var getStandaloneForm4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(getStandaloneForm3);
|
|
836
769
|
var deleteStandaloneForm4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(deleteStandaloneForm3);
|
|
@@ -854,7 +787,6 @@ var getSiteProperties4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModu
|
|
|
854
787
|
createStandaloneForm,
|
|
855
788
|
deleteStandaloneForm,
|
|
856
789
|
getDeletedStandaloneForm,
|
|
857
|
-
getOrCreateFormStandaloneMetaSite,
|
|
858
790
|
getSiteProperties,
|
|
859
791
|
getStandaloneForm,
|
|
860
792
|
listDeletedStandaloneForms,
|