feat : 보스 응답 메시지 문제 수정

This commit is contained in:
qornwh1
2026-03-17 09:15:41 +09:00
parent 39ef81d48a
commit f8fa34edbc
3 changed files with 48 additions and 13 deletions

View File

@@ -4,10 +4,39 @@ namespace MMOserver.Api;
// API 응답(BossRaidAccessResponse)을 직접 노출하지 않고 이걸로 매핑해서 반환
public sealed class BossRaidResult
{
public int RoomId { get; init; }
public string SessionName { get; init; } = string.Empty;
public int BossId { get; init; }
public List<string> Players { get; init; } = new();
public string Status { get; init; } = string.Empty;
public string? Tokens { get; init; }
public int RoomId
{
get;
init;
}
public string SessionName
{
get;
init;
} = string.Empty;
public int BossId
{
get;
init;
}
public List<string> Players
{
get;
init;
} = new();
public string Status
{
get;
init;
} = string.Empty;
public Dictionary<string, string> Tokens
{
get;
init;
} = new();
}

View File

@@ -79,7 +79,7 @@ public class RestApi : Singleton<RestApi>
{
try
{
HttpResponseMessage response = await httpClient.PostAsJsonAsync(url, new { usernames = userNames, bossId });
HttpResponseMessage response = await httpClient.PostAsJsonAsync(url, new { usernames = userNames, bossId = bossId });
// 401: API 키 인증 실패
if (response.StatusCode == HttpStatusCode.Unauthorized)
@@ -166,10 +166,10 @@ public class RestApi : Singleton<RestApi>
}
[JsonPropertyName("tokens")]
public string? Tokens
public Dictionary<string, string> Tokens
{
get;
set;
}
} = new();
}
}