ticket.proto 1.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758
  1. syntax = "proto3";
  2. package ticket;
  3. // golang
  4. option go_package = "./ticket";
  5. // java
  6. option java_package = "com.gshopper.crm.ticket";
  7. option java_outer_classname = "proto";
  8. enum MessageProvider {
  9. UnknownMessageProvider = 0;
  10. EmailMessageProvider = 1;
  11. ChatMessageProvider = 2;
  12. GptMessageProvider = 3;
  13. ApiMessageProvider = 4;
  14. FunctionProvider = 5;
  15. }
  16. message Message {
  17. message Header {
  18. string key = 1;
  19. string value = 2;
  20. }
  21. message Attachment {
  22. message Upload {
  23. string bucket = 1;
  24. string key = 2;
  25. string etag = 3;
  26. int64 size = 4;
  27. int64 last_modified = 5;
  28. string location = 6;
  29. string version = 7;
  30. }
  31. string id = 1;
  32. string filename = 2;
  33. string content_type = 3;
  34. string content_encoding = 4;
  35. Upload upload = 5;
  36. }
  37. string ticket_id = 1 [json_name = "ticket_id"];
  38. MessageProvider provider = 2 [json_name = "provider"];
  39. string body = 3 [json_name = "body"];
  40. int64 date = 4 [json_name = "date"];
  41. string raw = 5 [json_name = "raw"];
  42. string id = 6 [json_name = "id"];
  43. bytes flags = 7 [json_name = "flags"];
  44. repeated Header headers = 10 [json_name = "headers"];
  45. repeated Attachment attachments = 11 [json_name = "attachments"];
  46. }
  47. message Ticket {
  48. string id = 1 [json_name= "id"];
  49. repeated Message thread = 10 [json_name = "thread"];
  50. }