1. Go to this page and download the library: Download arueckauer/harvest-api library. Choose the download type require.
2. Extract the ZIP file and open the index.php.
3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
declare(strict_types=1);
namespace App\Handler;
use Psr\Container\ContainerInterface;
class HarvestApiFactory
{
public function __invoke(ContainerInterface $container) : HarvestApi
{
return new HarvestApi($container->get(\arueckauer\HarvestApi\Client::class));
}
}
// public/index.php
n' => 'Bearer $ACCESS_TOKEN',
'Harvest-Account-Id' => '$ACCOUNT_ID',
'User-Agent' => 'MyApp ([email protected])',
];
$client = new \arueckauer\HarvestApi\Client($headers);
Loading please wait ...
Before you can download the PHP files, the dependencies should be resolved. This can take some minutes. Please be patient.