1
0
mirror of https://github.com/ppy/osu.git synced 2024-11-18 06:52:55 +08:00
osu-lazer/osu.Game/Online/API/Requests/ChatAckRequest.cs

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

29 lines
927 B
C#
Raw Normal View History

2022-10-27 13:55:24 +08:00
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
// See the LICENCE file in the repository root for full licence text.
using System.Net.Http;
using osu.Framework.IO.Network;
using osu.Game.Online.API.Requests.Responses;
namespace osu.Game.Online.API.Requests
{
public class ChatAckRequest : APIRequest<ChatAckResponse>
{
public long? SinceMessageId;
2022-11-02 16:13:14 +08:00
public uint? SinceSilenceId;
2022-10-27 13:55:24 +08:00
protected override WebRequest CreateWebRequest()
{
var req = base.CreateWebRequest();
req.Method = HttpMethod.Post;
if (SinceMessageId != null)
req.AddParameter(@"since", SinceMessageId.ToString());
2022-11-02 16:13:14 +08:00
if (SinceSilenceId != null)
req.AddParameter(@"history_since", SinceSilenceId.Value.ToString());
2022-10-27 13:55:24 +08:00
return req;
}
protected override string Target => "chat/ack";
}
}