Skip to main content

Python wrapper for http://fortnitetracker.com/ api.

Project description

Build Status PyPI version Requirements Status

fortnite-python

Python wrapper for http://fortnitetracker.com/ api.

Installation

You can install it via pip

pip install fortnite-python

Usage

You need to register for an api key at https://fortnitetracker.com/site-api

Then it's just easy as:

from fortnite_python import Fortnite

fortnite = Fortnite('Given api key')

Retrieving a player:

>>> from fortnite_python import Fortnite

>>> fortnite = Fortnite('Given api key')
>>> player = fortnite.player('playername')
player

<Player 20a8fafaa-6chfj-6455-b715-2424fff pc>

The default platform is PC, if you want to use a diferent platform you should do it this way:

>>> from fortnite_python import Fortnite
>>> from fortnite_python.domain import Platform

>>> fortnite = Fortnite('Given api key')
>>> player = fortnite.player('playername', Platform.XBOX)
>>> player
<Player 20a8fafaa-6chfj-6455-b715-2424fff xb1>


You can check the available platforms here

Retrieving player stats:

>>> from fortnite_python import Fortnite
>>> from fortnite_python.domain import Mode

>>> fortnite = Fortnite('Given api key')
>>> player = fortnite.player('playername')
>>> stats = player.getStats(Mode.DUO)
>>> stats.wins
'10'
>>> stats.top3
'20'

You can check the available modes here

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

fortnite-python-0.2.5.tar.gz (3.3 kB view hashes)

Uploaded Source

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page