denand / tvdb-v4-client
TVDB V4 API Client for PHP
Installs: 0
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 0
Forks: 0
Open Issues: 0
pkg:composer/denand/tvdb-v4-client
Requires
- php: ^7.4|^8.0|^8.1|^8.2|^8.3|^8.4
- ext-json: *
- guzzlehttp/guzzle: ^7.0.1
- illuminate/support: ^8.0||^9.0||^10.0||^11.0
Requires (Dev)
- orchestra/testbench: ^6.0
- phpunit/phpunit: ^9.0
README
TVDB V4 Client for PHP/Laravel
A comprehensive PHP client for The TVDB V4 API, designed to work seamlessly with Laravel applications. This package provides easy access to The TVDB's extensive database of TV series, movies, and related metadata.
๐ Official Documentation
- The TVDB V4 API Documentation - Complete API reference and endpoints
- The TVDB API Information & Licensing - API pricing, licensing, and attribution requirements
๐ Features
- Full TVDB V4 API Support - Access to all available endpoints
- Laravel Integration - Seamless Laravel service provider and facade
- Extended Data Support - Get comprehensive series, episode, and movie information
- Translation Support - Multi-language content retrieval
- Search Functionality - Powerful search capabilities across the database
- Type and Status Support - Access to metadata types and statuses
- Laravel 10 Compatible - Updated for the latest Laravel version
๐ฆ Installation
Via Composer
You can install the package with Composer using Packagist:
composer require denand/tvdb-v4-client
Configuration
- Publish the configuration file:
php artisan vendor:publish --provider="DenAnd\TvdbV4Client\TvdbV4ClientServiceProvider"
- Configure your TVDB API credentials in
config/tvdb-v4-client.php:
return [ 'api_key' => env('TVDB_API_KEY', ''), 'api_pin' => env('TVDB_API_PIN', ''), // Add other configuration options as needed ];
- Add your TVDB API credentials to your
.envfile:
TVDB_API_KEY=your_api_key_here TVDB_API_PIN=your_api_pin_here
๐ง Usage
Basic Usage
use DenAnd\TvdbV4Client\TvdbV4Client; $tvdb = new TvdbV4Client(); // Get extended data for a TV series $series = $tvdb->getSeries('269586'); // Get series translations $translations = $tvdb->getSeriesTranslations('269586', 'eng'); // Get series with full data (translations + extended data) $seriesFull = $tvdb->getSeriesFull('269586', 'eng'); // Search for series $search = $tvdb->search('Brooklyn Nine-Nine'); // Search and get extended data $seriesByName = $tvdb->getSeriesByName('Brooklyn Nine-Nine');
Laravel Facade Usage
use DenAnd\TvdbV4Client\Facades\TvdbV4Client; // Using the facade $series = TvdbV4Client::getSeries('269586'); $search = TvdbV4Client::search('Breaking Bad');
Available Methods
getSeries($id)- Get extended series datagetSeriesTranslations($id, $language)- Get series translationsgetSeriesFull($id, $language)- Get series with translations and extended datasearch($query)- Search for series, movies, or peoplegetSeriesByName($name)- Search and get extended data by namegetTypes()- Get available typesgetStatuses()- Get available statuses
๐งช Testing
composer test
๐ Requirements
- PHP 7.4 or higher
- Laravel 8.0+ (for Laravel integration)
- The TVDB API credentials
๐ API Documentation & Resources
- The TVDB V4 API Documentation - Complete API reference
- The TVDB API Information - Licensing, pricing, and attribution requirements
- The TVDB Website - Main website and data contribution
๐ Changelog
Please see CHANGELOG for more information about recent changes.
๐ค Contributing
Please see CONTRIBUTING for details.
Security
If you discover any security related issues, please email denandteam@gmail.com instead of using the issue tracker.
๐ License
The MIT License (MIT). Please see License File for more information.
๐ Attribution
When using this package, please ensure you comply with The TVDB's attribution requirements. Display the following attribution to end users:
"Metadata provided by TheTVDB. Please consider adding missing information or subscribing."
For more information about attribution requirements, visit The TVDB API Information page.
๐ฅ Credits
- DenAnd Team - Package development and maintenance
- The TVDB - API and data provider