Skip to main content

An API wrapper for the Helldivers 2 Community and official APIs

Project description

Helldivers 2 Python API Wrapper

PyPI Documentation Status

This is an asyncronous api frontend library for the Helldivers 2 API and many of it's community wrappers.

Get the latest game state from Helldivers 2, and transform the raw data into collated data objects complete with important planet effects, the latest biome and enviornmental hazards, and more.

Still currently in development, expect frequent updates as the static data required by the package to build the collated objects can change in between patches to Helldivers 2.

All returned objects are Pydantic Models, which allow them to be quickly dumped and loaded from/to json strings.

Please note, this API Wrapper was designed to primarily work with the asyncio module.

Requirements:

  • httpx
  • pydantic

This front end supports:

current stable installation

 pip install -U hd2api.py

current latest installation

 pip install -U git+https://github.com/CrosswaveOmega/hd2api.py.git

Basic usage

import asyncio
from hd2api import GetApiRawAll, APIConfig, build_planet_2
async def main():
    apiconfig=APIConfig()
    allval=await GetApiRawAll(apiconfig)
    print(allval.status)
    planet=build_planet_2(64,allval, apiconfig.staticdata())
    print(planet)


asyncio.run(main)

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

hd2api_py-0.0.1.18.8.tar.gz (88.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

hd2api_py-0.0.1.18.8-py3-none-any.whl (111.8 kB view details)

Uploaded Python 3

File details

Details for the file hd2api_py-0.0.1.18.8.tar.gz.

File metadata

  • Download URL: hd2api_py-0.0.1.18.8.tar.gz
  • Upload date:
  • Size: 88.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for hd2api_py-0.0.1.18.8.tar.gz
Algorithm Hash digest
SHA256 0ecd6d5ae995e128acdd744bf8fe3ed74cbe5fab2f8166e8055efe40c73a69b8
MD5 2fc3716daeee53d8b69ccf4216e77083
BLAKE2b-256 11b9afc9413ea18dc8d02b5f528c7b5b9830f3ccd652f3668c54dc23732441d9

See more details on using hashes here.

File details

Details for the file hd2api_py-0.0.1.18.8-py3-none-any.whl.

File metadata

  • Download URL: hd2api_py-0.0.1.18.8-py3-none-any.whl
  • Upload date:
  • Size: 111.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for hd2api_py-0.0.1.18.8-py3-none-any.whl
Algorithm Hash digest
SHA256 b52b9ef421140487ad4e9f884f9db413dca872dfc848ed4eaf959fd1c3cc13d7
MD5 8608486f11125b01f98d60a88e049295
BLAKE2b-256 bf4c730369ec78ab2312947f3b2b609e0f6b46c2428e0cfc3eadd22386f1ee62

See more details on using hashes here.

Supported by

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