Showing posts with label gmail. Show all posts
Showing posts with label gmail. Show all posts
Tuesday, March 10, 2015
Bringing more context to Gmail contextual gadgets
As part of the launch of Gmail contextual gadgets, Google released a set of predefined extractors that developers could use. These extractors allow developers to match content within a single part of an email message, such as the subject, and use that content to display relevant information to the current user.
Many Gmail contextual gadget developers have expressed a desire to match on more complex patterns than is possible with the predefined extractors. Today, with the launch of the Google Apps extensions console, these complex patterns, known as custom extractors, are now available to drive contextual gadgets.
Custom extractors allow developers to trigger their gadget when a series of conditions are met. For example, a developer could write an extractor that triggered a gadget only when “Hello world” appeared in the subject and “john@example.com” was the sender of the email. This allows developers to more finely tune their gadgets, and provide even more relevant contextual information.
If you’re interested in writing a custom extractor you can get started by reading our documentation. If you have questions, please post them in the forum.
Read more »
Many Gmail contextual gadget developers have expressed a desire to match on more complex patterns than is possible with the predefined extractors. Today, with the launch of the Google Apps extensions console, these complex patterns, known as custom extractors, are now available to drive contextual gadgets.
Custom extractors allow developers to trigger their gadget when a series of conditions are met. For example, a developer could write an extractor that triggered a gadget only when “Hello world” appeared in the subject and “john@example.com” was the sender of the email. This allows developers to more finely tune their gadgets, and provide even more relevant contextual information.
If you’re interested in writing a custom extractor you can get started by reading our documentation. If you have questions, please post them in the forum.
Dan Holevoet, Google Developer Team
Want to weigh in on this topic? Discuss on Buzz
Monday, March 9, 2015
Gmail and Document Services now available in Apps Script
If you’ve used Google Apps Script before, you’ll know that we have deep integration with many Google Apps & APIs. You can access your Calendar and Contacts, create Google Sites, send email, and lots more. But two integrations were noticeably missing: the Google Docs word processor, and Gmail. A few weeks ago, at Google IO, we announced new Apps Script APIs for these two great products.
The new
To make sure your Gmail account remains private and secure, we are extra cautious about any script that uses
The new
Once you have a document, you can access all of its individual elements. You can do search and replace (great for mail merge!), change styles or text, add or remove tables and lists, and much more. And when you are done, you can call
Read more »
GmailApp - read, label and send emails
The new GmailApp should be instantly familiar if you’re used to using Gmail. You have access to labels, threads, and messages, and you can do all the things you expect: change labels, add and remove stars, mark things as important or trash or spam. You can also use the GmailApp.search() method to do any search you can do in Gmail itself. This is the first full fidelity API to Gmail, and we’re excited to see what you all will do with it.To make sure your Gmail account remains private and secure, we are extra cautious about any script that uses
GmailApp. Any time you change the code for a script that accesses Gmail, we will require you to reauthorize the script to run. Keep that in mind when editing a script that runs on a trigger - if you don’t reauthorize it, it will fail the next time the trigger tries to run it.DocumentApp - create and edit Docs
The new DocumentApp lets you create new documents or open existing ones by id. The id of a document is always in the URL you see when visiting it, and document ids are consistent between DocumentApp and the existing DocsList service, so you can use DocsList.find() to search for a document, and then get its id from File.getId(). Once you have a document, you can access all of its individual elements. You can do search and replace (great for mail merge!), change styles or text, add or remove tables and lists, and much more. And when you are done, you can call
Document.saveAndClose(), which makes sure all of your changes to the document get saved. If you don’t call it, we’ll do it for you at the end of the script, but it can be useful to call it yourself if you’d like to do something with the document after making your edits.GmailApp and DocumentApp are available to all Apps Script users right now. Now the only question is, what are you going to build with them?Posted by Corey Goldfeder, Google Apps Script Team
Want to weigh in on this topic? Discuss on Buzz
Subscribe to:
Posts (Atom)