@wix/data 1.0.161 → 1.0.162
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.
|
@@ -973,26 +973,27 @@ declare class BadRequestWixError extends Error {
|
|
|
973
973
|
static readonly __type = "wix_spi_error";
|
|
974
974
|
}
|
|
975
975
|
|
|
976
|
-
type ServicePluginMethodInput
|
|
976
|
+
type ServicePluginMethodInput = {
|
|
977
977
|
request: any;
|
|
978
978
|
metadata: any;
|
|
979
979
|
};
|
|
980
|
-
type ServicePluginContract
|
|
981
|
-
type ServicePluginMethodMetadata
|
|
980
|
+
type ServicePluginContract = Record<string, (payload: ServicePluginMethodInput) => unknown | Promise<unknown>>;
|
|
981
|
+
type ServicePluginMethodMetadata = {
|
|
982
982
|
name: string;
|
|
983
983
|
primaryHttpMappingPath: string;
|
|
984
984
|
transformations: {
|
|
985
|
-
fromREST: (...args: unknown[]) => ServicePluginMethodInput
|
|
985
|
+
fromREST: (...args: unknown[]) => ServicePluginMethodInput;
|
|
986
986
|
toREST: (...args: unknown[]) => unknown;
|
|
987
987
|
};
|
|
988
988
|
};
|
|
989
|
-
type ServicePluginDefinition
|
|
989
|
+
type ServicePluginDefinition<Contract extends ServicePluginContract> = {
|
|
990
990
|
__type: 'service-plugin-definition';
|
|
991
991
|
componentType: string;
|
|
992
|
-
methods: ServicePluginMethodMetadata
|
|
992
|
+
methods: ServicePluginMethodMetadata[];
|
|
993
993
|
__contract: Contract;
|
|
994
994
|
};
|
|
995
|
-
declare function ServicePluginDefinition
|
|
995
|
+
declare function ServicePluginDefinition<Contract extends ServicePluginContract>(componentType: string, methods: ServicePluginMethodMetadata[]): ServicePluginDefinition<Contract>;
|
|
996
|
+
type BuildServicePluginDefinition<T extends ServicePluginDefinition<any>> = (implementation: T['__contract']) => void;
|
|
996
997
|
|
|
997
998
|
declare global {
|
|
998
999
|
// eslint-disable-next-line @typescript-eslint/consistent-type-definitions -- It has to be an `interface` so that it can be merged.
|
|
@@ -1070,7 +1071,7 @@ interface GetCapabilitiesEnvelope {
|
|
|
1070
1071
|
request: GetCapabilitiesRequest;
|
|
1071
1072
|
metadata: Context;
|
|
1072
1073
|
}
|
|
1073
|
-
declare const provideHandlers$1: ServicePluginDefinition
|
|
1074
|
+
declare const provideHandlers$1: ServicePluginDefinition<{
|
|
1074
1075
|
/**
|
|
1075
1076
|
*
|
|
1076
1077
|
* Retrieves a list of items based on the provided filtering, sorting, and paging preferences. */
|
|
@@ -1147,35 +1148,6 @@ declare const provideHandlers$1: ServicePluginDefinition$1<{
|
|
|
1147
1148
|
getCapabilities(payload: GetCapabilitiesEnvelope): GetCapabilitiesResponse | Promise<GetCapabilitiesResponse>;
|
|
1148
1149
|
}>;
|
|
1149
1150
|
|
|
1150
|
-
type ServicePluginMethodInput = {
|
|
1151
|
-
request: any;
|
|
1152
|
-
metadata: any;
|
|
1153
|
-
};
|
|
1154
|
-
type ServicePluginContract = Record<string, (payload: ServicePluginMethodInput) => unknown | Promise<unknown>>;
|
|
1155
|
-
type ServicePluginMethodMetadata = {
|
|
1156
|
-
name: string;
|
|
1157
|
-
primaryHttpMappingPath: string;
|
|
1158
|
-
transformations: {
|
|
1159
|
-
fromREST: (...args: unknown[]) => ServicePluginMethodInput;
|
|
1160
|
-
toREST: (...args: unknown[]) => unknown;
|
|
1161
|
-
};
|
|
1162
|
-
};
|
|
1163
|
-
type ServicePluginDefinition<Contract extends ServicePluginContract> = {
|
|
1164
|
-
__type: 'service-plugin-definition';
|
|
1165
|
-
componentType: string;
|
|
1166
|
-
methods: ServicePluginMethodMetadata[];
|
|
1167
|
-
__contract: Contract;
|
|
1168
|
-
};
|
|
1169
|
-
declare function ServicePluginDefinition<Contract extends ServicePluginContract>(componentType: string, methods: ServicePluginMethodMetadata[]): ServicePluginDefinition<Contract>;
|
|
1170
|
-
type BuildServicePluginDefinition<T extends ServicePluginDefinition<any>> = (implementation: T['__contract']) => void;
|
|
1171
|
-
|
|
1172
|
-
declare global {
|
|
1173
|
-
// eslint-disable-next-line @typescript-eslint/consistent-type-definitions -- It has to be an `interface` so that it can be merged.
|
|
1174
|
-
interface SymbolConstructor {
|
|
1175
|
-
readonly observable: symbol;
|
|
1176
|
-
}
|
|
1177
|
-
}
|
|
1178
|
-
|
|
1179
1151
|
declare function createServicePluginModule<T extends ServicePluginDefinition<any>>(servicePluginDefinition: T): BuildServicePluginDefinition<T> & T;
|
|
1180
1152
|
|
|
1181
1153
|
type _publicProvideHandlersType = typeof provideHandlers$1;
|
|
@@ -831,26 +831,27 @@ interface IdentificationDataIdOneOf {
|
|
|
831
831
|
appId?: string;
|
|
832
832
|
}
|
|
833
833
|
|
|
834
|
-
type ServicePluginMethodInput
|
|
834
|
+
type ServicePluginMethodInput = {
|
|
835
835
|
request: any;
|
|
836
836
|
metadata: any;
|
|
837
837
|
};
|
|
838
|
-
type ServicePluginContract
|
|
839
|
-
type ServicePluginMethodMetadata
|
|
838
|
+
type ServicePluginContract = Record<string, (payload: ServicePluginMethodInput) => unknown | Promise<unknown>>;
|
|
839
|
+
type ServicePluginMethodMetadata = {
|
|
840
840
|
name: string;
|
|
841
841
|
primaryHttpMappingPath: string;
|
|
842
842
|
transformations: {
|
|
843
|
-
fromREST: (...args: unknown[]) => ServicePluginMethodInput
|
|
843
|
+
fromREST: (...args: unknown[]) => ServicePluginMethodInput;
|
|
844
844
|
toREST: (...args: unknown[]) => unknown;
|
|
845
845
|
};
|
|
846
846
|
};
|
|
847
|
-
type ServicePluginDefinition
|
|
847
|
+
type ServicePluginDefinition<Contract extends ServicePluginContract> = {
|
|
848
848
|
__type: 'service-plugin-definition';
|
|
849
849
|
componentType: string;
|
|
850
|
-
methods: ServicePluginMethodMetadata
|
|
850
|
+
methods: ServicePluginMethodMetadata[];
|
|
851
851
|
__contract: Contract;
|
|
852
852
|
};
|
|
853
|
-
declare function ServicePluginDefinition
|
|
853
|
+
declare function ServicePluginDefinition<Contract extends ServicePluginContract>(componentType: string, methods: ServicePluginMethodMetadata[]): ServicePluginDefinition<Contract>;
|
|
854
|
+
type BuildServicePluginDefinition<T extends ServicePluginDefinition<any>> = (implementation: T['__contract']) => void;
|
|
854
855
|
|
|
855
856
|
declare global {
|
|
856
857
|
// eslint-disable-next-line @typescript-eslint/consistent-type-definitions -- It has to be an `interface` so that it can be merged.
|
|
@@ -928,7 +929,7 @@ interface GetCapabilitiesEnvelope {
|
|
|
928
929
|
request: GetCapabilitiesRequest;
|
|
929
930
|
metadata: Context;
|
|
930
931
|
}
|
|
931
|
-
declare const provideHandlers$1: ServicePluginDefinition
|
|
932
|
+
declare const provideHandlers$1: ServicePluginDefinition<{
|
|
932
933
|
/**
|
|
933
934
|
*
|
|
934
935
|
* Retrieves a list of items based on the provided filtering, sorting, and paging preferences. */
|
|
@@ -1005,35 +1006,6 @@ declare const provideHandlers$1: ServicePluginDefinition$1<{
|
|
|
1005
1006
|
getCapabilities(payload: GetCapabilitiesEnvelope): GetCapabilitiesResponse | Promise<GetCapabilitiesResponse>;
|
|
1006
1007
|
}>;
|
|
1007
1008
|
|
|
1008
|
-
type ServicePluginMethodInput = {
|
|
1009
|
-
request: any;
|
|
1010
|
-
metadata: any;
|
|
1011
|
-
};
|
|
1012
|
-
type ServicePluginContract = Record<string, (payload: ServicePluginMethodInput) => unknown | Promise<unknown>>;
|
|
1013
|
-
type ServicePluginMethodMetadata = {
|
|
1014
|
-
name: string;
|
|
1015
|
-
primaryHttpMappingPath: string;
|
|
1016
|
-
transformations: {
|
|
1017
|
-
fromREST: (...args: unknown[]) => ServicePluginMethodInput;
|
|
1018
|
-
toREST: (...args: unknown[]) => unknown;
|
|
1019
|
-
};
|
|
1020
|
-
};
|
|
1021
|
-
type ServicePluginDefinition<Contract extends ServicePluginContract> = {
|
|
1022
|
-
__type: 'service-plugin-definition';
|
|
1023
|
-
componentType: string;
|
|
1024
|
-
methods: ServicePluginMethodMetadata[];
|
|
1025
|
-
__contract: Contract;
|
|
1026
|
-
};
|
|
1027
|
-
declare function ServicePluginDefinition<Contract extends ServicePluginContract>(componentType: string, methods: ServicePluginMethodMetadata[]): ServicePluginDefinition<Contract>;
|
|
1028
|
-
type BuildServicePluginDefinition<T extends ServicePluginDefinition<any>> = (implementation: T['__contract']) => void;
|
|
1029
|
-
|
|
1030
|
-
declare global {
|
|
1031
|
-
// eslint-disable-next-line @typescript-eslint/consistent-type-definitions -- It has to be an `interface` so that it can be merged.
|
|
1032
|
-
interface SymbolConstructor {
|
|
1033
|
-
readonly observable: symbol;
|
|
1034
|
-
}
|
|
1035
|
-
}
|
|
1036
|
-
|
|
1037
1009
|
declare function createServicePluginModule<T extends ServicePluginDefinition<any>>(servicePluginDefinition: T): BuildServicePluginDefinition<T> & T;
|
|
1038
1010
|
|
|
1039
1011
|
type _publicProvideHandlersType = typeof provideHandlers$1;
|