So there is no difficulty forecast API available? Seems like an opportunity...
https://alloscomp.com/bitcoin/calculator/json?hashrate=358373688{
"bc_per_block": 25.0,
"coins_before_retarget": 1.1441951795292777e-05,
"coins_per_hour": 1.511201180510367e-07,
"coins_per_hour_after_retarget": 1.2953152975803147e-07,
"difficulty": 49692386354.89384,
"dollars_before_retarget": 0.002765519748922264,
"dollars_per_hour": 3.652573253293557e-05,
"dollars_per_hour_after_retarget": 3.13077707425162e-05,
"exchange_rate": 241.7,
"exchange_rate_source": "preev",
"hashrate": 358373688.0,
"next_difficulty": 57974450747.376144,
"time_per_block": 595552737522.379
}
"next_difficulty": 57974450747.376144alloscomp.com calculation is not good for 4+ days estimation. This is better...
https://bitcoinwisdom.com/bitcoin/difficultyBut, you need to scrape HTML for it^^.