Still in early development.
An asynchronous, object-oriented API wrapper for the Epic/Fortnite HTTP services, written in Python.
- Use of the
asyncio
framework to handle many IO-bound tasks concurrently. - Automatic, configurable rate limit handling and caching.
- Optimised for a balance of speed and memory.
Python 3.10 or higher is required. For project dependencies, see requirements.txt.
It is recommended to install the library within a virtual environment instead of the global Python installation.
# Windows
py -m pip install py-epic
# Linux/MacOS
python3 -m pip install py-epic
import asyncio
import pyepic
async def main():
async with pyepic.HTTPClient() as client:
auth_code = input(f'Enter authorization code from {client.user_auth_path} here: ')
async with client.create_auth_session(auth_code) as auth_session:
account = await auth_session.account()
print(f'Logged in as: {account}')
asyncio.run(main())
- The APIs that PyEpic interacts with are not officially documented, nor are they intended to be used outside the official clients.
- The package could experience major breaking changes (or stop working!) at any moment.
- The developer can not take responsibility for any damages that result from using the package.