Please note that this is an advanced topic about how to point Awesome Miner to custom URL's for loading specific coin properties.

This feature can be used to load one of the following coin properties from a custom source:

  • Difficulty
  • Block Reward
  • Exchange rate

The configuration can be access via the Coin Properties dialog for a coin on the Coins tab. Enable "Dynamic update" for one of the supported properties.

Configuration

The following properties can be configured for a dynamic data source:

  • Provider
    This can either be set to Custom, where any URL can be used to load data, or to use the latest coin data from any of the coin statistics providers. If one of the coin statistics providers are selected, it must also be enabled globally in the Options dialog, Statistics Providers section.
  • URL
    Specify the URL from where Awesome Miner should load the coin data
  • HTTP method
    Should be set to GET in most cases, unless the data source explicitly requires a POST request.
  • POST Body
    Only required if the HTTP method is set to POST and the data source requires specific data to be included in the body of the HTTP request.
  • Add authorization header
    Only required if the HTTP server requires a username and password. Often required when connecting to coin wallet software.
    • Username
    • Password
  • JSON property expression
    Enter the name of the property where the value to load is located. Leave empty if the source data is a plain value and not a JSON response. Use the Test button to see the data response from the provider to find out the JSON structure. See also the examples below for how the expressions are used to find data in the JSON responses.
    In case a JSON property contains white spaces, use the following syntax: topPropertyName['property with space']
  • Arithmetic expression
    This field should only be used if the value from the data source needs to be modified. Example of expressions, where the first increases the value by 20% and the second divide the value by 1000:
    • * 1.2
    • / 1000

This field can also be used to convert a coin exchange rate from a currency other than BTC to BTC.

  • * helper.ExchangeFrom("ETH")

Examples

Load Litecoin difficulty from WhatToMine

  • Provider: WhatToMine
  • JSON property expression: coins.Litecoin.difficulty

Example of JSON response:

{
  "coins": {
    "Litecoin": {
      "id": 4,
      "tag": "LTC",
      "algorithm": "Scrypt",
      "block_time": "145.0",
      "difficulty": 9440866.436,
      "difficulty24": 9440866.43599998,
      ...
    },
    ...
  }
}


Load Litecoin difficulty from CoinCalculators

  • Provider: CoinCalculators
  • JSON property expression: [?(@.name=='Litecoin')].currentDifficulty

The data format for CoinCalculators doesn't have any property names for each coin, instead the expression must search all elements and find the one where the 'name' property is 'Litecoin'.

Example of JSON response:

[
  {
    "name": "Litecoin"
    "algorithm": "Scrypt",
    "difficulty24": 9440866.436,
    "difficulty6": 9440866.436,
    "difficulty3": 9440866.4360000025,
    "currentDifficulty": 9440866.436,
    ...
  },
  ...
]


Load Litecoin difficulty from CoinToMine

  • Provider: CoinToMine
  • JSON property expression: LTC.mining_difficulty

Example of JSON response:

{
  "LTC": {
    "id": 788,
    "name": "Litecoin",
    "ticker": "LTC",
    "mining_difficulty": "9440722.2171429",
    "mining_difficulty_avg15m": "9440722.2763636",
    "mining_difficulty_avg24h": "9440722.291482",
    ...
  },
  ...
}


Load BitCash difficulty from Block Explorer API (plain text data source)

Leave the field for 'JSON property expression' empty, as this data source returns a plain value

Example of response

867.8971270836576


Load Zcash difficulty from Block Explorer API

Example of JSON response:

{
  "accounts":3100239,
  "blockHash":"000000000186491615c385b890f9d4cd7b8c39162c998af5d142530abf3c949a",
  "blockNumber":504232,
  "difficulty":49867487.45665546,
  "hashrate":2643270531,
  ...
}


Load coin difficulty from local wallet software via JSON-RPC API

  • Provider: Custom
  • URL: http://localhost:9998
  • HTTP method: POST
  • POST body: {"jsonrpc": "1.0", "id":"curltest", "method": "getinfo", "params": [] }
  • Add authorization header: Checked (required by most wallet software)
  • Username: (enter the configured username)
  • Password: (enter the configured password)
  • JSON property expression: result.difficulty

Example of JSON response:

{
  "result": {
    "version": 1000101,
    "protocolversion": 70209,
    "walletversion": 61000,
    "balance": 0.0,
    "privatesend_balance": 0.0,
    "blocks": 379818,
    "difficulty": 9.4412448944448641,
    "testnet": false,
    ...
}


Load the latest exchange rate for Litecoin from Crex24:

The data format is an array of recent trades, where the first element is the most recent. Use '[0]' to get the first element of the array.

Example of JSON response:

[
  {
    "price": 0.01486,
    "volume": 0.02,
    "side": "sell",
    "timestamp": "2019-03-21T10:30:53Z"
  },
  {
    "price": 0.014886,
    "volume": 0.0347,
    "side": "sell",
    "timestamp": "2019-03-21T10:22:02Z"
  },
  ...
]


Load the latest exchange rate for Litecoin from Coingecko, using Binance as source for market rate: