public function sendPhoto(
        $chatId,
        $photo,
        $caption = null,
        $replyToMessageId = null,
        $replyMarkup = null,
        $disableNotification = false,
        $parseMode = null
    ) {
        return Message::fromResponse($this->call('sendPhoto', [
            'chat_id' => $chatId,
            'photo' => $photo,
            'caption' => $caption,
            'reply_to_message_id' => $replyToMessageId,
            'reply_markup' => is_null($replyMarkup) ? $replyMarkup : $replyMarkup->toJson(),
            'disable_notification' => (bool)$disableNotification,
            'parse_mode' => $parseMode
        ]));
    }
public function sendPhoto(
        $chatId,
        $photo,
        $caption = null,
        $replyToMessageId = null,
        $replyMarkup = null,
        $disableNotification = false,
        $parseMode = null
    ) {
        return Message::fromResponse($this->call('sendPhoto', [
            'chat_id' => $chatId,
            'photo' => $photo,
            'caption' => $caption,
            'reply_to_message_id' => $replyToMessageId,
            'reply_markup' => is_null($replyMarkup) ? $replyMarkup : $replyMarkup->toJson(),
            'disable_notification' => (bool)$disableNotification,
            'parse_mode' => $parseMode
        ]));
    }
public function sendPhoto ( $ chatId , $ photo , $ caption = null , $ replyToMessageId = null , $ replyMarkup = null , $ disableNotification = false , $ parseMode = null ) { return Message :: fromResponse ( $ this -> call ( 'sendPhoto' , [ 'chat_id' => $ chatId , 'photo' => $ photo , 'caption' => $ caption , 'reply_to_message_id' => $ replyToMessageId , 'reply_markup' => is_null ( $ replyMarkup ) ? $ replyMarkup : $ replyMarkup -> toJson ( ) , 'disable_notification' => ( bool ) $ disableNotification , 'parse_mode' => $ parseMode ] ) ) ; }
Use this method to send photos. On success, the sent Message is returned.

@param int|string $chatId chat_id or @channel_name
@param \CURLFile|string $photo
@param string|null $caption
@param int|null $replyToMessageId
@param Types\ReplyKeyboardMarkup|Types\ReplyKeyboardHide|Types\ForceReply|
Types\ReplyKeyboardRemove|null $replyMarkup
@param bool $disableNotification
@param string|null $parseMode

@return \TelegramBot\Api\Types\Message
@throws \TelegramBot\Api\InvalidArgumentException
@throws \TelegramBot\Api\Exception
Use this method to send photos . On success the sent Message is returned .