Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
A query to get the first 20 Gmail emails ordered by email address in descending order
val emails = Contacts(context).data()
.query()
.emails()
.where(Fields.Email.Address endsWith "gmail.com")
.orderBy(Fields.Email.Address.desc(ignoreCase = true))
.offset(0)
.limit(20)
.find()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment