1
0
mirror of https://github.com/InsanusMokrassar/TelegramBotAPI.git synced 2024-12-23 00:57:13 +00:00

InlineKeyboardMarkup using field as serial name for keyboard

This commit is contained in:
InsanusMokrassar 2019-04-20 13:14:49 +08:00
parent b002f61b71
commit bed60720d3
2 changed files with 3 additions and 1 deletions

View File

@ -64,6 +64,7 @@ const val inlineMessageIdField = "inline_message_id"
const val callbackDataField = "callback_data"
const val callbackQueryIdField = "callback_query_id"
const val inlineQueryIdField = "inline_query_id"
const val inlineKeyboardField = "inline_keyboard"
const val showAlertField = "show_alert"
const val cachedTimeField = "cached_time"
const val foursquareIdField = "foursquare_id"

View File

@ -1,11 +1,12 @@
package com.github.insanusmokrassar.TelegramBotAPI.types.buttons
import com.github.insanusmokrassar.TelegramBotAPI.types.buttons.InlineKeyboardButtons.InlineKeyboardButton
import com.github.insanusmokrassar.TelegramBotAPI.types.inlineKeyboardField
import kotlinx.serialization.*
import kotlinx.serialization.internal.ArrayListSerializer
@Serializable
data class InlineKeyboardMarkup(
@SerialName("inline_keyboard")
@SerialName(inlineKeyboardField)
val keyboard: Matrix<InlineKeyboardButton>
) : KeyboardMarkup