prisma 6.6.0-dev.10 → 6.6.0-dev.101
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/index.js +3786 -1175
- package/build/prisma_schema_build_bg.wasm +0 -0
- package/build/public/assets/index.js +1 -1
- package/build/schema_engine_bg.wasm +0 -0
- package/package.json +21 -19
- package/preinstall/index.js +4 -4
- package/prisma-client/generator-build/index.js +15648 -9416
- package/prisma-client/package.json +44 -24
- package/prisma-client/runtime/binary.js +120 -120
- package/prisma-client/runtime/binary.mjs +291 -0
- package/prisma-client/runtime/client.d.mts +3604 -0
- package/prisma-client/runtime/client.d.ts +430 -299
- package/prisma-client/runtime/client.js +41 -38
- package/prisma-client/runtime/client.mjs +113 -0
- package/prisma-client/runtime/edge-esm.js +18 -18
- package/prisma-client/runtime/edge.d.ts +3604 -0
- package/prisma-client/runtime/edge.js +18 -18
- package/prisma-client/runtime/index-browser.d.ts +3 -0
- package/prisma-client/runtime/index-browser.js +1 -1
- package/prisma-client/runtime/library.d.mts +3604 -0
- package/prisma-client/runtime/library.d.ts +430 -299
- package/prisma-client/runtime/library.js +65 -65
- package/prisma-client/runtime/library.mjs +150 -0
- package/prisma-client/runtime/query_compiler_bg.mysql.js +2 -2
- package/prisma-client/runtime/query_compiler_bg.mysql.mjs +2 -0
- package/prisma-client/runtime/query_compiler_bg.postgresql.js +2 -2
- package/prisma-client/runtime/query_compiler_bg.postgresql.mjs +2 -0
- package/prisma-client/runtime/query_compiler_bg.sqlite.js +2 -2
- package/prisma-client/runtime/query_compiler_bg.sqlite.mjs +2 -0
- package/prisma-client/runtime/query_engine_bg.mysql.js +2 -2
- package/prisma-client/runtime/query_engine_bg.mysql.mjs +2 -0
- package/prisma-client/runtime/query_engine_bg.postgresql.js +2 -2
- package/prisma-client/runtime/query_engine_bg.postgresql.mjs +2 -0
- package/prisma-client/runtime/query_engine_bg.sqlite.js +2 -2
- package/prisma-client/runtime/query_engine_bg.sqlite.mjs +2 -0
- package/prisma-client/runtime/react-native.d.ts +430 -299
- package/prisma-client/runtime/react-native.js +26 -26
- package/prisma-client/scripts/default-index.js +3 -3
@@ -23,7 +23,7 @@ declare type AccelerateEngineConfig = {
|
|
23
23
|
|
24
24
|
declare type AccelerateUtils = EngineConfig['accelerateUtils'];
|
25
25
|
|
26
|
-
export declare type Action = keyof typeof
|
26
|
+
export declare type Action = keyof typeof DMMF_2.ModelAction | 'executeRaw' | 'queryRaw' | 'runCommandRaw';
|
27
27
|
|
28
28
|
declare type ActiveConnectorType = Exclude<ConnectorType, 'postgres' | 'prisma+postgres'>;
|
29
29
|
|
@@ -47,6 +47,7 @@ export declare type AllModelsToStringIndex<TypeMap extends TypeMapDef, Args exte
|
|
47
47
|
} : {};
|
48
48
|
|
49
49
|
declare class AnyNull extends NullTypesEnumValue {
|
50
|
+
private readonly _brand_AnyNull;
|
50
51
|
}
|
51
52
|
|
52
53
|
export declare type ApplyOmit<T, OmitConfig> = Compute<{
|
@@ -91,7 +92,7 @@ declare interface Attributes {
|
|
91
92
|
declare type AttributeValue = string | number | boolean | Array<null | undefined | string> | Array<null | undefined | number> | Array<null | undefined | boolean>;
|
92
93
|
|
93
94
|
export declare type BaseDMMF = {
|
94
|
-
readonly datamodel: Omit<
|
95
|
+
readonly datamodel: Omit<DMMF_2.Datamodel, 'indexes'>;
|
95
96
|
};
|
96
97
|
|
97
98
|
declare type BatchArgs = {
|
@@ -122,8 +123,10 @@ declare type BatchQueryOptionsCbArgs = {
|
|
122
123
|
__internalParams: BatchInternalParams;
|
123
124
|
};
|
124
125
|
|
126
|
+
declare type BatchResponse = MultiBatchResponse | CompactedBatchResponse;
|
127
|
+
|
125
128
|
declare type BatchTransactionOptions = {
|
126
|
-
isolationLevel?:
|
129
|
+
isolationLevel?: IsolationLevel;
|
127
130
|
};
|
128
131
|
|
129
132
|
declare interface BinaryTargetsEnvValue {
|
@@ -204,14 +207,23 @@ declare const ColumnTypeEnum: {
|
|
204
207
|
readonly UnknownNumber: 128;
|
205
208
|
};
|
206
209
|
|
210
|
+
declare type CompactedBatchResponse = {
|
211
|
+
type: 'compacted';
|
212
|
+
plan: object;
|
213
|
+
arguments: Map<string, {}>[];
|
214
|
+
nestedSelection: string[];
|
215
|
+
keys: string[];
|
216
|
+
expectNonEmpty: boolean;
|
217
|
+
};
|
218
|
+
|
207
219
|
declare type CompilerWasmLoadingConfig = {
|
208
220
|
/**
|
209
221
|
* WASM-bindgen runtime for corresponding module
|
210
222
|
*/
|
211
|
-
getRuntime: () => {
|
212
|
-
__wbg_set_wasm(exports: unknown):
|
223
|
+
getRuntime: () => Promise<{
|
224
|
+
__wbg_set_wasm(exports: unknown): void;
|
213
225
|
QueryCompiler: QueryCompilerConstructor;
|
214
|
-
}
|
226
|
+
}>;
|
215
227
|
/**
|
216
228
|
* Loads the raw wasm module for the wasm compiler engine. This configuration is
|
217
229
|
* generated specifically for each type of client, eg. Node.js client and Edge
|
@@ -347,6 +359,22 @@ declare type DataLoaderOptions<T> = {
|
|
347
359
|
batchOrder: (requestA: T, requestB: T) => number;
|
348
360
|
};
|
349
361
|
|
362
|
+
declare type Datamodel = ReadonlyDeep_2<{
|
363
|
+
models: Model[];
|
364
|
+
enums: DatamodelEnum[];
|
365
|
+
types: Model[];
|
366
|
+
indexes: Index[];
|
367
|
+
}>;
|
368
|
+
|
369
|
+
declare type DatamodelEnum = ReadonlyDeep_2<{
|
370
|
+
name: string;
|
371
|
+
values: EnumValue[];
|
372
|
+
dbName?: string | null;
|
373
|
+
documentation?: string;
|
374
|
+
}>;
|
375
|
+
|
376
|
+
declare function datamodelEnumToSchemaEnum(datamodelEnum: DatamodelEnum): SchemaEnum;
|
377
|
+
|
350
378
|
declare type Datasource = {
|
351
379
|
url?: string;
|
352
380
|
};
|
@@ -356,6 +384,7 @@ declare type Datasources = {
|
|
356
384
|
};
|
357
385
|
|
358
386
|
declare class DbNull extends NullTypesEnumValue {
|
387
|
+
private readonly _brand_DbNull;
|
359
388
|
}
|
360
389
|
|
361
390
|
export declare const Debug: typeof debugCreate & {
|
@@ -681,6 +710,12 @@ declare function defineExtension(ext: ExtensionArgs | ((client: Client) => Clien
|
|
681
710
|
|
682
711
|
declare const denylist: readonly ["$connect", "$disconnect", "$on", "$transaction", "$use", "$extends"];
|
683
712
|
|
713
|
+
declare type Deprecation = ReadonlyDeep_2<{
|
714
|
+
sinceVersion: string;
|
715
|
+
reason: string;
|
716
|
+
plannedRemovalVersion?: string;
|
717
|
+
}>;
|
718
|
+
|
684
719
|
declare type DeserializedResponse = Array<Record<string, unknown>>;
|
685
720
|
|
686
721
|
export declare function deserializeJsonResponse(result: unknown): unknown;
|
@@ -708,263 +743,104 @@ export declare type DevTypeMapFnDef = {
|
|
708
743
|
};
|
709
744
|
|
710
745
|
export declare namespace DMMF {
|
711
|
-
export
|
712
|
-
|
713
|
-
|
714
|
-
|
715
|
-
|
716
|
-
|
717
|
-
|
718
|
-
|
719
|
-
|
720
|
-
|
721
|
-
|
722
|
-
|
723
|
-
|
724
|
-
|
725
|
-
|
726
|
-
|
727
|
-
|
728
|
-
|
729
|
-
|
730
|
-
|
731
|
-
|
732
|
-
|
733
|
-
|
734
|
-
|
735
|
-
|
736
|
-
|
737
|
-
|
738
|
-
|
739
|
-
|
740
|
-
|
741
|
-
|
742
|
-
|
743
|
-
|
744
|
-
|
745
|
-
|
746
|
-
|
747
|
-
|
748
|
-
name: string;
|
749
|
-
fields: string[];
|
750
|
-
}>;
|
751
|
-
export type PrimaryKey = ReadonlyDeep_2<{
|
752
|
-
name: string | null;
|
753
|
-
fields: string[];
|
754
|
-
}>;
|
755
|
-
export type Model = ReadonlyDeep_2<{
|
756
|
-
name: string;
|
757
|
-
dbName: string | null;
|
758
|
-
schema: string | null;
|
759
|
-
fields: Field[];
|
760
|
-
uniqueFields: string[][];
|
761
|
-
uniqueIndexes: uniqueIndex[];
|
762
|
-
documentation?: string;
|
763
|
-
primaryKey: PrimaryKey | null;
|
764
|
-
isGenerated?: boolean;
|
765
|
-
}>;
|
766
|
-
export type FieldKind = 'scalar' | 'object' | 'enum' | 'unsupported';
|
767
|
-
export type FieldNamespace = 'model' | 'prisma';
|
768
|
-
export type FieldLocation = 'scalar' | 'inputObjectTypes' | 'outputObjectTypes' | 'enumTypes' | 'fieldRefTypes';
|
769
|
-
export type Field = ReadonlyDeep_2<{
|
770
|
-
kind: FieldKind;
|
771
|
-
name: string;
|
772
|
-
isRequired: boolean;
|
773
|
-
isList: boolean;
|
774
|
-
isUnique: boolean;
|
775
|
-
isId: boolean;
|
776
|
-
isReadOnly: boolean;
|
777
|
-
isGenerated?: boolean;
|
778
|
-
isUpdatedAt?: boolean;
|
779
|
-
/**
|
780
|
-
* Describes the data type in the same the way it is defined in the Prisma schema:
|
781
|
-
* BigInt, Boolean, Bytes, DateTime, Decimal, Float, Int, JSON, String, $ModelName
|
782
|
-
*/
|
783
|
-
type: string;
|
784
|
-
/**
|
785
|
-
* Native database type, if specified.
|
786
|
-
* For example, `@db.VarChar(191)` is encoded as `['VarChar', ['191']]`,
|
787
|
-
* `@db.Text` is encoded as `['Text', []]`.
|
788
|
-
*/
|
789
|
-
nativeType?: [string, string[]] | null;
|
790
|
-
dbName?: string | null;
|
791
|
-
hasDefaultValue: boolean;
|
792
|
-
default?: FieldDefault | FieldDefaultScalar | FieldDefaultScalar[];
|
793
|
-
relationFromFields?: string[];
|
794
|
-
relationToFields?: string[];
|
795
|
-
relationOnDelete?: string;
|
796
|
-
relationOnUpdate?: string;
|
797
|
-
relationName?: string;
|
798
|
-
documentation?: string;
|
799
|
-
}>;
|
800
|
-
export type FieldDefault = ReadonlyDeep_2<{
|
801
|
-
name: string;
|
802
|
-
args: Array<string | number>;
|
803
|
-
}>;
|
804
|
-
export type FieldDefaultScalar = string | boolean | number;
|
805
|
-
export type Index = ReadonlyDeep_2<{
|
806
|
-
model: string;
|
807
|
-
type: IndexType;
|
808
|
-
isDefinedOnField: boolean;
|
809
|
-
name?: string;
|
810
|
-
dbName?: string;
|
811
|
-
algorithm?: string;
|
812
|
-
clustered?: boolean;
|
813
|
-
fields: IndexField[];
|
814
|
-
}>;
|
815
|
-
export type IndexType = 'id' | 'normal' | 'unique' | 'fulltext';
|
816
|
-
export type IndexField = ReadonlyDeep_2<{
|
817
|
-
name: string;
|
818
|
-
sortOrder?: SortOrder;
|
819
|
-
length?: number;
|
820
|
-
operatorClass?: string;
|
821
|
-
}>;
|
822
|
-
export type SortOrder = 'asc' | 'desc';
|
823
|
-
export type Schema = ReadonlyDeep_2<{
|
824
|
-
rootQueryType?: string;
|
825
|
-
rootMutationType?: string;
|
826
|
-
inputObjectTypes: {
|
827
|
-
model?: InputType[];
|
828
|
-
prisma: InputType[];
|
829
|
-
};
|
830
|
-
outputObjectTypes: {
|
831
|
-
model: OutputType[];
|
832
|
-
prisma: OutputType[];
|
833
|
-
};
|
834
|
-
enumTypes: {
|
835
|
-
model?: SchemaEnum[];
|
836
|
-
prisma: SchemaEnum[];
|
837
|
-
};
|
838
|
-
fieldRefTypes: {
|
839
|
-
prisma?: FieldRefType[];
|
840
|
-
};
|
841
|
-
}>;
|
842
|
-
export type Query = ReadonlyDeep_2<{
|
843
|
-
name: string;
|
844
|
-
args: SchemaArg[];
|
845
|
-
output: QueryOutput;
|
846
|
-
}>;
|
847
|
-
export type QueryOutput = ReadonlyDeep_2<{
|
848
|
-
name: string;
|
849
|
-
isRequired: boolean;
|
850
|
-
isList: boolean;
|
851
|
-
}>;
|
852
|
-
export type TypeRef<AllowedLocations extends FieldLocation> = {
|
853
|
-
isList: boolean;
|
854
|
-
type: string;
|
855
|
-
location: AllowedLocations;
|
856
|
-
namespace?: FieldNamespace;
|
857
|
-
};
|
858
|
-
export type InputTypeRef = TypeRef<'scalar' | 'inputObjectTypes' | 'enumTypes' | 'fieldRefTypes'>;
|
859
|
-
export type SchemaArg = ReadonlyDeep_2<{
|
860
|
-
name: string;
|
861
|
-
comment?: string;
|
862
|
-
isNullable: boolean;
|
863
|
-
isRequired: boolean;
|
864
|
-
inputTypes: InputTypeRef[];
|
865
|
-
deprecation?: Deprecation;
|
866
|
-
}>;
|
867
|
-
export type OutputType = ReadonlyDeep_2<{
|
868
|
-
name: string;
|
869
|
-
fields: SchemaField[];
|
870
|
-
}>;
|
871
|
-
export type SchemaField = ReadonlyDeep_2<{
|
872
|
-
name: string;
|
873
|
-
isNullable?: boolean;
|
874
|
-
outputType: OutputTypeRef;
|
875
|
-
args: SchemaArg[];
|
876
|
-
deprecation?: Deprecation;
|
877
|
-
documentation?: string;
|
878
|
-
}>;
|
879
|
-
export type OutputTypeRef = TypeRef<'scalar' | 'outputObjectTypes' | 'enumTypes'>;
|
880
|
-
export type Deprecation = ReadonlyDeep_2<{
|
881
|
-
sinceVersion: string;
|
882
|
-
reason: string;
|
883
|
-
plannedRemovalVersion?: string;
|
884
|
-
}>;
|
885
|
-
export type InputType = ReadonlyDeep_2<{
|
886
|
-
name: string;
|
887
|
-
constraints: {
|
888
|
-
maxNumFields: number | null;
|
889
|
-
minNumFields: number | null;
|
890
|
-
fields?: string[];
|
891
|
-
};
|
892
|
-
meta?: {
|
893
|
-
source?: string;
|
894
|
-
};
|
895
|
-
fields: SchemaArg[];
|
896
|
-
}>;
|
897
|
-
export type FieldRefType = ReadonlyDeep_2<{
|
898
|
-
name: string;
|
899
|
-
allowTypes: FieldRefAllowType[];
|
900
|
-
fields: SchemaArg[];
|
901
|
-
}>;
|
902
|
-
export type FieldRefAllowType = TypeRef<'scalar' | 'enumTypes'>;
|
903
|
-
export type ModelMapping = ReadonlyDeep_2<{
|
904
|
-
model: string;
|
905
|
-
plural: string;
|
906
|
-
findUnique?: string | null;
|
907
|
-
findUniqueOrThrow?: string | null;
|
908
|
-
findFirst?: string | null;
|
909
|
-
findFirstOrThrow?: string | null;
|
910
|
-
findMany?: string | null;
|
911
|
-
create?: string | null;
|
912
|
-
createMany?: string | null;
|
913
|
-
createManyAndReturn?: string | null;
|
914
|
-
update?: string | null;
|
915
|
-
updateMany?: string | null;
|
916
|
-
updateManyAndReturn?: string | null;
|
917
|
-
upsert?: string | null;
|
918
|
-
delete?: string | null;
|
919
|
-
deleteMany?: string | null;
|
920
|
-
aggregate?: string | null;
|
921
|
-
groupBy?: string | null;
|
922
|
-
count?: string | null;
|
923
|
-
findRaw?: string | null;
|
924
|
-
aggregateRaw?: string | null;
|
925
|
-
}>;
|
926
|
-
export enum ModelAction {
|
927
|
-
findUnique = "findUnique",
|
928
|
-
findUniqueOrThrow = "findUniqueOrThrow",
|
929
|
-
findFirst = "findFirst",
|
930
|
-
findFirstOrThrow = "findFirstOrThrow",
|
931
|
-
findMany = "findMany",
|
932
|
-
create = "create",
|
933
|
-
createMany = "createMany",
|
934
|
-
createManyAndReturn = "createManyAndReturn",
|
935
|
-
update = "update",
|
936
|
-
updateMany = "updateMany",
|
937
|
-
updateManyAndReturn = "updateManyAndReturn",
|
938
|
-
upsert = "upsert",
|
939
|
-
delete = "delete",
|
940
|
-
deleteMany = "deleteMany",
|
941
|
-
groupBy = "groupBy",
|
942
|
-
count = "count",// TODO: count does not actually exist, why?
|
943
|
-
aggregate = "aggregate",
|
944
|
-
findRaw = "findRaw",
|
945
|
-
aggregateRaw = "aggregateRaw"
|
746
|
+
export {
|
747
|
+
datamodelEnumToSchemaEnum,
|
748
|
+
Document_2 as Document,
|
749
|
+
Mappings,
|
750
|
+
OtherOperationMappings,
|
751
|
+
DatamodelEnum,
|
752
|
+
SchemaEnum,
|
753
|
+
EnumValue,
|
754
|
+
Datamodel,
|
755
|
+
uniqueIndex,
|
756
|
+
PrimaryKey,
|
757
|
+
Model,
|
758
|
+
FieldKind,
|
759
|
+
FieldNamespace,
|
760
|
+
FieldLocation,
|
761
|
+
Field,
|
762
|
+
FieldDefault,
|
763
|
+
FieldDefaultScalar,
|
764
|
+
Index,
|
765
|
+
IndexType,
|
766
|
+
IndexField,
|
767
|
+
SortOrder,
|
768
|
+
Schema,
|
769
|
+
Query,
|
770
|
+
QueryOutput,
|
771
|
+
TypeRef,
|
772
|
+
InputTypeRef,
|
773
|
+
SchemaArg,
|
774
|
+
OutputType,
|
775
|
+
SchemaField,
|
776
|
+
OutputTypeRef,
|
777
|
+
Deprecation,
|
778
|
+
InputType,
|
779
|
+
FieldRefType,
|
780
|
+
FieldRefAllowType,
|
781
|
+
ModelMapping,
|
782
|
+
ModelAction
|
946
783
|
}
|
947
784
|
}
|
948
785
|
|
949
|
-
|
786
|
+
declare namespace DMMF_2 {
|
787
|
+
export {
|
788
|
+
datamodelEnumToSchemaEnum,
|
789
|
+
Document_2 as Document,
|
790
|
+
Mappings,
|
791
|
+
OtherOperationMappings,
|
792
|
+
DatamodelEnum,
|
793
|
+
SchemaEnum,
|
794
|
+
EnumValue,
|
795
|
+
Datamodel,
|
796
|
+
uniqueIndex,
|
797
|
+
PrimaryKey,
|
798
|
+
Model,
|
799
|
+
FieldKind,
|
800
|
+
FieldNamespace,
|
801
|
+
FieldLocation,
|
802
|
+
Field,
|
803
|
+
FieldDefault,
|
804
|
+
FieldDefaultScalar,
|
805
|
+
Index,
|
806
|
+
IndexType,
|
807
|
+
IndexField,
|
808
|
+
SortOrder,
|
809
|
+
Schema,
|
810
|
+
Query,
|
811
|
+
QueryOutput,
|
812
|
+
TypeRef,
|
813
|
+
InputTypeRef,
|
814
|
+
SchemaArg,
|
815
|
+
OutputType,
|
816
|
+
SchemaField,
|
817
|
+
OutputTypeRef,
|
818
|
+
Deprecation,
|
819
|
+
InputType,
|
820
|
+
FieldRefType,
|
821
|
+
FieldRefAllowType,
|
822
|
+
ModelMapping,
|
823
|
+
ModelAction
|
824
|
+
}
|
825
|
+
}
|
950
826
|
|
951
|
-
export declare
|
952
|
-
|
953
|
-
|
954
|
-
|
955
|
-
|
956
|
-
|
957
|
-
|
958
|
-
|
959
|
-
|
960
|
-
|
961
|
-
|
962
|
-
|
963
|
-
|
827
|
+
export declare function dmmfToRuntimeDataModel(dmmfDataModel: DMMF_2.Datamodel): RuntimeDataModel;
|
828
|
+
|
829
|
+
declare type Document_2 = ReadonlyDeep_2<{
|
830
|
+
datamodel: Datamodel;
|
831
|
+
schema: Schema;
|
832
|
+
mappings: Mappings;
|
833
|
+
}>;
|
834
|
+
|
835
|
+
/**
|
836
|
+
* A generic driver adapter factory that allows the user to instantiate a
|
837
|
+
* driver adapter. The query and result types are specific to the adapter.
|
838
|
+
*/
|
839
|
+
declare interface DriverAdapterFactory<Query, Result> extends AdapterInfo {
|
964
840
|
/**
|
965
|
-
*
|
841
|
+
* Instantiate a driver adapter.
|
966
842
|
*/
|
967
|
-
|
843
|
+
connect(): Promise<Queryable<Query, Result>>;
|
968
844
|
}
|
969
845
|
|
970
846
|
/** Client */
|
@@ -1134,7 +1010,6 @@ declare interface Engine<InteractiveTransactionPayload = unknown> {
|
|
1134
1010
|
declare interface EngineConfig {
|
1135
1011
|
cwd: string;
|
1136
1012
|
dirname: string;
|
1137
|
-
datamodelPath: string;
|
1138
1013
|
enableDebugLogs?: boolean;
|
1139
1014
|
allowTriggerPanic?: boolean;
|
1140
1015
|
prismaPath?: string;
|
@@ -1161,10 +1036,9 @@ declare interface EngineConfig {
|
|
1161
1036
|
* rather than Prisma's Rust drivers.
|
1162
1037
|
* @remarks only used by LibraryEngine.ts
|
1163
1038
|
*/
|
1164
|
-
adapter?:
|
1039
|
+
adapter?: SqlDriverAdapterFactory;
|
1165
1040
|
/**
|
1166
1041
|
* The contents of the schema encoded into a string
|
1167
|
-
* @remarks only used by DataProxyEngine.ts
|
1168
1042
|
*/
|
1169
1043
|
inlineSchema: string;
|
1170
1044
|
/**
|
@@ -1215,8 +1089,6 @@ declare type EngineEvent<E extends EngineEventType> = E extends QueryEventType ?
|
|
1215
1089
|
|
1216
1090
|
declare type EngineEventType = QueryEventType | LogEventType;
|
1217
1091
|
|
1218
|
-
declare type EngineProtocol = 'graphql' | 'json';
|
1219
|
-
|
1220
1092
|
declare type EngineSpan = {
|
1221
1093
|
id: EngineSpanId;
|
1222
1094
|
parentId: string | null;
|
@@ -1236,10 +1108,10 @@ declare type EngineWasmLoadingConfig = {
|
|
1236
1108
|
/**
|
1237
1109
|
* WASM-bindgen runtime for corresponding module
|
1238
1110
|
*/
|
1239
|
-
getRuntime: () => {
|
1240
|
-
__wbg_set_wasm(exports: unknown):
|
1111
|
+
getRuntime: () => Promise<{
|
1112
|
+
__wbg_set_wasm(exports: unknown): void;
|
1241
1113
|
QueryEngine: QueryEngineConstructor;
|
1242
|
-
}
|
1114
|
+
}>;
|
1243
1115
|
/**
|
1244
1116
|
* Loads the raw wasm module for the wasm query engine. This configuration is
|
1245
1117
|
* generated specifically for each type of client, eg. Node.js client and Edge
|
@@ -1250,6 +1122,11 @@ declare type EngineWasmLoadingConfig = {
|
|
1250
1122
|
getQueryEngineWasmModule: () => Promise<unknown>;
|
1251
1123
|
};
|
1252
1124
|
|
1125
|
+
declare type EnumValue = ReadonlyDeep_2<{
|
1126
|
+
name: string;
|
1127
|
+
dbName: string | null;
|
1128
|
+
}>;
|
1129
|
+
|
1253
1130
|
declare type EnvPaths = {
|
1254
1131
|
rootEnvPath: string | null;
|
1255
1132
|
schemaEnvPath: string | undefined;
|
@@ -1268,6 +1145,9 @@ declare type Error_2 = {
|
|
1268
1145
|
} | {
|
1269
1146
|
kind: 'UnsupportedNativeDataType';
|
1270
1147
|
type: string;
|
1148
|
+
} | {
|
1149
|
+
kind: 'InvalidIsolationLevel';
|
1150
|
+
level: string;
|
1271
1151
|
} | {
|
1272
1152
|
kind: 'postgres';
|
1273
1153
|
code: string;
|
@@ -1296,7 +1176,7 @@ declare type ErrorCapturingInterface<T> = {
|
|
1296
1176
|
[K in keyof T]: ErrorCapturingFunction<T[K]>;
|
1297
1177
|
};
|
1298
1178
|
|
1299
|
-
declare interface
|
1179
|
+
declare interface ErrorCapturingSqlDriverAdapter extends ErrorCapturingInterface<SqlDriverAdapter> {
|
1300
1180
|
readonly errorRegistry: ErrorRegistry;
|
1301
1181
|
}
|
1302
1182
|
|
@@ -1453,6 +1333,51 @@ export declare type ExtractGlobalOmit<Options, ModelName extends string> = Optio
|
|
1453
1333
|
};
|
1454
1334
|
} ? GlobalOmit : {};
|
1455
1335
|
|
1336
|
+
declare type Field = ReadonlyDeep_2<{
|
1337
|
+
kind: FieldKind;
|
1338
|
+
name: string;
|
1339
|
+
isRequired: boolean;
|
1340
|
+
isList: boolean;
|
1341
|
+
isUnique: boolean;
|
1342
|
+
isId: boolean;
|
1343
|
+
isReadOnly: boolean;
|
1344
|
+
isGenerated?: boolean;
|
1345
|
+
isUpdatedAt?: boolean;
|
1346
|
+
/**
|
1347
|
+
* Describes the data type in the same the way it is defined in the Prisma schema:
|
1348
|
+
* BigInt, Boolean, Bytes, DateTime, Decimal, Float, Int, JSON, String, $ModelName
|
1349
|
+
*/
|
1350
|
+
type: string;
|
1351
|
+
/**
|
1352
|
+
* Native database type, if specified.
|
1353
|
+
* For example, `@db.VarChar(191)` is encoded as `['VarChar', ['191']]`,
|
1354
|
+
* `@db.Text` is encoded as `['Text', []]`.
|
1355
|
+
*/
|
1356
|
+
nativeType?: [string, string[]] | null;
|
1357
|
+
dbName?: string | null;
|
1358
|
+
hasDefaultValue: boolean;
|
1359
|
+
default?: FieldDefault | FieldDefaultScalar | FieldDefaultScalar[];
|
1360
|
+
relationFromFields?: string[];
|
1361
|
+
relationToFields?: string[];
|
1362
|
+
relationOnDelete?: string;
|
1363
|
+
relationOnUpdate?: string;
|
1364
|
+
relationName?: string;
|
1365
|
+
documentation?: string;
|
1366
|
+
}>;
|
1367
|
+
|
1368
|
+
declare type FieldDefault = ReadonlyDeep_2<{
|
1369
|
+
name: string;
|
1370
|
+
args: Array<string | number>;
|
1371
|
+
}>;
|
1372
|
+
|
1373
|
+
declare type FieldDefaultScalar = string | boolean | number;
|
1374
|
+
|
1375
|
+
declare type FieldKind = 'scalar' | 'object' | 'enum' | 'unsupported';
|
1376
|
+
|
1377
|
+
declare type FieldLocation = 'scalar' | 'inputObjectTypes' | 'outputObjectTypes' | 'enumTypes' | 'fieldRefTypes';
|
1378
|
+
|
1379
|
+
declare type FieldNamespace = 'model' | 'prisma';
|
1380
|
+
|
1456
1381
|
/**
|
1457
1382
|
* A reference to a specific field of a specific model
|
1458
1383
|
*/
|
@@ -1463,7 +1388,15 @@ export declare interface FieldRef<Model, FieldType> {
|
|
1463
1388
|
readonly isList: boolean;
|
1464
1389
|
}
|
1465
1390
|
|
1466
|
-
|
1391
|
+
declare type FieldRefAllowType = TypeRef<'scalar' | 'enumTypes'>;
|
1392
|
+
|
1393
|
+
declare type FieldRefType = ReadonlyDeep_2<{
|
1394
|
+
name: string;
|
1395
|
+
allowTypes: FieldRefAllowType[];
|
1396
|
+
fields: SchemaArg[];
|
1397
|
+
}>;
|
1398
|
+
|
1399
|
+
declare type FluentOperation = 'findUnique' | 'findUniqueOrThrow' | 'findFirst' | 'findFirstOrThrow' | 'create' | 'update' | 'upsert' | 'delete';
|
1467
1400
|
|
1468
1401
|
export declare interface Fn<Params = unknown, Returns = unknown> {
|
1469
1402
|
params: Params;
|
@@ -1697,16 +1630,15 @@ export declare function getPrismaClient(config: GetPrismaClientConfig): {
|
|
1697
1630
|
* loaded, this same config is passed to {@link getPrismaClient} which creates a
|
1698
1631
|
* closure with that config around a non-instantiated [[PrismaClient]].
|
1699
1632
|
*/
|
1700
|
-
declare type GetPrismaClientConfig = {
|
1633
|
+
export declare type GetPrismaClientConfig = {
|
1701
1634
|
runtimeDataModel: RuntimeDataModel;
|
1702
1635
|
generator?: GeneratorConfig;
|
1703
|
-
relativeEnvPaths
|
1636
|
+
relativeEnvPaths?: {
|
1704
1637
|
rootEnvPath?: string | null;
|
1705
1638
|
schemaEnvPath?: string | null;
|
1706
1639
|
};
|
1707
1640
|
relativePath: string;
|
1708
1641
|
dirname: string;
|
1709
|
-
filename?: string;
|
1710
1642
|
clientVersion: string;
|
1711
1643
|
engineVersion: string;
|
1712
1644
|
datasourceNames: string[];
|
@@ -1843,6 +1775,26 @@ declare type HrTime = [number, number];
|
|
1843
1775
|
*/
|
1844
1776
|
declare type HrTime_2 = [number, number];
|
1845
1777
|
|
1778
|
+
declare type Index = ReadonlyDeep_2<{
|
1779
|
+
model: string;
|
1780
|
+
type: IndexType;
|
1781
|
+
isDefinedOnField: boolean;
|
1782
|
+
name?: string;
|
1783
|
+
dbName?: string;
|
1784
|
+
algorithm?: string;
|
1785
|
+
clustered?: boolean;
|
1786
|
+
fields: IndexField[];
|
1787
|
+
}>;
|
1788
|
+
|
1789
|
+
declare type IndexField = ReadonlyDeep_2<{
|
1790
|
+
name: string;
|
1791
|
+
sortOrder?: SortOrder;
|
1792
|
+
length?: number;
|
1793
|
+
operatorClass?: string;
|
1794
|
+
}>;
|
1795
|
+
|
1796
|
+
declare type IndexType = 'id' | 'normal' | 'unique' | 'fulltext';
|
1797
|
+
|
1846
1798
|
/**
|
1847
1799
|
* Matches a JSON array.
|
1848
1800
|
* Unlike \`JsonArray\`, readonly arrays are assignable to this type.
|
@@ -1875,6 +1827,22 @@ export declare type InputJsonValue = string | number | boolean | InputJsonObject
|
|
1875
1827
|
toJSON(): unknown;
|
1876
1828
|
};
|
1877
1829
|
|
1830
|
+
declare type InputType = ReadonlyDeep_2<{
|
1831
|
+
name: string;
|
1832
|
+
constraints: {
|
1833
|
+
maxNumFields: number | null;
|
1834
|
+
minNumFields: number | null;
|
1835
|
+
fields?: string[];
|
1836
|
+
};
|
1837
|
+
meta?: {
|
1838
|
+
source?: string;
|
1839
|
+
grouping?: string;
|
1840
|
+
};
|
1841
|
+
fields: SchemaArg[];
|
1842
|
+
}>;
|
1843
|
+
|
1844
|
+
declare type InputTypeRef = TypeRef<'scalar' | 'inputObjectTypes' | 'enumTypes' | 'fieldRefTypes'>;
|
1845
|
+
|
1878
1846
|
declare type InteractiveTransactionInfo<Payload = unknown> = {
|
1879
1847
|
/**
|
1880
1848
|
* Transaction ID returned by the query engine.
|
@@ -1950,13 +1918,7 @@ declare type InternalRequestParams = {
|
|
1950
1918
|
customDataProxyFetch?: CustomDataProxyFetch;
|
1951
1919
|
} & Omit<QueryMiddlewareParams, 'runInTransaction'>;
|
1952
1920
|
|
1953
|
-
declare
|
1954
|
-
ReadUncommitted = "ReadUncommitted",
|
1955
|
-
ReadCommitted = "ReadCommitted",
|
1956
|
-
RepeatableRead = "RepeatableRead",
|
1957
|
-
Snapshot = "Snapshot",
|
1958
|
-
Serializable = "Serializable"
|
1959
|
-
}
|
1921
|
+
declare type IsolationLevel = 'READ UNCOMMITTED' | 'READ COMMITTED' | 'REPEATABLE READ' | 'SNAPSHOT' | 'SERIALIZABLE';
|
1960
1922
|
|
1961
1923
|
declare function isSkip(value: unknown): value is Skip;
|
1962
1924
|
|
@@ -2002,7 +1964,7 @@ export declare interface JsonArray extends Array<JsonValue> {
|
|
2002
1964
|
export declare type JsonBatchQuery = {
|
2003
1965
|
batch: JsonQuery[];
|
2004
1966
|
transaction?: {
|
2005
|
-
isolationLevel?:
|
1967
|
+
isolationLevel?: IsolationLevel;
|
2006
1968
|
};
|
2007
1969
|
};
|
2008
1970
|
|
@@ -2016,6 +1978,7 @@ declare type JsonFieldSelection = {
|
|
2016
1978
|
};
|
2017
1979
|
|
2018
1980
|
declare class JsonNull extends NullTypesEnumValue {
|
1981
|
+
private readonly _brand_JsonNull;
|
2019
1982
|
}
|
2020
1983
|
|
2021
1984
|
/**
|
@@ -2145,6 +2108,14 @@ export declare function makeStrictEnum<T extends Record<PropertyKey, string | nu
|
|
2145
2108
|
|
2146
2109
|
export declare function makeTypedQueryFactory(sql: string): (...values: any[]) => TypedSql<any[], unknown>;
|
2147
2110
|
|
2111
|
+
declare type Mappings = ReadonlyDeep_2<{
|
2112
|
+
modelOperations: ModelMapping[];
|
2113
|
+
otherOperations: {
|
2114
|
+
read: string[];
|
2115
|
+
write: string[];
|
2116
|
+
};
|
2117
|
+
}>;
|
2118
|
+
|
2148
2119
|
/**
|
2149
2120
|
* Class that holds the list of all extensions, applied to particular instance,
|
2150
2121
|
* as well as resolved versions of the components that need to apply on
|
@@ -2244,6 +2215,40 @@ declare class MiddlewareHandler<M extends Function> {
|
|
2244
2215
|
length(): number;
|
2245
2216
|
}
|
2246
2217
|
|
2218
|
+
declare type Model = ReadonlyDeep_2<{
|
2219
|
+
name: string;
|
2220
|
+
dbName: string | null;
|
2221
|
+
schema: string | null;
|
2222
|
+
fields: Field[];
|
2223
|
+
uniqueFields: string[][];
|
2224
|
+
uniqueIndexes: uniqueIndex[];
|
2225
|
+
documentation?: string;
|
2226
|
+
primaryKey: PrimaryKey | null;
|
2227
|
+
isGenerated?: boolean;
|
2228
|
+
}>;
|
2229
|
+
|
2230
|
+
declare enum ModelAction {
|
2231
|
+
findUnique = "findUnique",
|
2232
|
+
findUniqueOrThrow = "findUniqueOrThrow",
|
2233
|
+
findFirst = "findFirst",
|
2234
|
+
findFirstOrThrow = "findFirstOrThrow",
|
2235
|
+
findMany = "findMany",
|
2236
|
+
create = "create",
|
2237
|
+
createMany = "createMany",
|
2238
|
+
createManyAndReturn = "createManyAndReturn",
|
2239
|
+
update = "update",
|
2240
|
+
updateMany = "updateMany",
|
2241
|
+
updateManyAndReturn = "updateManyAndReturn",
|
2242
|
+
upsert = "upsert",
|
2243
|
+
delete = "delete",
|
2244
|
+
deleteMany = "deleteMany",
|
2245
|
+
groupBy = "groupBy",
|
2246
|
+
count = "count",// TODO: count does not actually exist in DMMF
|
2247
|
+
aggregate = "aggregate",
|
2248
|
+
findRaw = "findRaw",
|
2249
|
+
aggregateRaw = "aggregateRaw"
|
2250
|
+
}
|
2251
|
+
|
2247
2252
|
export declare type ModelArg = {
|
2248
2253
|
[MethodName in string]: unknown;
|
2249
2254
|
};
|
@@ -2256,6 +2261,30 @@ export declare type ModelArgs = {
|
|
2256
2261
|
|
2257
2262
|
export declare type ModelKey<TypeMap extends TypeMapDef, M extends PropertyKey> = M extends keyof TypeMap['model'] ? M : Capitalize<M & string>;
|
2258
2263
|
|
2264
|
+
declare type ModelMapping = ReadonlyDeep_2<{
|
2265
|
+
model: string;
|
2266
|
+
plural: string;
|
2267
|
+
findUnique?: string | null;
|
2268
|
+
findUniqueOrThrow?: string | null;
|
2269
|
+
findFirst?: string | null;
|
2270
|
+
findFirstOrThrow?: string | null;
|
2271
|
+
findMany?: string | null;
|
2272
|
+
create?: string | null;
|
2273
|
+
createMany?: string | null;
|
2274
|
+
createManyAndReturn?: string | null;
|
2275
|
+
update?: string | null;
|
2276
|
+
updateMany?: string | null;
|
2277
|
+
updateManyAndReturn?: string | null;
|
2278
|
+
upsert?: string | null;
|
2279
|
+
delete?: string | null;
|
2280
|
+
deleteMany?: string | null;
|
2281
|
+
aggregate?: string | null;
|
2282
|
+
groupBy?: string | null;
|
2283
|
+
count?: string | null;
|
2284
|
+
findRaw?: string | null;
|
2285
|
+
aggregateRaw?: string | null;
|
2286
|
+
}>;
|
2287
|
+
|
2259
2288
|
export declare type ModelQueryOptionsCb = (args: ModelQueryOptionsCbArgs) => Promise<any>;
|
2260
2289
|
|
2261
2290
|
export declare type ModelQueryOptionsCbArgs = {
|
@@ -2265,6 +2294,11 @@ export declare type ModelQueryOptionsCbArgs = {
|
|
2265
2294
|
query: (args: JsArgs) => Promise<unknown>;
|
2266
2295
|
};
|
2267
2296
|
|
2297
|
+
declare type MultiBatchResponse = {
|
2298
|
+
type: 'multi';
|
2299
|
+
plans: object[];
|
2300
|
+
};
|
2301
|
+
|
2268
2302
|
export declare type NameArgs = {
|
2269
2303
|
name?: string;
|
2270
2304
|
};
|
@@ -2281,11 +2315,6 @@ declare class NullTypesEnumValue extends ObjectEnumValue {
|
|
2281
2315
|
_getNamespace(): string;
|
2282
2316
|
}
|
2283
2317
|
|
2284
|
-
/**
|
2285
|
-
* List of Prisma enums that must use unique objects instead of strings as their values.
|
2286
|
-
*/
|
2287
|
-
export declare const objectEnumNames: string[];
|
2288
|
-
|
2289
2318
|
/**
|
2290
2319
|
* Base class for unique values of object-valued enums.
|
2291
2320
|
*/
|
@@ -2364,6 +2393,18 @@ export declare type Or<A extends 1 | 0, B extends 1 | 0> = {
|
|
2364
2393
|
};
|
2365
2394
|
}[A][B];
|
2366
2395
|
|
2396
|
+
declare type OtherOperationMappings = ReadonlyDeep_2<{
|
2397
|
+
read: string[];
|
2398
|
+
write: string[];
|
2399
|
+
}>;
|
2400
|
+
|
2401
|
+
declare type OutputType = ReadonlyDeep_2<{
|
2402
|
+
name: string;
|
2403
|
+
fields: SchemaField[];
|
2404
|
+
}>;
|
2405
|
+
|
2406
|
+
declare type OutputTypeRef = TypeRef<'scalar' | 'outputObjectTypes' | 'enumTypes'>;
|
2407
|
+
|
2367
2408
|
export declare function Param<$Type, $Value extends string>(name: $Value): Param<$Type, $Value>;
|
2368
2409
|
|
2369
2410
|
export declare type Param<out $Type, $Value extends string> = {
|
@@ -2391,6 +2432,11 @@ declare type Pick_2<T, K extends string | number | symbol> = {
|
|
2391
2432
|
};
|
2392
2433
|
export { Pick_2 as Pick }
|
2393
2434
|
|
2435
|
+
declare type PrimaryKey = ReadonlyDeep_2<{
|
2436
|
+
name: string | null;
|
2437
|
+
fields: string[];
|
2438
|
+
}>;
|
2439
|
+
|
2394
2440
|
export declare class PrismaClientInitializationError extends Error {
|
2395
2441
|
clientVersion: string;
|
2396
2442
|
errorCode?: string;
|
@@ -2416,7 +2462,7 @@ export declare type PrismaClientOptions = {
|
|
2416
2462
|
/**
|
2417
2463
|
* Instance of a Driver Adapter, e.g., like one provided by `@prisma/adapter-planetscale.
|
2418
2464
|
*/
|
2419
|
-
adapter?:
|
2465
|
+
adapter?: SqlDriverAdapterFactory | null;
|
2420
2466
|
/**
|
2421
2467
|
* Overwrites the datasource url from your schema.prisma file
|
2422
2468
|
*/
|
@@ -2581,6 +2627,12 @@ declare namespace Public_2 {
|
|
2581
2627
|
}
|
2582
2628
|
}
|
2583
2629
|
|
2630
|
+
declare type Query = ReadonlyDeep_2<{
|
2631
|
+
name: string;
|
2632
|
+
args: SchemaArg[];
|
2633
|
+
output: QueryOutput;
|
2634
|
+
}>;
|
2635
|
+
|
2584
2636
|
declare interface Queryable<Query, Result> extends AdapterInfo {
|
2585
2637
|
/**
|
2586
2638
|
* Execute a query and return its result.
|
@@ -2594,6 +2646,7 @@ declare interface Queryable<Query, Result> extends AdapterInfo {
|
|
2594
2646
|
|
2595
2647
|
declare type QueryCompiler = {
|
2596
2648
|
compile(request: string): Promise<string>;
|
2649
|
+
compileBatch(batchRequest: string): Promise<BatchResponse>;
|
2597
2650
|
};
|
2598
2651
|
|
2599
2652
|
declare interface QueryCompilerConstructor {
|
@@ -2609,7 +2662,7 @@ declare type QueryCompilerOptions = {
|
|
2609
2662
|
declare type QueryEngineBatchGraphQLRequest = {
|
2610
2663
|
batch: QueryEngineRequest[];
|
2611
2664
|
transaction?: boolean;
|
2612
|
-
isolationLevel?:
|
2665
|
+
isolationLevel?: IsolationLevel;
|
2613
2666
|
};
|
2614
2667
|
|
2615
2668
|
declare type QueryEngineBatchRequest = QueryEngineBatchGraphQLRequest | JsonBatchQuery;
|
@@ -2622,12 +2675,12 @@ declare type QueryEngineConfig = {
|
|
2622
2675
|
datasourceOverrides: Record<string, string>;
|
2623
2676
|
env: Record<string, string | undefined>;
|
2624
2677
|
logLevel: QueryEngineLogLevel;
|
2625
|
-
engineProtocol:
|
2678
|
+
engineProtocol: QueryEngineProtocol;
|
2626
2679
|
enableTracing: boolean;
|
2627
2680
|
};
|
2628
2681
|
|
2629
2682
|
declare interface QueryEngineConstructor {
|
2630
|
-
new (config: QueryEngineConfig, logger: (log: string) => void, adapter?:
|
2683
|
+
new (config: QueryEngineConfig, logger: (log: string) => void, adapter?: ErrorCapturingSqlDriverAdapter): QueryEngineInstance;
|
2631
2684
|
}
|
2632
2685
|
|
2633
2686
|
declare type QueryEngineInstance = {
|
@@ -2649,6 +2702,8 @@ declare type QueryEngineInstance = {
|
|
2649
2702
|
|
2650
2703
|
declare type QueryEngineLogLevel = 'trace' | 'debug' | 'info' | 'warn' | 'error' | 'off';
|
2651
2704
|
|
2705
|
+
declare type QueryEngineProtocol = 'graphql' | 'json';
|
2706
|
+
|
2652
2707
|
declare type QueryEngineRequest = {
|
2653
2708
|
query: string;
|
2654
2709
|
variables: Object;
|
@@ -2701,6 +2756,12 @@ export declare type QueryOptionsCbArgs = {
|
|
2701
2756
|
query: (args: JsArgs | RawQueryArgs) => Promise<unknown>;
|
2702
2757
|
};
|
2703
2758
|
|
2759
|
+
declare type QueryOutput = ReadonlyDeep_2<{
|
2760
|
+
name: string;
|
2761
|
+
isRequired: boolean;
|
2762
|
+
isList: boolean;
|
2763
|
+
}>;
|
2764
|
+
|
2704
2765
|
/**
|
2705
2766
|
* Create raw SQL statement.
|
2706
2767
|
*/
|
@@ -2841,8 +2902,6 @@ export declare type Result_2<T, A, F extends Operation> = Result<T, A, F>;
|
|
2841
2902
|
|
2842
2903
|
declare namespace Result_3 {
|
2843
2904
|
export {
|
2844
|
-
Operation,
|
2845
|
-
FluentOperation,
|
2846
2905
|
Count,
|
2847
2906
|
GetFindResult,
|
2848
2907
|
SelectablePayloadFields,
|
@@ -2899,12 +2958,55 @@ export declare type RuntimeDataModel = {
|
|
2899
2958
|
readonly types: Record<string, RuntimeModel>;
|
2900
2959
|
};
|
2901
2960
|
|
2902
|
-
declare type RuntimeEnum = Omit<
|
2961
|
+
declare type RuntimeEnum = Omit<DMMF_2.DatamodelEnum, 'name'>;
|
2903
2962
|
|
2904
|
-
declare type RuntimeModel = Omit<
|
2963
|
+
declare type RuntimeModel = Omit<DMMF_2.Model, 'name'>;
|
2905
2964
|
|
2906
2965
|
declare type RuntimeName = 'workerd' | 'deno' | 'netlify' | 'node' | 'bun' | 'edge-light' | '';
|
2907
2966
|
|
2967
|
+
declare type Schema = ReadonlyDeep_2<{
|
2968
|
+
rootQueryType?: string;
|
2969
|
+
rootMutationType?: string;
|
2970
|
+
inputObjectTypes: {
|
2971
|
+
model?: InputType[];
|
2972
|
+
prisma: InputType[];
|
2973
|
+
};
|
2974
|
+
outputObjectTypes: {
|
2975
|
+
model: OutputType[];
|
2976
|
+
prisma: OutputType[];
|
2977
|
+
};
|
2978
|
+
enumTypes: {
|
2979
|
+
model?: SchemaEnum[];
|
2980
|
+
prisma: SchemaEnum[];
|
2981
|
+
};
|
2982
|
+
fieldRefTypes: {
|
2983
|
+
prisma?: FieldRefType[];
|
2984
|
+
};
|
2985
|
+
}>;
|
2986
|
+
|
2987
|
+
declare type SchemaArg = ReadonlyDeep_2<{
|
2988
|
+
name: string;
|
2989
|
+
comment?: string;
|
2990
|
+
isNullable: boolean;
|
2991
|
+
isRequired: boolean;
|
2992
|
+
inputTypes: InputTypeRef[];
|
2993
|
+
deprecation?: Deprecation;
|
2994
|
+
}>;
|
2995
|
+
|
2996
|
+
declare type SchemaEnum = ReadonlyDeep_2<{
|
2997
|
+
name: string;
|
2998
|
+
values: string[];
|
2999
|
+
}>;
|
3000
|
+
|
3001
|
+
declare type SchemaField = ReadonlyDeep_2<{
|
3002
|
+
name: string;
|
3003
|
+
isNullable?: boolean;
|
3004
|
+
outputType: OutputTypeRef;
|
3005
|
+
args: SchemaArg[];
|
3006
|
+
deprecation?: Deprecation;
|
3007
|
+
documentation?: string;
|
3008
|
+
}>;
|
3009
|
+
|
2908
3010
|
export declare type Select<T, U> = T extends U ? T : never;
|
2909
3011
|
|
2910
3012
|
export declare type SelectablePayloadFields<K extends PropertyKey, O> = {
|
@@ -2949,6 +3051,8 @@ declare class Skip {
|
|
2949
3051
|
|
2950
3052
|
export declare const skip: Skip;
|
2951
3053
|
|
3054
|
+
declare type SortOrder = 'asc' | 'desc';
|
3055
|
+
|
2952
3056
|
/**
|
2953
3057
|
* An interface that represents a span. A span represents a single operation
|
2954
3058
|
* within a trace. Examples of span might include remote procedure calls or a
|
@@ -3217,6 +3321,29 @@ export declare class Sql {
|
|
3217
3321
|
};
|
3218
3322
|
}
|
3219
3323
|
|
3324
|
+
declare interface SqlDriverAdapter extends SqlQueryable {
|
3325
|
+
/**
|
3326
|
+
* Execute multiple SQL statements separated by semicolon.
|
3327
|
+
*/
|
3328
|
+
executeScript(script: string): Promise<void>;
|
3329
|
+
/**
|
3330
|
+
* Start new transaction.
|
3331
|
+
*/
|
3332
|
+
startTransaction(isolationLevel?: IsolationLevel): Promise<Transaction>;
|
3333
|
+
/**
|
3334
|
+
* Optional method that returns extra connection info
|
3335
|
+
*/
|
3336
|
+
getConnectionInfo?(): ConnectionInfo;
|
3337
|
+
/**
|
3338
|
+
* Dispose of the connection and release any resources.
|
3339
|
+
*/
|
3340
|
+
dispose(): Promise<void>;
|
3341
|
+
}
|
3342
|
+
|
3343
|
+
export declare interface SqlDriverAdapterFactory extends DriverAdapterFactory<SqlQuery, SqlResultSet> {
|
3344
|
+
connect(): Promise<SqlDriverAdapter>;
|
3345
|
+
}
|
3346
|
+
|
3220
3347
|
declare type SqlQuery = {
|
3221
3348
|
sql: string;
|
3222
3349
|
args: Array<unknown>;
|
@@ -3325,20 +3452,12 @@ declare interface Transaction extends AdapterInfo, SqlQueryable {
|
|
3325
3452
|
|
3326
3453
|
declare namespace Transaction_2 {
|
3327
3454
|
export {
|
3328
|
-
IsolationLevel,
|
3329
3455
|
TransactionOptions_2 as Options,
|
3330
3456
|
InteractiveTransactionInfo,
|
3331
3457
|
TransactionHeaders
|
3332
3458
|
}
|
3333
3459
|
}
|
3334
3460
|
|
3335
|
-
declare interface TransactionContext extends AdapterInfo, SqlQueryable {
|
3336
|
-
/**
|
3337
|
-
* Start new transaction.
|
3338
|
-
*/
|
3339
|
-
startTransaction(): Promise<Transaction>;
|
3340
|
-
}
|
3341
|
-
|
3342
3461
|
declare type TransactionHeaders = {
|
3343
3462
|
traceparent?: string;
|
3344
3463
|
};
|
@@ -3375,6 +3494,13 @@ export declare type TypeMapCbDef = Fn<{
|
|
3375
3494
|
/** Shared */
|
3376
3495
|
export declare type TypeMapDef = Record<any, any>;
|
3377
3496
|
|
3497
|
+
declare type TypeRef<AllowedLocations extends FieldLocation> = {
|
3498
|
+
isList: boolean;
|
3499
|
+
type: string;
|
3500
|
+
location: AllowedLocations;
|
3501
|
+
namespace?: FieldNamespace;
|
3502
|
+
};
|
3503
|
+
|
3378
3504
|
declare namespace Types {
|
3379
3505
|
export {
|
3380
3506
|
Result_3 as Result,
|
@@ -3390,6 +3516,11 @@ declare namespace Types {
|
|
3390
3516
|
}
|
3391
3517
|
export { Types }
|
3392
3518
|
|
3519
|
+
declare type uniqueIndex = ReadonlyDeep_2<{
|
3520
|
+
name: string;
|
3521
|
+
fields: string[];
|
3522
|
+
}>;
|
3523
|
+
|
3393
3524
|
declare type UnknownErrorParams = {
|
3394
3525
|
clientVersion: string;
|
3395
3526
|
batchRequestIdx?: number;
|