Skip to main content

Battlemetrics API wrapper.

Project description

Battlemetrics API Wrapper

This repository allows users to quickly and easily pull data from the Battlemetrics API. Removing a lot of the guesswork when reading the API.

Alternatives

Javascript

For the javascript equivalent, visit this repository: https://github.com/cubiquitous/battlemetrics-js

Disclaimer

Please note that I am an individual member of the community and not affiliated with Battlemetrics. The resources provided here are developed to facilitate the usage of the Battlemetrics API but come with no official endorsement or sponsorship from Battlemetrics.

It's important to understand that any actions you take using these resources are solely your responsibility. I am not liable for any damage or consequences that may occur to your server or account. Please exercise caution and ensure that you follow best practices when using the API.

Getting Started

To begin using the Battlemetrics API, make sure you have RCON access and an API token. If you don't have an API token yet, you can obtain one by visiting the Battlemetrics developers page.

Installation

  1. Clone or Install this repo:

    Clone this repository

    git clone https://github.com/Gnomeslayer/battlemetrics.git
    

    Pip install

    pip install battlemetrics
    
  2. Install the required dependencies

    or you can do:

    pip install -r requirements.txt
    
  3. Import the Battlemetrics class into your project.

    from battlemetrics import Battlemetrics
    

Usage

Refer to example file for examples. Here's an example of how to use the Battlemetrics API wrapper:

# Instantiate the API wrapper with your token
bmapi = battlemetrics("Your token here")

# Retrieve player information
player = asyncio.run(bmapi.player.search(12345))

# Print the player information
print(player)

Make sure to replace "Your API token here" with your actual API token obtained from the Battlemetrics developers page.

Resources

For more details on the Battlemetrics API and its capabilities, refer to the official Battlemetrics API.

Contributing

If you find any issues or have suggestions for improvement, please feel free to submit a pull request or open an issue in the issue tracker. I welcome contributions from the community!

Contact

You can contact me on Discord, simply add me: gnomeslayer or, you can join the official Battlemetrics discord and @gnomeslayer there.

Suport

This repository will ALWAYS be free and hopefully regularly updated, but if you want to support me, you can do so Here

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

battlemetrics-1.0.13.tar.gz (22.3 kB view details)

Uploaded Source

Built Distribution

battlemetrics-1.0.13-py3-none-any.whl (27.6 kB view details)

Uploaded Python 3

File details

Details for the file battlemetrics-1.0.13.tar.gz.

File metadata

  • Download URL: battlemetrics-1.0.13.tar.gz
  • Upload date:
  • Size: 22.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.12.5

File hashes

Hashes for battlemetrics-1.0.13.tar.gz
Algorithm Hash digest
SHA256 a644c6a724874d5d1c6e5b5a3bc2feaf0a1f244963bf6bba21e8ff12a48af5a6
MD5 5449b9b897905d52c2c35646554884de
BLAKE2b-256 ad81e7283bc7220ead5b5c2844830e8663a95b26283586e18fab135dcc87a0d3

See more details on using hashes here.

File details

Details for the file battlemetrics-1.0.13-py3-none-any.whl.

File metadata

File hashes

Hashes for battlemetrics-1.0.13-py3-none-any.whl
Algorithm Hash digest
SHA256 9b796d4de060e442aa584b3fc6c9ab4d9916bd3d6f1db97489168a8242468d1a
MD5 3f9f12d9e55b592bac9590603ac9deac
BLAKE2b-256 0c37763f3eb7df88af6e7331cd605e4713e584d9c385e6631c1d9bf0b61112ce

See more details on using hashes here.

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