1 |
|
2 |
|
3 |
|
4 |
|
5 |
|
6 |
|
7 |
|
8 | import { Activity, BotFrameworkClient, InvokeResponse } from 'botbuilder-core';
|
9 | import { AppCredentials, ICredentialProvider } from 'botframework-connector';
|
10 |
|
11 |
|
12 |
|
13 | export declare class BotFrameworkHttpClient implements BotFrameworkClient {
|
14 | protected readonly channelService: string;
|
15 | |
16 |
|
17 |
|
18 |
|
19 | private static readonly appCredentialMapCache;
|
20 | private readonly credentialProvider;
|
21 | |
22 |
|
23 |
|
24 |
|
25 |
|
26 | constructor(credentialProvider: ICredentialProvider, channelService?: string);
|
27 | /**
|
28 | * Forwards an activity to another bot.
|
29 | * @remarks
|
30 | *
|
31 | * @template T The type of body in the InvokeResponse.
|
32 | * @param fromBotId The MicrosoftAppId of the bot sending the activity.
|
33 | * @param toBotId The MicrosoftAppId of the bot receiving the activity.
|
34 | * @param toUrl The URL of the bot receiving the activity.
|
35 | * @param serviceUrl The callback Url for the skill host.
|
36 | * @param conversationId A conversation ID to use for the conversation with the skill.
|
37 | * @param activity Activity to forward.
|
38 | */
|
39 | postActivity<T = any>(fromBotId: string, toBotId: string, toUrl: string, serviceUrl: string, conversationId: string, activity: Activity): Promise<InvokeResponse<T>>;
|
40 | /**
|
41 | * Logic to build an [AppCredentials](xref:botframework-connector.AppCredentials) to be used to acquire tokens for this `HttpClient`.
|
42 | * @param appId The application id.
|
43 | * @param oAuthScope Optional. The OAuth scope.
|
44 | *
|
45 | * @returns The app credentials to be used to acquire tokens.
|
46 | */
|
47 | protected buildCredentials(appId: string, oAuthScope?: string): Promise<AppCredentials>;
|
48 | /**
|
49 | * Gets the application credentials. App Credentials are cached so as to ensure we are not refreshing
|
50 | * token every time.
|
51 | * @private
|
52 | * @param appId The application identifier (AAD Id for the bot).
|
53 | * @param oAuthScope The scope for the token, skills will use the Skill App Id.
|
54 | */
|
55 | private getAppCredentials;
|
56 | }
|
57 | //# sourceMappingURL=botFrameworkHttpClient.d.ts.map |
\ | No newline at end of file |