I cannot find an appropriate guide for "How to use imaplib".
For example, when I want to move a message to the trash, I find the statement:
[Gmail]/Trash
Why not just "Trash"? What is the '[Gmail]' extension and how to use it?
Another example. For fetching information, I can do:
(BODY.PEEK[HEADER.FIELDS (SUBJECT)])
For getting the subject.
Or:
(RFC822)
For the whole message.
And another confusing thing is this 'labels' things. For example:
X-GM-MSGID
I don't understand what it stands for.
There are more labels etc. that I do not understand.
Can someone explain how to use the imaplib
library to me?