Wrap the API Behind the Repository
Hide Ktor and serialization from callers.
Now Build the Real Thing
With the interface set, you write a concrete implementation that actually fetches data behind the scenes.
Implement the Interface
Create a class that uses implements the repository interface, promising to fulfill every method it declares.
class UserRepositoryImpl : UserRepositoryAll lessons in this course
- Define a Repository Interface
- Wrap the API Behind the Repository
- Map DTOs to Domain Models
- Expose Results as Flow