ronami_core/payloads/send_venue.rs
1//! Generated by `codegen_payloads`, do not edit by hand.
2
3use serde::Serialize;
4
5use crate::types::{
6 BusinessConnectionId, EffectId, Message, Recipient, ReplyMarkup, ReplyParameters,
7 SuggestedPostParameters, ThreadId, TopicId,
8};
9
10impl_payload! {
11 /// Use this method to send information about a venue. On success, the sent [`Message`] is returned.
12 ///
13 /// [`Message`]: crate::types::Message
14 #[derive(Debug, PartialEq, Clone, Serialize)]
15 pub SendVenue (SendVenueSetters) => Message {
16 required {
17 /// Unique identifier for the target chat or username of the target channel (in the format `@channelusername`)
18 pub chat_id: Recipient [into],
19 /// Latitude of new location
20 pub latitude: f64,
21 /// Longitude of new location
22 pub longitude: f64,
23 /// Name of the venue
24 pub title: String [into],
25 /// Address of the venue
26 pub address: String [into],
27 }
28 optional {
29 /// Unique identifier of the business connection on behalf of which the message will be sent
30 pub business_connection_id: BusinessConnectionId,
31 /// Unique identifier for the target message thread (topic) of the forum; for forum supergroups only
32 pub message_thread_id: ThreadId,
33 /// Identifier of the direct messages topic to which the message will be sent; required if the message is sent to a direct messages chat
34 pub direct_messages_topic_id: TopicId,
35 /// Foursquare identifier of the venue
36 pub foursquare_id: String [into],
37 /// Foursquare type of the venue, if known. (For example, “arts_entertainment/default”, “arts_entertainment/aquarium” or “food/icecream”.)
38 pub foursquare_type: String [into],
39 /// Google Places identifier of the venue
40 pub google_place_id: String [into],
41 /// Google Places type of the venue. (See [supported types].)
42 ///
43 /// [supported types]: https://developers.google.com/places/web-service/supported_types
44 pub google_place_type: String [into],
45 /// Sends the message [silently]. Users will receive a notification with no sound.
46 ///
47 /// [silently]: https://telegram.org/blog/channels-2-0#silent-messages
48 pub disable_notification: bool,
49 /// Protects the contents of sent messages from forwarding and saving
50 pub protect_content: bool,
51 /// 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
52 pub allow_paid_broadcast: bool,
53 /// Unique identifier of the message effect to be added to the message; for private chats only
54 pub message_effect_id: EffectId,
55 /// 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.
56 pub suggested_post_parameters: SuggestedPostParameters,
57 /// Description of the message to reply to
58 pub reply_parameters: ReplyParameters,
59 /// 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.
60 ///
61 /// [inline keyboard]: https://core.telegram.org/bots#inline-keyboards-and-on-the-fly-updating
62 /// [custom reply keyboard]: https://core.telegram.org/bots#keyboards
63 pub reply_markup: ReplyMarkup [into],
64 }
65 }
66}