Skip to content

Commit

Permalink
FEATURE: TMDbClient (#180)
Browse files Browse the repository at this point in the history
* AccountService

* Ceritifcations

* Companies

* Configuration

* Discover

* Genres

* Movies

* People

* Search

* Trending

* TVEpisode

* TVSeasons

* TVSeries

* WatchProviders

* Authentication

* Docs

* Documentation

* Fix markdown lint error
  • Loading branch information
adamayoung authored May 22, 2024
1 parent 27ae0ae commit 5968076
Show file tree
Hide file tree
Showing 131 changed files with 2,860 additions and 1,813 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -84,10 +84,10 @@ jobs:
uses: actions/checkout@v4

- name: Build
run: swift build --build-tests -Xswiftc -warnings-as-errors
run: swift build --build-tests -Xswiftc -warnings-as-errors -Xswiftc -strict-concurrency=complete

- name: Test
run: swift test --skip-build --filter TMDbTests
run: swift test --skip-build --filter TMDbTests -Xswiftc -strict-concurrency=complete

- name: Build for Release
run: swift build -c release -Xswiftc -warnings-as-errors
run: swift build -c release -Xswiftc -warnings-as-errors -Xswiftc -strict-concurrency=complete
9 changes: 9 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,15 @@ Add the TMDb package to your Project's Package dependencies.
Create an API key from The Movie Database web site
[https://www.themoviedb.org/documentation/api](https://www.themoviedb.org/documentation/api).

### Quick Start

```swift
let tmdbClient = TMDbClient(apiKey: "<your-tmdb-api-key>")

let moviesToDiscover = try await tmdbClient.discover.movies().results
let fightClub = try await tmdbClient.movies.details(forMovie: 550)
```

## Documentation

Documentation and examples of usage can be found at
Expand Down
2 changes: 1 addition & 1 deletion Sources/TMDb/Domain/APIClient/APIClient.swift
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@

import Foundation

protocol APIClient {
protocol APIClient: Sendable {

func perform<Request: APIRequest>(_ request: Request) async throws -> Request.Response

Expand Down
Loading

0 comments on commit 5968076

Please sign in to comment.