@breadstone/archipel-mcp 0.0.25 → 0.0.27
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/data/guides/document-generation.md +17 -6
- package/data/packages/platform-analytics/api/Class.AnalyticsHealthIndicator.md +4 -4
- package/data/packages/platform-authentication/api/Class.AuthenticationHealthIndicator.md +3 -3
- package/data/packages/platform-blob-storage/api/Class.BlobHealthIndicator.md +4 -4
- package/data/packages/platform-database/api/Class.DatabaseHealthIndicator.md +4 -4
- package/data/packages/platform-database/api/Class.RepositoryBase.md +124 -50
- package/data/packages/platform-database/api/Class.RepositoryBase2.md +181 -0
- package/data/packages/platform-database/api/Function.aggregate.md +33 -0
- package/data/packages/platform-database/api/Function.aggregateRaw.md +34 -0
- package/data/packages/platform-database/api/Function.count.md +33 -0
- package/data/packages/platform-database/api/Function.create.md +33 -0
- package/data/packages/platform-database/api/Function.createMany.md +33 -0
- package/data/packages/platform-database/api/Function.createManyAndReturn.md +35 -0
- package/data/packages/platform-database/api/Function.findFirst.md +35 -0
- package/data/packages/platform-database/api/Function.findFirstOrThrow.md +34 -0
- package/data/packages/platform-database/api/Function.findMany.md +32 -0
- package/data/packages/platform-database/api/Function.findManyPaged.md +34 -0
- package/data/packages/platform-database/api/Function.findRaw.md +34 -0
- package/data/packages/platform-database/api/Function.findUnique.md +32 -0
- package/data/packages/platform-database/api/Function.findUniqueOrThrow.md +34 -0
- package/data/packages/platform-database/api/Function.groupBy.md +33 -0
- package/data/packages/platform-database/api/Function.pipe.md +34 -0
- package/data/packages/platform-database/api/Function.pipeAll.md +35 -0
- package/data/packages/platform-database/api/Function.query2.md +35 -0
- package/data/packages/platform-database/api/Function.remove.md +33 -0
- package/data/packages/platform-database/api/Function.removeMany.md +33 -0
- package/data/packages/platform-database/api/Function.update.md +33 -0
- package/data/packages/platform-database/api/Function.updateMany.md +33 -0
- package/data/packages/platform-database/api/Function.updateManyAndReturn.md +35 -0
- package/data/packages/platform-database/api/Function.upsert.md +33 -0
- package/data/packages/platform-database/api/Interface.IRepositoryQuery2.md +45 -0
- package/data/packages/platform-database/api/TypeAlias.DelegateArgs.md +1 -1
- package/data/packages/platform-database/api/TypeAlias.DelegateOperations.md +29 -0
- package/data/packages/platform-database/api/TypeAlias.DelegateReturnTypes.md +1 -1
- package/data/packages/platform-database/api/TypeAlias.RepositoryOperationsAll.md +19 -0
- package/data/packages/platform-database/api/TypeAlias.RepositoryOperationsBase.md +34 -0
- package/data/packages/platform-database/api/index.md +29 -1
- package/data/packages/platform-database/index.md +1 -1
- package/data/packages/platform-documents/index.md +14 -7
- package/data/packages/platform-esigning/api/Class.EsigningHealthIndicator.md +4 -4
- package/data/packages/platform-mailing/api/Class.MailHealthIndicator.md +4 -4
- package/data/packages/platform-mcp/api/Class.McpHealthIndicator.md +4 -4
- package/data/packages/platform-payments/api/Class.PaymentHealthIndicator.md +4 -4
- package/data/packages/platform-telemetry/api/Class.TelemetryHealthIndicator.md +4 -4
- package/package.json +1 -1
|
@@ -0,0 +1,181 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: 'Abstract Class: RepositoryBase2\<TDelegate\>'
|
|
3
|
+
generated: true
|
|
4
|
+
editUrl: false
|
|
5
|
+
---
|
|
6
|
+
# Abstract Class: RepositoryBase2\<TDelegate\>
|
|
7
|
+
|
|
8
|
+
Defined in: [repositories2/abstracts/RepositoryBase2.ts:19](https://github.com/RueDeRennes/archipel/blob/main/libs/platform-database/src/repositories2/abstracts/RepositoryBase2.ts#L19)
|
|
9
|
+
|
|
10
|
+
**`Beta`**
|
|
11
|
+
|
|
12
|
+
Minimal repository base that exposes the underlying Prisma delegate and
|
|
13
|
+
provides a typed pipe helper for functional operators.
|
|
14
|
+
|
|
15
|
+
## Type Parameters
|
|
16
|
+
|
|
17
|
+
| Type Parameter | Description |
|
|
18
|
+
| ------ | ------ |
|
|
19
|
+
| `TDelegate` | The concrete Prisma delegate type (e.g. Prisma.UserDelegate) |
|
|
20
|
+
|
|
21
|
+
## Constructors
|
|
22
|
+
|
|
23
|
+
### Constructor
|
|
24
|
+
|
|
25
|
+
```ts
|
|
26
|
+
new RepositoryBase2<TDelegate>(db, delegate): RepositoryBase2<TDelegate>;
|
|
27
|
+
```
|
|
28
|
+
|
|
29
|
+
Defined in: [repositories2/abstracts/RepositoryBase2.ts:39](https://github.com/RueDeRennes/archipel/blob/main/libs/platform-database/src/repositories2/abstracts/RepositoryBase2.ts#L39)
|
|
30
|
+
|
|
31
|
+
**`Beta`**
|
|
32
|
+
|
|
33
|
+
Constructs a new instance of the repository.
|
|
34
|
+
|
|
35
|
+
#### Parameters
|
|
36
|
+
|
|
37
|
+
| Parameter | Type |
|
|
38
|
+
| ------ | ------ |
|
|
39
|
+
| `db` | [`DatabaseService`](Class.DatabaseService) |
|
|
40
|
+
| `delegate` | `unknown` |
|
|
41
|
+
|
|
42
|
+
#### Returns
|
|
43
|
+
|
|
44
|
+
`RepositoryBase2`\<`TDelegate`\>
|
|
45
|
+
|
|
46
|
+
#### Remarks
|
|
47
|
+
|
|
48
|
+
The `delegate` parameter is typed as `unknown` and cast internally to
|
|
49
|
+
`TDelegate`. This avoids `GlobalOmitOptions` mismatches introduced in
|
|
50
|
+
Prisma 7 where `PrismaClient` instantiates delegates with
|
|
51
|
+
`PrismaClientOptions` while consumer code references them with the
|
|
52
|
+
default `{}`.
|
|
53
|
+
|
|
54
|
+
## Accessors
|
|
55
|
+
|
|
56
|
+
### database
|
|
57
|
+
|
|
58
|
+
#### Get Signature
|
|
59
|
+
|
|
60
|
+
```ts
|
|
61
|
+
get protected database(): DatabaseService;
|
|
62
|
+
```
|
|
63
|
+
|
|
64
|
+
Defined in: [repositories2/abstracts/RepositoryBase2.ts:55](https://github.com/RueDeRennes/archipel/blob/main/libs/platform-database/src/repositories2/abstracts/RepositoryBase2.ts#L55)
|
|
65
|
+
|
|
66
|
+
**`Beta`**
|
|
67
|
+
|
|
68
|
+
Provides access to the underlying DatabaseService for derived repositories.
|
|
69
|
+
Only to be used for transactional orchestration that spans multiple models.
|
|
70
|
+
|
|
71
|
+
##### Returns
|
|
72
|
+
|
|
73
|
+
[`DatabaseService`](Class.DatabaseService)
|
|
74
|
+
|
|
75
|
+
***
|
|
76
|
+
|
|
77
|
+
### delegate
|
|
78
|
+
|
|
79
|
+
#### Get Signature
|
|
80
|
+
|
|
81
|
+
```ts
|
|
82
|
+
get protected delegate(): TDelegate;
|
|
83
|
+
```
|
|
84
|
+
|
|
85
|
+
Defined in: [repositories2/abstracts/RepositoryBase2.ts:66](https://github.com/RueDeRennes/archipel/blob/main/libs/platform-database/src/repositories2/abstracts/RepositoryBase2.ts#L66)
|
|
86
|
+
|
|
87
|
+
**`Beta`**
|
|
88
|
+
|
|
89
|
+
Provides direct access to the underlying Prisma model delegate.
|
|
90
|
+
Use with caution, as this bypasses any repository-level logic.
|
|
91
|
+
|
|
92
|
+
##### Returns
|
|
93
|
+
|
|
94
|
+
`TDelegate`
|
|
95
|
+
|
|
96
|
+
## Methods
|
|
97
|
+
|
|
98
|
+
### execute()
|
|
99
|
+
|
|
100
|
+
```ts
|
|
101
|
+
execute<TRun>(query): Promise<UnwrapPromise<ReturnType<TRun>>>;
|
|
102
|
+
```
|
|
103
|
+
|
|
104
|
+
Defined in: [repositories2/abstracts/RepositoryBase2.ts:88](https://github.com/RueDeRennes/archipel/blob/main/libs/platform-database/src/repositories2/abstracts/RepositoryBase2.ts#L88)
|
|
105
|
+
|
|
106
|
+
Executes an query and preserves full inferred return type.
|
|
107
|
+
Always returns a Promise of the unwrapped result, regardless of whether the underlying run is sync or async.
|
|
108
|
+
|
|
109
|
+
#### Type Parameters
|
|
110
|
+
|
|
111
|
+
| Type Parameter |
|
|
112
|
+
| ------ |
|
|
113
|
+
| `TRun` *extends* (`delegate`) => `unknown` |
|
|
114
|
+
|
|
115
|
+
#### Parameters
|
|
116
|
+
|
|
117
|
+
| Parameter | Type |
|
|
118
|
+
| ------ | ------ |
|
|
119
|
+
| `query` | [`IRepositoryQuery2`](Interface.IRepositoryQuery2)\<`TDelegate`, `TRun`\> |
|
|
120
|
+
|
|
121
|
+
#### Returns
|
|
122
|
+
|
|
123
|
+
`Promise`\<`UnwrapPromise`\<`ReturnType`\<`TRun`\>\>\>
|
|
124
|
+
|
|
125
|
+
***
|
|
126
|
+
|
|
127
|
+
### pipe()
|
|
128
|
+
|
|
129
|
+
```ts
|
|
130
|
+
pipe<R>(op): R;
|
|
131
|
+
```
|
|
132
|
+
|
|
133
|
+
Defined in: [repositories2/abstracts/RepositoryBase2.ts:78](https://github.com/RueDeRennes/archipel/blob/main/libs/platform-database/src/repositories2/abstracts/RepositoryBase2.ts#L78)
|
|
134
|
+
|
|
135
|
+
Executes a single operator against this repository's delegate.
|
|
136
|
+
|
|
137
|
+
#### Type Parameters
|
|
138
|
+
|
|
139
|
+
| Type Parameter |
|
|
140
|
+
| ------ |
|
|
141
|
+
| `R` |
|
|
142
|
+
|
|
143
|
+
#### Parameters
|
|
144
|
+
|
|
145
|
+
| Parameter | Type | Description |
|
|
146
|
+
| ------ | ------ | ------ |
|
|
147
|
+
| `op` | `QueryOperator`\<`TDelegate`, `R`\> | Repository operator |
|
|
148
|
+
|
|
149
|
+
#### Returns
|
|
150
|
+
|
|
151
|
+
`R`
|
|
152
|
+
|
|
153
|
+
***
|
|
154
|
+
|
|
155
|
+
### tryCatch()
|
|
156
|
+
|
|
157
|
+
```ts
|
|
158
|
+
protected tryCatch<T>(promise): Promise<T>;
|
|
159
|
+
```
|
|
160
|
+
|
|
161
|
+
Defined in: [repositories2/abstracts/RepositoryBase2.ts:100](https://github.com/RueDeRennes/archipel/blob/main/libs/platform-database/src/repositories2/abstracts/RepositoryBase2.ts#L100)
|
|
162
|
+
|
|
163
|
+
**`Beta`**
|
|
164
|
+
|
|
165
|
+
Uniform error wrapping utility for promise-returning functions.
|
|
166
|
+
|
|
167
|
+
#### Type Parameters
|
|
168
|
+
|
|
169
|
+
| Type Parameter |
|
|
170
|
+
| ------ |
|
|
171
|
+
| `T` |
|
|
172
|
+
|
|
173
|
+
#### Parameters
|
|
174
|
+
|
|
175
|
+
| Parameter | Type |
|
|
176
|
+
| ------ | ------ |
|
|
177
|
+
| `promise` | `Promise`\<`T`\> |
|
|
178
|
+
|
|
179
|
+
#### Returns
|
|
180
|
+
|
|
181
|
+
`Promise`\<`T`\>
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: 'Function: aggregate()'
|
|
3
|
+
generated: true
|
|
4
|
+
editUrl: false
|
|
5
|
+
---
|
|
6
|
+
# Function: aggregate()
|
|
7
|
+
|
|
8
|
+
```ts
|
|
9
|
+
function aggregate<D, A>(args): QueryOperator<D, ReturnType<D["aggregate"]>>;
|
|
10
|
+
```
|
|
11
|
+
|
|
12
|
+
Defined in: [repositories2/operators/aggregate.ts:13](https://github.com/RueDeRennes/archipel/blob/main/libs/platform-database/src/repositories2/operators/aggregate.ts#L13)
|
|
13
|
+
|
|
14
|
+
**`Beta`**
|
|
15
|
+
|
|
16
|
+
Executes an aggregate query via the delegate `aggregate` method.
|
|
17
|
+
|
|
18
|
+
## Type Parameters
|
|
19
|
+
|
|
20
|
+
| Type Parameter |
|
|
21
|
+
| ------ |
|
|
22
|
+
| `D` *extends* `IAggregateDelegate` |
|
|
23
|
+
| `A` *extends* `unknown` |
|
|
24
|
+
|
|
25
|
+
## Parameters
|
|
26
|
+
|
|
27
|
+
| Parameter | Type | Description |
|
|
28
|
+
| ------ | ------ | ------ |
|
|
29
|
+
| `args` | `A` | Prisma aggregate arguments |
|
|
30
|
+
|
|
31
|
+
## Returns
|
|
32
|
+
|
|
33
|
+
`QueryOperator`\<`D`, `ReturnType`\<`D`\[`"aggregate"`\]\>\>
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: 'Function: aggregateRaw()'
|
|
3
|
+
generated: true
|
|
4
|
+
editUrl: false
|
|
5
|
+
---
|
|
6
|
+
# Function: aggregateRaw()
|
|
7
|
+
|
|
8
|
+
```ts
|
|
9
|
+
function aggregateRaw<D>(...args): QueryOperator<D, ReturnType<D["aggregateRaw"]>>;
|
|
10
|
+
```
|
|
11
|
+
|
|
12
|
+
Defined in: [repositories2/operators/aggregateRaw.ts:15](https://github.com/RueDeRennes/archipel/blob/main/libs/platform-database/src/repositories2/operators/aggregateRaw.ts#L15)
|
|
13
|
+
|
|
14
|
+
**`Beta`**
|
|
15
|
+
|
|
16
|
+
Executes a raw aggregate query via the delegate `aggregateRaw` method.
|
|
17
|
+
|
|
18
|
+
**Provider support:** MongoDB only.
|
|
19
|
+
|
|
20
|
+
## Type Parameters
|
|
21
|
+
|
|
22
|
+
| Type Parameter |
|
|
23
|
+
| ------ |
|
|
24
|
+
| `D` *extends* `IAggregateRawDelegate` |
|
|
25
|
+
|
|
26
|
+
## Parameters
|
|
27
|
+
|
|
28
|
+
| Parameter | Type | Description |
|
|
29
|
+
| ------ | ------ | ------ |
|
|
30
|
+
| ...`args` | `Parameters`\<`D`\[`"aggregateRaw"`\]\> | Prisma aggregateRaw arguments (optional) |
|
|
31
|
+
|
|
32
|
+
## Returns
|
|
33
|
+
|
|
34
|
+
`QueryOperator`\<`D`, `ReturnType`\<`D`\[`"aggregateRaw"`\]\>\>
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: 'Function: count()'
|
|
3
|
+
generated: true
|
|
4
|
+
editUrl: false
|
|
5
|
+
---
|
|
6
|
+
# Function: count()
|
|
7
|
+
|
|
8
|
+
```ts
|
|
9
|
+
function count<D, A>(args): QueryOperator<D, ReturnType<D["count"]>>;
|
|
10
|
+
```
|
|
11
|
+
|
|
12
|
+
Defined in: [repositories2/operators/count.ts:13](https://github.com/RueDeRennes/archipel/blob/main/libs/platform-database/src/repositories2/operators/count.ts#L13)
|
|
13
|
+
|
|
14
|
+
**`Beta`**
|
|
15
|
+
|
|
16
|
+
Counts records via the delegate `count` method.
|
|
17
|
+
|
|
18
|
+
## Type Parameters
|
|
19
|
+
|
|
20
|
+
| Type Parameter |
|
|
21
|
+
| ------ |
|
|
22
|
+
| `D` *extends* `ICountDelegate` |
|
|
23
|
+
| `A` *extends* `unknown` |
|
|
24
|
+
|
|
25
|
+
## Parameters
|
|
26
|
+
|
|
27
|
+
| Parameter | Type | Description |
|
|
28
|
+
| ------ | ------ | ------ |
|
|
29
|
+
| `args` | `A` | Prisma count arguments |
|
|
30
|
+
|
|
31
|
+
## Returns
|
|
32
|
+
|
|
33
|
+
`QueryOperator`\<`D`, `ReturnType`\<`D`\[`"count"`\]\>\>
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: 'Function: create()'
|
|
3
|
+
generated: true
|
|
4
|
+
editUrl: false
|
|
5
|
+
---
|
|
6
|
+
# Function: create()
|
|
7
|
+
|
|
8
|
+
```ts
|
|
9
|
+
function create<D, A>(args): QueryOperator<D, ReturnType<D["create"]>>;
|
|
10
|
+
```
|
|
11
|
+
|
|
12
|
+
Defined in: [repositories2/operators/create.ts:13](https://github.com/RueDeRennes/archipel/blob/main/libs/platform-database/src/repositories2/operators/create.ts#L13)
|
|
13
|
+
|
|
14
|
+
**`Beta`**
|
|
15
|
+
|
|
16
|
+
Creates a record using the underlying delegate `create` method.
|
|
17
|
+
|
|
18
|
+
## Type Parameters
|
|
19
|
+
|
|
20
|
+
| Type Parameter |
|
|
21
|
+
| ------ |
|
|
22
|
+
| `D` *extends* `ICreateDelegate` |
|
|
23
|
+
| `A` *extends* `unknown` |
|
|
24
|
+
|
|
25
|
+
## Parameters
|
|
26
|
+
|
|
27
|
+
| Parameter | Type | Description |
|
|
28
|
+
| ------ | ------ | ------ |
|
|
29
|
+
| `args` | `A` | Prisma create arguments |
|
|
30
|
+
|
|
31
|
+
## Returns
|
|
32
|
+
|
|
33
|
+
`QueryOperator`\<`D`, `ReturnType`\<`D`\[`"create"`\]\>\>
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: 'Function: createMany()'
|
|
3
|
+
generated: true
|
|
4
|
+
editUrl: false
|
|
5
|
+
---
|
|
6
|
+
# Function: createMany()
|
|
7
|
+
|
|
8
|
+
```ts
|
|
9
|
+
function createMany<D, A>(args): QueryOperator<D, ReturnType<D["createMany"]>>;
|
|
10
|
+
```
|
|
11
|
+
|
|
12
|
+
Defined in: [repositories2/operators/createMany.ts:13](https://github.com/RueDeRennes/archipel/blob/main/libs/platform-database/src/repositories2/operators/createMany.ts#L13)
|
|
13
|
+
|
|
14
|
+
**`Beta`**
|
|
15
|
+
|
|
16
|
+
Creates multiple records via the delegate `createMany` method.
|
|
17
|
+
|
|
18
|
+
## Type Parameters
|
|
19
|
+
|
|
20
|
+
| Type Parameter |
|
|
21
|
+
| ------ |
|
|
22
|
+
| `D` *extends* `ICreateManyDelegate` |
|
|
23
|
+
| `A` *extends* `unknown` |
|
|
24
|
+
|
|
25
|
+
## Parameters
|
|
26
|
+
|
|
27
|
+
| Parameter | Type | Description |
|
|
28
|
+
| ------ | ------ | ------ |
|
|
29
|
+
| `args` | `A` | Prisma createMany arguments |
|
|
30
|
+
|
|
31
|
+
## Returns
|
|
32
|
+
|
|
33
|
+
`QueryOperator`\<`D`, `ReturnType`\<`D`\[`"createMany"`\]\>\>
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: 'Function: createManyAndReturn()'
|
|
3
|
+
generated: true
|
|
4
|
+
editUrl: false
|
|
5
|
+
---
|
|
6
|
+
# Function: createManyAndReturn()
|
|
7
|
+
|
|
8
|
+
```ts
|
|
9
|
+
function createManyAndReturn<D, A>(args): QueryOperator<D, ReturnType<D["createManyAndReturn"]>>;
|
|
10
|
+
```
|
|
11
|
+
|
|
12
|
+
Defined in: [repositories2/operators/createManyAndReturn.ts:15](https://github.com/RueDeRennes/archipel/blob/main/libs/platform-database/src/repositories2/operators/createManyAndReturn.ts#L15)
|
|
13
|
+
|
|
14
|
+
**`Beta`**
|
|
15
|
+
|
|
16
|
+
Creates multiple records and returns them via the delegate `createManyAndReturn` method.
|
|
17
|
+
|
|
18
|
+
**Provider support:** PostgreSQL, CockroachDB, SQLite only.
|
|
19
|
+
|
|
20
|
+
## Type Parameters
|
|
21
|
+
|
|
22
|
+
| Type Parameter |
|
|
23
|
+
| ------ |
|
|
24
|
+
| `D` *extends* `ICreateManyAndReturnDelegate` |
|
|
25
|
+
| `A` *extends* `unknown` |
|
|
26
|
+
|
|
27
|
+
## Parameters
|
|
28
|
+
|
|
29
|
+
| Parameter | Type | Description |
|
|
30
|
+
| ------ | ------ | ------ |
|
|
31
|
+
| `args` | `A` | Prisma createManyAndReturn arguments |
|
|
32
|
+
|
|
33
|
+
## Returns
|
|
34
|
+
|
|
35
|
+
`QueryOperator`\<`D`, `ReturnType`\<`D`\[`"createManyAndReturn"`\]\>\>
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: 'Function: findFirst()'
|
|
3
|
+
generated: true
|
|
4
|
+
editUrl: false
|
|
5
|
+
---
|
|
6
|
+
# Function: findFirst()
|
|
7
|
+
|
|
8
|
+
```ts
|
|
9
|
+
function findFirst<D, A>(args): QueryOperator<D, ReturnType<D["findFirst"]>>;
|
|
10
|
+
```
|
|
11
|
+
|
|
12
|
+
Defined in: [repositories2/operators/findFirst.ts:14](https://github.com/RueDeRennes/archipel/blob/main/libs/platform-database/src/repositories2/operators/findFirst.ts#L14)
|
|
13
|
+
|
|
14
|
+
**`Beta`**
|
|
15
|
+
|
|
16
|
+
Creates an operator that executes a `findFirst` query with the provided arguments.
|
|
17
|
+
|
|
18
|
+
## Type Parameters
|
|
19
|
+
|
|
20
|
+
| Type Parameter |
|
|
21
|
+
| ------ |
|
|
22
|
+
| `D` *extends* `IFindFirstDelegate` |
|
|
23
|
+
| `A` *extends* `unknown` |
|
|
24
|
+
|
|
25
|
+
## Parameters
|
|
26
|
+
|
|
27
|
+
| Parameter | Type | Description |
|
|
28
|
+
| ------ | ------ | ------ |
|
|
29
|
+
| `args` | `A` | Prisma findFirst arguments |
|
|
30
|
+
|
|
31
|
+
## Returns
|
|
32
|
+
|
|
33
|
+
`QueryOperator`\<`D`, `ReturnType`\<`D`\[`"findFirst"`\]\>\>
|
|
34
|
+
|
|
35
|
+
Operator yielding the record or null
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: 'Function: findFirstOrThrow()'
|
|
3
|
+
generated: true
|
|
4
|
+
editUrl: false
|
|
5
|
+
---
|
|
6
|
+
# Function: findFirstOrThrow()
|
|
7
|
+
|
|
8
|
+
```ts
|
|
9
|
+
function findFirstOrThrow<D, A>(args): QueryOperator<D, ReturnType<D["findFirstOrThrow"]>>;
|
|
10
|
+
```
|
|
11
|
+
|
|
12
|
+
Defined in: [repositories2/operators/findFirstOrThrow.ts:14](https://github.com/RueDeRennes/archipel/blob/main/libs/platform-database/src/repositories2/operators/findFirstOrThrow.ts#L14)
|
|
13
|
+
|
|
14
|
+
**`Beta`**
|
|
15
|
+
|
|
16
|
+
Finds the first record matching the criteria via the delegate `findFirstOrThrow` method.
|
|
17
|
+
Throws a `PrismaClientKnownRequestError` with code `P2025` if no record is found.
|
|
18
|
+
|
|
19
|
+
## Type Parameters
|
|
20
|
+
|
|
21
|
+
| Type Parameter |
|
|
22
|
+
| ------ |
|
|
23
|
+
| `D` *extends* `IFindFirstOrThrowDelegate` |
|
|
24
|
+
| `A` *extends* `unknown` |
|
|
25
|
+
|
|
26
|
+
## Parameters
|
|
27
|
+
|
|
28
|
+
| Parameter | Type | Description |
|
|
29
|
+
| ------ | ------ | ------ |
|
|
30
|
+
| `args` | `A` | Prisma findFirstOrThrow arguments |
|
|
31
|
+
|
|
32
|
+
## Returns
|
|
33
|
+
|
|
34
|
+
`QueryOperator`\<`D`, `ReturnType`\<`D`\[`"findFirstOrThrow"`\]\>\>
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: 'Function: findMany()'
|
|
3
|
+
generated: true
|
|
4
|
+
editUrl: false
|
|
5
|
+
---
|
|
6
|
+
# Function: findMany()
|
|
7
|
+
|
|
8
|
+
```ts
|
|
9
|
+
function findMany<D>(...args): QueryOperator<D, ReturnType<D["findMany"]>>;
|
|
10
|
+
```
|
|
11
|
+
|
|
12
|
+
Defined in: [repositories2/operators/findMany.ts:9](https://github.com/RueDeRennes/archipel/blob/main/libs/platform-database/src/repositories2/operators/findMany.ts#L9)
|
|
13
|
+
|
|
14
|
+
**`Beta`**
|
|
15
|
+
|
|
16
|
+
Finds many records via the delegate `findMany` method.
|
|
17
|
+
|
|
18
|
+
## Type Parameters
|
|
19
|
+
|
|
20
|
+
| Type Parameter |
|
|
21
|
+
| ------ |
|
|
22
|
+
| `D` *extends* \{ `findMany`: (...`inner`) => `unknown`; \} |
|
|
23
|
+
|
|
24
|
+
## Parameters
|
|
25
|
+
|
|
26
|
+
| Parameter | Type | Description |
|
|
27
|
+
| ------ | ------ | ------ |
|
|
28
|
+
| ...`args` | `Parameters`\<`D`\[`"findMany"`\]\> | Prisma findMany arguments (optional) |
|
|
29
|
+
|
|
30
|
+
## Returns
|
|
31
|
+
|
|
32
|
+
`QueryOperator`\<`D`, `ReturnType`\<`D`\[`"findMany"`\]\>\>
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: 'Function: findManyPaged()'
|
|
3
|
+
generated: true
|
|
4
|
+
editUrl: false
|
|
5
|
+
---
|
|
6
|
+
# Function: findManyPaged()
|
|
7
|
+
|
|
8
|
+
```ts
|
|
9
|
+
function findManyPaged<D, A>(page, args?): QueryOperator<D, unknown>;
|
|
10
|
+
```
|
|
11
|
+
|
|
12
|
+
Defined in: [repositories2/operators/findManyPaged.ts:15](https://github.com/RueDeRennes/archipel/blob/main/libs/platform-database/src/repositories2/operators/findManyPaged.ts#L15)
|
|
13
|
+
|
|
14
|
+
**`Beta`**
|
|
15
|
+
|
|
16
|
+
Finds many records with pagination using the delegate `findMany` method.
|
|
17
|
+
|
|
18
|
+
## Type Parameters
|
|
19
|
+
|
|
20
|
+
| Type Parameter |
|
|
21
|
+
| ------ |
|
|
22
|
+
| `D` *extends* `IFindManyDelegate` |
|
|
23
|
+
| `A` *extends* `unknown` |
|
|
24
|
+
|
|
25
|
+
## Parameters
|
|
26
|
+
|
|
27
|
+
| Parameter | Type | Description |
|
|
28
|
+
| ------ | ------ | ------ |
|
|
29
|
+
| `page` | `Required`\<[`IPaginateOptions`](Interface.IPaginateOptions)\> | Pagination configuration |
|
|
30
|
+
| `args?` | `A` | Prisma findMany arguments (optional) |
|
|
31
|
+
|
|
32
|
+
## Returns
|
|
33
|
+
|
|
34
|
+
`QueryOperator`\<`D`, `unknown`\>
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: 'Function: findRaw()'
|
|
3
|
+
generated: true
|
|
4
|
+
editUrl: false
|
|
5
|
+
---
|
|
6
|
+
# Function: findRaw()
|
|
7
|
+
|
|
8
|
+
```ts
|
|
9
|
+
function findRaw<D>(...args): QueryOperator<D, ReturnType<D["findRaw"]>>;
|
|
10
|
+
```
|
|
11
|
+
|
|
12
|
+
Defined in: [repositories2/operators/findRaw.ts:15](https://github.com/RueDeRennes/archipel/blob/main/libs/platform-database/src/repositories2/operators/findRaw.ts#L15)
|
|
13
|
+
|
|
14
|
+
**`Beta`**
|
|
15
|
+
|
|
16
|
+
Executes a raw find query via the delegate `findRaw` method.
|
|
17
|
+
|
|
18
|
+
**Provider support:** MongoDB only.
|
|
19
|
+
|
|
20
|
+
## Type Parameters
|
|
21
|
+
|
|
22
|
+
| Type Parameter |
|
|
23
|
+
| ------ |
|
|
24
|
+
| `D` *extends* `IFindRawDelegate` |
|
|
25
|
+
|
|
26
|
+
## Parameters
|
|
27
|
+
|
|
28
|
+
| Parameter | Type | Description |
|
|
29
|
+
| ------ | ------ | ------ |
|
|
30
|
+
| ...`args` | `Parameters`\<`D`\[`"findRaw"`\]\> | Prisma findRaw arguments (optional) |
|
|
31
|
+
|
|
32
|
+
## Returns
|
|
33
|
+
|
|
34
|
+
`QueryOperator`\<`D`, `ReturnType`\<`D`\[`"findRaw"`\]\>\>
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: 'Function: findUnique()'
|
|
3
|
+
generated: true
|
|
4
|
+
editUrl: false
|
|
5
|
+
---
|
|
6
|
+
# Function: findUnique()
|
|
7
|
+
|
|
8
|
+
```ts
|
|
9
|
+
function findUnique<D>(...args): QueryOperator<D, ReturnType<D["findUnique"]>>;
|
|
10
|
+
```
|
|
11
|
+
|
|
12
|
+
Defined in: [repositories2/operators/findUnique.ts:9](https://github.com/RueDeRennes/archipel/blob/main/libs/platform-database/src/repositories2/operators/findUnique.ts#L9)
|
|
13
|
+
|
|
14
|
+
**`Beta`**
|
|
15
|
+
|
|
16
|
+
Finds a unique record via the delegate `findUnique` method.
|
|
17
|
+
|
|
18
|
+
## Type Parameters
|
|
19
|
+
|
|
20
|
+
| Type Parameter |
|
|
21
|
+
| ------ |
|
|
22
|
+
| `D` *extends* \{ `findUnique`: (...`inner`) => `unknown`; \} |
|
|
23
|
+
|
|
24
|
+
## Parameters
|
|
25
|
+
|
|
26
|
+
| Parameter | Type | Description |
|
|
27
|
+
| ------ | ------ | ------ |
|
|
28
|
+
| ...`args` | `Parameters`\<`D`\[`"findUnique"`\]\> | Prisma findUnique arguments |
|
|
29
|
+
|
|
30
|
+
## Returns
|
|
31
|
+
|
|
32
|
+
`QueryOperator`\<`D`, `ReturnType`\<`D`\[`"findUnique"`\]\>\>
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: 'Function: findUniqueOrThrow()'
|
|
3
|
+
generated: true
|
|
4
|
+
editUrl: false
|
|
5
|
+
---
|
|
6
|
+
# Function: findUniqueOrThrow()
|
|
7
|
+
|
|
8
|
+
```ts
|
|
9
|
+
function findUniqueOrThrow<D, A>(args): QueryOperator<D, ReturnType<D["findUniqueOrThrow"]>>;
|
|
10
|
+
```
|
|
11
|
+
|
|
12
|
+
Defined in: [repositories2/operators/findUniqueOrThrow.ts:14](https://github.com/RueDeRennes/archipel/blob/main/libs/platform-database/src/repositories2/operators/findUniqueOrThrow.ts#L14)
|
|
13
|
+
|
|
14
|
+
**`Beta`**
|
|
15
|
+
|
|
16
|
+
Finds a unique record via the delegate `findUniqueOrThrow` method.
|
|
17
|
+
Throws a `PrismaClientKnownRequestError` with code `P2025` if no record is found.
|
|
18
|
+
|
|
19
|
+
## Type Parameters
|
|
20
|
+
|
|
21
|
+
| Type Parameter |
|
|
22
|
+
| ------ |
|
|
23
|
+
| `D` *extends* `IFindUniqueOrThrowDelegate` |
|
|
24
|
+
| `A` *extends* `unknown` |
|
|
25
|
+
|
|
26
|
+
## Parameters
|
|
27
|
+
|
|
28
|
+
| Parameter | Type | Description |
|
|
29
|
+
| ------ | ------ | ------ |
|
|
30
|
+
| `args` | `A` | Prisma findUniqueOrThrow arguments |
|
|
31
|
+
|
|
32
|
+
## Returns
|
|
33
|
+
|
|
34
|
+
`QueryOperator`\<`D`, `ReturnType`\<`D`\[`"findUniqueOrThrow"`\]\>\>
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: 'Function: groupBy()'
|
|
3
|
+
generated: true
|
|
4
|
+
editUrl: false
|
|
5
|
+
---
|
|
6
|
+
# Function: groupBy()
|
|
7
|
+
|
|
8
|
+
```ts
|
|
9
|
+
function groupBy<D, A>(args): QueryOperator<D, ReturnType<D["groupBy"]>>;
|
|
10
|
+
```
|
|
11
|
+
|
|
12
|
+
Defined in: [repositories2/operators/groupBy.ts:13](https://github.com/RueDeRennes/archipel/blob/main/libs/platform-database/src/repositories2/operators/groupBy.ts#L13)
|
|
13
|
+
|
|
14
|
+
**`Beta`**
|
|
15
|
+
|
|
16
|
+
Performs a group-by query via the delegate `groupBy` method.
|
|
17
|
+
|
|
18
|
+
## Type Parameters
|
|
19
|
+
|
|
20
|
+
| Type Parameter |
|
|
21
|
+
| ------ |
|
|
22
|
+
| `D` *extends* `IGroupByDelegate` |
|
|
23
|
+
| `A` *extends* `unknown` |
|
|
24
|
+
|
|
25
|
+
## Parameters
|
|
26
|
+
|
|
27
|
+
| Parameter | Type | Description |
|
|
28
|
+
| ------ | ------ | ------ |
|
|
29
|
+
| `args` | `A` | Prisma groupBy arguments |
|
|
30
|
+
|
|
31
|
+
## Returns
|
|
32
|
+
|
|
33
|
+
`QueryOperator`\<`D`, `ReturnType`\<`D`\[`"groupBy"`\]\>\>
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: 'Function: pipe()'
|
|
3
|
+
generated: true
|
|
4
|
+
editUrl: false
|
|
5
|
+
---
|
|
6
|
+
# Function: pipe()
|
|
7
|
+
|
|
8
|
+
```ts
|
|
9
|
+
function pipe<D, R>(delegate, op): R;
|
|
10
|
+
```
|
|
11
|
+
|
|
12
|
+
Defined in: [repositories2/operators/pipe.ts:10](https://github.com/RueDeRennes/archipel/blob/main/libs/platform-database/src/repositories2/operators/pipe.ts#L10)
|
|
13
|
+
|
|
14
|
+
**`Beta`**
|
|
15
|
+
|
|
16
|
+
Executes a single operator against the provided delegate.
|
|
17
|
+
|
|
18
|
+
## Type Parameters
|
|
19
|
+
|
|
20
|
+
| Type Parameter | Description |
|
|
21
|
+
| ------ | ------ |
|
|
22
|
+
| `D` | Concrete delegate type (e.g. Prisma.UserDelegate) |
|
|
23
|
+
| `R` | Result type produced by the operator |
|
|
24
|
+
|
|
25
|
+
## Parameters
|
|
26
|
+
|
|
27
|
+
| Parameter | Type |
|
|
28
|
+
| ------ | ------ |
|
|
29
|
+
| `delegate` | `D` |
|
|
30
|
+
| `op` | `QueryOperator`\<`D`, `R`\> |
|
|
31
|
+
|
|
32
|
+
## Returns
|
|
33
|
+
|
|
34
|
+
`R`
|