Prometheus exporter for chess.com player data

Overview

chess-exporter

Prometheus exporter for chess.com player data implemented via chess.com's published data API and Prometheus Python Client

Example use cases:

Deployment into Kubernetes

Simply deploy the Kubernetes manifests in the manifests folder. Have a look at kustomization.yaml first. Ensure that namespace suits you, and optionally uncomment servicemonitor.yaml.

kubectl apply -k manifests

Available metrics

Metric name description values
chess_rapid_rating_current{playerName="playerName"} Current chess.com rating of player playerName in rapid integer
chess_rapid_wins{playerName="playerName"} Total number of wins of player playerName in rapid integer
chess_rapid_losses{playerName="playerName"} Total number of losses of player playerName in rapid integer
chess_rapid_draws{playerName="playerName"} Total number of draws of player playerName in rapid integer
chess_blitz_rating_current{playerName="playerName"} Current chess.com rating of player playerName in blitz integer
chess_blitz_wins{playerName="playerName"} Total number of wins of player playerName in blitz integer
chess_blitz_losses{playerName="playerName"} Total number of losses of player playerName in blitz integer
chess_blitz_draws{playerName="playerName"} Total number of draws of player playerName in blitz integer
chess_bullet_rating_current{playerName="playerName"} Current chess.com rating of player playerName in bullet integer
chess_bullet_wins{playerName="playerName"} Total number of wins of player playerName in bullet integer
chess_bullet_losses{playerName="playerName"} Total number of losses of player playerName in bullet integer
chess_bullet_draws{playerName="playerName"} Total number of draws of player playerName in bullet integer
chess_online{chess_online="online",playerName="playerName"} online status of player playerName, currently not working 0 or 1
chess_online{chess_online="offline",playerName="playerName"} online status of player playerName, currently not working 0 or 1
chess_online{chess_online="unknown",playerName="playerName"} online status of player playerName, currently not working 0 or 1

Configuration

Chess-exporter is highly configurable via environment variables, and a configuration file.


Inspired by https://trstringer.com/quick-and-easy-prometheus-exporter/

You might also like...
Python: Wrangled and unpivoted gaming datasets. Tableau: created dashboards - Market Beacon and Player’s Shopping Guide.

Created two information products for GameStop. Using Python, wrangled and unpivoted datasets, and created Tableau dashboards.

A Pythonic Data Catalog powered by Ray that brings exabyte-level scalability and fast, ACID-compliant, change-data-capture to your big data workloads.

DeltaCAT DeltaCAT is a Pythonic Data Catalog powered by Ray. Its data storage model allows you to define and manage fast, scalable, ACID-compliant dat

Viewflow is an Airflow-based framework that allows data scientists to create data models without writing Airflow code.
Viewflow is an Airflow-based framework that allows data scientists to create data models without writing Airflow code.

Viewflow Viewflow is a framework built on the top of Airflow that enables data scientists to create materialized views. It allows data scientists to f

resultados (data) de elecciones 2021 y código para extraer data de la ONPE

elecciones-peru-2021-ONPE Resultados (data) de elecciones 2021 y código para extraer data de la ONPE Data Licencia liberal, pero si vas a usarlo por f

An unofficial python API for trading on the DeGiro platform, with the ability to get real time data and historical data.

DegiroAPI An unofficial API for the trading platform Degiro written in Python with the ability to get real time data and historical data for products.

 Improve current data preprocessing for FTM's WOB data to analyze Shell and Dutch Governmental contacts.
Improve current data preprocessing for FTM's WOB data to analyze Shell and Dutch Governmental contacts.

We're the hackathon leftovers, but we are Too Good To Go ;-). A repo by Lukas Schubotz and Raymon van Dinter. We aim to improve current data preprocessing for FTM's WOB data to analyze Shell and Dutch Governmental contacts.

Python for downloading model data (HRRR, RAP, GFS, NBM, etc.) from NOMADS, NOAA's Big Data Program partners (Amazon, Google, Microsoft), and the University of Utah Pando Archive System.
Python for downloading model data (HRRR, RAP, GFS, NBM, etc.) from NOMADS, NOAA's Big Data Program partners (Amazon, Google, Microsoft), and the University of Utah Pando Archive System.

