@@ -128,6 +128,27 @@ message gateway_info_v3 {
128128 uint64 num_location_asserts = 6 ;
129129}
130130
131+ message gateway_info_v4 {
132+ // The public key binary address and on-chain identity of the gateway
133+ bytes address = 1 ;
134+ // The gateway metadata
135+ gateway_metadata_v3 metadata = 2 ;
136+ // The asserted device type of the gateway
137+ device_type_v2 device_type = 3 ;
138+ // The Unix epoch timestamp (in seconds) when the gateway was first added to
139+ // the database
140+ uint64 created_at = 4 ;
141+ // The Unix epoch timestamp (in seconds) when the gateway parameters were last
142+ // updated. NOTE: This field is also updated when the location or owner changes.
143+ uint64 updated_at = 5 ;
144+ // Count of hotspot location changes
145+ uint64 num_location_asserts = 6 ;
146+ // The gateway's owner
147+ string owner = 7 ;
148+ // The last time the owner was changed (in seconds)
149+ uint64 owner_changed_at = 8 ;
150+ }
151+
131152message gateway_info_req_v1 {
132153 // The public key address of the gateway to look up
133154 bytes address = 1 ;
@@ -208,6 +229,32 @@ message gateway_info_stream_req_v3 {
208229 uint64 min_location_changed_at = 6 ;
209230}
210231
232+ message gateway_info_stream_req_v4 {
233+ // max number of gateway info records in each message of the response stream
234+ uint32 batch_size = 1 ;
235+ // pubkey binary of the signing keypair
236+ bytes signer = 2 ;
237+ bytes signature = 3 ;
238+ // Device types that will be returned in the response
239+ // Use empty array if you don't want to apply this filter
240+ repeated device_type_v2 device_types = 4 ;
241+ // The Unix epoch timestamp (in seconds).
242+ // Filters the response based on the last time gateway parameter(s) was
243+ // updated (Includes location and owner changing).
244+ // Use 0 if you don't want to apply this filter
245+ // NOTE: It is recommended to use the highest `updated_at` field from
246+ // returned radios in the next subsequent requests.
247+ uint64 min_updated_at = 5 ;
248+ // The Unix epoch timestamp (in seconds).
249+ // Filters the response based on the last time gateway changed its location.
250+ // Use 0 if you don't want to apply this filter
251+ uint64 min_location_changed_at = 6 ;
252+ // The Unix epoch timestamp (in seconds).
253+ // Filters the response based on the last time gateway's owner was changed
254+ // Use 0 to fetch all gateways.
255+ uint64 min_owner_changed_at = 7 ;
256+ }
257+
211258message gateway_info_stream_req_v2 {
212259 // max number of gateway info records in each message of the response stream
213260 uint32 batch_size = 1 ;
@@ -255,6 +302,16 @@ message gateway_info_stream_res_v3 {
255302 bytes signature = 4 ;
256303}
257304
305+ message gateway_info_stream_res_v4 {
306+ // a list of gateway info numbering up to the request batch size
307+ repeated gateway_info_v4 gateways = 1 ;
308+ // unix epoch timestamp in seconds
309+ uint64 timestamp = 2 ;
310+ // pubkey binary of the signing keypair
311+ bytes signer = 3 ;
312+ bytes signature = 4 ;
313+ }
314+
258315message entity_verify_req_v1 {
259316 // binary identifier of the entity
260317 bytes entity_id = 1 ;
@@ -475,6 +532,11 @@ service gateway {
475532 // Get a stream of gateway info (V3)
476533 rpc info_stream_v3 (gateway_info_stream_req_v3 )
477534 returns (stream gateway_info_stream_res_v3 );
535+
536+ // V4
537+ // Get a stream of gateway info (V4)
538+ rpc info_stream_v4 (gateway_info_stream_req_v4 )
539+ returns (stream gateway_info_stream_res_v4 );
478540}
479541
480542service entity {
0 commit comments