Is there any API for searching user emails (synced with the device) from an app?
For example, searching all the emails from one particular contact which has the word "watermelon" in it.
There is no API for accessing user emails.
The answer by Nicolas R only deals with searching email addresses in contacts, not searching the actual emails.
Yes, there is one, provided by basic documentation: http://msdn.microsoft.com/en-us/library/windows/apps/hh286417.aspx
It's the SearchAsync method.
Sample:
SearchAsync("Chris#example.com", FilterKind.EmailAddress, "State String 4")
Other info and more detailed sample: http://msdn.microsoft.com/en-us/library/microsoft.phone.userdata.contacts.searchasync
But be careful with the results:
Email addresses are matched by exact and smart matching. The name
portion before the # symbol must match exactly
So if you intend to do a "like" search on the 1st part of the email, you will miss results
Related
I have a lot of google access tokens in my DB (more than 1k). These tokens belong to google-my-business owners that have been authenticated to my app via google and gave permissions to use their tokens. I want to get all google reviews from all these accounts and save them to my DB.
But when I get reviews, I get them with an automatically generated translation as a single string. And I want to split the original and translated and save it separately.
Reviews have this format.
(Translated by Google) Awesome!
(Original) Круто!
Usually, I would just split this string by "(Translated by Google)" substring. But this solution doesn't work, because the substring is actually different and depends on the user's account language settings. And if user set up his language to russian, this substring will look like "(Переведено Google)".
Is there any way to split the original comment from translated one, considering different language settings?
P.S. This question is not a duplicate because other ones don't have this language problem.
I found a solution that I really don't like and it's an overkill, but that's the only thing that came to my mind.
First I get the user's language settings by calling this endpoint https://developers.google.com/my-business/reference/rest/v4/accounts.
Then I translate '(Translated by Google)' string via google translate API to this language and then I split the review comment by this string. It works, but if you suggest something better, it would be awesome.
I am writing a tool in Google Sheets to analyze my work calendar and I just noticed that if I invite a "Group" (of 23 people) it only shows up as a single guest in the calendar data. Is there a way to get access to the e-mails of the people in the group?
From my research I know there is a Groups service but I'm not sure how to even recognize that it's a group. It looks like a normal e-mail address in the calendar: "management_team#gmail.com". (I could search for that specific group name, but I'm looking for a universal solution, so I can share this tool with others.)
Any suggestions will be appreciated. Thank you.
To verify either an email is a group and to retrieve its members you need to use the Admin SDK method Groups:get
But in order to use the Admin SDK you need to be a domain admin.
Each person who uses my tool will need their own copy and they will have to enter their calendar e-mail address. (The first time they run the tool there's a rather scary permissions message, but I will only be sharing this with some office mates so that should be okay.)
When my program runs I'll use this command:
var groups = GroupsApp.getGroups();
... to get a list of all the groups to which that person belongs. (I'll also have arrays for the members of each group.) Then I'll just compare the group names against the meeting guest names. If there's a match I can pretty easily retrieve the whole list.
I would like to automatically respond to an e-mail with some information. The idea is to provide a self-service way for students to get grades and passwords. I see sample scripts that work on e-mails, but I need to:
look for a keyword in the subject to understand what type of information to provide (i.e., grade, password, etc.)
look at the e-mail of the inbound e-mail to identify the student (optionally locate a password)
look up the information (possibly in a spreadsheet)
create an e-mail and send it to the student
I am more familiar with using scripts with e-mail and spreadsheets, but I would prefer to create this on a Google Sites page or embed it in a wiki.
Thanks in advance for the help,
JDF
I am not sure how much detail you were looking for, or if you where looking for example code, but here are some high level things to think about.
First, if you are going to embed the code into a webpage that you want be able to access all your other Google things easaly. eg if i stored all the student names passwords and student numbers in an spreadsheet or database you have to set up permission to do so. Your website does not count as you "persay" because if you had it shared out then someone could potentally steal all your google stuff.
Take a good look through the Google appi google apps script. You can search your email by thread (subeject) and then go through the emails like that. I think all the function that you want are there.
I send 3 different links to people on a daily basis. I know the name of the person I am sending the link to. How do I attach that persons information to the link to know they clicked on the link?
I sent close to 50 emails to different people. I just want to be notified that someone I sent the link to click on it.
You need to use a database for this. The link could contain a random hash that can be looked up in the "emails" table. This table could keep records for timestamps, specifically when the emial was sent out, and when the user clicked the link.
#QUESTION:
Most hosting providers give you the option to hook up a database. If you have trouble finding this, use google or their support. As far as how to "use" a database, you will need to learn this in you own time. But like anything else the basics are widely available through google, which in your case, is all you need to finish your project.
You can add an encrypted or obfuscated field to your URLs identifying the email address.
Common methods:
base64 encoded email address XOR-ed with known key
md5 hash of email address truncated to first N characters
And so on.
The first method allows you to reverse the process (i.e. getting back the email address from the visit log), the second is one-way only.
For example, using the second method with email dude#gmail.com (truncated to 12 characters):
http://domain.com/click.php?v=ec3ab9422d7a
Or, as already said, you can simply use a database and store a key-value pair (email, hash) with, for each email, a random string generated on-the-fly by your massmailer.
This question is more theoretical.
Is it save to be passing email address in query string like:
www.something.com/?email=person#domain.com
I am using this in one project, but i would like to know what are the downsides. Cause some big services are avoiding this, for example Gravatar wants you to convert email address into MD5 hash and then pass it in query.
Thanks for explanation
The main one is privacy.
Take Gravatar for instance. The traditional usecase is rendering an avatar for each comment. If you were to put the real email address in the query string, then you would be publishing the email addresses of everyone who commented (perfect for harvesting by spam bots or for harassing people who make comments that you disagree with).