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

namespace MyTelegram.Schema;

///<summary>
/// URL button
/// See <a href="https://corefork.telegram.org/constructor/keyboardButtonUrl" />
///</summary>
[TlObject(0x258aff05)]
public sealed class TKeyboardButtonUrl : IKeyboardButton
{
    public uint ConstructorId => 0x258aff05;
    ///<summary>
    /// Button label
    ///</summary>
    public string Text { get; set; }

    ///<summary>
    /// URL
    ///</summary>
    public string Url { get; set; }

    public void ComputeFlag()
    {

    }

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

    public void Deserialize(ref ReadOnlyMemory<byte> buffer)
    {
        Text = buffer.ReadString();
        Url = buffer.ReadString();
    }
}