Per this SO thread I should be able to go directly to a Gmail draft message, created using the Gmail REST API, using a hyperlink formatted like:
https://mail.google.com/mail/#drafts?compose={ThreadId}
However, it's not working. The thread ID I get as a response to my Gmail API call does not open the draft message created. What's really strange is when I open the draft from Gmail (that I created using the API) the thread ID DOES match for a split second in the URL then changes.
How does one open directly to a draft message utilizing the message.threadId? I'd like it to be a pop out message as well and should be possible per this thread but getting the draft to show at all is my first priority.
答案 0 :(得分:2)
草稿的线程ID /消息ID不稳定。也就是说,每次编辑/保存草稿时它们都会更改。唯一稳定的是草案ID,但是,这在gmail ui中不可用。
答案 1 :(得分:2)
Users.drafts.create API call会返回包含草稿ID的User.drafts resource。草稿ID与消息或线程ID不同,但您可以调用Users.drafts.get或Users.drafts.list,这两者都可以让草稿ID与线程ID和消息ID相关联。