CredentialsResponse.cs 765 B

12345678910111213141516171819202122232425262728293031323334
  1. using System.Reflection;
  2. using Unity.Plastic.Newtonsoft.Json;
  3. using PlasticGui.WebApi.Responses;
  4. namespace Unity.PlasticSCM.Editor.WebApi
  5. {
  6. [ObfuscationAttribute(Exclude = true)]
  7. public class CredentialsResponse
  8. {
  9. [JsonProperty("error")]
  10. public ErrorResponse.ErrorFields Error { get; set; }
  11. public enum TokenType : int
  12. {
  13. Password = 0,
  14. Bearer = 1,
  15. }
  16. [JsonIgnore]
  17. public TokenType Type
  18. {
  19. get { return (TokenType)TokenTypeValue; }
  20. }
  21. [JsonProperty("email")]
  22. public string Email;
  23. [JsonProperty("token")]
  24. public string Token;
  25. [JsonProperty("tokenTypeValue")]
  26. public int TokenTypeValue;
  27. }
  28. }