### Install Laravel Hunter via Composer Source: https://github.com/jeffersongoncalves/laravel-hunter/blob/main/README.md Installs the Laravel Hunter package via Composer. ```bash composer require jeffersongoncalves/laravel-hunter ``` -------------------------------- ### Campaign Management Operations Source: https://github.com/jeffersongoncalves/laravel-hunter/blob/main/README.md Manages campaigns: list, get, start, and pause. ```php Hunter::listCampaigns(limit: 10, offset: 0); Hunter::getCampaign('campaign-id'); Hunter::startCampaign('campaign-id'); Hunter::pauseCampaign('campaign-id'); ``` -------------------------------- ### Lead Management Operations Source: https://github.com/jeffersongoncalves/laravel-hunter/blob/main/README.md Manages leads: list, get, create, and delete. ```php Hunter::listLeads(limit: 10, offset: 0); Hunter::getLead('lead-id'); Hunter::createLead('jane@example.com', firstName: 'Jane', lastName: 'Doe', company: 'Acme'); Hunter::deleteLead('lead-id'); ``` -------------------------------- ### Get Hunter Account Info Source: https://github.com/jeffersongoncalves/laravel-hunter/blob/main/README.md Retrieves account information from Hunter.io. ```php Hunter::accountInfo(); ``` -------------------------------- ### Domain Search and Email Count Source: https://github.com/jeffersongoncalves/laravel-hunter/blob/main/README.md Performs a domain search and gets the email count for a domain. ```php Hunter::domainSearch('example.com', limit: 10, type: 'personal'); Hunter::emailCount('example.com', type: 'personal'); ``` -------------------------------- ### Run Static Analysis Source: https://github.com/jeffersongoncalves/laravel-hunter/blob/main/README.md Runs static analysis. ```bash composer analyse ``` -------------------------------- ### Run Tests Source: https://github.com/jeffersongoncalves/laravel-hunter/blob/main/README.md Runs the test suite. ```bash composer test ``` -------------------------------- ### Import Hunter Facade and Exception Source: https://github.com/jeffersongoncalves/laravel-hunter/blob/main/README.md Imports the Hunter facade and HunterException for use in your code. ```php use JeffersonGoncalves\Hunter\Facades\Hunter; use JeffersonGoncalves\Hunter\Exceptions\HunterException; ``` -------------------------------- ### Run Code Formatting Source: https://github.com/jeffersongoncalves/laravel-hunter/blob/main/README.md Runs code formatting. ```bash composer format ``` -------------------------------- ### Publish Hunter Config File Source: https://github.com/jeffersongoncalves/laravel-hunter/blob/main/README.md Optionally publishes the package's configuration file. ```bash php artisan vendor:publish --tag="hunter-config" ``` -------------------------------- ### Leads Lists Operations Source: https://github.com/jeffersongoncalves/laravel-hunter/blob/main/README.md Lists and retrieves leads lists. ```php Hunter::listLeadsLists(limit: 10, offset: 0); Hunter::getLeadsList('list-id'); ``` -------------------------------- ### Set Hunter API Key in .env Source: https://github.com/jeffersongoncalves/laravel-hunter/blob/main/README.md Sets the Hunter.io API key in the .env file. Find your key at https://hunter.io/api-keys. ```env HUNTER_API_KEY=your-api-key ``` -------------------------------- ### Hunter Config Options Source: https://github.com/jeffersongoncalves/laravel-hunter/blob/main/README.md Configuration options for the Hunter package: api_key and base_url, both read from environment variables. ```php // config/hunter.php return [ 'api_key' => env('HUNTER_API_KEY'), 'base_url' => env('HUNTER_BASE_URL', 'https://api.hunter.io/v2'), ]; ``` -------------------------------- ### Email Finder and Verifier Source: https://github.com/jeffersongoncalves/laravel-hunter/blob/main/README.md Finds an email address for a person and verifies an email address. ```php Hunter::findEmail('example.com', 'Jane', 'Doe'); Hunter::verifyEmail('jane@example.com'); ``` -------------------------------- ### Handle Hunter API Errors Source: https://github.com/jeffersongoncalves/laravel-hunter/blob/main/README.md Handles errors from Hunter API calls. HunterException carries the API error message and HTTP status code; InvalidArgumentException is thrown when a required parameter is empty. ```php try { $result = Hunter::findEmail('example.com', 'Jane', 'Doe'); } catch (HunterException $e) { // $e->getMessage() — the API's errors[0].details, or the raw response body // $e->statusCode — the HTTP status code returned by Hunter.io } catch (InvalidArgumentException $e) { // a required parameter was empty } ``` === COMPLETE CONTENT === This response contains all available snippets from this library. No additional content exists. Do not make further requests.