@develit-services/rbac 0.0.1
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/@types.cjs +24 -0
- package/dist/@types.d.cts +27 -0
- package/dist/@types.d.mts +27 -0
- package/dist/@types.d.ts +27 -0
- package/dist/@types.mjs +2 -0
- package/dist/database/schema.cjs +12 -0
- package/dist/database/schema.d.cts +2 -0
- package/dist/database/schema.d.mts +2 -0
- package/dist/database/schema.d.ts +2 -0
- package/dist/database/schema.mjs +3 -0
- package/dist/export/worker.cjs +776 -0
- package/dist/export/worker.d.cts +36 -0
- package/dist/export/worker.d.mts +34 -0
- package/dist/export/worker.d.ts +36 -0
- package/dist/export/worker.mjs +771 -0
- package/dist/export/wrangler.cjs +48 -0
- package/dist/export/wrangler.d.cts +33 -0
- package/dist/export/wrangler.d.mts +33 -0
- package/dist/export/wrangler.d.ts +33 -0
- package/dist/export/wrangler.mjs +46 -0
- package/dist/shared/rbac.2EhZ2epo.cjs +363 -0
- package/dist/shared/rbac.BmuK3PNh.d.cts +499 -0
- package/dist/shared/rbac.BmuK3PNh.d.mts +499 -0
- package/dist/shared/rbac.BmuK3PNh.d.ts +499 -0
- package/dist/shared/rbac.C9brkvW9.mjs +344 -0
- package/dist/shared/rbac.CHxy3VJb.d.ts +1034 -0
- package/dist/shared/rbac.CJLU5iuV.mjs +45 -0
- package/dist/shared/rbac.CaoDccv4.d.cts +1034 -0
- package/dist/shared/rbac.ClMKyW8J.d.cts +20 -0
- package/dist/shared/rbac.ClMKyW8J.d.mts +20 -0
- package/dist/shared/rbac.ClMKyW8J.d.ts +20 -0
- package/dist/shared/rbac.Cra1T2nC.cjs +51 -0
- package/dist/shared/rbac.DH5084jg.d.mts +1034 -0
- package/package.json +59 -0
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import * as _develit_io_backend_sdk from '@develit-io/backend-sdk';
|
|
2
|
+
import { IRPCResponse } from '@develit-io/backend-sdk';
|
|
3
|
+
import { WorkerEntrypoint } from 'cloudflare:workers';
|
|
4
|
+
import { t as tables, C as CreateRoleInput, a as CreateRoleOutput, A as AssignRoleToUserInput, b as AssignRoleToUserOutput, c as AssignRolesToUserInput, d as AssignRolesToUserOutput, R as RevokeRoleFromUserInput, e as RevokeRoleFromUserOutput, G as GrantScopeToUserInput, f as GrantScopeToUserOutput, g as GrantScopesToUserInput, h as GrantScopesToUserOutput, i as RevokeScopeFromUserInput, j as RevokeScopeFromUserOutput, k as GrantScopeToRoleInput, l as GrantScopeToRoleOutput, m as RevokeScopeFromRoleInput, n as RevokeScopeFromRoleOutput, o as GetPermissionsOutput, p as GetUserPermissionsInput, q as GetUserPermissionsOutput, V as VerifyAccessInput, r as VerifyAccessOutput, D as DeleteRoleInput, s as DeleteRoleOutput, U as UpdateRoleInput, u as UpdateRoleOutput } from '../shared/rbac.CaoDccv4.cjs';
|
|
5
|
+
import { DrizzleD1Database } from 'drizzle-orm/d1';
|
|
6
|
+
import 'zod';
|
|
7
|
+
import 'drizzle-orm';
|
|
8
|
+
import '../shared/rbac.BmuK3PNh.cjs';
|
|
9
|
+
import 'drizzle-orm/sqlite-core';
|
|
10
|
+
|
|
11
|
+
declare const RbacServiceBase_base: (abstract new (ctx: ExecutionContext, env: RbacEnv) => WorkerEntrypoint<RbacEnv, {}>) & (abstract new (...args: any[]) => _develit_io_backend_sdk.DevelitWorkerMethods);
|
|
12
|
+
declare class RbacServiceBase extends RbacServiceBase_base {
|
|
13
|
+
readonly db: DrizzleD1Database<typeof tables>;
|
|
14
|
+
constructor(ctx: ExecutionContext, env: RbacEnv);
|
|
15
|
+
createRole(input: CreateRoleInput): Promise<IRPCResponse<CreateRoleOutput>>;
|
|
16
|
+
assignRoleToUser(input: AssignRoleToUserInput): Promise<IRPCResponse<AssignRoleToUserOutput>>;
|
|
17
|
+
assignRolesToUser(input: AssignRolesToUserInput): Promise<IRPCResponse<AssignRolesToUserOutput>>;
|
|
18
|
+
revokeRoleFromUser(input: RevokeRoleFromUserInput): Promise<IRPCResponse<RevokeRoleFromUserOutput>>;
|
|
19
|
+
grantScopeToUser(input: GrantScopeToUserInput): Promise<IRPCResponse<GrantScopeToUserOutput>>;
|
|
20
|
+
grantScopesToUser(input: GrantScopesToUserInput): Promise<IRPCResponse<GrantScopesToUserOutput>>;
|
|
21
|
+
revokeScopeFromUser(input: RevokeScopeFromUserInput): Promise<IRPCResponse<RevokeScopeFromUserOutput>>;
|
|
22
|
+
grantScopeToRole(input: GrantScopeToRoleInput): Promise<IRPCResponse<GrantScopeToRoleOutput>>;
|
|
23
|
+
revokeScopeFromRole(input: RevokeScopeFromRoleInput): Promise<IRPCResponse<RevokeScopeFromRoleOutput>>;
|
|
24
|
+
getPermissions(): Promise<IRPCResponse<GetPermissionsOutput>>;
|
|
25
|
+
getUserPermissions(input: GetUserPermissionsInput): Promise<IRPCResponse<GetUserPermissionsOutput>>;
|
|
26
|
+
verifyAccess(input: VerifyAccessInput): Promise<IRPCResponse<VerifyAccessOutput>>;
|
|
27
|
+
deleteRole(input: DeleteRoleInput): Promise<IRPCResponse<DeleteRoleOutput>>;
|
|
28
|
+
updateRole(input: UpdateRoleInput): Promise<IRPCResponse<UpdateRoleOutput>>;
|
|
29
|
+
}
|
|
30
|
+
declare function defineRbacService(): new (ctx: ExecutionContext, env: RbacEnv) => RbacServiceBase;
|
|
31
|
+
|
|
32
|
+
declare const _default: new (ctx: ExecutionContext, env: RbacEnv) => WorkerEntrypoint<RbacEnv>;
|
|
33
|
+
|
|
34
|
+
// @ts-ignore
|
|
35
|
+
export = _default;
|
|
36
|
+
export { defineRbacService };
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import * as _develit_io_backend_sdk from '@develit-io/backend-sdk';
|
|
2
|
+
import { IRPCResponse } from '@develit-io/backend-sdk';
|
|
3
|
+
import { WorkerEntrypoint } from 'cloudflare:workers';
|
|
4
|
+
import { t as tables, C as CreateRoleInput, a as CreateRoleOutput, A as AssignRoleToUserInput, b as AssignRoleToUserOutput, c as AssignRolesToUserInput, d as AssignRolesToUserOutput, R as RevokeRoleFromUserInput, e as RevokeRoleFromUserOutput, G as GrantScopeToUserInput, f as GrantScopeToUserOutput, g as GrantScopesToUserInput, h as GrantScopesToUserOutput, i as RevokeScopeFromUserInput, j as RevokeScopeFromUserOutput, k as GrantScopeToRoleInput, l as GrantScopeToRoleOutput, m as RevokeScopeFromRoleInput, n as RevokeScopeFromRoleOutput, o as GetPermissionsOutput, p as GetUserPermissionsInput, q as GetUserPermissionsOutput, V as VerifyAccessInput, r as VerifyAccessOutput, D as DeleteRoleInput, s as DeleteRoleOutput, U as UpdateRoleInput, u as UpdateRoleOutput } from '../shared/rbac.DH5084jg.mjs';
|
|
5
|
+
import { DrizzleD1Database } from 'drizzle-orm/d1';
|
|
6
|
+
import 'zod';
|
|
7
|
+
import 'drizzle-orm';
|
|
8
|
+
import '../shared/rbac.BmuK3PNh.mjs';
|
|
9
|
+
import 'drizzle-orm/sqlite-core';
|
|
10
|
+
|
|
11
|
+
declare const RbacServiceBase_base: (abstract new (ctx: ExecutionContext, env: RbacEnv) => WorkerEntrypoint<RbacEnv, {}>) & (abstract new (...args: any[]) => _develit_io_backend_sdk.DevelitWorkerMethods);
|
|
12
|
+
declare class RbacServiceBase extends RbacServiceBase_base {
|
|
13
|
+
readonly db: DrizzleD1Database<typeof tables>;
|
|
14
|
+
constructor(ctx: ExecutionContext, env: RbacEnv);
|
|
15
|
+
createRole(input: CreateRoleInput): Promise<IRPCResponse<CreateRoleOutput>>;
|
|
16
|
+
assignRoleToUser(input: AssignRoleToUserInput): Promise<IRPCResponse<AssignRoleToUserOutput>>;
|
|
17
|
+
assignRolesToUser(input: AssignRolesToUserInput): Promise<IRPCResponse<AssignRolesToUserOutput>>;
|
|
18
|
+
revokeRoleFromUser(input: RevokeRoleFromUserInput): Promise<IRPCResponse<RevokeRoleFromUserOutput>>;
|
|
19
|
+
grantScopeToUser(input: GrantScopeToUserInput): Promise<IRPCResponse<GrantScopeToUserOutput>>;
|
|
20
|
+
grantScopesToUser(input: GrantScopesToUserInput): Promise<IRPCResponse<GrantScopesToUserOutput>>;
|
|
21
|
+
revokeScopeFromUser(input: RevokeScopeFromUserInput): Promise<IRPCResponse<RevokeScopeFromUserOutput>>;
|
|
22
|
+
grantScopeToRole(input: GrantScopeToRoleInput): Promise<IRPCResponse<GrantScopeToRoleOutput>>;
|
|
23
|
+
revokeScopeFromRole(input: RevokeScopeFromRoleInput): Promise<IRPCResponse<RevokeScopeFromRoleOutput>>;
|
|
24
|
+
getPermissions(): Promise<IRPCResponse<GetPermissionsOutput>>;
|
|
25
|
+
getUserPermissions(input: GetUserPermissionsInput): Promise<IRPCResponse<GetUserPermissionsOutput>>;
|
|
26
|
+
verifyAccess(input: VerifyAccessInput): Promise<IRPCResponse<VerifyAccessOutput>>;
|
|
27
|
+
deleteRole(input: DeleteRoleInput): Promise<IRPCResponse<DeleteRoleOutput>>;
|
|
28
|
+
updateRole(input: UpdateRoleInput): Promise<IRPCResponse<UpdateRoleOutput>>;
|
|
29
|
+
}
|
|
30
|
+
declare function defineRbacService(): new (ctx: ExecutionContext, env: RbacEnv) => RbacServiceBase;
|
|
31
|
+
|
|
32
|
+
declare const _default: new (ctx: ExecutionContext, env: RbacEnv) => WorkerEntrypoint<RbacEnv>;
|
|
33
|
+
|
|
34
|
+
export { _default as default, defineRbacService };
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import * as _develit_io_backend_sdk from '@develit-io/backend-sdk';
|
|
2
|
+
import { IRPCResponse } from '@develit-io/backend-sdk';
|
|
3
|
+
import { WorkerEntrypoint } from 'cloudflare:workers';
|
|
4
|
+
import { t as tables, C as CreateRoleInput, a as CreateRoleOutput, A as AssignRoleToUserInput, b as AssignRoleToUserOutput, c as AssignRolesToUserInput, d as AssignRolesToUserOutput, R as RevokeRoleFromUserInput, e as RevokeRoleFromUserOutput, G as GrantScopeToUserInput, f as GrantScopeToUserOutput, g as GrantScopesToUserInput, h as GrantScopesToUserOutput, i as RevokeScopeFromUserInput, j as RevokeScopeFromUserOutput, k as GrantScopeToRoleInput, l as GrantScopeToRoleOutput, m as RevokeScopeFromRoleInput, n as RevokeScopeFromRoleOutput, o as GetPermissionsOutput, p as GetUserPermissionsInput, q as GetUserPermissionsOutput, V as VerifyAccessInput, r as VerifyAccessOutput, D as DeleteRoleInput, s as DeleteRoleOutput, U as UpdateRoleInput, u as UpdateRoleOutput } from '../shared/rbac.CHxy3VJb.js';
|
|
5
|
+
import { DrizzleD1Database } from 'drizzle-orm/d1';
|
|
6
|
+
import 'zod';
|
|
7
|
+
import 'drizzle-orm';
|
|
8
|
+
import '../shared/rbac.BmuK3PNh.js';
|
|
9
|
+
import 'drizzle-orm/sqlite-core';
|
|
10
|
+
|
|
11
|
+
declare const RbacServiceBase_base: (abstract new (ctx: ExecutionContext, env: RbacEnv) => WorkerEntrypoint<RbacEnv, {}>) & (abstract new (...args: any[]) => _develit_io_backend_sdk.DevelitWorkerMethods);
|
|
12
|
+
declare class RbacServiceBase extends RbacServiceBase_base {
|
|
13
|
+
readonly db: DrizzleD1Database<typeof tables>;
|
|
14
|
+
constructor(ctx: ExecutionContext, env: RbacEnv);
|
|
15
|
+
createRole(input: CreateRoleInput): Promise<IRPCResponse<CreateRoleOutput>>;
|
|
16
|
+
assignRoleToUser(input: AssignRoleToUserInput): Promise<IRPCResponse<AssignRoleToUserOutput>>;
|
|
17
|
+
assignRolesToUser(input: AssignRolesToUserInput): Promise<IRPCResponse<AssignRolesToUserOutput>>;
|
|
18
|
+
revokeRoleFromUser(input: RevokeRoleFromUserInput): Promise<IRPCResponse<RevokeRoleFromUserOutput>>;
|
|
19
|
+
grantScopeToUser(input: GrantScopeToUserInput): Promise<IRPCResponse<GrantScopeToUserOutput>>;
|
|
20
|
+
grantScopesToUser(input: GrantScopesToUserInput): Promise<IRPCResponse<GrantScopesToUserOutput>>;
|
|
21
|
+
revokeScopeFromUser(input: RevokeScopeFromUserInput): Promise<IRPCResponse<RevokeScopeFromUserOutput>>;
|
|
22
|
+
grantScopeToRole(input: GrantScopeToRoleInput): Promise<IRPCResponse<GrantScopeToRoleOutput>>;
|
|
23
|
+
revokeScopeFromRole(input: RevokeScopeFromRoleInput): Promise<IRPCResponse<RevokeScopeFromRoleOutput>>;
|
|
24
|
+
getPermissions(): Promise<IRPCResponse<GetPermissionsOutput>>;
|
|
25
|
+
getUserPermissions(input: GetUserPermissionsInput): Promise<IRPCResponse<GetUserPermissionsOutput>>;
|
|
26
|
+
verifyAccess(input: VerifyAccessInput): Promise<IRPCResponse<VerifyAccessOutput>>;
|
|
27
|
+
deleteRole(input: DeleteRoleInput): Promise<IRPCResponse<DeleteRoleOutput>>;
|
|
28
|
+
updateRole(input: UpdateRoleInput): Promise<IRPCResponse<UpdateRoleOutput>>;
|
|
29
|
+
}
|
|
30
|
+
declare function defineRbacService(): new (ctx: ExecutionContext, env: RbacEnv) => RbacServiceBase;
|
|
31
|
+
|
|
32
|
+
declare const _default: new (ctx: ExecutionContext, env: RbacEnv) => WorkerEntrypoint<RbacEnv>;
|
|
33
|
+
|
|
34
|
+
// @ts-ignore
|
|
35
|
+
export = _default;
|
|
36
|
+
export { defineRbacService };
|