Bitminter shuts down mining 2020-07-01 and website 2021-06-01

API


For software developers we offer this API for pulling data off of BitMinter. Please refrain from making requests more often than necessary. Abusive clients will be blocked.

The API has two sections. Pool data is publically accessible while user data requires an API key.

Most data is JSON formatted. General information on JSON is available at json.org.

Third party wrappers/libraries


Instead of accessing the API directly you may want to use one of the available libraries, made by third parties:


Advertisements





 

Pool data


System-wide data is available at the following locations:

  • /api/pool/stats - general pool statistics

    An object with the following attributes:

    hash_rate The pool's hash rate in Ghps
    active_workers The number of currently active workers
    active_users The number of currently active users
  • /api/pool/hashrate - pool hash rate in Ghps

    The pool hash rate (Ghps) as a plain number.

  • /api/pool/workers - active workers

    The number of active workers as a plain number.

  • /api/pool/users - active users

    The number of active users as a plain number.

  • /api/pool/round - status of current rounds

    An object with the following attributes:

    hash_rate The pool's hash rate in Ghps
    active_workers The number of currently active workers
    active_users The number of currently active users
    shift_accepted The number of accepted shares in the current shift
    shift_rejected The number of rejected shares in the current shift
    shift_duration The number of seconds spent on the current shift
    shift_score The total score so far
    chains An object mapping chains/cointypes to their round data

    Each chain is an object with the following attributes:

    accepted The number of accepted proofs of work
    rejected The number of rejected proofs of work
    duration Round duration in seconds
    difficulty The current difficulty of this chain
  • /api/pool/blocks - latest blocks

    Optional parameters:

    max Max entries to return, 1 to 50 allowed. Default 10.
    offset Skip this many entries, used to access older data. Default 0.
    commodity Return only this commodity, example 'BTC'. Default all.

    Example with parameters: /api/pool/blocks?commodity=BTC&max=20 - 20 latest BTC blocks

    Returned is an array of objects with the following attributes:

    id Block ID unique within BitMinter
    chain The chain/cointype
    hash The hash of the block header
    height The height aka. block number
    difficulty The difficulty at the time this block was generated
    income Total income, minted coins + transaction fees
    accepted The number of accepted proofs of work
    rejected The number of rejected proofs of work
    status One of the following:
    processing - block was just created
    unconfirmed - recent block, still lacking confirmations
    stale - never made the blockchain (stale work)
    orphan - was on the blockchain but was later orphaned
    confirmed - confirmed and paid out block
    confirmations_left Confirmations left, -1 if stale/orphaned, 0 if confirmed
    generator The name of the user who generated this block
    generated The time the block was generated, in number of seconds since epoch
    duration Time spent on this block, in seconds
  • /api/pool/shifts - latest shifts

    Optional parameters:

    max Max entries to return, 1 to 50 allowed. Default 10.
    offset Skip this many entries, used to access older data. Default 0.

    Example with parameters: /api/pool/shifts?max=20 - 20 latest shifts

    Returned is an array of objects with the following attributes:

    id Shift ID unique within BitMinter
    difficulty The difficulty at the time this shift was completed
    accepted The number of accepted proofs of work
    rejected The number of rejected proofs of work
    score Total score of the shift
    completed The time the shift was completed, in number of seconds since epoch
    duration Time spent on this shift, in seconds
  • /api/pool/top50 - top 50 fastest users

    An object mapping 50 user names to hash rates in Mhps.

User data


In the following URLs USERNAME should be replaced with the name of the user whose information you are seeking.

To access this part of the API you need an API key that must be passed along with the request. There are three ways to do this:

  • In HTTP header, Authorization: key=APIKEY (simple)
  • In HTTP header, Authorization: Basic BASE64 (browser compatible, BASE64 is base64 encoding of key:APIKEY)
  • In URL, https://bitminter.com/api/users/USERNAME?key=APIKEY (not recommended, gets exposed in logfiles)

Make sure you use https (SSL/TLS) to secure the data and key from eavesdropping. Most secure is https with the key in the Authorization header. Least secure is http with the key in the URL.

User-specific data is available at the following locations:

  • /api/users/USERNAME - summary of workers and account balances (of named user)
    /api/users - summary of workers and account balances (of API key owner)

    Requires API key with access to "Balance and worker summary"

    An object with the following attributes:

    name The user name
    active_workers Number of currently active workers
    hash_rate Current hash rate in Mhps (all workers)
    now Server time, in number of seconds since epoch
    round_start An object mapping commodity name (BTC, NMC) to round start time, in number of seconds since epoch
    shift Current shift (see below)
    balances An object mapping commodity name (BTC, NMC) to balance
    workers An array of objects, one per worker (see below)

    Shift is an object with the following attributes:

    start Shift start time, in number of seconds since epoch
    accepted Proofs of work accepted in the current shift
    rejected Proofs of work rejected in the current shift
    user_score Score in the current shift (user only)
    total_score Score in the current shift (pool total)

    Each worker is an object with the following attributes:

    name The worker's name
    hash_rate Current hash rate in Mhps
    last_work Last time a proof of work was sent in, in number of seconds since epoch
    alive True if proof of work received in the last 5 minutes, otherwise false
    work An object mapping commodity name (BTC, NMC) to work data (see below)

    Work data for each commodity is an object with the following attributes:

    total_accepted Number of accepted proofs of work (all time)
    total_rejected Number of rejected proofs of work (all time)
    round_accepted No longer used (always zero)
    round_rejected No longer used (always zero)
    checkpoint_accepted Number of accepted proofs of work (before last reset/checkpoint)
    checkpoint_rejected Number of rejected proofs of work (before last reset/checkpoint)