jobbrander / jobs-ziprecruiter
1.1.0
2017-10-04 21:41 UTC
Requires
- php: >=5.5.0
- jobapis/jobs-common: ^2.0.0
Requires (Dev)
- mockery/mockery: >=0.9.4
- phpunit/php-code-coverage: ~2.0
- phpunit/phpunit: >=4.6
- squizlabs/php_codesniffer: ~2.0
This package is not auto-updated.
Last update: 2022-02-01 12:50:04 UTC
README
此包为 ZipRecruiter Jobs API 提供了对 Jobs Common 的支持。
安装
要安装,请使用 composer
composer require jobapis/jobs-ziprecruiter
使用方法
创建一个查询对象并通过构造函数添加所有所需的参数。
// Add parameters to the query via the constructor $query = new JobApis\Jobs\Client\Queries\ZiprecruiterQuery([ 'api_key' => YOUR_API_KEY ]);
或者通过 "set" 方法。所有在Indeed文档中记录的参数都可以添加。
// Add parameters via the set() method $query->set('search', 'engineering');
如果您愿意,甚至可以链式调用它们。
// Add parameters via the set() method $query->set('location', 'Chicago, IL') ->set('jobs_per_page', '100');
然后将查询对象注入到提供者中。
// Instantiating an IndeedProvider with a query object $client = new JobApis\Jobs\Client\Provider\ZiprecruiterProvider($query);
调用 "getJobs" 方法以获取结果。
// Get a Collection of Jobs $jobs = $client->getJobs();
"getJobs" 方法将返回一个 Collection,其中包含 Job 对象。
测试
$ ./vendor/bin/phpunit
贡献
请参阅 CONTRIBUTING 以获取详细信息。
鸣谢
许可证
Apache 2.0。请参阅 许可证文件 以获取更多信息。