all repos — telegram-bot-api @ 289f7ef6adf7ca7c44c5486cf497ef30dbdb9a60

Golang bindings for the Telegram Bot API

Add more omitempty, as null values create errors.
Syfaro syfaro@foxpaw.in
Wed, 13 Apr 2016 15:45:51 -0500
commit

289f7ef6adf7ca7c44c5486cf497ef30dbdb9a60

parent

5b58a2a70185f0706b09ccdd7af5c02f1a94b5ba

1 files changed, 12 insertions(+), 12 deletions(-)

jump to
M types.gotypes.go

@@ -344,10 +344,10 @@ }

// InlineQueryResultArticle is an inline query response article. type InlineQueryResultArticle struct { - Type string `json:"type"` // required - ID string `json:"id"` // required - Title string `json:"title"` // required - InputMessageContent interface{} `json:"input_message_content"` // required + Type string `json:"type"` // required + ID string `json:"id"` // required + Title string `json:"title"` // required + InputMessageContent interface{} `json:"input_message_content,omitempty"` // required ReplyMarkup *InlineKeyboardMarkup `json:"reply_markup,omitempty"` URL string `json:"url"` HideURL bool `json:"hide_url"`

@@ -370,7 +370,7 @@ Title string `json:"title"`

Description string `json:"description"` Caption string `json:"caption"` ReplyMarkup *InlineKeyboardMarkup `json:"reply_markup,omitempty"` - InputMessageContent interface{} `json:"input_message_content"` + InputMessageContent interface{} `json:"input_message_content,omitempty"` } // InlineQueryResultGIF is an inline query response GIF.

@@ -384,7 +384,7 @@ ThumbURL string `json:"thumb_url"`

Title string `json:"title"` Caption string `json:"caption"` ReplyMarkup *InlineKeyboardMarkup `json:"reply_markup,omitempty"` - InputMessageContent interface{} `json:"input_message_content"` + InputMessageContent interface{} `json:"input_message_content,omitempty"` } // InlineQueryResultMPEG4GIF is an inline query response MPEG4 GIF.

@@ -398,7 +398,7 @@ ThumbURL string `json:"thumb_url"`

Title string `json:"title"` Caption string `json:"caption"` ReplyMarkup *InlineKeyboardMarkup `json:"reply_markup,omitempty"` - InputMessageContent interface{} `json:"input_message_content"` + InputMessageContent interface{} `json:"input_message_content,omitempty"` } // InlineQueryResultVideo is an inline query response video.

@@ -415,7 +415,7 @@ Height int `json:"video_height"`

Duration int `json:"video_duration"` Description string `json:"description"` ReplyMarkup *InlineKeyboardMarkup `json:"reply_markup,omitempty"` - InputMessageContent interface{} `json:"input_message_content"` + InputMessageContent interface{} `json:"input_message_content,omitempty"` } // InlineQueryResultAudio is an inline query response audio.

@@ -427,7 +427,7 @@ Title string `json:"title"` // required

Performer string `json:"performer"` Duration int `json:"audio_duration"` ReplyMarkup *InlineKeyboardMarkup `json:"reply_markup,omitempty"` - InputMessageContent interface{} `json:"input_message_content"` + InputMessageContent interface{} `json:"input_message_content,omitempty"` } // InlineQueryResultVoice is an inline query response voice.

@@ -438,7 +438,7 @@ URL string `json:"voice_url"` // required

Title string `json:"title"` // required Duration int `json:"voice_duration"` ReplyMarkup *InlineKeyboardMarkup `json:"reply_markup,omitempty"` - InputMessageContent interface{} `json:"input_message_content"` + InputMessageContent interface{} `json:"input_message_content,omitempty"` } // InlineQueryResultDocument is an inline query response document.

@@ -451,7 +451,7 @@ URL string `json:"document_url"` // required

MimeType string `json:"mime_type"` // required Description string `json:"description"` ReplyMarkup *InlineKeyboardMarkup `json:"reply_markup,omitempty"` - InputMessageContent interface{} `json:"input_message_content"` + InputMessageContent interface{} `json:"input_message_content,omitempty"` ThumbURL string `json:"thumb_url"` ThumbWidth int `json:"thumb_width"` ThumbHeight int `json:"thumb_height"`

@@ -465,7 +465,7 @@ Latitude float64 `json:"latitude"` // required

Longitude float64 `json:"longitude"` // required Title string `json:"title"` // required ReplyMarkup *InlineKeyboardMarkup `json:"reply_markup,omitempty"` - InputMessageContent interface{} `json:"input_message_content"` + InputMessageContent interface{} `json:"input_message_content,omitempty"` ThumbURL string `json:"thumb_url"` ThumbWidth int `json:"thumb_width"` ThumbHeight int `json:"thumb_height"`