diff --git a/DisCatSharp/Entities/Integration/DiscordIntegration.cs b/DisCatSharp/Entities/Integration/DiscordIntegration.cs index a3bcaea70..6df36c75d 100644 --- a/DisCatSharp/Entities/Integration/DiscordIntegration.cs +++ b/DisCatSharp/Entities/Integration/DiscordIntegration.cs @@ -1,119 +1,131 @@ // This file is part of the DisCatSharp project, based off DSharpPlus. // // Copyright (c) 2021-2023 AITSYS // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal // in the Software without restriction, including without limitation the rights // to use, copy, modify, merge, publish, distribute, sublicense, and/or sell // copies of the Software, and to permit persons to whom the Software is // furnished to do so, subject to the following conditions: // // The above copyright notice and this permission notice shall be included in all // copies or substantial portions of the Software. // // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR // IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, // FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE // AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, // OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE // SOFTWARE. using System; using DisCatSharp.Enums; using Newtonsoft.Json; namespace DisCatSharp.Entities; /// /// Represents a Discord integration. These appear on the profile as linked 3rd party accounts. /// public class DiscordIntegration : SnowflakeObject { /// /// Gets the integration name. /// [JsonProperty("name", NullValueHandling = NullValueHandling.Ignore)] public string Name { get; internal set; } /// /// Gets the integration type. /// [JsonProperty("type", NullValueHandling = NullValueHandling.Ignore)] public string Type { get; internal set; } /// /// Gets whether this integration is enabled. /// [JsonProperty("enabled", NullValueHandling = NullValueHandling.Ignore)] public bool IsEnabled { get; internal set; } /// /// Gets whether this integration is syncing. /// [JsonProperty("syncing", NullValueHandling = NullValueHandling.Ignore)] public bool IsSyncing { get; internal set; } /// /// Gets ID of the role this integration uses for subscribers. /// [JsonProperty("role_id", NullValueHandling = NullValueHandling.Ignore)] public ulong RoleId { get; internal set; } /// /// Gets the expiration behaviour. /// [JsonProperty("expire_behavior", NullValueHandling = NullValueHandling.Ignore)] public IntegrationExpireBehavior ExpireBehavior { get; internal set; } /// /// Gets the grace period before expiring subscribers. /// [JsonProperty("expire_grace_period", NullValueHandling = NullValueHandling.Ignore)] public int ExpireGracePeriod { get; internal set; } /// /// Gets the user that owns this integration. /// [JsonProperty("user", NullValueHandling = NullValueHandling.Ignore)] public DiscordUser User { get; internal set; } /// /// Gets the 3rd party service account for this integration. /// [JsonProperty("account", NullValueHandling = NullValueHandling.Ignore)] public DiscordIntegrationAccount Account { get; internal set; } /// /// Gets the date and time this integration was last synced. /// [JsonProperty("synced_at", NullValueHandling = NullValueHandling.Ignore)] public DateTimeOffset SyncedAt { get; internal set; } /// /// Gets the subscriber count. /// [JsonProperty("subscriber_count", NullValueHandling = NullValueHandling.Ignore)] public int? SubscriberCount { get; internal set; } /// /// Whether the integration is revoked. /// [JsonProperty("revoked", NullValueHandling = NullValueHandling.Ignore)] public bool? Revoked { get; internal set; } + /// + /// Gets the application this integration is bound to. + /// [JsonProperty("application", NullValueHandling = NullValueHandling.Ignore)] public DiscordApplication Application { get; internal set; } + /// + /// Gets the integration's scopes. + /// [JsonProperty("scopes", NullValueHandling = NullValueHandling.Ignore)] public string[] Scopes { get; internal set; } + /// + /// Gets whether emoticons are enabled. + /// + [JsonProperty("enable_emoticons", NullValueHandling = NullValueHandling.Ignore)] + public bool? EnableEmoticons { get; internal set; } + /// /// Initializes a new instance of the class. /// internal DiscordIntegration() { } }