@rebasepro/types 0.12.1-canary.g4e7bcbf → 0.12.1-canary.g52d71ee
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 -12
- package/dist/index.es.js.map +1 -1
- package/dist/types/project_manifest.d.ts +15 -0
- package/dist/types/relations.d.ts +51 -0
- package/dist/users/user.d.ts +2 -2
- package/package.json +1 -1
- package/src/controllers/client.ts +7 -13
- package/src/types/project_manifest.ts +15 -0
- package/src/types/relations.ts +51 -0
- package/src/users/user.ts +2 -2
|
@@ -390,19 +390,14 @@ export interface RebaseClient<DB = unknown> {
|
|
|
390
390
|
* the admin-scoped {@link dataAsAdmin} accessor, raw {@link sql}, and the
|
|
391
391
|
* {@link email} service are all present (non-optional).
|
|
392
392
|
*
|
|
393
|
-
* **Trust levels.**
|
|
394
|
-
*
|
|
395
|
-
*
|
|
396
|
-
*
|
|
397
|
-
* (`c.var.driver`)
|
|
393
|
+
* **Trust levels.** {@link dataAsAdmin} is the admin-scoped, **RLS-bypassing**
|
|
394
|
+
* driver, and it is the only name for it here — the `data` alias that used to
|
|
395
|
+
* sit beside it is deliberately `Omit`ted from {@link RebaseClient} so the
|
|
396
|
+
* privilege has to be spelled out at every call site. For user-scoped queries
|
|
397
|
+
* inside a request handler use the request-scoped driver (`c.var.driver`)
|
|
398
|
+
* instead — never `dataAsAdmin`.
|
|
398
399
|
*/
|
|
399
|
-
export interface RebaseServerClient<DB = unknown> extends RebaseClient<DB> {
|
|
400
|
-
/**
|
|
401
|
-
* @deprecated On the server, prefer {@link dataAsAdmin} for admin scope or
|
|
402
|
-
* the request-scoped driver (`c.var.driver`) for user scope. This alias
|
|
403
|
-
* points at the same admin-scoped, RLS-bypassing accessor as `dataAsAdmin`.
|
|
404
|
-
*/
|
|
405
|
-
data: RebaseSdkData<DB>;
|
|
400
|
+
export interface RebaseServerClient<DB = unknown> extends Omit<RebaseClient<DB>, "data"> {
|
|
406
401
|
/**
|
|
407
402
|
* Admin-scoped, **RLS-bypassing** data accessor. Always present server-side.
|
|
408
403
|
* See {@link RebaseClient.dataAsAdmin} for the full safety contract.
|