I have a web page that uses gmail API and javascript to deal with gmail messages. I am stuck at a point where I want to retrieve the messages after a particular timestamp.
This is part of my code that lists the mails
{
var request = gapi.client.gmail.users.messages.list({
'userId': 'me',
'maxResults': 10
});
I want to list the messages after the longdate 1531958459000
.
My attempt was as below
{
var request = gapi.client.gmail.users.messages.list({
'userId': 'me',
'after':'1531958459000',
'maxResults': 10
});
and it doesn't seem to work. Instead getting messages after that time, I am getting 10 messages at random, like the code without the after
part.
Any help?