Skip to content

Commit

Permalink
Fix README errors
Browse files Browse the repository at this point in the history
  • Loading branch information
Jisin0 committed Jun 4, 2024
1 parent cfc3cbb commit 33be770
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 12 deletions.
12 changes: 6 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,9 +39,9 @@ root of each package.
```go
import "github.com/Jisin0/filmigo/imdb"

client := imdb.NewClient()

func main() {
client := imdb.NewClient()

movie, _ := client.GetMovie("t1375666")
movie.PrettyPrint()
}
Expand All @@ -52,9 +52,9 @@ func main() {
```go
import "github.com/Jisin0/filmigo/omdb"

client := omdb.NewClient("your_api_key")

func main() {
client := omdb.NewClient("your_api_key")

movie, _ := client.GetMovie("t1375666")
movie.PrettyPrint()
}
Expand All @@ -67,9 +67,9 @@ of the movie which is more common within justwatch.
```go
import "github.com/Jisin0/filmigo/justwatch"

client := justwatch.NewClient()

func main() {
client := justwatch.NewClient()

movie, _ := client.GetTitle("tm92641")
movie.PrettyPrint()
}
Expand Down
8 changes: 4 additions & 4 deletions justwatch/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ The justwatch package offers methods to browse justwatch and get data about enti
## Table Of Content
- [Setup](#setup)
- [Search](#search)
- [Fetch Movie](#getmovie)
- [Fetch Title Offers](#getoffers)
- [Fetch Movie](#get-title)
- [Fetch Title Offers](#get-title-offers)

## Guide
Here's a short guide of the available methods and it's usage. All options are passed in the optional field of each function.
Expand Down Expand Up @@ -36,7 +36,7 @@ client.SearchTitles("inception")
- Country : Use a country code for the specific request (uses client's country by default).
- LangCode : Use a language code for the specific request (uses client's LangCode by default).

### Fetch Movie {#getmovie}
### Get Title
You can fetch a title by it's id or it's url. Justwatch ids are only used internally unlike imdb that exclusively use this to identify titles.

#### By ID
Expand All @@ -60,7 +60,7 @@ client.GetTitleFromURL("https://www.justwatch.com/us/movie/inception")
- Country : Use a country code for the specific request (uses client's country by default).
- LangCode : Use a language code for the specific request (uses client's LangCode by default).

### Get Offers {#getoffers}
### Get Title Offers
Use this function to get offers for a title using it's justwatch id. We'll use [tm820952](https://www.justwatch.com/us/movie/inception) for this example.
```go
client.GetTitleOffers("tm820952")
Expand Down
3 changes: 1 addition & 2 deletions omdb/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ The omdb package is an api wrapper for omdbapi.com.
- [Setup](#setup)
- [Search](#search)
- [Fetch Movie](#getmovie)
- [Fetch Title Offers](#getoffers)

## Guide
Here's a short guide of the available methods and it's usage. All options are passed in the optional field of each function.
Expand Down Expand Up @@ -35,7 +34,7 @@ client.Search("inception")
- Year : Year of release of the movie.
- Page : Results page to return.

### Fetch Movie {#getmovie}
### GetMovie
You can fetch a movie by it's imdb id or it's exact title. Either ID or Title field must be set in request options.
```go
opts := omdb.GetMovieOpts{
Expand Down

0 comments on commit 33be770

Please sign in to comment.