Skip to main content

A typed, handwrited and powerful spacetraders API wrapper

Project description

astrotraders

A typed, handwrited and powerful library for spacetraders.io game.

SpaceTraders is an API-based game where you acquire and manage a fleet of ships to explore, trade, and fight your way across the galaxy.

This client based on HTTPX and Pydantic.

Install

pip install astrotraders

Usage

Currently, you can use API wrapper which represented by AstroTradersClient class:

from astrotraders import AstroTradersClient
client = AstroTradersClient.set_up(
    "token_here",
)

After initializing client you can use API resources, for example:

agent = client.agents.info()
systems = client.systems.list()
contracts = client.contracts.list()
factions = client.factions.list()
# you can use undocumented endpoints!
stats = client.server.stats()
universe = client.systems.all()

TODO

  1. "Game objects" with data caching and more pythonic usage
  2. CLI tool for manage fleet (and as example)

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

astrotraders-1.0.2.tar.gz (17.3 kB view hashes)

Uploaded Source

Built Distribution

astrotraders-1.0.2-py3-none-any.whl (21.1 kB view hashes)

Uploaded Python 3

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