共用方式為


ServiceClientCredentialsFactory class

ServiceClientCredentialsFactory 抽象類,可讓 Bot 提供自己的 ServiceClientCredentials,讓 Bot 對 Bot 通道或技能 Bot 傳送至父 Bot 呼叫。

方法

createCredentials(string, string | undefined, string, boolean)

用來建立 ServiceClientCredentials 的 Factory 方法。

isAuthenticationDisabled()

檢查 Bot 驗證是否已停用。

isValidAppId(string)

驗證應用程式識別碼。

方法詳細資料

createCredentials(string, string | undefined, string, boolean)

用來建立 ServiceClientCredentials 的 Factory 方法。

function createCredentials(appId: string, audience: string | undefined, loginEndpoint: string, validateAuthority: boolean): Promise<ServiceClientCredentials>

參數

appId

string

appId。

audience

string | undefined

觀眾。

loginEndpoint

string

登入 URL。

validateAuthority

boolean

要使用的驗證授權單位值。

傳回

Promise<ServiceClientCredentials>

ServiceClientCredentials

isAuthenticationDisabled()

檢查 Bot 驗證是否已停用。

function isAuthenticationDisabled(): Promise<boolean>

傳回

Promise<boolean>

如果已停用 Bot 驗證,則結果為 true;否則為 false。

isValidAppId(string)

驗證應用程式識別碼。

function isValidAppId(appId: string): Promise<boolean>

參數

appId

string

要驗證的應用程式識別碼。

傳回

Promise<boolean>

如果 appId 對控制器有效,則結果為 true;否則為 false。