async sendSignInCardAsync(context) {
        const state = Buffer.from(
            JSON.stringify({
                nonce: Crypto.randomBytes(32).toString('base64'),
                user: context.activity.from.id,
            })
        ).toString('hex');
        const authorizationUrl = await this.getAuthorizationUrl(state, `${context.fusebit.baseUrl}/callback`);
        Sdk.debug('AUTHORIZATION URL', authorizationUrl);
        const startAuthorizationUrl = [
            context.fusebit.baseUrl,
            '/start-oauth',
            `?authorizationUrl=${encodeURIComponent(authorizationUrl)}`,
        ].join('');
        const card = CardFactory.signinCard('Sign in', startAuthorizationUrl, `Welcome to ${context.fusebit.configuration.vendor_name}`);
        const response = await context.sendActivity(MessageFactory.attachment(card));
        await context.fusebit.storage.put(
            { data: { status: 'authenticating', state, timestamp: Date.now(), cardActivityId: response.id } },
            this.getStorageIdForTeamsUser(context.activity.from.id)
        );
    }
/**
     * Sends a signin card to the Microsoft Teams user which allows the user to log into the vendor's system
     * to establish an association with the the vendor's user.
     * @param {TurnContext} context The turn context
     */
Sends a signin card to the Microsoft Teams user which allows the user to log into the vendor's system
to establish an association with the the vendor's user.
@param {TurnContext} context The turn context
Sends a signin card to the Microsoft Teams user which allows the user to log into the vendor ' s system to establish an association with the the vendor ' s user . @param { TurnContext } context The turn context
async sendSignInCardAsync(context) {
        const state = Buffer.from(
            JSON.stringify({
                nonce: Crypto.randomBytes(32).toString('base64'),
                user: context.activity.from.id,
            })
        ).toString('hex');
        const authorizationUrl = await this.getAuthorizationUrl(state, `${context.fusebit.baseUrl}/callback`);
        Sdk.debug('AUTHORIZATION URL', authorizationUrl);
        const startAuthorizationUrl = [
            context.fusebit.baseUrl,
            '/start-oauth',
            `?authorizationUrl=${encodeURIComponent(authorizationUrl)}`,
        ].join('');
        const card = CardFactory.signinCard('Sign in', startAuthorizationUrl, `Welcome to ${context.fusebit.configuration.vendor_name}`);
        const response = await context.sendActivity(MessageFactory.attachment(card));
        await context.fusebit.storage.put(
            { data: { status: 'authenticating', state, timestamp: Date.now(), cardActivityId: response.id } },
            this.getStorageIdForTeamsUser(context.activity.from.id)
        );
    }
async sendSignInCardAsync ( context ) { const state = Buffer . from ( JSON . stringify ( { nonce : Crypto . randomBytes ( 32 ) . toString ( 'base64' ) , user : context . activity . from . id , } ) ) . toString ( 'hex' ) ; const authorizationUrl = await this . getAuthorizationUrl ( state , ` ${ context . fusebit . baseUrl } ` ) ; Sdk . debug ( 'AUTHORIZATION URL' , authorizationUrl ) ; const startAuthorizationUrl = [ context . fusebit . baseUrl , '/start-oauth' , ` ${ encodeURIComponent ( authorizationUrl ) } ` , ] . join ( '' ) ; const card = CardFactory . signinCard ( 'Sign in' , startAuthorizationUrl , ` ${ context . fusebit . configuration . vendor_name } ` ) ; const response = await context . sendActivity ( MessageFactory . attachment ( card ) ) ; await context . fusebit . storage . put ( { data : { status : 'authenticating' , state , timestamp : Date . now ( ) , cardActivityId : response . id } } , this . getStorageIdForTeamsUser ( context . activity . from . id ) ) ; }
Sends a signin card to the Microsoft Teams user which allows the user to log into the vendor's system
 to establish an association with the the vendor's user.
Sends a signin card to the Microsoft Teams user which allows the user to log into the vendor ' s system to establish an association with the the vendor ' s user .