battlemetrics-client
v0.3.1
Published
TypeScript client library for the BattleMetrics API
Downloads
7
Maintainers
Readme
battlemetrics-client
TypeScript client library for the BattleMetrics API.
BattleMetrics provides game server monitoring, player tracking, and admin tools for popular games like Rust, Ark, CS2, and more.
⚠️ Note: This is a partial implementation focused on specific BattleMetrics API endpoints. If you need additional endpoints that aren't currently supported, please open an issue or submit a pull request!
The project is designed to be easily extensible, and I'm happy to help guide contributions for new features. Feel free to reach out if you'd like to add support for specific endpoints.
Installation
npm install battlemetrics-clientQuick Start
Set your BattleMetrics API token as an environment variable:
export BATTLEMETRICS_TOKEN="your-api-token-here"Basic usage:
import { getGameList, getGameInfo } from "battlemetrics-client";
// Get all games
const games = await getGameList();
// Get specific game info
const arkInfo = await getGameInfo("ark");Documentation
📖 Full Usage Guide - Comprehensive examples and API reference for all implemented resources.
API Reference
For full API documentation, see the BattleMetrics API docs.
Authentication
Get your API token from BattleMetrics.
Features
- Full TypeScript support
- BattleMetrics API coverage
- Modern ES modules
- Comprehensive error handling
Development
# Install dependencies
npm install
# Run tests
npm test
# Run linting
npm run lint
# Build project
npm run buildContributing
This project welcomes contributions! If you'd like to add support for additional BattleMetrics API endpoints or improve existing functionality, please:
- Check the existing issues to see if your feature is already being worked on
- Open an issue to discuss the proposed changes
- Submit a pull request with your implementation
I'm happy to help guide you through the contribution process and provide assistance with implementation details.
Support
If you find this project helpful, consider supporting me on Ko-fi ☕
License
MIT License. See LICENSE for details.
Created by hizenxyz.
