Giter Site home page Giter Site logo

cndrd / siegeapi Goto Github PK

View Code? Open in Web Editor NEW
47.0 2.0 2.0 224 KB

Rainbow Six Siege Python API Interface

Home Page: https://cndrd.github.io/siegeapi/

License: MIT License

Python 100.00%
rainbow-six-siege api python interface python3 ubisoft ubisoft-api r6 r6s

siegeapi's Introduction

siegeapi


How to install

pip install siegeapi

Quick example

from siegeapi import Auth
import asyncio

async def sample():
    auth = Auth(UBISOFT_EMAIL, UBISOFT_PASSW)
    player = await auth.get_player(name="CNDRD")

    print(f"Name: {player.name}")
    print(f"Profile pic URL: {player.profile_pic_url}")

    await player.load_persona()
    print(f"Streamer nickname: {player.persona.nickname}")
    print(f"Nickname enabled: {player.persona.enabled}")

    await player.load_playtime()
    print(f"Total Time Played: {player.total_time_played:,} seconds / {player.total_time_played_hours:,} hours")
    print(f"Level: {player.level}")

    await player.load_ranked_v2()
    print(f"Ranked Points: {player.ranked_profile.rank_points}")
    print(f"Rank: {player.ranked_profile.rank}")
    print(f"Max Rank Points: {player.ranked_profile.max_rank_points}")
    print(f"Max Rank: {player.ranked_profile.max_rank}")

    await player.load_progress()
    print(f"XP: {player.xp:,}")
    print(f"Total XP: {player.total_xp:,}")
    print(f"XP to level up: {player.xp_to_level_up:,}")

    await auth.close()

asyncio.run(sample())

Output

Name: CNDRD
Profile pic URL: https://ubisoft-avatars.akamaized.net/7e0f63df-a39b-44c5-8de0-d39a05926e77/default_256_256.png
Streamer nickname: d1kCheeze
Nickname enabled: True
Total Time Played: 9,265,890 seconds / 2,573 hours
Level: 308
Ranked Points: 3919
Rank: Emerald 1
Max Rank Points: 3933
Max Rank: Emerald 1
XP: 124,375
Total XP: 21,238,875
XP to level up: 20,625

Siege Inventory

If you want to see every skin, headgear, uniform and more, head over to skins.cndrd.xyz

Docs

For docs go to cndrd.github.io/siegeapi

Credits

Operator Icons from r6operators by marcopixel & sourced by me straight from the game files
Built (and re-built) on top of what billy-yoyo started

Problems

If you experience any problems, reach out to me, or submit a PR
You can reach out here on GitHub or on Discord (cndrd)

forthebadge
forthebadge

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.