@palbase/backend 33.0.1 → 34.0.0
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/dist/bin/palbase-backend.cjs +2020 -350
- package/dist/bin/palbase-backend.cjs.map +1 -1
- package/dist/bin/palbase-backend.js +9 -7
- package/dist/bin/palbase-backend.js.map +1 -1
- package/dist/{chunk-SI4KGEM3.js → chunk-FOWA7PF4.js} +97 -96
- package/dist/chunk-FOWA7PF4.js.map +1 -0
- package/dist/chunk-GHNC2UHS.js +20 -0
- package/dist/chunk-GHNC2UHS.js.map +1 -0
- package/dist/{chunk-BRLJOXWS.js → chunk-JJW3L62T.js} +3 -3
- package/dist/chunk-JJW3L62T.js.map +1 -0
- package/dist/{chunk-TVCCR6SO.js → chunk-LOGL2ZHD.js} +58 -9
- package/dist/chunk-LOGL2ZHD.js.map +1 -0
- package/dist/{chunk-IKDONZ5D.js → chunk-MNGZE2MM.js} +1651 -186
- package/dist/chunk-MNGZE2MM.js.map +1 -0
- package/dist/{chunk-XOX6RFPZ.js → chunk-PRH45NZU.js} +46 -3
- package/dist/chunk-PRH45NZU.js.map +1 -0
- package/dist/{chunk-26GH54D2.js → chunk-RZLY4BOY.js} +5 -3
- package/dist/{chunk-26GH54D2.js.map → chunk-RZLY4BOY.js.map} +1 -1
- package/dist/{chunk-YIQ4RS4F.js → chunk-SEM36BWY.js} +283 -5
- package/dist/chunk-SEM36BWY.js.map +1 -0
- package/dist/{chunk-KATPXCJ5.js → chunk-UMESJJRS.js} +19 -40
- package/dist/chunk-UMESJJRS.js.map +1 -0
- package/dist/chunk-VXPNPVAG.js +40 -0
- package/dist/chunk-VXPNPVAG.js.map +1 -0
- package/dist/{chunk-WWUG2QXF.js → chunk-YX7UA7VC.js} +53 -4
- package/dist/chunk-YX7UA7VC.js.map +1 -0
- package/dist/db/env.cjs.map +1 -1
- package/dist/db/env.d.cts +2 -0
- package/dist/db/env.d.ts +2 -0
- package/dist/db/index.cjs +261 -2
- package/dist/db/index.cjs.map +1 -1
- package/dist/db/index.d.cts +46 -3
- package/dist/db/index.d.ts +46 -3
- package/dist/db/index.js +14 -5
- package/dist/{index-DMZG3kpo.d.ts → endpoint-DpNUx-ON.d.ts} +315 -57
- package/dist/{index-DB_nW-AV.d.cts → endpoint-kYgEHrrV.d.cts} +315 -57
- package/dist/engine/index.cjs +2026 -348
- package/dist/engine/index.cjs.map +1 -1
- package/dist/engine/index.d.cts +5 -5
- package/dist/engine/index.d.ts +5 -5
- package/dist/engine/index.js +17 -7
- package/dist/{index-D-3duy8Y.d.ts → index-JrHqNsjQ.d.ts} +108 -50
- package/dist/{index-DLveQoOf.d.cts → index-pnDsEfxJ.d.cts} +108 -50
- package/dist/index.cjs +616 -254
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +7 -6
- package/dist/index.d.ts +7 -6
- package/dist/index.js +25 -15
- package/dist/index.js.map +1 -1
- package/dist/openapi/index.cjs +8 -1
- package/dist/openapi/index.cjs.map +1 -1
- package/dist/openapi/index.d.cts +3 -3
- package/dist/openapi/index.d.ts +3 -3
- package/dist/openapi/index.js +4 -3
- package/dist/openapi/index.js.map +1 -1
- package/dist/{registry-DSTThhKf.d.cts → registry-BcOd8Zhf.d.cts} +3 -1
- package/dist/{registry-JjF5lcj4.d.ts → registry-BoX5iNyY.d.ts} +3 -1
- package/dist/test/index.cjs +103 -66
- package/dist/test/index.cjs.map +1 -1
- package/dist/test/index.d.cts +3 -3
- package/dist/test/index.d.ts +3 -3
- package/dist/test/index.js +33 -7
- package/dist/test/index.js.map +1 -1
- package/docs/README.md +1 -1
- package/docs/database.md +308 -0
- package/docs/examples/check-query-contracts.ts +5 -0
- package/docs/examples/database-dx.contract.json +65 -0
- package/docs/examples/database-dx.ts +63 -0
- package/docs/examples/money-transfer.ts +73 -0
- package/docs/llms-full.txt +309 -1
- package/package.json +1 -2
- package/template/AGENTS.md +7 -7
- package/template/modules/health/health.controller.ts +7 -4
- package/template/modules/notes/dto/create.ts +4 -3
- package/template/modules/notes/notes.controller.ts +8 -6
- package/template/package.json +1 -1
- package/dist/chunk-BRLJOXWS.js.map +0 -1
- package/dist/chunk-IKDONZ5D.js.map +0 -1
- package/dist/chunk-KATPXCJ5.js.map +0 -1
- package/dist/chunk-SI4KGEM3.js.map +0 -1
- package/dist/chunk-TVCCR6SO.js.map +0 -1
- package/dist/chunk-WWUG2QXF.js.map +0 -1
- package/dist/chunk-XOX6RFPZ.js.map +0 -1
- package/dist/chunk-YIQ4RS4F.js.map +0 -1
- package/stack-images.json +0 -24
|
@@ -1,8 +1,112 @@
|
|
|
1
|
-
import { Schemas, Tables, TableTypes } from './db/env.cjs';
|
|
2
1
|
import { ZodSchema, z } from 'zod';
|
|
3
2
|
import { PalbaseFlagKey, Buckets, BucketTypes, PalbaseSecretName } from './stack.cjs';
|
|
3
|
+
import { Schemas, Tables, TableTypes } from './db/env.cjs';
|
|
4
4
|
import { AsyncLocalStorage } from 'node:async_hooks';
|
|
5
5
|
|
|
6
|
+
interface CommandOptions {
|
|
7
|
+
/** auto uses the sequential plan when a command cannot be compiled or the
|
|
8
|
+
* executor is not installed. compiled refuses fallback; sequential opts out. */
|
|
9
|
+
mode?: "auto" | "compiled" | "sequential";
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
interface InsertManyOptions<Key extends string = string> {
|
|
13
|
+
onConflict?: readonly Key[];
|
|
14
|
+
/** Defaults to ignore when onConflict is supplied. */
|
|
15
|
+
action?: "ignore" | "update";
|
|
16
|
+
/** false returns the affected row count and skips row serialization. */
|
|
17
|
+
returning?: boolean;
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
/** Forward and backward requests are exclusive. Omit the size for 50 rows. */
|
|
21
|
+
type PageNavigation = {
|
|
22
|
+
first?: number;
|
|
23
|
+
after?: string;
|
|
24
|
+
last?: never;
|
|
25
|
+
before?: never;
|
|
26
|
+
} | {
|
|
27
|
+
last?: number;
|
|
28
|
+
before?: string;
|
|
29
|
+
first?: never;
|
|
30
|
+
after?: never;
|
|
31
|
+
};
|
|
32
|
+
interface PageInfo {
|
|
33
|
+
startCursor: string | null;
|
|
34
|
+
endCursor: string | null;
|
|
35
|
+
hasNextPage: boolean;
|
|
36
|
+
hasPreviousPage: boolean;
|
|
37
|
+
}
|
|
38
|
+
interface Page<Row> {
|
|
39
|
+
rows: Row[];
|
|
40
|
+
pageInfo: PageInfo;
|
|
41
|
+
}
|
|
42
|
+
/** The raw transport surface. Typed tables restrict column and relation names. */
|
|
43
|
+
type RawPageOptions = PageNavigation & {
|
|
44
|
+
orderBy?: {
|
|
45
|
+
column: string;
|
|
46
|
+
direction?: "asc" | "desc";
|
|
47
|
+
nulls?: "first" | "last";
|
|
48
|
+
} | readonly {
|
|
49
|
+
column: string;
|
|
50
|
+
direction?: "asc" | "desc";
|
|
51
|
+
nulls?: "first" | "last";
|
|
52
|
+
}[];
|
|
53
|
+
select?: readonly string[];
|
|
54
|
+
with?: Record<string, unknown>;
|
|
55
|
+
};
|
|
56
|
+
|
|
57
|
+
interface DatabaseBudget {
|
|
58
|
+
/** Application statements, including failed statements and retry attempts. */
|
|
59
|
+
maxQueries?: number;
|
|
60
|
+
/** Root rows returned across application statements. Nested relation rows are included in bytes. */
|
|
61
|
+
maxRows?: number;
|
|
62
|
+
/** Estimated JSON result bytes; this is not PostgreSQL protocol traffic. */
|
|
63
|
+
maxBytes?: number;
|
|
64
|
+
}
|
|
65
|
+
interface DatabaseQueryEvent {
|
|
66
|
+
ordinal: number;
|
|
67
|
+
fingerprint: string;
|
|
68
|
+
name?: string;
|
|
69
|
+
sql?: string;
|
|
70
|
+
source?: string;
|
|
71
|
+
durationMs: number;
|
|
72
|
+
rows: number;
|
|
73
|
+
bytes: number;
|
|
74
|
+
errorCode?: string;
|
|
75
|
+
}
|
|
76
|
+
interface DatabaseDiagnostics {
|
|
77
|
+
endpoint?: string;
|
|
78
|
+
requestId?: string;
|
|
79
|
+
outcome: "active" | "committed" | "failed";
|
|
80
|
+
elapsedMs: number;
|
|
81
|
+
queries: number;
|
|
82
|
+
rows: number;
|
|
83
|
+
bytes: number;
|
|
84
|
+
queueMs: number;
|
|
85
|
+
/** Time until the driver's transaction callback starts; includes wire BEGIN. */
|
|
86
|
+
poolMs: number;
|
|
87
|
+
setupMs: number;
|
|
88
|
+
/** Driver wait including PostgreSQL execution/locks and network time. */
|
|
89
|
+
sqlMs: number;
|
|
90
|
+
commitMs: number;
|
|
91
|
+
rollbackMs: number;
|
|
92
|
+
commits: number;
|
|
93
|
+
commitFailures: number;
|
|
94
|
+
rollbackRequests: number;
|
|
95
|
+
retries: number;
|
|
96
|
+
/** Bounded to the first 200 completed statements. Totals include every statement. */
|
|
97
|
+
statements: readonly DatabaseQueryEvent[];
|
|
98
|
+
}
|
|
99
|
+
interface DatabaseDiagnosticsOptions extends DatabaseBudget {
|
|
100
|
+
endpoint?: string;
|
|
101
|
+
requestId?: string;
|
|
102
|
+
/** Opt-in because a stack capture costs work on every statement. */
|
|
103
|
+
captureSource?: boolean;
|
|
104
|
+
/** SQL parameters are never recorded. Raw SQL text can contain inline literals. */
|
|
105
|
+
includeSql?: boolean;
|
|
106
|
+
onQuery?: (event: DatabaseQueryEvent) => void | Promise<void>;
|
|
107
|
+
onComplete?: (diagnostics: DatabaseDiagnostics) => void | Promise<void>;
|
|
108
|
+
}
|
|
109
|
+
|
|
6
110
|
/** Supported HTTP methods for endpoints. */
|
|
7
111
|
type HttpMethod = "GET" | "POST" | "PUT" | "PATCH" | "DELETE";
|
|
8
112
|
/**
|
|
@@ -144,6 +248,13 @@ type MiddlewareHandler = (ctx: MiddlewareContext, next: () => Promise<void>) =>
|
|
|
144
248
|
*/
|
|
145
249
|
declare function defineMiddleware(_fn: MiddlewareHandler): never;
|
|
146
250
|
|
|
251
|
+
/** A union of exact keys, not a partial row that could match many records. */
|
|
252
|
+
type UniqueWhere<Row, Keys> = Keys extends readonly (infer Key extends readonly string[])[] ? Key extends unknown ? {
|
|
253
|
+
[K in Extract<Key[number], keyof Row>]-?: NonNullable<Row[K]>;
|
|
254
|
+
} & {
|
|
255
|
+
[K in Exclude<keyof Row, Key[number]>]?: never;
|
|
256
|
+
} : never : never;
|
|
257
|
+
|
|
147
258
|
/** On delete action for foreign key references. */
|
|
148
259
|
type OnDeleteAction = 'cascade' | 'set null' | 'restrict' | 'no action';
|
|
149
260
|
/**
|
|
@@ -2938,23 +3049,95 @@ declare const Flags: PalbaseFlagsAmbient;
|
|
|
2938
3049
|
*/
|
|
2939
3050
|
declare const Realtime: PalbaseRealtimeClient;
|
|
2940
3051
|
|
|
2941
|
-
/**
|
|
2942
|
-
*
|
|
2943
|
-
|
|
2944
|
-
|
|
2945
|
-
|
|
2946
|
-
|
|
2947
|
-
|
|
2948
|
-
|
|
2949
|
-
|
|
2950
|
-
|
|
2951
|
-
|
|
2952
|
-
|
|
2953
|
-
|
|
2954
|
-
|
|
2955
|
-
|
|
2956
|
-
|
|
2957
|
-
|
|
3052
|
+
/** Limits apply per engine process. PostgreSQL locks remain the authority when
|
|
3053
|
+
* several replicas write the same rows. Size the total budget across replicas. */
|
|
3054
|
+
interface WorkloadOptions {
|
|
3055
|
+
concurrency: number;
|
|
3056
|
+
queueLimit: number;
|
|
3057
|
+
tenantConcurrency?: number;
|
|
3058
|
+
tenantQueueLimit?: number;
|
|
3059
|
+
queueTimeoutMs?: number;
|
|
3060
|
+
/** Read from authenticated claims; defaults to tenant_id, then sub, then one
|
|
3061
|
+
* shared anonymous bucket. A request body never chooses the tenant budget. */
|
|
3062
|
+
tenantClaim?: string;
|
|
3063
|
+
}
|
|
3064
|
+
interface DatabaseWorkload {
|
|
3065
|
+
readonly name: string;
|
|
3066
|
+
readonly concurrency: number;
|
|
3067
|
+
readonly queueLimit: number;
|
|
3068
|
+
readonly tenantConcurrency: number;
|
|
3069
|
+
readonly tenantQueueLimit: number;
|
|
3070
|
+
readonly queueTimeoutMs: number;
|
|
3071
|
+
readonly tenantClaim: string;
|
|
3072
|
+
}
|
|
3073
|
+
/** Declare once at module scope and reuse on $atomic calls. Keys, queue limits
|
|
3074
|
+
* and tenant budgets affect admission, not SQL permissions or isolation. */
|
|
3075
|
+
declare function defineWorkload(name: string, options: WorkloadOptions): DatabaseWorkload;
|
|
3076
|
+
|
|
3077
|
+
/** A PostgreSQL isolation level supported by the explicit root transaction. */
|
|
3078
|
+
type TransactionIsolation = "read committed" | "repeatable read" | "serializable";
|
|
3079
|
+
interface AtomicOptions {
|
|
3080
|
+
/** Each retry opens a fresh transaction and reruns the complete callback.
|
|
3081
|
+
* Defaults to zero. Keep external effects outside it; persist an outbox instead. */
|
|
3082
|
+
retry?: number;
|
|
3083
|
+
isolation?: TransactionIsolation;
|
|
3084
|
+
readOnly?: boolean;
|
|
3085
|
+
/** Maximum wait for a PostgreSQL lock. Defaults to 5000 ms. */
|
|
3086
|
+
lockTimeoutMs?: number;
|
|
3087
|
+
/** PostgreSQL statement timeout; applies to every statement in this scope. */
|
|
3088
|
+
statementTimeoutMs?: number;
|
|
3089
|
+
/** Total work deadline including queueing and retries. Active Bun queries are
|
|
3090
|
+
* cancelled; rollback settles before release. An in-flight COMMIT is awaited. */
|
|
3091
|
+
timeoutMs?: number;
|
|
3092
|
+
signal?: AbortSignal;
|
|
3093
|
+
workload?: DatabaseWorkload;
|
|
3094
|
+
/** Resource names shared within a workload. Include a tenant prefix if the
|
|
3095
|
+
* resource ID itself is only unique inside a tenant. Requires workload. */
|
|
3096
|
+
conflictKeys?: readonly string[];
|
|
3097
|
+
}
|
|
3098
|
+
|
|
3099
|
+
/** Storage metadata that affects the declared response; defaults and unrelated
|
|
3100
|
+
* columns do not change an explicitly projected query's contract. */
|
|
3101
|
+
interface QueryColumnContract {
|
|
3102
|
+
type: string;
|
|
3103
|
+
nullable: boolean;
|
|
3104
|
+
codec?: string;
|
|
3105
|
+
enumValues?: readonly string[];
|
|
3106
|
+
dimensions?: number;
|
|
3107
|
+
}
|
|
3108
|
+
interface PreparedRead {
|
|
3109
|
+
name: string;
|
|
3110
|
+
table: string;
|
|
3111
|
+
columns: Record<string, QueryColumnContract>;
|
|
3112
|
+
where: Record<string, unknown>;
|
|
3113
|
+
options: {
|
|
3114
|
+
select: string[];
|
|
3115
|
+
orderBy?: {
|
|
3116
|
+
column: string;
|
|
3117
|
+
direction?: "asc" | "desc";
|
|
3118
|
+
nulls?: "first" | "last";
|
|
3119
|
+
} | {
|
|
3120
|
+
column: string;
|
|
3121
|
+
direction?: "asc" | "desc";
|
|
3122
|
+
nulls?: "first" | "last";
|
|
3123
|
+
}[];
|
|
3124
|
+
limit?: number;
|
|
3125
|
+
};
|
|
3126
|
+
}
|
|
3127
|
+
interface CompiledRead {
|
|
3128
|
+
sql: string;
|
|
3129
|
+
params: unknown[];
|
|
3130
|
+
}
|
|
3131
|
+
interface QueryDatabase {
|
|
3132
|
+
readQuery(query: PreparedRead): Promise<Record<string, unknown>[]>;
|
|
3133
|
+
compileQuery(query: PreparedRead): CompiledRead;
|
|
3134
|
+
explainQuery(query: PreparedRead): Promise<unknown[]>;
|
|
3135
|
+
}
|
|
3136
|
+
interface EnvQueryDatabase {
|
|
3137
|
+
$readQuery: QueryDatabase["readQuery"];
|
|
3138
|
+
$compileQuery: QueryDatabase["compileQuery"];
|
|
3139
|
+
$explainQuery: QueryDatabase["explainQuery"];
|
|
3140
|
+
}
|
|
2958
3141
|
|
|
2959
3142
|
/** Keys of C whose columns are required on INSERT (not nullable, no default). */
|
|
2960
3143
|
type RequiredKeys<C> = {
|
|
@@ -2986,12 +3169,22 @@ type RowShape<T extends TableDef> = {
|
|
|
2986
3169
|
};
|
|
2987
3170
|
/** A typed table accessor that mirrors the runtime DBClient surface. */
|
|
2988
3171
|
interface TypedTable<T extends TableDef> {
|
|
3172
|
+
/** Runtime validates the key against the installed schema. Generated env tables
|
|
3173
|
+
* also check the complete unique/composite key at compile time. */
|
|
3174
|
+
findUnique<K extends keyof RowShape<T> = keyof RowShape<T>>(q: {
|
|
3175
|
+
where: Partial<RowShape<T>>;
|
|
3176
|
+
select?: readonly K[];
|
|
3177
|
+
}): Promise<Pick<RowShape<T>, K> | null>;
|
|
3178
|
+
page<K extends keyof RowShape<T> = keyof RowShape<T>>(q?: PageInput<RowShape<T>, K>): Promise<Page<Pick<RowShape<T>, K>>>;
|
|
2989
3179
|
insert(data: InsertValues<InsertShape<T>>): Promise<RowShape<T>>;
|
|
2990
3180
|
/** Çok satır, TEK statement. Satırların anahtar kümesi aynı olmalı. */
|
|
2991
|
-
insertMany(rows: readonly InsertValues<InsertShape<T>>[], opts
|
|
2992
|
-
|
|
2993
|
-
|
|
3181
|
+
insertMany(rows: readonly InsertValues<InsertShape<T>>[], opts: InsertManyOptions & {
|
|
3182
|
+
returning: false;
|
|
3183
|
+
}): Promise<number>;
|
|
3184
|
+
insertMany(rows: readonly InsertValues<InsertShape<T>>[], opts?: InsertManyOptions & {
|
|
3185
|
+
returning?: true;
|
|
2994
3186
|
}): Promise<RowShape<T>[]>;
|
|
3187
|
+
insertMany(rows: readonly InsertValues<InsertShape<T>>[], opts?: InsertManyOptions): Promise<RowShape<T>[] | number>;
|
|
2995
3188
|
put(q: {
|
|
2996
3189
|
data: InsertShape<T>;
|
|
2997
3190
|
onConflict: readonly string[];
|
|
@@ -3058,7 +3251,9 @@ interface TypedTable<T extends TableDef> {
|
|
|
3058
3251
|
}): Promise<number>;
|
|
3059
3252
|
}
|
|
3060
3253
|
/** A typed DB facade covering all tables declared in schema `S`. */
|
|
3061
|
-
interface TypedDB<S extends SchemaDef> {
|
|
3254
|
+
interface TypedDB<S extends SchemaDef> extends QueryDatabase {
|
|
3255
|
+
diagnostics: DBOps["diagnostics"];
|
|
3256
|
+
command<T>(fn: (tx: TypedTx<S>) => T extends Promise<unknown> ? never : T, options?: CommandOptions): Promise<Materialized<T>>;
|
|
3062
3257
|
tables: {
|
|
3063
3258
|
[K in keyof S["tables"]]: TypedTable<S["tables"][K]>;
|
|
3064
3259
|
};
|
|
@@ -3095,7 +3290,7 @@ type TypedTx<S extends SchemaDef> = TxPlanHandle<{
|
|
|
3095
3290
|
* object to the precise mapped type (TS cannot infer the mapped-type result
|
|
3096
3291
|
* through `Object.keys` iteration) — see the module-level doc comment.
|
|
3097
3292
|
*/
|
|
3098
|
-
declare function makeTypedDB<S extends SchemaDef>(schema: S, raw:
|
|
3293
|
+
declare function makeTypedDB<S extends SchemaDef>(schema: S, raw: AtomicClient): TypedDB<S>;
|
|
3099
3294
|
/** Bir where değeri: düz eşitlik YA DA operatör nesnesi (FR-016). */
|
|
3100
3295
|
/**
|
|
3101
3296
|
* Metin operatörleri YALNIZ metin kolonlarında görünür (FR-005).
|
|
@@ -3240,10 +3435,9 @@ type SqlFragment = {
|
|
|
3240
3435
|
/**
|
|
3241
3436
|
* Retryable bir hatada işlemi yeniden dener (FR-037).
|
|
3242
3437
|
*
|
|
3243
|
-
*
|
|
3244
|
-
*
|
|
3245
|
-
*
|
|
3246
|
-
* çalışan yarısı.
|
|
3438
|
+
* `fn` must open and settle a NEW transaction on each invocation. Repeating
|
|
3439
|
+
* a savepoint retains the old snapshot and cannot retry a failed COMMIT.
|
|
3440
|
+
* Database.$atomic owns that boundary for ordinary application code.
|
|
3247
3441
|
*
|
|
3248
3442
|
* VARSAYILAN SIFIR. Sessiz bir varsayılan retry, idempotent OLMAYAN bir işlemi
|
|
3249
3443
|
* çağıranın haberi olmadan iki kez çalıştırırdı — bir para transferini iki kez.
|
|
@@ -3283,7 +3477,12 @@ type TextOps<V> = V extends string ? {
|
|
|
3283
3477
|
icontains?: string;
|
|
3284
3478
|
startsWith?: string;
|
|
3285
3479
|
endsWith?: string;
|
|
3286
|
-
} :
|
|
3480
|
+
} : {
|
|
3481
|
+
contains?: never;
|
|
3482
|
+
icontains?: never;
|
|
3483
|
+
startsWith?: never;
|
|
3484
|
+
endsWith?: never;
|
|
3485
|
+
};
|
|
3287
3486
|
/** Operatör gövdesi, kolon-referans tipi DIŞARIDAN verilmiş hâliyle.
|
|
3288
3487
|
*
|
|
3289
3488
|
* `C` bir parametre, çünkü `ColRefOf<Row, V>` aksi hâlde altı operatör
|
|
@@ -3469,16 +3668,17 @@ type HasBranch<Row, Rels> = [unknown] extends [Rels] ? never : [keyof Rels] exte
|
|
|
3469
3668
|
* `true` bütün kolonları, bir nesne ise `select`/`where`/`orderBy`/`limit` ile
|
|
3470
3669
|
* daraltılmış hâlini getiriyor. Tek sorgu: LATERAL + `json_agg`.
|
|
3471
3670
|
*/
|
|
3472
|
-
type WithOpts<To> = {
|
|
3671
|
+
type WithOpts<To, D extends HasDepth> = {
|
|
3473
3672
|
select?: readonly Extract<keyof RelatedRow<To>, string>[];
|
|
3474
3673
|
where?: WhereFilter<RelatedRow<To>>;
|
|
3475
3674
|
orderBy?: OrderBySpec<RelatedRow<To>> | readonly OrderBySpec<RelatedRow<To>>[];
|
|
3476
3675
|
limit?: number;
|
|
3676
|
+
with?: D extends 1 ? never : [keyof RelatedRels<To>] extends [never] ? never : WithInput<RelatedRels<To>, HasDec[D]>;
|
|
3477
3677
|
};
|
|
3478
|
-
type WithInput<Rels> = {
|
|
3678
|
+
type WithInput<Rels, D extends HasDepth = 3> = {
|
|
3479
3679
|
[R in keyof Rels]?: Rels[R] extends {
|
|
3480
3680
|
to: infer To;
|
|
3481
|
-
} ? true | WithOpts<To> : never;
|
|
3681
|
+
} ? true | WithOpts<To, D> : never;
|
|
3482
3682
|
};
|
|
3483
3683
|
/** Bir `with` dalının DÖNÜŞ tipi — `many` dizi, `one` tekil ya da null. */
|
|
3484
3684
|
type WithRowOf<Rels, R extends keyof Rels, Q> = Rels[R] extends {
|
|
@@ -3486,7 +3686,9 @@ type WithRowOf<Rels, R extends keyof Rels, Q> = Rels[R] extends {
|
|
|
3486
3686
|
kind: infer K;
|
|
3487
3687
|
} ? (Q extends {
|
|
3488
3688
|
select: readonly (infer C extends keyof RelatedRow<To>)[];
|
|
3489
|
-
} ? Pick<RelatedRow<To>, C> : RelatedRow<To>)
|
|
3689
|
+
} ? Pick<RelatedRow<To>, C> : RelatedRow<To>) & (Q extends {
|
|
3690
|
+
with: infer W;
|
|
3691
|
+
} ? WithResult<RelatedRels<To>, W> : unknown) extends infer Row ? [K] extends ["many"] ? Row[] : Row | null : never : never;
|
|
3490
3692
|
/**
|
|
3491
3693
|
* `with` istenmediğinde `unknown` — kesişimde YOK OLSUN diye.
|
|
3492
3694
|
*
|
|
@@ -3544,6 +3746,9 @@ type QueryInput<Row, K extends keyof Row = keyof Row, Rels = unknown> = {
|
|
|
3544
3746
|
*/
|
|
3545
3747
|
select?: readonly K[];
|
|
3546
3748
|
} & FindManyOpts<Row>;
|
|
3749
|
+
type PageInput<Row, K extends keyof Row = keyof Row, Rels = unknown> = Omit<QueryInput<Row, keyof Row, Rels>, "limit" | "offset" | "select"> & {
|
|
3750
|
+
select?: readonly K[];
|
|
3751
|
+
} & PageNavigation;
|
|
3547
3752
|
/** Bir yazmanın TEK parametresi: neyi (`where`) neye çevirdiğin (`set`). */
|
|
3548
3753
|
type MutateInput<Row, Insert, Rels = unknown> = {
|
|
3549
3754
|
where: WhereFilter<Row> | SqlFragment | HasBranch<Row, Rels>;
|
|
@@ -3727,6 +3932,16 @@ type AggregateResult<Q, Row> = Q extends {
|
|
|
3727
3932
|
} & AggBody<Q, Row>)[] : AggBody<Q, Row>;
|
|
3728
3933
|
/** Temel tablo erişimcisi — search'süz beş op. */
|
|
3729
3934
|
interface EnvTypedTableBase<T extends TableTypes> {
|
|
3935
|
+
findUnique<K extends keyof T["row"] = keyof T["row"], W extends WithInput<RelsOf<T>> = Record<never, never>>(q: {
|
|
3936
|
+
where: UniqueWhere<T["row"], T["uniqueKeys"]>;
|
|
3937
|
+
select?: readonly K[];
|
|
3938
|
+
with?: QueryInput<T["row"], keyof T["row"], RelsOf<T>>["with"] & W;
|
|
3939
|
+
}): Promise<(Pick<T["row"], K> & WithResult<RelsOf<T>, W>) | null>;
|
|
3940
|
+
/** Index-backed pagination. The engine appends the declared primary key to
|
|
3941
|
+
* orderBy, encrypts cursor values and validates the query and caller scope. */
|
|
3942
|
+
page<K extends keyof T["row"] = keyof T["row"], W extends WithInput<RelsOf<T>> = Record<never, never>>(q?: PageInput<T["row"], K, RelsOf<T>> & {
|
|
3943
|
+
with?: W;
|
|
3944
|
+
}): Promise<Page<Pick<T["row"], K> & WithResult<RelsOf<T>, W>>>;
|
|
3730
3945
|
insert(data: InsertValues<T["insert"]>): Promise<T["row"]>;
|
|
3731
3946
|
/**
|
|
3732
3947
|
* Çok satırı TEK statement'la ekle (tek gidiş-dönüş).
|
|
@@ -3743,14 +3958,13 @@ interface EnvTypedTableBase<T extends TableTypes> {
|
|
|
3743
3958
|
*
|
|
3744
3959
|
* Boş dizi boş sonuç döner — hata değil: "eklenecek bir şey yoktu".
|
|
3745
3960
|
*/
|
|
3746
|
-
insertMany(rows: readonly InsertValues<T["insert"]>[], opts
|
|
3747
|
-
|
|
3748
|
-
|
|
3749
|
-
|
|
3750
|
-
|
|
3751
|
-
* üzerine yazar. */
|
|
3752
|
-
action?: "ignore" | "update";
|
|
3961
|
+
insertMany(rows: readonly InsertValues<T["insert"]>[], opts: InsertManyOptions<Extract<keyof T["row"], string>> & {
|
|
3962
|
+
returning: false;
|
|
3963
|
+
}): Promise<number>;
|
|
3964
|
+
insertMany(rows: readonly InsertValues<T["insert"]>[], opts?: InsertManyOptions<Extract<keyof T["row"], string>> & {
|
|
3965
|
+
returning?: true;
|
|
3753
3966
|
}): Promise<T["row"][]>;
|
|
3967
|
+
insertMany(rows: readonly InsertValues<T["insert"]>[], opts?: InsertManyOptions<Extract<keyof T["row"], string>>): Promise<T["row"][] | number>;
|
|
3754
3968
|
/**
|
|
3755
3969
|
* Bir idempotency anahtarını sahiplen (FR-033).
|
|
3756
3970
|
*
|
|
@@ -4007,13 +4221,22 @@ type TxPlan = TxPlanHandle<TxTables> & TxSchemaSurface;
|
|
|
4007
4221
|
* Every op it performs runs as the `service_role` (BYPASSRLS).
|
|
4008
4222
|
*/
|
|
4009
4223
|
type EnvServiceDatabase = EnvSchemaSurface & {
|
|
4224
|
+
/** Commits independently of the request. All decision reads and writes belong
|
|
4225
|
+
* inside this callback; each retry includes a new BEGIN and COMMIT. */
|
|
4226
|
+
$atomic<T>(fn: (tx: AtomicDatabase) => Promise<T>, options?: AtomicOptions): Promise<T>;
|
|
4010
4227
|
/** Ham SQL. Generic verilmezse `unknown[]` döner (FR-021). */
|
|
4011
4228
|
$query: DBClient["query"];
|
|
4012
4229
|
$insert: DBClient["insert"];
|
|
4013
4230
|
$update: DBClient["update"];
|
|
4014
4231
|
$delete: DBClient["delete"];
|
|
4015
4232
|
$findById: DBClient["findById"];
|
|
4233
|
+
$findUnique: DBClient["findUnique"];
|
|
4234
|
+
$readQuery: DBClient["readQuery"];
|
|
4235
|
+
$diagnostics: DBClient["diagnostics"];
|
|
4236
|
+
$compileQuery: DBClient["compileQuery"];
|
|
4237
|
+
$explainQuery: DBClient["explainQuery"];
|
|
4016
4238
|
$findMany: DBClient["findMany"];
|
|
4239
|
+
$page: DBClient["page"];
|
|
4017
4240
|
$put: DBClient["put"];
|
|
4018
4241
|
$updateMany: DBClient["updateMany"];
|
|
4019
4242
|
$deleteMany: DBClient["deleteMany"];
|
|
@@ -4027,12 +4250,12 @@ type EnvServiceDatabase = EnvSchemaSurface & {
|
|
|
4027
4250
|
$lockRows: DBClient["lockRows"];
|
|
4028
4251
|
$advisoryXactLock: DBClient["advisoryXactLock"];
|
|
4029
4252
|
$attempt: DBClient["attempt"];
|
|
4253
|
+
$command<T>(fn: (tx: TxPlan) => T extends Promise<unknown> ? never : T, options?: CommandOptions): Promise<Materialized<T>>;
|
|
4030
4254
|
/** Bkz. {@link EnvTypedDatabase.$transaction}. */
|
|
4031
4255
|
/**
|
|
4032
|
-
*
|
|
4033
|
-
*
|
|
4034
|
-
*
|
|
4035
|
-
* haberi olmadan iki kez çalıştırırdı.
|
|
4256
|
+
* A plan is a savepoint in the current transaction. Nonzero `retry` is
|
|
4257
|
+
* refused; use $atomic for whole-transaction retry, including decision reads
|
|
4258
|
+
* and COMMIT. The default plan keeps request-scoped commit/rollback behavior.
|
|
4036
4259
|
*/
|
|
4037
4260
|
$transaction<T>(fn: (tx: TxPlan) => T extends Promise<unknown> ? never : T, opts?: {
|
|
4038
4261
|
retry?: number;
|
|
@@ -4072,13 +4295,22 @@ type EnvSchemaSurface = {
|
|
|
4072
4295
|
* await Database.$transaction((tx) => { … });
|
|
4073
4296
|
*/
|
|
4074
4297
|
type EnvTypedDatabase = EnvSchemaSurface & {
|
|
4298
|
+
/** Commits independently of the request. A later handler failure does not
|
|
4299
|
+
* undo this scope. The callback cannot switch RLS identity or nest a root. */
|
|
4300
|
+
$atomic<T>(fn: (tx: AtomicDatabase) => Promise<T>, options?: AtomicOptions): Promise<T>;
|
|
4075
4301
|
/** Ham SQL. Generic verilmezse `unknown[]` döner (FR-021). */
|
|
4076
4302
|
$query: DBClient["query"];
|
|
4077
4303
|
$insert: DBClient["insert"];
|
|
4078
4304
|
$update: DBClient["update"];
|
|
4079
4305
|
$delete: DBClient["delete"];
|
|
4080
4306
|
$findById: DBClient["findById"];
|
|
4307
|
+
$findUnique: DBClient["findUnique"];
|
|
4308
|
+
$readQuery: DBClient["readQuery"];
|
|
4309
|
+
$diagnostics: DBClient["diagnostics"];
|
|
4310
|
+
$compileQuery: DBClient["compileQuery"];
|
|
4311
|
+
$explainQuery: DBClient["explainQuery"];
|
|
4081
4312
|
$findMany: DBClient["findMany"];
|
|
4313
|
+
$page: DBClient["page"];
|
|
4082
4314
|
$put: DBClient["put"];
|
|
4083
4315
|
$updateMany: DBClient["updateMany"];
|
|
4084
4316
|
$deleteMany: DBClient["deleteMany"];
|
|
@@ -4092,6 +4324,7 @@ type EnvTypedDatabase = EnvSchemaSurface & {
|
|
|
4092
4324
|
$lockRows: DBClient["lockRows"];
|
|
4093
4325
|
$advisoryXactLock: DBClient["advisoryXactLock"];
|
|
4094
4326
|
$attempt: DBClient["attempt"];
|
|
4327
|
+
$command<T>(fn: (tx: TxPlan) => T extends Promise<unknown> ? never : T, options?: CommandOptions): Promise<Materialized<T>>;
|
|
4095
4328
|
/** RLS'i bypass eden kardeş yüzey. Kendisi `$asService` TAŞIMAZ — çift bypass yok. */
|
|
4096
4329
|
$asService(): EnvServiceDatabase;
|
|
4097
4330
|
/**
|
|
@@ -4100,15 +4333,16 @@ type EnvTypedDatabase = EnvSchemaSurface & {
|
|
|
4100
4333
|
* Callback SENKRONDUR: döndüğünde hiçbir şey çalışmamıştır.
|
|
4101
4334
|
*/
|
|
4102
4335
|
/**
|
|
4103
|
-
*
|
|
4104
|
-
*
|
|
4105
|
-
*
|
|
4106
|
-
* haberi olmadan iki kez çalıştırırdı.
|
|
4336
|
+
* A plan is a savepoint in the current transaction. Nonzero `retry` is
|
|
4337
|
+
* refused; use $atomic for whole-transaction retry, including decision reads
|
|
4338
|
+
* and COMMIT. The default plan keeps request-scoped commit/rollback behavior.
|
|
4107
4339
|
*/
|
|
4108
4340
|
$transaction<T>(fn: (tx: TxPlan) => T extends Promise<unknown> ? never : T, opts?: {
|
|
4109
4341
|
retry?: number;
|
|
4110
4342
|
}): Promise<Materialized<T>>;
|
|
4111
4343
|
};
|
|
4344
|
+
/** The same typed table/query surface on one active physical transaction. */
|
|
4345
|
+
type AtomicDatabase = Omit<EnvServiceDatabase, "$atomic">;
|
|
4112
4346
|
|
|
4113
4347
|
/**
|
|
4114
4348
|
* tx-plan.ts — `Database.$transaction()` as a PLAN, not a pinned session.
|
|
@@ -4768,7 +5002,16 @@ interface RateLimitConfig {
|
|
|
4768
5002
|
}
|
|
4769
5003
|
/** The six raw string-keyed DB operations shared by `DBClient` and the
|
|
4770
5004
|
* transaction-scoped client. */
|
|
4771
|
-
interface DBOps {
|
|
5005
|
+
interface DBOps extends QueryDatabase {
|
|
5006
|
+
/** Null when diagnostics/budgets are disabled. Binding values are never included. */
|
|
5007
|
+
diagnostics(): DatabaseDiagnostics | null;
|
|
5008
|
+
/** Match exactly one declared primary/unique key; null never denotes a unique value. */
|
|
5009
|
+
findUnique(table: string, where: Record<string, unknown>, opts?: {
|
|
5010
|
+
select?: readonly string[];
|
|
5011
|
+
with?: Record<string, unknown>;
|
|
5012
|
+
}): Promise<Record<string, unknown> | null>;
|
|
5013
|
+
/** Keyset pagination with opaque, lossless cursors and a unique ordering. */
|
|
5014
|
+
page(table: string, query?: Record<string, unknown>, opts?: RawPageOptions): Promise<Page<Record<string, unknown>>>;
|
|
4772
5015
|
/**
|
|
4773
5016
|
* Run SQL on the REQUEST'S OWN transaction.
|
|
4774
5017
|
*
|
|
@@ -4814,10 +5057,13 @@ interface DBOps {
|
|
|
4814
5057
|
count?: boolean;
|
|
4815
5058
|
groupBy?: readonly string[];
|
|
4816
5059
|
}): Promise<Record<string, unknown> | Record<string, unknown>[]>;
|
|
4817
|
-
insertMany(table: string, rows: readonly Record<string, unknown>[], opts
|
|
4818
|
-
|
|
4819
|
-
|
|
5060
|
+
insertMany(table: string, rows: readonly Record<string, unknown>[], opts: InsertManyOptions & {
|
|
5061
|
+
returning: false;
|
|
5062
|
+
}): Promise<number>;
|
|
5063
|
+
insertMany(table: string, rows: readonly Record<string, unknown>[], opts?: InsertManyOptions & {
|
|
5064
|
+
returning?: true;
|
|
4820
5065
|
}): Promise<Record<string, unknown>[]>;
|
|
5066
|
+
insertMany(table: string, rows: readonly Record<string, unknown>[], opts?: InsertManyOptions): Promise<Record<string, unknown>[] | number>;
|
|
4821
5067
|
/**
|
|
4822
5068
|
* Insert the row, or update it when it collides on `onConflict` — one
|
|
4823
5069
|
* statement, so two concurrent callers cannot both lose.
|
|
@@ -4945,7 +5191,14 @@ interface DBOps {
|
|
|
4945
5191
|
orderBy?: {
|
|
4946
5192
|
column: string;
|
|
4947
5193
|
direction?: "asc" | "desc";
|
|
4948
|
-
|
|
5194
|
+
nulls?: "first" | "last";
|
|
5195
|
+
} | {
|
|
5196
|
+
column: string;
|
|
5197
|
+
direction?: "asc" | "desc";
|
|
5198
|
+
nulls?: "first" | "last";
|
|
5199
|
+
}[];
|
|
5200
|
+
select?: string[];
|
|
5201
|
+
with?: Record<string, unknown>;
|
|
4949
5202
|
limit?: number;
|
|
4950
5203
|
offset?: number;
|
|
4951
5204
|
}): Promise<Record<string, unknown>[]>;
|
|
@@ -4995,15 +5248,18 @@ interface DBOps {
|
|
|
4995
5248
|
}
|
|
4996
5249
|
/** Database client interface injected into endpoint context. */
|
|
4997
5250
|
interface DBClient extends DBOps {
|
|
5251
|
+
/** Execute a compilable plan on PostgreSQL, with an explicit fallback policy. */
|
|
5252
|
+
command(plan: TxPlanBody, options?: CommandOptions): Promise<TxPlanResponse>;
|
|
5253
|
+
/** An independent physical transaction. Resolves after COMMIT, and retries the
|
|
5254
|
+
* complete callback on a fresh transaction. One identity for its entire scope. */
|
|
5255
|
+
atomic<T>(fn: (tx: AtomicClient) => Promise<T>, options?: AtomicOptions): Promise<T>;
|
|
4998
5256
|
/**
|
|
4999
5257
|
* Run a whole transaction as ONE plan, executed on the request's own
|
|
5000
5258
|
* transaction inside a savepoint.
|
|
5001
5259
|
*
|
|
5002
5260
|
* The low-level seam behind `Database.$transaction(plan)`: the SDK builds the
|
|
5003
|
-
* plan
|
|
5004
|
-
*
|
|
5005
|
-
* Nothing pins a Postgres backend across round trips, because there is only
|
|
5006
|
-
* one round trip.
|
|
5261
|
+
* plan and the local engine executes it on this transaction. A single API
|
|
5262
|
+
* call can issue several SQL statements; it does not promise one DB round trip.
|
|
5007
5263
|
*
|
|
5008
5264
|
* On failure the runtime must reject with an error carrying the broker's
|
|
5009
5265
|
* envelope fields — see {@link TxPlanRejection}. `slot` in particular is what
|
|
@@ -5028,6 +5284,8 @@ interface DBClient extends DBOps {
|
|
|
5028
5284
|
*/
|
|
5029
5285
|
asService(): Omit<DBClient, "asService">;
|
|
5030
5286
|
}
|
|
5287
|
+
/** An active root-transaction handle cannot switch identities or nest another root. */
|
|
5288
|
+
type AtomicClient = Omit<DBClient, "asService" | "atomic">;
|
|
5031
5289
|
/** Logger interface injected into endpoint context. */
|
|
5032
5290
|
interface Logger {
|
|
5033
5291
|
info(message: string, ...args: unknown[]): void;
|
|
@@ -5319,4 +5577,4 @@ type Middleware = (ctx: MiddlewareContext, next: () => Promise<void>) => Promise
|
|
|
5319
5577
|
*/
|
|
5320
5578
|
type AuthSpec = boolean | Partial<AuthConfig>;
|
|
5321
5579
|
|
|
5322
|
-
export { type
|
|
5580
|
+
export { type ErrorMap as $, type AuthSpec as A, BadRequest as B, type CompiledRead as C, type DatabaseBudget as D, type EnvServiceDatabase as E, type ColumnMap as F, type ColumnType as G, HttpError as H, Conflict as I, Database as J, type DatabaseQueryEvent as K, type DatabaseWorkload as L, DeadlockDetected as M, Documents as N, EXTENSION_DEPENDENCIES as O, type PreparedRead as P, type EmbeddingModelRef as Q, type RateLimitConfig as R, type SchemaDef as S, type TransactionIsolation as T, type EnvQueryDatabase as U, type EnvSchemas as V, type EnvTables as W, type EnvTypedDatabase as X, type EnvTypedTable as Y, type ErrorDef as Z, __runWithRuntime as _, type DBClient as a, type PalbaseFileObject as a$, type ErrorThrowers as a0, type FileContext as a1, type FindManyOpts as a2, Flags as a3, Forbidden as a4, type HttpMethod as a5, IndexBuilder as a6, type IndexDef as a7, type InsertManyOptions as a8, type InsertShape as a9, type PalbaseAttestiOSResult as aA, type PalbaseAuthAdminClient as aB, type PalbaseAuthClient as aC, type PalbaseBatchOverrideOperation as aD, type PalbaseBatchSetOverridesResult as aE, type PalbaseBindDeviceParams as aF, type PalbaseBucketClient as aG, type PalbaseClearAllOverridesResult as aH, type PalbaseClearOverrideResult as aI, type PalbaseCohortQueryInput as aJ, type PalbaseCohortResult as aK, type PalbaseCollectionRef as aL, type PalbaseCountQueryInput as aM, type PalbaseCountResult as aN, type PalbaseCreateLinkParams as aO, type PalbaseDeviceInfo as aP, type PalbaseDeviceTokenView as aQ, type PalbaseDocsClient as aR, type PalbaseDocumentRef as aS, type PalbaseDocumentSnapshot as aT, type PalbaseEmailClient as aU, type PalbaseEmailSendParams as aV, type PalbaseEmailSendResponse as aW, type PalbaseEventNamesResult as aX, type PalbaseEventsQueryInput as aY, type PalbaseEventsResult as aZ, type PalbaseExtension as a_, type InsertValues as aa, type LifecycleHook as ab, Log as ac, type Logger as ad, type Materialized as ae, type Middleware as af, type MiddlewareContext as ag, type MiddlewareHandler as ah, type MutateInput as ai, NotFound as aj, Notifications as ak, type OnDeleteAction as al, type OrderBySpec as am, PALBASE_EXTENSIONS as an, type PBRequest as ao, type PageInfo as ap, type PageInput as aq, type PageNavigation as ar, PalError as as, type PalbaseAnalyticsClient as at, type PalbaseAnalyticsManagementNamespace as au, type PalbaseAnalyticsProperties as av, type PalbaseAnalyticsQueryNamespace as aw, type PalbaseAttestAndroidParams as ax, type PalbaseAttestAndroidResult as ay, type PalbaseAttestiOSParams as az, type RuntimeServices as b, PolicyExprRef as b$, type PalbaseFlag as b0, type PalbaseFlagContext as b1, type PalbaseFlagSource as b2, type PalbaseFlagValue as b3, type PalbaseFlagVariant as b4, type PalbaseFlagsClient as b5, type PalbaseFlagsServiceClient as b6, type PalbaseFunctionsClient as b7, type PalbaseFunnelQueryInput as b8, type PalbaseFunnelResult as b9, type PalbaseQuerySnapshot as bA, type PalbaseRealtimeClient as bB, type PalbaseRegisterDeviceParams as bC, type PalbaseRetentionQueryInput as bD, type PalbaseRetentionResult as bE, type PalbaseSession as bF, type PalbaseSetOverrideResult as bG, type PalbaseSetOverridesResult as bH, type PalbaseSignedUrlResponse as bI, type PalbaseSmsClient as bJ, type PalbaseSmsSendParams as bK, type PalbaseSmsSendResponse as bL, type PalbaseStorageClient as bM, type PalbaseTransformOptions as bN, type PalbaseUpdateLinkParams as bO, type PalbaseUploadOptions as bP, type PalbaseUser as bQ, type PalbaseUserDetailResult as bR, type PalbaseUsersQueryInput as bS, type PalbaseUsersResult as bT, type PalbaseVerifyRequestSignatureParams as bU, type PalbaseWhereOperator as bV, type PolicyBinOp as bW, PolicyBuilder as bX, type PolicyCommand as bY, type PolicyDef as bZ, type PolicyExprCtx as b_, type PalbaseIdentifyTraits as ba, type PalbaseInboxClient as bb, type PalbaseInboxListOptions as bc, type PalbaseInboxListResult as bd, type PalbaseInboxMessage as be, type PalbaseInboxSendParams as bf, type PalbaseInboxSendResponse as bg, type PalbaseInitialLink as bh, type PalbaseInvokeOptions as bi, type PalbaseLink as bj, type PalbaseLinkAnalytics as bk, type PalbaseLinkDetails as bl, type PalbaseLinksClient as bm, type PalbaseListLinksOptions as bn, type PalbaseListLinksResult as bo, type PalbaseListOptions as bp, type PalbaseMatchParams as bq, type PalbaseMultiChannelResponse as br, type PalbaseNotificationsClient as bs, type PalbaseOverviewResult as bt, type PalbasePreferences as bu, type PalbasePreferencesClient as bv, type PalbasePushClient as bw, type PalbasePushSendParams as bx, type PalbasePushSendResponse as by, type PalbaseQrCodeOptions as bz, type DatabaseDiagnosticsOptions as c, col as c$, type PolicyMode as c0, type PolicyOperand as c1, type QueryColumnContract as c2, type QueryDatabase as c3, type QueryInput as c4, type RawConstraintDef as c5, Realtime as c6, type Ref as c7, type RequestStore as c8, type RowShape as c9, type TxSetShape as cA, type TxSetValue as cB, type TxTable as cC, type TxTables as cD, type TxWhere as cE, type TxWireExpr as cF, type TxWireGuard as cG, type TxWireOp as cH, type TxWireRef as cI, type TxWireValue as cJ, type TypedDB as cK, type TypedTable as cL, type TypedTx as cM, Unauthorized as cN, UniqueViolation as cO, type UniqueWhere as cP, type User as cQ, type VerifiedDevice as cR, type WhereFilter as cS, type WhereOp as cT, type WorkloadOptions as cU, __getRuntime as cV, __resetLifecycleHooks as cW, __runStartHooks as cX, __setRuntime as cY, bigint as cZ, boolean as c_, Secrets as ca, type SecretsService as cb, SerializationFailure as cc, type SetShape as cd, type SetValue as ce, type ShutdownRunner as cf, type SqlFragment as cg, Storage as ch, TABLE_META as ci, type TableDef as cj, type TableHandle as ck, type TableInput as cl, TooManyRequests as cm, type TxColumnExpr as cn, type TxInsertShape as co, type TxInsertValue as cp, type TxNow as cq, type TxPlan as cr, TxPlanError as cs, type TxPlanHandle as ct, type TxPlanOpResult as cu, type TxPlanRejection as cv, TxRefError as cw, type TxRow as cx, type TxRows as cy, type TxSelectOptions as cz, type DatabaseDiagnostics as d, dec as d0, decrement as d1, defineMiddleware as d2, defineSchema as d3, defineTable as d4, defineWorkload as d5, enumType as d6, exprCtx as d7, inc as d8, increment as d9, index as da, installationRef as db, integer as dc, isPalbaseExtension as dd, isRetryable as de, jsonb as df, makeTypedDB as dg, now as dh, numeric as di, onShutdown as dj, onStart as dk, openai as dl, ownedByUser as dm, policy as dn, raw as dp, sqlFragment as dq, text as dr, timestamp as ds, userRef as dt, uuid as du, vector as dv, withRetry as dw, type ColValue as dx, type DBOps as e, type RawPageOptions as f, type Page as g, type TxPlanBody as h, type CommandOptions as i, type TxPlanResponse as j, type CacheClient as k, __requestALS as l, type PalbaseResult as m, type PolicyExpr as n, type AggregateInput as o, type AggregateResult as p, type AnyColumn as q, type AtomicDatabase as r, type AtomicOptions as s, Auth as t, type AuthConfig as u, Cache as v, type ClientInfo as w, type ColRef as x, ColumnBuilder as y, type ColumnDef as z };
|