UNPKG

fnbr

Version:

A library to interact with Epic Games' Fortnite HTTP and XMPP services

67 lines (66 loc) 1.72 kB
import Base from '../../Base'; import type { PresencePartyData } from '../../../resources/structs'; import type Client from '../../Client'; import type Party from './Party'; /** * Represents a party received by a friend's presence */ declare class PresenceParty extends Base { /** * Whether this party is private. * NOTE: If this is true, all other properties are undefined */ isPrivate: boolean; /** * The party's ID */ id?: string; /** * The party's member count */ size?: number; /** * The party type ID */ typeId?: number; /** * The party key */ key?: string; /** * The party's app ID */ appId?: string; /** * The party's build ID */ buildId?: string; /** * The party's flags */ flags?: number; /** * The reason why this party doesn't accept new members. * Will be 0 if it does accept new members */ notAcceptingMembersReason?: number; /** * @param client The main client * @param data The presence party's data */ constructor(client: Client, data: PresencePartyData); /** * Joins this presence party * @throws {PartyNotFoundError} The party wasn't found * @throws {PartyPermissionError} The party cannot be fetched (the party is private) * @throws {PartyMaxSizeReachedError} The party has reached its max size */ join(): Promise<void>; /** * Fetches this party * @throws {PartyNotFoundError} The party wasn't found * @throws {PartyPermissionError} The party cannot be fetched (the party is private) */ fetch(): Promise<Party>; } export default PresenceParty;