Skip to content

Latest commit

 

History

History
33 lines (22 loc) · 942 Bytes

README.md

File metadata and controls

33 lines (22 loc) · 942 Bytes

go-themoviedb Build Status

Golang interface to The Movie DB (TMDb) APIs

See the godoc go-themoviedb documentation

Golang library for requesting metadata from themoviedb.org It's used by

  1. Initializing the library via Init(), with the caller's API key from http://www.themoviedb.org like

  2. Calling MovieData() to get the actual data, like

package main

import "fmt"
import "github.com/amahi/go-themoviedb"

func main() {
        tmdb := tmdb.Init("your-api-key")
        metadata, err := tmdb.MovieData("Pulp Fiction")
        if err != nil {
                fmt.Printf("Error: %s\n", err)
        } else {
                fmt.Printf("TMDb Metadata: %s\n", metadata)
        }
}

the metadata is returned in XML format according to TMDB guidelines.