Skip to main content

Class: Clan

Represents a Clan.

Constructors

constructor

new Clan(client, data)

Parameters

NameType
clientClient
dataAPIClan

Defined in

struct/Clan.ts:99

Properties

name

name: string

Name of the clan.

Defined in

struct/Clan.ts:13


tag

tag: string

Tag of the clan.

Defined in

struct/Clan.ts:16


type

type: "open" | "inviteOnly" | "closed"

The clan's type for accepting members.

Defined in

struct/Clan.ts:19


description

description: string

The clan's description.

Defined in

struct/Clan.ts:22


location

location: null | Location

The location of this clan.

Defined in

struct/Clan.ts:25


chatLanguage

chatLanguage: null | APIChatLanguage

The clan's trophy count.

Defined in

struct/Clan.ts:28


badge

badge: Badge

The clan's Badge.

Defined in

struct/Clan.ts:31


level

level: number

The clan's level.

Defined in

struct/Clan.ts:34


points

points: number

The clan's trophy count.

Defined in

struct/Clan.ts:37


capitalPoints

capitalPoints: number

The clan's capital points.

Defined in

struct/Clan.ts:40


builderBasePoints

builderBasePoints: number

The clan's builder base trophy count.

Defined in

struct/Clan.ts:43


requiredTrophies

requiredTrophies: number

The minimum trophies required to apply to this clan.

Defined in

struct/Clan.ts:46


requiredBuilderBaseTrophies

requiredBuilderBaseTrophies: null | number

The minimum builder base trophies required to apply to this clan.

Defined in

struct/Clan.ts:49


requiredTownHallLevel

requiredTownHallLevel: null | number

The minimum hall level required to apply to this clan.

Defined in

struct/Clan.ts:52


warFrequency

Optional warFrequency: "always" | "moreThanOncePerWeek" | "oncePerWeek" | "lessThanOncePerWeek" | "never" | "unknown"

The frequency for when this clan goes to war.

Defined in

struct/Clan.ts:55


warWinStreak

warWinStreak: number

The clan's current war winning streak.

Defined in

struct/Clan.ts:58


warWins

warWins: number

The number of wars the clan has won.

Defined in

struct/Clan.ts:61


warTies

warTies: null | number

The number of wars the clan has tied.

Defined in

struct/Clan.ts:64


warLosses

warLosses: null | number

The number of wars the clan has lost.

Defined in

struct/Clan.ts:67


isWarLogPublic

isWarLogPublic: boolean

Indicates if the clan has a public war log.

Defined in

struct/Clan.ts:70


warLeague

warLeague: null | APIWarLeague

The clan's CWL league.

Defined in

struct/Clan.ts:73


memberCount

memberCount: number

The number of members in the clan.

Defined in

struct/Clan.ts:76


labels

labels: APILabel[]

An array of Label that the clan has.

Defined in

struct/Clan.ts:79


clanCapital

clanCapital: null | ClanCapital

The clan's Clan Capital information

Defined in

struct/Clan.ts:82


capitalLeague

Optional capitalLeague: APICapitalLeague

The clan's capital league.

Defined in

struct/Clan.ts:85


isFamilyFriendly

isFamilyFriendly: boolean

Whether the clan is family friendly.

Defined in

struct/Clan.ts:88


members

members: ClanMember[]

List of clan members.

  • This property returns empty array for getClans method.

Defined in

struct/Clan.ts:94

Accessors

get shareLink(): string

Get clan's formatted link to open clan in-game.

Returns

string

Defined in

struct/Clan.ts:139

Methods

fetchMembers

fetchMembers(options?): Promise<Player[]>

Get Player info for every Player in the clan.

Parameters

NameType
options?OverrideOptions

Returns

Promise<Player[]>

Defined in

struct/Clan.ts:132