import * as msRest from "@azure/ms-rest-js"; import * as Models from "../models"; import { Office365ConnectorContext } from "../office365ConnectorContext"; /** Class representing a Mail. */ export declare class Mail { private readonly client; /** * Create a Mail. * @param {Office365ConnectorContext} client Reference to the service client. */ constructor(client: Office365ConnectorContext); /** * This operation gets emails from a folder. * @summary Get emails * @param [options] The optional parameters * @deprecated This operation is deprecated. Please do not use it any longer. * @returns Promise */ getEmails(options?: Models.MailGetEmailsOptionalParams): Promise; /** * @param callback The callback * @deprecated This operation is deprecated. Please do not use it any longer. */ getEmails(callback: msRest.ServiceCallback): void; /** * @param options The optional parameters * @param callback The callback * @deprecated This operation is deprecated. Please do not use it any longer. */ getEmails(options: Models.MailGetEmailsOptionalParams, callback: msRest.ServiceCallback): void; /** * This operation sends an email message. * @summary Send an email * @param emailMessage Email. * @param [options] The optional parameters * @deprecated This operation is deprecated. Please do not use it any longer. * @returns Promise */ sendEmail(emailMessage: Models.ClientSendMessage, options?: msRest.RequestOptionsBase): Promise; /** * @param emailMessage Email. * @param callback The callback * @deprecated This operation is deprecated. Please do not use it any longer. */ sendEmail(emailMessage: Models.ClientSendMessage, callback: msRest.ServiceCallback): void; /** * @param emailMessage Email. * @param options The optional parameters * @param callback The callback * @deprecated This operation is deprecated. Please do not use it any longer. */ sendEmail(emailMessage: Models.ClientSendMessage, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; /** * This operation flags an email. * @summary Flag email * @param messageId Id of the email to be flagged. * @param [options] The optional parameters * @deprecated This operation is deprecated. Please do not use it any longer. * @returns Promise */ flag(messageId: string, options?: msRest.RequestOptionsBase): Promise; /** * @param messageId Id of the email to be flagged. * @param callback The callback * @deprecated This operation is deprecated. Please do not use it any longer. */ flag(messageId: string, callback: msRest.ServiceCallback): void; /** * @param messageId Id of the email to be flagged. * @param options The optional parameters * @param callback The callback * @deprecated This operation is deprecated. Please do not use it any longer. */ flag(messageId: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; /** * This operation marks an email as having been read. * @summary Mark as read * @param messageId Id of the email to be marked as read. * @param [options] The optional parameters * @deprecated This operation is deprecated. Please do not use it any longer. * @returns Promise */ markAsRead(messageId: string, options?: msRest.RequestOptionsBase): Promise; /** * @param messageId Id of the email to be marked as read. * @param callback The callback * @deprecated This operation is deprecated. Please do not use it any longer. */ markAsRead(messageId: string, callback: msRest.ServiceCallback): void; /** * @param messageId Id of the email to be marked as read. * @param options The optional parameters * @param callback The callback * @deprecated This operation is deprecated. Please do not use it any longer. */ markAsRead(messageId: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; /** * This operation moves an email to the specified folder. * @summary Move email * @param messageId Id of the email to be moved. * @param folderPath Mail folder to move the email to. * @param [options] The optional parameters * @deprecated This operation is deprecated. Please do not use it any longer. * @returns Promise */ move(messageId: string, folderPath: string, options?: msRest.RequestOptionsBase): Promise; /** * @param messageId Id of the email to be moved. * @param folderPath Mail folder to move the email to. * @param callback The callback * @deprecated This operation is deprecated. Please do not use it any longer. */ move(messageId: string, folderPath: string, callback: msRest.ServiceCallback): void; /** * @param messageId Id of the email to be moved. * @param folderPath Mail folder to move the email to. * @param options The optional parameters * @param callback The callback * @deprecated This operation is deprecated. Please do not use it any longer. */ move(messageId: string, folderPath: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; /** * This operation replies to an email. * @summary Reply to email * @param messageId Id of the email to reply to. * @param comment Reply comment. * @param [options] The optional parameters * @deprecated This operation is deprecated. Please do not use it any longer. * @returns Promise */ replyTo(messageId: string, comment: string, options?: Models.MailReplyToOptionalParams): Promise; /** * @param messageId Id of the email to reply to. * @param comment Reply comment. * @param callback The callback * @deprecated This operation is deprecated. Please do not use it any longer. */ replyTo(messageId: string, comment: string, callback: msRest.ServiceCallback): void; /** * @param messageId Id of the email to reply to. * @param comment Reply comment. * @param options The optional parameters * @param callback The callback * @deprecated This operation is deprecated. Please do not use it any longer. */ replyTo(messageId: string, comment: string, options: Models.MailReplyToOptionalParams, callback: msRest.ServiceCallback): void; /** * This operation deletes an email by id. * @summary Delete email * @param messageId Id of the email to delete. * @param [options] The optional parameters * @deprecated This operation is deprecated. Please do not use it any longer. * @returns Promise */ deleteEmail(messageId: string, options?: msRest.RequestOptionsBase): Promise; /** * @param messageId Id of the email to delete. * @param callback The callback * @deprecated This operation is deprecated. Please do not use it any longer. */ deleteEmail(messageId: string, callback: msRest.ServiceCallback): void; /** * @param messageId Id of the email to delete. * @param options The optional parameters * @param callback The callback * @deprecated This operation is deprecated. Please do not use it any longer. */ deleteEmail(messageId: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; /** * This operation gets an email by id. * @summary Get email * @param messageId Id of the email. * @param [options] The optional parameters * @deprecated This operation is deprecated. Please do not use it any longer. * @returns Promise */ getEmail(messageId: string, options?: Models.MailGetEmailOptionalParams): Promise; /** * @param messageId Id of the email. * @param callback The callback * @deprecated This operation is deprecated. Please do not use it any longer. */ getEmail(messageId: string, callback: msRest.ServiceCallback): void; /** * @param messageId Id of the email. * @param options The optional parameters * @param callback The callback * @deprecated This operation is deprecated. Please do not use it any longer. */ getEmail(messageId: string, options: Models.MailGetEmailOptionalParams, callback: msRest.ServiceCallback): void; /** * This operation gets an email attachment by id. * @summary Get attachment * @param messageId Id of the email. * @param attachmentId Id of the attachment to download. * @param [options] The optional parameters * @deprecated This operation is deprecated. Please do not use it any longer. * @returns Promise */ getAttachment(messageId: string, attachmentId: string, options?: msRest.RequestOptionsBase): Promise; /** * @param messageId Id of the email. * @param attachmentId Id of the attachment to download. * @param callback The callback * @deprecated This operation is deprecated. Please do not use it any longer. */ getAttachment(messageId: string, attachmentId: string, callback: msRest.ServiceCallback): void; /** * @param messageId Id of the email. * @param attachmentId Id of the attachment to download. * @param options The optional parameters * @param callback The callback * @deprecated This operation is deprecated. Please do not use it any longer. */ getAttachment(messageId: string, attachmentId: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; /** * This operation deletes an email by id. * @summary Delete email (V2) * @param messageId Id of the email to delete. * @param [options] The optional parameters * @returns Promise */ deleteEmailV2(messageId: string, options?: Models.MailDeleteEmailV2OptionalParams): Promise; /** * @param messageId Id of the email to delete. * @param callback The callback */ deleteEmailV2(messageId: string, callback: msRest.ServiceCallback): void; /** * @param messageId Id of the email to delete. * @param options The optional parameters * @param callback The callback */ deleteEmailV2(messageId: string, options: Models.MailDeleteEmailV2OptionalParams, callback: msRest.ServiceCallback): void; /** * This operation gets an email attachment by id. * @summary Get Attachment (V2) * @param messageId Id of the email. * @param attachmentId Id of the attachment to download. * @param [options] The optional parameters * @returns Promise */ getAttachmentV2(messageId: string, attachmentId: string, options?: Models.MailGetAttachmentV2OptionalParams): Promise; /** * @param messageId Id of the email. * @param attachmentId Id of the attachment to download. * @param callback The callback */ getAttachmentV2(messageId: string, attachmentId: string, callback: msRest.ServiceCallback): void; /** * @param messageId Id of the email. * @param attachmentId Id of the attachment to download. * @param options The optional parameters * @param callback The callback */ getAttachmentV2(messageId: string, attachmentId: string, options: Models.MailGetAttachmentV2OptionalParams, callback: msRest.ServiceCallback): void; /** * This operation updates an email flag. * @summary Flag email (V2) * @param messageId Id of the email to be flagged. * @param [options] The optional parameters * @returns Promise */ flagV2(messageId: string, options?: Models.MailFlagV2OptionalParams): Promise; /** * @param messageId Id of the email to be flagged. * @param callback The callback */ flagV2(messageId: string, callback: msRest.ServiceCallback): void; /** * @param messageId Id of the email to be flagged. * @param options The optional parameters * @param callback The callback */ flagV2(messageId: string, options: Models.MailFlagV2OptionalParams, callback: msRest.ServiceCallback): void; /** * This operation marks an email as read/unread. * @summary Mark as read or unread (V2) * @param messageId Id of the email to be marked. * @param [options] The optional parameters * @returns Promise */ markAsReadV2(messageId: string, options?: Models.MailMarkAsReadV2OptionalParams): Promise; /** * @param messageId Id of the email to be marked. * @param callback The callback */ markAsReadV2(messageId: string, callback: msRest.ServiceCallback): void; /** * @param messageId Id of the email to be marked. * @param options The optional parameters * @param callback The callback */ markAsReadV2(messageId: string, options: Models.MailMarkAsReadV2OptionalParams, callback: msRest.ServiceCallback): void; /** * This operation marks an email as read/unread. * @summary Mark as read or unread (V3) * @param messageId Id of the email to be marked. * @param [options] The optional parameters * @returns Promise */ markAsReadV3(messageId: string, options?: Models.MailMarkAsReadV3OptionalParams): Promise; /** * @param messageId Id of the email to be marked. * @param callback The callback */ markAsReadV3(messageId: string, callback: msRest.ServiceCallback): void; /** * @param messageId Id of the email to be marked. * @param options The optional parameters * @param callback The callback */ markAsReadV3(messageId: string, options: Models.MailMarkAsReadV3OptionalParams, callback: msRest.ServiceCallback): void; /** * This operation gets emails from a folder. * @summary Get emails (V2) * @param [options] The optional parameters * @deprecated This operation is deprecated. Please do not use it any longer. * @returns Promise */ getEmailsV2(options?: Models.MailGetEmailsV2OptionalParams): Promise; /** * @param callback The callback * @deprecated This operation is deprecated. Please do not use it any longer. */ getEmailsV2(callback: msRest.ServiceCallback): void; /** * @param options The optional parameters * @param callback The callback * @deprecated This operation is deprecated. Please do not use it any longer. */ getEmailsV2(options: Models.MailGetEmailsV2OptionalParams, callback: msRest.ServiceCallback): void; /** * This operation sends an email message. * @summary Send an email (V2) * @param emailMessage Email. * @param [options] The optional parameters * @returns Promise */ sendEmailV2(emailMessage: Models.ClientSendHtmlMessage, options?: msRest.RequestOptionsBase): Promise; /** * @param emailMessage Email. * @param callback The callback */ sendEmailV2(emailMessage: Models.ClientSendHtmlMessage, callback: msRest.ServiceCallback): void; /** * @param emailMessage Email. * @param options The optional parameters * @param callback The callback */ sendEmailV2(emailMessage: Models.ClientSendHtmlMessage, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; /** * This operation moves an email to the specified folder. * @summary Move email (V2) * @param messageId Id of the email to be moved. * @param folderPath Mail folder to move the email to. * @param [options] The optional parameters * @returns Promise */ moveV2(messageId: string, folderPath: string, options?: Models.MailMoveV2OptionalParams): Promise; /** * @param messageId Id of the email to be moved. * @param folderPath Mail folder to move the email to. * @param callback The callback */ moveV2(messageId: string, folderPath: string, callback: msRest.ServiceCallback): void; /** * @param messageId Id of the email to be moved. * @param folderPath Mail folder to move the email to. * @param options The optional parameters * @param callback The callback */ moveV2(messageId: string, folderPath: string, options: Models.MailMoveV2OptionalParams, callback: msRest.ServiceCallback): void; /** * This operation replies to an email. * @summary Reply to email (V2) * @param messageId Id of the email to reply to. * @param replyParameters Details of the email reply. * @param [options] The optional parameters * @deprecated This operation is deprecated. Please do not use it any longer. * @returns Promise */ replyToV2(messageId: string, replyParameters: Models.ReplyMessage, options?: Models.MailReplyToV2OptionalParams): Promise; /** * @param messageId Id of the email to reply to. * @param replyParameters Details of the email reply. * @param callback The callback * @deprecated This operation is deprecated. Please do not use it any longer. */ replyToV2(messageId: string, replyParameters: Models.ReplyMessage, callback: msRest.ServiceCallback): void; /** * @param messageId Id of the email to reply to. * @param replyParameters Details of the email reply. * @param options The optional parameters * @param callback The callback * @deprecated This operation is deprecated. Please do not use it any longer. */ replyToV2(messageId: string, replyParameters: Models.ReplyMessage, options: Models.MailReplyToV2OptionalParams, callback: msRest.ServiceCallback): void; /** * This operation gets an email by id. * @summary Get email (V2) * @param messageId Id of the email. * @param [options] The optional parameters * @returns Promise */ getEmailV2(messageId: string, options?: Models.MailGetEmailV2OptionalParams): Promise; /** * @param messageId Id of the email. * @param callback The callback */ getEmailV2(messageId: string, callback: msRest.ServiceCallback): void; /** * @param messageId Id of the email. * @param options The optional parameters * @param callback The callback */ getEmailV2(messageId: string, options: Models.MailGetEmailV2OptionalParams, callback: msRest.ServiceCallback): void; /** * This operation gets emails from a folder via graph apis. Please note that filtering related to * these fields: To, Cc, To Or Cc, From, Importance, Fetch Only With Attachments, Subject Filter, * is performed using first 250 items in a given mail folder. To avoid that limitation you can use * 'Search Query' field. * @summary Get emails (V3) * @param [options] The optional parameters * @returns Promise */ getEmailsV3(options?: Models.MailGetEmailsV3OptionalParams): Promise; /** * @param callback The callback */ getEmailsV3(callback: msRest.ServiceCallback): void; /** * @param options The optional parameters * @param callback The callback */ getEmailsV3(options: Models.MailGetEmailsV3OptionalParams, callback: msRest.ServiceCallback): void; /** * This operation replies to an email. * @summary Reply to email (V3) * @param messageId Id of the email to reply to. * @param replyParameters Details of the email reply. * @param [options] The optional parameters * @returns Promise */ replyToV3(messageId: string, replyParameters: Models.ReplyHtmlMessage, options?: Models.MailReplyToV3OptionalParams): Promise; /** * @param messageId Id of the email to reply to. * @param replyParameters Details of the email reply. * @param callback The callback */ replyToV3(messageId: string, replyParameters: Models.ReplyHtmlMessage, callback: msRest.ServiceCallback): void; /** * @param messageId Id of the email to reply to. * @param replyParameters Details of the email reply. * @param options The optional parameters * @param callback The callback */ replyToV3(messageId: string, replyParameters: Models.ReplyHtmlMessage, options: Models.MailReplyToV3OptionalParams, callback: msRest.ServiceCallback): void; } //# sourceMappingURL=mail.d.ts.map