Download index.html from Filimon1/my-space: direct link, hf CLI and curl.
- Browser
- Download file 22.4 kB
-
https://huggingface.co/spaces/Filimon1/my-space/resolve/main/index.html
- Command line
-
hf download hf://spaces/Filimon1/my-space/index.html
-
curl -L -o index.html https://huggingface.co/spaces/Filimon1/my-space/resolve/main/index.html
22.4 kB
| <html lang="en"> | |
| <head> | |
| <meta charset="UTF-8"> | |
| <meta name="viewport" content="width=device-width, initial-scale=1.0"> | |
| <title>Binance Auto Trading Bot</title> | |
| <script src="https://cdn.tailwindcss.com"></script> | |
| <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css"> | |
| <style> | |
| .gradient-bg { | |
| background: linear-gradient(135deg, #1e3a8a 0%, #1e40af 100%); | |
| } | |
| .card-hover:hover { | |
| transform: translateY(-5px); | |
| box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04); | |
| } | |
| .switch { | |
| position: relative; | |
| display: inline-block; | |
| width: 60px; | |
| height: 34px; | |
| } | |
| .switch input { | |
| opacity: 0; | |
| width: 0; | |
| height: 0; | |
| } | |
| .slider { | |
| position: absolute; | |
| cursor: pointer; | |
| top: 0; | |
| left: 0; | |
| right: 0; | |
| bottom: 0; | |
| background-color: #ccc; | |
| transition: .4s; | |
| border-radius: 34px; | |
| } | |
| .slider:before { | |
| position: absolute; | |
| content: ""; | |
| height: 26px; | |
| width: 26px; | |
| left: 4px; | |
| bottom: 4px; | |
| background-color: white; | |
| transition: .4s; | |
| border-radius: 50%; | |
| } | |
| input:checked + .slider { | |
| background-color: #10b981; | |
| } | |
| input:checked + .slider:before { | |
| transform: translateX(26px); | |
| } | |
| .tradingview-widget-container { | |
| height: 400px; | |
| width: 100%; | |
| } | |
| </style> | |
| </head> | |
| <body class="bg-gray-100 font-sans"> | |
| <div class="min-h-screen"> | |
| <!-- Header --> | |
| <header class="gradient-bg text-white shadow-lg"> | |
| <div class="container mx-auto px-4 py-6"> | |
| <div class="flex justify-between items-center"> | |
| <div class="flex items-center space-x-2"> | |
| <i class="fas fa-robot text-2xl"></i> | |
| <h1 class="text-2xl font-bold">Binance Auto Trading Bot</h1> | |
| </div> | |
| <div class="flex items-center space-x-4"> | |
| <div class="flex items-center"> | |
| <span class="mr-2">Connected</span> | |
| <div class="w-3 h-3 rounded-full bg-green-500"></div> | |
| </div> | |
| <button class="bg-blue-600 hover:bg-blue-700 px-4 py-2 rounded-lg flex items-center"> | |
| <i class="fas fa-user-circle mr-2"></i> | |
| Account | |
| </button> | |
| </div> | |
| </div> | |
| </div> | |
| </header> | |
| <!-- Main Content --> | |
| <main class="container mx-auto px-4 py-8"> | |
| <div class="grid grid-cols-1 lg:grid-cols-3 gap-8"> | |
| <!-- Left Column --> | |
| <div class="lg:col-span-2 space-y-6"> | |
| <!-- Bot Control Panel --> | |
| <div class="bg-white rounded-xl shadow-md p-6 transition duration-300 card-hover"> | |
| <div class="flex justify-between items-center mb-6"> | |
| <h2 class="text-xl font-semibold text-gray-800">Bot Control Panel</h2> | |
| <div class="flex items-center"> | |
| <span class="mr-2 text-gray-600">Status:</span> | |
| <label class="switch"> | |
| <input type="checkbox" id="botToggle" checked> | |
| <span class="slider"></span> | |
| </label> | |
| </div> | |
| </div> | |
| <div class="grid grid-cols-1 md:grid-cols-2 gap-6"> | |
| <div> | |
| <h3 class="text-lg font-medium text-gray-700 mb-3">Trading Pairs</h3> | |
| <div class="space-y-2"> | |
| <div class="flex items-center"> | |
| <input type="checkbox" id="dogeusdc" class="mr-2" checked> | |
| <label for="dogeusdc">DOGE/USDC</label> | |
| </div> | |
| <div class="flex items-center"> | |
| <input type="checkbox" id="xrpusdc" class="mr-2" checked> | |
| <label for="xrpusdc">XRP/USDC</label> | |
| </div> | |
| <div class="flex items-center"> | |
| <input type="checkbox" id="shibusdc" class="mr-2" checked> | |
| <label for="shibusdc">SHIB/USDC</label> | |
| </div> | |
| </div> | |
| </div> | |
| <div> | |
| <h3 class="text-lg font-medium text-gray-700 mb-3">Timeframes</h3> | |
| <div class="space-y-2"> | |
| <div class="flex items-center"> | |
| <input type="radio" id="15m" name="timeframe" class="mr-2" checked> | |
| <label for="15m">15 Minutes</label> | |
| </div> | |
| <div class="flex items-center"> | |
| <input type="radio" id="30m" name="timeframe" class="mr-2"> | |
| <label for="30m">30 Minutes</label> | |
| </div> | |
| <div class="flex items-center"> | |
| <input type="radio" id="1h" name="timeframe" class="mr-2"> | |
| <label for="1h">1 Hour</label> | |
| </div> | |
| </div> | |
| </div> | |
| </div> | |
| <div class="mt-6"> | |
| <h3 class="text-lg font-medium text-gray-700 mb-3">Investment Settings</h3> | |
| <div class="flex items-center"> | |
| <span class="mr-2 text-gray-600">Amount per trade:</span> | |
| <div class="relative"> | |
| <input type="number" id="investmentAmount" value="0.5" step="0.1" min="0.1" class="w-24 pl-3 pr-8 py-2 border border-gray-300 rounded-lg"> | |
| <span class="absolute right-3 top-2.5 text-gray-500">USDC</span> | |
| </div> | |
| </div> | |
| </div> | |
| <div class="mt-6"> | |
| <h3 class="text-lg font-medium text-gray-700 mb-3">Strategy Settings (RSI)</h3> | |
| <div class="grid grid-cols-1 md:grid-cols-2 gap-4"> | |
| <div> | |
| <label for="rsiPeriod" class="block text-sm font-medium text-gray-600 mb-1">RSI Period</label> | |
| <input type="number" id="rsiPeriod" value="14" min="1" max="30" class="w-full px-3 py-2 border border-gray-300 rounded-lg"> | |
| </div> | |
| <div> | |
| <label for="overbought" class="block text-sm font-medium text-gray-600 mb-1">Overbought Level</label> | |
| <input type="number" id="overbought" value="70" min="50" max="90" class="w-full px-3 py-2 border border-gray-300 rounded-lg"> | |
| </div> | |
| <div> | |
| <label for="oversold" class="block text-sm font-medium text-gray-600 mb-1">Oversold Level</label> | |
| <input type="number" id="oversold" value="30" min="10" max="50" class="w-full px-3 py-2 border border-gray-300 rounded-lg"> | |
| </div> | |
| </div> | |
| </div> | |
| <div class="mt-6 flex justify-end space-x-4"> | |
| <button id="saveSettings" class="bg-blue-600 hover:bg-blue-700 text-white px-6 py-2 rounded-lg flex items-center"> | |
| <i class="fas fa-save mr-2"></i> | |
| Save Settings | |
| </button> | |
| <button id="startBot" class="bg-green-600 hover:bg-green-700 text-white px-6 py-2 rounded-lg flex items-center"> | |
| <i class="fas fa-play mr-2"></i> | |
| Start Bot | |
| </button> | |
| <button id="stopBot" class="bg-red-600 hover:bg-red-700 text-white px-6 py-2 rounded-lg flex items-center"> | |
| <i class="fas fa-stop mr-2"></i> | |
| Stop Bot | |
| </button> | |
| </div> | |
| </div> | |
| <!-- Trading View Chart --> | |
| <div class="bg-white rounded-xl shadow-md p-6 transition duration-300 card-hover"> | |
| <h2 class="text-xl font-semibold text-gray-800 mb-4">Market Analysis</h2> | |
| <div class="tradingview-widget-container"> | |
| <div id="tradingview-chart" class="h-full"></div> | |
| </div> | |
| </div> | |
| </div> | |
| <!-- Right Column --> | |
| <div class="space-y-6"> | |
| <!-- API Connection --> | |
| <div class="bg-white rounded-xl shadow-md p-6 transition duration-300 card-hover"> | |
| <h2 class="text-xl font-semibold text-gray-800 mb-4">Binance API Connection</h2> | |
| <div class="space-y-4"> | |
| <div> | |
| <label for="apiKey" class="block text-sm font-medium text-gray-600 mb-1">API Key</label> | |
| <input type="text" id="apiKey" placeholder="Enter your Binance API key" class="w-full px-3 py-2 border border-gray-300 rounded-lg"> | |
| </div> | |
| <div> | |
| <label for="apiSecret" class="block text-sm font-medium text-gray-600 mb-1">API Secret</label> | |
| <input type="password" id="apiSecret" placeholder="Enter your Binance API secret" class="w-full px-3 py-2 border border-gray-300 rounded-lg"> | |
| </div> | |
| <button id="connectAPI" class="w-full bg-blue-600 hover:bg-blue-700 text-white px-4 py-2 rounded-lg flex items-center justify-center"> | |
| <i class="fas fa-plug mr-2"></i> | |
| Connect to Binance | |
| </button> | |
| </div> | |
| </div> | |
| <!-- Trading Activity --> | |
| <div class="bg-white rounded-xl shadow-md p-6 transition duration-300 card-hover"> | |
| <h2 class="text-xl font-semibold text-gray-800 mb-4">Trading Activity</h2> | |
| <div class="space-y-4"> | |
| <div class="flex justify-between items-center"> | |
| <span class="text-gray-600">Total Trades Today</span> | |
| <span class="font-medium">12</span> | |
| </div> | |
| <div class="flex justify-between items-center"> | |
| <span class="text-gray-600">Successful Trades</span> | |
| <span class="font-medium text-green-600">9 (75%)</span> | |
| </div> | |
| <div class="flex justify-between items-center"> | |
| <span class="text-gray-600">Unsuccessful Trades</span> | |
| <span class="font-medium text-red-600">3 (25%)</span> | |
| </div> | |
| <div class="flex justify-between items-center"> | |
| <span class="text-gray-600">Total Profit</span> | |
| <span class="font-medium text-green-600">+4.27 USDC</span> | |
| </div> | |
| </div> | |
| </div> | |
| <!-- Recent Trades --> | |
| <div class="bg-white rounded-xl shadow-md p-6 transition duration-300 card-hover"> | |
| <h2 class="text-xl font-semibold text-gray-800 mb-4">Recent Trades</h2> | |
| <div class="overflow-y-auto max-h-96"> | |
| <table class="min-w-full divide-y divide-gray-200"> | |
| <thead class="bg-gray-50"> | |
| <tr> | |
| <th class="px-4 py-2 text-left text-xs font-medium text-gray-500 uppercase tracking-wider">Pair</th> | |
| <th class="px-4 py-2 text-left text-xs font-medium text-gray-500 uppercase tracking-wider">Type</th> | |
| <th class="px-4 py-2 text-left text-xs font-medium text-gray-500 uppercase tracking-wider">Result</th> | |
| </tr> | |
| </thead> | |
| <tbody class="bg-white divide-y divide-gray-200"> | |
| <tr> | |
| <td class="px-4 py-2 whitespace-nowrap text-sm text-gray-900">DOGE/USDC</td> | |
| <td class="px-4 py-2 whitespace-nowrap text-sm text-gray-900">Buy</td> | |
| <td class="px-4 py-2 whitespace-nowrap text-sm text-green-600">+0.42 USDC</td> | |
| </tr> | |
| <tr> | |
| <td class="px-4 py-2 whitespace-nowrap text-sm text-gray-900">XRP/USDC</td> | |
| <td class="px-4 py-2 whitespace-nowrap text-sm text-gray-900">Sell</td> | |
| <td class="px-4 py-2 whitespace-nowrap text-sm text-red-600">-0.15 USDC</td> | |
| </tr> | |
| <tr> | |
| <td class="px-4 py-2 whitespace-nowrap text-sm text-gray-900">SHIB/USDC</td> | |
| <td class="px-4 py-2 whitespace-nowrap text-sm text-gray-900">Buy</td> | |
| <td class="px-4 py-2 whitespace-nowrap text-sm text-green-600">+0.38 USDC</td> | |
| </tr> | |
| <tr> | |
| <td class="px-4 py-2 whitespace-nowrap text-sm text-gray-900">DOGE/USDC</td> | |
| <td class="px-4 py-2 whitespace-nowrap text-sm text-gray-900">Sell</td> | |
| <td class="px-4 py-2 whitespace-nowrap text-sm text-green-600">+0.51 USDC</td> | |
| </tr> | |
| <tr> | |
| <td class="px-4 py-2 whitespace-nowrap text-sm text-gray-900">XRP/USDC</td> | |
| <td class="px-4 py-2 whitespace-nowrap text-sm text-gray-900">Buy</td> | |
| <td class="px-4 py-2 whitespace-nowrap text-sm text-green-600">+0.27 USDC</td> | |
| </tr> | |
| </tbody> | |
| </table> | |
| </div> | |
| </div> | |
| </div> | |
| </div> | |
| </main> | |
| </div> | |
| <!-- TradingView Widget Script --> | |
| <script type="text/javascript" src="https://s3.tradingview.com/tv.js"></script> | |
| <script> | |
| // Initialize TradingView Widget | |
| new TradingView.widget({ | |
| "autosize": true, | |
| "symbol": "BINANCE:DOGEUSDC", | |
| "interval": "15", | |
| "timezone": "Etc/UTC", | |
| "theme": "light", | |
| "style": "1", | |
| "locale": "en", | |
| "toolbar_bg": "#f1f3f6", | |
| "enable_publishing": false, | |
| "hide_top_toolbar": false, | |
| "hide_side_toolbar": false, | |
| "allow_symbol_change": true, | |
| "container_id": "tradingview-chart" | |
| }); | |
| // Bot Control Logic | |
| document.addEventListener('DOMContentLoaded', function() { | |
| const botToggle = document.getElementById('botToggle'); | |
| const startBot = document.getElementById('startBot'); | |
| const stopBot = document.getElementById('stopBot'); | |
| const saveSettings = document.getElementById('saveSettings'); | |
| const connectAPI = document.getElementById('connectAPI'); | |
| // Bot status | |
| let isBotRunning = true; | |
| // Toggle bot status | |
| botToggle.addEventListener('change', function() { | |
| isBotRunning = this.checked; | |
| updateBotStatus(); | |
| }); | |
| // Start bot button | |
| startBot.addEventListener('click', function() { | |
| isBotRunning = true; | |
| botToggle.checked = true; | |
| updateBotStatus(); | |
| showNotification('Bot started successfully', 'success'); | |
| }); | |
| // Stop bot button | |
| stopBot.addEventListener('click', function() { | |
| isBotRunning = false; | |
| botToggle.checked = false; | |
| updateBotStatus(); | |
| showNotification('Bot stopped successfully', 'warning'); | |
| }); | |
| // Save settings | |
| saveSettings.addEventListener('click', function() { | |
| const pairs = []; | |
| if (document.getElementById('dogeusdc').checked) pairs.push('DOGE/USDC'); | |
| if (document.getElementById('xrpusdc').checked) pairs.push('XRP/USDC'); | |
| if (document.getElementById('shibusdc').checked) pairs.push('SHIB/USDC'); | |
| let timeframe = '15m'; | |
| if (document.getElementById('30m').checked) timeframe = '30m'; | |
| if (document.getElementById('1h').checked) timeframe = '1h'; | |
| const investmentAmount = document.getElementById('investmentAmount').value; | |
| const rsiPeriod = document.getElementById('rsiPeriod').value; | |
| const overbought = document.getElementById('overbought').value; | |
| const oversold = document.getElementById('oversold').value; | |
| // In a real app, you would save these to localStorage or send to server | |
| console.log('Settings saved:', { | |
| pairs, | |
| timeframe, | |
| investmentAmount, | |
| rsiPeriod, | |
| overbought, | |
| oversold | |
| }); | |
| showNotification('Settings saved successfully', 'success'); | |
| }); | |
| // Connect to Binance API | |
| connectAPI.addEventListener('click', function() { | |
| const apiKey = document.getElementById('apiKey').value; | |
| const apiSecret = document.getElementById('apiSecret').value; | |
| if (!apiKey || !apiSecret) { | |
| showNotification('Please enter both API Key and Secret', 'error'); | |
| return; | |
| } | |
| // In a real app, you would validate the API keys | |
| showNotification('Successfully connected to Binance API', 'success'); | |
| }); | |
| // Update bot status UI | |
| function updateBotStatus() { | |
| if (isBotRunning) { | |
| startBot.classList.add('bg-green-600', 'hover:bg-green-700'); | |
| startBot.classList.remove('bg-gray-400', 'hover:bg-gray-500'); | |
| stopBot.classList.add('bg-gray-400', 'hover:bg-gray-500'); | |
| stopBot.classList.remove('bg-red-600', 'hover:bg-red-700'); | |
| } else { | |
| startBot.classList.add('bg-gray-400', 'hover:bg-gray-500'); | |
| startBot.classList.remove('bg-green-600', 'hover:bg-green-700'); | |
| stopBot.classList.add('bg-red-600', 'hover:bg-red-700'); | |
| stopBot.classList.remove('bg-gray-400', 'hover:bg-gray-500'); | |
| } | |
| } | |
| // Show notification | |
| function showNotification(message, type) { | |
| // In a real app, you would show a proper notification | |
| alert(`${type.toUpperCase()}: ${message}`); | |
| } | |
| // Initialize | |
| updateBotStatus(); | |
| }); | |
| </script> | |
| <p style="border-radius: 8px; text-align: center; font-size: 12px; color: #fff; margin-top: 16px;position: fixed; left: 8px; bottom: 8px; z-index: 10; background: rgba(0, 0, 0, 0.8); padding: 4px 8px;">Made with <img src="https://enzostvs-deepsite.hf.space/logo.svg" alt="DeepSite Logo" style="width: 16px; height: 16px; vertical-align: middle;display:inline-block;margin-right:3px;filter:brightness(0) invert(1);"><a href="https://enzostvs-deepsite.hf.space" style="color: #fff;text-decoration: underline;" target="_blank" >DeepSite</a> - 🧬 <a href="https://enzostvs-deepsite.hf.space?remix=Filimon1/my-space" style="color: #fff;text-decoration: underline;" target="_blank" >Remix</a></p></body> | |
| </html> |