OpenMLBB SDK Docs

OpenMLBB Addon Client

Structured SDK docs for Addon endpoints using from OpenMLBB import OpenMLBB.

Every card documents the SDK call from OpenMLBB and mirrors API path/query/body requirements.

GET Win Rate Calculator for Consecutive Wins

/openmlbb/addon/win-rate-calculator

Open Only This

API Path: /api/addon/win-rate-calculator

Calculate the number of consecutive wins required to reach a target win rate based on current matches and current win rate.

Query parameters:

  • match-now: Current total number of matches played (minimum: 0).
  • wr-now: Current win rate in percent (range: 0-100).
  • wr-future: Target win rate in percent. Must be greater than current win rate and between 0-100.

The response includes win rate calculation data:

  • status: Response status (e.g., 'success').
  • match_now: Current total matches played.
  • wr_now: Current win rate.
  • wr_future: Target win rate.
  • required_no_lose_matches: Number of consecutive wins required without losses to reach the target win rate.
  • message: Explanation message summarizing the result.

This endpoint is useful for:

  • Calculating how many consecutive wins are needed to reach a desired win rate.
  • Helping players set realistic performance goals.
  • Providing analytics for win rate progression.

Python Example

from OpenMLBB import OpenMLBB

client = OpenMLBB()
response = client.addon.win_rate_calculator(match_now=100, wr_now=50, wr_future=60)
print(response)

Path and Query Parameters

Name In Type Required Default
match-now query integer yes -
wr-now query number yes -
wr-future query number yes -

GET Check IP address location details

/openmlbb/addon/ip

Open Only This

API Path: /api/addon/ip

Retrieves geographic information associated with a given IP address. No parameters required.

The response includes IP location data:

  • code: Response code (e.g., 0).
  • msg: Status message (e.g., 'ok').
  • data:
      • city: City name (e.g., 'Yogyakarta').
      • state: State or region (e.g., 'Yogyakarta').
      • country: Country code (e.g., 'id').
      • lang: Language code (e.g., 'en').

This endpoint is useful for:

  • Identifying approximate geographic location of an IP address.
  • Supporting analytics and personalization.
  • Performing security checks and contextual validation.

Python Example

from OpenMLBB import OpenMLBB

client = OpenMLBB()
response = client.addon.ip()
print(response)