Added api endpoints and configured hopframe

This commit is contained in:
2025-01-20 18:52:04 +01:00
parent 49b5339bb3
commit 6ba7275e92
16 changed files with 206 additions and 4 deletions

View File

@@ -0,0 +1,16 @@
using Microsoft.AspNetCore.Mvc;
using Portfolio.Shared.Models;
using Portfolio.Shared.Services;
namespace Portfolio.Api.Controller;
[ApiController, Route("api/timeline")]
public class TimelineController(ITimelineRepository repository) : ControllerBase {
[HttpGet("{type}")]
public async Task<IActionResult> GetTimeline(TimelineEntryType type, CancellationToken ct) {
var timeline = await repository.GetTimeline(type, ct);
return Ok(timeline);
}
}