feature: IMDB movie/TV extractor #30

Closed
opened 2026-02-14 16:13:07 +00:00 by Claude · 1 comment
Collaborator

Description

Mort integrates with TMDB for movie data. An IMDB extractor would provide complementary data (user ratings, box office, trivia) and could power mortbux prediction markets on movie scores or box office performance.

Proposed API

package imdb

type Movie struct {
    ID          string   // e.g. "tt1234567"
    Title       string
    Year        int
    Rating      float64  // IMDB score (0-10)
    Votes       int
    Runtime     string
    Genres      []string
    Director    string
    Cast        []string
    Plot        string
    PosterURL   string
    BoxOffice   string   // e.g. "$200,000,000"
}

type Config struct{}
var DefaultConfig = Config{}

func (c Config) GetMovie(ctx context.Context, b extractor.Browser, id string) (*Movie, error)
func (c Config) Search(ctx context.Context, b extractor.Browser, query string) ([]Movie, error)

URL Patterns

  • Movie page: https://www.imdb.com/title/{id}/
  • Search: https://www.imdb.com/find/?q={query}

Benefits

  • Mort could offer .imdb command for quick movie lookups
  • Powers mortbux prediction markets ("Will this movie score above 7.0?")
  • Complements existing TMDB integration with user ratings and box office data
## Description Mort integrates with TMDB for movie data. An IMDB extractor would provide complementary data (user ratings, box office, trivia) and could power mortbux prediction markets on movie scores or box office performance. ## Proposed API ```go package imdb type Movie struct { ID string // e.g. "tt1234567" Title string Year int Rating float64 // IMDB score (0-10) Votes int Runtime string Genres []string Director string Cast []string Plot string PosterURL string BoxOffice string // e.g. "$200,000,000" } type Config struct{} var DefaultConfig = Config{} func (c Config) GetMovie(ctx context.Context, b extractor.Browser, id string) (*Movie, error) func (c Config) Search(ctx context.Context, b extractor.Browser, query string) ([]Movie, error) ``` ## URL Patterns - Movie page: `https://www.imdb.com/title/{id}/` - Search: `https://www.imdb.com/find/?q={query}` ## Benefits - Mort could offer `.imdb` command for quick movie lookups - Powers mortbux prediction markets ("Will this movie score above 7.0?") - Complements existing TMDB integration with user ratings and box office data
Claude added the enhancementpriority/medium labels 2026-02-14 21:01:05 +00:00
Author
Collaborator

Implemented in PR #49. Added sites/imdb package with GetMovie() (by IMDB ID) and Search() (by query). Extracts title, year, rating, votes, runtime, genres, director, cast, plot, poster, and box office. Uses JSON-LD parsing for Movie/TVSeries/TVMiniSeries types with DOM fallback. Full mock-based test coverage.

Implemented in PR #49. Added `sites/imdb` package with `GetMovie()` (by IMDB ID) and `Search()` (by query). Extracts title, year, rating, votes, runtime, genres, director, cast, plot, poster, and box office. Uses JSON-LD parsing for Movie/TVSeries/TVMiniSeries types with DOM fallback. Full mock-based test coverage.
Sign in to join this conversation.