public async Task <IActionResult> AddPaymentMethod(ShopPaymentMethodPostRequest model) { try { if (!ModelState.IsValid) { throw new Exception("Petición de alta inválida"); } return(Ok(await _shopService.AddPaymentethodAsync(model, _apiDbContext))); } catch (Exception e) { return(StatusCode(500, e.Message)); } }