gmail

Can I get a URL link to a Gmail draft using the Gmail API?

余生颓废 提交于 2019-12-05 05:33:37
The new Gmail API allows us to create and view drafts, but is there a way to get a URL link to view the draft? I can manually create the link using the draft's ThreadId with something like this: https://mail.google.com/mail/u/0/#drafts?compose= {ThreadId} But that is somewhat fragile if Google decides to change how those URLs are structured. I also don't know if the URL will be different for people in other countries. The 0 will also change depending on how many accounts you are logged into in the browser. Is there a better way to get this link than creating it manually like I am? Also, is

2-legged OAuth and the Gmail atom feed

此生再无相见时 提交于 2019-12-05 05:29:17
问题 We're trying to get 2-legged OAuth to work with the Gmail atom feed. We're using the Java library contributed by John Kristian, Praveen Alavilli and Dirk Balfanz. [http://oauth.net/code/] instead of the GData library. We know we have the correct CONSUMER_KEY and CONSUMER_SECRET, etc. becuase it works with the Contacts feed (http://www.google.com/m8/feeds/contacts/default/full) and have no problems. However with Gmail atom feed it always returns: HTTP/1.1 401 Unauthorized Any ideas? Should we

creating folders in IMAP does not work

痞子三分冷 提交于 2019-12-05 05:12:22
I am trying hard to create a folder in IMAP (I am using gmail) Here is what i have attempted so far: public boolean createFolder(String folderName) throws MessagingException { store = session.getStore("imap"); System.out.println("connecting store.."); store.connect("imap.gmail.com", 993, "something@gmail.com", "password"); System.out.println("connected !"); //using store.getDefaultFolder(); shows error : "folder cannot contain messages" Folder defaultFolder = store.getFolder("Inbox"); return createFolder(defaultFolder, folderName); } private boolean createFolder(Folder parent, String

(Gmail) Sending emails from spreadsheet. How to add signature with image?

蓝咒 提交于 2019-12-05 05:08:50
问题 Due to the large amount of emails i'm sending with GMAIL i decided to automatize this process using a script and following this tutorial.Tutorial: Sending emails from a Spreadsheet The "Message" is being generated by another function i created, called prepareEmails . The problems are the following: 1) How can i tell prepareEmails to add my personal signature? I can't simply copy its text into that function, because my signature contains an image (for which i have the URL), and i want that

How to fetch Gmail contacts? [closed]

爱⌒轻易说出口 提交于 2019-12-05 05:05:11
I have a scenario in my current application where I want to fetch the Gmail id's of my users. Could anyone tell me the way with piece of code in C#? Note: I am developing a web-base application in asp.net with C#. Sam Saffron Use the google contacts api there are C# sample there. You can use the Google Accounts API . You can find an example here. Take a look at the open source .Net library gmailapi .The GmailAgent has a GetContacts method for retrieving all the contacts. 来源: https://stackoverflow.com/questions/999766/how-to-fetch-gmail-contacts

TLS issue when sending to gmail through JavaMail

不羁的心 提交于 2019-12-05 04:07:55
Turns out that JavaMail is a bit more frustrating than I thought it would be. I've looked at several examples online on how to send a simple SMTP email through Gmail's servers (but not through SSL). After trying several different examples of code, I keep concluding to the same example exception when I call transport.connect() . I keep getting this stack trace: Exception in thread "main" com.sun.mail.smtp.SMTPSendFailedException: 530 5.7.0 Must issue a STARTTLS command first. l10sm302158wfk.21 at com.sun.mail.smtp.SMTPTransport.issueSendCommand(SMTPTransport.java:2057) at com.sun.mail.smtp

How do sites support http (non-SSLed) sessions securely?

ε祈祈猫儿з 提交于 2019-12-05 03:57:19
问题 I note that some sites (such as gmail) allow the user to authenticate over https and then switch to http with non-secure cookies for the main use of the site. How is it possible to have http access to a session but this still be secure? Or is it not secure and hence this is why gmail gives the option to have the entire session secured using https? Please give an example of how this works and avoids session hijacking attacks, whilst still allowing access to authenticated content over http. I

Access Gmail attachment from a chrome extension?

血红的双手。 提交于 2019-12-05 03:46:12
问题 Hi I am trying to write a chrome extension which needs to read in an email attachment (plain txt). I feel this should be possible as gmail gives you a download link, however it is not a direct link does this make it impossible? I have the following code to read a remote file which works just not for gmail: <script> var txtFile = new XMLHttpRequest(); txtFile.open("GET", "http://remote.com/remote_file", true); txtFile.onreadystatechange = function() { if (txtFile.readyState === 4) { // Makes

How do I access my existing cookies using Chrome?

耗尽温柔 提交于 2019-12-05 03:06:27
问题 I have cookies with Gmail login info, so that chrome automatically opens my Gmail. I tried the following code, but it didn't work: System.setProperty("webdriver.chrome.driver","chromedriver\\chromedriver.exe"); DesiredCapabilities capabilities = DesiredCapabilities.chrome(); capabilities.setCapability("chrome.switches", Arrays.asList("C:\\Users\\Owner\\AppData\\Local\\Google\\Chrome\\User Data\\Default")); //I also tried using: capabilities.setCapability("chrome.switches", Arrays.asList("-

Why does SMTP via gmail work locally but not on my production server?

青春壹個敷衍的年華 提交于 2019-12-05 02:49:18
问题 I'm running a nodejs server hosted on AWS (Ireland) and using emailjs to send emails. The email account I'm using is a gmail account and I can send emails from my local machine without any issues, but the emails fail to send from the production server. Outbound firewall is set to allow all traffic on all ports. The error message I get is "authorization.failed". 回答1: Gmail blocks IP addresses from AWS by default. After logging into gmail locally, visit the following URL. https://accounts