GramIO API Reference / @gramio/keyboards/dist / InputMessageContent
Class: InputMessageContent
Defined in: keyboards/index.d.ts:671
This object represents the content of a message to be sent as a result of an inline query.
Example
bot.api.answerInlineQuery({
inline_query_id: context.id,
results: [
InlineQueryResult.article(
"id-1",
"some article",
InputMessageContent.text("my article"),
),
],
});Constructors
Constructor
new InputMessageContent():
InputMessageContent
Returns
InputMessageContent
Methods
contact()
staticcontact(phoneNumber,firstName,options?):TelegramInputContactMessageContent
Defined in: keyboards/index.d.ts:695
Represents the content of a contact message to be sent as the result of an inline query.
Parameters
| Parameter | Type |
|---|---|
phoneNumber | string |
firstName | string |
options? | Omit<TelegramInputContactMessageContent, "phone_number" | "first_name"> |
Returns
TelegramInputContactMessageContent
invoice()
staticinvoice(options):TelegramInputInvoiceMessageContent
Defined in: keyboards/index.d.ts:701
Represents the content of an invoice message to be sent as the result of an inline query.
Parameters
| Parameter | Type |
|---|---|
options | TelegramInputInvoiceMessageContent |
Returns
TelegramInputInvoiceMessageContent
location()
staticlocation(latitude,longitude,options?):TelegramInputLocationMessageContent
Defined in: keyboards/index.d.ts:683
Represents the content of a location message to be sent as the result of an inline query.
Parameters
| Parameter | Type |
|---|---|
latitude | number |
longitude | number |
options? | Omit<TelegramInputLocationMessageContent, "latitude" | "longitude"> |
Returns
TelegramInputLocationMessageContent
text()
statictext(text,options?):TelegramInputTextMessageContent
Defined in: keyboards/index.d.ts:677
Represents the content of a text message to be sent as the result of an inline query.
Parameters
| Parameter | Type |
|---|---|
text | string |
options? | Omit<TelegramInputTextMessageContent, "message_text"> |
Returns
TelegramInputTextMessageContent
venue()
staticvenue(options):TelegramInputLocationMessageContent
Defined in: keyboards/index.d.ts:689
Represents the content of a venue message to be sent as the result of an inline query.
Parameters
| Parameter | Type |
|---|---|
options | TelegramInputVenueMessageContent |