public async Task <IActionResult> CreateNewTournament([FromBody] NewTournamentRequest newTournamentRequest) { try { var tournamentId = await _tournamentService.CreateNewTournament(newTournamentRequest); return(Ok(tournamentId)); } catch (MissingSubscriptionException) { return(Unauthorized("A subscription is required for tournament creation")); } }
// POST: api/Tournament public Tournament Post([FromBody] Tournament value) { return(_tournamentService.CreateNewTournament(value)); }