@microsoft/teams-js
Version:
Microsoft Client SDK for building app for Microsoft hosts
42 lines (41 loc) • 1.69 kB
TypeScript
/**
* Interact with the user's calendar, including opening calendar items and composing meetings.
* @module
*/
/**
* Opens a calendar item.
*
* @param openCalendarItemParams - object containing unique ID of the calendar item to be opened.
*/
export declare function openCalendarItem(openCalendarItemParams: OpenCalendarItemParams): Promise<void>;
/**
* Compose a new meeting in the user's calendar.
*
* @param composeMeetingParams - object containing various properties to set up the meeting details.
*/
export declare function composeMeeting(composeMeetingParams: ComposeMeetingParams): Promise<void>;
/**
* Checks if the calendar capability is supported by the host
* @returns boolean to represent whether the calendar capability is supported
*
* @throws Error if {@linkcode app.initialize} has not successfully completed
*/
export declare function isSupported(): boolean;
/** Open calendar item parameters. */
export interface OpenCalendarItemParams {
/** An unique base64-encoded string id that represents the event's unique identifier of the calendar item to be opened. */
itemId: string;
}
/** Compose meeting parameters */
export interface ComposeMeetingParams {
/** An array of email addresses, user name, or user id of the attendees to invite to the meeting. */
attendees?: string[];
/** The start time of the meeting in MM/DD/YYYY HH:MM:SS format. */
startTime?: string;
/** The end time of the meeting in MM/DD/YYYY HH:MM:SS format. */
endTime?: string;
/** The subject line of the meeting. */
subject?: string;
/** The body content of the meeting. */
content?: string;
}