ronami_core/payloads/send_venue.rs
1//! Generated by `codegen_payloads`, do not edit by hand.
2
3use serde::Serialize;
4
5use crate::types::BusinessConnectionId;
6use crate::types::EffectId;
7use crate::types::EphemeralMessageParameters;
8use crate::types::Message;
9use crate::types::Recipient;
10use crate::types::ReplyMarkup;
11use crate::types::ReplyParameters;
12use crate::types::SuggestedPostParameters;
13use crate::types::ThreadId;
14use crate::types::TopicId;
15
16impl_payload! {
17 /// Use this method to send information about a venue. On success, the sent [`Message`] is returned.
18 ///
19 /// [`Message`]: crate::types::Message
20 #[derive(Debug, PartialEq, Clone, Serialize)]
21 pub SendVenue (SendVenueSetters) => Message {
22 required {
23 /// Unique identifier for the target chat or username of the target channel (in the format `@channelusername`)
24 pub chat_id: Recipient [into],
25 /// Latitude of new location
26 pub latitude: f64,
27 /// Longitude of new location
28 pub longitude: f64,
29 /// Name of the venue
30 pub title: String [into],
31 /// Address of the venue
32 pub address: String [into],
33 }
34 optional {
35 /// Unique identifier of the business connection on behalf of which the message will be sent
36 pub business_connection_id: BusinessConnectionId,
37 /// Unique identifier for the target message thread (topic) of the forum; for forum supergroups only
38 pub message_thread_id: ThreadId,
39 /// Identifier of the direct messages topic to which the message will be sent; required if the message is sent to a direct messages chat
40 pub direct_messages_topic_id: TopicId,
41 /// Foursquare identifier of the venue
42 pub foursquare_id: String [into],
43 /// Foursquare type of the venue, if known. (For example, “arts_entertainment/default”, “arts_entertainment/aquarium” or “food/icecream”.)
44 pub foursquare_type: String [into],
45 /// Google Places identifier of the venue
46 pub google_place_id: String [into],
47 /// Google Places type of the venue. (See [supported types].)
48 ///
49 /// [supported types]: https://developers.google.com/places/web-service/supported_types
50 pub google_place_type: String [into],
51 /// Sends the message [silently]. Users will receive a notification with no sound.
52 ///
53 /// [silently]: https://telegram.org/blog/channels-2-0#silent-messages
54 pub disable_notification: bool,
55 /// Protects the contents of sent messages from forwarding and saving
56 pub protect_content: bool,
57 /// Pass `true` to allow up to 1000 messages per second, ignoring broadcasting limits for a fee of 0.1 Telegram Stars per message. The relevant Stars will be withdrawn from the bot's balance
58 pub allow_paid_broadcast: bool,
59 /// Unique identifier of the message effect to be added to the message; for private chats only
60 pub message_effect_id: EffectId,
61 /// An object containing the parameters of the suggested post to send; for direct messages chats only. If the message is sent as a reply to another suggested post, then that suggested post is automatically declined.
62 pub suggested_post_parameters: SuggestedPostParameters,
63 /// A JSON-serialized object containing the parameters of the ephemeral message to send
64 pub ephemeral_message_parameters: EphemeralMessageParameters,
65 /// Description of the message to reply to
66 pub reply_parameters: ReplyParameters,
67 /// Additional interface options. A JSON-serialized object for an [inline keyboard], [custom reply keyboard], instructions to remove a reply keyboard or to force a reply from the user. Not supported for messages sent on behalf of a business account.
68 ///
69 /// [inline keyboard]: https://core.telegram.org/bots#inline-keyboards-and-on-the-fly-updating
70 /// [custom reply keyboard]: https://core.telegram.org/bots#keyboards
71 pub reply_markup: ReplyMarkup [into],
72 }
73 }
74}