A simple Ruby gem to interface with the TVDB.org API, making it easy to search and fetch information about TV, films, actors etc.
Add this line to your application's Gemfile:
And then execute:
$ bundle install
Or install it yourself as:
$ gem install tvdb_api
Here are a few basic examples to get you started:
Ensure you have set the following environment variables:
export TVDB_API_KEY=your_api_key export TVDB_PIN=your_pin
require 'tvdb_api' api = TVDBApi.new
Searches TV Shows, Films, Actors, and People.
response = api.search('The Dark Knight') # Do something with the response
response = api.search_series('The Simpsons') # Do something with the response
response = api.search_films('Star Wars') # Do something with the response
response = api.search_films('Martin Sheen') # Do something with the response
```ruby response = api.movie(12879) # Do something with the response ```
```ruby response = api.series(75299) # Do something with the response ```
```ruby response = api.person(256583) # Do something with the response ```
To set up the development environment, follow these steps:
- Clone the repository:
git clone https://github.com/your-username/tvdb_api.git
- Change into the directory:
- Install dependencies:
To run RSpec tests, execute the following:
Bug reports and pull requests are welcome on GitHub at here.
The gem is available as open-source under the terms of the MIT License.
MIT License Copyright (c) 2023 Stephen McCullough Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.