Go to file
洛水居室 07977a7738
🎨 Renamed ApiHelperException to SIMNetException due to project renaming
The project was originally initialized as 'ApiHelper', but has since been formally renamed to 'SIMNet'. This commit updates the base exception class name and the associated documentation comment to reflect this change, for consistency.
2023-07-19 20:07:44 +08:00
simnet 🎨 Renamed ApiHelperException to SIMNetException due to project renaming 2023-07-19 20:07:44 +08:00
tests Tests Ignore NeedChallenge Error 2023-06-11 22:19:51 +08:00
.deepsource.toml 🔧 Add tests file patterns in .deepsource.toml 2023-06-09 11:23:58 +08:00
.gitignore 🔧 Add .idea/ to .gitignore 2023-05-08 09:10:56 +08:00
LICENSE 📄 Add license 2023-05-09 12:21:15 +08:00
pyproject.toml 🔖 Bump Version to v0.1.2 2023-07-19 12:44:42 +08:00
README.md 📝 Update docs to mention HSR limited availability on Hoyolab 2023-05-17 09:28:42 +08:00
requirements.dev.txt Update test 2023-05-08 09:21:32 +08:00
requirements.txt 🎉 Initial commit 2023-05-02 01:02:47 +08:00
setup.py Add setup 2023-05-08 11:37:45 +08:00

Semi-Intransient Matrix Network

Modern API wrapper for Genshin Impact & Honkai: Star Rail built on asyncio and pydantic.

Requirements

  • Python 3.9+
  • httpx
  • Pydantic

Example

A very simple example of how simnet would be used:

import asyncio
import simnet

async def main():
    cookies = {} # write your cookies
    player_id = 123456789
    async with simnet.StarRailClient(cookies, player_id=player_id) as client:
        data = await client.get_starrail_user()
        print(f"Player has a total of {data.stats.avatar_num} characters")

asyncio.run(main())

Note that Hoyolab has not implemented Battle Chronicle for Honkai Star Rail yet (as of 05/16/2023). HSR related features will be unavailable for global players. For more details, check issue #24

Credits