MDL-46187 allow generation of calendar export tokens with username.
Includes codereview changes and inclusion of auth on the token.