omdb

Client implementation of the OMDB API.
https://gitlab.com/haath/omdb-haxe

To install, run:

haxelib install omdb 1.2.4 

See using Haxelib in Haxelib documentation for more information.

README.md

haxelib-template

build status test coverage license haxelib version haxelib downloads


Haxe client implementation of the OMDB API.

Currently, only the free public API is supported. If you're interested in the user-level API please make a PR.

Installation

The library is available on Haxelib.

haxelib install omdb

Usage

All the methods return tink_core Promise.

var client: OmdbClient = new OmdbClient('api key');

client.getById('tt0848228').map(r -> r.sure()).handle(movie ->
{
    // movie.title, movie.year ...
});

client.getByTitle('avengers').map(r -> r.sure()).handle(movie ->
{
    // movie.title: The Avengers
    // movie.year: 2012
});

client.getByTitle('avengers', 2019).map(r -> r.sure()).handle(movie ->
{
    // movie.title: Avengers: Endgame
    // movie.year: 2019
});

client.search('the avengers').map(r -> r.sure()).handle(movies ->
{
    for (movie in movies)
    {
        // movie.title, movie.year ...
    }
});

Versioning

This library will follow the M.m.p versioning scheme, where:

  • M: the major number will follow the OMDB API version
  • m: the minor number will be incremented when forward-breaking changes are made to the library's interface
  • p: the patch number will be incremented when non-breaking changes are made to the library's interface
Contributors
Haath
Version
1.2.4
Published
1 year ago
Dependencies
License
MIT

All libraries are free

Every month, more than a thousand developers use Haxelib to find, share, and reuse code — and assemble it in powerful new ways. Enjoy Haxe; It is great!

Explore Haxe

Haxe Manual

Haxe Code Cookbook

Haxe API documentation

You can try Haxe in the browser! try.haxe.org

Join us on GitHub!

Haxe is being developed on GitHub. Feel free to contribute or report issues to our projects.

Haxe on GitHub