आवश्यकताएँ

Python 3.8+, websockets पुस्तकालय (pip install websockets), और API टोकन वाला Deriv खाता।

चरण 1: API टोकन प्राप्त करें

अपने Deriv खाते में Settings → API Token खोलें। trading अनुमतियों के साथ एक टोकन बनाएँ।

चरण 2: बुनियादी connection

Deriv WebSocket से जुड़ें और अपने टोकन से अधिकृत करें:

import asyncio
import json
import websockets

API_URL = "wss://ws.derivws.com/websockets/v3?app_id=1089"

async def connect():
    async with websockets.connect(API_URL) as ws:
        # authorize
        await ws.send(json.dumps({
            "authorize": "AAPKA_API_TOKEN"
        }))
        resp = await ws.recv()
        print(json.loads(resp))

asyncio.run(connect())

चरण 3: ट्रेड खोलें

अधिकृत होने के बाद, आप एक contract खोल सकते हैं (जैसे R_100 पर 5 मिनट के लिए CALL):

async def buy_contract(ws):
    await ws.send(json.dumps({
        "buy": 1,
        "price": 10,
        "parameters": {
            "contract_type": "CALL",
            "symbol": "R_100",
            "duration": 5,
            "duration_unit": "m",
            "basis": "stake",
            "amount": 1,
            "currency": "USD"
        }
    }))

पूर्ण दस्तावेज़ api.deriv.com पर है। बॉट के बारे में अधिक जानकारी के लिए, ट्रेडिंग बॉट कैसे बनाएँ पर हमारी गाइड पढ़ें।

⚠️ महत्वपूर्ण

असली पैसे का उपयोग करने से पहले हमेशा डेमो खाते पर परीक्षण करें। अपने बॉट में जोखिम प्रबंधन शामिल करें: दैनिक stop loss और trade सीमा।

⚠️ जोखिम चेतावनी

binary options ट्रेडिंग में भारी जोखिम है। अधिकांश ट्रेडर पैसा गंवाते हैं। इस साइट में ऐफिलिएट लिंक हैं।