#[non_exhaustive]pub struct PartialIntegration {Show 17 fields
pub id: IntegrationId,
pub name: Option<CompactString>,
pub kind: Option<IntegrationType>,
pub enabled: bool,
pub syncing: bool,
pub role_id: Option<RoleId>,
pub enable_emoticons: bool,
pub expire_behavior: Option<IntegrationExpireBehavior>,
pub expire_grace_period: Option<u32>,
pub user: Option<Box<User>>,
pub account: Option<IntegrationAccount>,
pub synced_at: Option<Timestamp>,
pub subscriber_count: Option<u32>,
pub revoked: bool,
pub application: Option<Box<IntegrationApplication>>,
pub application_id: Option<ApplicationId>,
pub scopes: Vec<Scope>,
}Expand description
A partial Integration, as listed on a user’s
Connection and in an AuditLog
(D-051).
Discord does not document which fields are present; only the ID is required here.
discord.js counterpart: the integrations of APIConnection (discord-api-types).
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.id: IntegrationIdThe integration’s ID.
name: Option<CompactString>The integration’s name.
kind: Option<IntegrationType>The kind of integration.
enabled: boolWhether the integration is enabled.
syncing: boolWhether the integration is syncing.
role_id: Option<RoleId>The role given to subscribers.
enable_emoticons: boolWhether emoticons are synced (Twitch only).
expire_behavior: Option<IntegrationExpireBehavior>What happens to expired subscribers.
expire_grace_period: Option<u32>The grace period before subscribers expire, in days.
user: Option<Box<User>>The user who added the integration.
account: Option<IntegrationAccount>The integration’s account.
synced_at: Option<Timestamp>When the integration last synced.
subscriber_count: Option<u32>The number of subscribers.
revoked: boolWhether the integration was revoked.
application: Option<Box<IntegrationApplication>>The bot or OAuth2 application of a Discord integration.
application_id: Option<ApplicationId>The ID of the integration’s application (audit log integrations; shown in the docs’ audit log example but not in the integration table).
scopes: Vec<Scope>The scopes the application was authorized for.