'A'], 'B', ['C', 'D'] ); // Buttons to perform Contact or Location sharing $keyboards[] = new Keyboard([ ['text' => 'Send my contact', 'request_contact' => true], ['text' => 'Send my location', 'request_location' => true], ]); // Shuffle our example keyboards and return a random one shuffle($keyboards); $keyboard = end($keyboards) ->setResizeKeyboard(true) ->setOneTimeKeyboard(true) ->setSelective(false); return $this->replyToChat('Press a Button!', [ 'reply_markup' => $keyboard, ]); } }