PHP code example of combindma / laravel-sendinblue

1. Go to this page and download the library: Download combindma/laravel-sendinblue 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/ */

    

combindma / laravel-sendinblue example snippets


return [
    /*
   * Enable or disable Sendinblue. Useful for local development when running tests.
   */
    'api_enabled' => env('SENDINBLUE_ENABLED', false),

    /*
     * The API key of a Sendinblue account.
     */
    'apiKey' => env('SENDINBLUE_APIKEY'),

    /*
     * The default Ids of the lists to add the contact to when no listIds has been specified in a method.
     */
    'defaultListIds' => [
        2,
    ]
];

Sendinblue::subscribe('[email protected]');

Sendinblue::subscribe('[email protected]', ['FNAME'=>'Rince', 'LNAME'=>'Wind'];

Sendinblue::subscribe('[email protected]', ['FNAME'=>'Rince', 'LNAME'=>'Wind'], [2]);

Sendinblue::unsubscribe('[email protected]');
bash
php artisan vendor:publish --tag="sendinblue-config"