PHP Interface Telegram\Bot\Commands\CommandInterface

Mostra file Open project: irazasyed/telegram-bot-sdk

Public Methods

Method Description
getAliases ( ) : array Get Command Aliases
getDescription ( ) : string Get Command Description.
getName ( ) : string Get Command Name.
make ( Api $telegram, string $arguments, Update $update ) : mixed Process Inbound Command.

Method Details

getAliases() public method

Helpful when you want to trigger command with more than one name.
public getAliases ( ) : array
return array

getDescription() public method

The Telegram command description.
public getDescription ( ) : string
return string

getName() public method

The name of the Telegram command. Ex: help - Whenever the user sends /help, this would be resolved.
public getName ( ) : string
return string

make() public method

Process Inbound Command.
public make ( Api $telegram, string $arguments, Update $update ) : mixed
$telegram Telegram\Bot\Api
$arguments string
$update Telegram\Bot\Objects\Update
return mixed