From f4fa4b4b8dd4b23d22105b979f6c4f0431254b47 Mon Sep 17 00:00:00 2001 From: almostSouji Date: Sat, 12 Aug 2023 09:56:59 +0200 Subject: [PATCH] feat(Presence): Expose sync_id in Activity --- packages/discord.js/src/structures/Presence.js | 7 +++++++ packages/discord.js/typings/index.d.ts | 1 + 2 files changed, 8 insertions(+) diff --git a/packages/discord.js/src/structures/Presence.js b/packages/discord.js/src/structures/Presence.js index 79ecb2918b3b7..817cbc75beae8 100644 --- a/packages/discord.js/src/structures/Presence.js +++ b/packages/discord.js/src/structures/Presence.js @@ -216,6 +216,13 @@ class Activity { */ this.party = data.party ?? null; + /** + * The sync id of the activity + * This represents the track id in spotify activities. + * @type {?string} + */ + this.syncId = data.sync_id ?? null; + /** * Assets for rich presence * @type {?RichPresenceAssets} diff --git a/packages/discord.js/typings/index.d.ts b/packages/discord.js/typings/index.d.ts index 78503e17ebe35..dad5fe933c83c 100644 --- a/packages/discord.js/typings/index.d.ts +++ b/packages/discord.js/typings/index.d.ts @@ -264,6 +264,7 @@ export class Activity { size: [number, number]; } | null; public state: string | null; + public syncId: string | null; public timestamps: { start: Date | null; end: Date | null;