slvler / tmdb
TMDB.com api service for php
Installs: 8
Dependents: 0
Suggesters: 0
Security: 0
Stars: 6
Watchers: 2
Forks: 0
Open Issues: 0
Type:package
Requires (Dev)
- phpunit/phpunit: ^9.5
README
An api service for tmdb.com
Installation
To install this package tou can use composer:
composer require slvler/tmdb
Usage
- first step is to start client client with required url, version, api key
$option['base_url'] = 'https://api.themoviedb.org/3/' $option['api_key'] = 'xxxx' $option['version'] = '3' $client = new Client($option);
- You need to make a request to the tmdb service with the service point we created.
$tmdb = new Tmdb($client);
- Then you can send a request like this to bring the information of the movie we want.
$tmdb->movie("550");
- You can it to fetch player information.
$tmdb->people("13");
- to search on the specified keyword
$tmdb->keyword("550");
- to search in the specified condition
$tmdb->network("550");
- You can it to search in specified situations.
$tmdb->review("58aa82f09251416f92006a3a");
- You want this service when you want a TV program.
$tmdb->tv("111");
- movies with collection
$tmdb->collection("10");
Testing
vendor\bin\phpunit
Credits
License
The MIT License (MIT). Please see License File for more information.