-
Notifications
You must be signed in to change notification settings - Fork 0
/
weatherstackv1.proto
33 lines (26 loc) · 950 Bytes
/
weatherstackv1.proto
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
// https://cloud.google.com/apis/design
syntax = "proto3";
// versioned separately to the http / public-facing api
package weather.weatherstack.v1;
option go_package = "github.com/joeycumines/mx51-weather-api/weatherstack";
import "google/protobuf/timestamp.proto";
import "type/location/location.proto";
// Weatherstack models the actual https://api.weatherstack.com API, providing a caching layer, and abstracting
// concerns including auth.
//
// Only metric units are supported / used.
service Weatherstack {
rpc GetCurrentWeather (GetCurrentWeatherRequest) returns (CurrentWeather) {}
}
// https://weatherstack.com/documentation#current_weather
message CurrentWeather {
google.protobuf.Timestamp read_time = 1;
weather.type.Location location = 2;
double temperature = 3;
// Wind speed in km/hour.
double wind_speed = 4;
}
message GetCurrentWeatherRequest {
string query = 1;
google.protobuf.Timestamp min_read_time = 2;
}