tg_flows/types/location.rs
1use serde::{Deserialize, Serialize};
2
3/// This object represents a point on the map.
4#[derive(Copy, Clone, Debug, PartialEq, Serialize, Deserialize)]
5pub struct Location {
6 /// Longitude as defined by sender.
7 pub longitude: f64,
8
9 /// Latitude as defined by sender.
10 pub latitude: f64,
11
12 /// The radius of uncertainty for the location, measured in meters; 0-1500
13 pub horizontal_accuracy: Option<f64>,
14
15 /// Time relative to the message sending date, during which the location can
16 /// be updated, in seconds. For active live locations only.
17 pub live_period: Option<u32>,
18
19 /// The direction in which user is moving, in degrees; 1-360. For active
20 /// live locations only.
21 pub heading: Option<u16>,
22
23 /// Maximum distance for proximity alerts about approaching another chat
24 /// member, in meters. For sent live locations only.
25 pub proximity_alert_radius: Option<u32>,
26}