1
0
mirror of https://github.com/ncblakely/GiantsTools synced 2024-06-26 16:11:44 +02:00
GiantsTools/Giants.WebApi/Controllers/CommunityController.cs

31 lines
772 B
C#
Raw Normal View History

2020-08-16 11:03:10 +02:00
namespace Giants.WebApi.Controllers
{
using Giants.DataContract.V1;
using Giants.Services;
using Microsoft.AspNetCore.Mvc;
[ApiController]
2020-10-12 23:42:44 +02:00
[ApiVersion("1.0")]
2020-08-16 11:03:10 +02:00
[Route("api/[controller]")]
public class CommunityController : ControllerBase
2020-08-16 11:03:10 +02:00
{
private readonly ICommunityService discordService;
2020-08-16 11:03:10 +02:00
public CommunityController(
ICommunityService communityService)
2020-08-16 11:03:10 +02:00
{
this.discordService = communityService;
2020-08-16 11:03:10 +02:00
}
[HttpGet]
public CommunityStatus GetDiscordStatus()
2020-08-16 11:03:10 +02:00
{
return new CommunityStatus
2020-08-16 11:03:10 +02:00
{
CommunityAppName = "Discord",
CommunityAppUri = this.discordService.GetDiscordUri()
2020-08-16 11:03:10 +02:00
};
}
}
}