justijndepover / bullhorn-api
Bullhorn API 的 PHP 客户端
0.4.0
2022-01-12 10:28 UTC
Requires
- guzzlehttp/guzzle: ^6.3
Requires (Dev)
- justijndepover/php-check: ^0.12.0
- orchestra/testbench: ^6.22
- phpunit/phpunit: ^9.5
This package is auto-updated.
Last update: 2024-09-12 16:09:21 UTC
README
Bullhorn API 的 PHP 客户端
注意
此应用程序仍在开发中,可能会实现破坏性更改。请自行承担风险使用。
安装
您可以使用 composer 安装此包
composer require justijndepover/bullhorn-api
用法
连接到 Bullhorn
// note the state param: this can be a random string. It's used as an extra layer of protection. Bullhorn will return this value when connecting. $bullhorn = new Bullhorn(CLIENT_ID, CLIENT_SECRET, REDIRECT_URI, STATE); // if you already possess authentication credentials, provide them: $bullhorn->setAccessToken($accessToken); $bullhorn->setRefreshToken($refreshToken); $bullhorn->setTokenExpiresAt($expiresAt); $bullhorn->setRestUrl($restUrl); $bullhorn->setBHRestToken($BHRestToken); // when one of the tokens (accesstoken, refreshtoken, BHRestToken) changes, a callback method is called. Giving you the opportunity to store them. $bullhorn->setTokenUpdateCallback(function ($bullhorn) { // you should store away these tokens $bullhorn->getAccessToken(); $bullhorn->getRefreshToken(); $bullhorn->getTokenExpiresAt(); $bullhorn->getRestUrl(); $bullhorn->getBHRestToken(); }); // open the connection $bullhorn->connect();
您的应用程序现在已连接。要开始获取数据
$bullhorn->get('entity/Candidate/5059165');
安全性
如果您发现任何与安全性相关的问题,请打开一个问题或直接通过 justijndepover@gmail.com 联系我。
贡献
如果您希望对该包进行任何更改或改进,请随时提交拉取请求。
许可
MIT 许可证 (MIT)。有关更多信息,请参阅 许可文件。