Python for downloading model data (HRRR, RAP, GFS, NBM, etc.) from NOMADS, NOAA's Big Data Program partners (Amazon, Google, Microsoft), and the University of Utah Pando Archive System.

A program made in PYTHON🐍 that automatically performs data insertions into a POSTGRES database 🐘 , using as base a .CSV file 📁 , useful in mass data insertions

A program made in PYTHON🐍 that automatically performs data insertions into a POSTGRES database 🐘 , using as base a .CSV file 📁 , useful in mass data insertions.

Comments
  • Track FIDE ratings

    Track FIDE ratings

    It may be possible to somehow track actual FIDE ratings as well. For example, via curl https://ratings.fide.com/profile/2016192 and extracting the player rating out of the data. This might be a welcome addition to the chess-exporter project.

    opened by MarioUhrik 0
  • Don't auto-assume previous data points are still true

    Don't auto-assume previous data points are still true

    I suspect that when a player drops out of a tracked leaderboard, the exporter keeps publishing potentially incorrect metrics about them, without actually checking with the chess.com API. This may be because there is no "clean-up" mechanism for leaderboard drop outs. If this is true, then it should certainly be fixed, because it's not correct to assume someone's current data based on a past data point.

    Likewise, when chess-exporter fails to fetch new data for any reason (e.g. connection issue), it should probably stop reporting that metric in order not to assume anything.

    This can be up for discussion though.

    opened by MarioUhrik 0
Owner
Mário Uhrík
DevOps Engineer
Mário Uhrík
Prometheus exporter for Spigot accounts

SpigotExporter Prometheus exporter for Spigot accounts What it provides SpigotExporter will output metrics for each of your plugins and a cumulative d

Jacob Bashista 5 Dec 20, 2021
Chess bot can play automatically as white or black on lichess.com, chess.com and any website using drag and drop to move pieces

Chessbot "Why create another chessbot ?" The explanation is simple : I did not find a free bot I liked online : all the bots I saw on internet are par

Dhimas Bagus Prayoga 2 Nov 11, 2021
Notifies server owners of mod updates, also notifies of player deaths and player joins through Discord.

ProjectZomboid-ServerAssistant Notifies server owners of mod updates, also notifies of player deaths and player joins through Discord. A Python based

null 3 Sep 30, 2022
Multitrack exporter for OP-Z

Underbridge for OP-Z Multitrack exporter Description Exports patterns and projects individual audio tracks to seperate folders for use in your DAW. Py

Thomas Herrmann 71 Dec 25, 2022
Provide Prometheus url_sd compatible API Endpoint with data from Netbox

netbox-plugin-prometheus-sd Provide Prometheus http_sd compatible API Endpoint with data from Netbox. HTTP SD is a new feature in Prometheus and not a

Felix Peters 66 Dec 19, 2022
Push Prometheus metrics to VictoriaMetrics or other exporters

Push metrics from your periodic long-running jobs to existing Prometheus/VictoriaMetrics monitoring system.

olegm 14 Nov 4, 2022
A free and open-source chess improvement app that combines the power of Lichess and Anki.

A free and open-source chess improvement app that combines the power of Lichess and Anki. Chessli Project Activity & Issue Tracking PyPI Build & Healt

null 93 Nov 23, 2022
In the works, creating a new Chess Board and way to Play...

sWJz4Chess date started on github.com 11-13-2021 In the works, creating a new Chess Board and way to Play... starting to write this in Pygame, any ind

Shawn 2 Nov 18, 2021
Get the stats of a (or more) Hypixel player(s)

Hypixel_Stats Get the statistics of a (or more) Hypixel player(s) Who needs this? Everyone who plays a lot of Minecraft and often plays on mc.hypixel.

Finnomator 1 Feb 12, 2022
Simple rofi script to choose player for playerctl to execute its command

rofi-playerctl-switcher simple rofi script to choose player for playerctl to execute its command Usage copy playerSwitch.py and playerctl.sh to ~/.con

null 2 Jan 3, 2022