PortalEazeApiService constructor
PortalEazeApiService()
Implementation
PortalEazeApiService() {
client = Dio();
clientToken = Dio();
cancelToken = CancelToken();
client.options = BaseOptions(
baseUrl: "http://103.182.72.242:8089/api/",
// baseUrl: "https://eaze-dev.onbilling.id/api/",
connectTimeout: const Duration(seconds: 30),
receiveTimeout: const Duration(seconds: 60),
sendTimeout: const Duration(seconds: 60),
// contentType: "application/json",
contentType: "text/plain",
);
clientToken.options = BaseOptions(
baseUrl: "http://103.182.72.242:8089/api/",
// baseUrl: "https://eaze-dev.onbilling.id/api/",
connectTimeout: const Duration(seconds: 30),
receiveTimeout: const Duration(seconds: 60),
sendTimeout: const Duration(seconds: 60),
// contentType: "application/json",
// contentType: "text/plain",
);
client.interceptors.add(apiInterceptor);
clientToken.interceptors.add(apiInterceptorToken);
}