/omdb-api

Ruby interface to the OMDB API

Primary LanguageRubyMIT LicenseMIT

Omdb Api

home

github.com/nikkypx/omdb-api

DESCRIPTION:

Ruby interface to the Open Movie Database API

FEATURES/PROBLEMS:

#find_by_id
#find_by_title
#search

SYNOPSIS:

require 'omdb/api'

client = Omdb::Api::Client.new(api_key: [your API key])`

or configure with a block

client = Omdb::Api::Client.new do |config|
  config.api_key = api_key
end

client.find_by_title('star wars')
=> #<Omdb::Api::Movie:0x007f9a7d453cf0 @actors="Harrison Ford"...

client.find_by_id('tt0083929')
=> #<Omdb::Api::Movie:0x007f960a648f28 @actors="Sean Penn, Jennifer Jason Leigh, Judge Reinhold, Robert Romanus",

client.search('indiana jones')
=> [#<Omdb::Api::Movie:0x007ffec28ad1a8 @title="Indiana...

REQUIREMENTS:

  • ruby >= 2.5.0

INSTALL:

gem install omdb-api

LICENSE:

(The MIT License)

Copyright © 2022 Nicholas Palaniuk

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.