arungpisyadi/sibex
Composer 安装命令:
composer require arungpisyadi/sibex
包简介
A more straight forward package to use SendinBlue API V3 in Laravel environment (Ex : Express Solution). The package will enable you to handle SendInBlue various functions through Laravel Facade, mostly related to building email list and managing marketing campaign.
README 文档
README
A more straight forward package to use SendinBlue API V3 in Laravel environment (Ex : Express Solution). The package will enable you to handle SendInBlue various functions through Laravel Facade, mostly related to building email list and managing marketing campaign.
Requirements
- PHP 7 and later
- Laravel 5.8+
Installation
Via Composer
$ composer require arungpisyadi/sibex
Basic Usage
<?php
use ArungPIsyadi\SiBex\SiBex;
// These values is better kept save on .env file.
$sibex = new SiBex(SIB_API_TYPE, SIB_API_KEY); // either "api-key" or "partner-key", your SendInBlue API key.
# Account function.
dump($account = $sibex->getAccount());
dump('email: '.$account['email']); // there are other return parameters that you can check your self.
# Contact function.
// get your lists
dump($sibex->getLists($limit, $offset));
// create a new list.
dump($this->sibex->createList());
// add a new email address as our contact in SendInBlue.
$request->email = 'test+temp01@example.com';
dump($sibex->createContact($request->email));
// add a contact based on email to a certain list.
$added = $sibex->addContactToList($list_id, $emails); // $list_id must be an integer, $emails is a separated by comma string.
dump($added);
//Get contacts from a list.
$contacts = $sibex->getContactsFromList($list_id);
dump($contacts);
?>
Change log
Please see the changelog for more information on what has changed recently.
Testing
$ composer test
Contributing
Please see contributing.md for details and a todolist.
Security
If you discover any security related issues, please email isyadiarung@gmail.com instead of using the issue tracker.
Credits
License
GNU. Please see the license file for more information.
统计信息
- 总下载量: 13
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 0
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2020-09-25