thirdparty.proto 2.0 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283
  1. syntax = "proto3";
  2. // package声明符,用来防止不同的消息类型有命名冲突
  3. package v1;
  4. // 用于生成指定语言go的包名称
  5. option go_package = "dust-monitor/pb/v1";
  6. message WeatherConditionRequest{
  7. // 省市名(市为直辖市)
  8. string province = 1;
  9. // 地区
  10. string region = 2;
  11. }
  12. message WeatherConditionReply{
  13. string condition = 1;
  14. string condition_id = 2;
  15. string humidity = 3;
  16. string icon = 4;
  17. string pressure = 5;
  18. string real_feel = 6;
  19. string sun_rise = 7;
  20. string sun_set = 8;
  21. string temp = 9;
  22. string tips = 10;
  23. string updatetime = 11;
  24. string uvi = 12;
  25. string wind_dir = 13;
  26. string wind_level = 14;
  27. string wind_speed = 15;
  28. }
  29. message WeatherEnviromentRequest{
  30. // 省市名(市为直辖市)
  31. string province = 1;
  32. // 地区
  33. string region = 2;
  34. }
  35. message WeatherEnviromentReply{
  36. string city_name = 1;
  37. // 一氧化碳指数
  38. string co = 2;
  39. // 二氧化氮指数
  40. string no2= 3;
  41. // 臭氧指数
  42. string o3 = 4;
  43. // PM10指数
  44. string pm10 = 5;
  45. // PM2.5指数
  46. string pm25 = 6;
  47. // 全国排名
  48. string rank = 7;
  49. // 二氧化硫指数
  50. string so2 = 8;
  51. // 空气质量指数值
  52. string value = 9;
  53. }
  54. message WeatherForecast15Request{
  55. // 省市名(市为直辖市)
  56. string province = 1;
  57. // 地区
  58. string region = 2;
  59. }
  60. message WeatherForecast15{
  61. string condition_day = 1;
  62. string condition_id_day = 2;
  63. string condition_id_night = 3;
  64. string condition_night = 4;
  65. string moonphase = 5;
  66. string temp_day = 6;
  67. string temp_night = 7;
  68. string wind_dir_day = 8;
  69. string wind_dir_night = 9;
  70. string wind_level_day = 10;
  71. string wind_levelNight = 11;
  72. string wind_speed_day = 12;
  73. string wind_speed_night = 13;
  74. }
  75. message WeatherForecast15Reply{
  76. repeated WeatherForecast15 WeatherForecast15= 1;
  77. }