🔍 Průzkum Bitfinex Historical Rates API

📡 Test Bitfinex veřejných API pro historické rates

💰 Testování pro USD

🧪 Test: Funding History - fUSD

URL: https://api-pub.bitfinex.com/v2/funding/fUSD/hist?limit=50

❌ Chyba (HTTP 404)

<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>Error</title>
</head>
<body>
<pre>Cannot GET /api/v2/funding/fUSD/hist</pre>
</body>
</html>

🧪 Test: Stats Funding Average - fUSD

URL: https://api-pub.bitfinex.com/v2/stats1/funding.avg:1h:fUSD/hist?limit=24

✅ Úspěch (HTTP 200)

⚠️ Nevalidní JSON nebo prázdný response

[]

🧪 Test: Funding Candles - fUSD

URL: https://api-pub.bitfinex.com/v2/candles/funding:fUSD:hist?limit=24

❌ Chyba (HTTP 404)

<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>Error</title>
</head>
<body>
<pre>Cannot GET /api/v2/candles/funding:fUSD:hist</pre>
</body>
</html>

🧪 Test: Alternative Stats - fUSD

URL: https://api-pub.bitfinex.com/v2/stats1/funding.size:1h:fUSD/hist?limit=24

✅ Úspěch (HTTP 200)

Počet záznamů: 24

📊 Ukázka prvních 3 záznamů:

IndexHodnotyInterpretace
0[1794895200000,6457964045.660527]Čas: 2026-11-17 06:00:00, Rate: 6457964045.6605
1[1794891600000,6452606684.837175]Čas: 2026-11-17 05:00:00, Rate: 6452606684.8372
2[1794888000000,6451894115.797505]Čas: 2026-11-17 04:00:00, Rate: 6451894115.7975

💰 Testování pro BTC

🧪 Test: Funding History - fBTC

URL: https://api-pub.bitfinex.com/v2/funding/fBTC/hist?limit=50

❌ Chyba (HTTP 404)

<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>Error</title>
</head>
<body>
<pre>Cannot GET /api/v2/funding/fBTC/hist</pre>
</body>
</html>

🧪 Test: Stats Funding Average - fBTC

URL: https://api-pub.bitfinex.com/v2/stats1/funding.avg:1h:fBTC/hist?limit=24

✅ Úspěch (HTTP 200)

⚠️ Nevalidní JSON nebo prázdný response

[]

🧪 Test: Funding Candles - fBTC

URL: https://api-pub.bitfinex.com/v2/candles/funding:fBTC:hist?limit=24

❌ Chyba (HTTP 404)

<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>Error</title>
</head>
<body>
<pre>Cannot GET /api/v2/candles/funding:fBTC:hist</pre>
</body>
</html>

🧪 Test: Alternative Stats - fBTC

URL: https://api-pub.bitfinex.com/v2/stats1/funding.size:1h:fBTC/hist?limit=24

✅ Úspěch (HTTP 200)

Počet záznamů: 24

📊 Ukázka prvních 3 záznamů:

IndexHodnotyInterpretace
0[1794895200000,894.38910935]Čas: 2026-11-17 06:00:00, Rate: 894.38910935
1[1794891600000,894.23890957]Čas: 2026-11-17 05:00:00, Rate: 894.23890957
2[1794888000000,894.34275276]Čas: 2026-11-17 04:00:00, Rate: 894.34275276

💰 Testování pro EUR

🧪 Test: Funding History - fEUR

URL: https://api-pub.bitfinex.com/v2/funding/fEUR/hist?limit=50

❌ Chyba (HTTP 404)

<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>Error</title>
</head>
<body>
<pre>Cannot GET /api/v2/funding/fEUR/hist</pre>
</body>
</html>

🧪 Test: Stats Funding Average - fEUR

URL: https://api-pub.bitfinex.com/v2/stats1/funding.avg:1h:fEUR/hist?limit=24

✅ Úspěch (HTTP 200)

⚠️ Nevalidní JSON nebo prázdný response

[]

🧪 Test: Funding Candles - fEUR

URL: https://api-pub.bitfinex.com/v2/candles/funding:fEUR:hist?limit=24

❌ Chyba (HTTP 404)

<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>Error</title>
</head>
<body>
<pre>Cannot GET /api/v2/candles/funding:fEUR:hist</pre>
</body>
</html>

🧪 Test: Alternative Stats - fEUR

URL: https://api-pub.bitfinex.com/v2/stats1/funding.size:1h:fEUR/hist?limit=24

✅ Úspěch (HTTP 200)

Počet záznamů: 24

📊 Ukázka prvních 3 záznamů:

IndexHodnotyInterpretace
0[1794895200000,6162061.38187124]Čas: 2026-11-17 06:00:00, Rate: 6162061.3818712
1[1794891600000,6160585.74910157]Čas: 2026-11-17 05:00:00, Rate: 6160585.7491016
2[1794888000000,6161161.46879824]Čas: 2026-11-17 04:00:00, Rate: 6161161.4687982

🎯 Závěry a doporučení

Na základě testů výše identifikuji nejlepší API endpoint pro historické funding rates.

📋 Možné endpointy:

🔧 Implementace do botu

Pokud některý endpoint funguje, můžeme:

  1. Nahradit lokální historii rates_24h.json
  2. Získávat aktuální historické rates přímo z Bitfinex
  3. Mít skutečné max rates za 1h, 24h, 72h, 168h

⚡ Výhody API přístupu