Files
RRAC/RecRoomArchive/Controllers/API/Config/V1/ConfigController.cs
splootybean 387ec7ba89 Initialize repository
Added basic info to get in game for like...August 2016 ;-;
It's not much but it's a start
2026-02-27 00:58:13 -08:00

34 lines
1.3 KiB
C#

using Microsoft.AspNetCore.Mvc;
using RecRoomArchive.Services;
namespace RecRoomArchive.Controllers.API.Config.V1
{
/// <summary>
/// Configs that control Rec Room. These configs include data like Amplitude, MessageOfTheDay, Objectives, etc...
/// </summary>
[Route(template: "api/[controller]/v1")]
[ApiController]
public class ConfigController(MessageOfTheDayService motdService) : ControllerBase
{
/// <summary>
/// Gets the legacy version of the Message of the Day, to display on the Dorm Room bulletin board, or to show on the login screen in pre-Dorm Room versions of the game
/// </summary>
/// <returns>A basic string to display in game, related to the Message of the Day</returns>
[HttpGet(template: "motd")]
public async Task<ActionResult<string>> GetMessageOfTheDay()
{
var messageOfTheDay = await motdService.GetMessageOfTheDay();
return Ok(messageOfTheDay);
}
/// <summary>
/// Returns the current daily objectives to use before config/v2 existed
/// </summary>
/// <returns>A list of objectives</returns>
[HttpGet(template: "objectives")]
public async Task<ActionResult<List<object>>> GetDailyObjectives()
{
return Ok(new List<object>());
}
}
}