Skip to content

Instantly share code, notes, and snippets.

View DarkSeraphim's full-sized avatar

Mark Hendriks DarkSeraphim

View GitHub Profile
@DarkSeraphim
DarkSeraphim / example.java
Created October 19, 2016 17:05 — forked from mkotb/example.java
Telegram Inline Menu Example
InlineMenuBuilder builder = InlineMenu.builder(bot, event.getChat())
.allowedUser(event.getMessage().getSender())
.message(SendableTextMessage.markdown("*Cool Message*"))
.newRow()
.toggleButton()
.toggleCallback((button, newValue) -> "The value is " + newValue)
.newRow()
.inputButton("Click for name")
.buttonCallback((button) -> "Send me your name as a text!")
.textCallback((button, input) -> button.setText("Your name is " + input))