UNPKG

botframework-connector

Version:

Bot Connector is autorest generated connector client.

39 lines 1.66 kB
/** * @module botframework-connector */ /** * Copyright (c) Microsoft Corporation. All rights reserved. * Licensed under the MIT License. */ import { ClaimsIdentity } from './claimsIdentity'; import { AuthenticationConfiguration } from './authenticationConfiguration'; /** * @deprecated Use `ConfigurationBotFrameworkAuthentication` instead to perform AseChannel validation. * Validates and Examines JWT tokens from the Bot Framework AseChannel */ export declare namespace AseChannelValidation { let MetadataUrl: string; /** * init authentication from user .env configuration. * * @param configuration The user .env configuration. */ function init(configuration: any): void; /** * Determines if a given Auth header is from the Bot Framework AseChannel * * @param {string} channelId The channelId. * @returns {boolean} True, if the token was issued by the AseChannel. Otherwise, false. */ function isTokenFromAseChannel(channelId: string): boolean; /** * Validate the incoming Auth Header as a token sent from the Bot Framework AseChannel. * A token issued by the Bot Framework will FAIL this check. Only AseChannel tokens will pass. * * @param {string} authHeader The raw HTTP header in the format: 'Bearer [longString]' * @param {AuthenticationConfiguration} authConfig The authentication configuration. * @returns {Promise<ClaimsIdentity>} A valid ClaimsIdentity. */ function authenticateAseChannelToken(authHeader: string, authConfig?: AuthenticationConfiguration): Promise<ClaimsIdentity>; } //# sourceMappingURL=aseChannelValidation.d.ts.map