Table of Contents

Class AutoModerationRuleProperties

Namespace
NetCord
Assembly
NetCord.dll
public class AutoModerationRuleProperties
Inheritance
AutoModerationRuleProperties
Inherited Members

Constructors

AutoModerationRuleProperties(string, AutoModerationRuleEventType, AutoModerationRuleTriggerType, IEnumerable<AutoModerationActionProperties>)

public AutoModerationRuleProperties(string name, AutoModerationRuleEventType eventType, AutoModerationRuleTriggerType triggerType, IEnumerable<AutoModerationActionProperties> actions)

Parameters

name string
eventType AutoModerationRuleEventType
triggerType AutoModerationRuleTriggerType
actions IEnumerable<AutoModerationActionProperties>

Properties

Actions

[JsonPropertyName("actions")]
public IEnumerable<AutoModerationActionProperties> Actions { get; set; }

Property Value

IEnumerable<AutoModerationActionProperties>

Enabled

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

Property Value

bool

EventType

[JsonPropertyName("event_type")]
public AutoModerationRuleEventType EventType { get; set; }

Property Value

AutoModerationRuleEventType

ExemptChannels

[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
[JsonPropertyName("exempt_channels")]
public IEnumerable<ulong>? ExemptChannels { get; set; }

Property Value

IEnumerable<ulong>

ExemptRoles

[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
[JsonPropertyName("exempt_roles")]
public IEnumerable<ulong>? ExemptRoles { get; set; }

Property Value

IEnumerable<ulong>

Name

[JsonPropertyName("name")]
public string Name { get; set; }

Property Value

string

TriggerMetadata

[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
[JsonPropertyName("trigger_metadata")]
public AutoModerationRuleTriggerMetadataProperties? TriggerMetadata { get; set; }

Property Value

AutoModerationRuleTriggerMetadataProperties

TriggerType

[JsonPropertyName("trigger_type")]
public AutoModerationRuleTriggerType TriggerType { get; set; }

Property Value

AutoModerationRuleTriggerType

Methods

AddActions(params AutoModerationActionProperties[])

public AutoModerationRuleProperties AddActions(params AutoModerationActionProperties[] actions)

Parameters

actions AutoModerationActionProperties[]

Returns

AutoModerationRuleProperties

AddActions(IEnumerable<AutoModerationActionProperties>)

public AutoModerationRuleProperties AddActions(IEnumerable<AutoModerationActionProperties> actions)

Parameters

actions IEnumerable<AutoModerationActionProperties>

Returns

AutoModerationRuleProperties

AddExemptChannels(IEnumerable<ulong>)

public AutoModerationRuleProperties AddExemptChannels(IEnumerable<ulong> exemptChannels)

Parameters

exemptChannels IEnumerable<ulong>

Returns

AutoModerationRuleProperties

AddExemptChannels(params ulong[])

public AutoModerationRuleProperties AddExemptChannels(params ulong[] exemptChannels)

Parameters

exemptChannels ulong[]

Returns

AutoModerationRuleProperties

AddExemptRoles(IEnumerable<ulong>)

public AutoModerationRuleProperties AddExemptRoles(IEnumerable<ulong> exemptRoles)

Parameters

exemptRoles IEnumerable<ulong>

Returns

AutoModerationRuleProperties

AddExemptRoles(params ulong[])

public AutoModerationRuleProperties AddExemptRoles(params ulong[] exemptRoles)

Parameters

exemptRoles ulong[]

Returns

AutoModerationRuleProperties

WithActions(IEnumerable<AutoModerationActionProperties>)

public AutoModerationRuleProperties WithActions(IEnumerable<AutoModerationActionProperties> actions)

Parameters

actions IEnumerable<AutoModerationActionProperties>

Returns

AutoModerationRuleProperties

WithEnabled(bool)

public AutoModerationRuleProperties WithEnabled(bool enabled = true)

Parameters

enabled bool

Returns

AutoModerationRuleProperties

WithEventType(AutoModerationRuleEventType)

public AutoModerationRuleProperties WithEventType(AutoModerationRuleEventType eventType)

Parameters

eventType AutoModerationRuleEventType

Returns

AutoModerationRuleProperties

WithExemptChannels(IEnumerable<ulong>?)

public AutoModerationRuleProperties WithExemptChannels(IEnumerable<ulong>? exemptChannels)

Parameters

exemptChannels IEnumerable<ulong>

Returns

AutoModerationRuleProperties

WithExemptRoles(IEnumerable<ulong>?)

public AutoModerationRuleProperties WithExemptRoles(IEnumerable<ulong>? exemptRoles)

Parameters

exemptRoles IEnumerable<ulong>

Returns

AutoModerationRuleProperties

WithName(string)

public AutoModerationRuleProperties WithName(string name)

Parameters

name string

Returns

AutoModerationRuleProperties

WithTriggerMetadata(AutoModerationRuleTriggerMetadataProperties?)

public AutoModerationRuleProperties WithTriggerMetadata(AutoModerationRuleTriggerMetadataProperties? triggerMetadata)

Parameters

triggerMetadata AutoModerationRuleTriggerMetadataProperties

Returns

AutoModerationRuleProperties

WithTriggerType(AutoModerationRuleTriggerType)

public AutoModerationRuleProperties WithTriggerType(AutoModerationRuleTriggerType triggerType)

Parameters

triggerType AutoModerationRuleTriggerType

Returns

AutoModerationRuleProperties