@wix/auto_sdk_data_collections 1.0.31 → 1.0.33
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.js +35 -0
- package/build/cjs/index.js.map +1 -1
- package/build/cjs/index.typings.js +35 -0
- package/build/cjs/index.typings.js.map +1 -1
- package/build/cjs/meta.d.ts +610 -1
- package/build/cjs/meta.js +259 -0
- package/build/cjs/meta.js.map +1 -1
- package/build/es/index.mjs +35 -0
- package/build/es/index.mjs.map +1 -1
- package/build/es/index.typings.mjs +35 -0
- package/build/es/index.typings.mjs.map +1 -1
- package/build/es/meta.d.mts +610 -1
- package/build/es/meta.mjs +240 -0
- package/build/es/meta.mjs.map +1 -1
- package/build/internal/cjs/index.js +35 -0
- package/build/internal/cjs/index.js.map +1 -1
- package/build/internal/cjs/index.typings.js +35 -0
- package/build/internal/cjs/index.typings.js.map +1 -1
- package/build/internal/cjs/meta.d.ts +610 -1
- package/build/internal/cjs/meta.js +259 -0
- package/build/internal/cjs/meta.js.map +1 -1
- package/build/internal/es/index.mjs +35 -0
- package/build/internal/es/index.mjs.map +1 -1
- package/build/internal/es/index.typings.mjs +35 -0
- package/build/internal/es/index.typings.mjs.map +1 -1
- package/build/internal/es/meta.d.mts +610 -1
- package/build/internal/es/meta.mjs +240 -0
- package/build/internal/es/meta.mjs.map +1 -1
- package/package.json +3 -3
package/build/cjs/meta.d.ts
CHANGED
|
@@ -176,6 +176,19 @@ interface IndexLimits {
|
|
|
176
176
|
/** Maximum number of regular and unique indexes allowed for this collection. */
|
|
177
177
|
total?: number;
|
|
178
178
|
}
|
|
179
|
+
interface IndexQuotaLimits {
|
|
180
|
+
/**
|
|
181
|
+
* limit of regular single-field indexes, even if 0 1-field indices may be created using
|
|
182
|
+
* 3-field quota (if available)
|
|
183
|
+
*/
|
|
184
|
+
regular1Field?: number;
|
|
185
|
+
/** limit of regular indexes up to 3-fields (in addition to 1-field indexes quota) */
|
|
186
|
+
regular3Field?: number;
|
|
187
|
+
/** limit of unique indexes */
|
|
188
|
+
unique1Field?: number;
|
|
189
|
+
/** Maximum number of regular and unique indexes allowed for this collection. */
|
|
190
|
+
total?: number;
|
|
191
|
+
}
|
|
179
192
|
interface Field extends FieldRangeValidationsOneOf {
|
|
180
193
|
/** Range of possible values for a numerical field. */
|
|
181
194
|
numberRange?: NumberRange;
|
|
@@ -678,6 +691,38 @@ interface PluginCmsOptions {
|
|
|
678
691
|
/** CMS sort, applied when a collection is displayed on a site. */
|
|
679
692
|
siteSort?: SiteSort;
|
|
680
693
|
}
|
|
694
|
+
interface CatalogOptions {
|
|
695
|
+
/**
|
|
696
|
+
* *Required** - the field key that contains the catalog item name - field must be of type TEXT.
|
|
697
|
+
* @maxLength 1000
|
|
698
|
+
*/
|
|
699
|
+
name?: string;
|
|
700
|
+
/**
|
|
701
|
+
* *Required** - the field key that contains the catalog item price - field must be of type NUMBER.
|
|
702
|
+
* @maxLength 1000
|
|
703
|
+
*/
|
|
704
|
+
price?: string;
|
|
705
|
+
/**
|
|
706
|
+
* the field key that contains the catalog item URL - field must be of type URL.
|
|
707
|
+
* @maxLength 1000
|
|
708
|
+
*/
|
|
709
|
+
url?: string | null;
|
|
710
|
+
/**
|
|
711
|
+
* the field key that contains the catalog item description - field must be of type TEXT.
|
|
712
|
+
* @maxLength 1000
|
|
713
|
+
*/
|
|
714
|
+
description?: string | null;
|
|
715
|
+
/**
|
|
716
|
+
* the field key that contains the catalog item image - field must be of type IMAGE.
|
|
717
|
+
* @maxLength 1000
|
|
718
|
+
*/
|
|
719
|
+
image?: string | null;
|
|
720
|
+
/**
|
|
721
|
+
* the field key that contains the catalog item quantity - field must be of type NUMBER.
|
|
722
|
+
* @maxLength 1000
|
|
723
|
+
*/
|
|
724
|
+
quantity?: string | null;
|
|
725
|
+
}
|
|
681
726
|
declare enum PagingMode {
|
|
682
727
|
/** Offset-based paging. */
|
|
683
728
|
OFFSET = "OFFSET",
|
|
@@ -686,6 +731,111 @@ declare enum PagingMode {
|
|
|
686
731
|
}
|
|
687
732
|
/** @enumType */
|
|
688
733
|
type PagingModeWithLiterals = PagingMode | 'OFFSET' | 'CURSOR';
|
|
734
|
+
/** Data permissions defined by access level for each action. */
|
|
735
|
+
interface DataPermissions {
|
|
736
|
+
/** Access level for data items read */
|
|
737
|
+
itemRead?: AccessLevelWithLiterals;
|
|
738
|
+
/** Access level for data items insert */
|
|
739
|
+
itemInsert?: AccessLevelWithLiterals;
|
|
740
|
+
/** Access level for data items update */
|
|
741
|
+
itemUpdate?: AccessLevelWithLiterals;
|
|
742
|
+
/** Access level for data items removal */
|
|
743
|
+
itemRemove?: AccessLevelWithLiterals;
|
|
744
|
+
}
|
|
745
|
+
/**
|
|
746
|
+
* Describes who can perform certain action.
|
|
747
|
+
* Each level includes all levels below it (except UNDEFINED).
|
|
748
|
+
*/
|
|
749
|
+
declare enum AccessLevel {
|
|
750
|
+
/** Not set. */
|
|
751
|
+
UNDEFINED = "UNDEFINED",
|
|
752
|
+
/** Any subject, including visitors. */
|
|
753
|
+
ANYONE = "ANYONE",
|
|
754
|
+
/** Any signed-in user (both site members and collaborators). */
|
|
755
|
+
SITE_MEMBER = "SITE_MEMBER",
|
|
756
|
+
/** Any signed-in user, but site members only have access to own items. */
|
|
757
|
+
SITE_MEMBER_AUTHOR = "SITE_MEMBER_AUTHOR",
|
|
758
|
+
/** Site collaborator that has a role with CMS Access permission. */
|
|
759
|
+
CMS_EDITOR = "CMS_EDITOR",
|
|
760
|
+
/** CMS administrators and users or roles granted with special access. */
|
|
761
|
+
PRIVILEGED = "PRIVILEGED"
|
|
762
|
+
}
|
|
763
|
+
/** @enumType */
|
|
764
|
+
type AccessLevelWithLiterals = AccessLevel | 'UNDEFINED' | 'ANYONE' | 'SITE_MEMBER' | 'SITE_MEMBER_AUTHOR' | 'CMS_EDITOR' | 'PRIVILEGED';
|
|
765
|
+
interface AllowedDataPermissions {
|
|
766
|
+
/** If data items read permitted */
|
|
767
|
+
itemRead?: boolean;
|
|
768
|
+
/** If for data items insert permitted */
|
|
769
|
+
itemInsert?: boolean;
|
|
770
|
+
/** If data items update permitted */
|
|
771
|
+
itemUpdate?: boolean;
|
|
772
|
+
/** If data items removal permitted */
|
|
773
|
+
itemRemove?: boolean;
|
|
774
|
+
}
|
|
775
|
+
interface DataCollectionClonedEvent {
|
|
776
|
+
/**
|
|
777
|
+
* Instance ID of the collection from which the data is cloned.
|
|
778
|
+
* @format GUID
|
|
779
|
+
*/
|
|
780
|
+
originInstanceId?: string;
|
|
781
|
+
/**
|
|
782
|
+
* ID of the collection from which the data is cloned.
|
|
783
|
+
* @maxLength 256
|
|
784
|
+
*/
|
|
785
|
+
originId?: string;
|
|
786
|
+
}
|
|
787
|
+
interface DataCollectionChangedEvent {
|
|
788
|
+
/**
|
|
789
|
+
* list of new fields
|
|
790
|
+
* @maxSize 1000
|
|
791
|
+
*/
|
|
792
|
+
fieldsAdded?: Field[];
|
|
793
|
+
/**
|
|
794
|
+
* list of changed fields
|
|
795
|
+
* @maxSize 1000
|
|
796
|
+
*/
|
|
797
|
+
fieldsUpdated?: FieldUpdate[];
|
|
798
|
+
/**
|
|
799
|
+
* list of removed fields
|
|
800
|
+
* @maxSize 1000
|
|
801
|
+
*/
|
|
802
|
+
fieldsRemoved?: Field[];
|
|
803
|
+
/**
|
|
804
|
+
* list of new plugins
|
|
805
|
+
* @maxSize 100
|
|
806
|
+
*/
|
|
807
|
+
pluginsAdded?: Plugin[];
|
|
808
|
+
/**
|
|
809
|
+
* list of changed plugins
|
|
810
|
+
* @maxSize 100
|
|
811
|
+
*/
|
|
812
|
+
pluginsUpdated?: PluginUpdate[];
|
|
813
|
+
/**
|
|
814
|
+
* list of removed plugins
|
|
815
|
+
* @maxSize 100
|
|
816
|
+
*/
|
|
817
|
+
pluginsRemoved?: Plugin[];
|
|
818
|
+
}
|
|
819
|
+
interface FieldUpdate {
|
|
820
|
+
/** previous state of the field */
|
|
821
|
+
previous?: Field;
|
|
822
|
+
/** current state of the field */
|
|
823
|
+
current?: Field;
|
|
824
|
+
}
|
|
825
|
+
interface PluginUpdate {
|
|
826
|
+
/** previous state of the plugin */
|
|
827
|
+
previous?: Plugin;
|
|
828
|
+
/** current state of the plugin */
|
|
829
|
+
current?: Plugin;
|
|
830
|
+
}
|
|
831
|
+
interface DataCollectionEvictedEvent {
|
|
832
|
+
/**
|
|
833
|
+
* ID of the collection that was permanently deleted.
|
|
834
|
+
* @minLength 1
|
|
835
|
+
* @maxLength 1000
|
|
836
|
+
*/
|
|
837
|
+
id?: string;
|
|
838
|
+
}
|
|
689
839
|
interface CreateDataCollectionRequest {
|
|
690
840
|
/** Collection details. */
|
|
691
841
|
collection: DataCollection;
|
|
@@ -716,6 +866,13 @@ interface GetDataCollectionRequest {
|
|
|
716
866
|
*/
|
|
717
867
|
fields?: string[];
|
|
718
868
|
}
|
|
869
|
+
declare enum Segment {
|
|
870
|
+
UNKNOWN_SEGMENT = "UNKNOWN_SEGMENT",
|
|
871
|
+
PUBLIC = "PUBLIC",
|
|
872
|
+
DEV = "DEV"
|
|
873
|
+
}
|
|
874
|
+
/** @enumType */
|
|
875
|
+
type SegmentWithLiterals = Segment | 'UNKNOWN_SEGMENT' | 'PUBLIC' | 'DEV';
|
|
719
876
|
interface GetDataCollectionResponse {
|
|
720
877
|
/** Details of the collection requested. */
|
|
721
878
|
collection?: DataCollection;
|
|
@@ -787,6 +944,72 @@ interface PagingMetadataV2 {
|
|
|
787
944
|
/** Flag that indicates the server failed to calculate the `total` field. */
|
|
788
945
|
tooManyToCount?: boolean | null;
|
|
789
946
|
}
|
|
947
|
+
interface BulkGetDataCollectionsRequest {
|
|
948
|
+
/**
|
|
949
|
+
* IDs of the collections to retrieve.
|
|
950
|
+
* @minSize 1
|
|
951
|
+
* @maxSize 100
|
|
952
|
+
* @maxLength 256
|
|
953
|
+
*/
|
|
954
|
+
dataCollectionIds?: string[];
|
|
955
|
+
/**
|
|
956
|
+
* Whether to include deleted collections.
|
|
957
|
+
*
|
|
958
|
+
* Default: `false`
|
|
959
|
+
*/
|
|
960
|
+
showDeletedCollections?: boolean;
|
|
961
|
+
/**
|
|
962
|
+
* Whether the returned collection list should include referenced collections.
|
|
963
|
+
*
|
|
964
|
+
* Default: `false`
|
|
965
|
+
*/
|
|
966
|
+
includeReferencedCollections?: boolean;
|
|
967
|
+
/** Sorting preferences. */
|
|
968
|
+
sort?: Sorting;
|
|
969
|
+
/**
|
|
970
|
+
* Whether to retrieve data from the primary database instance.
|
|
971
|
+
* This decreases performance but ensures data retrieved is up to date even immediately after an update.
|
|
972
|
+
* Learn more about [Wix Data and eventual consistency](https://dev.wix.com/api/rest/wix-data/wix-data/eventual-consistency).
|
|
973
|
+
*
|
|
974
|
+
* Default: `false`
|
|
975
|
+
*/
|
|
976
|
+
consistentRead?: boolean;
|
|
977
|
+
/**
|
|
978
|
+
* List of specific field names to return, if empty all fields are returned.
|
|
979
|
+
* Affects all returned collections
|
|
980
|
+
* @maxSize 100
|
|
981
|
+
* @maxLength 1000
|
|
982
|
+
*/
|
|
983
|
+
fields?: string[];
|
|
984
|
+
}
|
|
985
|
+
interface BulkGetDataCollectionsResponse {
|
|
986
|
+
/**
|
|
987
|
+
* List of requested collections.
|
|
988
|
+
* When `include_referenced_collections` is `true` in the request, referenced collections are included here.
|
|
989
|
+
*/
|
|
990
|
+
activeCollections?: DataCollection[];
|
|
991
|
+
/** List of requested deleted collections. Only populated when `showDeletedCollections` is true in the request. */
|
|
992
|
+
deletedCollections?: DataCollection[];
|
|
993
|
+
/** List of failed collections. */
|
|
994
|
+
failedCollections?: FailedCollection[];
|
|
995
|
+
}
|
|
996
|
+
interface ApplicationError {
|
|
997
|
+
/** Error code. */
|
|
998
|
+
code?: string;
|
|
999
|
+
/** Description of the error. */
|
|
1000
|
+
description?: string;
|
|
1001
|
+
/** Data related to the error. */
|
|
1002
|
+
data?: Record<string, any> | null;
|
|
1003
|
+
}
|
|
1004
|
+
interface FailedCollection {
|
|
1005
|
+
/**
|
|
1006
|
+
* IDs of the failed collection.
|
|
1007
|
+
* @maxLength 255
|
|
1008
|
+
*/
|
|
1009
|
+
collectionId?: string;
|
|
1010
|
+
/** Reason of the failure. */
|
|
1011
|
+
error?: ApplicationError;
|
|
1012
|
+
}
|
|
790
1013
|
interface UpdateDataCollectionRequest {
|
|
791
1014
|
/** Updated collection details. The existing collection is replaced with this version. */
|
|
792
1015
|
collection: DataCollection;
|
|
@@ -857,6 +1080,392 @@ interface DeleteDataCollectionFieldResponse {
|
|
|
857
1080
|
/** Updated data collection. */
|
|
858
1081
|
dataCollection?: DataCollection;
|
|
859
1082
|
}
|
|
1083
|
+
interface UpdateDataPermissionsRequest {
|
|
1084
|
+
/**
|
|
1085
|
+
* ID of data collections to update
|
|
1086
|
+
* @maxLength 256
|
|
1087
|
+
*/
|
|
1088
|
+
dataCollectionId?: string;
|
|
1089
|
+
/** Data permissions to set */
|
|
1090
|
+
dataPermissions?: DataPermissions;
|
|
1091
|
+
}
|
|
1092
|
+
interface UpdateDataPermissionsResponse {
|
|
1093
|
+
/** Updated data collection */
|
|
1094
|
+
dataCollection?: DataCollection;
|
|
1095
|
+
}
|
|
1096
|
+
interface BulkGetDataCollectionsPageBySnapshotsRequest {
|
|
1097
|
+
/**
|
|
1098
|
+
* Ids of schema snapshot
|
|
1099
|
+
* @format GUID
|
|
1100
|
+
* @minSize 1
|
|
1101
|
+
* @maxSize 1000
|
|
1102
|
+
*/
|
|
1103
|
+
snapshotIds?: string[];
|
|
1104
|
+
/** Pagination information. */
|
|
1105
|
+
paging?: Paging;
|
|
1106
|
+
}
|
|
1107
|
+
interface BulkGetDataCollectionsPageBySnapshotsResponse {
|
|
1108
|
+
/** List of snapshot collection map */
|
|
1109
|
+
snapshotCollections?: SnapshotCollection[];
|
|
1110
|
+
/** Paging information. */
|
|
1111
|
+
pagingMetadata?: PagingMetadataV2;
|
|
1112
|
+
}
|
|
1113
|
+
interface SnapshotCollection {
|
|
1114
|
+
/**
|
|
1115
|
+
* snapshot to which collection belongs
|
|
1116
|
+
* @format GUID
|
|
1117
|
+
*/
|
|
1118
|
+
snapshotId?: string;
|
|
1119
|
+
/** snapshot collection */
|
|
1120
|
+
collection?: DataCollection;
|
|
1121
|
+
/**
|
|
1122
|
+
* snapshot of collection indexes
|
|
1123
|
+
* @maxSize 100
|
|
1124
|
+
*/
|
|
1125
|
+
indexes?: Index[];
|
|
1126
|
+
}
|
|
1127
|
+
/** An index is a map of a collection's data, organized according to specific fields to increase query speed. */
|
|
1128
|
+
interface Index {
|
|
1129
|
+
/**
|
|
1130
|
+
* Id of the index.
|
|
1131
|
+
* @readonly
|
|
1132
|
+
* @format GUID
|
|
1133
|
+
*/
|
|
1134
|
+
id?: string;
|
|
1135
|
+
/**
|
|
1136
|
+
* Name of the index.
|
|
1137
|
+
* @minLength 1
|
|
1138
|
+
* @maxLength 128
|
|
1139
|
+
*/
|
|
1140
|
+
name?: string;
|
|
1141
|
+
/**
|
|
1142
|
+
* Fields for which the index is defined.
|
|
1143
|
+
*
|
|
1144
|
+
* Max: 3 fields (for a unique index: 1 field)
|
|
1145
|
+
* @minSize 1
|
|
1146
|
+
* @maxSize 3
|
|
1147
|
+
*/
|
|
1148
|
+
fields?: IndexField[];
|
|
1149
|
+
/**
|
|
1150
|
+
* Current status of the index.
|
|
1151
|
+
* @readonly
|
|
1152
|
+
*/
|
|
1153
|
+
status?: IndexStatusWithLiterals;
|
|
1154
|
+
/**
|
|
1155
|
+
* Contains details about the reasons for failure when `status` is `FAILED`.
|
|
1156
|
+
* @readonly
|
|
1157
|
+
*/
|
|
1158
|
+
failure?: Failure;
|
|
1159
|
+
/**
|
|
1160
|
+
* Whether the index enforces uniqueness of values in the field for which it is defined.
|
|
1161
|
+
* If `true`, the index can have only one field.
|
|
1162
|
+
*
|
|
1163
|
+
* Default: `false`
|
|
1164
|
+
*/
|
|
1165
|
+
unique?: boolean;
|
|
1166
|
+
/**
|
|
1167
|
+
* Whether the index ignores case.
|
|
1168
|
+
*
|
|
1169
|
+
* Default: `false`
|
|
1170
|
+
*/
|
|
1171
|
+
caseInsensitive?: boolean;
|
|
1172
|
+
/** Specifies the origin of the index definition. */
|
|
1173
|
+
source?: IndexSourceWithLiterals;
|
|
1174
|
+
}
|
|
1175
|
+
/**
|
|
1176
|
+
* Order determines how values are ordered in the index. This is important when
|
|
1177
|
+
* ordering and/or range querying by indexed fields.
|
|
1178
|
+
*/
|
|
1179
|
+
declare enum Order {
|
|
1180
|
+
ASC = "ASC",
|
|
1181
|
+
DESC = "DESC"
|
|
1182
|
+
}
|
|
1183
|
+
/** @enumType */
|
|
1184
|
+
type OrderWithLiterals = Order | 'ASC' | 'DESC';
|
|
1185
|
+
interface IndexField {
|
|
1186
|
+
/**
|
|
1187
|
+
* Path of the field to index. For example: `title` or `options.price`.
|
|
1188
|
+
* @minLength 1
|
|
1189
|
+
* @maxLength 128
|
|
1190
|
+
*/
|
|
1191
|
+
path?: string;
|
|
1192
|
+
/**
|
|
1193
|
+
* Sort order for the index. Base on how the data is regularly queried.
|
|
1194
|
+
*
|
|
1195
|
+
* Default: `ASC`
|
|
1196
|
+
*/
|
|
1197
|
+
order?: OrderWithLiterals;
|
|
1198
|
+
}
|
|
1199
|
+
declare enum IndexStatus {
|
|
1200
|
+
/** Place holder. Never returned by the service. */
|
|
1201
|
+
UNKNOWN = "UNKNOWN",
|
|
1202
|
+
/** Index creation is in progress. */
|
|
1203
|
+
BUILDING = "BUILDING",
|
|
1204
|
+
/** Index has been successfully created and can be used in queries. */
|
|
1205
|
+
ACTIVE = "ACTIVE",
|
|
1206
|
+
/** Index is in the process of being dropped. */
|
|
1207
|
+
DROPPING = "DROPPING",
|
|
1208
|
+
/** Index has been dropped successfully. */
|
|
1209
|
+
DROPPED = "DROPPED",
|
|
1210
|
+
/** Index creation has failed. */
|
|
1211
|
+
FAILED = "FAILED",
|
|
1212
|
+
/** Index contains incorrectly indexed data. */
|
|
1213
|
+
INVALID = "INVALID"
|
|
1214
|
+
}
|
|
1215
|
+
/** @enumType */
|
|
1216
|
+
type IndexStatusWithLiterals = IndexStatus | 'UNKNOWN' | 'BUILDING' | 'ACTIVE' | 'DROPPING' | 'DROPPED' | 'FAILED' | 'INVALID';
|
|
1217
|
+
interface Failure {
|
|
1218
|
+
/**
|
|
1219
|
+
* Error code.
|
|
1220
|
+
* - `WDE0112`: Unknown error while building collection index.
|
|
1221
|
+
* - `WDE0113`: Duplicate key error while building collection index.
|
|
1222
|
+
* - `WDE0114`: Document too large while building collection index.
|
|
1223
|
+
* @maxLength 7
|
|
1224
|
+
*/
|
|
1225
|
+
code?: string;
|
|
1226
|
+
/**
|
|
1227
|
+
* Description of the failure.
|
|
1228
|
+
* @maxLength 1024
|
|
1229
|
+
*/
|
|
1230
|
+
description?: string;
|
|
1231
|
+
/**
|
|
1232
|
+
* ID of the data item that caused the failure.
|
|
1233
|
+
* For example, if `unique` is `true`, the ID of an item containing a duplicate value.
|
|
1234
|
+
* @maxLength 16000
|
|
1235
|
+
*/
|
|
1236
|
+
itemId?: string | null;
|
|
1237
|
+
}
|
|
1238
|
+
declare enum IndexSource {
|
|
1239
|
+
/** Place holder. Never returned by the service. */
|
|
1240
|
+
UNKNOWN_INDEX_SOURCE = "UNKNOWN_INDEX_SOURCE",
|
|
1241
|
+
/** Index is created by the system, present for all collections. */
|
|
1242
|
+
SYSTEM = "SYSTEM",
|
|
1243
|
+
/** Index was created by a user via API or UI. */
|
|
1244
|
+
USER = "USER",
|
|
1245
|
+
/** Index is created automatically by the system based on user queries. */
|
|
1246
|
+
AUTO = "AUTO"
|
|
1247
|
+
}
|
|
1248
|
+
/** @enumType */
|
|
1249
|
+
type IndexSourceWithLiterals = IndexSource | 'UNKNOWN_INDEX_SOURCE' | 'SYSTEM' | 'USER' | 'AUTO';
|
|
1250
|
+
interface CreateDataCollectionsSnapshotRequest {
|
|
1251
|
+
}
|
|
1252
|
+
interface CreateDataCollectionsSnapshotResponse {
|
|
1253
|
+
/**
|
|
1254
|
+
* created snapshot ID
|
|
1255
|
+
* @format GUID
|
|
1256
|
+
*/
|
|
1257
|
+
snapshotId?: string;
|
|
1258
|
+
/** data collections in snapshot */
|
|
1259
|
+
snapshotCollections?: DataCollection[];
|
|
1260
|
+
}
|
|
1261
|
+
interface RestoreDataCollectionsFromSnapshotRequest {
|
|
1262
|
+
/**
|
|
1263
|
+
* snapshot ID to restore
|
|
1264
|
+
* @format GUID
|
|
1265
|
+
*/
|
|
1266
|
+
snapshotId?: string;
|
|
1267
|
+
/**
|
|
1268
|
+
* collection IDs to restore, if empty – all collections would be restored
|
|
1269
|
+
* @maxSize 1000
|
|
1270
|
+
* @maxLength 256
|
|
1271
|
+
* @deprecated
|
|
1272
|
+
* @replacedBy restoration_collections
|
|
1273
|
+
* @targetRemovalDate 2025-12-31
|
|
1274
|
+
*/
|
|
1275
|
+
dataCollectionIds?: string[];
|
|
1276
|
+
/**
|
|
1277
|
+
* collection to restore, if empty – all collections would be restored
|
|
1278
|
+
* @maxSize 1000
|
|
1279
|
+
*/
|
|
1280
|
+
restorationCollections?: RestorationCollection[];
|
|
1281
|
+
}
|
|
1282
|
+
interface Destination {
|
|
1283
|
+
/**
|
|
1284
|
+
* Collection id.
|
|
1285
|
+
* @minLength 1
|
|
1286
|
+
* @maxLength 1000
|
|
1287
|
+
*/
|
|
1288
|
+
dataCollectionId?: string;
|
|
1289
|
+
/**
|
|
1290
|
+
* Display name. When not specified value is taken from the snapshot.
|
|
1291
|
+
* @maxLength 1000
|
|
1292
|
+
*/
|
|
1293
|
+
displayName?: string | null;
|
|
1294
|
+
}
|
|
1295
|
+
interface RestorationCollection {
|
|
1296
|
+
/**
|
|
1297
|
+
* Collection ID to restore
|
|
1298
|
+
* @minLength 1
|
|
1299
|
+
* @maxLength 1000
|
|
1300
|
+
*/
|
|
1301
|
+
dataCollectionId?: string;
|
|
1302
|
+
/**
|
|
1303
|
+
* Destination where to restore the collection.
|
|
1304
|
+
* When not specified destination is taken from snapshot.
|
|
1305
|
+
*/
|
|
1306
|
+
destination?: Destination;
|
|
1307
|
+
}
|
|
1308
|
+
interface RestoreDataCollectionsFromSnapshotResponse {
|
|
1309
|
+
/** restored collections */
|
|
1310
|
+
restoredCollections?: DataCollection[];
|
|
1311
|
+
}
|
|
1312
|
+
interface DeleteDataCollectionsSnapshotRequest {
|
|
1313
|
+
/**
|
|
1314
|
+
* snapshot ID to delete
|
|
1315
|
+
* @format GUID
|
|
1316
|
+
*/
|
|
1317
|
+
snapshotId?: string;
|
|
1318
|
+
}
|
|
1319
|
+
interface DeleteDataCollectionsSnapshotResponse {
|
|
1320
|
+
}
|
|
1321
|
+
interface CreateMigratedCollectionsSnapshotRequest {
|
|
1322
|
+
/** @format GUID */
|
|
1323
|
+
existingSnapshotId?: string;
|
|
1324
|
+
/** @maxLength 255 */
|
|
1325
|
+
newNamespace?: string;
|
|
1326
|
+
/** @maxLength 255 */
|
|
1327
|
+
existingNamespace?: string;
|
|
1328
|
+
}
|
|
1329
|
+
interface CreateMigratedCollectionsSnapshotResponse {
|
|
1330
|
+
/** @format GUID */
|
|
1331
|
+
snapshotId?: string;
|
|
1332
|
+
}
|
|
1333
|
+
interface DomainEvent extends DomainEventBodyOneOf {
|
|
1334
|
+
createdEvent?: EntityCreatedEvent;
|
|
1335
|
+
updatedEvent?: EntityUpdatedEvent;
|
|
1336
|
+
deletedEvent?: EntityDeletedEvent;
|
|
1337
|
+
actionEvent?: ActionEvent;
|
|
1338
|
+
/** Event ID. With this ID you can easily spot duplicated events and ignore them. */
|
|
1339
|
+
id?: string;
|
|
1340
|
+
/**
|
|
1341
|
+
* Fully Qualified Domain Name of an entity. This is a unique identifier assigned to the API main business entities.
|
|
1342
|
+
* For example, `wix.stores.catalog.product`, `wix.bookings.session`, `wix.payments.transaction`.
|
|
1343
|
+
*/
|
|
1344
|
+
entityFqdn?: string;
|
|
1345
|
+
/**
|
|
1346
|
+
* Event action name, placed at the top level to make it easier for users to dispatch messages.
|
|
1347
|
+
* For example: `created`/`updated`/`deleted`/`started`/`completed`/`email_opened`.
|
|
1348
|
+
*/
|
|
1349
|
+
slug?: string;
|
|
1350
|
+
/** ID of the entity associated with the event. */
|
|
1351
|
+
entityId?: string;
|
|
1352
|
+
/** Event timestamp in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601) format and UTC time. For example, `2020-04-26T13:57:50.699Z`. */
|
|
1353
|
+
eventTime?: Date | null;
|
|
1354
|
+
/**
|
|
1355
|
+
* Whether the event was triggered as a result of a privacy regulation application
|
|
1356
|
+
* (for example, GDPR).
|
|
1357
|
+
*/
|
|
1358
|
+
triggeredByAnonymizeRequest?: boolean | null;
|
|
1359
|
+
/** If present, indicates the action that triggered the event. */
|
|
1360
|
+
originatedFrom?: string | null;
|
|
1361
|
+
/**
|
|
1362
|
+
* A sequence number that indicates the order of updates to an entity. For example, if an entity was updated at 16:00 and then again at 16:01, the second update will always have a higher sequence number.
|
|
1363
|
+
* You can use this number to make sure you're handling updates in the right order. Just save the latest sequence number on your end and compare it to the one in each new message. If the new message has an older (lower) number, you can safely ignore it.
|
|
1364
|
+
*/
|
|
1365
|
+
entityEventSequence?: string | null;
|
|
1366
|
+
}
|
|
1367
|
+
/** @oneof */
|
|
1368
|
+
interface DomainEventBodyOneOf {
|
|
1369
|
+
createdEvent?: EntityCreatedEvent;
|
|
1370
|
+
updatedEvent?: EntityUpdatedEvent;
|
|
1371
|
+
deletedEvent?: EntityDeletedEvent;
|
|
1372
|
+
actionEvent?: ActionEvent;
|
|
1373
|
+
}
|
|
1374
|
+
interface EntityCreatedEvent {
|
|
1375
|
+
entityAsJson?: string;
|
|
1376
|
+
/** Indicates the event was triggered by a restore-from-trashbin operation for a previously deleted entity */
|
|
1377
|
+
restoreInfo?: RestoreInfo;
|
|
1378
|
+
}
|
|
1379
|
+
interface RestoreInfo {
|
|
1380
|
+
deletedDate?: Date | null;
|
|
1381
|
+
}
|
|
1382
|
+
interface EntityUpdatedEvent {
|
|
1383
|
+
/**
|
|
1384
|
+
* Since platformized APIs only expose PATCH and not PUT we can't assume that the fields sent from the client are the actual diff.
|
|
1385
|
+
* This means that to generate a list of changed fields (as opposed to sent fields) one needs to traverse both objects.
|
|
1386
|
+
* We don't want to impose this on all developers and so we leave this traversal to the notification recipients which need it.
|
|
1387
|
+
*/
|
|
1388
|
+
currentEntityAsJson?: string;
|
|
1389
|
+
}
|
|
1390
|
+
interface EntityDeletedEvent {
|
|
1391
|
+
/** Entity that was deleted. */
|
|
1392
|
+
deletedEntityAsJson?: string | null;
|
|
1393
|
+
}
|
|
1394
|
+
interface ActionEvent {
|
|
1395
|
+
bodyAsJson?: string;
|
|
1396
|
+
}
|
|
1397
|
+
interface MessageEnvelope {
|
|
1398
|
+
/**
|
|
1399
|
+
* App instance ID.
|
|
1400
|
+
* @format GUID
|
|
1401
|
+
*/
|
|
1402
|
+
instanceId?: string | null;
|
|
1403
|
+
/**
|
|
1404
|
+
* Event type.
|
|
1405
|
+
* @maxLength 150
|
|
1406
|
+
*/
|
|
1407
|
+
eventType?: string;
|
|
1408
|
+
/** The identification type and identity data. */
|
|
1409
|
+
identity?: IdentificationData;
|
|
1410
|
+
/** Stringify payload. */
|
|
1411
|
+
data?: string;
|
|
1412
|
+
}
|
|
1413
|
+
interface IdentificationData extends IdentificationDataIdOneOf {
|
|
1414
|
+
/**
|
|
1415
|
+
* ID of a site visitor that has not logged in to the site.
|
|
1416
|
+
* @format GUID
|
|
1417
|
+
*/
|
|
1418
|
+
anonymousVisitorId?: string;
|
|
1419
|
+
/**
|
|
1420
|
+
* ID of a site visitor that has logged in to the site.
|
|
1421
|
+
* @format GUID
|
|
1422
|
+
*/
|
|
1423
|
+
memberId?: string;
|
|
1424
|
+
/**
|
|
1425
|
+
* ID of a Wix user (site owner, contributor, etc.).
|
|
1426
|
+
* @format GUID
|
|
1427
|
+
*/
|
|
1428
|
+
wixUserId?: string;
|
|
1429
|
+
/**
|
|
1430
|
+
* ID of an app.
|
|
1431
|
+
* @format GUID
|
|
1432
|
+
*/
|
|
1433
|
+
appId?: string;
|
|
1434
|
+
/** @readonly */
|
|
1435
|
+
identityType?: WebhookIdentityTypeWithLiterals;
|
|
1436
|
+
}
|
|
1437
|
+
/** @oneof */
|
|
1438
|
+
interface IdentificationDataIdOneOf {
|
|
1439
|
+
/**
|
|
1440
|
+
* ID of a site visitor that has not logged in to the site.
|
|
1441
|
+
* @format GUID
|
|
1442
|
+
*/
|
|
1443
|
+
anonymousVisitorId?: string;
|
|
1444
|
+
/**
|
|
1445
|
+
* ID of a site visitor that has logged in to the site.
|
|
1446
|
+
* @format GUID
|
|
1447
|
+
*/
|
|
1448
|
+
memberId?: string;
|
|
1449
|
+
/**
|
|
1450
|
+
* ID of a Wix user (site owner, contributor, etc.).
|
|
1451
|
+
* @format GUID
|
|
1452
|
+
*/
|
|
1453
|
+
wixUserId?: string;
|
|
1454
|
+
/**
|
|
1455
|
+
* ID of an app.
|
|
1456
|
+
* @format GUID
|
|
1457
|
+
*/
|
|
1458
|
+
appId?: string;
|
|
1459
|
+
}
|
|
1460
|
+
declare enum WebhookIdentityType {
|
|
1461
|
+
UNKNOWN = "UNKNOWN",
|
|
1462
|
+
ANONYMOUS_VISITOR = "ANONYMOUS_VISITOR",
|
|
1463
|
+
MEMBER = "MEMBER",
|
|
1464
|
+
WIX_USER = "WIX_USER",
|
|
1465
|
+
APP = "APP"
|
|
1466
|
+
}
|
|
1467
|
+
/** @enumType */
|
|
1468
|
+
type WebhookIdentityTypeWithLiterals = WebhookIdentityType | 'UNKNOWN' | 'ANONYMOUS_VISITOR' | 'MEMBER' | 'WIX_USER' | 'APP';
|
|
860
1469
|
|
|
861
1470
|
type __PublicMethodMetaInfo<K = string, M = unknown, T = unknown, S = unknown, Q = unknown, R = unknown> = {
|
|
862
1471
|
getUrl: (context: any) => string;
|
|
@@ -884,4 +1493,4 @@ declare function createDataCollectionField(): __PublicMethodMetaInfo<'POST', {},
|
|
|
884
1493
|
declare function updateDataCollectionField(): __PublicMethodMetaInfo<'POST', {}, UpdateDataCollectionFieldRequest$1, UpdateDataCollectionFieldRequest, UpdateDataCollectionFieldResponse$1, UpdateDataCollectionFieldResponse>;
|
|
885
1494
|
declare function deleteDataCollectionField(): __PublicMethodMetaInfo<'POST', {}, DeleteDataCollectionFieldRequest$1, DeleteDataCollectionFieldRequest, DeleteDataCollectionFieldResponse$1, DeleteDataCollectionFieldResponse>;
|
|
886
1495
|
|
|
887
|
-
export { type __PublicMethodMetaInfo, createDataCollection, createDataCollectionField, deleteDataCollection, deleteDataCollectionField, getDataCollection, listDataCollections, restoreDataCollection, updateDataCollection, updateDataCollectionField };
|
|
1496
|
+
export { AccessLevel as AccessLevelOriginal, type AccessLevelWithLiterals as AccessLevelWithLiteralsOriginal, type ActionEvent as ActionEventOriginal, type AllowedDataPermissions as AllowedDataPermissionsOriginal, type ApplicationError as ApplicationErrorOriginal, type ArraySizeRange as ArraySizeRangeOriginal, type BulkGetDataCollectionsPageBySnapshotsRequest as BulkGetDataCollectionsPageBySnapshotsRequestOriginal, type BulkGetDataCollectionsPageBySnapshotsResponse as BulkGetDataCollectionsPageBySnapshotsResponseOriginal, type BulkGetDataCollectionsRequest as BulkGetDataCollectionsRequestOriginal, type BulkGetDataCollectionsResponse as BulkGetDataCollectionsResponseOriginal, type Calculator as CalculatorOriginal, type CalculatorPatternOneOf as CalculatorPatternOneOfOriginal, type CatalogOptions as CatalogOptionsOriginal, type CmsOptions as CmsOptionsOriginal, type CollectionCapabilities as CollectionCapabilitiesOriginal, CollectionOperation as CollectionOperationOriginal, type CollectionOperationWithLiterals as CollectionOperationWithLiteralsOriginal, CollectionType as CollectionTypeOriginal, type CollectionTypeWithLiterals as CollectionTypeWithLiteralsOriginal, type CreateDataCollectionFieldRequest as CreateDataCollectionFieldRequestOriginal, type CreateDataCollectionFieldResponse as CreateDataCollectionFieldResponseOriginal, type CreateDataCollectionRequest as CreateDataCollectionRequestOriginal, type CreateDataCollectionResponse as CreateDataCollectionResponseOriginal, type CreateDataCollectionsSnapshotRequest as CreateDataCollectionsSnapshotRequestOriginal, type CreateDataCollectionsSnapshotResponse as CreateDataCollectionsSnapshotResponseOriginal, type CreateMigratedCollectionsSnapshotRequest as CreateMigratedCollectionsSnapshotRequestOriginal, type CreateMigratedCollectionsSnapshotResponse as CreateMigratedCollectionsSnapshotResponseOriginal, type DataCollectionChangedEvent as DataCollectionChangedEventOriginal, type DataCollectionClonedEvent as DataCollectionClonedEventOriginal, type DataCollectionEvictedEvent as DataCollectionEvictedEventOriginal, type DataCollection as DataCollectionOriginal, DataOperation as DataOperationOriginal, type DataOperationWithLiterals as DataOperationWithLiteralsOriginal, type DataPermissions as DataPermissionsOriginal, type DeleteDataCollectionFieldRequest as DeleteDataCollectionFieldRequestOriginal, type DeleteDataCollectionFieldResponse as DeleteDataCollectionFieldResponseOriginal, type DeleteDataCollectionRequest as DeleteDataCollectionRequestOriginal, type DeleteDataCollectionResponse as DeleteDataCollectionResponseOriginal, type DeleteDataCollectionsSnapshotRequest as DeleteDataCollectionsSnapshotRequestOriginal, type DeleteDataCollectionsSnapshotResponse as DeleteDataCollectionsSnapshotResponseOriginal, type Destination as DestinationOriginal, Direction as DirectionOriginal, type DirectionWithLiterals as DirectionWithLiteralsOriginal, type DomainEventBodyOneOf as DomainEventBodyOneOfOriginal, type DomainEvent as DomainEventOriginal, type EntityCreatedEvent as EntityCreatedEventOriginal, type EntityDeletedEvent as EntityDeletedEventOriginal, type EntityUpdatedEvent as EntityUpdatedEventOriginal, type FailedCollection as FailedCollectionOriginal, type Failure as FailureOriginal, type FieldCapabilities as FieldCapabilitiesOriginal, type Field as FieldOriginal, type FieldPluginOptionsOneOf as FieldPluginOptionsOneOfOriginal, type FieldPlugin as FieldPluginOriginal, FieldPluginType as FieldPluginTypeOriginal, type FieldPluginTypeWithLiterals as FieldPluginTypeWithLiteralsOriginal, type FieldRangeValidationsOneOf as FieldRangeValidationsOneOfOriginal, type FieldUpdate as FieldUpdateOriginal, type FieldsPattern as FieldsPatternOriginal, Format as FormatOriginal, type FormatWithLiterals as FormatWithLiteralsOriginal, type GetDataCollectionRequest as GetDataCollectionRequestOriginal, type GetDataCollectionResponse as GetDataCollectionResponseOriginal, type IdentificationDataIdOneOf as IdentificationDataIdOneOfOriginal, type IdentificationData as IdentificationDataOriginal, type IndexField as IndexFieldOriginal, type IndexLimits as IndexLimitsOriginal, type Index as IndexOriginal, type IndexQuotaLimits as IndexQuotaLimitsOriginal, IndexSource as IndexSourceOriginal, type IndexSourceWithLiterals as IndexSourceWithLiteralsOriginal, IndexStatus as IndexStatusOriginal, type IndexStatusWithLiterals as IndexStatusWithLiteralsOriginal, type ListDataCollectionsRequest as ListDataCollectionsRequestOriginal, type ListDataCollectionsResponse as ListDataCollectionsResponseOriginal, type MessageEnvelope as MessageEnvelopeOriginal, type MultiReference as MultiReferenceOriginal, type MultilingualOptions as MultilingualOptionsOriginal, type NumberRange as NumberRangeOriginal, type ObjectField as ObjectFieldOriginal, Order as OrderOriginal, type OrderWithLiterals as OrderWithLiteralsOriginal, type PageLink as PageLinkOriginal, type PageLinkPluginOptions as PageLinkPluginOptionsOriginal, type PagingMetadataV2 as PagingMetadataV2Original, PagingMode as PagingModeOriginal, type PagingModeWithLiterals as PagingModeWithLiteralsOriginal, type Paging as PagingOriginal, type Permissions as PermissionsOriginal, type PluginCmsOptions as PluginCmsOptionsOriginal, type PluginOptionsOneOf as PluginOptionsOneOfOriginal, type Plugin as PluginOriginal, PluginType as PluginTypeOriginal, type PluginTypeWithLiterals as PluginTypeWithLiteralsOriginal, type PluginUpdate as PluginUpdateOriginal, type PublishPluginOptions as PublishPluginOptionsOriginal, QueryOperator as QueryOperatorOriginal, type QueryOperatorWithLiterals as QueryOperatorWithLiteralsOriginal, type Reference as ReferenceOriginal, type RestorationCollection as RestorationCollectionOriginal, type RestoreDataCollectionRequest as RestoreDataCollectionRequestOriginal, type RestoreDataCollectionResponse as RestoreDataCollectionResponseOriginal, type RestoreDataCollectionsFromSnapshotRequest as RestoreDataCollectionsFromSnapshotRequestOriginal, type RestoreDataCollectionsFromSnapshotResponse as RestoreDataCollectionsFromSnapshotResponseOriginal, type RestoreInfo as RestoreInfoOriginal, Role as RoleOriginal, type RoleWithLiterals as RoleWithLiteralsOriginal, Segment as SegmentOriginal, type SegmentWithLiterals as SegmentWithLiteralsOriginal, type SingleItemPluginOptions as SingleItemPluginOptionsOriginal, type SiteSort as SiteSortOriginal, type SnapshotCollection as SnapshotCollectionOriginal, SortOrder as SortOrderOriginal, type SortOrderWithLiterals as SortOrderWithLiteralsOriginal, type Sort as SortOriginal, type Sorting as SortingOriginal, Status as StatusOriginal, type StatusWithLiterals as StatusWithLiteralsOriginal, type StringLengthRange as StringLengthRangeOriginal, type TypeMetadataMetadataOneOf as TypeMetadataMetadataOneOfOriginal, type TypeMetadata as TypeMetadataOriginal, Type as TypeOriginal, type TypeWithLiterals as TypeWithLiteralsOriginal, type UpdateDataCollectionFieldRequest as UpdateDataCollectionFieldRequestOriginal, type UpdateDataCollectionFieldResponse as UpdateDataCollectionFieldResponseOriginal, type UpdateDataCollectionRequest as UpdateDataCollectionRequestOriginal, type UpdateDataCollectionResponse as UpdateDataCollectionResponseOriginal, type UpdateDataPermissionsRequest as UpdateDataPermissionsRequestOriginal, type UpdateDataPermissionsResponse as UpdateDataPermissionsResponseOriginal, type UrlizedOnlyPattern as UrlizedOnlyPatternOriginal, type UrlizedPluginOptions as UrlizedPluginOptionsOriginal, WebhookIdentityType as WebhookIdentityTypeOriginal, type WebhookIdentityTypeWithLiterals as WebhookIdentityTypeWithLiteralsOriginal, type _Array as _ArrayOriginal, type _Object as _ObjectOriginal, type __PublicMethodMetaInfo, createDataCollection, createDataCollectionField, deleteDataCollection, deleteDataCollectionField, getDataCollection, listDataCollections, restoreDataCollection, updateDataCollection, updateDataCollectionField };
|