Table of Contents

Class PremiumButtonProperties

Namespace
NetCord.Rest
Assembly
NetCord.dll
public class PremiumButtonProperties : IButtonProperties, IComponentSectionAccessoryProperties
Inheritance
PremiumButtonProperties
Implements
Inherited Members

Constructors

PremiumButtonProperties(ulong)

public PremiumButtonProperties(ulong skuId)

Parameters

skuId ulong

Properties

ComponentType

Type of the component.

[JsonPropertyName("type")]
public ComponentType ComponentType { get; }

Property Value

ComponentType

Disabled

Whether the button is disabled.

[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingDefault)]
[JsonPropertyName("disabled")]
public bool Disabled { get; set; }

Property Value

bool

Id

Unique identifier for the component. Auto populated through increment if not provided.

[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
[JsonPropertyName("id")]
public int? Id { get; set; }

Property Value

int?

SkuId

[JsonPropertyName("sku_id")]
public ulong SkuId { get; set; }

Property Value

ulong

Style

Style of the button.

[JsonPropertyName("style")]
public ButtonStyle Style { get; }

Property Value

ButtonStyle

Methods

WithDisabled(bool)

Whether the button is disabled.

public PremiumButtonProperties WithDisabled(bool disabled = true)

Parameters

disabled bool

Returns

PremiumButtonProperties

WithId(int?)

Unique identifier for the component. Auto populated through increment if not provided.

public PremiumButtonProperties WithId(int? id)

Parameters

id int?

Returns

PremiumButtonProperties

WithSkuId(ulong)

public PremiumButtonProperties WithSkuId(ulong skuId)

Parameters

skuId ulong

Returns

PremiumButtonProperties