| 1234567891011121314151617181920212223 |
- using Web.Api.Common;
- using MediatR;
- namespace Web.Api.Endpoints.Donation;
- /// <summary>채널의 활성 크루 세션 + 크루원 조회 (시청자용, 인증 불필요)</summary>
- internal sealed class CrewActiveForChannel : IEndpoint
- {
- public void MapEndpoint(IEndpointRouteBuilder app)
- {
- /// identifier: @handle 또는 YouTube Channel ID (SID)
- app.MapGet("api/donation/crew/active/{identifier}", async (
- string identifier,
- ISender sender,
- CancellationToken ct
- ) => {
- var data = await sender.Send(new Application.Features.Api.Crew.GetActiveCrewForChannel.Query(identifier), ct);
- return ApiResponse.Ok(data);
- })
- .WithTags("Donation")
- .AllowAnonymous();
- }
- }
|