forked from DefinitelyTyped/DefinitelyTyped
-
Notifications
You must be signed in to change notification settings - Fork 0
/
google-apps-script.mail.d.ts
31 lines (27 loc) · 1.16 KB
/
google-apps-script.mail.d.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
// Type definitions for Google Apps Script 2015-11-12
// Project: https://developers.google.com/apps-script/
// Definitions by: motemen <https://github.com/motemen/>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
/// <reference path="google-apps-script.types.d.ts" />
declare namespace GoogleAppsScript {
export module Mail {
/**
* Sends email.
*
* This service allows users to send emails with complete control over the
* content of the email. Unlike GmailApp, MailApp's sole purpose is sending email. MailApp cannot
* access a user's Gmail inbox.
*
* Changes to scripts written using GmailApp are more likely to trigger a re-authorization
* request from a user than MailApp scripts.
*/
export interface MailApp {
getRemainingDailyQuota(): Integer;
sendEmail(message: Object): void;
sendEmail(recipient: string, subject: string, body: string): void;
sendEmail(recipient: string, subject: string, body: string, options: Object): void;
sendEmail(to: string, replyTo: string, subject: string, body: string): void;
}
}
}
declare var MailApp: GoogleAppsScript.Mail.MailApp;