@nest-boot/auth 8.0.3-beta.1 → 8.0.3-beta.2
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 +538 -2
- package/dist/abilities/user.ability.d.ts +3 -0
- package/dist/abilities/user.ability.js +2 -0
- package/dist/abilities/user.ability.js.map +1 -1
- package/dist/abilities/workspace.ability.d.ts +3 -0
- package/dist/abilities/workspace.ability.js +2 -0
- package/dist/abilities/workspace.ability.js.map +1 -1
- package/dist/adapters/mikro-orm/adapter-config.js +1 -0
- package/dist/adapters/mikro-orm/adapter-config.js.map +1 -1
- package/dist/adapters/mikro-orm/create-custom-adapter.d.ts +3 -2
- package/dist/adapters/mikro-orm/entity-metadata-resolver.d.ts +2 -2
- package/dist/adapters/mikro-orm/entity-metadata-resolver.js +22 -0
- package/dist/adapters/mikro-orm/entity-metadata-resolver.js.map +1 -1
- package/dist/adapters/mikro-orm/where-compiler.d.ts +24 -24
- package/dist/adapters/mikro-orm-adapter.d.ts +6 -2
- package/dist/adapters/mikro-orm-adapter.js +2 -1
- package/dist/adapters/mikro-orm-adapter.js.map +1 -1
- package/dist/api-key-usage.interceptor.d.ts +5 -2
- package/dist/api-key-usage.interceptor.js +10 -8
- package/dist/api-key-usage.interceptor.js.map +1 -1
- package/dist/auth-handler.middleware.d.ts +3 -0
- package/dist/auth-handler.middleware.js +3 -0
- package/dist/auth-handler.middleware.js.map +1 -1
- package/dist/auth-module-options.interface.d.ts +31 -338
- package/dist/auth.constants.d.ts +4 -0
- package/dist/auth.constants.js +4 -0
- package/dist/auth.constants.js.map +1 -1
- package/dist/auth.guard.d.ts +31 -9
- package/dist/auth.guard.js +49 -106
- package/dist/auth.guard.js.map +1 -1
- package/dist/auth.middleware.d.ts +20 -6
- package/dist/auth.middleware.js +119 -48
- package/dist/auth.middleware.js.map +1 -1
- package/dist/auth.module-definition.d.ts +1 -1
- package/dist/auth.module.d.ts +28 -5
- package/dist/auth.module.js +87 -64
- package/dist/auth.module.js.map +1 -1
- package/dist/connections/account.connection-definition.d.ts +9 -0
- package/dist/connections/account.connection-definition.js +38 -0
- package/dist/connections/account.connection-definition.js.map +1 -0
- package/dist/connections/index.d.ts +8 -0
- package/dist/connections/index.js +9 -0
- package/dist/connections/index.js.map +1 -0
- package/dist/connections/invitation.connection-definition.d.ts +9 -0
- package/dist/connections/invitation.connection-definition.js +40 -0
- package/dist/connections/invitation.connection-definition.js.map +1 -0
- package/dist/connections/member.connection-definition.d.ts +9 -0
- package/dist/connections/member.connection-definition.js +52 -0
- package/dist/connections/member.connection-definition.js.map +1 -0
- package/dist/connections/session.connection-definition.d.ts +9 -0
- package/dist/connections/session.connection-definition.js +32 -0
- package/dist/connections/session.connection-definition.js.map +1 -0
- package/dist/connections/user-api-key.connection-definition.d.ts +13 -0
- package/dist/connections/user-api-key.connection-definition.js +60 -0
- package/dist/connections/user-api-key.connection-definition.js.map +1 -0
- package/dist/connections/user.connection-definition.d.ts +9 -0
- package/dist/connections/user.connection-definition.js +46 -0
- package/dist/connections/user.connection-definition.js.map +1 -0
- package/dist/connections/workspace-api-key.connection-definition.d.ts +13 -0
- package/dist/connections/workspace-api-key.connection-definition.js +60 -0
- package/dist/connections/workspace-api-key.connection-definition.js.map +1 -0
- package/dist/connections/workspace.connection-definition.d.ts +13 -0
- package/dist/connections/workspace.connection-definition.js +43 -0
- package/dist/connections/workspace.connection-definition.js.map +1 -0
- package/dist/decorators/can.decorator.d.ts +8 -0
- package/dist/decorators/can.decorator.js +8 -0
- package/dist/decorators/can.decorator.js.map +1 -1
- package/dist/decorators/current-api-key.decorator.d.ts +1 -0
- package/dist/decorators/current-api-key.decorator.js +3 -3
- package/dist/decorators/current-api-key.decorator.js.map +1 -1
- package/dist/decorators/current-member.decorator.d.ts +2 -0
- package/dist/decorators/current-member.decorator.js +6 -0
- package/dist/decorators/current-member.decorator.js.map +1 -0
- package/dist/decorators/current-session.decorator.d.ts +1 -0
- package/dist/decorators/current-session.decorator.js +3 -2
- package/dist/decorators/current-session.decorator.js.map +1 -1
- package/dist/decorators/current-user.decorator.d.ts +1 -0
- package/dist/decorators/current-user.decorator.js +3 -2
- package/dist/decorators/current-user.decorator.js.map +1 -1
- package/dist/decorators/current-workspace.decorator.d.ts +1 -0
- package/dist/decorators/current-workspace.decorator.js +3 -2
- package/dist/decorators/current-workspace.decorator.js.map +1 -1
- package/dist/decorators/index.d.ts +1 -1
- package/dist/decorators/index.js +1 -1
- package/dist/decorators/index.js.map +1 -1
- package/dist/decorators/public.decorator.d.ts +1 -0
- package/dist/decorators/public.decorator.js +1 -0
- package/dist/decorators/public.decorator.js.map +1 -1
- package/dist/decorators/user-can.decorator.d.ts +8 -0
- package/dist/decorators/user-can.decorator.js +8 -0
- package/dist/decorators/user-can.decorator.js.map +1 -1
- package/dist/decorators/workspace-can.decorator.d.ts +8 -0
- package/dist/decorators/workspace-can.decorator.js +8 -0
- package/dist/decorators/workspace-can.decorator.js.map +1 -1
- package/dist/entities/account.entity.d.ts +21 -3
- package/dist/entities/account.entity.js +67 -29
- package/dist/entities/account.entity.js.map +1 -1
- package/dist/entities/auth-entity-map.d.ts +21 -0
- package/dist/entities/auth-entity-map.js +22 -0
- package/dist/entities/auth-entity-map.js.map +1 -0
- package/dist/entities/index.d.ts +14 -3
- package/dist/entities/index.js +25 -3
- package/dist/entities/index.js.map +1 -1
- package/dist/entities/invitation.entity.d.ts +24 -0
- package/dist/entities/invitation.entity.js +117 -0
- package/dist/entities/invitation.entity.js.map +1 -0
- package/dist/entities/member.entity.d.ts +28 -0
- package/dist/entities/member.entity.js +126 -0
- package/dist/entities/member.entity.js.map +1 -0
- package/dist/entities/session.entity.d.ts +16 -6
- package/dist/entities/session.entity.js +57 -27
- package/dist/entities/session.entity.js.map +1 -1
- package/dist/entities/user-api-key.entity.d.ts +29 -0
- package/dist/entities/user-api-key.entity.js +147 -0
- package/dist/entities/user-api-key.entity.js.map +1 -0
- package/dist/entities/user.entity.d.ts +18 -2
- package/dist/entities/user.entity.js +104 -29
- package/dist/entities/user.entity.js.map +1 -1
- package/dist/entities/verification.entity.d.ts +8 -1
- package/dist/entities/verification.entity.js +27 -11
- package/dist/entities/verification.entity.js.map +1 -1
- package/dist/entities/workspace-api-key.entity.d.ts +29 -0
- package/dist/entities/workspace-api-key.entity.js +147 -0
- package/dist/entities/workspace-api-key.entity.js.map +1 -0
- package/dist/entities/workspace.entity.d.ts +10 -3
- package/dist/entities/workspace.entity.js +51 -20
- package/dist/entities/workspace.entity.js.map +1 -1
- package/dist/enums/index.d.ts +8 -0
- package/dist/enums/index.js +9 -0
- package/dist/enums/index.js.map +1 -0
- package/dist/enums/invitation-status.enum.d.ts +11 -0
- package/dist/enums/invitation-status.enum.js +17 -0
- package/dist/enums/invitation-status.enum.js.map +1 -0
- package/dist/enums/member-status.enum.d.ts +9 -0
- package/dist/enums/member-status.enum.js +15 -0
- package/dist/enums/member-status.enum.js.map +1 -0
- package/dist/enums/user-api-key-permission.enum.d.ts +4 -0
- package/dist/enums/user-api-key-permission.enum.js +11 -0
- package/dist/enums/user-api-key-permission.enum.js.map +1 -0
- package/dist/enums/user-permission.enum.d.ts +4 -0
- package/dist/enums/user-permission.enum.js +7 -0
- package/dist/enums/user-permission.enum.js.map +1 -0
- package/dist/enums/user-role.enum.d.ts +4 -0
- package/dist/enums/user-role.enum.js +6 -0
- package/dist/enums/user-role.enum.js.map +1 -0
- package/dist/enums/workspace-api-key-permission.enum.d.ts +4 -0
- package/dist/enums/workspace-api-key-permission.enum.js +11 -0
- package/dist/enums/workspace-api-key-permission.enum.js.map +1 -0
- package/dist/enums/workspace-permission.enum.d.ts +4 -0
- package/dist/enums/workspace-permission.enum.js +7 -0
- package/dist/enums/workspace-permission.enum.js.map +1 -0
- package/dist/enums/workspace-role.enum.d.ts +4 -0
- package/dist/enums/workspace-role.enum.js +9 -0
- package/dist/enums/workspace-role.enum.js.map +1 -0
- package/dist/index.d.ts +182 -12
- package/dist/index.js +181 -12
- package/dist/index.js.map +1 -1
- package/dist/infrastructure/api-key-authentication.service.d.ts +14 -0
- package/dist/infrastructure/api-key-authentication.service.js +78 -0
- package/dist/infrastructure/api-key-authentication.service.js.map +1 -0
- package/dist/infrastructure/auth-ability.factory.d.ts +15 -0
- package/dist/infrastructure/auth-ability.factory.js +91 -0
- package/dist/infrastructure/auth-ability.factory.js.map +1 -0
- package/dist/infrastructure/auth-enum-registry.d.ts +8 -0
- package/dist/infrastructure/auth-enum-registry.js +48 -0
- package/dist/infrastructure/auth-enum-registry.js.map +1 -0
- package/dist/infrastructure/auth-service.providers.d.ts +3 -0
- package/dist/infrastructure/auth-service.providers.js +72 -0
- package/dist/infrastructure/auth-service.providers.js.map +1 -0
- package/dist/infrastructure/create-contextual-auth-service.d.ts +10 -0
- package/dist/infrastructure/create-contextual-auth-service.js +50 -0
- package/dist/infrastructure/create-contextual-auth-service.js.map +1 -0
- package/dist/infrastructure/request-identity.d.ts +34 -0
- package/dist/infrastructure/request-identity.js +174 -0
- package/dist/infrastructure/request-identity.js.map +1 -0
- package/dist/infrastructure/revoked-authentication.exception.d.ts +4 -0
- package/dist/infrastructure/revoked-authentication.exception.js +5 -0
- package/dist/infrastructure/revoked-authentication.exception.js.map +1 -0
- package/dist/inputs/add-member.input.d.ts +5 -0
- package/dist/inputs/add-member.input.js +26 -0
- package/dist/inputs/add-member.input.js.map +1 -0
- package/dist/inputs/auth-change-email.input.d.ts +7 -0
- package/dist/inputs/auth-change-email.input.js +33 -0
- package/dist/inputs/auth-change-email.input.js.map +1 -0
- package/dist/inputs/auth-change-password.input.d.ts +9 -0
- package/dist/inputs/auth-change-password.input.js +40 -0
- package/dist/inputs/auth-change-password.input.js.map +1 -0
- package/dist/inputs/auth-delete-user.input.d.ts +9 -0
- package/dist/inputs/auth-delete-user.input.js +40 -0
- package/dist/inputs/auth-delete-user.input.js.map +1 -0
- package/dist/inputs/auth-link-social-account.input.d.ts +13 -0
- package/dist/inputs/auth-link-social-account.input.js +54 -0
- package/dist/inputs/auth-link-social-account.input.js.map +1 -0
- package/dist/inputs/auth-request-password-reset.input.d.ts +7 -0
- package/dist/inputs/auth-request-password-reset.input.js +33 -0
- package/dist/inputs/auth-request-password-reset.input.js.map +1 -0
- package/dist/inputs/auth-reset-password.input.d.ts +7 -0
- package/dist/inputs/auth-reset-password.input.js +33 -0
- package/dist/inputs/auth-reset-password.input.js.map +1 -0
- package/dist/inputs/auth-send-verification-email.input.d.ts +7 -0
- package/dist/inputs/auth-send-verification-email.input.js +33 -0
- package/dist/inputs/auth-send-verification-email.input.js.map +1 -0
- package/dist/inputs/auth-sign-in-social.input.d.ts +17 -0
- package/dist/inputs/auth-sign-in-social.input.js +68 -0
- package/dist/inputs/auth-sign-in-social.input.js.map +1 -0
- package/dist/inputs/auth-sign-in.input.d.ts +11 -0
- package/dist/inputs/auth-sign-in.input.js +47 -0
- package/dist/inputs/auth-sign-in.input.js.map +1 -0
- package/dist/inputs/auth-sign-up.input.d.ts +15 -0
- package/dist/inputs/auth-sign-up.input.js +61 -0
- package/dist/inputs/auth-sign-up.input.js.map +1 -0
- package/dist/inputs/auth-update-user.input.d.ts +7 -0
- package/dist/inputs/auth-update-user.input.js +33 -0
- package/dist/inputs/auth-update-user.input.js.map +1 -0
- package/dist/inputs/ban-user.input.d.ts +7 -0
- package/dist/inputs/ban-user.input.js +33 -0
- package/dist/inputs/ban-user.input.js.map +1 -0
- package/dist/inputs/create-invitation.input.d.ts +10 -0
- package/dist/inputs/create-invitation.input.js +41 -0
- package/dist/inputs/create-invitation.input.js.map +1 -0
- package/dist/inputs/create-user-api-key.input.d.ts +14 -0
- package/dist/inputs/create-user-api-key.input.js +55 -0
- package/dist/inputs/create-user-api-key.input.js.map +1 -0
- package/dist/inputs/create-user.input.d.ts +15 -0
- package/dist/inputs/create-user.input.js +56 -0
- package/dist/inputs/create-user.input.js.map +1 -0
- package/dist/inputs/create-workspace-api-key.input.d.ts +14 -0
- package/dist/inputs/create-workspace-api-key.input.js +55 -0
- package/dist/inputs/create-workspace-api-key.input.js.map +1 -0
- package/dist/inputs/create-workspace.input.d.ts +7 -0
- package/dist/inputs/create-workspace.input.js +28 -0
- package/dist/inputs/create-workspace.input.js.map +1 -0
- package/dist/inputs/set-member-permissions.input.d.ts +6 -0
- package/dist/inputs/set-member-permissions.input.js +27 -0
- package/dist/inputs/set-member-permissions.input.js.map +1 -0
- package/dist/inputs/set-member-roles.input.d.ts +6 -0
- package/dist/inputs/set-member-roles.input.js +27 -0
- package/dist/inputs/set-member-roles.input.js.map +1 -0
- package/dist/inputs/set-user-password.input.d.ts +5 -0
- package/dist/inputs/set-user-password.input.js +26 -0
- package/dist/inputs/set-user-password.input.js.map +1 -0
- package/dist/inputs/set-user-permissions.input.d.ts +6 -0
- package/dist/inputs/set-user-permissions.input.js +27 -0
- package/dist/inputs/set-user-permissions.input.js.map +1 -0
- package/dist/inputs/set-user-roles.input.d.ts +6 -0
- package/dist/inputs/set-user-roles.input.js +27 -0
- package/dist/inputs/set-user-roles.input.js.map +1 -0
- package/dist/inputs/update-member.input.d.ts +10 -0
- package/dist/inputs/update-member.input.js +43 -0
- package/dist/inputs/update-member.input.js.map +1 -0
- package/dist/inputs/update-user-api-key.input.d.ts +14 -0
- package/dist/inputs/update-user-api-key.input.js +50 -0
- package/dist/inputs/update-user-api-key.input.js.map +1 -0
- package/dist/inputs/update-user.input.d.ts +11 -0
- package/dist/inputs/update-user.input.js +47 -0
- package/dist/inputs/update-user.input.js.map +1 -0
- package/dist/inputs/update-workspace-api-key.input.d.ts +14 -0
- package/dist/inputs/update-workspace-api-key.input.js +50 -0
- package/dist/inputs/update-workspace-api-key.input.js.map +1 -0
- package/dist/inputs/update-workspace.input.d.ts +7 -0
- package/dist/inputs/update-workspace.input.js +28 -0
- package/dist/inputs/update-workspace.input.js.map +1 -0
- package/dist/inputs/user-id.input.d.ts +5 -0
- package/dist/inputs/user-id.input.js +26 -0
- package/dist/inputs/user-id.input.js.map +1 -0
- package/dist/interfaces/ability-rules.interface.d.ts +8 -0
- package/dist/interfaces/ability-rules.interface.js +2 -0
- package/dist/interfaces/ability-rules.interface.js.map +1 -0
- package/dist/interfaces/accept-invitation-result.interface.d.ts +9 -0
- package/dist/interfaces/accept-invitation-result.interface.js +2 -0
- package/dist/interfaces/accept-invitation-result.interface.js.map +1 -0
- package/dist/interfaces/add-member-options.interface.d.ts +7 -0
- package/dist/interfaces/add-member-options.interface.js +2 -0
- package/dist/interfaces/add-member-options.interface.js.map +1 -0
- package/dist/interfaces/auth-access-token.interface.d.ts +11 -0
- package/dist/interfaces/auth-access-token.interface.js +2 -0
- package/dist/interfaces/auth-access-token.interface.js.map +1 -0
- package/dist/interfaces/auth-account-info.interface.d.ts +11 -0
- package/dist/interfaces/auth-account-info.interface.js +2 -0
- package/dist/interfaces/auth-account-info.interface.js.map +1 -0
- package/dist/interfaces/auth-account.interface.d.ts +19 -0
- package/dist/interfaces/auth-account.interface.js +2 -0
- package/dist/interfaces/auth-account.interface.js.map +1 -0
- package/dist/interfaces/auth-change-email-confirmation-data.interface.d.ts +12 -0
- package/dist/interfaces/auth-change-email-confirmation-data.interface.js +2 -0
- package/dist/interfaces/auth-change-email-confirmation-data.interface.js.map +1 -0
- package/dist/interfaces/auth-delete-account-verification-data.interface.d.ts +10 -0
- package/dist/interfaces/auth-delete-account-verification-data.interface.js +2 -0
- package/dist/interfaces/auth-delete-account-verification-data.interface.js.map +1 -0
- package/dist/interfaces/auth-email-verification-data.interface.d.ts +10 -0
- package/dist/interfaces/auth-email-verification-data.interface.js +2 -0
- package/dist/interfaces/auth-email-verification-data.interface.js.map +1 -0
- package/dist/interfaces/auth-invitation-email-data.interface.d.ts +18 -0
- package/dist/interfaces/auth-invitation-email-data.interface.js +2 -0
- package/dist/interfaces/auth-invitation-email-data.interface.js.map +1 -0
- package/dist/interfaces/auth-module-account-linking-options.interface.d.ts +18 -0
- package/dist/interfaces/auth-module-account-linking-options.interface.js +2 -0
- package/dist/interfaces/auth-module-account-linking-options.interface.js.map +1 -0
- package/dist/interfaces/auth-module-account-options.interface.d.ts +16 -0
- package/dist/interfaces/auth-module-account-options.interface.js +2 -0
- package/dist/interfaces/auth-module-account-options.interface.js.map +1 -0
- package/dist/interfaces/auth-module-api-key-options.interface.d.ts +15 -0
- package/dist/interfaces/auth-module-api-key-options.interface.js +2 -0
- package/dist/interfaces/auth-module-api-key-options.interface.js.map +1 -0
- package/dist/interfaces/auth-module-change-email-options.interface.d.ts +10 -0
- package/dist/interfaces/auth-module-change-email-options.interface.js +2 -0
- package/dist/interfaces/auth-module-change-email-options.interface.js.map +1 -0
- package/dist/interfaces/auth-module-delete-user-options.interface.d.ts +15 -0
- package/dist/interfaces/auth-module-delete-user-options.interface.js +2 -0
- package/dist/interfaces/auth-module-delete-user-options.interface.js.map +1 -0
- package/dist/interfaces/auth-module-email-and-password-options.interface.d.ts +34 -0
- package/dist/interfaces/auth-module-email-and-password-options.interface.js +2 -0
- package/dist/interfaces/auth-module-email-and-password-options.interface.js.map +1 -0
- package/dist/interfaces/auth-module-email-verification-options.interface.d.ts +19 -0
- package/dist/interfaces/auth-module-email-verification-options.interface.js +2 -0
- package/dist/interfaces/auth-module-email-verification-options.interface.js.map +1 -0
- package/dist/interfaces/auth-module-middleware-options.interface.d.ts +11 -0
- package/dist/interfaces/auth-module-middleware-options.interface.js +2 -0
- package/dist/interfaces/auth-module-middleware-options.interface.js.map +1 -0
- package/dist/interfaces/auth-module-oauth-provider.interface.d.ts +91 -0
- package/dist/interfaces/auth-module-oauth-provider.interface.js +2 -0
- package/dist/interfaces/auth-module-oauth-provider.interface.js.map +1 -0
- package/dist/interfaces/auth-module-password-options.interface.d.ts +10 -0
- package/dist/interfaces/auth-module-password-options.interface.js +2 -0
- package/dist/interfaces/auth-module-password-options.interface.js.map +1 -0
- package/dist/interfaces/auth-module-session-cookie-cache-options.interface.d.ts +14 -0
- package/dist/interfaces/auth-module-session-cookie-cache-options.interface.js +2 -0
- package/dist/interfaces/auth-module-session-cookie-cache-options.interface.js.map +1 -0
- package/dist/interfaces/auth-module-session-cookie-cache-refresh-options.interface.d.ts +5 -0
- package/dist/interfaces/auth-module-session-cookie-cache-refresh-options.interface.js +2 -0
- package/dist/interfaces/auth-module-session-cookie-cache-refresh-options.interface.js.map +1 -0
- package/dist/interfaces/auth-module-session-options.interface.d.ts +16 -0
- package/dist/interfaces/auth-module-session-options.interface.js +2 -0
- package/dist/interfaces/auth-module-session-options.interface.js.map +1 -0
- package/dist/interfaces/auth-module-social-provider.interface.d.ts +109 -0
- package/dist/interfaces/auth-module-social-provider.interface.js +2 -0
- package/dist/interfaces/auth-module-social-provider.interface.js.map +1 -0
- package/dist/interfaces/auth-module-user-options.interface.d.ts +22 -0
- package/dist/interfaces/auth-module-user-options.interface.js +2 -0
- package/dist/interfaces/auth-module-user-options.interface.js.map +1 -0
- package/dist/interfaces/auth-module-workspace-options.interface.d.ts +19 -0
- package/dist/interfaces/auth-module-workspace-options.interface.js +2 -0
- package/dist/interfaces/auth-module-workspace-options.interface.js.map +1 -0
- package/dist/interfaces/auth-oauth-basic-token-endpoint-auth.interface.d.ts +5 -0
- package/dist/interfaces/auth-oauth-basic-token-endpoint-auth.interface.js +2 -0
- package/dist/interfaces/auth-oauth-basic-token-endpoint-auth.interface.js.map +1 -0
- package/dist/interfaces/auth-oauth-client-assertion-context.interface.d.ts +9 -0
- package/dist/interfaces/auth-oauth-client-assertion-context.interface.js +2 -0
- package/dist/interfaces/auth-oauth-client-assertion-context.interface.js.map +1 -0
- package/dist/interfaces/auth-oauth-custom-token-endpoint-auth.interface.d.ts +8 -0
- package/dist/interfaces/auth-oauth-custom-token-endpoint-auth.interface.js +2 -0
- package/dist/interfaces/auth-oauth-custom-token-endpoint-auth.interface.js.map +1 -0
- package/dist/interfaces/auth-oauth-mapped-user.interface.d.ts +15 -0
- package/dist/interfaces/auth-oauth-mapped-user.interface.js +2 -0
- package/dist/interfaces/auth-oauth-mapped-user.interface.js.map +1 -0
- package/dist/interfaces/auth-oauth-no-token-endpoint-auth.interface.d.ts +5 -0
- package/dist/interfaces/auth-oauth-no-token-endpoint-auth.interface.js +2 -0
- package/dist/interfaces/auth-oauth-no-token-endpoint-auth.interface.js.map +1 -0
- package/dist/interfaces/auth-oauth-post-token-endpoint-auth.interface.d.ts +5 -0
- package/dist/interfaces/auth-oauth-post-token-endpoint-auth.interface.js +2 -0
- package/dist/interfaces/auth-oauth-post-token-endpoint-auth.interface.js.map +1 -0
- package/dist/interfaces/auth-oauth-private-key-jwt-token-endpoint-auth.interface.d.ts +9 -0
- package/dist/interfaces/auth-oauth-private-key-jwt-token-endpoint-auth.interface.js +2 -0
- package/dist/interfaces/auth-oauth-private-key-jwt-token-endpoint-auth.interface.js.map +1 -0
- package/dist/interfaces/auth-oauth-profile.interface.d.ts +9 -0
- package/dist/interfaces/auth-oauth-profile.interface.js +2 -0
- package/dist/interfaces/auth-oauth-profile.interface.js.map +1 -0
- package/dist/interfaces/auth-oauth-refresh-context.interface.d.ts +7 -0
- package/dist/interfaces/auth-oauth-refresh-context.interface.js +2 -0
- package/dist/interfaces/auth-oauth-refresh-context.interface.js.map +1 -0
- package/dist/interfaces/auth-oauth-token-request-client-options.interface.d.ts +7 -0
- package/dist/interfaces/auth-oauth-token-request-client-options.interface.js +2 -0
- package/dist/interfaces/auth-oauth-token-request-client-options.interface.js.map +1 -0
- package/dist/interfaces/auth-oauth-token-request-context.interface.d.ts +15 -0
- package/dist/interfaces/auth-oauth-token-request-context.interface.js +2 -0
- package/dist/interfaces/auth-oauth-token-request-context.interface.js.map +1 -0
- package/dist/interfaces/auth-oauth-tokens.interface.d.ts +19 -0
- package/dist/interfaces/auth-oauth-tokens.interface.js +2 -0
- package/dist/interfaces/auth-oauth-tokens.interface.js.map +1 -0
- package/dist/interfaces/auth-oauth-user-info.interface.d.ts +13 -0
- package/dist/interfaces/auth-oauth-user-info.interface.js +2 -0
- package/dist/interfaces/auth-oauth-user-info.interface.js.map +1 -0
- package/dist/interfaces/auth-provider-user-info.interface.d.ts +13 -0
- package/dist/interfaces/auth-provider-user-info.interface.js +2 -0
- package/dist/interfaces/auth-provider-user-info.interface.js.map +1 -0
- package/dist/interfaces/auth-refreshed-token.interface.d.ts +19 -0
- package/dist/interfaces/auth-refreshed-token.interface.js +2 -0
- package/dist/interfaces/auth-refreshed-token.interface.js.map +1 -0
- package/dist/interfaces/auth-reset-password-data.interface.d.ts +10 -0
- package/dist/interfaces/auth-reset-password-data.interface.js +2 -0
- package/dist/interfaces/auth-reset-password-data.interface.js.map +1 -0
- package/dist/interfaces/auth-social-provider-user-info.interface.d.ts +8 -0
- package/dist/interfaces/auth-social-provider-user-info.interface.js +2 -0
- package/dist/interfaces/auth-social-provider-user-info.interface.js.map +1 -0
- package/dist/interfaces/auth-social-provider.interface.d.ts +7 -0
- package/dist/interfaces/auth-social-provider.interface.js +2 -0
- package/dist/interfaces/auth-social-provider.interface.js.map +1 -0
- package/dist/interfaces/auth-user.interface.d.ts +19 -0
- package/dist/interfaces/auth-user.interface.js +2 -0
- package/dist/interfaces/auth-user.interface.js.map +1 -0
- package/dist/interfaces/authenticated-session.interface.d.ts +9 -0
- package/dist/interfaces/authenticated-session.interface.js +2 -0
- package/dist/interfaces/authenticated-session.interface.js.map +1 -0
- package/dist/interfaces/ban-user-options.interface.d.ts +7 -0
- package/dist/interfaces/ban-user-options.interface.js +2 -0
- package/dist/interfaces/ban-user-options.interface.js.map +1 -0
- package/dist/interfaces/can-options.interface.d.ts +2 -0
- package/dist/interfaces/change-auth-email-options.interface.d.ts +7 -0
- package/dist/interfaces/change-auth-email-options.interface.js +2 -0
- package/dist/interfaces/change-auth-email-options.interface.js.map +1 -0
- package/dist/interfaces/change-auth-password-options.interface.d.ts +9 -0
- package/dist/interfaces/change-auth-password-options.interface.js +2 -0
- package/dist/interfaces/change-auth-password-options.interface.js.map +1 -0
- package/dist/interfaces/change-auth-password-result.interface.d.ts +5 -0
- package/dist/interfaces/change-auth-password-result.interface.js +2 -0
- package/dist/interfaces/change-auth-password-result.interface.js.map +1 -0
- package/dist/interfaces/create-api-key-options.interface.d.ts +14 -0
- package/dist/interfaces/create-api-key-options.interface.js +2 -0
- package/dist/interfaces/create-api-key-options.interface.js.map +1 -0
- package/dist/interfaces/create-invitation-options.interface.d.ts +9 -0
- package/dist/interfaces/create-invitation-options.interface.js +2 -0
- package/dist/interfaces/create-invitation-options.interface.js.map +1 -0
- package/dist/interfaces/create-user-options.interface.d.ts +13 -0
- package/dist/interfaces/create-user-options.interface.js +2 -0
- package/dist/interfaces/create-user-options.interface.js.map +1 -0
- package/dist/interfaces/create-workspace-options.interface.d.ts +5 -0
- package/dist/interfaces/create-workspace-options.interface.js +2 -0
- package/dist/interfaces/create-workspace-options.interface.js.map +1 -0
- package/dist/interfaces/created-api-key.interface.d.ts +8 -0
- package/dist/interfaces/created-api-key.interface.js +2 -0
- package/dist/interfaces/created-api-key.interface.js.map +1 -0
- package/dist/interfaces/delete-auth-user-options.interface.d.ts +9 -0
- package/dist/interfaces/delete-auth-user-options.interface.js +2 -0
- package/dist/interfaces/delete-auth-user-options.interface.js.map +1 -0
- package/dist/interfaces/delete-auth-user-result.interface.d.ts +7 -0
- package/dist/interfaces/delete-auth-user-result.interface.js +2 -0
- package/dist/interfaces/delete-auth-user-result.interface.js.map +1 -0
- package/dist/interfaces/impersonation-options.interface.d.ts +7 -0
- package/dist/interfaces/impersonation-options.interface.js +2 -0
- package/dist/interfaces/impersonation-options.interface.js.map +1 -0
- package/dist/interfaces/link-auth-social-account-options.interface.d.ts +21 -0
- package/dist/interfaces/link-auth-social-account-options.interface.js +2 -0
- package/dist/interfaces/link-auth-social-account-options.interface.js.map +1 -0
- package/dist/interfaces/link-auth-social-account-result.interface.d.ts +7 -0
- package/dist/interfaces/link-auth-social-account-result.interface.js +2 -0
- package/dist/interfaces/link-auth-social-account-result.interface.js.map +1 -0
- package/dist/interfaces/request-identity-patch.interface.d.ts +13 -0
- package/dist/interfaces/request-identity-patch.interface.js +2 -0
- package/dist/interfaces/request-identity-patch.interface.js.map +1 -0
- package/dist/interfaces/request-password-reset-options.interface.d.ts +7 -0
- package/dist/interfaces/request-password-reset-options.interface.js +2 -0
- package/dist/interfaces/request-password-reset-options.interface.js.map +1 -0
- package/dist/interfaces/request-password-reset-result.interface.d.ts +7 -0
- package/dist/interfaces/request-password-reset-result.interface.js +2 -0
- package/dist/interfaces/request-password-reset-result.interface.js.map +1 -0
- package/dist/interfaces/request-permissions.interface.d.ts +7 -0
- package/dist/interfaces/request-permissions.interface.js +2 -0
- package/dist/interfaces/request-permissions.interface.js.map +1 -0
- package/dist/interfaces/reset-password-options.interface.d.ts +7 -0
- package/dist/interfaces/reset-password-options.interface.js +2 -0
- package/dist/interfaces/reset-password-options.interface.js.map +1 -0
- package/dist/interfaces/route-argument-metadata-value.interface.d.ts +4 -0
- package/dist/interfaces/scope-policy-options.interface.d.ts +6 -0
- package/dist/interfaces/send-verification-email-options.interface.d.ts +7 -0
- package/dist/interfaces/send-verification-email-options.interface.js +2 -0
- package/dist/interfaces/send-verification-email-options.interface.js.map +1 -0
- package/dist/interfaces/serialized-ability-rule.interface.d.ts +7 -0
- package/dist/interfaces/sign-in-entity-result.interface.d.ts +7 -0
- package/dist/interfaces/sign-in-entity-result.interface.js +2 -0
- package/dist/interfaces/sign-in-entity-result.interface.js.map +1 -0
- package/dist/interfaces/sign-in-options.interface.d.ts +11 -0
- package/dist/interfaces/sign-in-options.interface.js +2 -0
- package/dist/interfaces/sign-in-options.interface.js.map +1 -0
- package/dist/interfaces/sign-in-result.interface.d.ts +12 -0
- package/dist/interfaces/sign-in-result.interface.js +2 -0
- package/dist/interfaces/sign-in-result.interface.js.map +1 -0
- package/dist/interfaces/sign-in-social-entity-result.interface.d.ts +7 -0
- package/dist/interfaces/sign-in-social-entity-result.interface.js +2 -0
- package/dist/interfaces/sign-in-social-entity-result.interface.js.map +1 -0
- package/dist/interfaces/sign-in-social-options.interface.d.ts +23 -0
- package/dist/interfaces/sign-in-social-options.interface.js +2 -0
- package/dist/interfaces/sign-in-social-options.interface.js.map +1 -0
- package/dist/interfaces/sign-in-social-result.interface.d.ts +12 -0
- package/dist/interfaces/sign-in-social-result.interface.js +2 -0
- package/dist/interfaces/sign-in-social-result.interface.js.map +1 -0
- package/dist/interfaces/sign-up-options.interface.d.ts +15 -0
- package/dist/interfaces/sign-up-options.interface.js +2 -0
- package/dist/interfaces/sign-up-options.interface.js.map +1 -0
- package/dist/interfaces/sign-up-result.interface.d.ts +8 -0
- package/dist/interfaces/sign-up-result.interface.js +2 -0
- package/dist/interfaces/sign-up-result.interface.js.map +1 -0
- package/dist/interfaces/unlink-auth-account-options.interface.d.ts +5 -0
- package/dist/interfaces/unlink-auth-account-options.interface.js +2 -0
- package/dist/interfaces/unlink-auth-account-options.interface.js.map +1 -0
- package/dist/interfaces/update-api-key-options.interface.d.ts +14 -0
- package/dist/interfaces/update-api-key-options.interface.js +2 -0
- package/dist/interfaces/update-api-key-options.interface.js.map +1 -0
- package/dist/interfaces/update-auth-user-options.interface.d.ts +7 -0
- package/dist/interfaces/update-auth-user-options.interface.js +2 -0
- package/dist/interfaces/update-auth-user-options.interface.js.map +1 -0
- package/dist/interfaces/update-member-options.interface.d.ts +10 -0
- package/dist/interfaces/update-member-options.interface.js +2 -0
- package/dist/interfaces/update-member-options.interface.js.map +1 -0
- package/dist/interfaces/update-user-options.interface.d.ts +11 -0
- package/dist/interfaces/update-user-options.interface.js +2 -0
- package/dist/interfaces/update-user-options.interface.js.map +1 -0
- package/dist/interfaces/update-workspace-options.interface.d.ts +5 -0
- package/dist/interfaces/update-workspace-options.interface.js +2 -0
- package/dist/interfaces/update-workspace-options.interface.js.map +1 -0
- package/dist/interfaces/user-api-key-validation.interface.d.ts +11 -0
- package/dist/interfaces/user-api-key-validation.interface.js +2 -0
- package/dist/interfaces/user-api-key-validation.interface.js.map +1 -0
- package/dist/interfaces/user-can-metadata.interface.d.ts +3 -0
- package/dist/interfaces/user-has-permissions-options.interface.d.ts +5 -0
- package/dist/interfaces/user-has-permissions-options.interface.js +2 -0
- package/dist/interfaces/user-has-permissions-options.interface.js.map +1 -0
- package/dist/interfaces/workspace-api-key-validation.interface.d.ts +11 -0
- package/dist/interfaces/workspace-api-key-validation.interface.js +2 -0
- package/dist/interfaces/workspace-api-key-validation.interface.js.map +1 -0
- package/dist/interfaces/workspace-can-metadata.interface.d.ts +3 -0
- package/dist/interfaces/workspace-has-permissions-options.interface.d.ts +5 -0
- package/dist/interfaces/workspace-has-permissions-options.interface.js +2 -0
- package/dist/interfaces/workspace-has-permissions-options.interface.js.map +1 -0
- package/dist/objects/accept-invitation-payload.object.d.ts +9 -0
- package/dist/objects/accept-invitation-payload.object.js +36 -0
- package/dist/objects/accept-invitation-payload.object.js.map +1 -0
- package/dist/objects/add-member-payload.object.d.ts +5 -0
- package/dist/objects/add-member-payload.object.js +24 -0
- package/dist/objects/add-member-payload.object.js.map +1 -0
- package/dist/objects/auth-ability-rule.object.d.ts +15 -0
- package/dist/objects/auth-ability-rule.object.js +55 -0
- package/dist/objects/auth-ability-rule.object.js.map +1 -0
- package/dist/objects/auth-change-password-result.object.d.ts +5 -0
- package/dist/objects/auth-change-password-result.object.js +24 -0
- package/dist/objects/auth-change-password-result.object.js.map +1 -0
- package/dist/objects/auth-delete-user-result.object.d.ts +7 -0
- package/dist/objects/auth-delete-user-result.object.js +30 -0
- package/dist/objects/auth-delete-user-result.object.js.map +1 -0
- package/dist/objects/auth-link-social-account-result.object.d.ts +7 -0
- package/dist/objects/auth-link-social-account-result.object.js +30 -0
- package/dist/objects/auth-link-social-account-result.object.js.map +1 -0
- package/dist/objects/auth-request-password-reset-result.object.d.ts +7 -0
- package/dist/objects/auth-request-password-reset-result.object.js +30 -0
- package/dist/objects/auth-request-password-reset-result.object.js.map +1 -0
- package/dist/objects/auth-sign-in-result.object.d.ts +12 -0
- package/dist/objects/auth-sign-in-result.object.js +43 -0
- package/dist/objects/auth-sign-in-result.object.js.map +1 -0
- package/dist/objects/auth-sign-in-social-result.object.d.ts +12 -0
- package/dist/objects/auth-sign-in-social-result.object.js +43 -0
- package/dist/objects/auth-sign-in-social-result.object.js.map +1 -0
- package/dist/objects/auth-social-provider.object.d.ts +7 -0
- package/dist/objects/auth-social-provider.object.js +30 -0
- package/dist/objects/auth-social-provider.object.js.map +1 -0
- package/dist/objects/ban-user-payload.object.d.ts +5 -0
- package/dist/objects/ban-user-payload.object.js +24 -0
- package/dist/objects/ban-user-payload.object.js.map +1 -0
- package/dist/objects/cancel-invitation-payload.object.d.ts +5 -0
- package/dist/objects/cancel-invitation-payload.object.js +24 -0
- package/dist/objects/cancel-invitation-payload.object.js.map +1 -0
- package/dist/objects/create-invitation-payload.object.d.ts +5 -0
- package/dist/objects/create-invitation-payload.object.js +24 -0
- package/dist/objects/create-invitation-payload.object.js.map +1 -0
- package/dist/objects/create-user-api-key-result.object.d.ts +10 -0
- package/dist/objects/create-user-api-key-result.object.js +33 -0
- package/dist/objects/create-user-api-key-result.object.js.map +1 -0
- package/dist/objects/create-user-payload.object.d.ts +5 -0
- package/dist/objects/create-user-payload.object.js +24 -0
- package/dist/objects/create-user-payload.object.js.map +1 -0
- package/dist/objects/create-workspace-api-key-result.object.d.ts +10 -0
- package/dist/objects/create-workspace-api-key-result.object.js +33 -0
- package/dist/objects/create-workspace-api-key-result.object.js.map +1 -0
- package/dist/objects/create-workspace-payload.object.d.ts +5 -0
- package/dist/objects/create-workspace-payload.object.js +24 -0
- package/dist/objects/create-workspace-payload.object.js.map +1 -0
- package/dist/objects/delete-user-payload.object.d.ts +5 -0
- package/dist/objects/delete-user-payload.object.js +24 -0
- package/dist/objects/delete-user-payload.object.js.map +1 -0
- package/dist/objects/delete-workspace-payload.object.d.ts +5 -0
- package/dist/objects/delete-workspace-payload.object.js +24 -0
- package/dist/objects/delete-workspace-payload.object.js.map +1 -0
- package/dist/objects/leave-workspace-payload.object.d.ts +5 -0
- package/dist/objects/leave-workspace-payload.object.js +24 -0
- package/dist/objects/leave-workspace-payload.object.js.map +1 -0
- package/dist/objects/reject-invitation-payload.object.d.ts +5 -0
- package/dist/objects/reject-invitation-payload.object.js +24 -0
- package/dist/objects/reject-invitation-payload.object.js.map +1 -0
- package/dist/objects/remove-member-payload.object.d.ts +5 -0
- package/dist/objects/remove-member-payload.object.js +24 -0
- package/dist/objects/remove-member-payload.object.js.map +1 -0
- package/dist/objects/set-member-permissions-payload.object.d.ts +5 -0
- package/dist/objects/set-member-permissions-payload.object.js +24 -0
- package/dist/objects/set-member-permissions-payload.object.js.map +1 -0
- package/dist/objects/set-member-roles-payload.object.d.ts +5 -0
- package/dist/objects/set-member-roles-payload.object.js +24 -0
- package/dist/objects/set-member-roles-payload.object.js.map +1 -0
- package/dist/objects/set-user-permissions-payload.object.d.ts +5 -0
- package/dist/objects/set-user-permissions-payload.object.js +24 -0
- package/dist/objects/set-user-permissions-payload.object.js.map +1 -0
- package/dist/objects/set-user-roles-payload.object.d.ts +5 -0
- package/dist/objects/set-user-roles-payload.object.js +24 -0
- package/dist/objects/set-user-roles-payload.object.js.map +1 -0
- package/dist/objects/sign-up-payload.object.d.ts +7 -0
- package/dist/objects/sign-up-payload.object.js +30 -0
- package/dist/objects/sign-up-payload.object.js.map +1 -0
- package/dist/objects/unban-user-payload.object.d.ts +5 -0
- package/dist/objects/unban-user-payload.object.js +24 -0
- package/dist/objects/unban-user-payload.object.js.map +1 -0
- package/dist/objects/update-member-payload.object.d.ts +5 -0
- package/dist/objects/update-member-payload.object.js +24 -0
- package/dist/objects/update-member-payload.object.js.map +1 -0
- package/dist/objects/update-user-payload.object.d.ts +5 -0
- package/dist/objects/update-user-payload.object.js +24 -0
- package/dist/objects/update-user-payload.object.js.map +1 -0
- package/dist/objects/update-workspace-payload.object.d.ts +5 -0
- package/dist/objects/update-workspace-payload.object.js +24 -0
- package/dist/objects/update-workspace-payload.object.js.map +1 -0
- package/dist/objects/user-api-key-permission-option.object.d.ts +8 -0
- package/dist/objects/user-api-key-permission-option.object.js +31 -0
- package/dist/objects/user-api-key-permission-option.object.js.map +1 -0
- package/dist/objects/user-permission-option.object.d.ts +8 -0
- package/dist/objects/user-permission-option.object.js +31 -0
- package/dist/objects/user-permission-option.object.js.map +1 -0
- package/dist/objects/user-role-option.object.d.ts +8 -0
- package/dist/objects/user-role-option.object.js +31 -0
- package/dist/objects/user-role-option.object.js.map +1 -0
- package/dist/objects/workspace-api-key-permission-option.object.d.ts +8 -0
- package/dist/objects/workspace-api-key-permission-option.object.js +31 -0
- package/dist/objects/workspace-api-key-permission-option.object.js.map +1 -0
- package/dist/objects/workspace-permission-option.object.d.ts +8 -0
- package/dist/objects/workspace-permission-option.object.js +31 -0
- package/dist/objects/workspace-permission-option.object.js.map +1 -0
- package/dist/objects/workspace-role-option.object.d.ts +8 -0
- package/dist/objects/workspace-role-option.object.js +31 -0
- package/dist/objects/workspace-role-option.object.js.map +1 -0
- package/dist/permission.constants.d.ts +23 -0
- package/dist/permission.constants.js +23 -0
- package/dist/permission.constants.js.map +1 -1
- package/dist/policies/create-scope-policy.d.ts +1 -0
- package/dist/policies/create-scope-policy.js +2 -1
- package/dist/policies/create-scope-policy.js.map +1 -1
- package/dist/policies/user-scope.policy.d.ts +8 -0
- package/dist/policies/user-scope.policy.js +8 -0
- package/dist/policies/user-scope.policy.js.map +1 -1
- package/dist/policies/workspace-scope.policy.d.ts +8 -0
- package/dist/policies/workspace-scope.policy.js +8 -0
- package/dist/policies/workspace-scope.policy.js.map +1 -1
- package/dist/resolvers/auth.resolver.d.ts +67 -0
- package/dist/resolvers/auth.resolver.js +279 -0
- package/dist/resolvers/auth.resolver.js.map +1 -0
- package/dist/resolvers/invitation.resolver.d.ts +32 -0
- package/dist/resolvers/invitation.resolver.js +134 -0
- package/dist/resolvers/invitation.resolver.js.map +1 -0
- package/dist/resolvers/member.resolver.d.ts +73 -0
- package/dist/resolvers/member.resolver.js +191 -0
- package/dist/resolvers/member.resolver.js.map +1 -0
- package/dist/resolvers/session.resolver.d.ts +33 -0
- package/dist/resolvers/session.resolver.js +156 -0
- package/dist/resolvers/session.resolver.js.map +1 -0
- package/dist/resolvers/user-api-key.resolver.d.ts +24 -0
- package/dist/resolvers/user-api-key.resolver.js +84 -0
- package/dist/resolvers/user-api-key.resolver.js.map +1 -0
- package/dist/resolvers/user.resolver.d.ts +75 -0
- package/dist/resolvers/user.resolver.js +289 -0
- package/dist/resolvers/user.resolver.js.map +1 -0
- package/dist/resolvers/workspace-api-key.resolver.d.ts +24 -0
- package/dist/resolvers/workspace-api-key.resolver.js +84 -0
- package/dist/resolvers/workspace-api-key.resolver.js.map +1 -0
- package/dist/resolvers/workspace.resolver.d.ts +80 -0
- package/dist/resolvers/workspace.resolver.js +211 -0
- package/dist/resolvers/workspace.resolver.js.map +1 -0
- package/dist/services/access-control.service.d.ts +52 -0
- package/dist/services/access-control.service.js +201 -0
- package/dist/services/access-control.service.js.map +1 -0
- package/dist/services/account.service.d.ts +14 -0
- package/dist/services/account.service.js +43 -0
- package/dist/services/account.service.js.map +1 -0
- package/dist/services/auth.service.d.ts +101 -0
- package/dist/services/auth.service.js +333 -0
- package/dist/services/auth.service.js.map +1 -0
- package/dist/services/invitation.service.d.ts +58 -0
- package/dist/services/invitation.service.js +386 -0
- package/dist/services/invitation.service.js.map +1 -0
- package/dist/services/member.service.d.ts +75 -0
- package/dist/services/member.service.js +390 -0
- package/dist/services/member.service.js.map +1 -0
- package/dist/services/session.service.d.ts +58 -0
- package/dist/services/session.service.js +313 -0
- package/dist/services/session.service.js.map +1 -0
- package/dist/services/user-api-key.service.d.ts +48 -0
- package/dist/services/user-api-key.service.js +260 -0
- package/dist/services/user-api-key.service.js.map +1 -0
- package/dist/services/user-deletion.service.d.ts +15 -0
- package/dist/services/user-deletion.service.js +50 -0
- package/dist/services/user-deletion.service.js.map +1 -0
- package/dist/services/user.service.d.ts +81 -0
- package/dist/services/user.service.js +479 -0
- package/dist/services/user.service.js.map +1 -0
- package/dist/services/workspace-api-key.service.d.ts +49 -0
- package/dist/services/workspace-api-key.service.js +272 -0
- package/dist/services/workspace-api-key.service.js.map +1 -0
- package/dist/services/workspace.service.d.ts +40 -0
- package/dist/services/workspace.service.js +202 -0
- package/dist/services/workspace.service.js.map +1 -0
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/dist/types/api-key-validation.type.d.ts +4 -0
- package/dist/types/api-key-validation.type.js +2 -0
- package/dist/types/api-key-validation.type.js.map +1 -0
- package/dist/types/api-key.type.d.ts +4 -0
- package/dist/types/api-key.type.js +2 -0
- package/dist/types/api-key.type.js.map +1 -0
- package/dist/types/auth-account-selector.type.d.ts +12 -0
- package/dist/types/auth-account-selector.type.js +2 -0
- package/dist/types/auth-account-selector.type.js.map +1 -0
- package/dist/types/auth-invitation-email-inviter.type.d.ts +7 -0
- package/dist/types/auth-invitation-email-inviter.type.js +2 -0
- package/dist/types/auth-invitation-email-inviter.type.js.map +1 -0
- package/dist/types/auth-maybe-promise.type.d.ts +2 -0
- package/dist/types/auth-maybe-promise.type.js +2 -0
- package/dist/types/auth-maybe-promise.type.js.map +1 -0
- package/dist/types/auth-module-provider.type.d.ts +4 -0
- package/dist/types/auth-module-provider.type.js +2 -0
- package/dist/types/auth-module-provider.type.js.map +1 -0
- package/dist/types/auth-module-roles.type.d.ts +3 -1
- package/dist/types/auth-module-social-provider-id.type.d.ts +2 -0
- package/dist/types/auth-module-social-provider-id.type.js +2 -0
- package/dist/types/auth-module-social-provider-id.type.js.map +1 -0
- package/dist/types/auth-oauth-token-endpoint-auth.type.d.ts +7 -0
- package/dist/types/auth-oauth-token-endpoint-auth.type.js +2 -0
- package/dist/types/auth-oauth-token-endpoint-auth.type.js.map +1 -0
- package/dist/types/auth-send-invitation-email.type.d.ts +7 -0
- package/dist/types/auth-send-invitation-email.type.js +2 -0
- package/dist/types/auth-send-invitation-email.type.js.map +1 -0
- package/dist/types/auth-send-reset-password.type.d.ts +7 -0
- package/dist/types/auth-send-reset-password.type.js +2 -0
- package/dist/types/auth-send-reset-password.type.js.map +1 -0
- package/dist/types/auth-send-verification-email.type.d.ts +7 -0
- package/dist/types/auth-send-verification-email.type.js +2 -0
- package/dist/types/auth-send-verification-email.type.js.map +1 -0
- package/dist/types/build-user-ability-callback.type.d.ts +10 -4
- package/dist/types/build-workspace-ability-callback.type.d.ts +10 -4
- package/dist/types/can-subject-factory.type.d.ts +1 -0
- package/dist/types/can-subject.type.d.ts +1 -0
- package/dist/types/lowercase-identifier.type.d.ts +6 -0
- package/dist/types/lowercase-identifier.type.js +2 -0
- package/dist/types/lowercase-identifier.type.js.map +1 -0
- package/dist/types/permission-name.type.d.ts +3 -0
- package/dist/types/permission-name.type.js +2 -0
- package/dist/types/permission-name.type.js.map +1 -0
- package/dist/types/role-name.type.d.ts +3 -0
- package/dist/types/role-name.type.js +2 -0
- package/dist/types/role-name.type.js.map +1 -0
- package/dist/types/route-argument-metadata.type.d.ts +1 -0
- package/dist/user.constants.d.ts +8 -2
- package/dist/user.constants.js +24 -14
- package/dist/user.constants.js.map +1 -1
- package/dist/utils/api-key-credential.util.d.ts +4 -0
- package/dist/utils/api-key-credential.util.js +16 -0
- package/dist/utils/api-key-credential.util.js.map +1 -0
- package/dist/utils/api-key-permissions.util.d.ts +6 -0
- package/dist/utils/api-key-permissions.util.js +16 -0
- package/dist/utils/api-key-permissions.util.js.map +1 -0
- package/dist/utils/append-metadata.util.d.ts +1 -0
- package/dist/utils/append-metadata.util.js +1 -0
- package/dist/utils/append-metadata.util.js.map +1 -1
- package/dist/utils/apply-auth-response-cookies.util.d.ts +1 -0
- package/dist/utils/apply-auth-response-cookies.util.js +1 -0
- package/dist/utils/apply-auth-response-cookies.util.js.map +1 -1
- package/dist/utils/auth-role.util.d.ts +8 -2
- package/dist/utils/auth-role.util.js +22 -6
- package/dist/utils/auth-role.util.js.map +1 -1
- package/dist/utils/build-request-ability.util.d.ts +7 -0
- package/dist/utils/build-request-ability.util.js +25 -0
- package/dist/utils/build-request-ability.util.js.map +1 -0
- package/dist/utils/can.util.d.ts +1 -0
- package/dist/utils/can.util.js +1 -0
- package/dist/utils/can.util.js.map +1 -1
- package/dist/utils/create-email-verification-config.d.ts +1 -0
- package/dist/utils/create-email-verification-config.js +1 -0
- package/dist/utils/create-email-verification-config.js.map +1 -1
- package/dist/utils/create-generic-oauth-config.d.ts +1 -0
- package/dist/utils/create-generic-oauth-config.js +1 -0
- package/dist/utils/create-generic-oauth-config.js.map +1 -1
- package/dist/utils/create-permission-enum.util.d.ts +2 -0
- package/dist/utils/create-permission-enum.util.js +16 -0
- package/dist/utils/create-permission-enum.util.js.map +1 -0
- package/dist/utils/create-user-config.d.ts +2 -1
- package/dist/utils/create-user-config.js +1 -0
- package/dist/utils/create-user-config.js.map +1 -1
- package/dist/utils/estimate-entropy.d.ts +7 -0
- package/dist/utils/estimate-entropy.js +7 -0
- package/dist/utils/estimate-entropy.js.map +1 -1
- package/dist/utils/extend-ability.util.d.ts +4 -0
- package/dist/utils/extend-ability.util.js +62 -0
- package/dist/utils/extend-ability.util.js.map +1 -0
- package/dist/utils/extract-api-key.util.d.ts +1 -0
- package/dist/utils/extract-api-key.util.js +1 -0
- package/dist/utils/extract-api-key.util.js.map +1 -1
- package/dist/utils/get-current-api-key.util.d.ts +3 -0
- package/dist/utils/get-current-api-key.util.js +9 -0
- package/dist/utils/get-current-api-key.util.js.map +1 -0
- package/dist/utils/get-user-ability.util.d.ts +2 -1
- package/dist/utils/get-user-ability.util.js +5 -2
- package/dist/utils/get-user-ability.util.js.map +1 -1
- package/dist/utils/get-workspace-ability.util.d.ts +2 -1
- package/dist/utils/get-workspace-ability.util.js +5 -2
- package/dist/utils/get-workspace-ability.util.js.map +1 -1
- package/dist/utils/resolve-auth-catalog.util.d.ts +7 -0
- package/dist/utils/resolve-auth-catalog.util.js +34 -0
- package/dist/utils/resolve-auth-catalog.util.js.map +1 -0
- package/dist/utils/resolve-effective-permissions.util.d.ts +9 -0
- package/dist/utils/resolve-effective-permissions.util.js +18 -0
- package/dist/utils/resolve-effective-permissions.util.js.map +1 -0
- package/dist/utils/resolve-request-permissions.util.d.ts +6 -0
- package/dist/utils/resolve-request-permissions.util.js +44 -0
- package/dist/utils/resolve-request-permissions.util.js.map +1 -0
- package/dist/utils/run-auth-query.d.ts +4 -0
- package/dist/utils/run-auth-query.js +32 -2
- package/dist/utils/run-auth-query.js.map +1 -1
- package/dist/utils/serialize-ability-rules.util.d.ts +1 -0
- package/dist/utils/serialize-ability-rules.util.js +2 -1
- package/dist/utils/serialize-ability-rules.util.js.map +1 -1
- package/dist/utils/split-auth-providers.d.ts +2 -1
- package/dist/utils/split-auth-providers.js +1 -0
- package/dist/utils/split-auth-providers.js.map +1 -1
- package/dist/utils/user-can.util.d.ts +1 -0
- package/dist/utils/user-can.util.js +3 -12
- package/dist/utils/user-can.util.js.map +1 -1
- package/dist/utils/workspace-can.util.d.ts +1 -0
- package/dist/utils/workspace-can.util.js +4 -12
- package/dist/utils/workspace-can.util.js.map +1 -1
- package/dist/workspace.constants.d.ts +10 -3
- package/dist/workspace.constants.js +24 -13
- package/dist/workspace.constants.js.map +1 -1
- package/package.json +36 -13
- package/dist/access-control.service.d.ts +0 -18
- package/dist/access-control.service.js +0 -153
- package/dist/access-control.service.js.map +0 -1
- package/dist/api-key.service.d.ts +0 -75
- package/dist/api-key.service.js +0 -332
- package/dist/api-key.service.js.map +0 -1
- package/dist/auth.service.d.ts +0 -27
- package/dist/auth.service.js +0 -199
- package/dist/auth.service.js.map +0 -1
- package/dist/decorators/current-workspace-member.decorator.d.ts +0 -1
- package/dist/decorators/current-workspace-member.decorator.js +0 -5
- package/dist/decorators/current-workspace-member.decorator.js.map +0 -1
- package/dist/entities/api-key.entity.d.ts +0 -17
- package/dist/entities/api-key.entity.js +0 -92
- package/dist/entities/api-key.entity.js.map +0 -1
- package/dist/entities/resolve-auth-relation-target.d.ts +0 -3
- package/dist/entities/resolve-auth-relation-target.js +0 -30
- package/dist/entities/resolve-auth-relation-target.js.map +0 -1
- package/dist/entities/workspace-invitation.entity.d.ts +0 -14
- package/dist/entities/workspace-invitation.entity.js +0 -74
- package/dist/entities/workspace-invitation.entity.js.map +0 -1
- package/dist/entities/workspace-member.entity.d.ts +0 -16
- package/dist/entities/workspace-member.entity.js +0 -86
- package/dist/entities/workspace-member.entity.js.map +0 -1
- package/dist/interfaces/auth-role.interface.d.ts +0 -4
- package/dist/interfaces/auth-role.interface.js +0 -2
- package/dist/interfaces/auth-role.interface.js.map +0 -1
- package/dist/interfaces/auth-service.interface.d.ts +0 -160
- package/dist/interfaces/auth-service.interface.js +0 -2
- package/dist/interfaces/auth-service.interface.js.map +0 -1
- package/dist/interfaces/session-service.interface.d.ts +0 -5
- package/dist/interfaces/session-service.interface.js +0 -2
- package/dist/interfaces/session-service.interface.js.map +0 -1
- package/dist/interfaces/user-service.interface.d.ts +0 -44
- package/dist/interfaces/user-service.interface.js +0 -2
- package/dist/interfaces/user-service.interface.js.map +0 -1
- package/dist/interfaces/workspace-service.interface.d.ts +0 -37
- package/dist/interfaces/workspace-service.interface.js +0 -2
- package/dist/interfaces/workspace-service.interface.js.map +0 -1
- package/dist/session.service.d.ts +0 -18
- package/dist/session.service.js +0 -165
- package/dist/session.service.js.map +0 -1
- package/dist/user-deletion.service.d.ts +0 -19
- package/dist/user-deletion.service.js +0 -96
- package/dist/user-deletion.service.js.map +0 -1
- package/dist/user.service.d.ts +0 -54
- package/dist/user.service.js +0 -384
- package/dist/user.service.js.map +0 -1
- package/dist/workspace.service.d.ts +0 -59
- package/dist/workspace.service.js +0 -618
- package/dist/workspace.service.js.map +0 -1
package/dist/index.d.ts
CHANGED
|
@@ -1,35 +1,206 @@
|
|
|
1
1
|
export * from "./abilities/index.js";
|
|
2
|
-
export * from "./access-control.service.js";
|
|
3
|
-
export * from "./api-key.service.js";
|
|
4
2
|
export * from "./api-key-usage.interceptor.js";
|
|
5
|
-
export { IS_PUBLIC_KEY } from "./auth.constants.js";
|
|
3
|
+
export { API_KEY, IS_PUBLIC_KEY } from "./auth.constants.js";
|
|
6
4
|
export * from "./auth.guard.js";
|
|
7
5
|
export * from "./auth.middleware.js";
|
|
8
6
|
export * from "./auth.module.js";
|
|
9
|
-
export * from "./auth.service.js";
|
|
10
7
|
export * from "./auth-module-options.interface.js";
|
|
8
|
+
export * from "./connections/index.js";
|
|
11
9
|
export * from "./decorators/index.js";
|
|
12
10
|
export * from "./entities/index.js";
|
|
13
|
-
export * from "./
|
|
14
|
-
export * from "./
|
|
11
|
+
export * from "./enums/index.js";
|
|
12
|
+
export * from "./inputs/add-member.input.js";
|
|
13
|
+
export * from "./inputs/auth-change-email.input.js";
|
|
14
|
+
export * from "./inputs/auth-change-password.input.js";
|
|
15
|
+
export * from "./inputs/auth-delete-user.input.js";
|
|
16
|
+
export * from "./inputs/auth-link-social-account.input.js";
|
|
17
|
+
export * from "./inputs/auth-request-password-reset.input.js";
|
|
18
|
+
export * from "./inputs/auth-reset-password.input.js";
|
|
19
|
+
export * from "./inputs/auth-send-verification-email.input.js";
|
|
20
|
+
export * from "./inputs/auth-sign-in.input.js";
|
|
21
|
+
export * from "./inputs/auth-sign-in-social.input.js";
|
|
22
|
+
export * from "./inputs/auth-sign-up.input.js";
|
|
23
|
+
export * from "./inputs/auth-update-user.input.js";
|
|
24
|
+
export * from "./inputs/ban-user.input.js";
|
|
25
|
+
export * from "./inputs/create-invitation.input.js";
|
|
26
|
+
export * from "./inputs/create-user.input.js";
|
|
27
|
+
export * from "./inputs/create-user-api-key.input.js";
|
|
28
|
+
export * from "./inputs/create-workspace.input.js";
|
|
29
|
+
export * from "./inputs/create-workspace-api-key.input.js";
|
|
30
|
+
export * from "./inputs/set-member-permissions.input.js";
|
|
31
|
+
export * from "./inputs/set-member-roles.input.js";
|
|
32
|
+
export * from "./inputs/set-user-password.input.js";
|
|
33
|
+
export * from "./inputs/set-user-permissions.input.js";
|
|
34
|
+
export * from "./inputs/set-user-roles.input.js";
|
|
35
|
+
export * from "./inputs/update-member.input.js";
|
|
36
|
+
export * from "./inputs/update-user.input.js";
|
|
37
|
+
export * from "./inputs/update-user-api-key.input.js";
|
|
38
|
+
export * from "./inputs/update-workspace.input.js";
|
|
39
|
+
export * from "./inputs/update-workspace-api-key.input.js";
|
|
40
|
+
export * from "./inputs/user-id.input.js";
|
|
41
|
+
export * from "./interfaces/ability-rules.interface.js";
|
|
42
|
+
export * from "./interfaces/accept-invitation-result.interface.js";
|
|
43
|
+
export * from "./interfaces/add-member-options.interface.js";
|
|
44
|
+
export * from "./interfaces/auth-access-token.interface.js";
|
|
45
|
+
export * from "./interfaces/auth-account.interface.js";
|
|
46
|
+
export * from "./interfaces/auth-account-info.interface.js";
|
|
47
|
+
export * from "./interfaces/auth-change-email-confirmation-data.interface.js";
|
|
48
|
+
export * from "./interfaces/auth-delete-account-verification-data.interface.js";
|
|
49
|
+
export * from "./interfaces/auth-email-verification-data.interface.js";
|
|
50
|
+
export * from "./interfaces/auth-invitation-email-data.interface.js";
|
|
51
|
+
export * from "./interfaces/auth-module-account-linking-options.interface.js";
|
|
52
|
+
export * from "./interfaces/auth-module-account-options.interface.js";
|
|
53
|
+
export * from "./interfaces/auth-module-api-key-options.interface.js";
|
|
54
|
+
export * from "./interfaces/auth-module-change-email-options.interface.js";
|
|
55
|
+
export * from "./interfaces/auth-module-delete-user-options.interface.js";
|
|
56
|
+
export * from "./interfaces/auth-module-email-and-password-options.interface.js";
|
|
57
|
+
export * from "./interfaces/auth-module-email-verification-options.interface.js";
|
|
58
|
+
export * from "./interfaces/auth-module-middleware-options.interface.js";
|
|
59
|
+
export * from "./interfaces/auth-module-oauth-provider.interface.js";
|
|
60
|
+
export * from "./interfaces/auth-module-password-options.interface.js";
|
|
61
|
+
export * from "./interfaces/auth-module-session-cookie-cache-options.interface.js";
|
|
62
|
+
export * from "./interfaces/auth-module-session-cookie-cache-refresh-options.interface.js";
|
|
63
|
+
export * from "./interfaces/auth-module-session-options.interface.js";
|
|
64
|
+
export * from "./interfaces/auth-module-social-provider.interface.js";
|
|
65
|
+
export * from "./interfaces/auth-module-user-options.interface.js";
|
|
66
|
+
export * from "./interfaces/auth-module-workspace-options.interface.js";
|
|
67
|
+
export * from "./interfaces/auth-oauth-basic-token-endpoint-auth.interface.js";
|
|
68
|
+
export * from "./interfaces/auth-oauth-client-assertion-context.interface.js";
|
|
69
|
+
export * from "./interfaces/auth-oauth-custom-token-endpoint-auth.interface.js";
|
|
70
|
+
export * from "./interfaces/auth-oauth-mapped-user.interface.js";
|
|
71
|
+
export * from "./interfaces/auth-oauth-no-token-endpoint-auth.interface.js";
|
|
72
|
+
export * from "./interfaces/auth-oauth-post-token-endpoint-auth.interface.js";
|
|
73
|
+
export * from "./interfaces/auth-oauth-private-key-jwt-token-endpoint-auth.interface.js";
|
|
74
|
+
export * from "./interfaces/auth-oauth-profile.interface.js";
|
|
75
|
+
export * from "./interfaces/auth-oauth-refresh-context.interface.js";
|
|
76
|
+
export * from "./interfaces/auth-oauth-token-request-client-options.interface.js";
|
|
77
|
+
export * from "./interfaces/auth-oauth-token-request-context.interface.js";
|
|
78
|
+
export * from "./interfaces/auth-oauth-tokens.interface.js";
|
|
79
|
+
export * from "./interfaces/auth-oauth-user-info.interface.js";
|
|
80
|
+
export * from "./interfaces/auth-provider-user-info.interface.js";
|
|
81
|
+
export * from "./interfaces/auth-refreshed-token.interface.js";
|
|
82
|
+
export * from "./interfaces/auth-reset-password-data.interface.js";
|
|
83
|
+
export * from "./interfaces/auth-social-provider.interface.js";
|
|
84
|
+
export * from "./interfaces/auth-social-provider-user-info.interface.js";
|
|
85
|
+
export * from "./interfaces/auth-user.interface.js";
|
|
86
|
+
export * from "./interfaces/authenticated-session.interface.js";
|
|
87
|
+
export * from "./interfaces/ban-user-options.interface.js";
|
|
15
88
|
export * from "./interfaces/can-options.interface.js";
|
|
89
|
+
export * from "./interfaces/change-auth-email-options.interface.js";
|
|
90
|
+
export * from "./interfaces/change-auth-password-options.interface.js";
|
|
91
|
+
export * from "./interfaces/change-auth-password-result.interface.js";
|
|
92
|
+
export * from "./interfaces/create-api-key-options.interface.js";
|
|
93
|
+
export * from "./interfaces/create-invitation-options.interface.js";
|
|
94
|
+
export * from "./interfaces/create-user-options.interface.js";
|
|
95
|
+
export * from "./interfaces/create-workspace-options.interface.js";
|
|
96
|
+
export * from "./interfaces/created-api-key.interface.js";
|
|
97
|
+
export * from "./interfaces/delete-auth-user-options.interface.js";
|
|
98
|
+
export * from "./interfaces/delete-auth-user-result.interface.js";
|
|
99
|
+
export * from "./interfaces/impersonation-options.interface.js";
|
|
100
|
+
export * from "./interfaces/link-auth-social-account-options.interface.js";
|
|
101
|
+
export * from "./interfaces/link-auth-social-account-result.interface.js";
|
|
102
|
+
export * from "./interfaces/request-password-reset-options.interface.js";
|
|
103
|
+
export * from "./interfaces/request-password-reset-result.interface.js";
|
|
104
|
+
export * from "./interfaces/reset-password-options.interface.js";
|
|
16
105
|
export * from "./interfaces/route-argument-metadata-value.interface.js";
|
|
17
106
|
export * from "./interfaces/scope-policy-options.interface.js";
|
|
107
|
+
export * from "./interfaces/send-verification-email-options.interface.js";
|
|
18
108
|
export * from "./interfaces/serialized-ability-rule.interface.js";
|
|
19
|
-
export * from "./interfaces/
|
|
20
|
-
export * from "./interfaces/
|
|
21
|
-
export * from "./interfaces/
|
|
109
|
+
export * from "./interfaces/sign-in-entity-result.interface.js";
|
|
110
|
+
export * from "./interfaces/sign-in-options.interface.js";
|
|
111
|
+
export * from "./interfaces/sign-in-result.interface.js";
|
|
112
|
+
export * from "./interfaces/sign-in-social-entity-result.interface.js";
|
|
113
|
+
export * from "./interfaces/sign-in-social-options.interface.js";
|
|
114
|
+
export * from "./interfaces/sign-in-social-result.interface.js";
|
|
115
|
+
export * from "./interfaces/sign-up-options.interface.js";
|
|
116
|
+
export * from "./interfaces/sign-up-result.interface.js";
|
|
117
|
+
export * from "./interfaces/unlink-auth-account-options.interface.js";
|
|
118
|
+
export * from "./interfaces/update-api-key-options.interface.js";
|
|
119
|
+
export * from "./interfaces/update-auth-user-options.interface.js";
|
|
120
|
+
export * from "./interfaces/update-member-options.interface.js";
|
|
121
|
+
export * from "./interfaces/update-user-options.interface.js";
|
|
122
|
+
export * from "./interfaces/update-workspace-options.interface.js";
|
|
123
|
+
export * from "./interfaces/user-api-key-validation.interface.js";
|
|
124
|
+
export * from "./interfaces/user-has-permissions-options.interface.js";
|
|
125
|
+
export * from "./interfaces/workspace-api-key-validation.interface.js";
|
|
126
|
+
export * from "./interfaces/workspace-has-permissions-options.interface.js";
|
|
127
|
+
export * from "./objects/accept-invitation-payload.object.js";
|
|
128
|
+
export * from "./objects/add-member-payload.object.js";
|
|
129
|
+
export * from "./objects/auth-ability-rule.object.js";
|
|
130
|
+
export * from "./objects/auth-change-password-result.object.js";
|
|
131
|
+
export * from "./objects/auth-delete-user-result.object.js";
|
|
132
|
+
export * from "./objects/auth-link-social-account-result.object.js";
|
|
133
|
+
export * from "./objects/auth-request-password-reset-result.object.js";
|
|
134
|
+
export * from "./objects/auth-sign-in-result.object.js";
|
|
135
|
+
export * from "./objects/auth-sign-in-social-result.object.js";
|
|
136
|
+
export * from "./objects/auth-social-provider.object.js";
|
|
137
|
+
export * from "./objects/ban-user-payload.object.js";
|
|
138
|
+
export * from "./objects/cancel-invitation-payload.object.js";
|
|
139
|
+
export * from "./objects/create-invitation-payload.object.js";
|
|
140
|
+
export * from "./objects/create-user-api-key-result.object.js";
|
|
141
|
+
export * from "./objects/create-user-payload.object.js";
|
|
142
|
+
export * from "./objects/create-workspace-api-key-result.object.js";
|
|
143
|
+
export * from "./objects/create-workspace-payload.object.js";
|
|
144
|
+
export * from "./objects/delete-user-payload.object.js";
|
|
145
|
+
export * from "./objects/delete-workspace-payload.object.js";
|
|
146
|
+
export * from "./objects/leave-workspace-payload.object.js";
|
|
147
|
+
export * from "./objects/reject-invitation-payload.object.js";
|
|
148
|
+
export * from "./objects/remove-member-payload.object.js";
|
|
149
|
+
export * from "./objects/set-member-permissions-payload.object.js";
|
|
150
|
+
export * from "./objects/set-member-roles-payload.object.js";
|
|
151
|
+
export * from "./objects/set-user-permissions-payload.object.js";
|
|
152
|
+
export * from "./objects/set-user-roles-payload.object.js";
|
|
153
|
+
export * from "./objects/sign-up-payload.object.js";
|
|
154
|
+
export * from "./objects/unban-user-payload.object.js";
|
|
155
|
+
export * from "./objects/update-member-payload.object.js";
|
|
156
|
+
export * from "./objects/update-user-payload.object.js";
|
|
157
|
+
export * from "./objects/update-workspace-payload.object.js";
|
|
158
|
+
export * from "./objects/user-api-key-permission-option.object.js";
|
|
159
|
+
export * from "./objects/user-permission-option.object.js";
|
|
160
|
+
export * from "./objects/user-role-option.object.js";
|
|
161
|
+
export * from "./objects/workspace-api-key-permission-option.object.js";
|
|
162
|
+
export * from "./objects/workspace-permission-option.object.js";
|
|
163
|
+
export * from "./objects/workspace-role-option.object.js";
|
|
22
164
|
export * from "./permission.constants.js";
|
|
23
165
|
export * from "./policies/index.js";
|
|
24
|
-
export * from "./
|
|
166
|
+
export * from "./resolvers/auth.resolver.js";
|
|
167
|
+
export * from "./resolvers/invitation.resolver.js";
|
|
168
|
+
export * from "./resolvers/member.resolver.js";
|
|
169
|
+
export * from "./resolvers/session.resolver.js";
|
|
170
|
+
export * from "./resolvers/user.resolver.js";
|
|
171
|
+
export * from "./resolvers/user-api-key.resolver.js";
|
|
172
|
+
export * from "./resolvers/workspace.resolver.js";
|
|
173
|
+
export * from "./resolvers/workspace-api-key.resolver.js";
|
|
174
|
+
export * from "./services/access-control.service.js";
|
|
175
|
+
export * from "./services/account.service.js";
|
|
176
|
+
export * from "./services/auth.service.js";
|
|
177
|
+
export * from "./services/invitation.service.js";
|
|
178
|
+
export * from "./services/member.service.js";
|
|
179
|
+
export * from "./services/session.service.js";
|
|
180
|
+
export * from "./services/user.service.js";
|
|
181
|
+
export * from "./services/user-api-key.service.js";
|
|
182
|
+
export * from "./services/workspace.service.js";
|
|
183
|
+
export * from "./services/workspace-api-key.service.js";
|
|
184
|
+
export type { ApiKey } from "./types/api-key.type.js";
|
|
185
|
+
export * from "./types/api-key-validation.type.js";
|
|
186
|
+
export * from "./types/auth-account-selector.type.js";
|
|
187
|
+
export * from "./types/auth-invitation-email-inviter.type.js";
|
|
188
|
+
export * from "./types/auth-maybe-promise.type.js";
|
|
189
|
+
export * from "./types/auth-module-provider.type.js";
|
|
25
190
|
export * from "./types/auth-module-roles.type.js";
|
|
191
|
+
export * from "./types/auth-module-social-provider-id.type.js";
|
|
192
|
+
export * from "./types/auth-oauth-token-endpoint-auth.type.js";
|
|
193
|
+
export * from "./types/auth-send-invitation-email.type.js";
|
|
194
|
+
export * from "./types/auth-send-reset-password.type.js";
|
|
195
|
+
export * from "./types/auth-send-verification-email.type.js";
|
|
26
196
|
export * from "./types/build-user-ability-callback.type.js";
|
|
27
197
|
export * from "./types/build-workspace-ability-callback.type.js";
|
|
28
198
|
export * from "./types/can-subject.type.js";
|
|
29
199
|
export * from "./types/can-subject-factory.type.js";
|
|
200
|
+
export * from "./types/permission-name.type.js";
|
|
201
|
+
export * from "./types/role-name.type.js";
|
|
30
202
|
export * from "./types/route-argument-metadata.type.js";
|
|
31
203
|
export * from "./user.constants.js";
|
|
32
|
-
export * from "./user.service.js";
|
|
33
204
|
export * from "./utils/can.util.js";
|
|
34
205
|
export * from "./utils/extract-api-key.util.js";
|
|
35
206
|
export * from "./utils/get-user-ability.util.js";
|
|
@@ -38,4 +209,3 @@ export * from "./utils/serialize-ability-rules.util.js";
|
|
|
38
209
|
export * from "./utils/user-can.util.js";
|
|
39
210
|
export * from "./utils/workspace-can.util.js";
|
|
40
211
|
export * from "./workspace.constants.js";
|
|
41
|
-
export * from "./workspace.service.js";
|
package/dist/index.js
CHANGED
|
@@ -1,35 +1,205 @@
|
|
|
1
1
|
export * from "./abilities/index.js";
|
|
2
|
-
export * from "./access-control.service.js";
|
|
3
|
-
export * from "./api-key.service.js";
|
|
4
2
|
export * from "./api-key-usage.interceptor.js";
|
|
5
|
-
export { IS_PUBLIC_KEY } from "./auth.constants.js";
|
|
3
|
+
export { API_KEY, IS_PUBLIC_KEY } from "./auth.constants.js";
|
|
6
4
|
export * from "./auth.guard.js";
|
|
7
5
|
export * from "./auth.middleware.js";
|
|
8
6
|
export * from "./auth.module.js";
|
|
9
|
-
export * from "./auth.service.js";
|
|
10
7
|
export * from "./auth-module-options.interface.js";
|
|
8
|
+
export * from "./connections/index.js";
|
|
11
9
|
export * from "./decorators/index.js";
|
|
12
10
|
export * from "./entities/index.js";
|
|
13
|
-
export * from "./
|
|
14
|
-
export * from "./
|
|
11
|
+
export * from "./enums/index.js";
|
|
12
|
+
export * from "./inputs/add-member.input.js";
|
|
13
|
+
export * from "./inputs/auth-change-email.input.js";
|
|
14
|
+
export * from "./inputs/auth-change-password.input.js";
|
|
15
|
+
export * from "./inputs/auth-delete-user.input.js";
|
|
16
|
+
export * from "./inputs/auth-link-social-account.input.js";
|
|
17
|
+
export * from "./inputs/auth-request-password-reset.input.js";
|
|
18
|
+
export * from "./inputs/auth-reset-password.input.js";
|
|
19
|
+
export * from "./inputs/auth-send-verification-email.input.js";
|
|
20
|
+
export * from "./inputs/auth-sign-in.input.js";
|
|
21
|
+
export * from "./inputs/auth-sign-in-social.input.js";
|
|
22
|
+
export * from "./inputs/auth-sign-up.input.js";
|
|
23
|
+
export * from "./inputs/auth-update-user.input.js";
|
|
24
|
+
export * from "./inputs/ban-user.input.js";
|
|
25
|
+
export * from "./inputs/create-invitation.input.js";
|
|
26
|
+
export * from "./inputs/create-user.input.js";
|
|
27
|
+
export * from "./inputs/create-user-api-key.input.js";
|
|
28
|
+
export * from "./inputs/create-workspace.input.js";
|
|
29
|
+
export * from "./inputs/create-workspace-api-key.input.js";
|
|
30
|
+
export * from "./inputs/set-member-permissions.input.js";
|
|
31
|
+
export * from "./inputs/set-member-roles.input.js";
|
|
32
|
+
export * from "./inputs/set-user-password.input.js";
|
|
33
|
+
export * from "./inputs/set-user-permissions.input.js";
|
|
34
|
+
export * from "./inputs/set-user-roles.input.js";
|
|
35
|
+
export * from "./inputs/update-member.input.js";
|
|
36
|
+
export * from "./inputs/update-user.input.js";
|
|
37
|
+
export * from "./inputs/update-user-api-key.input.js";
|
|
38
|
+
export * from "./inputs/update-workspace.input.js";
|
|
39
|
+
export * from "./inputs/update-workspace-api-key.input.js";
|
|
40
|
+
export * from "./inputs/user-id.input.js";
|
|
41
|
+
export * from "./interfaces/ability-rules.interface.js";
|
|
42
|
+
export * from "./interfaces/accept-invitation-result.interface.js";
|
|
43
|
+
export * from "./interfaces/add-member-options.interface.js";
|
|
44
|
+
export * from "./interfaces/auth-access-token.interface.js";
|
|
45
|
+
export * from "./interfaces/auth-account.interface.js";
|
|
46
|
+
export * from "./interfaces/auth-account-info.interface.js";
|
|
47
|
+
export * from "./interfaces/auth-change-email-confirmation-data.interface.js";
|
|
48
|
+
export * from "./interfaces/auth-delete-account-verification-data.interface.js";
|
|
49
|
+
export * from "./interfaces/auth-email-verification-data.interface.js";
|
|
50
|
+
export * from "./interfaces/auth-invitation-email-data.interface.js";
|
|
51
|
+
export * from "./interfaces/auth-module-account-linking-options.interface.js";
|
|
52
|
+
export * from "./interfaces/auth-module-account-options.interface.js";
|
|
53
|
+
export * from "./interfaces/auth-module-api-key-options.interface.js";
|
|
54
|
+
export * from "./interfaces/auth-module-change-email-options.interface.js";
|
|
55
|
+
export * from "./interfaces/auth-module-delete-user-options.interface.js";
|
|
56
|
+
export * from "./interfaces/auth-module-email-and-password-options.interface.js";
|
|
57
|
+
export * from "./interfaces/auth-module-email-verification-options.interface.js";
|
|
58
|
+
export * from "./interfaces/auth-module-middleware-options.interface.js";
|
|
59
|
+
export * from "./interfaces/auth-module-oauth-provider.interface.js";
|
|
60
|
+
export * from "./interfaces/auth-module-password-options.interface.js";
|
|
61
|
+
export * from "./interfaces/auth-module-session-cookie-cache-options.interface.js";
|
|
62
|
+
export * from "./interfaces/auth-module-session-cookie-cache-refresh-options.interface.js";
|
|
63
|
+
export * from "./interfaces/auth-module-session-options.interface.js";
|
|
64
|
+
export * from "./interfaces/auth-module-social-provider.interface.js";
|
|
65
|
+
export * from "./interfaces/auth-module-user-options.interface.js";
|
|
66
|
+
export * from "./interfaces/auth-module-workspace-options.interface.js";
|
|
67
|
+
export * from "./interfaces/auth-oauth-basic-token-endpoint-auth.interface.js";
|
|
68
|
+
export * from "./interfaces/auth-oauth-client-assertion-context.interface.js";
|
|
69
|
+
export * from "./interfaces/auth-oauth-custom-token-endpoint-auth.interface.js";
|
|
70
|
+
export * from "./interfaces/auth-oauth-mapped-user.interface.js";
|
|
71
|
+
export * from "./interfaces/auth-oauth-no-token-endpoint-auth.interface.js";
|
|
72
|
+
export * from "./interfaces/auth-oauth-post-token-endpoint-auth.interface.js";
|
|
73
|
+
export * from "./interfaces/auth-oauth-private-key-jwt-token-endpoint-auth.interface.js";
|
|
74
|
+
export * from "./interfaces/auth-oauth-profile.interface.js";
|
|
75
|
+
export * from "./interfaces/auth-oauth-refresh-context.interface.js";
|
|
76
|
+
export * from "./interfaces/auth-oauth-token-request-client-options.interface.js";
|
|
77
|
+
export * from "./interfaces/auth-oauth-token-request-context.interface.js";
|
|
78
|
+
export * from "./interfaces/auth-oauth-tokens.interface.js";
|
|
79
|
+
export * from "./interfaces/auth-oauth-user-info.interface.js";
|
|
80
|
+
export * from "./interfaces/auth-provider-user-info.interface.js";
|
|
81
|
+
export * from "./interfaces/auth-refreshed-token.interface.js";
|
|
82
|
+
export * from "./interfaces/auth-reset-password-data.interface.js";
|
|
83
|
+
export * from "./interfaces/auth-social-provider.interface.js";
|
|
84
|
+
export * from "./interfaces/auth-social-provider-user-info.interface.js";
|
|
85
|
+
export * from "./interfaces/auth-user.interface.js";
|
|
86
|
+
export * from "./interfaces/authenticated-session.interface.js";
|
|
87
|
+
export * from "./interfaces/ban-user-options.interface.js";
|
|
15
88
|
export * from "./interfaces/can-options.interface.js";
|
|
89
|
+
export * from "./interfaces/change-auth-email-options.interface.js";
|
|
90
|
+
export * from "./interfaces/change-auth-password-options.interface.js";
|
|
91
|
+
export * from "./interfaces/change-auth-password-result.interface.js";
|
|
92
|
+
export * from "./interfaces/create-api-key-options.interface.js";
|
|
93
|
+
export * from "./interfaces/create-invitation-options.interface.js";
|
|
94
|
+
export * from "./interfaces/create-user-options.interface.js";
|
|
95
|
+
export * from "./interfaces/create-workspace-options.interface.js";
|
|
96
|
+
export * from "./interfaces/created-api-key.interface.js";
|
|
97
|
+
export * from "./interfaces/delete-auth-user-options.interface.js";
|
|
98
|
+
export * from "./interfaces/delete-auth-user-result.interface.js";
|
|
99
|
+
export * from "./interfaces/impersonation-options.interface.js";
|
|
100
|
+
export * from "./interfaces/link-auth-social-account-options.interface.js";
|
|
101
|
+
export * from "./interfaces/link-auth-social-account-result.interface.js";
|
|
102
|
+
export * from "./interfaces/request-password-reset-options.interface.js";
|
|
103
|
+
export * from "./interfaces/request-password-reset-result.interface.js";
|
|
104
|
+
export * from "./interfaces/reset-password-options.interface.js";
|
|
16
105
|
export * from "./interfaces/route-argument-metadata-value.interface.js";
|
|
17
106
|
export * from "./interfaces/scope-policy-options.interface.js";
|
|
107
|
+
export * from "./interfaces/send-verification-email-options.interface.js";
|
|
18
108
|
export * from "./interfaces/serialized-ability-rule.interface.js";
|
|
19
|
-
export * from "./interfaces/
|
|
20
|
-
export * from "./interfaces/
|
|
21
|
-
export * from "./interfaces/
|
|
109
|
+
export * from "./interfaces/sign-in-entity-result.interface.js";
|
|
110
|
+
export * from "./interfaces/sign-in-options.interface.js";
|
|
111
|
+
export * from "./interfaces/sign-in-result.interface.js";
|
|
112
|
+
export * from "./interfaces/sign-in-social-entity-result.interface.js";
|
|
113
|
+
export * from "./interfaces/sign-in-social-options.interface.js";
|
|
114
|
+
export * from "./interfaces/sign-in-social-result.interface.js";
|
|
115
|
+
export * from "./interfaces/sign-up-options.interface.js";
|
|
116
|
+
export * from "./interfaces/sign-up-result.interface.js";
|
|
117
|
+
export * from "./interfaces/unlink-auth-account-options.interface.js";
|
|
118
|
+
export * from "./interfaces/update-api-key-options.interface.js";
|
|
119
|
+
export * from "./interfaces/update-auth-user-options.interface.js";
|
|
120
|
+
export * from "./interfaces/update-member-options.interface.js";
|
|
121
|
+
export * from "./interfaces/update-user-options.interface.js";
|
|
122
|
+
export * from "./interfaces/update-workspace-options.interface.js";
|
|
123
|
+
export * from "./interfaces/user-api-key-validation.interface.js";
|
|
124
|
+
export * from "./interfaces/user-has-permissions-options.interface.js";
|
|
125
|
+
export * from "./interfaces/workspace-api-key-validation.interface.js";
|
|
126
|
+
export * from "./interfaces/workspace-has-permissions-options.interface.js";
|
|
127
|
+
export * from "./objects/accept-invitation-payload.object.js";
|
|
128
|
+
export * from "./objects/add-member-payload.object.js";
|
|
129
|
+
export * from "./objects/auth-ability-rule.object.js";
|
|
130
|
+
export * from "./objects/auth-change-password-result.object.js";
|
|
131
|
+
export * from "./objects/auth-delete-user-result.object.js";
|
|
132
|
+
export * from "./objects/auth-link-social-account-result.object.js";
|
|
133
|
+
export * from "./objects/auth-request-password-reset-result.object.js";
|
|
134
|
+
export * from "./objects/auth-sign-in-result.object.js";
|
|
135
|
+
export * from "./objects/auth-sign-in-social-result.object.js";
|
|
136
|
+
export * from "./objects/auth-social-provider.object.js";
|
|
137
|
+
export * from "./objects/ban-user-payload.object.js";
|
|
138
|
+
export * from "./objects/cancel-invitation-payload.object.js";
|
|
139
|
+
export * from "./objects/create-invitation-payload.object.js";
|
|
140
|
+
export * from "./objects/create-user-api-key-result.object.js";
|
|
141
|
+
export * from "./objects/create-user-payload.object.js";
|
|
142
|
+
export * from "./objects/create-workspace-api-key-result.object.js";
|
|
143
|
+
export * from "./objects/create-workspace-payload.object.js";
|
|
144
|
+
export * from "./objects/delete-user-payload.object.js";
|
|
145
|
+
export * from "./objects/delete-workspace-payload.object.js";
|
|
146
|
+
export * from "./objects/leave-workspace-payload.object.js";
|
|
147
|
+
export * from "./objects/reject-invitation-payload.object.js";
|
|
148
|
+
export * from "./objects/remove-member-payload.object.js";
|
|
149
|
+
export * from "./objects/set-member-permissions-payload.object.js";
|
|
150
|
+
export * from "./objects/set-member-roles-payload.object.js";
|
|
151
|
+
export * from "./objects/set-user-permissions-payload.object.js";
|
|
152
|
+
export * from "./objects/set-user-roles-payload.object.js";
|
|
153
|
+
export * from "./objects/sign-up-payload.object.js";
|
|
154
|
+
export * from "./objects/unban-user-payload.object.js";
|
|
155
|
+
export * from "./objects/update-member-payload.object.js";
|
|
156
|
+
export * from "./objects/update-user-payload.object.js";
|
|
157
|
+
export * from "./objects/update-workspace-payload.object.js";
|
|
158
|
+
export * from "./objects/user-api-key-permission-option.object.js";
|
|
159
|
+
export * from "./objects/user-permission-option.object.js";
|
|
160
|
+
export * from "./objects/user-role-option.object.js";
|
|
161
|
+
export * from "./objects/workspace-api-key-permission-option.object.js";
|
|
162
|
+
export * from "./objects/workspace-permission-option.object.js";
|
|
163
|
+
export * from "./objects/workspace-role-option.object.js";
|
|
22
164
|
export * from "./permission.constants.js";
|
|
23
165
|
export * from "./policies/index.js";
|
|
24
|
-
export * from "./
|
|
166
|
+
export * from "./resolvers/auth.resolver.js";
|
|
167
|
+
export * from "./resolvers/invitation.resolver.js";
|
|
168
|
+
export * from "./resolvers/member.resolver.js";
|
|
169
|
+
export * from "./resolvers/session.resolver.js";
|
|
170
|
+
export * from "./resolvers/user.resolver.js";
|
|
171
|
+
export * from "./resolvers/user-api-key.resolver.js";
|
|
172
|
+
export * from "./resolvers/workspace.resolver.js";
|
|
173
|
+
export * from "./resolvers/workspace-api-key.resolver.js";
|
|
174
|
+
export * from "./services/access-control.service.js";
|
|
175
|
+
export * from "./services/account.service.js";
|
|
176
|
+
export * from "./services/auth.service.js";
|
|
177
|
+
export * from "./services/invitation.service.js";
|
|
178
|
+
export * from "./services/member.service.js";
|
|
179
|
+
export * from "./services/session.service.js";
|
|
180
|
+
export * from "./services/user.service.js";
|
|
181
|
+
export * from "./services/user-api-key.service.js";
|
|
182
|
+
export * from "./services/workspace.service.js";
|
|
183
|
+
export * from "./services/workspace-api-key.service.js";
|
|
184
|
+
export * from "./types/api-key-validation.type.js";
|
|
185
|
+
export * from "./types/auth-account-selector.type.js";
|
|
186
|
+
export * from "./types/auth-invitation-email-inviter.type.js";
|
|
187
|
+
export * from "./types/auth-maybe-promise.type.js";
|
|
188
|
+
export * from "./types/auth-module-provider.type.js";
|
|
25
189
|
export * from "./types/auth-module-roles.type.js";
|
|
190
|
+
export * from "./types/auth-module-social-provider-id.type.js";
|
|
191
|
+
export * from "./types/auth-oauth-token-endpoint-auth.type.js";
|
|
192
|
+
export * from "./types/auth-send-invitation-email.type.js";
|
|
193
|
+
export * from "./types/auth-send-reset-password.type.js";
|
|
194
|
+
export * from "./types/auth-send-verification-email.type.js";
|
|
26
195
|
export * from "./types/build-user-ability-callback.type.js";
|
|
27
196
|
export * from "./types/build-workspace-ability-callback.type.js";
|
|
28
197
|
export * from "./types/can-subject.type.js";
|
|
29
198
|
export * from "./types/can-subject-factory.type.js";
|
|
199
|
+
export * from "./types/permission-name.type.js";
|
|
200
|
+
export * from "./types/role-name.type.js";
|
|
30
201
|
export * from "./types/route-argument-metadata.type.js";
|
|
31
202
|
export * from "./user.constants.js";
|
|
32
|
-
export * from "./user.service.js";
|
|
33
203
|
export * from "./utils/can.util.js";
|
|
34
204
|
export * from "./utils/extract-api-key.util.js";
|
|
35
205
|
export * from "./utils/get-user-ability.util.js";
|
|
@@ -38,5 +208,4 @@ export * from "./utils/serialize-ability-rules.util.js";
|
|
|
38
208
|
export * from "./utils/user-can.util.js";
|
|
39
209
|
export * from "./utils/workspace-can.util.js";
|
|
40
210
|
export * from "./workspace.constants.js";
|
|
41
|
-
export * from "./workspace.service.js";
|
|
42
211
|
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,sBAAsB,CAAC;AACrC,cAAc,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,sBAAsB,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,yCAAyC,CAAC;AAExD,cAAc,oCAAoC,CAAC;AACnD,cAAc,uCAAuC,CAAC;AACtD,cAAc,+CAA+C,CAAC;AAC9D,cAAc,oCAAoC,CAAC;AACnD,cAAc,sCAAsC,CAAC;AACrD,cAAc,mCAAmC,CAAC;AAClD,cAAc,gDAAgD,CAAC;AAC/D,cAAc,gDAAgD,CAAC;AAC/D,cAAc,4CAA4C,CAAC;AAC3D,cAAc,0CAA0C,CAAC;AACzD,cAAc,8CAA8C,CAAC;AAC7D,cAAc,6CAA6C,CAAC;AAC5D,cAAc,kDAAkD,CAAC;AACjE,cAAc,6BAA6B,CAAC;AAC5C,cAAc,qCAAqC,CAAC;AACpD,cAAc,iCAAiC,CAAC;AAChD,cAAc,2BAA2B,CAAC;AAC1C,cAAc,yCAAyC,CAAC;AACxD,cAAc,qBAAqB,CAAC;AACpC,cAAc,qBAAqB,CAAC;AACpC,cAAc,iCAAiC,CAAC;AAChD,cAAc,kCAAkC,CAAC;AACjD,cAAc,uCAAuC,CAAC;AACtD,cAAc,yCAAyC,CAAC;AACxD,cAAc,0BAA0B,CAAC;AACzC,cAAc,+BAA+B,CAAC;AAC9C,cAAc,0BAA0B,CAAC"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { EntityManager } from "@mikro-orm/core";
|
|
2
|
+
import type { ApiKey } from "../types/api-key.type.js";
|
|
3
|
+
import type { ApiKeyValidation } from "../types/api-key-validation.type.js";
|
|
4
|
+
/** Authenticates both credential kinds; management stays in their domain services. @internal */
|
|
5
|
+
export declare class ApiKeyAuthenticationService {
|
|
6
|
+
private readonly em;
|
|
7
|
+
constructor(em: EntityManager);
|
|
8
|
+
/** Resolves one unambiguous, active credential and its owner. */
|
|
9
|
+
validate(plaintext: string): Promise<ApiKeyValidation>;
|
|
10
|
+
/** Captures the authenticating key's RLS scope before a handler can replace it. */
|
|
11
|
+
captureUsage(apiKey: ApiKey): () => Promise<ApiKey>;
|
|
12
|
+
/** Records successful use in the credential's own table. Deleted keys remain deleted. */
|
|
13
|
+
recordUsage(apiKey: ApiKey): Promise<ApiKey>;
|
|
14
|
+
}
|
|
@@ -0,0 +1,78 @@
|
|
|
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 { UserApiKey } from "../entities/user-api-key.entity.js";
|
|
14
|
+
import { WorkspaceApiKey } from "../entities/workspace-api-key.entity.js";
|
|
15
|
+
import { hashApiKey } from "../utils/api-key-credential.util.js";
|
|
16
|
+
/** Authenticates both credential kinds; management stays in their domain services. @internal */
|
|
17
|
+
let ApiKeyAuthenticationService = ApiKeyAuthenticationService_1 = class ApiKeyAuthenticationService {
|
|
18
|
+
em;
|
|
19
|
+
constructor(em) {
|
|
20
|
+
this.em = em;
|
|
21
|
+
}
|
|
22
|
+
/** Resolves one unambiguous, active credential and its owner. */
|
|
23
|
+
async validate(plaintext) {
|
|
24
|
+
if (!plaintext)
|
|
25
|
+
throw new UnauthorizedException("Missing API key");
|
|
26
|
+
const key = hashApiKey(plaintext);
|
|
27
|
+
const userKey = await this.em.findOne(UserApiKey, { key }, { populate: ["user"] });
|
|
28
|
+
const workspaceKey = await this.em.findOne(WorkspaceApiKey, { key }, { populate: ["workspace"] });
|
|
29
|
+
if ((!userKey && !workspaceKey) || (userKey && workspaceKey)) {
|
|
30
|
+
throw new UnauthorizedException("Invalid API key");
|
|
31
|
+
}
|
|
32
|
+
const apiKey = userKey ?? workspaceKey;
|
|
33
|
+
if (!apiKey)
|
|
34
|
+
throw new UnauthorizedException("Invalid API key");
|
|
35
|
+
if (!apiKey.enabled)
|
|
36
|
+
throw new UnauthorizedException("API key is disabled");
|
|
37
|
+
if (apiKey.expiresAt && apiKey.expiresAt <= new Date())
|
|
38
|
+
throw new UnauthorizedException("API key has expired");
|
|
39
|
+
if (userKey) {
|
|
40
|
+
const user = Reference.unwrapReference(userKey.user);
|
|
41
|
+
if (user.banned &&
|
|
42
|
+
(!user.banExpiresAt || user.banExpiresAt > new Date())) {
|
|
43
|
+
throw new UnauthorizedException("Invalid API key");
|
|
44
|
+
}
|
|
45
|
+
return { apiKey: userKey, ownerType: "user", user };
|
|
46
|
+
}
|
|
47
|
+
if (!workspaceKey)
|
|
48
|
+
throw new UnauthorizedException("Invalid API key");
|
|
49
|
+
const workspace = Reference.unwrapReference(workspaceKey.workspace);
|
|
50
|
+
return { apiKey: workspaceKey, ownerType: "workspace", workspace };
|
|
51
|
+
}
|
|
52
|
+
/** Captures the authenticating key's RLS scope before a handler can replace it. */
|
|
53
|
+
captureUsage(apiKey) {
|
|
54
|
+
// Forking copies the session context without changing the request identity.
|
|
55
|
+
// An existing transaction remains attached; unrelated pending writes do not.
|
|
56
|
+
const recorder = new ApiKeyAuthenticationService_1(this.em.fork({ useContext: false, keepTransactionContext: true }));
|
|
57
|
+
return () => recorder.recordUsage(apiKey);
|
|
58
|
+
}
|
|
59
|
+
/** Records successful use in the credential's own table. Deleted keys remain deleted. */
|
|
60
|
+
async recordUsage(apiKey) {
|
|
61
|
+
const now = new Date();
|
|
62
|
+
apiKey.lastUsedAt = now;
|
|
63
|
+
apiKey.updatedAt = now;
|
|
64
|
+
if (apiKey instanceof UserApiKey) {
|
|
65
|
+
await this.em.nativeUpdate(UserApiKey, { id: apiKey.id }, { lastUsedAt: now, updatedAt: now });
|
|
66
|
+
}
|
|
67
|
+
else {
|
|
68
|
+
await this.em.nativeUpdate(WorkspaceApiKey, { id: apiKey.id }, { lastUsedAt: now, updatedAt: now });
|
|
69
|
+
}
|
|
70
|
+
return apiKey;
|
|
71
|
+
}
|
|
72
|
+
};
|
|
73
|
+
ApiKeyAuthenticationService = ApiKeyAuthenticationService_1 = __decorate([
|
|
74
|
+
Injectable(),
|
|
75
|
+
__metadata("design:paramtypes", [EntityManager])
|
|
76
|
+
], ApiKeyAuthenticationService);
|
|
77
|
+
export { ApiKeyAuthenticationService };
|
|
78
|
+
//# sourceMappingURL=api-key-authentication.service.js.map
|
|
@@ -0,0 +1 @@
|
|
|
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,UAAU,EAAE,MAAM,oCAAoC,CAAC;AAChE,OAAO,EAAE,eAAe,EAAE,MAAM,yCAAyC,CAAC;AAG1E,OAAO,EAAE,UAAU,EAAE,MAAM,qCAAqC,CAAC;AAEjE,gGAAgG;AAEzF,IAAM,2BAA2B,mCAAjC,MAAM,2BAA2B;IACT;IAA7B,YAA6B,EAAiB;QAAjB,OAAE,GAAF,EAAE,CAAe;IAAG,CAAC;IAElD,iEAAiE;IACjE,KAAK,CAAC,QAAQ,CAAC,SAAiB;QAC9B,IAAI,CAAC,SAAS;YAAE,MAAM,IAAI,qBAAqB,CAAC,iBAAiB,CAAC,CAAC;QACnE,MAAM,GAAG,GAAG,UAAU,C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Y,2BAA2B;IADvC,UAAU,EAAE;qCAEsB,aAAa;GADnC,2BAA2B,CAsEvC"}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { UserAbility } from "../abilities/user.ability.js";
|
|
2
|
+
import { WorkspaceAbility } from "../abilities/workspace.ability.js";
|
|
3
|
+
import { User } from "../entities/user.entity.js";
|
|
4
|
+
import { Workspace } from "../entities/workspace.entity.js";
|
|
5
|
+
import type { AuthModuleUserOptions } from "../interfaces/auth-module-user-options.interface.js";
|
|
6
|
+
import type { AuthModuleWorkspaceOptions } from "../interfaces/auth-module-workspace-options.interface.js";
|
|
7
|
+
/** Owns built-in permission mappings and validates business extensions. @internal */
|
|
8
|
+
export declare class AuthAbilityFactory {
|
|
9
|
+
/** Builds auth rules and restricted extensions from already credential-limited permissions. */
|
|
10
|
+
static createUserAbility(permissions: readonly string[], user: User, options?: AuthModuleUserOptions): UserAbility;
|
|
11
|
+
/** Builds auth rules and restricted extensions from already credential-limited permissions. */
|
|
12
|
+
static createWorkspaceAbility(permissions: readonly string[], workspace: Workspace, options?: AuthModuleWorkspaceOptions): WorkspaceAbility;
|
|
13
|
+
/** Keeps class checks, tagged objects, and serialized frontend names equivalent. */
|
|
14
|
+
private static addSubjectAliases;
|
|
15
|
+
}
|