PHP code example of veksa / carrot-yii2

1. Go to this page and download the library: Download veksa/carrot-yii2 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/ */

    

veksa / carrot-yii2 example snippets


    'components' => [
        // ...
        'carrot' => [
            'class' => 'Veksa\Carrot\Yii2\Service',
            'appId' => 'your carrot application id',
            'token' => 'your carrot access token'
        ],
        // ...
    ],
    

$carrot = Yii::$app->get('carrot');
$leads = $carrot->getCountLeads();

php composer.phar