public async Task <ActionResult <WithdrawalSetupRespObj> > GetAllWithdrawalSetupAsync() { try { var response = await _repo.GetAllWithdrawalSetupAsync(); return(new WithdrawalSetupRespObj { WithdrawalSetups = _mapper.Map <List <WithdrawalSetupObj> >(response), }); } catch (Exception ex) { var errorCode = ErrorID.Generate(5); return(new WithdrawalSetupRespObj { Status = new APIResponseStatus { IsSuccessful = false, Message = new APIResponseMessage { FriendlyMessage = "Error Occurred", TechnicalMessage = ex?.Message, MessageId = errorCode } } }); } }