Client

Client

new Client(key)

The client for interacting with the Fortnite Tracker API
Source:
Parameters:
Name Type Description
key string Fortnite Tracker API token

Methods

get(username, platformopt, rawopt) → {Promise.<Account>|Promise.<Object>}

Get user info
Source:
Parameters:
Name Type Attributes Default Description
username string username of the user to search for
platform string <optional>
'pc' platform to search for user in (pc, xbl, or psn)
raw boolean <optional>
false whether to return raw response from API
Returns:
Type:
Promise.<Account> | Promise.<Object>

getChallenges(rawopt) → {Promise.<Challenges>|Promise.<Object>}

Get currently weekly challenges
Source:
Parameters:
Name Type Attributes Default Description
raw boolean <optional>
false whether to return raw response from API
Returns:
Type:
Promise.<Challenges> | Promise.<Object>

getMatches(accountId, rawopt) → {Promise.<Array.<Match>>|Promise.<Array.<Object>>}

Get user's matches
Source:
Parameters:
Name Type Attributes Default Description
accountId string user's account ID found in user info
raw boolean <optional>
false whether to return raw response from API
Returns:
Type:
Promise.<Array.<Match>> | Promise.<Array.<Object>>

getStore(rawopt) → {Promise.<Array.<StoreItem>>|Promise.<Array.<Object>>}

Get current store items
Source:
Parameters:
Name Type Attributes Default Description
raw boolean <optional>
false whether to return raw response from API
Returns:
Type:
Promise.<Array.<StoreItem>> | Promise.<Array.<Object>>