darkin1 / intercom
Intercom 类的包装器,由Intercom提供 - 支持 Laravel 5.x, 6.x, 7.x
v3.0.0
2021-05-19 09:29 UTC
Requires
- php: >= 7.3
- guzzlehttp/psr7: ^1.7.0
- illuminate/support: ^5.8|^6.0|^7.0|^8.0
- intercom/intercom-php: ^4.0
This package is not auto-updated.
Last update: 2024-09-24 16:41:46 UTC
README
Intercom 类的包装器,由Intercom提供 - 支持 Laravel 5.x, 6.x, 7.x, 8.x
安装
使用composer安装
composer require darkin1/intercom
并在 config/app.php
中添加服务提供者
Darkin1\Intercom\IntercomServiceProvider::class,
并在 config/app.php
中添加外观别名
'Intercom' => Darkin1\Intercom\Facades\Intercom::class,
配置
在 app/config/intercom.php
中更改默认设置
<?php return [ 'access_token' => env('INTERCOM_ACCESS_TOKEN', '****'), 'api_version' => env('INTERCOM_API_VERSION', '1.1'), ];
查看官方文档,以查看可用的 Intercom API 版本列表
示例
use Intercom; $users = Intercom::users()->getUsers([]); $leads = Intercom::leads()->getLeads([]);