@nest-boot/auth 8.1.0 → 8.2.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/README.md +247 -142
- package/dist/admin/admin.providers.d.ts +3 -0
- package/dist/admin/admin.providers.js +17 -0
- package/dist/admin/admin.providers.js.map +1 -0
- package/dist/admin/connections/system-account.connection-definition.d.ts +9 -0
- package/dist/admin/connections/system-account.connection-definition.js +41 -0
- package/dist/admin/connections/system-account.connection-definition.js.map +1 -0
- package/dist/admin/enums/system-account-permission.enum.d.ts +4 -0
- package/dist/admin/enums/system-account-permission.enum.js +7 -0
- package/dist/admin/enums/system-account-permission.enum.js.map +1 -0
- package/dist/admin/inputs/ban-user.input.js.map +1 -0
- package/dist/admin/inputs/create-system-account.input.d.ts +8 -0
- package/dist/admin/inputs/create-system-account.input.js +34 -0
- package/dist/admin/inputs/create-system-account.input.js.map +1 -0
- package/dist/admin/inputs/create-user.input.d.ts +15 -0
- package/dist/admin/inputs/create-user.input.js +56 -0
- package/dist/admin/inputs/create-user.input.js.map +1 -0
- package/dist/admin/inputs/set-user-password.input.js.map +1 -0
- package/dist/admin/inputs/set-user-permissions.input.d.ts +6 -0
- package/dist/admin/inputs/set-user-permissions.input.js +27 -0
- package/dist/admin/inputs/set-user-permissions.input.js.map +1 -0
- package/dist/admin/inputs/set-user-roles.input.d.ts +6 -0
- package/dist/admin/inputs/set-user-roles.input.js +27 -0
- package/dist/admin/inputs/set-user-roles.input.js.map +1 -0
- package/dist/admin/inputs/update-system-account.input.d.ts +10 -0
- package/dist/admin/inputs/update-system-account.input.js +41 -0
- package/dist/admin/inputs/update-system-account.input.js.map +1 -0
- package/dist/admin/inputs/update-user.input.js.map +1 -0
- package/dist/admin/inputs/user-id.input.js.map +1 -0
- package/dist/admin/interfaces/auth-module-admin-options.interface.d.ts +5 -0
- package/dist/admin/interfaces/auth-module-admin-options.interface.js +2 -0
- package/dist/admin/interfaces/auth-module-admin-options.interface.js.map +1 -0
- package/dist/admin/interfaces/ban-user-options.interface.js.map +1 -0
- package/dist/admin/interfaces/create-user-options.interface.js.map +1 -0
- package/dist/admin/interfaces/impersonation-options.interface.js.map +1 -0
- package/dist/admin/interfaces/update-user-options.interface.js.map +1 -0
- package/dist/admin/objects/ban-user-payload.object.js.map +1 -0
- package/dist/admin/objects/create-user-payload.object.js.map +1 -0
- package/dist/admin/objects/delete-user-payload.object.js.map +1 -0
- package/dist/admin/objects/set-user-permissions-payload.object.js.map +1 -0
- package/dist/admin/objects/set-user-roles-payload.object.js.map +1 -0
- package/dist/admin/objects/system-account-permission-option.object.d.ts +10 -0
- package/dist/admin/objects/system-account-permission-option.object.js +37 -0
- package/dist/admin/objects/system-account-permission-option.object.js.map +1 -0
- package/dist/admin/objects/unban-user-payload.object.js.map +1 -0
- package/dist/admin/objects/update-user-payload.object.js.map +1 -0
- package/dist/admin/objects/user-permission-option.object.d.ts +8 -0
- package/dist/admin/objects/user-permission-option.object.js +31 -0
- package/dist/admin/objects/user-permission-option.object.js.map +1 -0
- package/dist/admin/objects/user-role-option.object.d.ts +8 -0
- package/dist/admin/objects/user-role-option.object.js +31 -0
- package/dist/admin/objects/user-role-option.object.js.map +1 -0
- package/dist/admin/resolvers/admin-session.resolver.d.ts +38 -0
- package/dist/admin/resolvers/admin-session.resolver.js +99 -0
- package/dist/admin/resolvers/admin-session.resolver.js.map +1 -0
- package/dist/admin/resolvers/admin-user.resolver.d.ts +104 -0
- package/dist/admin/resolvers/admin-user.resolver.js +247 -0
- package/dist/admin/resolvers/admin-user.resolver.js.map +1 -0
- package/dist/admin/resolvers/system-account.resolver.d.ts +60 -0
- package/dist/admin/resolvers/system-account.resolver.js +145 -0
- package/dist/admin/resolvers/system-account.resolver.js.map +1 -0
- package/dist/admin/services/system-account.service.d.ts +62 -0
- package/dist/admin/services/system-account.service.js +177 -0
- package/dist/admin/services/system-account.service.js.map +1 -0
- package/dist/admin/utils/assert-system-account-administrator.util.d.ts +8 -0
- package/dist/admin/utils/assert-system-account-administrator.util.js +27 -0
- package/dist/admin/utils/assert-system-account-administrator.util.js.map +1 -0
- package/dist/api-key/api-key.providers.d.ts +3 -0
- package/dist/api-key/api-key.providers.js +30 -0
- package/dist/api-key/api-key.providers.js.map +1 -0
- package/dist/api-key/connections/create-api-key-connection.d.ts +14 -0
- package/dist/api-key/connections/create-api-key-connection.js +91 -0
- package/dist/api-key/connections/create-api-key-connection.js.map +1 -0
- package/dist/api-key/connections/system-api-key.connection-definition.d.ts +12 -0
- package/dist/api-key/connections/system-api-key.connection-definition.js +29 -0
- package/dist/api-key/connections/system-api-key.connection-definition.js.map +1 -0
- package/dist/api-key/connections/user-api-key.connection-definition.d.ts +12 -0
- package/dist/api-key/connections/user-api-key.connection-definition.js +29 -0
- package/dist/api-key/connections/user-api-key.connection-definition.js.map +1 -0
- package/dist/api-key/connections/workspace-api-key.connection-definition.d.ts +12 -0
- package/dist/api-key/connections/workspace-api-key.connection-definition.js +29 -0
- package/dist/api-key/connections/workspace-api-key.connection-definition.js.map +1 -0
- package/dist/api-key/constants/system-account.constants.d.ts +2 -0
- package/dist/api-key/constants/system-account.constants.js +10 -0
- package/dist/api-key/constants/system-account.constants.js.map +1 -0
- package/dist/api-key/decorators/current-api-key.decorator.js.map +1 -0
- package/dist/api-key/entities/api-key.entity-schema.d.ts +19 -0
- package/dist/api-key/entities/api-key.entity-schema.js +85 -0
- package/dist/api-key/entities/api-key.entity-schema.js.map +1 -0
- package/dist/api-key/entities/api-key.entity.d.ts +88 -0
- package/dist/api-key/entities/api-key.entity.js +121 -0
- package/dist/api-key/entities/api-key.entity.js.map +1 -0
- package/dist/api-key/entities/system-account.entity.d.ts +24 -0
- package/dist/api-key/entities/system-account.entity.js +101 -0
- package/dist/api-key/entities/system-account.entity.js.map +1 -0
- package/dist/api-key/enums/system-api-key-permission.enum.d.ts +3 -0
- package/dist/api-key/enums/system-api-key-permission.enum.js +6 -0
- package/dist/api-key/enums/system-api-key-permission.enum.js.map +1 -0
- package/dist/api-key/enums/user-api-key-permission.enum.js +11 -0
- package/dist/api-key/enums/user-api-key-permission.enum.js.map +1 -0
- package/dist/api-key/enums/workspace-api-key-permission.enum.d.ts +4 -0
- package/dist/api-key/enums/workspace-api-key-permission.enum.js +11 -0
- package/dist/api-key/enums/workspace-api-key-permission.enum.js.map +1 -0
- package/dist/api-key/inputs/create-system-api-key.input.d.ts +16 -0
- package/dist/api-key/inputs/create-system-api-key.input.js +62 -0
- package/dist/api-key/inputs/create-system-api-key.input.js.map +1 -0
- package/dist/api-key/inputs/create-user-api-key.input.js.map +1 -0
- package/dist/api-key/inputs/create-workspace-api-key.input.d.ts +16 -0
- package/dist/api-key/inputs/create-workspace-api-key.input.js +62 -0
- package/dist/api-key/inputs/create-workspace-api-key.input.js.map +1 -0
- package/dist/api-key/inputs/update-system-api-key.input.d.ts +12 -0
- package/dist/api-key/inputs/update-system-api-key.input.js +43 -0
- package/dist/api-key/inputs/update-system-api-key.input.js.map +1 -0
- package/dist/api-key/inputs/update-user-api-key.input.d.ts +12 -0
- package/dist/api-key/inputs/update-user-api-key.input.js +43 -0
- package/dist/api-key/inputs/update-user-api-key.input.js.map +1 -0
- package/dist/api-key/inputs/update-workspace-api-key.input.d.ts +12 -0
- package/dist/api-key/inputs/update-workspace-api-key.input.js +43 -0
- package/dist/api-key/inputs/update-workspace-api-key.input.js.map +1 -0
- package/dist/api-key/interceptors/api-key-usage.interceptor.d.ts +19 -0
- package/dist/api-key/interceptors/api-key-usage.interceptor.js +46 -0
- package/dist/api-key/interceptors/api-key-usage.interceptor.js.map +1 -0
- package/dist/api-key/interfaces/auth-module-api-key-options.interface.d.ts +13 -0
- package/dist/api-key/interfaces/auth-module-api-key-options.interface.js.map +1 -0
- package/dist/api-key/interfaces/auth-module-api-key-scope-options.interface.d.ts +11 -0
- package/dist/api-key/interfaces/auth-module-api-key-scope-options.interface.js.map +1 -0
- package/dist/api-key/interfaces/create-api-key-options.interface.js.map +1 -0
- package/dist/api-key/interfaces/create-system-api-key-options.interface.d.ts +6 -0
- package/dist/api-key/interfaces/create-system-api-key-options.interface.js +2 -0
- package/dist/api-key/interfaces/create-system-api-key-options.interface.js.map +1 -0
- package/dist/api-key/interfaces/create-workspace-api-key-options.interface.d.ts +7 -0
- package/dist/api-key/interfaces/create-workspace-api-key-options.interface.js +2 -0
- package/dist/api-key/interfaces/create-workspace-api-key-options.interface.js.map +1 -0
- package/dist/api-key/interfaces/created-api-key.interface.d.ts +8 -0
- package/dist/api-key/interfaces/created-api-key.interface.js.map +1 -0
- package/dist/api-key/interfaces/system-api-key-validation.interface.d.ts +8 -0
- package/dist/api-key/interfaces/system-api-key-validation.interface.js +2 -0
- package/dist/api-key/interfaces/system-api-key-validation.interface.js.map +1 -0
- package/dist/api-key/interfaces/update-api-key-options.interface.d.ts +12 -0
- package/dist/api-key/interfaces/update-api-key-options.interface.js.map +1 -0
- package/dist/api-key/interfaces/user-api-key-validation.interface.d.ts +11 -0
- package/dist/api-key/interfaces/user-api-key-validation.interface.js.map +1 -0
- package/dist/api-key/interfaces/workspace-api-key-validation.interface.d.ts +17 -0
- package/dist/api-key/interfaces/workspace-api-key-validation.interface.js +2 -0
- package/dist/api-key/interfaces/workspace-api-key-validation.interface.js.map +1 -0
- package/dist/api-key/objects/api-key.object.d.ts +76 -0
- package/dist/api-key/objects/api-key.object.js +162 -0
- package/dist/api-key/objects/api-key.object.js.map +1 -0
- package/dist/api-key/objects/create-system-api-key-result.object.d.ts +6 -0
- package/dist/api-key/objects/create-system-api-key-result.object.js +29 -0
- package/dist/api-key/objects/create-system-api-key-result.object.js.map +1 -0
- package/dist/api-key/objects/create-user-api-key-result.object.d.ts +6 -0
- package/dist/api-key/objects/create-user-api-key-result.object.js +29 -0
- package/dist/api-key/objects/create-user-api-key-result.object.js.map +1 -0
- package/dist/api-key/objects/create-workspace-api-key-result.object.d.ts +6 -0
- package/dist/api-key/objects/create-workspace-api-key-result.object.js +29 -0
- package/dist/api-key/objects/create-workspace-api-key-result.object.js.map +1 -0
- package/dist/api-key/objects/system-api-key-permission-option.object.d.ts +10 -0
- package/dist/api-key/objects/system-api-key-permission-option.object.js +37 -0
- package/dist/api-key/objects/system-api-key-permission-option.object.js.map +1 -0
- package/dist/api-key/objects/system-api-key.object.d.ts +20 -0
- package/dist/api-key/objects/system-api-key.object.js +42 -0
- package/dist/api-key/objects/system-api-key.object.js.map +1 -0
- package/dist/api-key/objects/user-api-key-permission-option.object.js.map +1 -0
- package/dist/api-key/objects/user-api-key.object.d.ts +21 -0
- package/dist/api-key/objects/user-api-key.object.js +45 -0
- package/dist/api-key/objects/user-api-key.object.js.map +1 -0
- package/dist/api-key/objects/workspace-api-key-permission-option.object.d.ts +10 -0
- package/dist/api-key/objects/workspace-api-key-permission-option.object.js +37 -0
- package/dist/api-key/objects/workspace-api-key-permission-option.object.js.map +1 -0
- package/dist/api-key/objects/workspace-api-key.object.d.ts +21 -0
- package/dist/api-key/objects/workspace-api-key.object.js +45 -0
- package/dist/api-key/objects/workspace-api-key.object.js.map +1 -0
- package/dist/api-key/policies/api-key-owner.policy.d.ts +8 -0
- package/dist/api-key/policies/api-key-owner.policy.js +19 -0
- package/dist/api-key/policies/api-key-owner.policy.js.map +1 -0
- package/dist/api-key/resolvers/system-api-key-relation.resolver.d.ts +16 -0
- package/dist/api-key/resolvers/system-api-key-relation.resolver.js +57 -0
- package/dist/api-key/resolvers/system-api-key-relation.resolver.js.map +1 -0
- package/dist/api-key/resolvers/system-api-key.resolver.d.ts +77 -0
- package/dist/api-key/resolvers/system-api-key.resolver.js +183 -0
- package/dist/api-key/resolvers/system-api-key.resolver.js.map +1 -0
- package/dist/api-key/resolvers/user-api-key-relation.resolver.d.ts +16 -0
- package/dist/api-key/resolvers/user-api-key-relation.resolver.js +57 -0
- package/dist/api-key/resolvers/user-api-key-relation.resolver.js.map +1 -0
- package/dist/api-key/resolvers/user-api-key.resolver.d.ts +69 -0
- package/dist/api-key/resolvers/user-api-key.resolver.js +157 -0
- package/dist/api-key/resolvers/user-api-key.resolver.js.map +1 -0
- package/dist/api-key/resolvers/workspace-api-key-connection.resolver.d.ts +30 -0
- package/dist/api-key/resolvers/workspace-api-key-connection.resolver.js +71 -0
- package/dist/api-key/resolvers/workspace-api-key-connection.resolver.js.map +1 -0
- package/dist/api-key/resolvers/workspace-api-key-relation.resolver.d.ts +16 -0
- package/dist/api-key/resolvers/workspace-api-key-relation.resolver.js +57 -0
- package/dist/api-key/resolvers/workspace-api-key-relation.resolver.js.map +1 -0
- package/dist/api-key/resolvers/workspace-api-key.resolver.d.ts +63 -0
- package/dist/api-key/resolvers/workspace-api-key.resolver.js +146 -0
- package/dist/api-key/resolvers/workspace-api-key.resolver.js.map +1 -0
- package/dist/api-key/services/api-key-authentication.service.d.ts +33 -0
- package/dist/api-key/services/api-key-authentication.service.js +164 -0
- package/dist/api-key/services/api-key-authentication.service.js.map +1 -0
- package/dist/api-key/services/api-key.service.d.ts +67 -0
- package/dist/api-key/services/api-key.service.js +195 -0
- package/dist/api-key/services/api-key.service.js.map +1 -0
- package/dist/api-key/services/system-api-key.service.d.ts +67 -0
- package/dist/api-key/services/system-api-key.service.js +266 -0
- package/dist/api-key/services/system-api-key.service.js.map +1 -0
- package/dist/api-key/services/user-api-key.service.d.ts +83 -0
- package/dist/api-key/services/user-api-key.service.js +263 -0
- package/dist/api-key/services/user-api-key.service.js.map +1 -0
- package/dist/api-key/services/workspace-api-key.service.d.ts +90 -0
- package/dist/api-key/services/workspace-api-key.service.js +331 -0
- package/dist/api-key/services/workspace-api-key.service.js.map +1 -0
- package/dist/api-key/types/api-key-validation.type.d.ts +5 -0
- package/dist/api-key/types/api-key-validation.type.js.map +1 -0
- package/dist/api-key/utils/api-key-credential.util.js.map +1 -0
- package/dist/api-key/utils/api-key-permissions.util.d.ts +21 -0
- package/dist/api-key/utils/api-key-permissions.util.js +63 -0
- package/dist/api-key/utils/api-key-permissions.util.js.map +1 -0
- package/dist/api-key/utils/api-key-view.util.d.ts +27 -0
- package/dist/api-key/utils/api-key-view.util.js +22 -0
- package/dist/api-key/utils/api-key-view.util.js.map +1 -0
- package/dist/api-key/utils/assert-api-key-feature.util.d.ts +7 -0
- package/dist/api-key/utils/assert-api-key-feature.util.js +13 -0
- package/dist/api-key/utils/assert-api-key-feature.util.js.map +1 -0
- package/dist/api-key/utils/assert-api-key-owner.util.d.ts +8 -0
- package/dist/api-key/utils/assert-api-key-owner.util.js +12 -0
- package/dist/api-key/utils/assert-api-key-owner.util.js.map +1 -0
- package/dist/api-key/utils/extract-api-key.util.js.map +1 -0
- package/dist/api-key/utils/get-current-api-key.util.d.ts +7 -0
- package/dist/api-key/utils/get-current-api-key.util.js +13 -0
- package/dist/api-key/utils/get-current-api-key.util.js.map +1 -0
- package/dist/api-key/utils/is-current-api-key.util.d.ts +7 -0
- package/dist/api-key/utils/is-current-api-key.util.js +13 -0
- package/dist/api-key/utils/is-current-api-key.util.js.map +1 -0
- package/dist/api-key/utils/resolve-api-key-relation.util.d.ts +14 -0
- package/dist/api-key/utils/resolve-api-key-relation.util.js +35 -0
- package/dist/api-key/utils/resolve-api-key-relation.util.js.map +1 -0
- package/dist/common/auth.ability.d.ts +23 -0
- package/dist/common/auth.ability.js +46 -0
- package/dist/common/auth.ability.js.map +1 -0
- package/dist/common/constants/permission.constants.js.map +1 -0
- package/dist/common/decorators/can.decorator.d.ts +11 -0
- package/dist/common/decorators/can.decorator.js +16 -0
- package/dist/common/decorators/can.decorator.js.map +1 -0
- package/dist/common/decorators/public.decorator.d.ts +7 -0
- package/dist/common/decorators/public.decorator.js +9 -0
- package/dist/common/decorators/public.decorator.js.map +1 -0
- package/dist/common/feature-provider.d.ts +15 -0
- package/dist/common/feature-provider.js +19 -0
- package/dist/common/feature-provider.js.map +1 -0
- package/dist/common/interfaces/ability-context.interface.d.ts +19 -0
- package/dist/common/interfaces/ability-context.interface.js.map +1 -0
- package/dist/common/interfaces/ability-rules.interface.js.map +1 -0
- package/dist/common/interfaces/can-metadata.interface.d.ts +9 -0
- package/dist/common/interfaces/can-metadata.interface.js.map +1 -0
- package/dist/common/interfaces/request-permissions.interface.js.map +1 -0
- package/dist/common/interfaces/route-argument-metadata-value.interface.js.map +1 -0
- package/dist/common/interfaces/scope-policy-options.interface.js.map +1 -0
- package/dist/common/interfaces/serialized-ability-rule.interface.js.map +1 -0
- package/dist/common/policies/create-scope-policy.js.map +1 -0
- package/dist/common/policies/index.js.map +1 -0
- package/dist/common/policies/user-scope.policy.js.map +1 -0
- package/dist/common/policies/workspace-scope.policy.js.map +1 -0
- package/dist/common/utils/append-metadata.util.js.map +1 -0
- package/dist/common/utils/authorize.util.js.map +1 -0
- package/dist/common/utils/can.util.js.map +1 -0
- package/dist/common/utils/create-permission-enum.util.js.map +1 -0
- package/dist/common/utils/extend-ability.util.js +112 -0
- package/dist/common/utils/extend-ability.util.js.map +1 -0
- package/dist/common/utils/filter-permission-values.util.d.ts +7 -0
- package/dist/common/utils/filter-permission-values.util.js +11 -0
- package/dist/common/utils/filter-permission-values.util.js.map +1 -0
- package/dist/common/utils/get-auth-ability.util.js +22 -0
- package/dist/common/utils/get-auth-ability.util.js.map +1 -0
- package/dist/common/utils/omit-credentials.util.js +17 -0
- package/dist/common/utils/omit-credentials.util.js.map +1 -0
- package/dist/common/utils/permission-grants.util.d.ts +33 -0
- package/dist/common/utils/permission-grants.util.js +54 -0
- package/dist/common/utils/permission-grants.util.js.map +1 -0
- package/dist/common/utils/resolve-auth-catalog.util.d.ts +12 -0
- package/dist/common/utils/resolve-auth-catalog.util.js +73 -0
- package/dist/common/utils/resolve-auth-catalog.util.js.map +1 -0
- package/dist/common/utils/resolve-effective-permissions.util.d.ts +36 -0
- package/dist/common/utils/resolve-effective-permissions.util.js +48 -0
- package/dist/common/utils/resolve-effective-permissions.util.js.map +1 -0
- package/dist/common/utils/resolve-request-permissions.util.d.ts +14 -0
- package/dist/common/utils/resolve-request-permissions.util.js +66 -0
- package/dist/common/utils/resolve-request-permissions.util.js.map +1 -0
- package/dist/common/utils/run-auth-query.js +55 -0
- package/dist/common/utils/run-auth-query.js.map +1 -0
- package/dist/common/utils/serialize-ability-rules.util.js +41 -0
- package/dist/common/utils/serialize-ability-rules.util.js.map +1 -0
- package/dist/core/adapters/mikro-orm/adapter-config.js.map +1 -0
- package/dist/core/adapters/mikro-orm/create-custom-adapter.js +110 -0
- package/dist/core/adapters/mikro-orm/create-custom-adapter.js.map +1 -0
- package/dist/core/adapters/mikro-orm/entity-metadata-resolver.js +103 -0
- package/dist/core/adapters/mikro-orm/entity-metadata-resolver.js.map +1 -0
- package/dist/core/adapters/mikro-orm/where-compiler.js +81 -0
- package/dist/core/adapters/mikro-orm/where-compiler.js.map +1 -0
- package/dist/core/adapters/mikro-orm-adapter.js +38 -0
- package/dist/core/adapters/mikro-orm-adapter.js.map +1 -0
- package/dist/core/auth-ability.factory.d.ts +14 -0
- package/dist/core/auth-ability.factory.js +146 -0
- package/dist/core/auth-ability.factory.js.map +1 -0
- package/dist/core/auth-context.d.ts +35 -0
- package/dist/core/auth-context.js +172 -0
- package/dist/core/auth-context.js.map +1 -0
- package/dist/core/auth-entities.d.ts +12 -0
- package/dist/core/auth-entities.js +25 -0
- package/dist/core/auth-entities.js.map +1 -0
- package/dist/core/auth-enum-registry.d.ts +11 -0
- package/dist/core/auth-enum-registry.js +79 -0
- package/dist/core/auth-enum-registry.js.map +1 -0
- package/dist/core/auth-handler.middleware.js +45 -0
- package/dist/core/auth-handler.middleware.js.map +1 -0
- package/dist/core/auth-service.providers.d.ts +18 -0
- package/dist/core/auth-service.providers.js +19 -0
- package/dist/core/auth-service.providers.js.map +1 -0
- package/dist/core/auth.guard.d.ts +48 -0
- package/dist/core/auth.guard.js +219 -0
- package/dist/core/auth.guard.js.map +1 -0
- package/dist/core/auth.middleware.d.ts +62 -0
- package/dist/core/auth.middleware.js +254 -0
- package/dist/core/auth.middleware.js.map +1 -0
- package/dist/core/auth.module-definition.d.ts +2 -0
- package/dist/core/auth.module-definition.js.map +1 -0
- package/dist/core/auth.module.d.ts +41 -0
- package/dist/core/auth.module.js +231 -0
- package/dist/core/auth.module.js.map +1 -0
- package/dist/core/better-auth-adapter.js.map +1 -0
- package/dist/core/connections/account.connection-definition.js.map +1 -0
- package/dist/core/connections/session.connection-definition.js.map +1 -0
- package/dist/core/connections/user.connection-definition.js.map +1 -0
- package/dist/core/constants/auth.constants.js.map +1 -0
- package/dist/core/constants/user.constants.d.ts +13 -0
- package/dist/core/constants/user.constants.js +38 -0
- package/dist/core/constants/user.constants.js.map +1 -0
- package/dist/core/create-auth-instance.d.ts +31 -0
- package/dist/core/create-auth-instance.js +170 -0
- package/dist/core/create-auth-instance.js.map +1 -0
- package/dist/core/decorators/current-session.decorator.js.map +1 -0
- package/dist/core/decorators/current-user.decorator.js.map +1 -0
- package/dist/core/entities/account.entity.js +143 -0
- package/dist/core/entities/account.entity.js.map +1 -0
- package/dist/core/entities/auth-entity-map.d.ts +20 -0
- package/dist/core/entities/auth-entity-map.js +21 -0
- package/dist/core/entities/auth-entity-map.js.map +1 -0
- package/dist/core/entities/session.entity.js.map +1 -0
- package/dist/core/entities/user.entity.d.ts +28 -0
- package/dist/core/entities/user.entity.js +151 -0
- package/dist/core/entities/user.entity.js.map +1 -0
- package/dist/core/entities/verification.entity.js.map +1 -0
- package/dist/core/enums/user-permission.enum.js +7 -0
- package/dist/core/enums/user-permission.enum.js.map +1 -0
- package/dist/core/enums/user-role.enum.js +6 -0
- package/dist/core/enums/user-role.enum.js.map +1 -0
- package/dist/core/inputs/auth-change-email.input.js.map +1 -0
- package/dist/core/inputs/auth-change-password.input.js.map +1 -0
- package/dist/core/inputs/auth-delete-user.input.js.map +1 -0
- package/dist/core/inputs/auth-link-social-account.input.js.map +1 -0
- package/dist/core/inputs/auth-request-password-reset.input.js.map +1 -0
- package/dist/core/inputs/auth-reset-password.input.js.map +1 -0
- package/dist/core/inputs/auth-send-verification-email.input.js.map +1 -0
- package/dist/core/inputs/auth-sign-in-social.input.js.map +1 -0
- package/dist/core/inputs/auth-sign-in.input.js.map +1 -0
- package/dist/core/inputs/auth-sign-up.input.js.map +1 -0
- package/dist/core/inputs/auth-update-user.input.js.map +1 -0
- package/dist/core/interfaces/auth-access-token.interface.js.map +1 -0
- package/dist/core/interfaces/auth-account-info.interface.js.map +1 -0
- package/dist/core/interfaces/auth-account.interface.js.map +1 -0
- package/dist/core/interfaces/auth-change-email-confirmation-data.interface.js.map +1 -0
- package/dist/core/interfaces/auth-context-patch.interface.d.ts +16 -0
- package/dist/core/interfaces/auth-context-patch.interface.js +2 -0
- package/dist/core/interfaces/auth-context-patch.interface.js.map +1 -0
- package/dist/core/interfaces/auth-delete-account-verification-data.interface.js.map +1 -0
- package/dist/core/interfaces/auth-email-verification-data.interface.js.map +1 -0
- package/dist/core/interfaces/auth-module-account-linking-options.interface.js.map +1 -0
- package/dist/core/interfaces/auth-module-account-options.interface.js.map +1 -0
- package/dist/core/interfaces/auth-module-change-email-options.interface.js.map +1 -0
- package/dist/core/interfaces/auth-module-delete-user-options.interface.js.map +1 -0
- package/dist/core/interfaces/auth-module-email-and-password-options.interface.js.map +1 -0
- package/dist/core/interfaces/auth-module-email-verification-options.interface.js.map +1 -0
- package/dist/core/interfaces/auth-module-middleware-options.interface.js.map +1 -0
- package/dist/core/interfaces/auth-module-oauth-provider.interface.js.map +1 -0
- package/dist/core/interfaces/auth-module-options.interface.d.ts +49 -0
- package/dist/core/interfaces/auth-module-options.interface.js.map +1 -0
- package/dist/core/interfaces/auth-module-password-options.interface.js.map +1 -0
- package/dist/core/interfaces/auth-module-session-cookie-cache-options.interface.js.map +1 -0
- package/dist/core/interfaces/auth-module-session-cookie-cache-refresh-options.interface.js.map +1 -0
- package/dist/core/interfaces/auth-module-session-options.interface.js.map +1 -0
- package/dist/core/interfaces/auth-module-social-provider.interface.js.map +1 -0
- package/dist/core/interfaces/auth-module-user-options.interface.js.map +1 -0
- package/dist/core/interfaces/auth-oauth-basic-token-endpoint-auth.interface.js.map +1 -0
- package/dist/core/interfaces/auth-oauth-client-assertion-context.interface.js.map +1 -0
- package/dist/core/interfaces/auth-oauth-custom-token-endpoint-auth.interface.js.map +1 -0
- package/dist/core/interfaces/auth-oauth-mapped-user.interface.js.map +1 -0
- package/dist/core/interfaces/auth-oauth-no-token-endpoint-auth.interface.js.map +1 -0
- package/dist/core/interfaces/auth-oauth-post-token-endpoint-auth.interface.js.map +1 -0
- package/dist/core/interfaces/auth-oauth-private-key-jwt-token-endpoint-auth.interface.js.map +1 -0
- package/dist/core/interfaces/auth-oauth-profile.interface.js.map +1 -0
- package/dist/core/interfaces/auth-oauth-refresh-context.interface.js.map +1 -0
- package/dist/core/interfaces/auth-oauth-token-request-client-options.interface.js.map +1 -0
- package/dist/core/interfaces/auth-oauth-token-request-context.interface.js.map +1 -0
- package/dist/core/interfaces/auth-oauth-tokens.interface.js.map +1 -0
- package/dist/core/interfaces/auth-oauth-user-info.interface.js.map +1 -0
- package/dist/core/interfaces/auth-provider-user-info.interface.js.map +1 -0
- package/dist/core/interfaces/auth-refreshed-token.interface.js.map +1 -0
- package/dist/core/interfaces/auth-reset-password-data.interface.js.map +1 -0
- package/dist/core/interfaces/auth-social-provider-user-info.interface.js.map +1 -0
- package/dist/core/interfaces/auth-social-provider.interface.js.map +1 -0
- package/dist/core/interfaces/auth-user.interface.js.map +1 -0
- package/dist/core/interfaces/authenticated-session.interface.js.map +1 -0
- package/dist/core/interfaces/change-auth-email-options.interface.js.map +1 -0
- package/dist/core/interfaces/change-auth-password-options.interface.js.map +1 -0
- package/dist/core/interfaces/change-auth-password-result.interface.js.map +1 -0
- package/dist/core/interfaces/delete-auth-user-options.interface.js.map +1 -0
- package/dist/core/interfaces/delete-auth-user-result.interface.js.map +1 -0
- package/dist/core/interfaces/link-auth-social-account-options.interface.js.map +1 -0
- package/dist/core/interfaces/link-auth-social-account-result.interface.js.map +1 -0
- package/dist/core/interfaces/request-password-reset-options.interface.js.map +1 -0
- package/dist/core/interfaces/request-password-reset-result.interface.js.map +1 -0
- package/dist/core/interfaces/reset-password-options.interface.js.map +1 -0
- package/dist/core/interfaces/send-verification-email-options.interface.js.map +1 -0
- package/dist/core/interfaces/sign-in-entity-result.interface.js.map +1 -0
- package/dist/core/interfaces/sign-in-options.interface.js.map +1 -0
- package/dist/core/interfaces/sign-in-result.interface.js.map +1 -0
- package/dist/core/interfaces/sign-in-social-entity-result.interface.js.map +1 -0
- package/dist/core/interfaces/sign-in-social-options.interface.js.map +1 -0
- package/dist/core/interfaces/sign-in-social-result.interface.js.map +1 -0
- package/dist/core/interfaces/sign-up-options.interface.js.map +1 -0
- package/dist/core/interfaces/sign-up-result.interface.js.map +1 -0
- package/dist/core/interfaces/unlink-auth-account-options.interface.js.map +1 -0
- package/dist/core/interfaces/update-auth-user-options.interface.js.map +1 -0
- package/dist/core/interfaces/user-has-permissions-options.interface.js.map +1 -0
- package/dist/core/objects/auth-ability-rule.object.js.map +1 -0
- package/dist/core/objects/auth-change-password-result.object.js.map +1 -0
- package/dist/core/objects/auth-delete-user-result.object.js.map +1 -0
- package/dist/core/objects/auth-link-social-account-result.object.js.map +1 -0
- package/dist/core/objects/auth-request-password-reset-result.object.js.map +1 -0
- package/dist/core/objects/auth-sign-in-result.object.js.map +1 -0
- package/dist/core/objects/auth-sign-in-social-result.object.js.map +1 -0
- package/dist/core/objects/auth-social-provider.object.js.map +1 -0
- package/dist/core/objects/password-policy.object.js.map +1 -0
- package/dist/core/objects/sign-up-payload.object.js.map +1 -0
- package/dist/core/resolvers/auth.resolver.js +352 -0
- package/dist/core/resolvers/auth.resolver.js.map +1 -0
- package/dist/core/resolvers/session.resolver.d.ts +53 -0
- package/dist/core/resolvers/session.resolver.js +137 -0
- package/dist/core/resolvers/session.resolver.js.map +1 -0
- package/dist/core/resolvers/user.resolver.d.ts +41 -0
- package/dist/core/resolvers/user.resolver.js +94 -0
- package/dist/core/resolvers/user.resolver.js.map +1 -0
- package/dist/core/revoked-authentication.exception.js.map +1 -0
- package/dist/core/services/account.service.js +63 -0
- package/dist/core/services/account.service.js.map +1 -0
- package/dist/core/services/auth.service.js +471 -0
- package/dist/core/services/auth.service.js.map +1 -0
- package/dist/core/services/session.service.d.ts +92 -0
- package/dist/core/services/session.service.js +440 -0
- package/dist/core/services/session.service.js.map +1 -0
- package/dist/core/services/user-deletion.service.d.ts +21 -0
- package/dist/core/services/user-deletion.service.js +58 -0
- package/dist/core/services/user-deletion.service.js.map +1 -0
- package/dist/core/services/user.service.d.ts +176 -0
- package/dist/core/services/user.service.js +613 -0
- package/dist/core/services/user.service.js.map +1 -0
- package/dist/core/types/auth-account-selector.type.js.map +1 -0
- package/dist/core/types/auth-maybe-promise.type.js.map +1 -0
- package/dist/core/types/auth-module-provider.type.js.map +1 -0
- package/dist/core/types/auth-module-roles.type.js.map +1 -0
- package/dist/core/types/auth-module-social-provider-id.type.js.map +1 -0
- package/dist/core/types/auth-oauth-token-endpoint-auth.type.js.map +1 -0
- package/dist/core/types/auth-send-reset-password.type.js.map +1 -0
- package/dist/core/types/auth-send-verification-email.type.js.map +1 -0
- package/dist/core/types/build-ability-callback.type.d.ts +4 -0
- package/dist/core/types/build-ability-callback.type.js.map +1 -0
- package/dist/core/types/can-subject-callback.type.js.map +1 -0
- package/dist/core/types/lowercase-identifier.type.js.map +1 -0
- package/dist/core/types/permission-name.type.js.map +1 -0
- package/dist/core/types/role-name.type.js.map +1 -0
- package/dist/core/types/route-argument-metadata.type.d.ts +3 -0
- package/dist/core/types/route-argument-metadata.type.js.map +1 -0
- package/dist/core/utils/apply-auth-response-cookies.util.js +18 -0
- package/dist/core/utils/apply-auth-response-cookies.util.js.map +1 -0
- package/dist/core/utils/assert-current-identity.util.d.ts +29 -0
- package/dist/core/utils/assert-current-identity.util.js +69 -0
- package/dist/core/utils/assert-current-identity.util.js.map +1 -0
- package/dist/core/utils/auth-role.util.js.map +1 -0
- package/dist/core/utils/build-request-ability.util.d.ts +8 -0
- package/dist/core/utils/build-request-ability.util.js +33 -0
- package/dist/core/utils/build-request-ability.util.js.map +1 -0
- package/dist/core/utils/clear-authentication-context.util.d.ts +6 -0
- package/dist/core/utils/clear-authentication-context.util.js +35 -0
- package/dist/core/utils/clear-authentication-context.util.js.map +1 -0
- package/dist/core/utils/create-email-and-password-config.d.ts +16 -0
- package/dist/core/utils/create-email-and-password-config.js.map +1 -0
- package/dist/core/utils/create-email-verification-config.d.ts +13 -0
- package/dist/core/utils/create-email-verification-config.js.map +1 -0
- package/dist/core/utils/create-generic-oauth-config.js.map +1 -0
- package/dist/core/utils/create-oidc-config.js.map +1 -0
- package/dist/core/utils/create-social-provider-config.js.map +1 -0
- package/dist/core/utils/create-social-providers-config.js.map +1 -0
- package/dist/core/utils/create-user-config.js +59 -0
- package/dist/core/utils/create-user-config.js.map +1 -0
- package/dist/core/utils/estimate-entropy.js +14 -0
- package/dist/core/utils/estimate-entropy.js.map +1 -0
- package/dist/core/utils/generic-oauth-provider-config.type.js.map +1 -0
- package/dist/core/utils/has-social-provider-credential-env-config.js.map +1 -0
- package/dist/core/utils/is-env-true.js.map +1 -0
- package/dist/core/utils/oidc.constants.d.ts +4 -0
- package/dist/core/utils/oidc.constants.js +15 -0
- package/dist/core/utils/oidc.constants.js.map +1 -0
- package/dist/core/utils/resolve-auth-features.util.d.ts +26 -0
- package/dist/core/utils/resolve-auth-features.util.js +67 -0
- package/dist/core/utils/resolve-auth-features.util.js.map +1 -0
- package/dist/core/utils/resolve-oidc-prompt.js.map +1 -0
- package/dist/core/utils/resolve-oidc-scopes.js.map +1 -0
- package/dist/core/utils/resolve-required-oidc-env.js.map +1 -0
- package/dist/core/utils/resolve-required-social-provider-env.js.map +1 -0
- package/dist/core/utils/resolve-secret.d.ts +7 -0
- package/dist/core/utils/resolve-secret.js.map +1 -0
- package/dist/core/utils/resolve-social-provider-enabled.js.map +1 -0
- package/dist/core/utils/social-provider.constants.d.ts +20 -0
- package/dist/core/utils/social-provider.constants.js +19 -0
- package/dist/core/utils/social-provider.constants.js.map +1 -0
- package/dist/core/utils/split-auth-providers.js.map +1 -0
- package/dist/index.d.ts +270 -211
- package/dist/index.js +270 -209
- package/dist/index.js.map +1 -1
- package/dist/workspace/connections/workspace-invitation.connection-definition.d.ts +9 -0
- package/dist/workspace/connections/workspace-invitation.connection-definition.js +45 -0
- package/dist/workspace/connections/workspace-invitation.connection-definition.js.map +1 -0
- package/dist/workspace/connections/workspace-member.connection-definition.d.ts +9 -0
- package/dist/workspace/connections/workspace-member.connection-definition.js +58 -0
- package/dist/workspace/connections/workspace-member.connection-definition.js.map +1 -0
- package/dist/workspace/connections/workspace.connection-definition.js +48 -0
- package/dist/workspace/connections/workspace.connection-definition.js.map +1 -0
- package/dist/workspace/constants/workspace.constants.d.ts +15 -0
- package/dist/workspace/constants/workspace.constants.js +39 -0
- package/dist/workspace/constants/workspace.constants.js.map +1 -0
- package/dist/workspace/decorators/current-workspace-member.decorator.d.ts +2 -0
- package/dist/workspace/decorators/current-workspace-member.decorator.js +6 -0
- package/dist/workspace/decorators/current-workspace-member.decorator.js.map +1 -0
- package/dist/workspace/decorators/current-workspace.decorator.js.map +1 -0
- package/dist/workspace/entities/workspace-invitation.entity.d.ts +29 -0
- package/dist/workspace/entities/workspace-invitation.entity.js +129 -0
- package/dist/workspace/entities/workspace-invitation.entity.js.map +1 -0
- package/dist/workspace/entities/workspace-member.entity.d.ts +37 -0
- package/dist/workspace/entities/workspace-member.entity.js +151 -0
- package/dist/workspace/entities/workspace-member.entity.js.map +1 -0
- package/dist/workspace/entities/workspace.entity.d.ts +15 -0
- package/dist/workspace/entities/workspace.entity.js +79 -0
- package/dist/workspace/entities/workspace.entity.js.map +1 -0
- package/dist/workspace/enums/workspace-invitation-status.enum.d.ts +11 -0
- package/dist/workspace/enums/workspace-invitation-status.enum.js +17 -0
- package/dist/workspace/enums/workspace-invitation-status.enum.js.map +1 -0
- package/dist/workspace/enums/workspace-member-status.enum.d.ts +9 -0
- package/dist/workspace/enums/workspace-member-status.enum.js +15 -0
- package/dist/workspace/enums/workspace-member-status.enum.js.map +1 -0
- package/dist/workspace/enums/workspace-member-type.enum.d.ts +7 -0
- package/dist/workspace/enums/workspace-member-type.enum.js +11 -0
- package/dist/workspace/enums/workspace-member-type.enum.js.map +1 -0
- package/dist/workspace/enums/workspace-permission.enum.js +7 -0
- package/dist/workspace/enums/workspace-permission.enum.js.map +1 -0
- package/dist/workspace/enums/workspace-role.enum.js +9 -0
- package/dist/workspace/enums/workspace-role.enum.js.map +1 -0
- package/dist/workspace/inputs/add-workspace-member.input.d.ts +16 -0
- package/dist/workspace/inputs/add-workspace-member.input.js +57 -0
- package/dist/workspace/inputs/add-workspace-member.input.js.map +1 -0
- package/dist/workspace/inputs/create-workspace-invitation.input.d.ts +10 -0
- package/dist/workspace/inputs/create-workspace-invitation.input.js +41 -0
- package/dist/workspace/inputs/create-workspace-invitation.input.js.map +1 -0
- package/dist/workspace/inputs/create-workspace.input.js.map +1 -0
- package/dist/workspace/inputs/set-workspace-member-permissions.input.d.ts +6 -0
- package/dist/workspace/inputs/set-workspace-member-permissions.input.js +27 -0
- package/dist/workspace/inputs/set-workspace-member-permissions.input.js.map +1 -0
- package/dist/workspace/inputs/set-workspace-member-roles.input.d.ts +6 -0
- package/dist/workspace/inputs/set-workspace-member-roles.input.js +27 -0
- package/dist/workspace/inputs/set-workspace-member-roles.input.js.map +1 -0
- package/dist/workspace/inputs/update-workspace-member.input.d.ts +10 -0
- package/dist/workspace/inputs/update-workspace-member.input.js +45 -0
- package/dist/workspace/inputs/update-workspace-member.input.js.map +1 -0
- package/dist/workspace/inputs/update-workspace.input.js.map +1 -0
- package/dist/workspace/interfaces/accept-workspace-invitation-result.interface.d.ts +9 -0
- package/dist/workspace/interfaces/accept-workspace-invitation-result.interface.js +2 -0
- package/dist/workspace/interfaces/accept-workspace-invitation-result.interface.js.map +1 -0
- package/dist/workspace/interfaces/add-workspace-member-options.interface.d.ts +7 -0
- package/dist/workspace/interfaces/add-workspace-member-options.interface.js +2 -0
- package/dist/workspace/interfaces/add-workspace-member-options.interface.js.map +1 -0
- package/dist/workspace/interfaces/auth-module-workspace-options.interface.d.ts +18 -0
- package/dist/workspace/interfaces/auth-module-workspace-options.interface.js.map +1 -0
- package/dist/workspace/interfaces/auth-workspace-invitation-email-data.interface.d.ts +18 -0
- package/dist/workspace/interfaces/auth-workspace-invitation-email-data.interface.js +2 -0
- package/dist/workspace/interfaces/auth-workspace-invitation-email-data.interface.js.map +1 -0
- package/dist/workspace/interfaces/create-workspace-invitation-options.interface.d.ts +9 -0
- package/dist/workspace/interfaces/create-workspace-invitation-options.interface.js +2 -0
- package/dist/workspace/interfaces/create-workspace-invitation-options.interface.js.map +1 -0
- package/dist/workspace/interfaces/create-workspace-options.interface.js.map +1 -0
- package/dist/workspace/interfaces/update-workspace-member-options.interface.d.ts +10 -0
- package/dist/workspace/interfaces/update-workspace-member-options.interface.js +2 -0
- package/dist/workspace/interfaces/update-workspace-member-options.interface.js.map +1 -0
- package/dist/workspace/interfaces/update-workspace-options.interface.js.map +1 -0
- package/dist/workspace/interfaces/workspace-has-permissions-options.interface.js.map +1 -0
- package/dist/workspace/objects/accept-workspace-invitation-payload.object.d.ts +9 -0
- package/dist/workspace/objects/accept-workspace-invitation-payload.object.js +36 -0
- package/dist/workspace/objects/accept-workspace-invitation-payload.object.js.map +1 -0
- package/dist/workspace/objects/add-workspace-member-payload.object.d.ts +5 -0
- package/dist/workspace/objects/add-workspace-member-payload.object.js +24 -0
- package/dist/workspace/objects/add-workspace-member-payload.object.js.map +1 -0
- package/dist/workspace/objects/cancel-workspace-invitation-payload.object.d.ts +5 -0
- package/dist/workspace/objects/cancel-workspace-invitation-payload.object.js +24 -0
- package/dist/workspace/objects/cancel-workspace-invitation-payload.object.js.map +1 -0
- package/dist/workspace/objects/create-workspace-invitation-payload.object.d.ts +5 -0
- package/dist/workspace/objects/create-workspace-invitation-payload.object.js +24 -0
- package/dist/workspace/objects/create-workspace-invitation-payload.object.js.map +1 -0
- package/dist/workspace/objects/create-workspace-payload.object.js.map +1 -0
- package/dist/workspace/objects/delete-workspace-payload.object.js.map +1 -0
- package/dist/workspace/objects/leave-workspace-payload.object.js.map +1 -0
- package/dist/workspace/objects/reject-workspace-invitation-payload.object.d.ts +5 -0
- package/dist/workspace/objects/reject-workspace-invitation-payload.object.js +24 -0
- package/dist/workspace/objects/reject-workspace-invitation-payload.object.js.map +1 -0
- package/dist/workspace/objects/remove-workspace-member-payload.object.d.ts +5 -0
- package/dist/workspace/objects/remove-workspace-member-payload.object.js +24 -0
- package/dist/workspace/objects/remove-workspace-member-payload.object.js.map +1 -0
- package/dist/workspace/objects/set-workspace-member-permissions-payload.object.d.ts +5 -0
- package/dist/workspace/objects/set-workspace-member-permissions-payload.object.js +24 -0
- package/dist/workspace/objects/set-workspace-member-permissions-payload.object.js.map +1 -0
- package/dist/workspace/objects/set-workspace-member-roles-payload.object.d.ts +5 -0
- package/dist/workspace/objects/set-workspace-member-roles-payload.object.js +24 -0
- package/dist/workspace/objects/set-workspace-member-roles-payload.object.js.map +1 -0
- package/dist/workspace/objects/update-workspace-member-payload.object.d.ts +5 -0
- package/dist/workspace/objects/update-workspace-member-payload.object.js +24 -0
- package/dist/workspace/objects/update-workspace-member-payload.object.js.map +1 -0
- package/dist/workspace/objects/update-workspace-payload.object.js.map +1 -0
- package/dist/workspace/objects/workspace-permission-option.object.js.map +1 -0
- package/dist/workspace/objects/workspace-role-option.object.js.map +1 -0
- package/dist/workspace/resolvers/user-workspace.resolver.d.ts +34 -0
- package/dist/workspace/resolvers/user-workspace.resolver.js +77 -0
- package/dist/workspace/resolvers/user-workspace.resolver.js.map +1 -0
- package/dist/workspace/resolvers/workspace-invitation.resolver.d.ts +67 -0
- package/dist/workspace/resolvers/workspace-invitation.resolver.js +170 -0
- package/dist/workspace/resolvers/workspace-invitation.resolver.js.map +1 -0
- package/dist/workspace/resolvers/workspace-member.resolver.d.ts +92 -0
- package/dist/workspace/resolvers/workspace-member.resolver.js +233 -0
- package/dist/workspace/resolvers/workspace-member.resolver.js.map +1 -0
- package/dist/workspace/resolvers/workspace.resolver.d.ts +108 -0
- package/dist/workspace/resolvers/workspace.resolver.js +256 -0
- package/dist/workspace/resolvers/workspace.resolver.js.map +1 -0
- package/dist/workspace/services/workspace-invitation.service.d.ts +120 -0
- package/dist/workspace/services/workspace-invitation.service.js +466 -0
- package/dist/workspace/services/workspace-invitation.service.js.map +1 -0
- package/dist/workspace/services/workspace-member.service.d.ts +169 -0
- package/dist/workspace/services/workspace-member.service.js +564 -0
- package/dist/workspace/services/workspace-member.service.js.map +1 -0
- package/dist/workspace/services/workspace.service.d.ts +108 -0
- package/dist/workspace/services/workspace.service.js +347 -0
- package/dist/workspace/services/workspace.service.js.map +1 -0
- package/dist/workspace/types/auth-send-workspace-invitation-email.type.d.ts +7 -0
- package/dist/workspace/types/auth-send-workspace-invitation-email.type.js +2 -0
- package/dist/workspace/types/auth-send-workspace-invitation-email.type.js.map +1 -0
- package/dist/workspace/types/auth-workspace-invitation-email-inviter.type.d.ts +7 -0
- package/dist/workspace/types/auth-workspace-invitation-email-inviter.type.js +2 -0
- package/dist/workspace/types/auth-workspace-invitation-email-inviter.type.js.map +1 -0
- package/dist/workspace/utils/get-current-workspace-member.util.d.ts +6 -0
- package/dist/workspace/utils/get-current-workspace-member.util.js +17 -0
- package/dist/workspace/utils/get-current-workspace-member.util.js.map +1 -0
- package/dist/workspace/utils/read-invitation-identity.util.d.ts +8 -0
- package/dist/workspace/utils/read-invitation-identity.util.js +38 -0
- package/dist/workspace/utils/read-invitation-identity.util.js.map +1 -0
- package/dist/workspace/utils/resolve-request-workspace-member.util.d.ts +7 -0
- package/dist/workspace/utils/resolve-request-workspace-member.util.js +29 -0
- package/dist/workspace/utils/resolve-request-workspace-member.util.js.map +1 -0
- package/dist/workspace/workspace.providers.d.ts +3 -0
- package/dist/workspace/workspace.providers.js +16 -0
- package/dist/workspace/workspace.providers.js.map +1 -0
- package/package.json +14 -11
- package/dist/adapters/mikro-orm/adapter-config.js.map +0 -1
- package/dist/adapters/mikro-orm/create-custom-adapter.js +0 -106
- package/dist/adapters/mikro-orm/create-custom-adapter.js.map +0 -1
- package/dist/adapters/mikro-orm/entity-metadata-resolver.js +0 -97
- package/dist/adapters/mikro-orm/entity-metadata-resolver.js.map +0 -1
- package/dist/adapters/mikro-orm/where-compiler.js +0 -80
- package/dist/adapters/mikro-orm/where-compiler.js.map +0 -1
- package/dist/adapters/mikro-orm-adapter.js +0 -38
- package/dist/adapters/mikro-orm-adapter.js.map +0 -1
- package/dist/api-key-usage.interceptor.d.ts +0 -19
- package/dist/api-key-usage.interceptor.js +0 -45
- package/dist/api-key-usage.interceptor.js.map +0 -1
- package/dist/auth-handler.middleware.js +0 -45
- package/dist/auth-handler.middleware.js.map +0 -1
- package/dist/auth-module-options.interface.d.ts +0 -46
- package/dist/auth-module-options.interface.js.map +0 -1
- package/dist/auth.ability.d.ts +0 -17
- package/dist/auth.ability.js +0 -32
- package/dist/auth.ability.js.map +0 -1
- package/dist/auth.constants.js.map +0 -1
- package/dist/auth.guard.d.ts +0 -48
- package/dist/auth.guard.js +0 -219
- package/dist/auth.guard.js.map +0 -1
- package/dist/auth.middleware.d.ts +0 -54
- package/dist/auth.middleware.js +0 -235
- package/dist/auth.middleware.js.map +0 -1
- package/dist/auth.module-definition.d.ts +0 -2
- package/dist/auth.module-definition.js.map +0 -1
- package/dist/auth.module.d.ts +0 -40
- package/dist/auth.module.js +0 -169
- package/dist/auth.module.js.map +0 -1
- package/dist/connections/account.connection-definition.js.map +0 -1
- package/dist/connections/index.d.ts +0 -8
- package/dist/connections/index.js +0 -9
- package/dist/connections/index.js.map +0 -1
- package/dist/connections/member-api-key.connection-definition.d.ts +0 -13
- package/dist/connections/member-api-key.connection-definition.js +0 -60
- package/dist/connections/member-api-key.connection-definition.js.map +0 -1
- package/dist/connections/member.connection-definition.d.ts +0 -9
- package/dist/connections/member.connection-definition.js +0 -53
- package/dist/connections/member.connection-definition.js.map +0 -1
- package/dist/connections/session.connection-definition.js.map +0 -1
- package/dist/connections/user-api-key.connection-definition.d.ts +0 -13
- package/dist/connections/user-api-key.connection-definition.js +0 -60
- package/dist/connections/user-api-key.connection-definition.js.map +0 -1
- package/dist/connections/user.connection-definition.js.map +0 -1
- package/dist/connections/workspace.connection-definition.js +0 -43
- package/dist/connections/workspace.connection-definition.js.map +0 -1
- package/dist/decorators/can.decorator.d.ts +0 -11
- package/dist/decorators/can.decorator.js +0 -15
- package/dist/decorators/can.decorator.js.map +0 -1
- package/dist/decorators/current-api-key.decorator.js.map +0 -1
- package/dist/decorators/current-member.decorator.d.ts +0 -2
- package/dist/decorators/current-member.decorator.js +0 -6
- package/dist/decorators/current-member.decorator.js.map +0 -1
- package/dist/decorators/current-session.decorator.js.map +0 -1
- package/dist/decorators/current-user.decorator.js.map +0 -1
- package/dist/decorators/current-workspace.decorator.js.map +0 -1
- package/dist/decorators/index.d.ts +0 -7
- package/dist/decorators/index.js +0 -8
- package/dist/decorators/index.js.map +0 -1
- package/dist/decorators/public.decorator.d.ts +0 -7
- package/dist/decorators/public.decorator.js +0 -9
- package/dist/decorators/public.decorator.js.map +0 -1
- package/dist/entities/account.entity.js +0 -143
- package/dist/entities/account.entity.js.map +0 -1
- package/dist/entities/auth-entity-map.d.ts +0 -21
- package/dist/entities/auth-entity-map.js +0 -22
- package/dist/entities/auth-entity-map.js.map +0 -1
- package/dist/entities/index.d.ts +0 -19
- package/dist/entities/index.js +0 -31
- package/dist/entities/index.js.map +0 -1
- package/dist/entities/invitation.entity.d.ts +0 -29
- package/dist/entities/invitation.entity.js +0 -129
- package/dist/entities/invitation.entity.js.map +0 -1
- package/dist/entities/member-api-key.entity.d.ts +0 -39
- package/dist/entities/member-api-key.entity.js +0 -171
- package/dist/entities/member-api-key.entity.js.map +0 -1
- package/dist/entities/member.entity.d.ts +0 -37
- package/dist/entities/member.entity.js +0 -151
- package/dist/entities/member.entity.js.map +0 -1
- package/dist/entities/session.entity.js.map +0 -1
- package/dist/entities/user-api-key.entity.d.ts +0 -29
- package/dist/entities/user-api-key.entity.js +0 -147
- package/dist/entities/user-api-key.entity.js.map +0 -1
- package/dist/entities/user.entity.d.ts +0 -31
- package/dist/entities/user.entity.js +0 -159
- package/dist/entities/user.entity.js.map +0 -1
- package/dist/entities/verification.entity.js.map +0 -1
- package/dist/entities/workspace.entity.d.ts +0 -15
- package/dist/entities/workspace.entity.js +0 -79
- package/dist/entities/workspace.entity.js.map +0 -1
- package/dist/enums/index.d.ts +0 -9
- package/dist/enums/index.js +0 -10
- package/dist/enums/index.js.map +0 -1
- package/dist/enums/member-api-key-permission.enum.d.ts +0 -4
- package/dist/enums/member-api-key-permission.enum.js +0 -11
- package/dist/enums/member-api-key-permission.enum.js.map +0 -1
- package/dist/enums/member-status.enum.d.ts +0 -9
- package/dist/enums/member-status.enum.js +0 -15
- package/dist/enums/member-status.enum.js.map +0 -1
- package/dist/enums/member-type.enum.d.ts +0 -7
- package/dist/enums/member-type.enum.js +0 -11
- package/dist/enums/member-type.enum.js.map +0 -1
- package/dist/enums/user-api-key-permission.enum.js +0 -11
- package/dist/enums/user-api-key-permission.enum.js.map +0 -1
- package/dist/enums/user-permission.enum.js +0 -7
- package/dist/enums/user-permission.enum.js.map +0 -1
- package/dist/enums/user-role.enum.js +0 -6
- package/dist/enums/user-role.enum.js.map +0 -1
- package/dist/enums/workspace-permission.enum.js +0 -7
- package/dist/enums/workspace-permission.enum.js.map +0 -1
- package/dist/enums/workspace-role.enum.js +0 -9
- package/dist/enums/workspace-role.enum.js.map +0 -1
- package/dist/features/invitations/accept-invitation-payload.object.d.ts +0 -9
- package/dist/features/invitations/accept-invitation-payload.object.js +0 -36
- package/dist/features/invitations/accept-invitation-payload.object.js.map +0 -1
- package/dist/features/invitations/accept-invitation-result.interface.d.ts +0 -9
- package/dist/features/invitations/accept-invitation-result.interface.js +0 -2
- package/dist/features/invitations/accept-invitation-result.interface.js.map +0 -1
- package/dist/features/invitations/auth-invitation-email-data.interface.d.ts +0 -18
- package/dist/features/invitations/auth-invitation-email-data.interface.js +0 -2
- package/dist/features/invitations/auth-invitation-email-data.interface.js.map +0 -1
- package/dist/features/invitations/auth-invitation-email-inviter.type.d.ts +0 -7
- package/dist/features/invitations/auth-invitation-email-inviter.type.js +0 -2
- package/dist/features/invitations/auth-invitation-email-inviter.type.js.map +0 -1
- package/dist/features/invitations/auth-send-invitation-email.type.d.ts +0 -7
- package/dist/features/invitations/auth-send-invitation-email.type.js +0 -2
- package/dist/features/invitations/auth-send-invitation-email.type.js.map +0 -1
- package/dist/features/invitations/cancel-invitation-payload.object.d.ts +0 -5
- package/dist/features/invitations/cancel-invitation-payload.object.js +0 -24
- package/dist/features/invitations/cancel-invitation-payload.object.js.map +0 -1
- package/dist/features/invitations/create-invitation-options.interface.d.ts +0 -9
- package/dist/features/invitations/create-invitation-options.interface.js +0 -2
- package/dist/features/invitations/create-invitation-options.interface.js.map +0 -1
- package/dist/features/invitations/create-invitation-payload.object.d.ts +0 -5
- package/dist/features/invitations/create-invitation-payload.object.js +0 -24
- package/dist/features/invitations/create-invitation-payload.object.js.map +0 -1
- package/dist/features/invitations/create-invitation.input.d.ts +0 -10
- package/dist/features/invitations/create-invitation.input.js +0 -41
- package/dist/features/invitations/create-invitation.input.js.map +0 -1
- package/dist/features/invitations/invitation-status.enum.d.ts +0 -11
- package/dist/features/invitations/invitation-status.enum.js +0 -17
- package/dist/features/invitations/invitation-status.enum.js.map +0 -1
- package/dist/features/invitations/invitation.connection-definition.d.ts +0 -9
- package/dist/features/invitations/invitation.connection-definition.js +0 -40
- package/dist/features/invitations/invitation.connection-definition.js.map +0 -1
- package/dist/features/invitations/invitation.resolver.d.ts +0 -67
- package/dist/features/invitations/invitation.resolver.js +0 -169
- package/dist/features/invitations/invitation.resolver.js.map +0 -1
- package/dist/features/invitations/invitation.service.d.ts +0 -120
- package/dist/features/invitations/invitation.service.js +0 -444
- package/dist/features/invitations/invitation.service.js.map +0 -1
- package/dist/features/invitations/reject-invitation-payload.object.d.ts +0 -5
- package/dist/features/invitations/reject-invitation-payload.object.js +0 -24
- package/dist/features/invitations/reject-invitation-payload.object.js.map +0 -1
- package/dist/infrastructure/api-key-authentication.service.d.ts +0 -30
- package/dist/infrastructure/api-key-authentication.service.js +0 -111
- package/dist/infrastructure/api-key-authentication.service.js.map +0 -1
- package/dist/infrastructure/api-key-lifecycle.d.ts +0 -53
- package/dist/infrastructure/api-key-lifecycle.js +0 -96
- package/dist/infrastructure/api-key-lifecycle.js.map +0 -1
- package/dist/infrastructure/auth-ability.factory.d.ts +0 -21
- package/dist/infrastructure/auth-ability.factory.js +0 -128
- package/dist/infrastructure/auth-ability.factory.js.map +0 -1
- package/dist/infrastructure/auth-enum-registry.d.ts +0 -11
- package/dist/infrastructure/auth-enum-registry.js +0 -58
- package/dist/infrastructure/auth-enum-registry.js.map +0 -1
- package/dist/infrastructure/auth-service.providers.d.ts +0 -6
- package/dist/infrastructure/auth-service.providers.js +0 -73
- package/dist/infrastructure/auth-service.providers.js.map +0 -1
- package/dist/infrastructure/better-auth-adapter.js.map +0 -1
- package/dist/infrastructure/create-auth-instance.d.ts +0 -28
- package/dist/infrastructure/create-auth-instance.js +0 -132
- package/dist/infrastructure/create-auth-instance.js.map +0 -1
- package/dist/infrastructure/create-contextual-auth-service.d.ts +0 -14
- package/dist/infrastructure/create-contextual-auth-service.js +0 -54
- package/dist/infrastructure/create-contextual-auth-service.js.map +0 -1
- package/dist/infrastructure/request-identity.d.ts +0 -117
- package/dist/infrastructure/request-identity.js +0 -280
- package/dist/infrastructure/request-identity.js.map +0 -1
- package/dist/infrastructure/revoked-authentication.exception.js.map +0 -1
- package/dist/inputs/add-member.input.d.ts +0 -16
- package/dist/inputs/add-member.input.js +0 -57
- package/dist/inputs/add-member.input.js.map +0 -1
- package/dist/inputs/auth-change-email.input.js.map +0 -1
- package/dist/inputs/auth-change-password.input.js.map +0 -1
- package/dist/inputs/auth-delete-user.input.js.map +0 -1
- package/dist/inputs/auth-link-social-account.input.js.map +0 -1
- package/dist/inputs/auth-request-password-reset.input.js.map +0 -1
- package/dist/inputs/auth-reset-password.input.js.map +0 -1
- package/dist/inputs/auth-send-verification-email.input.js.map +0 -1
- package/dist/inputs/auth-sign-in-social.input.js.map +0 -1
- package/dist/inputs/auth-sign-in.input.js.map +0 -1
- package/dist/inputs/auth-sign-up.input.js.map +0 -1
- package/dist/inputs/auth-update-user.input.js.map +0 -1
- package/dist/inputs/ban-user.input.js.map +0 -1
- package/dist/inputs/create-member-api-key.input.d.ts +0 -16
- package/dist/inputs/create-member-api-key.input.js +0 -62
- package/dist/inputs/create-member-api-key.input.js.map +0 -1
- package/dist/inputs/create-user-api-key.input.js.map +0 -1
- package/dist/inputs/create-user.input.d.ts +0 -15
- package/dist/inputs/create-user.input.js +0 -56
- package/dist/inputs/create-user.input.js.map +0 -1
- package/dist/inputs/create-workspace.input.js.map +0 -1
- package/dist/inputs/set-member-permissions.input.d.ts +0 -6
- package/dist/inputs/set-member-permissions.input.js +0 -27
- package/dist/inputs/set-member-permissions.input.js.map +0 -1
- package/dist/inputs/set-member-roles.input.d.ts +0 -6
- package/dist/inputs/set-member-roles.input.js +0 -27
- package/dist/inputs/set-member-roles.input.js.map +0 -1
- package/dist/inputs/set-user-password.input.js.map +0 -1
- package/dist/inputs/set-user-permissions.input.d.ts +0 -6
- package/dist/inputs/set-user-permissions.input.js +0 -27
- package/dist/inputs/set-user-permissions.input.js.map +0 -1
- package/dist/inputs/set-user-roles.input.d.ts +0 -6
- package/dist/inputs/set-user-roles.input.js +0 -27
- package/dist/inputs/set-user-roles.input.js.map +0 -1
- package/dist/inputs/update-member-api-key.input.d.ts +0 -14
- package/dist/inputs/update-member-api-key.input.js +0 -50
- package/dist/inputs/update-member-api-key.input.js.map +0 -1
- package/dist/inputs/update-member.input.d.ts +0 -10
- package/dist/inputs/update-member.input.js +0 -43
- package/dist/inputs/update-member.input.js.map +0 -1
- package/dist/inputs/update-user-api-key.input.d.ts +0 -14
- package/dist/inputs/update-user-api-key.input.js +0 -50
- package/dist/inputs/update-user-api-key.input.js.map +0 -1
- package/dist/inputs/update-user.input.js.map +0 -1
- package/dist/inputs/update-workspace.input.js.map +0 -1
- package/dist/inputs/user-id.input.js.map +0 -1
- package/dist/interfaces/ability-context.interface.d.ts +0 -16
- package/dist/interfaces/ability-context.interface.js.map +0 -1
- package/dist/interfaces/ability-rules.interface.js.map +0 -1
- package/dist/interfaces/add-member-options.interface.d.ts +0 -7
- package/dist/interfaces/add-member-options.interface.js +0 -2
- package/dist/interfaces/add-member-options.interface.js.map +0 -1
- package/dist/interfaces/auth-access-token.interface.js.map +0 -1
- package/dist/interfaces/auth-account-info.interface.js.map +0 -1
- package/dist/interfaces/auth-account.interface.js.map +0 -1
- package/dist/interfaces/auth-change-email-confirmation-data.interface.js.map +0 -1
- package/dist/interfaces/auth-delete-account-verification-data.interface.js.map +0 -1
- package/dist/interfaces/auth-email-verification-data.interface.js.map +0 -1
- package/dist/interfaces/auth-module-account-linking-options.interface.js.map +0 -1
- package/dist/interfaces/auth-module-account-options.interface.js.map +0 -1
- package/dist/interfaces/auth-module-api-key-options.interface.d.ts +0 -8
- package/dist/interfaces/auth-module-api-key-options.interface.js.map +0 -1
- package/dist/interfaces/auth-module-api-key-scope-options.interface.d.ts +0 -9
- package/dist/interfaces/auth-module-api-key-scope-options.interface.js.map +0 -1
- package/dist/interfaces/auth-module-change-email-options.interface.js.map +0 -1
- package/dist/interfaces/auth-module-delete-user-options.interface.js.map +0 -1
- package/dist/interfaces/auth-module-email-and-password-options.interface.js.map +0 -1
- package/dist/interfaces/auth-module-email-verification-options.interface.js.map +0 -1
- package/dist/interfaces/auth-module-middleware-options.interface.js.map +0 -1
- package/dist/interfaces/auth-module-oauth-provider.interface.js.map +0 -1
- package/dist/interfaces/auth-module-password-options.interface.js.map +0 -1
- package/dist/interfaces/auth-module-session-cookie-cache-options.interface.js.map +0 -1
- package/dist/interfaces/auth-module-session-cookie-cache-refresh-options.interface.js.map +0 -1
- package/dist/interfaces/auth-module-session-options.interface.js.map +0 -1
- package/dist/interfaces/auth-module-social-provider.interface.js.map +0 -1
- package/dist/interfaces/auth-module-user-options.interface.js.map +0 -1
- package/dist/interfaces/auth-module-workspace-options.interface.d.ts +0 -16
- package/dist/interfaces/auth-module-workspace-options.interface.js.map +0 -1
- package/dist/interfaces/auth-oauth-basic-token-endpoint-auth.interface.js.map +0 -1
- package/dist/interfaces/auth-oauth-client-assertion-context.interface.js.map +0 -1
- package/dist/interfaces/auth-oauth-custom-token-endpoint-auth.interface.js.map +0 -1
- package/dist/interfaces/auth-oauth-mapped-user.interface.js.map +0 -1
- package/dist/interfaces/auth-oauth-no-token-endpoint-auth.interface.js.map +0 -1
- package/dist/interfaces/auth-oauth-post-token-endpoint-auth.interface.js.map +0 -1
- package/dist/interfaces/auth-oauth-private-key-jwt-token-endpoint-auth.interface.js.map +0 -1
- package/dist/interfaces/auth-oauth-profile.interface.js.map +0 -1
- package/dist/interfaces/auth-oauth-refresh-context.interface.js.map +0 -1
- package/dist/interfaces/auth-oauth-token-request-client-options.interface.js.map +0 -1
- package/dist/interfaces/auth-oauth-token-request-context.interface.js.map +0 -1
- package/dist/interfaces/auth-oauth-tokens.interface.js.map +0 -1
- package/dist/interfaces/auth-oauth-user-info.interface.js.map +0 -1
- package/dist/interfaces/auth-provider-user-info.interface.js.map +0 -1
- package/dist/interfaces/auth-refreshed-token.interface.js.map +0 -1
- package/dist/interfaces/auth-reset-password-data.interface.js.map +0 -1
- package/dist/interfaces/auth-social-provider-user-info.interface.js.map +0 -1
- package/dist/interfaces/auth-social-provider.interface.js.map +0 -1
- package/dist/interfaces/auth-user.interface.js.map +0 -1
- package/dist/interfaces/authenticated-session.interface.js.map +0 -1
- package/dist/interfaces/ban-user-options.interface.js.map +0 -1
- package/dist/interfaces/can-metadata.interface.d.ts +0 -9
- package/dist/interfaces/can-metadata.interface.js.map +0 -1
- package/dist/interfaces/change-auth-email-options.interface.js.map +0 -1
- package/dist/interfaces/change-auth-password-options.interface.js.map +0 -1
- package/dist/interfaces/change-auth-password-result.interface.js.map +0 -1
- package/dist/interfaces/create-api-key-options.interface.js.map +0 -1
- package/dist/interfaces/create-member-api-key-options.interface.d.ts +0 -7
- package/dist/interfaces/create-member-api-key-options.interface.js +0 -2
- package/dist/interfaces/create-member-api-key-options.interface.js.map +0 -1
- package/dist/interfaces/create-user-options.interface.js.map +0 -1
- package/dist/interfaces/create-workspace-options.interface.js.map +0 -1
- package/dist/interfaces/created-api-key.interface.d.ts +0 -8
- package/dist/interfaces/created-api-key.interface.js.map +0 -1
- package/dist/interfaces/delete-auth-user-options.interface.js.map +0 -1
- package/dist/interfaces/delete-auth-user-result.interface.js.map +0 -1
- package/dist/interfaces/impersonation-options.interface.js.map +0 -1
- package/dist/interfaces/link-auth-social-account-options.interface.js.map +0 -1
- package/dist/interfaces/link-auth-social-account-result.interface.js.map +0 -1
- package/dist/interfaces/member-api-key-validation.interface.d.ts +0 -17
- package/dist/interfaces/member-api-key-validation.interface.js +0 -2
- package/dist/interfaces/member-api-key-validation.interface.js.map +0 -1
- package/dist/interfaces/request-identity-patch.interface.d.ts +0 -16
- package/dist/interfaces/request-identity-patch.interface.js +0 -2
- package/dist/interfaces/request-identity-patch.interface.js.map +0 -1
- package/dist/interfaces/request-password-reset-options.interface.js.map +0 -1
- package/dist/interfaces/request-password-reset-result.interface.js.map +0 -1
- package/dist/interfaces/request-permissions.interface.js.map +0 -1
- package/dist/interfaces/reset-password-options.interface.js.map +0 -1
- package/dist/interfaces/route-argument-metadata-value.interface.js.map +0 -1
- package/dist/interfaces/scope-policy-options.interface.js.map +0 -1
- package/dist/interfaces/send-verification-email-options.interface.js.map +0 -1
- package/dist/interfaces/serialized-ability-rule.interface.js.map +0 -1
- package/dist/interfaces/sign-in-entity-result.interface.js.map +0 -1
- package/dist/interfaces/sign-in-options.interface.js.map +0 -1
- package/dist/interfaces/sign-in-result.interface.js.map +0 -1
- package/dist/interfaces/sign-in-social-entity-result.interface.js.map +0 -1
- package/dist/interfaces/sign-in-social-options.interface.js.map +0 -1
- package/dist/interfaces/sign-in-social-result.interface.js.map +0 -1
- package/dist/interfaces/sign-up-options.interface.js.map +0 -1
- package/dist/interfaces/sign-up-result.interface.js.map +0 -1
- package/dist/interfaces/unlink-auth-account-options.interface.js.map +0 -1
- package/dist/interfaces/update-api-key-options.interface.d.ts +0 -14
- package/dist/interfaces/update-api-key-options.interface.js.map +0 -1
- package/dist/interfaces/update-auth-user-options.interface.js.map +0 -1
- package/dist/interfaces/update-member-options.interface.d.ts +0 -10
- package/dist/interfaces/update-member-options.interface.js +0 -2
- package/dist/interfaces/update-member-options.interface.js.map +0 -1
- package/dist/interfaces/update-user-options.interface.js.map +0 -1
- package/dist/interfaces/update-workspace-options.interface.js.map +0 -1
- package/dist/interfaces/user-api-key-validation.interface.d.ts +0 -11
- package/dist/interfaces/user-api-key-validation.interface.js.map +0 -1
- package/dist/interfaces/user-has-permissions-options.interface.js.map +0 -1
- package/dist/interfaces/workspace-has-permissions-options.interface.js.map +0 -1
- package/dist/objects/add-member-payload.object.d.ts +0 -5
- package/dist/objects/add-member-payload.object.js +0 -24
- package/dist/objects/add-member-payload.object.js.map +0 -1
- package/dist/objects/auth-ability-rule.object.js.map +0 -1
- package/dist/objects/auth-change-password-result.object.js.map +0 -1
- package/dist/objects/auth-delete-user-result.object.js.map +0 -1
- package/dist/objects/auth-link-social-account-result.object.js.map +0 -1
- package/dist/objects/auth-request-password-reset-result.object.js.map +0 -1
- package/dist/objects/auth-sign-in-result.object.js.map +0 -1
- package/dist/objects/auth-sign-in-social-result.object.js.map +0 -1
- package/dist/objects/auth-social-provider.object.js.map +0 -1
- package/dist/objects/ban-user-payload.object.js.map +0 -1
- package/dist/objects/create-member-api-key-result.object.d.ts +0 -10
- package/dist/objects/create-member-api-key-result.object.js +0 -33
- package/dist/objects/create-member-api-key-result.object.js.map +0 -1
- package/dist/objects/create-user-api-key-result.object.d.ts +0 -10
- package/dist/objects/create-user-api-key-result.object.js +0 -33
- package/dist/objects/create-user-api-key-result.object.js.map +0 -1
- package/dist/objects/create-user-payload.object.js.map +0 -1
- package/dist/objects/create-workspace-payload.object.js.map +0 -1
- package/dist/objects/delete-user-payload.object.js.map +0 -1
- package/dist/objects/delete-workspace-payload.object.js.map +0 -1
- package/dist/objects/leave-workspace-payload.object.js.map +0 -1
- package/dist/objects/member-api-key-permission-option.object.d.ts +0 -10
- package/dist/objects/member-api-key-permission-option.object.js +0 -37
- package/dist/objects/member-api-key-permission-option.object.js.map +0 -1
- package/dist/objects/password-policy.object.js.map +0 -1
- package/dist/objects/remove-member-payload.object.d.ts +0 -5
- package/dist/objects/remove-member-payload.object.js +0 -24
- package/dist/objects/remove-member-payload.object.js.map +0 -1
- package/dist/objects/set-member-permissions-payload.object.d.ts +0 -5
- package/dist/objects/set-member-permissions-payload.object.js +0 -24
- package/dist/objects/set-member-permissions-payload.object.js.map +0 -1
- package/dist/objects/set-member-roles-payload.object.d.ts +0 -5
- package/dist/objects/set-member-roles-payload.object.js +0 -24
- package/dist/objects/set-member-roles-payload.object.js.map +0 -1
- package/dist/objects/set-user-permissions-payload.object.js.map +0 -1
- package/dist/objects/set-user-roles-payload.object.js.map +0 -1
- package/dist/objects/sign-up-payload.object.js.map +0 -1
- package/dist/objects/unban-user-payload.object.js.map +0 -1
- package/dist/objects/update-member-payload.object.d.ts +0 -5
- package/dist/objects/update-member-payload.object.js +0 -24
- package/dist/objects/update-member-payload.object.js.map +0 -1
- package/dist/objects/update-user-payload.object.js.map +0 -1
- package/dist/objects/update-workspace-payload.object.js.map +0 -1
- package/dist/objects/user-api-key-permission-option.object.js.map +0 -1
- package/dist/objects/user-permission-option.object.d.ts +0 -8
- package/dist/objects/user-permission-option.object.js +0 -31
- package/dist/objects/user-permission-option.object.js.map +0 -1
- package/dist/objects/user-role-option.object.d.ts +0 -8
- package/dist/objects/user-role-option.object.js +0 -31
- package/dist/objects/user-role-option.object.js.map +0 -1
- package/dist/objects/workspace-permission-option.object.js.map +0 -1
- package/dist/objects/workspace-role-option.object.js.map +0 -1
- package/dist/permission.constants.js.map +0 -1
- package/dist/policies/create-scope-policy.js.map +0 -1
- package/dist/policies/index.js.map +0 -1
- package/dist/policies/user-scope.policy.js.map +0 -1
- package/dist/policies/workspace-scope.policy.js.map +0 -1
- package/dist/resolvers/auth.resolver.js +0 -352
- package/dist/resolvers/auth.resolver.js.map +0 -1
- package/dist/resolvers/member-api-key.resolver.d.ts +0 -46
- package/dist/resolvers/member-api-key.resolver.js +0 -109
- package/dist/resolvers/member-api-key.resolver.js.map +0 -1
- package/dist/resolvers/member.resolver.d.ts +0 -88
- package/dist/resolvers/member.resolver.js +0 -216
- package/dist/resolvers/member.resolver.js.map +0 -1
- package/dist/resolvers/session.resolver.d.ts +0 -80
- package/dist/resolvers/session.resolver.js +0 -203
- package/dist/resolvers/session.resolver.js.map +0 -1
- package/dist/resolvers/user-api-key.resolver.d.ts +0 -46
- package/dist/resolvers/user-api-key.resolver.js +0 -105
- package/dist/resolvers/user-api-key.resolver.js.map +0 -1
- package/dist/resolvers/user.resolver.d.ts +0 -172
- package/dist/resolvers/user.resolver.js +0 -390
- package/dist/resolvers/user.resolver.js.map +0 -1
- package/dist/resolvers/workspace.resolver.d.ts +0 -104
- package/dist/resolvers/workspace.resolver.js +0 -236
- package/dist/resolvers/workspace.resolver.js.map +0 -1
- package/dist/services/account.service.js +0 -63
- package/dist/services/account.service.js.map +0 -1
- package/dist/services/auth.service.js +0 -443
- package/dist/services/auth.service.js.map +0 -1
- package/dist/services/member-api-key.service.d.ts +0 -76
- package/dist/services/member-api-key.service.js +0 -264
- package/dist/services/member-api-key.service.js.map +0 -1
- package/dist/services/member.service.d.ts +0 -165
- package/dist/services/member.service.js +0 -519
- package/dist/services/member.service.js.map +0 -1
- package/dist/services/session.service.d.ts +0 -83
- package/dist/services/session.service.js +0 -377
- package/dist/services/session.service.js.map +0 -1
- package/dist/services/user-api-key.service.d.ts +0 -74
- package/dist/services/user-api-key.service.js +0 -231
- package/dist/services/user-api-key.service.js.map +0 -1
- package/dist/services/user-deletion.service.d.ts +0 -21
- package/dist/services/user-deletion.service.js +0 -56
- package/dist/services/user-deletion.service.js.map +0 -1
- package/dist/services/user.service.d.ts +0 -172
- package/dist/services/user.service.js +0 -579
- package/dist/services/user.service.js.map +0 -1
- package/dist/services/workspace.service.d.ts +0 -78
- package/dist/services/workspace.service.js +0 -240
- package/dist/services/workspace.service.js.map +0 -1
- package/dist/types/api-key-metadata.type.d.ts +0 -6
- package/dist/types/api-key-metadata.type.js +0 -2
- package/dist/types/api-key-metadata.type.js.map +0 -1
- package/dist/types/api-key-validation.type.d.ts +0 -4
- package/dist/types/api-key-validation.type.js.map +0 -1
- package/dist/types/api-key.type.d.ts +0 -4
- package/dist/types/api-key.type.js +0 -2
- package/dist/types/api-key.type.js.map +0 -1
- package/dist/types/auth-account-selector.type.js.map +0 -1
- package/dist/types/auth-maybe-promise.type.js.map +0 -1
- package/dist/types/auth-module-provider.type.js.map +0 -1
- package/dist/types/auth-module-roles.type.js.map +0 -1
- package/dist/types/auth-module-social-provider-id.type.js.map +0 -1
- package/dist/types/auth-oauth-token-endpoint-auth.type.js.map +0 -1
- package/dist/types/auth-send-reset-password.type.js.map +0 -1
- package/dist/types/auth-send-verification-email.type.js.map +0 -1
- package/dist/types/build-ability-callback.type.d.ts +0 -4
- package/dist/types/build-ability-callback.type.js.map +0 -1
- package/dist/types/can-subject-callback.type.js.map +0 -1
- package/dist/types/lowercase-identifier.type.js.map +0 -1
- package/dist/types/permission-name.type.js.map +0 -1
- package/dist/types/role-name.type.js.map +0 -1
- package/dist/types/route-argument-metadata.type.d.ts +0 -3
- package/dist/types/route-argument-metadata.type.js.map +0 -1
- package/dist/user.constants.d.ts +0 -13
- package/dist/user.constants.js +0 -31
- package/dist/user.constants.js.map +0 -1
- package/dist/utils/api-key-credential.util.js.map +0 -1
- package/dist/utils/api-key-permissions.util.d.ts +0 -21
- package/dist/utils/api-key-permissions.util.js +0 -47
- package/dist/utils/api-key-permissions.util.js.map +0 -1
- package/dist/utils/append-metadata.util.js.map +0 -1
- package/dist/utils/apply-auth-response-cookies.util.js +0 -17
- package/dist/utils/apply-auth-response-cookies.util.js.map +0 -1
- package/dist/utils/auth-role.util.js.map +0 -1
- package/dist/utils/authorize.util.js.map +0 -1
- package/dist/utils/build-request-ability.util.d.ts +0 -8
- package/dist/utils/build-request-ability.util.js +0 -29
- package/dist/utils/build-request-ability.util.js.map +0 -1
- package/dist/utils/can.util.js.map +0 -1
- package/dist/utils/create-email-and-password-config.d.ts +0 -16
- package/dist/utils/create-email-and-password-config.js.map +0 -1
- package/dist/utils/create-email-verification-config.d.ts +0 -13
- package/dist/utils/create-email-verification-config.js.map +0 -1
- package/dist/utils/create-generic-oauth-config.js.map +0 -1
- package/dist/utils/create-oidc-config.js.map +0 -1
- package/dist/utils/create-permission-enum.util.js.map +0 -1
- package/dist/utils/create-social-provider-config.js.map +0 -1
- package/dist/utils/create-social-providers-config.js.map +0 -1
- package/dist/utils/create-user-config.js +0 -55
- package/dist/utils/create-user-config.js.map +0 -1
- package/dist/utils/estimate-entropy.js +0 -13
- package/dist/utils/estimate-entropy.js.map +0 -1
- package/dist/utils/extend-ability.util.js +0 -92
- package/dist/utils/extend-ability.util.js.map +0 -1
- package/dist/utils/extract-api-key.util.js.map +0 -1
- package/dist/utils/generic-oauth-provider-config.type.js.map +0 -1
- package/dist/utils/get-auth-ability.util.js +0 -20
- package/dist/utils/get-auth-ability.util.js.map +0 -1
- package/dist/utils/get-current-api-key.util.d.ts +0 -7
- package/dist/utils/get-current-api-key.util.js +0 -13
- package/dist/utils/get-current-api-key.util.js.map +0 -1
- package/dist/utils/has-oidc-env-config.d.ts +0 -5
- package/dist/utils/has-oidc-env-config.js +0 -9
- package/dist/utils/has-oidc-env-config.js.map +0 -1
- package/dist/utils/has-social-provider-credential-env-config.js.map +0 -1
- package/dist/utils/has-social-provider-env-config.d.ts +0 -7
- package/dist/utils/has-social-provider-env-config.js +0 -10
- package/dist/utils/has-social-provider-env-config.js.map +0 -1
- package/dist/utils/is-env-true.js.map +0 -1
- package/dist/utils/oidc.constants.d.ts +0 -5
- package/dist/utils/oidc.constants.js +0 -24
- package/dist/utils/oidc.constants.js.map +0 -1
- package/dist/utils/omit-credentials.util.js +0 -16
- package/dist/utils/omit-credentials.util.js.map +0 -1
- package/dist/utils/permission-grants.util.d.ts +0 -33
- package/dist/utils/permission-grants.util.js +0 -51
- package/dist/utils/permission-grants.util.js.map +0 -1
- package/dist/utils/resolve-auth-catalog.util.d.ts +0 -12
- package/dist/utils/resolve-auth-catalog.util.js +0 -49
- package/dist/utils/resolve-auth-catalog.util.js.map +0 -1
- package/dist/utils/resolve-effective-permissions.util.d.ts +0 -27
- package/dist/utils/resolve-effective-permissions.util.js +0 -36
- package/dist/utils/resolve-effective-permissions.util.js.map +0 -1
- package/dist/utils/resolve-oidc-prompt.js.map +0 -1
- package/dist/utils/resolve-oidc-scopes.js.map +0 -1
- package/dist/utils/resolve-request-member.util.d.ts +0 -7
- package/dist/utils/resolve-request-member.util.js +0 -27
- package/dist/utils/resolve-request-member.util.js.map +0 -1
- package/dist/utils/resolve-request-permissions.util.d.ts +0 -14
- package/dist/utils/resolve-request-permissions.util.js +0 -47
- package/dist/utils/resolve-request-permissions.util.js.map +0 -1
- package/dist/utils/resolve-required-oidc-env.js.map +0 -1
- package/dist/utils/resolve-required-social-provider-env.js.map +0 -1
- package/dist/utils/resolve-secret.d.ts +0 -7
- package/dist/utils/resolve-secret.js.map +0 -1
- package/dist/utils/resolve-social-provider-enabled.js.map +0 -1
- package/dist/utils/run-auth-query.js +0 -54
- package/dist/utils/run-auth-query.js.map +0 -1
- package/dist/utils/serialize-ability-rules.util.js +0 -38
- package/dist/utils/serialize-ability-rules.util.js.map +0 -1
- package/dist/utils/social-provider.constants.d.ts +0 -22
- package/dist/utils/social-provider.constants.js +0 -31
- package/dist/utils/social-provider.constants.js.map +0 -1
- package/dist/utils/split-auth-providers.js.map +0 -1
- package/dist/with-auth-database-config.d.ts +0 -9
- package/dist/with-auth-database-config.js +0 -21
- package/dist/with-auth-database-config.js.map +0 -1
- package/dist/workspace.constants.d.ts +0 -15
- package/dist/workspace.constants.js +0 -39
- package/dist/workspace.constants.js.map +0 -1
- /package/dist/{inputs → admin/inputs}/ban-user.input.d.ts +0 -0
- /package/dist/{inputs → admin/inputs}/ban-user.input.js +0 -0
- /package/dist/{inputs → admin/inputs}/set-user-password.input.d.ts +0 -0
- /package/dist/{inputs → admin/inputs}/set-user-password.input.js +0 -0
- /package/dist/{inputs → admin/inputs}/update-user.input.d.ts +0 -0
- /package/dist/{inputs → admin/inputs}/update-user.input.js +0 -0
- /package/dist/{inputs → admin/inputs}/user-id.input.d.ts +0 -0
- /package/dist/{inputs → admin/inputs}/user-id.input.js +0 -0
- /package/dist/{interfaces → admin/interfaces}/ban-user-options.interface.d.ts +0 -0
- /package/dist/{interfaces → admin/interfaces}/ban-user-options.interface.js +0 -0
- /package/dist/{interfaces → admin/interfaces}/create-user-options.interface.d.ts +0 -0
- /package/dist/{interfaces → admin/interfaces}/create-user-options.interface.js +0 -0
- /package/dist/{interfaces → admin/interfaces}/impersonation-options.interface.d.ts +0 -0
- /package/dist/{interfaces → admin/interfaces}/impersonation-options.interface.js +0 -0
- /package/dist/{interfaces → admin/interfaces}/update-user-options.interface.d.ts +0 -0
- /package/dist/{interfaces → admin/interfaces}/update-user-options.interface.js +0 -0
- /package/dist/{objects → admin/objects}/ban-user-payload.object.d.ts +0 -0
- /package/dist/{objects → admin/objects}/ban-user-payload.object.js +0 -0
- /package/dist/{objects → admin/objects}/create-user-payload.object.d.ts +0 -0
- /package/dist/{objects → admin/objects}/create-user-payload.object.js +0 -0
- /package/dist/{objects → admin/objects}/delete-user-payload.object.d.ts +0 -0
- /package/dist/{objects → admin/objects}/delete-user-payload.object.js +0 -0
- /package/dist/{objects → admin/objects}/set-user-permissions-payload.object.d.ts +0 -0
- /package/dist/{objects → admin/objects}/set-user-permissions-payload.object.js +0 -0
- /package/dist/{objects → admin/objects}/set-user-roles-payload.object.d.ts +0 -0
- /package/dist/{objects → admin/objects}/set-user-roles-payload.object.js +0 -0
- /package/dist/{objects → admin/objects}/unban-user-payload.object.d.ts +0 -0
- /package/dist/{objects → admin/objects}/unban-user-payload.object.js +0 -0
- /package/dist/{objects → admin/objects}/update-user-payload.object.d.ts +0 -0
- /package/dist/{objects → admin/objects}/update-user-payload.object.js +0 -0
- /package/dist/{decorators → api-key/decorators}/current-api-key.decorator.d.ts +0 -0
- /package/dist/{decorators → api-key/decorators}/current-api-key.decorator.js +0 -0
- /package/dist/{enums → api-key/enums}/user-api-key-permission.enum.d.ts +0 -0
- /package/dist/{inputs → api-key/inputs}/create-user-api-key.input.d.ts +0 -0
- /package/dist/{inputs → api-key/inputs}/create-user-api-key.input.js +0 -0
- /package/dist/{interfaces → api-key/interfaces}/auth-module-api-key-options.interface.js +0 -0
- /package/dist/{interfaces → api-key/interfaces}/auth-module-api-key-scope-options.interface.js +0 -0
- /package/dist/{interfaces → api-key/interfaces}/create-api-key-options.interface.d.ts +0 -0
- /package/dist/{interfaces → api-key/interfaces}/create-api-key-options.interface.js +0 -0
- /package/dist/{interfaces → api-key/interfaces}/created-api-key.interface.js +0 -0
- /package/dist/{interfaces → api-key/interfaces}/update-api-key-options.interface.js +0 -0
- /package/dist/{interfaces → api-key/interfaces}/user-api-key-validation.interface.js +0 -0
- /package/dist/{objects → api-key/objects}/user-api-key-permission-option.object.d.ts +0 -0
- /package/dist/{objects → api-key/objects}/user-api-key-permission-option.object.js +0 -0
- /package/dist/{types → api-key/types}/api-key-validation.type.js +0 -0
- /package/dist/{utils → api-key/utils}/api-key-credential.util.d.ts +0 -0
- /package/dist/{utils → api-key/utils}/api-key-credential.util.js +0 -0
- /package/dist/{utils → api-key/utils}/extract-api-key.util.d.ts +0 -0
- /package/dist/{utils → api-key/utils}/extract-api-key.util.js +0 -0
- /package/dist/{permission.constants.d.ts → common/constants/permission.constants.d.ts} +0 -0
- /package/dist/{permission.constants.js → common/constants/permission.constants.js} +0 -0
- /package/dist/{interfaces → common/interfaces}/ability-context.interface.js +0 -0
- /package/dist/{interfaces → common/interfaces}/ability-rules.interface.d.ts +0 -0
- /package/dist/{interfaces → common/interfaces}/ability-rules.interface.js +0 -0
- /package/dist/{interfaces → common/interfaces}/can-metadata.interface.js +0 -0
- /package/dist/{interfaces → common/interfaces}/request-permissions.interface.d.ts +0 -0
- /package/dist/{interfaces → common/interfaces}/request-permissions.interface.js +0 -0
- /package/dist/{interfaces → common/interfaces}/route-argument-metadata-value.interface.d.ts +0 -0
- /package/dist/{interfaces → common/interfaces}/route-argument-metadata-value.interface.js +0 -0
- /package/dist/{interfaces → common/interfaces}/scope-policy-options.interface.d.ts +0 -0
- /package/dist/{interfaces → common/interfaces}/scope-policy-options.interface.js +0 -0
- /package/dist/{interfaces → common/interfaces}/serialized-ability-rule.interface.d.ts +0 -0
- /package/dist/{interfaces → common/interfaces}/serialized-ability-rule.interface.js +0 -0
- /package/dist/{policies → common/policies}/create-scope-policy.d.ts +0 -0
- /package/dist/{policies → common/policies}/create-scope-policy.js +0 -0
- /package/dist/{policies → common/policies}/index.d.ts +0 -0
- /package/dist/{policies → common/policies}/index.js +0 -0
- /package/dist/{policies → common/policies}/user-scope.policy.d.ts +0 -0
- /package/dist/{policies → common/policies}/user-scope.policy.js +0 -0
- /package/dist/{policies → common/policies}/workspace-scope.policy.d.ts +0 -0
- /package/dist/{policies → common/policies}/workspace-scope.policy.js +0 -0
- /package/dist/{utils → common/utils}/append-metadata.util.d.ts +0 -0
- /package/dist/{utils → common/utils}/append-metadata.util.js +0 -0
- /package/dist/{utils → common/utils}/authorize.util.d.ts +0 -0
- /package/dist/{utils → common/utils}/authorize.util.js +0 -0
- /package/dist/{utils → common/utils}/can.util.d.ts +0 -0
- /package/dist/{utils → common/utils}/can.util.js +0 -0
- /package/dist/{utils → common/utils}/create-permission-enum.util.d.ts +0 -0
- /package/dist/{utils → common/utils}/create-permission-enum.util.js +0 -0
- /package/dist/{utils → common/utils}/extend-ability.util.d.ts +0 -0
- /package/dist/{utils → common/utils}/get-auth-ability.util.d.ts +0 -0
- /package/dist/{utils → common/utils}/omit-credentials.util.d.ts +0 -0
- /package/dist/{utils → common/utils}/run-auth-query.d.ts +0 -0
- /package/dist/{utils → common/utils}/serialize-ability-rules.util.d.ts +0 -0
- /package/dist/{adapters → core/adapters}/mikro-orm/adapter-config.d.ts +0 -0
- /package/dist/{adapters → core/adapters}/mikro-orm/adapter-config.js +0 -0
- /package/dist/{adapters → core/adapters}/mikro-orm/create-custom-adapter.d.ts +0 -0
- /package/dist/{adapters → core/adapters}/mikro-orm/entity-metadata-resolver.d.ts +0 -0
- /package/dist/{adapters → core/adapters}/mikro-orm/where-compiler.d.ts +0 -0
- /package/dist/{adapters → core/adapters}/mikro-orm-adapter.d.ts +0 -0
- /package/dist/{auth-handler.middleware.d.ts → core/auth-handler.middleware.d.ts} +0 -0
- /package/dist/{auth.module-definition.js → core/auth.module-definition.js} +0 -0
- /package/dist/{infrastructure → core}/better-auth-adapter.d.ts +0 -0
- /package/dist/{infrastructure → core}/better-auth-adapter.js +0 -0
- /package/dist/{connections → core/connections}/account.connection-definition.d.ts +0 -0
- /package/dist/{connections → core/connections}/account.connection-definition.js +0 -0
- /package/dist/{connections → core/connections}/session.connection-definition.d.ts +0 -0
- /package/dist/{connections → core/connections}/session.connection-definition.js +0 -0
- /package/dist/{connections → core/connections}/user.connection-definition.d.ts +0 -0
- /package/dist/{connections → core/connections}/user.connection-definition.js +0 -0
- /package/dist/{auth.constants.d.ts → core/constants/auth.constants.d.ts} +0 -0
- /package/dist/{auth.constants.js → core/constants/auth.constants.js} +0 -0
- /package/dist/{decorators → core/decorators}/current-session.decorator.d.ts +0 -0
- /package/dist/{decorators → core/decorators}/current-session.decorator.js +0 -0
- /package/dist/{decorators → core/decorators}/current-user.decorator.d.ts +0 -0
- /package/dist/{decorators → core/decorators}/current-user.decorator.js +0 -0
- /package/dist/{entities → core/entities}/account.entity.d.ts +0 -0
- /package/dist/{entities → core/entities}/session.entity.d.ts +0 -0
- /package/dist/{entities → core/entities}/session.entity.js +0 -0
- /package/dist/{entities → core/entities}/verification.entity.d.ts +0 -0
- /package/dist/{entities → core/entities}/verification.entity.js +0 -0
- /package/dist/{enums → core/enums}/user-permission.enum.d.ts +0 -0
- /package/dist/{enums → core/enums}/user-role.enum.d.ts +0 -0
- /package/dist/{inputs → core/inputs}/auth-change-email.input.d.ts +0 -0
- /package/dist/{inputs → core/inputs}/auth-change-email.input.js +0 -0
- /package/dist/{inputs → core/inputs}/auth-change-password.input.d.ts +0 -0
- /package/dist/{inputs → core/inputs}/auth-change-password.input.js +0 -0
- /package/dist/{inputs → core/inputs}/auth-delete-user.input.d.ts +0 -0
- /package/dist/{inputs → core/inputs}/auth-delete-user.input.js +0 -0
- /package/dist/{inputs → core/inputs}/auth-link-social-account.input.d.ts +0 -0
- /package/dist/{inputs → core/inputs}/auth-link-social-account.input.js +0 -0
- /package/dist/{inputs → core/inputs}/auth-request-password-reset.input.d.ts +0 -0
- /package/dist/{inputs → core/inputs}/auth-request-password-reset.input.js +0 -0
- /package/dist/{inputs → core/inputs}/auth-reset-password.input.d.ts +0 -0
- /package/dist/{inputs → core/inputs}/auth-reset-password.input.js +0 -0
- /package/dist/{inputs → core/inputs}/auth-send-verification-email.input.d.ts +0 -0
- /package/dist/{inputs → core/inputs}/auth-send-verification-email.input.js +0 -0
- /package/dist/{inputs → core/inputs}/auth-sign-in-social.input.d.ts +0 -0
- /package/dist/{inputs → core/inputs}/auth-sign-in-social.input.js +0 -0
- /package/dist/{inputs → core/inputs}/auth-sign-in.input.d.ts +0 -0
- /package/dist/{inputs → core/inputs}/auth-sign-in.input.js +0 -0
- /package/dist/{inputs → core/inputs}/auth-sign-up.input.d.ts +0 -0
- /package/dist/{inputs → core/inputs}/auth-sign-up.input.js +0 -0
- /package/dist/{inputs → core/inputs}/auth-update-user.input.d.ts +0 -0
- /package/dist/{inputs → core/inputs}/auth-update-user.input.js +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-access-token.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-access-token.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-account-info.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-account-info.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-account.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-account.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-change-email-confirmation-data.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-change-email-confirmation-data.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-delete-account-verification-data.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-delete-account-verification-data.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-email-verification-data.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-email-verification-data.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-module-account-linking-options.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-module-account-linking-options.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-module-account-options.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-module-account-options.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-module-change-email-options.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-module-change-email-options.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-module-delete-user-options.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-module-delete-user-options.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-module-email-and-password-options.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-module-email-and-password-options.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-module-email-verification-options.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-module-email-verification-options.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-module-middleware-options.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-module-middleware-options.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-module-oauth-provider.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-module-oauth-provider.interface.js +0 -0
- /package/dist/{auth-module-options.interface.js → core/interfaces/auth-module-options.interface.js} +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-module-password-options.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-module-password-options.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-module-session-cookie-cache-options.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-module-session-cookie-cache-options.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-module-session-cookie-cache-refresh-options.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-module-session-cookie-cache-refresh-options.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-module-session-options.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-module-session-options.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-module-social-provider.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-module-social-provider.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-module-user-options.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-module-user-options.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-oauth-basic-token-endpoint-auth.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-oauth-basic-token-endpoint-auth.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-oauth-client-assertion-context.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-oauth-client-assertion-context.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-oauth-custom-token-endpoint-auth.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-oauth-custom-token-endpoint-auth.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-oauth-mapped-user.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-oauth-mapped-user.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-oauth-no-token-endpoint-auth.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-oauth-no-token-endpoint-auth.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-oauth-post-token-endpoint-auth.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-oauth-post-token-endpoint-auth.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-oauth-private-key-jwt-token-endpoint-auth.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-oauth-private-key-jwt-token-endpoint-auth.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-oauth-profile.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-oauth-profile.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-oauth-refresh-context.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-oauth-refresh-context.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-oauth-token-request-client-options.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-oauth-token-request-client-options.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-oauth-token-request-context.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-oauth-token-request-context.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-oauth-tokens.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-oauth-tokens.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-oauth-user-info.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-oauth-user-info.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-provider-user-info.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-provider-user-info.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-refreshed-token.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-refreshed-token.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-reset-password-data.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-reset-password-data.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-social-provider-user-info.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-social-provider-user-info.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-social-provider.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-social-provider.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-user.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/auth-user.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/authenticated-session.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/authenticated-session.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/change-auth-email-options.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/change-auth-email-options.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/change-auth-password-options.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/change-auth-password-options.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/change-auth-password-result.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/change-auth-password-result.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/delete-auth-user-options.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/delete-auth-user-options.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/delete-auth-user-result.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/delete-auth-user-result.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/link-auth-social-account-options.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/link-auth-social-account-options.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/link-auth-social-account-result.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/link-auth-social-account-result.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/request-password-reset-options.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/request-password-reset-options.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/request-password-reset-result.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/request-password-reset-result.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/reset-password-options.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/reset-password-options.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/send-verification-email-options.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/send-verification-email-options.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/sign-in-entity-result.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/sign-in-entity-result.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/sign-in-options.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/sign-in-options.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/sign-in-result.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/sign-in-result.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/sign-in-social-entity-result.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/sign-in-social-entity-result.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/sign-in-social-options.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/sign-in-social-options.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/sign-in-social-result.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/sign-in-social-result.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/sign-up-options.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/sign-up-options.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/sign-up-result.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/sign-up-result.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/unlink-auth-account-options.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/unlink-auth-account-options.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/update-auth-user-options.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/update-auth-user-options.interface.js +0 -0
- /package/dist/{interfaces → core/interfaces}/user-has-permissions-options.interface.d.ts +0 -0
- /package/dist/{interfaces → core/interfaces}/user-has-permissions-options.interface.js +0 -0
- /package/dist/{objects → core/objects}/auth-ability-rule.object.d.ts +0 -0
- /package/dist/{objects → core/objects}/auth-ability-rule.object.js +0 -0
- /package/dist/{objects → core/objects}/auth-change-password-result.object.d.ts +0 -0
- /package/dist/{objects → core/objects}/auth-change-password-result.object.js +0 -0
- /package/dist/{objects → core/objects}/auth-delete-user-result.object.d.ts +0 -0
- /package/dist/{objects → core/objects}/auth-delete-user-result.object.js +0 -0
- /package/dist/{objects → core/objects}/auth-link-social-account-result.object.d.ts +0 -0
- /package/dist/{objects → core/objects}/auth-link-social-account-result.object.js +0 -0
- /package/dist/{objects → core/objects}/auth-request-password-reset-result.object.d.ts +0 -0
- /package/dist/{objects → core/objects}/auth-request-password-reset-result.object.js +0 -0
- /package/dist/{objects → core/objects}/auth-sign-in-result.object.d.ts +0 -0
- /package/dist/{objects → core/objects}/auth-sign-in-result.object.js +0 -0
- /package/dist/{objects → core/objects}/auth-sign-in-social-result.object.d.ts +0 -0
- /package/dist/{objects → core/objects}/auth-sign-in-social-result.object.js +0 -0
- /package/dist/{objects → core/objects}/auth-social-provider.object.d.ts +0 -0
- /package/dist/{objects → core/objects}/auth-social-provider.object.js +0 -0
- /package/dist/{objects → core/objects}/password-policy.object.d.ts +0 -0
- /package/dist/{objects → core/objects}/password-policy.object.js +0 -0
- /package/dist/{objects → core/objects}/sign-up-payload.object.d.ts +0 -0
- /package/dist/{objects → core/objects}/sign-up-payload.object.js +0 -0
- /package/dist/{resolvers → core/resolvers}/auth.resolver.d.ts +0 -0
- /package/dist/{infrastructure → core}/revoked-authentication.exception.d.ts +0 -0
- /package/dist/{infrastructure → core}/revoked-authentication.exception.js +0 -0
- /package/dist/{services → core/services}/account.service.d.ts +0 -0
- /package/dist/{services → core/services}/auth.service.d.ts +0 -0
- /package/dist/{types → core/types}/auth-account-selector.type.d.ts +0 -0
- /package/dist/{types → core/types}/auth-account-selector.type.js +0 -0
- /package/dist/{types → core/types}/auth-maybe-promise.type.d.ts +0 -0
- /package/dist/{types → core/types}/auth-maybe-promise.type.js +0 -0
- /package/dist/{types → core/types}/auth-module-provider.type.d.ts +0 -0
- /package/dist/{types → core/types}/auth-module-provider.type.js +0 -0
- /package/dist/{types → core/types}/auth-module-roles.type.d.ts +0 -0
- /package/dist/{types → core/types}/auth-module-roles.type.js +0 -0
- /package/dist/{types → core/types}/auth-module-social-provider-id.type.d.ts +0 -0
- /package/dist/{types → core/types}/auth-module-social-provider-id.type.js +0 -0
- /package/dist/{types → core/types}/auth-oauth-token-endpoint-auth.type.d.ts +0 -0
- /package/dist/{types → core/types}/auth-oauth-token-endpoint-auth.type.js +0 -0
- /package/dist/{types → core/types}/auth-send-reset-password.type.d.ts +0 -0
- /package/dist/{types → core/types}/auth-send-reset-password.type.js +0 -0
- /package/dist/{types → core/types}/auth-send-verification-email.type.d.ts +0 -0
- /package/dist/{types → core/types}/auth-send-verification-email.type.js +0 -0
- /package/dist/{types → core/types}/build-ability-callback.type.js +0 -0
- /package/dist/{types → core/types}/can-subject-callback.type.d.ts +0 -0
- /package/dist/{types → core/types}/can-subject-callback.type.js +0 -0
- /package/dist/{types → core/types}/lowercase-identifier.type.d.ts +0 -0
- /package/dist/{types → core/types}/lowercase-identifier.type.js +0 -0
- /package/dist/{types → core/types}/permission-name.type.d.ts +0 -0
- /package/dist/{types → core/types}/permission-name.type.js +0 -0
- /package/dist/{types → core/types}/role-name.type.d.ts +0 -0
- /package/dist/{types → core/types}/role-name.type.js +0 -0
- /package/dist/{types → core/types}/route-argument-metadata.type.js +0 -0
- /package/dist/{utils → core/utils}/apply-auth-response-cookies.util.d.ts +0 -0
- /package/dist/{utils → core/utils}/auth-role.util.d.ts +0 -0
- /package/dist/{utils → core/utils}/auth-role.util.js +0 -0
- /package/dist/{utils → core/utils}/create-email-and-password-config.js +0 -0
- /package/dist/{utils → core/utils}/create-email-verification-config.js +0 -0
- /package/dist/{utils → core/utils}/create-generic-oauth-config.d.ts +0 -0
- /package/dist/{utils → core/utils}/create-generic-oauth-config.js +0 -0
- /package/dist/{utils → core/utils}/create-oidc-config.d.ts +0 -0
- /package/dist/{utils → core/utils}/create-oidc-config.js +0 -0
- /package/dist/{utils → core/utils}/create-social-provider-config.d.ts +0 -0
- /package/dist/{utils → core/utils}/create-social-provider-config.js +0 -0
- /package/dist/{utils → core/utils}/create-social-providers-config.d.ts +0 -0
- /package/dist/{utils → core/utils}/create-social-providers-config.js +0 -0
- /package/dist/{utils → core/utils}/create-user-config.d.ts +0 -0
- /package/dist/{utils → core/utils}/estimate-entropy.d.ts +0 -0
- /package/dist/{utils → core/utils}/generic-oauth-provider-config.type.d.ts +0 -0
- /package/dist/{utils → core/utils}/generic-oauth-provider-config.type.js +0 -0
- /package/dist/{utils → core/utils}/has-social-provider-credential-env-config.d.ts +0 -0
- /package/dist/{utils → core/utils}/has-social-provider-credential-env-config.js +0 -0
- /package/dist/{utils → core/utils}/is-env-true.d.ts +0 -0
- /package/dist/{utils → core/utils}/is-env-true.js +0 -0
- /package/dist/{utils → core/utils}/resolve-oidc-prompt.d.ts +0 -0
- /package/dist/{utils → core/utils}/resolve-oidc-prompt.js +0 -0
- /package/dist/{utils → core/utils}/resolve-oidc-scopes.d.ts +0 -0
- /package/dist/{utils → core/utils}/resolve-oidc-scopes.js +0 -0
- /package/dist/{utils → core/utils}/resolve-required-oidc-env.d.ts +0 -0
- /package/dist/{utils → core/utils}/resolve-required-oidc-env.js +0 -0
- /package/dist/{utils → core/utils}/resolve-required-social-provider-env.d.ts +0 -0
- /package/dist/{utils → core/utils}/resolve-required-social-provider-env.js +0 -0
- /package/dist/{utils → core/utils}/resolve-secret.js +0 -0
- /package/dist/{utils → core/utils}/resolve-social-provider-enabled.d.ts +0 -0
- /package/dist/{utils → core/utils}/resolve-social-provider-enabled.js +0 -0
- /package/dist/{utils → core/utils}/split-auth-providers.d.ts +0 -0
- /package/dist/{utils → core/utils}/split-auth-providers.js +0 -0
- /package/dist/{connections → workspace/connections}/workspace.connection-definition.d.ts +0 -0
- /package/dist/{decorators → workspace/decorators}/current-workspace.decorator.d.ts +0 -0
- /package/dist/{decorators → workspace/decorators}/current-workspace.decorator.js +0 -0
- /package/dist/{enums → workspace/enums}/workspace-permission.enum.d.ts +0 -0
- /package/dist/{enums → workspace/enums}/workspace-role.enum.d.ts +0 -0
- /package/dist/{inputs → workspace/inputs}/create-workspace.input.d.ts +0 -0
- /package/dist/{inputs → workspace/inputs}/create-workspace.input.js +0 -0
- /package/dist/{inputs → workspace/inputs}/update-workspace.input.d.ts +0 -0
- /package/dist/{inputs → workspace/inputs}/update-workspace.input.js +0 -0
- /package/dist/{interfaces → workspace/interfaces}/auth-module-workspace-options.interface.js +0 -0
- /package/dist/{interfaces → workspace/interfaces}/create-workspace-options.interface.d.ts +0 -0
- /package/dist/{interfaces → workspace/interfaces}/create-workspace-options.interface.js +0 -0
- /package/dist/{interfaces → workspace/interfaces}/update-workspace-options.interface.d.ts +0 -0
- /package/dist/{interfaces → workspace/interfaces}/update-workspace-options.interface.js +0 -0
- /package/dist/{interfaces → workspace/interfaces}/workspace-has-permissions-options.interface.d.ts +0 -0
- /package/dist/{interfaces → workspace/interfaces}/workspace-has-permissions-options.interface.js +0 -0
- /package/dist/{objects → workspace/objects}/create-workspace-payload.object.d.ts +0 -0
- /package/dist/{objects → workspace/objects}/create-workspace-payload.object.js +0 -0
- /package/dist/{objects → workspace/objects}/delete-workspace-payload.object.d.ts +0 -0
- /package/dist/{objects → workspace/objects}/delete-workspace-payload.object.js +0 -0
- /package/dist/{objects → workspace/objects}/leave-workspace-payload.object.d.ts +0 -0
- /package/dist/{objects → workspace/objects}/leave-workspace-payload.object.js +0 -0
- /package/dist/{objects → workspace/objects}/update-workspace-payload.object.d.ts +0 -0
- /package/dist/{objects → workspace/objects}/update-workspace-payload.object.js +0 -0
- /package/dist/{objects → workspace/objects}/workspace-permission-option.object.d.ts +0 -0
- /package/dist/{objects → workspace/objects}/workspace-permission-option.object.js +0 -0
- /package/dist/{objects → workspace/objects}/workspace-role-option.object.d.ts +0 -0
- /package/dist/{objects → workspace/objects}/workspace-role-option.object.js +0 -0
|
@@ -1,444 +0,0 @@
|
|
|
1
|
-
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
2
|
-
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
3
|
-
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
4
|
-
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
5
|
-
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
6
|
-
};
|
|
7
|
-
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
8
|
-
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
9
|
-
};
|
|
10
|
-
var __param = (this && this.__param) || function (paramIndex, decorator) {
|
|
11
|
-
return function (target, key) { decorator(target, key, paramIndex); }
|
|
12
|
-
};
|
|
13
|
-
import { EntityManager, LockMode, Reference, UniqueConstraintViolationException, } from "@mikro-orm/core";
|
|
14
|
-
import { ConnectionManager, } from "@nest-boot/graphql-connection";
|
|
15
|
-
import { RequestContext } from "@nest-boot/request-context";
|
|
16
|
-
import { BadRequestException, ConflictException, ForbiddenException, Inject, Injectable, NotFoundException, } from "@nestjs/common";
|
|
17
|
-
import { MODULE_OPTIONS_TOKEN } from "../../auth.module-definition.js";
|
|
18
|
-
import { Invitation } from "../../entities/invitation.entity.js";
|
|
19
|
-
import { Member } from "../../entities/member.entity.js";
|
|
20
|
-
import { User } from "../../entities/user.entity.js";
|
|
21
|
-
import { Workspace } from "../../entities/workspace.entity.js";
|
|
22
|
-
import { RequestIdentity } from "../../infrastructure/request-identity.js";
|
|
23
|
-
import { normalizeAuthRoles, resolveAuthPermissions, } from "../../utils/auth-role.util.js";
|
|
24
|
-
import { authorize } from "../../utils/authorize.util.js";
|
|
25
|
-
import { can } from "../../utils/can.util.js";
|
|
26
|
-
import { getCurrentApiKey } from "../../utils/get-current-api-key.util.js";
|
|
27
|
-
import { assertCanGrantPermissions } from "../../utils/permission-grants.util.js";
|
|
28
|
-
import { resolveAuthCatalog } from "../../utils/resolve-auth-catalog.util.js";
|
|
29
|
-
import { DEFAULT_WORKSPACE_ROLE } from "../../workspace.constants.js";
|
|
30
|
-
import { InvitationConnection } from "./invitation.connection-definition.js";
|
|
31
|
-
/** Workspace invitation queries and lifecycle operations. */
|
|
32
|
-
let InvitationService = class InvitationService {
|
|
33
|
-
em;
|
|
34
|
-
authOptions;
|
|
35
|
-
/**
|
|
36
|
-
* Creates a workspace invitation domain service.
|
|
37
|
-
* @param em - Entity manager used for persistence.
|
|
38
|
-
* @param authOptions - Authentication module configuration.
|
|
39
|
-
*/
|
|
40
|
-
constructor(
|
|
41
|
-
/** MikroORM entity manager used for workspace persistence. */
|
|
42
|
-
em, authOptions) {
|
|
43
|
-
this.em = em;
|
|
44
|
-
this.authOptions = authOptions;
|
|
45
|
-
}
|
|
46
|
-
/**
|
|
47
|
-
* Creates a pending workspace invitation.
|
|
48
|
-
* @param workspace - The workspace that scopes this operation.
|
|
49
|
-
* @param inviter - User who sends the invitation.
|
|
50
|
-
* @param input - Requested field values for the operation.
|
|
51
|
-
* @param request - Incoming HTTP request.
|
|
52
|
-
* @returns Persisted invitation.
|
|
53
|
-
*/
|
|
54
|
-
async createInvitation(workspace, inviter, input, request) {
|
|
55
|
-
RequestIdentity.assertCurrentWorkspace(workspace);
|
|
56
|
-
RequestIdentity.assertCurrentUser(inviter);
|
|
57
|
-
authorize("write", Invitation);
|
|
58
|
-
const email = input.email.trim().toLowerCase();
|
|
59
|
-
const roles = this.normalizeGrantedRoles(input.roles ?? [this.defaultRole]);
|
|
60
|
-
const expiresIn = input.expiresIn ?? 60 * 60 * 48;
|
|
61
|
-
if (!Number.isSafeInteger(expiresIn) || expiresIn <= 0) {
|
|
62
|
-
throw new BadRequestException("Workspace invitation lifetime must be a positive integer");
|
|
63
|
-
}
|
|
64
|
-
const sendInvitationEmail = this.authOptions.workspace?.sendInvitationEmail;
|
|
65
|
-
if (sendInvitationEmail && this.em.isInTransaction()) {
|
|
66
|
-
throw new BadRequestException("Create invitations with email delivery outside an active transaction");
|
|
67
|
-
}
|
|
68
|
-
let transactionResult;
|
|
69
|
-
try {
|
|
70
|
-
transactionResult = await this.em.transactional(async (em) => {
|
|
71
|
-
await this.lockWorkspace(em, workspace);
|
|
72
|
-
const now = new Date();
|
|
73
|
-
const userId = await this.getUserIdForInvitation(workspace, inviter, email);
|
|
74
|
-
const [member, invitation, inviterMember] = await Promise.all([
|
|
75
|
-
userId
|
|
76
|
-
? em.findOne(Member, { workspace, user: userId }, { filters: false })
|
|
77
|
-
: Promise.resolve(null),
|
|
78
|
-
em.findOne(Invitation, {
|
|
79
|
-
email,
|
|
80
|
-
status: "pending",
|
|
81
|
-
workspace,
|
|
82
|
-
}, { filters: false }),
|
|
83
|
-
sendInvitationEmail
|
|
84
|
-
? em.findOne(Member, {
|
|
85
|
-
status: "ACTIVE",
|
|
86
|
-
user: inviter,
|
|
87
|
-
workspace,
|
|
88
|
-
}, { filters: false })
|
|
89
|
-
: Promise.resolve(null),
|
|
90
|
-
]);
|
|
91
|
-
if (member) {
|
|
92
|
-
throw new ConflictException("User is already a member");
|
|
93
|
-
}
|
|
94
|
-
if (invitation && invitation.expiresAt.getTime() > now.getTime()) {
|
|
95
|
-
throw new ConflictException("User is already invited to this workspace");
|
|
96
|
-
}
|
|
97
|
-
if (sendInvitationEmail && !inviterMember) {
|
|
98
|
-
throw new ForbiddenException("Invitation sender is not an active workspace member");
|
|
99
|
-
}
|
|
100
|
-
if (invitation) {
|
|
101
|
-
invitation.status = "canceled";
|
|
102
|
-
await em.flush();
|
|
103
|
-
}
|
|
104
|
-
const created = em.create(Invitation, {
|
|
105
|
-
email,
|
|
106
|
-
expiresAt: new Date(now.getTime() + expiresIn * 1000),
|
|
107
|
-
inviter,
|
|
108
|
-
roles,
|
|
109
|
-
status: "pending",
|
|
110
|
-
workspace,
|
|
111
|
-
});
|
|
112
|
-
authorize("write", created);
|
|
113
|
-
await em.persist(created).flush();
|
|
114
|
-
return { created, inviterMember };
|
|
115
|
-
}, { clear: true });
|
|
116
|
-
}
|
|
117
|
-
catch (error) {
|
|
118
|
-
if (error instanceof UniqueConstraintViolationException) {
|
|
119
|
-
throw new ConflictException("User is already invited to this workspace");
|
|
120
|
-
}
|
|
121
|
-
throw error;
|
|
122
|
-
}
|
|
123
|
-
const { created, inviterMember } = transactionResult;
|
|
124
|
-
if (sendInvitationEmail && inviterMember) {
|
|
125
|
-
const callbackInviter = Object.assign(Object.create(Object.getPrototypeOf(inviterMember)), inviterMember, { user: inviter });
|
|
126
|
-
try {
|
|
127
|
-
await sendInvitationEmail({
|
|
128
|
-
email,
|
|
129
|
-
id: created.id,
|
|
130
|
-
invitation: created,
|
|
131
|
-
inviter: callbackInviter,
|
|
132
|
-
roles: [...created.roles],
|
|
133
|
-
workspace,
|
|
134
|
-
}, request);
|
|
135
|
-
}
|
|
136
|
-
catch (error) {
|
|
137
|
-
await this.em.nativeUpdate(Invitation, {
|
|
138
|
-
id: created.id,
|
|
139
|
-
status: "pending",
|
|
140
|
-
}, { status: "canceled" });
|
|
141
|
-
throw error;
|
|
142
|
-
}
|
|
143
|
-
}
|
|
144
|
-
return created;
|
|
145
|
-
}
|
|
146
|
-
/**
|
|
147
|
-
* Resolves only the login identity needed for invitation membership checks.
|
|
148
|
-
* Infrastructure isolates this lookup; invitation writes retain request RLS.
|
|
149
|
-
* An unregistered email is a valid invitation recipient.
|
|
150
|
-
* @param workspace - The workspace that scopes this operation.
|
|
151
|
-
* @param inviter - User who sends the invitation.
|
|
152
|
-
* @param email - Email address used to identify the user.
|
|
153
|
-
* @returns Identifier of the user with the invitation email, or null.
|
|
154
|
-
* @internal
|
|
155
|
-
*/
|
|
156
|
-
async getUserIdForInvitation(workspace, inviter, email) {
|
|
157
|
-
RequestIdentity.assertCurrentWorkspace(workspace);
|
|
158
|
-
RequestIdentity.assertCurrentUser(inviter);
|
|
159
|
-
authorize("write", Invitation);
|
|
160
|
-
const user = await this.em.findOne(User, { email: email.trim().toLowerCase() }, { fields: ["id"], filters: false });
|
|
161
|
-
return user ? String(user.id) : null;
|
|
162
|
-
}
|
|
163
|
-
/**
|
|
164
|
-
* Finds an invitation after recipient or workspace authorization, preserving RLS.
|
|
165
|
-
* @param id - Identifier of the record to access.
|
|
166
|
-
* @returns Accessible invitation, or null if it does not exist.
|
|
167
|
-
*/
|
|
168
|
-
async getInvitation(id) {
|
|
169
|
-
const recipientSession = RequestContext.isActive() &&
|
|
170
|
-
RequestContext.get(User) &&
|
|
171
|
-
!getCurrentApiKey();
|
|
172
|
-
if (!recipientSession && !can("read", Invitation)) {
|
|
173
|
-
throw new ForbiddenException("Invitation read access denied");
|
|
174
|
-
}
|
|
175
|
-
const invitation = await this.em.findOne(Invitation, { id }, { refresh: true });
|
|
176
|
-
if (invitation)
|
|
177
|
-
this.assertInvitationReadAccess(invitation);
|
|
178
|
-
return invitation;
|
|
179
|
-
}
|
|
180
|
-
/**
|
|
181
|
-
* Resolves the inviter through an authorized invitation without bypassing RLS.
|
|
182
|
-
* @param invitation - Invitation being inspected or changed.
|
|
183
|
-
* @returns User who sent the invitation.
|
|
184
|
-
*/
|
|
185
|
-
async getInvitationInviter(invitation) {
|
|
186
|
-
const current = await this.getInvitationForRelation(invitation);
|
|
187
|
-
const actor = RequestContext.isActive() ? RequestContext.get(User) : null;
|
|
188
|
-
const self = !getCurrentApiKey() && actor?.id === current.inviter.id;
|
|
189
|
-
if (!self)
|
|
190
|
-
authorize("read", User);
|
|
191
|
-
const user = await this.em.findOne(User, { id: current.inviter.id }, { refresh: true });
|
|
192
|
-
if (!user)
|
|
193
|
-
throw new NotFoundException("Invitation inviter not found");
|
|
194
|
-
if (!self)
|
|
195
|
-
authorize("read", user);
|
|
196
|
-
return user;
|
|
197
|
-
}
|
|
198
|
-
/**
|
|
199
|
-
* Resolves the workspace through an authorized invitation without requiring membership.
|
|
200
|
-
* @param invitation - Invitation being inspected or changed.
|
|
201
|
-
* @returns Workspace to which the invitation grants membership.
|
|
202
|
-
*/
|
|
203
|
-
async getInvitationWorkspace(invitation) {
|
|
204
|
-
const current = await this.getInvitationForRelation(invitation);
|
|
205
|
-
const workspace = await this.em.findOne(Workspace, { id: current.workspace.id }, { refresh: true });
|
|
206
|
-
if (!workspace)
|
|
207
|
-
throw new NotFoundException("Invitation workspace not found");
|
|
208
|
-
return workspace;
|
|
209
|
-
}
|
|
210
|
-
async getInvitationForRelation(invitation) {
|
|
211
|
-
this.assertInvitationReadAccess(invitation);
|
|
212
|
-
// Re-read through this manager: a mutation may return entities/references
|
|
213
|
-
// hydrated by the isolated authentication context, or an older identity.
|
|
214
|
-
const current = await this.em.findOne(Invitation, { id: invitation.id }, { refresh: true });
|
|
215
|
-
if (!current)
|
|
216
|
-
throw new NotFoundException("Workspace invitation not found");
|
|
217
|
-
this.assertInvitationReadAccess(current);
|
|
218
|
-
return current;
|
|
219
|
-
}
|
|
220
|
-
assertInvitationReadAccess(invitation) {
|
|
221
|
-
const user = RequestContext.isActive() ? RequestContext.get(User) : null;
|
|
222
|
-
if (invitation.email.toLowerCase() === user?.email?.toLowerCase() &&
|
|
223
|
-
!getCurrentApiKey()) {
|
|
224
|
-
return;
|
|
225
|
-
}
|
|
226
|
-
RequestIdentity.assertCurrentWorkspace(this.unwrapInvitationWorkspace(invitation));
|
|
227
|
-
authorize("read", invitation);
|
|
228
|
-
}
|
|
229
|
-
/**
|
|
230
|
-
* Finds an invitation when it is addressed to the supplied user.
|
|
231
|
-
* @param id - Identifier of the record to access.
|
|
232
|
-
* @param user - The user whose account is being accessed.
|
|
233
|
-
* @returns Accessible invitation addressed to the user, or null.
|
|
234
|
-
*/
|
|
235
|
-
async getInvitationByUser(id, user) {
|
|
236
|
-
RequestIdentity.assertUserSession(user);
|
|
237
|
-
const invitation = await this.em.findOne(Invitation, {
|
|
238
|
-
id,
|
|
239
|
-
email: user.email.toLowerCase(),
|
|
240
|
-
});
|
|
241
|
-
return invitation;
|
|
242
|
-
}
|
|
243
|
-
/**
|
|
244
|
-
* Finds an invitation owned by the supplied workspace.
|
|
245
|
-
* @param id - Identifier of the record to access.
|
|
246
|
-
* @param workspace - The workspace that scopes this operation.
|
|
247
|
-
* @returns Accessible invitation in the workspace, or null.
|
|
248
|
-
*/
|
|
249
|
-
async getInvitationByWorkspace(id, workspace) {
|
|
250
|
-
RequestIdentity.assertCurrentWorkspace(workspace);
|
|
251
|
-
authorize("read", Invitation);
|
|
252
|
-
const invitation = await this.em.findOne(Invitation, {
|
|
253
|
-
id,
|
|
254
|
-
workspace,
|
|
255
|
-
});
|
|
256
|
-
if (invitation)
|
|
257
|
-
authorize("read", invitation);
|
|
258
|
-
return invitation;
|
|
259
|
-
}
|
|
260
|
-
/**
|
|
261
|
-
* Paginates invitations for the selected workspace after authorization.
|
|
262
|
-
* @param workspace - The workspace that scopes this operation.
|
|
263
|
-
* @param args - Pagination, filtering, and ordering arguments.
|
|
264
|
-
* @param info - GraphQL selection information used to shape the query.
|
|
265
|
-
* @returns Paginated invitations belonging to the workspace.
|
|
266
|
-
*/
|
|
267
|
-
async getInvitationConnectionByWorkspace(workspace, args, info) {
|
|
268
|
-
RequestIdentity.assertCurrentWorkspace(workspace);
|
|
269
|
-
authorize("read", Invitation);
|
|
270
|
-
const connection = await new ConnectionManager(this.em).find(InvitationConnection, args, {
|
|
271
|
-
...(info && { info }),
|
|
272
|
-
where: { workspace },
|
|
273
|
-
});
|
|
274
|
-
for (const { node } of connection.edges) {
|
|
275
|
-
authorize("read", node);
|
|
276
|
-
}
|
|
277
|
-
return connection;
|
|
278
|
-
}
|
|
279
|
-
/**
|
|
280
|
-
* Paginates unexpired pending invitations addressed to the current user.
|
|
281
|
-
* @param user - The user whose account is being accessed.
|
|
282
|
-
* @param args - Pagination, filtering, and ordering arguments.
|
|
283
|
-
* @param info - GraphQL selection information used to shape the query.
|
|
284
|
-
* @returns Paginated invitations addressed to the user.
|
|
285
|
-
*/
|
|
286
|
-
async getInvitationConnectionByUser(user, args, info) {
|
|
287
|
-
RequestIdentity.assertUserSession(user);
|
|
288
|
-
const now = new Date();
|
|
289
|
-
const connection = await new ConnectionManager(this.em).find(InvitationConnection, args, {
|
|
290
|
-
...(info && { info }),
|
|
291
|
-
where: {
|
|
292
|
-
email: user.email.toLowerCase(),
|
|
293
|
-
expiresAt: { $gt: now },
|
|
294
|
-
status: "pending",
|
|
295
|
-
},
|
|
296
|
-
});
|
|
297
|
-
return connection;
|
|
298
|
-
}
|
|
299
|
-
/**
|
|
300
|
-
* Accepts a pending invitation and creates an active membership.
|
|
301
|
-
* @param user - The user whose account is being accessed.
|
|
302
|
-
* @param invitationId - Identifier of the invitation to accept.
|
|
303
|
-
* @returns Accepted invitation and its resulting membership.
|
|
304
|
-
*/
|
|
305
|
-
async acceptInvitation(user, invitationId) {
|
|
306
|
-
RequestIdentity.assertUserSession(user);
|
|
307
|
-
return await this.em.transactional(async (em) => {
|
|
308
|
-
const invitation = await em.findOne(Invitation, { id: invitationId }, {
|
|
309
|
-
filters: false,
|
|
310
|
-
populate: ["workspace"],
|
|
311
|
-
});
|
|
312
|
-
if (!invitation)
|
|
313
|
-
return null;
|
|
314
|
-
if (invitation.email.toLowerCase() !== user.email.toLowerCase()) {
|
|
315
|
-
throw new ForbiddenException("Workspace invitation belongs to another email address");
|
|
316
|
-
}
|
|
317
|
-
// All membership/invitation creation takes the workspace lock first.
|
|
318
|
-
// Refresh the invitation only afterwards so direct addition and deletion
|
|
319
|
-
// cannot race acceptance or acquire these locks in the opposite order.
|
|
320
|
-
const workspace = this.unwrapInvitationWorkspace(invitation);
|
|
321
|
-
await this.lockWorkspace(em, workspace);
|
|
322
|
-
await em.refreshOrFail(invitation, {
|
|
323
|
-
filters: false,
|
|
324
|
-
lockMode: LockMode.PESSIMISTIC_WRITE,
|
|
325
|
-
populate: [],
|
|
326
|
-
});
|
|
327
|
-
if (invitation.status !== "pending") {
|
|
328
|
-
throw new BadRequestException("Workspace invitation is not pending");
|
|
329
|
-
}
|
|
330
|
-
if (invitation.expiresAt.getTime() <= Date.now()) {
|
|
331
|
-
throw new BadRequestException("Workspace invitation has expired");
|
|
332
|
-
}
|
|
333
|
-
if (invitation.email.toLowerCase() !== user.email.toLowerCase()) {
|
|
334
|
-
throw new ForbiddenException("Workspace invitation belongs to another email address");
|
|
335
|
-
}
|
|
336
|
-
const existing = await em.findOne(Member, { user, workspace }, { filters: false });
|
|
337
|
-
if (existing)
|
|
338
|
-
throw new ConflictException("User is already a member");
|
|
339
|
-
const member = em.create(Member, {
|
|
340
|
-
name: user.name,
|
|
341
|
-
email: user.email.trim().toLowerCase(),
|
|
342
|
-
permissions: [],
|
|
343
|
-
roles: this.normalizeRoles(invitation.roles),
|
|
344
|
-
status: "ACTIVE",
|
|
345
|
-
user,
|
|
346
|
-
workspace,
|
|
347
|
-
});
|
|
348
|
-
invitation.status = "accepted";
|
|
349
|
-
await em.persist(member).flush();
|
|
350
|
-
return { invitation, member };
|
|
351
|
-
}, { clear: true });
|
|
352
|
-
}
|
|
353
|
-
/**
|
|
354
|
-
* Cancels a pending invitation.
|
|
355
|
-
* @param invitation - Invitation being inspected or changed.
|
|
356
|
-
* @returns Canceled invitation.
|
|
357
|
-
*/
|
|
358
|
-
async cancelInvitation(invitation) {
|
|
359
|
-
authorize("write", Invitation);
|
|
360
|
-
invitation = await this.resolveInvitationForAction(invitation);
|
|
361
|
-
const workspace = this.unwrapInvitationWorkspace(invitation);
|
|
362
|
-
RequestIdentity.assertCurrentWorkspace(workspace);
|
|
363
|
-
authorize("write", invitation);
|
|
364
|
-
if (invitation.status !== "pending") {
|
|
365
|
-
throw new BadRequestException("Workspace invitation is not pending");
|
|
366
|
-
}
|
|
367
|
-
const updated = await this.em.nativeUpdate(Invitation, {
|
|
368
|
-
id: invitation.id,
|
|
369
|
-
status: "pending",
|
|
370
|
-
workspace,
|
|
371
|
-
}, { status: "canceled" });
|
|
372
|
-
if (updated !== 1) {
|
|
373
|
-
throw new BadRequestException("Workspace invitation is not pending");
|
|
374
|
-
}
|
|
375
|
-
invitation.status = "canceled";
|
|
376
|
-
return invitation;
|
|
377
|
-
}
|
|
378
|
-
/**
|
|
379
|
-
* Rejects an invitation after verifying the invited user's email.
|
|
380
|
-
* @param user - The user whose account is being accessed.
|
|
381
|
-
* @param invitation - Invitation being inspected or changed.
|
|
382
|
-
* @returns Rejected invitation.
|
|
383
|
-
*/
|
|
384
|
-
async rejectInvitation(user, invitation) {
|
|
385
|
-
RequestIdentity.assertUserSession(user);
|
|
386
|
-
invitation = await this.resolveInvitationForAction(invitation);
|
|
387
|
-
if (invitation.status !== "pending") {
|
|
388
|
-
throw new BadRequestException("Workspace invitation is not pending");
|
|
389
|
-
}
|
|
390
|
-
if (invitation.email.toLowerCase() !== user.email.toLowerCase()) {
|
|
391
|
-
throw new ForbiddenException("Workspace invitation belongs to another email address");
|
|
392
|
-
}
|
|
393
|
-
const updated = await this.em.nativeUpdate(Invitation, {
|
|
394
|
-
email: user.email.trim().toLowerCase(),
|
|
395
|
-
id: invitation.id,
|
|
396
|
-
status: "pending",
|
|
397
|
-
}, { status: "rejected" });
|
|
398
|
-
if (updated !== 1) {
|
|
399
|
-
throw new BadRequestException("Workspace invitation is not pending");
|
|
400
|
-
}
|
|
401
|
-
invitation.status = "rejected";
|
|
402
|
-
return invitation;
|
|
403
|
-
}
|
|
404
|
-
async resolveInvitationForAction(invitation) {
|
|
405
|
-
if (typeof invitation !== "string")
|
|
406
|
-
return invitation;
|
|
407
|
-
const entity = await this.em.findOne(Invitation, { id: invitation }, { populate: ["workspace"], refresh: true });
|
|
408
|
-
if (!entity)
|
|
409
|
-
throw new NotFoundException("Workspace invitation not found");
|
|
410
|
-
return entity;
|
|
411
|
-
}
|
|
412
|
-
async lockWorkspace(em, workspace) {
|
|
413
|
-
await em.refreshOrFail(workspace, {
|
|
414
|
-
filters: false,
|
|
415
|
-
lockMode: LockMode.PESSIMISTIC_WRITE,
|
|
416
|
-
populate: [],
|
|
417
|
-
failHandler: () => new NotFoundException("Workspace not found"),
|
|
418
|
-
});
|
|
419
|
-
}
|
|
420
|
-
normalizeRoles(role) {
|
|
421
|
-
return normalizeAuthRoles(role, this.roles);
|
|
422
|
-
}
|
|
423
|
-
normalizeGrantedRoles(role) {
|
|
424
|
-
const roles = this.normalizeRoles(role);
|
|
425
|
-
assertCanGrantPermissions(this.authOptions, "workspace", resolveAuthPermissions(roles, [], this.roles));
|
|
426
|
-
return roles;
|
|
427
|
-
}
|
|
428
|
-
get roles() {
|
|
429
|
-
return resolveAuthCatalog(this.authOptions, "workspace").roles;
|
|
430
|
-
}
|
|
431
|
-
get defaultRole() {
|
|
432
|
-
return this.authOptions.workspace?.defaultRole ?? DEFAULT_WORKSPACE_ROLE;
|
|
433
|
-
}
|
|
434
|
-
unwrapInvitationWorkspace(invitation) {
|
|
435
|
-
return Reference.unwrapReference(invitation.workspace);
|
|
436
|
-
}
|
|
437
|
-
};
|
|
438
|
-
InvitationService = __decorate([
|
|
439
|
-
Injectable(),
|
|
440
|
-
__param(1, Inject(MODULE_OPTIONS_TOKEN)),
|
|
441
|
-
__metadata("design:paramtypes", [EntityManager, Object])
|
|
442
|
-
], InvitationService);
|
|
443
|
-
export { InvitationService };
|
|
444
|
-
//# sourceMappingURL=invitation.service.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"invitation.service.js","sourceRoot":"","sources":["../../../src/features/invitations/invitation.service.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,OAAO,EACL,aAAa,EACb,QAAQ,EACR,SAAS,EACT,kCAAkC,GACnC,MAAM,iBAAiB,CAAC;AAEzB,OAAO,EAEL,iBAAiB,GAElB,MAAM,+BAA+B,CAAC;AACvC,OAAO,EAAE,cAAc,EAAE,MAAM,4BAA4B,CAAC;AAC5D,OAAO,EACL,mBAAmB,EACnB,iBAAiB,EACjB,kBAAkB,EAClB,MAAM,EACN,UAAU,EACV,iBAAiB,GAClB,MAAM,gBAAgB,CAAC;AAGxB,OAAO,EAAE,oBAAoB,EAAE,MAAM,iCAAiC,CAAC;AAEvE,OAAO,EAAE,UAAU,EAAE,MAAM,qCAAqC,CAAC;AACjE,OAAO,EAAE,MAAM,EAAE,MAAM,iCAAiC,CAAC;AACzD,OAAO,EAAE,IAAI,EAAE,MAAM,+BAA+B,CAAC;AACrD,OAAO,EAAE,SAAS,EAAE,MAAM,oCAAoC,CAAC;AAC/D,OAAO,EAAE,eAAe,EAAE,MAAM,0CAA0C,CAAC;AAE3E,OAAO,EACL,kBAAkB,EAClB,sBAAsB,GACvB,MAAM,+BAA+B,CAAC;AACvC,OAAO,EAAE,SAAS,EAAE,MAAM,+BAA+B,CAAC;AAC1D,OAAO,EAAE,GAAG,EAAE,MAAM,yBAAyB,CAAC;AAC9C,OAAO,EAAE,gBAAgB,EAAE,MAAM,yCAAyC,CAAC;AAC3E,OAAO,EAAE,yBAAyB,EAAE,MAAM,uCAAuC,CAAC;AAClF,OAAO,EAAE,kBAAkB,EAAE,MAAM,0CAA0C,CAAC;AAC9E,OAAO,EAAE,sBAAsB,EAAE,MAAM,8BAA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
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
2
|
-
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
3
|
-
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
4
|
-
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
5
|
-
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
6
|
-
};
|
|
7
|
-
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
8
|
-
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
9
|
-
};
|
|
10
|
-
import { Field, ID, ObjectType } from "@nest-boot/graphql";
|
|
11
|
-
/** Rejected invitation identifier without restricted relations. */
|
|
12
|
-
let RejectInvitationPayload = class RejectInvitationPayload {
|
|
13
|
-
/** Identifier of the affected resource. */
|
|
14
|
-
id;
|
|
15
|
-
};
|
|
16
|
-
__decorate([
|
|
17
|
-
Field(() => ID),
|
|
18
|
-
__metadata("design:type", String)
|
|
19
|
-
], RejectInvitationPayload.prototype, "id", void 0);
|
|
20
|
-
RejectInvitationPayload = __decorate([
|
|
21
|
-
ObjectType()
|
|
22
|
-
], RejectInvitationPayload);
|
|
23
|
-
export { RejectInvitationPayload };
|
|
24
|
-
//# sourceMappingURL=reject-invitation-payload.object.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"reject-invitation-payload.object.js","sourceRoot":"","sources":["../../../src/features/invitations/reject-invitation-payload.object.ts"],"names":[],"mappings":";;;;;;;;;AAAA,OAAO,EAAE,KAAK,EAAE,EAAE,EAAE,UAAU,EAAE,MAAM,oBAAoB,CAAC;AAE3D,mEAAmE;AAE5D,IAAM,uBAAuB,GAA7B,MAAM,uBAAuB;IAClC,2CAA2C;IAE3C,EAAE,CAAU;CACb,CAAA;AADC;IADC,KAAK,CAAC,GAAG,EAAE,CAAC,EAAE,CAAC;;mDACJ;AAHD,uBAAuB;IADnC,UAAU,EAAE;GACA,uBAAuB,CAInC"}
|
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
import { EntityManager } from "@mikro-orm/core";
|
|
2
|
-
import type { ApiKeyMetadata } from "../types/api-key-metadata.type.js";
|
|
3
|
-
import type { ApiKeyValidation } from "../types/api-key-validation.type.js";
|
|
4
|
-
/**
|
|
5
|
-
* Authenticates both credential kinds; management stays in their domain services.
|
|
6
|
-
* @internal
|
|
7
|
-
*/
|
|
8
|
-
export declare class ApiKeyAuthenticationService {
|
|
9
|
-
private readonly em;
|
|
10
|
-
constructor(em: EntityManager);
|
|
11
|
-
/**
|
|
12
|
-
* Resolves one unambiguous, active credential and its owner.
|
|
13
|
-
* @param plaintext - Unhashed API key presented by the caller.
|
|
14
|
-
* @returns Validated credential and its owning identity.
|
|
15
|
-
* @throws {UnauthorizedException} When the credential or its owner is invalid.
|
|
16
|
-
*/
|
|
17
|
-
validate(plaintext: string): Promise<ApiKeyValidation>;
|
|
18
|
-
/**
|
|
19
|
-
* Captures the authenticating key's RLS scope before a handler can replace it.
|
|
20
|
-
* @param apiKey - API key whose metadata is being accessed.
|
|
21
|
-
* @returns Callback that records usage for the captured key.
|
|
22
|
-
*/
|
|
23
|
-
captureUsage(apiKey: ApiKeyMetadata): () => Promise<ApiKeyMetadata>;
|
|
24
|
-
/**
|
|
25
|
-
* Records successful use in the credential's own table. Deleted keys remain deleted.
|
|
26
|
-
* @param apiKey - API key whose metadata is being accessed.
|
|
27
|
-
* @returns Key metadata after recording its last-used timestamp.
|
|
28
|
-
*/
|
|
29
|
-
recordUsage(apiKey: ApiKeyMetadata): Promise<ApiKeyMetadata>;
|
|
30
|
-
}
|
|
@@ -1,111 +0,0 @@
|
|
|
1
|
-
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
2
|
-
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
3
|
-
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
4
|
-
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
5
|
-
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
6
|
-
};
|
|
7
|
-
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
8
|
-
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
9
|
-
};
|
|
10
|
-
var ApiKeyAuthenticationService_1;
|
|
11
|
-
import { EntityManager, Reference } from "@mikro-orm/core";
|
|
12
|
-
import { Injectable, UnauthorizedException } from "@nestjs/common";
|
|
13
|
-
import { MemberApiKey } from "../entities/member-api-key.entity.js";
|
|
14
|
-
import { UserApiKey } from "../entities/user-api-key.entity.js";
|
|
15
|
-
import { hashApiKey } from "../utils/api-key-credential.util.js";
|
|
16
|
-
/**
|
|
17
|
-
* Authenticates both credential kinds; management stays in their domain services.
|
|
18
|
-
* @internal
|
|
19
|
-
*/
|
|
20
|
-
let ApiKeyAuthenticationService = ApiKeyAuthenticationService_1 = class ApiKeyAuthenticationService {
|
|
21
|
-
em;
|
|
22
|
-
constructor(em) {
|
|
23
|
-
this.em = em;
|
|
24
|
-
}
|
|
25
|
-
/**
|
|
26
|
-
* Resolves one unambiguous, active credential and its owner.
|
|
27
|
-
* @param plaintext - Unhashed API key presented by the caller.
|
|
28
|
-
* @returns Validated credential and its owning identity.
|
|
29
|
-
* @throws {UnauthorizedException} When the credential or its owner is invalid.
|
|
30
|
-
*/
|
|
31
|
-
async validate(plaintext) {
|
|
32
|
-
if (!plaintext)
|
|
33
|
-
throw new UnauthorizedException("Missing API key");
|
|
34
|
-
const key = hashApiKey(plaintext);
|
|
35
|
-
const userKey = await this.em.findOne(UserApiKey, { key }, { populate: ["user"] });
|
|
36
|
-
const memberKey = await this.em.findOne(MemberApiKey, { key }, { populate: ["member.workspace", "member.user"] });
|
|
37
|
-
if ((!userKey && !memberKey) || (userKey && memberKey)) {
|
|
38
|
-
throw new UnauthorizedException("Invalid API key");
|
|
39
|
-
}
|
|
40
|
-
const apiKey = userKey ?? memberKey;
|
|
41
|
-
if (!apiKey)
|
|
42
|
-
throw new UnauthorizedException("Invalid API key");
|
|
43
|
-
if (!apiKey.enabled)
|
|
44
|
-
throw new UnauthorizedException("API key is disabled");
|
|
45
|
-
if (apiKey.expiresAt && apiKey.expiresAt <= new Date())
|
|
46
|
-
throw new UnauthorizedException("API key has expired");
|
|
47
|
-
if (userKey) {
|
|
48
|
-
const user = Reference.unwrapReference(userKey.user);
|
|
49
|
-
if (user.banned &&
|
|
50
|
-
(!user.banExpiresAt || user.banExpiresAt > new Date())) {
|
|
51
|
-
throw new UnauthorizedException("Invalid API key");
|
|
52
|
-
}
|
|
53
|
-
return { apiKey: userKey, ownerType: "user", user };
|
|
54
|
-
}
|
|
55
|
-
if (!memberKey)
|
|
56
|
-
throw new UnauthorizedException("Invalid API key");
|
|
57
|
-
if (!memberKey.member)
|
|
58
|
-
throw new UnauthorizedException("Invalid API key");
|
|
59
|
-
const member = Reference.unwrapReference(memberKey.member);
|
|
60
|
-
const user = member.user ? Reference.unwrapReference(member.user) : null;
|
|
61
|
-
if (member.status !== "ACTIVE" ||
|
|
62
|
-
!member.workspace ||
|
|
63
|
-
(member.type === "USER" && !user) ||
|
|
64
|
-
(member.type === "SERVICE_ACCOUNT" && user) ||
|
|
65
|
-
(user?.banned && (!user.banExpiresAt || user.banExpiresAt > new Date()))) {
|
|
66
|
-
throw new UnauthorizedException("Invalid API key");
|
|
67
|
-
}
|
|
68
|
-
const workspace = Reference.unwrapReference(member.workspace);
|
|
69
|
-
return {
|
|
70
|
-
apiKey: memberKey,
|
|
71
|
-
ownerType: "member",
|
|
72
|
-
workspace,
|
|
73
|
-
member,
|
|
74
|
-
user,
|
|
75
|
-
};
|
|
76
|
-
}
|
|
77
|
-
/**
|
|
78
|
-
* Captures the authenticating key's RLS scope before a handler can replace it.
|
|
79
|
-
* @param apiKey - API key whose metadata is being accessed.
|
|
80
|
-
* @returns Callback that records usage for the captured key.
|
|
81
|
-
*/
|
|
82
|
-
captureUsage(apiKey) {
|
|
83
|
-
// Forking copies the session context without changing the request identity.
|
|
84
|
-
// An existing transaction remains attached; unrelated pending writes do not.
|
|
85
|
-
const recorder = new ApiKeyAuthenticationService_1(this.em.fork({ useContext: false, keepTransactionContext: true }));
|
|
86
|
-
return () => recorder.recordUsage(apiKey);
|
|
87
|
-
}
|
|
88
|
-
/**
|
|
89
|
-
* Records successful use in the credential's own table. Deleted keys remain deleted.
|
|
90
|
-
* @param apiKey - API key whose metadata is being accessed.
|
|
91
|
-
* @returns Key metadata after recording its last-used timestamp.
|
|
92
|
-
*/
|
|
93
|
-
async recordUsage(apiKey) {
|
|
94
|
-
const now = new Date();
|
|
95
|
-
apiKey.lastUsedAt = now;
|
|
96
|
-
apiKey.updatedAt = now;
|
|
97
|
-
if (apiKey instanceof UserApiKey) {
|
|
98
|
-
await this.em.nativeUpdate(UserApiKey, { id: apiKey.id }, { lastUsedAt: now, updatedAt: now });
|
|
99
|
-
}
|
|
100
|
-
else {
|
|
101
|
-
await this.em.nativeUpdate(MemberApiKey, { id: apiKey.id }, { lastUsedAt: now, updatedAt: now });
|
|
102
|
-
}
|
|
103
|
-
return apiKey;
|
|
104
|
-
}
|
|
105
|
-
};
|
|
106
|
-
ApiKeyAuthenticationService = ApiKeyAuthenticationService_1 = __decorate([
|
|
107
|
-
Injectable(),
|
|
108
|
-
__metadata("design:paramtypes", [EntityManager])
|
|
109
|
-
], ApiKeyAuthenticationService);
|
|
110
|
-
export { ApiKeyAuthenticationService };
|
|
111
|
-
//# sourceMappingURL=api-key-authentication.service.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"api-key-authentication.service.js","sourceRoot":"","sources":["../../src/infrastructure/api-key-authentication.service.ts"],"names":[],"mappings":";;;;;;;;;;AAAA,OAAO,EAAE,aAAa,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAC3D,OAAO,EAAE,UAAU,EAAE,qBAAqB,EAAE,MAAM,gBAAgB,CAAC;AAEnE,OAAO,EAAE,YAAY,EAAE,MAAM,sCAAsC,CAAC;AACpE,OAAO,EAAE,UAAU,EAAE,MAAM,oCAAoC,CAAC;AAGhE,OAAO,EAAE,UAAU,EAAE,MAAM,qCAAqC,CAAC;AAEjE;;;GAGG;AAEI,IAAM,2BAA2B,mCAAjC,MAAM,2BAA2B;IACT;IAA7B,YAA6B,EAAiB;QAAjB,OAAE,GAAF,EAAE,CAAe;IAAG,CAAC;IAElD;;;;;OAKG;IACH,KAAK,CAAC,QAAQ,CAAC,SAAiB;QAC9B,IAAI,CAAC,SAAS;YAAE,MAAM,IAAI,qBAAqB,CAAC,iBAAiB,CAAC,CAAC;QACnE,MAAM,GAAG,GAAG,UAAU,CAAC,SAAS,CAAC,CAAC;QAClC,MAAM,OAAO,GAAG,MAAM,IAAI,CAAC,EAAE,CAAC,OAAO,CACnC,UAAU,EACV,EAAE,GAAG,EAAE,EACP,EAAE,QAAQ,EAAE,CAAC,MAAM,CAAC,EAAE,CACvB,CAAC;QACF,MAAM,SAAS,GAAG,MAAM,IAAI,CAAC,EAAE,CAAC,OAAO,CACrC,YAAY,EACZ,EAAE,GAAG,EAAE,EACP,EAAE,QAAQ,EAAE,CAAC,kBAAkB,EAAE,aAAa,CAAC,EAAE,CAClD,CAAC;QACF,IAAI,CAAC,CAAC,OAAO,IAAI,CAAC,SAAS,CAAC,IAAI,CAAC,OAAO,IAAI,SAAS,CAAC,EAAE,CAAC;YACvD,MAAM,IAAI,qBAAqB,CAAC,iBAAiB,CAAC,CAAC;QACrD,CAAC;QACD,MAAM,MAAM,GAAG,OAAO,IA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