title: Getting messages/mails sorted by date and time in Gmail API
body: <p>I am working on a web app where I need to check "latest mail"  that I have received from a particular sender in my gmail account on an hourly basis.</p>
  
  <p>To achieve this, I used the Gmail API for PHP and was able to retrieve mails from a particular sender but I need to sort this mails/messages w.r.t date and time so that I can get the last email from a particular sender.</p>
  
  <p>I checked <a href="https://support.google.com/mail/answer/7190?hl=en">Advanced Search options of Gmail API </a>
  which provides to sort with respect to date , however it doesn't provide any method to handle it with respect to time.</p>
  
  <p>Is there any way to get the time and date and sort it? or any other approach that can help me get the "latest" mail from a particular sender?</p>
  
  <p>Please help me out. Thanks in Advance.</p>