GatewayActivity

https://discord.com/developers/docs/topics/gateway-events#activity-object-activity-structure

Signature

export interface GatewayActivity

Properties

id: string;

The activity's id

@unstable
name: string;

The activity's name

type: ActivityType;

Activity type See https://discord.com/developers/docs/topics/gateway-events#activity-object-activity-types

url?: string | null;

Stream url, is validated when type is `1`

created_at: number;

Unix timestamp of when the activity was added to the user's session

sync_id?: string;

The Spotify song id

@unstable
platform?: string;

The platform this activity is being done on

@unstableYou can use {@link ActivityPlatform } as a stepping stone, but this might be inaccurate
details?: string | null;

What the player is currently doing

state?: string | null;

The user's current party status, or the text used for a custom status

emoji?: GatewayActivityEmoji;

The emoji used for a custom status See https://discord.com/developers/docs/topics/gateway-events#activity-object-activity-emoji

party?: GatewayActivityParty;

Information for the current party of the player See https://discord.com/developers/docs/topics/gateway-events#activity-object-activity-party

assets?: GatewayActivityAssets;

Images for the presence and their hover texts See https://discord.com/developers/docs/topics/gateway-events#activity-object-activity-assets

secrets?: GatewayActivitySecrets;

Secrets for Rich Presence joining and spectating See https://discord.com/developers/docs/topics/gateway-events#activity-object-activity-secrets

instance?: boolean;

Whether or not the activity is an instanced game session

flags?: ActivityFlags;

Activity flags `OR`d together, describes what the payload includes See https://discord.com/developers/docs/topics/gateway-events#activity-object-activity-flags See https://en.wikipedia.org/wiki/Bit_field