我正在开发一个项目,我需要在imap服务器的收件箱中阅读邮件,处理它,然后从收件箱中删除电子邮件.
curl --url "imaps://imap.gmail.com:993/inBox;UID=1" --user "user:password"
这对于获取电子邮件非常合适,我成功处理它没有问题所以现在当我尝试删除它时我使用以下内容:
curl --url "imaps://imap.gmail.com:993/inBox;UID=1" --user "user:password" -X 'UID STORE 1 +Flags \Deleted'
但我得到以下回应:
curl: (21) Quote command returned error curl: (6) Could not resolve host: STORE curl: (6) Could not resolve host: 1 curl: (6) Could not resolve host: +Flags curl: (6) Could not resolve host: \Deleted'