naffiq/telegram-channel-php
最新稳定版本:v1.0.2
Composer 安装命令:
composer require naffiq/telegram-channel-php
包简介
Post to your telegram channel with ease!
README 文档
README
This little lib (1 class only!) helps you to push messages to your telegram channel via bot.
Installation
In order to install use composer:
$ composer require naffiq/telegram-channel-php
Usage
- Create bot via BotFather and get
BOT_TOKENfrom it - Add it as an admin to your channel
- Follow examples below to post messages or photos:
Post message
<?php $manager = new \naffiq\telegram\channel\Manager(BOT_TOKEN, CHANNEL_NAME); $manager->postMessage('Hello, fellas!');
Post photo
<?php $manager = new \naffiq\telegram\channel\Manager(BOT_TOKEN, CHANNEL_NAME); $manager->postPhoto(__DIR__ . '/photo.jpeg', 'Put your label here');
统计信息
- 总下载量: 3.95k
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 12
- 点击次数: 1
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2017-08-25