// <auto-generated/>
// ReSharper disable All

namespace MyTelegram.Schema.Messages;

///<summary>
/// Report a secret chat for spam
/// <para>Possible errors</para>
/// Code Type Description
/// 400 CHAT_ID_INVALID The provided chat id is invalid.
/// See <a href="https://corefork.telegram.org/method/messages.reportEncryptedSpam" />
///</summary>
[TlObject(0x4b0c8c0f)]
public sealed class RequestReportEncryptedSpam : IRequest<IBool>
{
    public uint ConstructorId => 0x4b0c8c0f;
    ///<summary>
    /// The secret chat to report
    /// See <a href="https://corefork.telegram.org/type/InputEncryptedChat" />
    ///</summary>
    public MyTelegram.Schema.IInputEncryptedChat Peer { get; set; }

    public void ComputeFlag()
    {

    }

    public void Serialize(IBufferWriter<byte> writer)
    {
        ComputeFlag();
        writer.Write(ConstructorId);
        writer.Write(Peer);
    }

    public void Deserialize(ref ReadOnlyMemory<byte> buffer)
    {
        Peer = buffer.Read<MyTelegram.Schema.IInputEncryptedChat>();
    }
}
