Для всех кто задается подобным вопросом:
Пример работающего у меня кода:
$url = "
https://api.telegram.org/bot" . $api . "/sendMediaGroup";
$postContent = [
'chat_id' => $chat_id,
'media' => json_encode([
['type' => 'photo', 'media' => '
https://mytelegrambot.club/escooter/img/users_img/...' ],
['type' => 'photo', 'media' => '
https://mytelegrambot.club/escooter/img/users_img/...' ],
['type' => 'photo', 'media' => '
https://mytelegrambot.club/escooter/img/users_img/...' ]
]),
];
$curl = curl_init();
curl_setopt($curl, CURLOPT_URL, $url);
curl_setopt($curl, CURLOPT_POSTFIELDS, $postContent);
curl_setopt($curl, CURLOPT_RETURNTRANSFER, true);
curl_setopt($curl, CURLOPT_HTTPHEADER, ['Content-Type: multipart/form-data']);
$result = curl_exec($curl);
curl_close($curl);