2024-01-02 19:08:39 +03:30
|
|
|
|
using NetinaShop.Infrastructure.Models;
|
|
|
|
|
|
|
|
|
|
|
|
namespace NetinaShop.Infrastructure.RestServices;
|
|
|
|
|
|
|
|
|
|
|
|
public interface IRestApiWrapper : IScopedDependency
|
|
|
|
|
|
{
|
|
|
|
|
|
IKaveNegarRestApi KaveNegarRestApi { get; }
|
2024-02-12 10:46:18 +03:30
|
|
|
|
IZarinpalRestApi ZarinpalRestApi { get; }
|
2024-02-15 10:39:00 +03:30
|
|
|
|
IDigikalaRestApi DigikalaRestApi { get; }
|
2024-01-02 19:08:39 +03:30
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
public class RestApiWrapper : IRestApiWrapper
|
|
|
|
|
|
{
|
|
|
|
|
|
public IKaveNegarRestApi KaveNegarRestApi => RestService.For<IKaveNegarRestApi>(RestAddress.BaseKaveNegar);
|
2024-02-12 10:46:18 +03:30
|
|
|
|
public IZarinpalRestApi ZarinpalRestApi => RestService.For<IZarinpalRestApi>(RestAddress.BaseZarinpal);
|
2024-02-15 10:39:00 +03:30
|
|
|
|
public IDigikalaRestApi DigikalaRestApi => RestService.For<IDigikalaRestApi>(RestAddress.DigikalaApi);
|
2024-01-02 19:08:39 +03:30
|
|
|
|
}
|