MBOX-Line: From tss at iki.fi  Thu Feb 17 10:05:34 2011
To: imap-protocol@u.washington.edu
From: Timo Sirainen <tss@iki.fi>
Date: Fri Jun  8 12:34:45 2018
Subject: [Imap-protocol] detecting new messages
In-Reply-To: <2CA53ECF4094AB4D8BDC7C60A75B1C02110BEAFC52@hawaii.shoretel.com>
References: <2CA53ECF4094AB4D8BDC7C60A75B1C02110BEAFC52@hawaii.shoretel.com>
Message-ID: <5398C04A-99D8-47E5-ABB8-AE10B168F3C4@iki.fi>

On 17.2.2011, at 19.55, Darren Croke wrote:

> Section 2.3.1.1 states: Note: The next unique identifier value is intended to provide a means for a client to determine whether any messages have been delivered to the mailbox since the previous time it checked this value.
>  
> Section 6.3.10 states: The STATUS command MUST NOT be used as a "check for new messages in the selected mailbox" operation (refer to sections 7, 7.3.1, and 7.3.2 for more information about the proper method for new message checking).
>  
> If both these statements are true, what is the recommended method to retrieve the next unique identifier value from a server?

Use STATUS for getting UIDNEXT for non-selected mailboxes. For selected mailbox, hopefully you don't care about knowing the UIDNEXT value. If you do, see this thread: http://mailman2.u.washington.edu/pipermail/imap-protocol/2011-January/001339.html


