### Install Laravel Wistia with Composer Source: https://github.com/jeffersongoncalves/laravel-wistia/blob/main/README.md Installs the Laravel Wistia package via Composer. ```bash composer require jeffersongoncalves/laravel-wistia ``` -------------------------------- ### Run Code Formatting with Composer Source: https://github.com/jeffersongoncalves/laravel-wistia/blob/main/README.md Runs code formatting (Pint) on the codebase. ```bash composer format ``` -------------------------------- ### Run Tests with Composer Source: https://github.com/jeffersongoncalves/laravel-wistia/blob/main/README.md Runs the test suite for the package. ```bash composer test ``` -------------------------------- ### Run Static Analysis with Composer Source: https://github.com/jeffersongoncalves/laravel-wistia/blob/main/README.md Runs static analysis (PHPStan) on the codebase. ```bash composer analyse ``` -------------------------------- ### Use WistiaClient for Account, Projects, Medias, Stats, and Captions Source: https://github.com/jeffersongoncalves/laravel-wistia/blob/main/README.md Shows the main usage of the WistiaClient static methods for account, projects, medias, stats, and captions. Single-resource methods return array|null, collections return list|null, and delete methods return bool; null/false on network failure or non-2xx. Null arguments are stripped from the payload. ```php use JeffersonGoncalves\Wistia\WistiaClient; // Account $account = WistiaClient::account(); $accountStats = WistiaClient::accountStats(); // Projects $projects = WistiaClient::projects(['per_page' => 50]); $project = WistiaClient::project('abc123'); $created = WistiaClient::createProject('Onboarding', public: true, description: 'Customer onboarding videos'); WistiaClient::updateProject('abc123', ['name' => 'Onboarding 2026']); WistiaClient::deleteProject('abc123'); $projectStats = WistiaClient::projectStats('abc123'); // Medias $medias = WistiaClient::medias(['project_id' => 'abc123', 'type' => 'Video']); $media = WistiaClient::media('vid1'); WistiaClient::updateMedia('vid1', ['name' => 'Intro', 'description' => 'Welcome']); WistiaClient::copyMedia('vid1', targetProjectId: 'def456'); WistiaClient::deleteMedia('vid1'); $mediaStats = WistiaClient::mediaStats('vid1'); // Stats $byDate = WistiaClient::mediaStatsByDate('vid1', startDate: '2026-09-01', endDate: '2026-09-07'); $engagement = WistiaClient::mediaEngagement('vid1'); $visitors = WistiaClient::visitors(['search' => 'jane', 'per_page' => 50]); $visitor = WistiaClient::visitor('visitor_key'); $events = WistiaClient::events(['media_id' => 'vid1']); // Captions $captions = WistiaClient::captions('vid1'); WistiaClient::createCaption('vid1', 'eng', file_get_contents('subtitles.srt')); ``` -------------------------------- ### Laravel Wistia Config Options Source: https://github.com/jeffersongoncalves/laravel-wistia/blob/main/README.md Default configuration file for the package. When 'token' is null, the client falls back to config('services.wistia.token'). ```php // config/wistia.php return [ 'token' => env('WISTIA_API_KEY'), 'timeout' => (int) env('WISTIA_TIMEOUT', 8), ]; ``` -------------------------------- ### Set WISTIA_API_KEY in .env Source: https://github.com/jeffersongoncalves/laravel-wistia/blob/main/README.md Sets the Wistia API key in the .env file. Create an API password from the Wistia account API settings. ```env WISTIA_API_KEY=... ``` -------------------------------- ### Publish Laravel Wistia Config Source: https://github.com/jeffersongoncalves/laravel-wistia/blob/main/README.md Publishes the package configuration file (config/wistia.php) to the application. ```bash php artisan vendor:publish --tag="laravel-wistia-config" ``` === COMPLETE CONTENT === This response contains all available snippets from this library. No additional content exists. Do not make further requests.