protected override async Task <object> OnPerform() { var content = new StringContent(JsonConvert.SerializeObject(_saleSummaryContract), Encoding.UTF8, ApplicationJSON); var response = await _restClient.SaleSummary(content, _kickBackAmount); var data = await response.Content.ReadAsStringAsync(); switch (response.StatusCode) { case HttpStatusCode.OK: var saleSummary = new DeSerializer().MapCheckoutSummary(data); return(new Mapper().MapCheckoutSummary(saleSummary)); default: return(await HandleExceptions(response)); } }