def _GenerateUserPayload(users):
  """Generate the user payload data for all users.

  I could just pass through all the user's properties here, but that
  would expose the private key we have in the datastore along with
  various other user data, so I'm explicitly limiting what we show to
  an email and key for modifying values.

  Args:
    users: A list of users with associated properties from the datastore.

  Returns:
    user_token_payloads: A dictionary with user key id as key and email
        as a value.
  """
  user_token_payloads = {}
  for user in users:
    user_token_payloads[user.key.urlsafe()] = user.email

  return user_token_payloads