1
0
Fork 0

👽 Updatedd code to v4.9

This commit is contained in:
Maxim Lebedev 2020-06-05 16:10:51 +05:00
parent de43f2736b
commit 30ab992414
No known key found for this signature in database
GPG Key ID: F8978F46FF0FFA4F
3 changed files with 17 additions and 1 deletions

View File

@ -3,7 +3,7 @@ package telegram
import "github.com/Masterminds/semver"
// Version represents current version of Telegram API supported by this package
var Version = semver.MustParse("4.8.0") //nolint: gochecknoglobals
var Version = semver.MustParse("4.9.0") //nolint: gochecknoglobals
// Action represents available and supported status actions of bot
const (
@ -146,7 +146,9 @@ const (
// Mime represents available and supported MIME types of data
const (
MimeGIF string = "image/gif"
MimeHTML string = "text/html"
MimeJPEG string = "image/jpeg"
MimeMP4 string = "video/mp4"
MimePDF string = "application/pdf"
MimeZIP string = "application/zip"

View File

@ -113,6 +113,10 @@ type (
// URL of the static thumbnail for the result (jpeg or gif)
ThumbURL string `json:"thumb_url"`
// MIME type of the thumbnail, must be one of “image/jpeg”, “image/gif”, or “video/mp4”. Defaults to
// “image/jpeg”
ThumbMimeType string `json:"thumb_mime_type,omitempty"`
// Title for the result
Title string `json:"title,omitempty"`
@ -152,6 +156,10 @@ type (
// URL of the static thumbnail (jpeg or gif) for the result
ThumbURL string `json:"thumb_url"`
// MIME type of the thumbnail, must be one of “image/jpeg”, “image/gif”, or “video/mp4”. Defaults to
// “image/jpeg”
ThumbMimeType string `json:"thumb_mime_type,omitempty"`
// Title for the result
Title string `json:"title,omitempty"`
@ -167,6 +175,9 @@ type (
// Video duration
Mpeg4Duration int `json:"mpeg4_duration,omitempty"`
// Mode for parsing entities in the caption. See formatting options for more details.
ParseMode string `json:"parse_mode,omitempty"`
// Inline keyboard attached to the message
ReplyMarkup *InlineKeyboardMarkup `json:"reply_markup,omitempty"`

View File

@ -131,6 +131,9 @@ type (
// For replies, the original message. Note that the Message object in this field will not contain further reply_to_message fields even if it itself is a reply.
ReplyToMessage *Message `json:"reply_to_message,omitempty"`
// Bot through which the message was sent
ViaBot *User `json:"via_bot,omitempty"`
// Date the message was last edited in Unix time
EditDate int64 `json:"edit_date,omitempty"`