Package Exports
- @sheetbase/gmail-server
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (@sheetbase/gmail-server) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
Sheetbase Module: @sheetbase/gmail-server
Send email using Gmail in Sheetbase backend app.
Install
Using npm: npm install --save @sheetbase/gmail-server
import * as Gmail from "@sheetbase/gmail-server";As a library: 1cKQyLf_OZwivLAiNBw-naLV_uq-lmf8AcOEnE9t5E9IQhA1Fo8JTV_sm
Set the Indentifier to GmailModule and select the lastest version, view code.
declare const GmailModule: { Gmail: any };
const Gmail = GmailModule.Gmail;Scopes
`https://www.googleapis.com/auth/gmail.send
https://www.googleapis.com/auth/script.send_mail`
Usage
Docs homepage: https://sheetbase.github.io/gmail-server
API reference: https://sheetbase.github.io/gmail-server/api
Examples
import * as Gmail from "./public_api";
function load_() {
return Gmail.gmail();
}
export function example1(): void {
const Gmail = load_();
const quota = Gmail.quota();
Logger.log(quota);
}
export function example2(): void {
const Gmail = load_();
const email = Gmail.send({
recipient: "<email_address>",
subject: "Hello",
options: {
htmlBody: "<h1>Hello</h1><p>Gmail here!</p>"
}
});
Logger.log(email);
}License
@sheetbase/gmail-server is released under the MIT license.