@rebasepro/types 0.9.1-canary.ff338b5 → 0.10.1-canary.a54c057
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/controllers/client.d.ts +7 -5
- package/dist/index.es.js +1 -1
- package/dist/index.es.js.map +1 -1
- package/dist/types/auth_adapter.d.ts +48 -4
- package/dist/types/backend.d.ts +48 -1
- package/dist/types/collections.d.ts +13 -8
- package/dist/types/policy.d.ts +1 -1
- package/dist/types/websockets.d.ts +43 -0
- package/package.json +1 -1
- package/src/controllers/client.ts +7 -6
- package/src/types/auth_adapter.ts +52 -4
- package/src/types/backend.ts +51 -1
- package/src/types/collections.ts +13 -8
- package/src/types/policy.ts +1 -1
- package/src/types/websockets.ts +45 -0
|
@@ -131,7 +131,7 @@ export interface AdminAPI {
|
|
|
131
131
|
limit: number;
|
|
132
132
|
offset: number;
|
|
133
133
|
}>;
|
|
134
|
-
getUser(
|
|
134
|
+
getUser(uid: string): Promise<{
|
|
135
135
|
user: AdminUser;
|
|
136
136
|
}>;
|
|
137
137
|
createUser(data: {
|
|
@@ -143,7 +143,7 @@ export interface AdminAPI {
|
|
|
143
143
|
}): Promise<{
|
|
144
144
|
user: AdminUser;
|
|
145
145
|
}>;
|
|
146
|
-
updateUser(
|
|
146
|
+
updateUser(uid: string, data: {
|
|
147
147
|
email?: string;
|
|
148
148
|
displayName?: string;
|
|
149
149
|
password?: string;
|
|
@@ -152,10 +152,10 @@ export interface AdminAPI {
|
|
|
152
152
|
}): Promise<{
|
|
153
153
|
user: AdminUser;
|
|
154
154
|
}>;
|
|
155
|
-
deleteUser(
|
|
155
|
+
deleteUser(uid: string): Promise<{
|
|
156
156
|
success: boolean;
|
|
157
157
|
}>;
|
|
158
|
-
resetPassword(
|
|
158
|
+
resetPassword(uid: string, options?: {
|
|
159
159
|
password?: string;
|
|
160
160
|
}): Promise<{
|
|
161
161
|
user: AdminUser;
|
|
@@ -391,11 +391,13 @@ export interface RebaseServerClient<DB = unknown> extends RebaseClient<DB> {
|
|
|
391
391
|
email: EmailService;
|
|
392
392
|
/**
|
|
393
393
|
* Execute raw SQL against the database. Always present server-side for SQL
|
|
394
|
-
* engines.
|
|
394
|
+
* engines. Values interpolated into the query should be passed via
|
|
395
|
+
* `params`, referenced as `$1`, `$2`, … placeholders in the query text.
|
|
395
396
|
*/
|
|
396
397
|
sql(query: string, options?: {
|
|
397
398
|
database?: string;
|
|
398
399
|
role?: string;
|
|
400
|
+
params?: unknown[];
|
|
399
401
|
}): Promise<Record<string, unknown>[]>;
|
|
400
402
|
}
|
|
401
403
|
/**
|
package/dist/index.es.js
CHANGED
|
@@ -315,7 +315,7 @@ function getDeclaredSubcollections(collection) {
|
|
|
315
315
|
/**
|
|
316
316
|
* The id a request without a logged-in user reports as `auth.uid()`.
|
|
317
317
|
*
|
|
318
|
-
* A user-context request always sets `app.
|
|
318
|
+
* A user-context request always sets `app.uid`: blank would read back as
|
|
319
319
|
* `NULL`, and `NULL` is how the trusted server context is recognised, so an
|
|
320
320
|
* anonymous visitor would be promoted to server privileges. The driver
|
|
321
321
|
* therefore substitutes this sentinel at the single chokepoint where the GUC
|