@frontegg/client
Advanced tools
Comparing version 1.0.66 to 1.0.67
import { AuditsClient } from './src/audits'; | ||
import { FronteggAuthenticator } from './src/authenticator'; | ||
import { withAuthentication } from './src/identity'; | ||
import { contextResolver, withAuthentication } from './src/identity'; | ||
import { frontegg, IFronteggOptions } from './src/middleware'; | ||
@@ -11,2 +11,2 @@ import { NotificationsClient } from './src/notifications'; | ||
export * from './src/events'; | ||
export { AuditsClient, NotificationsClient, TenantsClient, frontegg, FronteggPermissions, IFronteggOptions, FronteggAuthenticator, RbacMiddleware, SsoClient, withAuthentication, }; | ||
export { AuditsClient, NotificationsClient, TenantsClient, frontegg, FronteggPermissions, IFronteggOptions, FronteggAuthenticator, RbacMiddleware, SsoClient, withAuthentication, contextResolver, }; |
@@ -11,2 +11,3 @@ "use strict"; | ||
var identity_1 = require("./src/identity"); | ||
exports.contextResolver = identity_1.contextResolver; | ||
exports.withAuthentication = identity_1.withAuthentication; | ||
@@ -13,0 +14,0 @@ var middleware_1 = require("./src/middleware"); |
@@ -42,2 +42,3 @@ "use strict"; | ||
var logger_1 = require("../helpers/logger"); | ||
var middleware_1 = require("../middleware"); | ||
var IdentityClient = /** @class */ (function () { | ||
@@ -78,3 +79,3 @@ function IdentityClient() { | ||
logger_1.default.info('going to authenticate'); | ||
return [4 /*yield*/, authenticator.init(process.env.FRONTEGG_CLIENT_ID || '', process.env.FRONTEGG_API_KEY || '')]; | ||
return [4 /*yield*/, authenticator.init(middleware_1.FRONTEGG_CLIENT_ID || process.env.FRONTEGG_CLIENT_ID || '', middleware_1.FRONTEGG_API_KEY || process.env.FRONTEGG_API_KEY || '')]; | ||
case 1: | ||
@@ -81,0 +82,0 @@ _a.sent(); |
export { IdentityClient } from './identity-client'; | ||
export { withAuthentication } from './with-authentication'; | ||
export { contextResolver } from './contextResolver'; |
@@ -7,2 +7,4 @@ "use strict"; | ||
exports.withAuthentication = with_authentication_1.withAuthentication; | ||
var contextResolver_1 = require("./contextResolver"); | ||
exports.contextResolver = contextResolver_1.contextResolver; | ||
//# sourceMappingURL=index.js.map |
import { NextFunction, Request, Response } from 'express'; | ||
import { FronteggPermissions } from '../permissions'; | ||
export declare let FRONTEGG_CLIENT_ID: string; | ||
export declare let FRONTEGG_API_KEY: string; | ||
declare type fronteggContextResolver = (req: Request) => Promise<{ | ||
@@ -4,0 +6,0 @@ tenantId: string; |
@@ -198,2 +198,4 @@ "use strict"; | ||
} | ||
exports.FRONTEGG_CLIENT_ID = options.clientId; | ||
exports.FRONTEGG_API_KEY = options.apiKey; | ||
authenticator.init(options.clientId, options.apiKey); | ||
@@ -200,0 +202,0 @@ proxy.on('error', function (err, req, res, _) { return __awaiter(_this, void 0, void 0, function () { |
import { AuditsClient } from './src/audits'; | ||
import { FronteggAuthenticator } from './src/authenticator'; | ||
import { withAuthentication } from './src/identity'; | ||
import { contextResolver, withAuthentication } from './src/identity'; | ||
import { frontegg, IFronteggOptions } from './src/middleware'; | ||
@@ -23,2 +23,3 @@ import { NotificationsClient } from './src/notifications'; | ||
withAuthentication, | ||
contextResolver, | ||
}; |
{ | ||
"name": "@frontegg/client", | ||
"version": "1.0.66", | ||
"version": "1.0.67", | ||
"description": "Frontegg Javascript Library for backend", | ||
@@ -5,0 +5,0 @@ "main": "dist/index.js", |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
202357
92
3015