All v2 Ids including applications, accounts, messages, events, and contacts are lowercase alphanumeric strings between 23 and 25 characters in length.
For v3, there are major differences:
Grants & Applications are UUIDs
Objects use their email provider's Id value. This can vary wildly. It can range from a lower case alphanumeric string for Gmail of about 20 characters or less to a massive string of characters and symbols for Microsoft approaching 100 characters.
IMAP objects have their Id as a hash of the message-id header and folder.
How do you programmatically determine the difference?
You can use RegEx to identify v2 Ids. Use this RegEx:
^[a-z0-9]{23,25}$
Because of their variety, you can't use RegEx to identify v3 Ids.
Comments
0 comments
Please sign in to leave a comment.