package.dist.src.auth-client.js Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of sdk Show documentation
Show all versions of sdk Show documentation
Client SDK for Momento services
The newest version!
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.AuthClient = void 0;
const internal_auth_client_1 = require("./internal/internal-auth-client");
const AbstractAuthClient_1 = require("@gomomento/sdk-core/dist/src/internal/clients/auth/AbstractAuthClient");
const sdk_core_1 = require("@gomomento/sdk-core");
class AuthClient extends AbstractAuthClient_1.AbstractAuthClient {
constructor(props) {
var _a;
const allProps = {
...props,
credentialProvider: (_a = props.credentialProvider) !== null && _a !== void 0 ? _a : (0, sdk_core_1.getDefaultCredentialProvider)(),
};
const authClient = new internal_auth_client_1.InternalAuthClient(allProps);
super({ createAuthClient: () => authClient });
}
}
exports.AuthClient = AuthClient;
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYXV0aC1jbGllbnQuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi9zcmMvYXV0aC1jbGllbnQudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6Ijs7O0FBQUEsMEVBQW1FO0FBRW5FLDhHQUF5RztBQUd6RyxrREFBaUU7QUFFakUsTUFBYSxVQUFXLFNBQVEsdUNBQWtCO0lBQ2hELFlBQVksS0FBc0I7O1FBQ2hDLE1BQU0sUUFBUSxHQUF1QjtZQUNuQyxHQUFHLEtBQUs7WUFDUixrQkFBa0IsRUFDaEIsTUFBQSxLQUFLLENBQUMsa0JBQWtCLG1DQUFJLElBQUEsdUNBQTRCLEdBQUU7U0FDN0QsQ0FBQztRQUNGLE1BQU0sVUFBVSxHQUFHLElBQUkseUNBQWtCLENBQUMsUUFBUSxDQUFDLENBQUM7UUFFcEQsS0FBSyxDQUFDLEVBQUMsZ0JBQWdCLEVBQUUsR0FBRyxFQUFFLENBQUMsVUFBVSxFQUFDLENBQUMsQ0FBQztJQUM5QyxDQUF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