refit
refit copied to clipboard
Composing multiple interfaces for one API.
Hello I'm using refit with the httpclientfactory, I'm wondering if it's possible to use interface composition instead of putting all endpoints in a single file.
public interface IGithubApi {
IAccountService Account { get; }
IRepositoryService Repository { get; }
....
}
public interface IAccountService {
[Get("/account")]
Task<string> MyEndpoint();
}
This discussion describe what I need, but it has been closed. Thank you