1 | // Copyright (c) Microsoft Corporation.
|
2 | // Licensed under the MIT License.
|
3 |
|
4 | import { BotFrameworkAuthentication, ClaimsIdentity } from 'botframework-connector';
|
5 | import { ChannelServiceHandlerBase } from './channelServiceHandlerBase';
|
6 |
|
7 | export class CloudChannelServiceHandler extends ChannelServiceHandlerBase {
|
8 | constructor(private readonly auth: BotFrameworkAuthentication) {
|
9 | super();
|
10 | }
|
11 |
|
12 | protected async authenticate(authHeader: string): Promise<ClaimsIdentity> {
|
13 | return this.auth.authenticateChannelRequest(authHeader);
|
14 | }
|
15 | }
|