How to capture mail.app message url that will remain persistent when message is moved?
Short answer

message: URLs are persistent, but Mail needs to be restarted so that its message ID database gets updated and the URLs are properly resolved.

You will have to restart Mail before using BusyCal. Alternatively, you could restart Mail in your script.



Long answer

After some tests I noticed that:


message IDs don't change when a message is moved:

The message ID of this test mail located in the Inbox:



doesn't change after moving it to the _People mailbox:


message IDs work after Mail is restarted:

After moving the message, the URL message:%3CCA+pHXZSgP12HvSg2sQ9J3ochK2K8xOTk_wEoTf+6WmMcYGYxnw@mail.gmail.com%3E shows an empty message because Mail looks for the message in the Inbox (press Command and click the envelope icon on the window bar to show the path to the empty message):



After restarting Mail, the message is found successfully:




(Tested on OS X Mavericks 10.10.4.) 

To your questions: 

Is there a way to access messages through a URL even when they've moved? 

Yes, restart Mail so that it rebuilds its internal message ID database. You will be able to access any moved messages in their new mailboxes. 

I understand this is annoying but it seems to be the only workaround.

If not, how do I move a message and then get its message ID? 

That's not necessary as message IDs don't change.