appdb/php-push-sender
最新稳定版本:1.0.1
Composer 安装命令:
composer require appdb/php-push-sender
包简介
PHP library to send push notifications via appdb push service
README 文档
README
This library allows you to send push notifications to your apps that are published on appdb.
More information about appdb push notification service can be found on Documentation website
Installation
composer require appdb/php-push-sender
Sending of push notification (sample code)
require_once 'vendor/autoload.php';
$sender = new \Appdb\PhpPushSender\PhpPushSender('push_xxx', 'xxx');
$payload = [
'aps' => [
'alert' => [
'title' => 'test',
'subtitle' => 'test notification',
'body' => 'test at ' . date('r')
]
]
];
$destinations['c_xxx'] = []; // sending to this customer
// OR
$destinations['c_xxx'][] = 'd_xxx'; // sending to specific device of customer
$pushSendResult = $sender->send($payload, $destinations);
var_dump($pushSendResult);
统计信息
- 总下载量: 10
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 5
- 点击次数: 0
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: GPL-3.0-or-later
- 更新时间: 2024-04-24