This is a custom integration for NiceHash.
It will enable you to collect:
- Your accounts statistics
- balance
- profitability
- local profitability
- unpaid amount
- Your rigs statistics
- Accepted Hash rate
- Rejected Hash rate
- Profitability
- Local Profitability
All the values which represent a BTC amount generate 2 sensors:
- one in BTC
- one in the currency you selected during the setup (conversion rate if provided by NiceHash)
- Add this repository to HACS as an integration: https://github.com/RomRider/ha_nicehash
- Install the integration
- Restart your instance
- Copy the content of
custom_components/nicehash
into yourcustom_components/nicehash folder
. - Restart your instance
You'll need to create an API key in NiceHash for this integration to work:
-
head over to your NiceHash account settings
-
Go into the API Keys menu
-
In this menu at the top, you'll find your Organisation ID which is required to later setup the integration in Home-Assistant
-
click
CREATE NEW API KEY
-
This will present you with this popup:
-
⚠️ Make sure you configure it like the above picture (DO NOT ENABLE ANY OF THE OTHER SETTINGS, this is at your own risk) -
Click on
GENERATE API KEY
-
This will give you 2 strings, note them down, you can't retrieve them later on:
- The Key
- The Secret
-
Validate the popup and enable the API Key (it will be through email)
Once that is done, head over to Home-Assistant and add the integration from the integration menu:
- Name: Give a name to your integration (it will also be used as part of some sensors)
- Key and Secret: This is the key/secret you retrieved from the API Key creation
- Org ID: This is the Organization ID
- Currency Trigam: This is the trigram of the currency the BTC amount will be converted to (both sensors will exist, BTC and the selected currency)
- You're all set 🎉
It is best to use apexcharts-card (more flexibility) or mini-graph-card (less flexibility) to display the data from those sensors.