ArtStyle ArtStyle - 7 months ago 21
Objective-C Question

How to get a number of unread messages in gmail objective c

This sample allow me to fetch some labels from Gmail interface. The question is: Is it possible to fetch number of user's unread messages in Gmail using same tools like in the sample?


I'm not very good at objective-c, but you can get every message with the UNREAD-label and check the unread count:




 "id": "UNREAD",
 "name": "UNREAD",
 "type": "system",
 "messagesTotal": 354,
 "messagesUnread": 354,
 "threadsTotal": 320,
 "threadsUnread": 320

As you can see, messagesUnread tells me I have 354 unread messages.