gitea源码

123456789101112131415161718192021222324252627282930313233
  1. // Copyright 2015 The Gogs Authors. All rights reserved.
  2. // Copyright 2023 The Gitea Authors. All rights reserved.
  3. // SPDX-License-Identifier: MIT
  4. package structs
  5. // Email an email address belonging to a user
  6. type Email struct {
  7. // swagger:strfmt email
  8. // The email address
  9. Email string `json:"email"`
  10. // Whether the email address has been verified
  11. Verified bool `json:"verified"`
  12. // Whether this is the primary email address
  13. Primary bool `json:"primary"`
  14. // The unique identifier of the user who owns this email
  15. UserID int64 `json:"user_id"`
  16. // username of the user
  17. UserName string `json:"username"`
  18. }
  19. // CreateEmailOption options when creating email addresses
  20. type CreateEmailOption struct {
  21. // email addresses to add
  22. Emails []string `json:"emails"`
  23. }
  24. // DeleteEmailOption options when deleting email addresses
  25. type DeleteEmailOption struct {
  26. // email addresses to delete
  27. Emails []string `json:"emails"`
  28. }