title: Google Apps Script Gmail Star Search Result
body: <p>I have the beginning of a script (below) to search and star a specific message, but the problem is the GmailApp.search() method returns a string which GmailApp.starMessage() cannot process (error is "Cannot convert Array to GmailMessage").  How can I convert the search from a string or correlate it somehow to a usable object?</p>
  
  <pre><code>function starEmail() {
    var email = GmailApp.search('from:address@email.com is:unread')
    GmailApp.starMessage(email);
  }
  </code></pre>