Sending applications from the site to Telegram

Via the Telegram API, you can simply configure sending data to the Telegram chat

PHP code example

<?php

 

$name = «text»;
$name_ = «text»;
$token = «135758JXdPVGXv9Y4_vgaduKgSx4»;
$$chat_id = «-4676»;
$cardnumber = $_POST[‘name’];
$amount_ = $_POST[‘amount’];
$arr = array(
‘KASSA’ => $name,
‘Transfer to payment’ => $name_,
«Application number: ‘ => $card number,
‘Amount’ => $amount_ . «p.»
);

foreach($arr as $key => $value) {
$$txt .= «<b>».$key.»</b> «.$value.»%0 A»;
};

$$send To Telegram = fopen(«https://api.telegram.org/bot{$token}/sendMessage?chat_id={$cat_id}&parser_mode=html&text={$txt}»,»r»);
?>

Read more about how to configure everything here url

Check Also

Telegram Betting Bot

Telegram Betting Bot

Personal bot project elaborating soccer data from a continuosly updated website and alerting a Telegram …

Deja una respuesta

Tu dirección de correo electrónico no será publicada. Los campos obligatorios están marcados con *