mirror of
https://github.com/v2board/v2board.git
synced 2025-06-15 06:07:49 +08:00
update telegram
This commit is contained in:
20
app/Http/Controllers/User/TelegramController.php
Normal file
20
app/Http/Controllers/User/TelegramController.php
Normal file
@ -0,0 +1,20 @@
|
||||
<?php
|
||||
|
||||
namespace App\Http\Controllers\User;
|
||||
|
||||
use App\Http\Controllers\Controller;
|
||||
use App\Services\TelegramService;
|
||||
|
||||
class TelegramController extends Controller
|
||||
{
|
||||
public function getBotInfo()
|
||||
{
|
||||
$telegramService = new TelegramService();
|
||||
$response = $telegramService->getMe();
|
||||
return response([
|
||||
'data' => [
|
||||
'username' => $response->result->username
|
||||
]
|
||||
]);
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user