@microsoft/teams.api
Version:
<p> <a href="https://www.npmjs.com/package/@microsoft/teams.api" target="_blank"> <img src="https://img.shields.io/npm/v/@microsoft/teams.api/latest" /> </a> <a href="https://www.npmjs.com/package/@microsoft/teams.api?activeTab=code" t
48 lines (45 loc) • 859 B
TypeScript
import { CallerType } from './caller.js';
/**
* any authorized token
*/
interface IToken {
/**
* the app id
*/
appId: string;
/**
* the app display name
*/
appDisplayName?: string;
/**
* the tenant id
*/
tenantId?: string;
/**
* the service url to send responses to
*/
serviceUrl: string;
/**
* where the activity originated from
*/
from: CallerType;
/**
* the id of the activity sender
*/
fromId: string;
/**
* the expiration of the token since epoch
* in milliseconds
*/
expiration?: number;
/**
* check if the token is expired
* @param bufferMs default 5min
*/
isExpired(bufferMs?: number): boolean;
/**
* string form of the token
*/
toString(): string;
}
export type { IToken };