Botunuz zaten Binance USD-M Futures konuşuyorsa, tek bir base URL değiştirin ve BuyCrypt'te canlıya geçin. Kullanıcılarımız botunuzu liderlik tablosunda keşfeder, ücretsiz 1.000$'lık demo hesapta dener ve ikna olduklarında gerçek anahtarlara geçer.
Kod yeniden yazmaya gerek yok. Borsaya özgü tuhaflıklar yok. Aynı HMAC-SHA256 imzalama, aynı WebSocket user-data akışı, aynı emir tipleri — kullanıcıların sermayelerini riske atmadan botları karşılaştırabilmesi için demo trading motorumuzun üzerine sarılmış.
Abone olan her kullanıcı, 1.000$ sanal bakiyeli kendi demo hesabını alır. Botunuz onu işlem yapar. Canlı PnL, düşüşü (drawdown) ve kazanma oranını izlerler. Gerçek sermayelerine risk yok — ve size müşteri edinme maliyeti yok.
Botunuzun kendi demo hesabı, herkese açık liderlik tablosunda 🤖 BOT rozetiyle görünür. Kullanıcılar gerçek trader'lar arasında PnL sıralamasını görür. Satıra dokunup "Bağlan"a basmaları anında abonelik sağlar.
Botunuz herhangi bir Binance Futures SDK'sı kullanıyorsa (binance-connector-python, python-binance, CCXT vb.), base_url'ünü https://api.buycrypt.com/fapi adresine yönlendirin. HMAC, recvWindow, emir tipleri — birebir aynı.
Bir kullanıcı abone olduğunda, yeni oluşturulan API anahtarı + secret'i webhook URL'nize POST ederiz — HMAC imzalı, hata durumunda üstel geri çekilmeyle yeniden denenir, dead-letter üzerinden kurtarılabilir. Kullanıcıdan asla kimlik bilgisi istemenize gerek kalmaz.
Kullanıcı liderlik tablosunu açar. Botunuzun hesabı, kullanıcı adının yanında 🤖 BOT etiketi ve abone sayısıyla görünür. Satıra dokunurlar.
Botun profil sayfasında "Demo hesabına bağlan"ı görürler. Tek dokunuş yeni bir 1.000$ demo hesap oluşturur ve botunuz onun üzerinde işlem yapmaya başlar.
Kullanıcı botun demosunu günlerce veya haftalarca izler. PnL, pozisyonlar, kazanma oranı — hepsi uygulamada canlı. Beğenirlerse, demodan üretime geçmek için BuyCrypt içine gerçek Binance API anahtarlarını girerler.
Kullanıcı gerçek Binance API anahtarını BuyCrypt içine ekler. Demo anahtarını teslim ettiğimiz aynı şekilde webhook'unuza teslim ederiz — aynı subscription.created olayı, sadece üretim kimlik bilgileriyle. Tek bir entegrasyon hem demo hem de canlı akışları kapsar.
Normal bir BuyCrypt hesabı oluşturun — herhangi bir kullanıcıyla aynı akış. Kaydolur kaydolmaz başlangıç bakiyeli ücretsiz bir demo hesap alırsınız. Başvuru formu yok, inceleme kuyruğu yok.
API anahtarlarını doğrudan BuyCrypt mobil uygulaması içinde oluşturun: Profilim → API anahtarları → demo hesabınıza dokunun → Oluştur. Bir kez gösterilen yeni bir apiKey + apiSecret alırsınız — botunuza kopyalayın. Ardından mevcut Binance USD-M Futures botunuzu https://api.buycrypt.com/fapi adresine yönlendirin, hemen çalışır — aynı HMAC, aynı uç noktalar, aynı emir tipleri.
Demonuzda API tabanlı işlem tespit eder etmez, hesabınız otomatik olarak bot olarak işaretlenir. Demonuz liderlik tablosunda 🤖 BOT etiketi ve herkese açık profille görünür, böylece diğer kullanıcılar onu keşfedip abone olabilir.
Abone kabul etmeye hazır olduğunuzda, ayarlarda bot profilinize bir webhook URL'si ekleyin. Bir kullanıcı her abone olduğunda — demoda ya da gerçek Binance anahtarlarıyla — o kullanıcının hesabı için API anahtarı + secret içeren bir subscription.created olayı POST ederiz. (userId, apiKey, apiSecret) bilgisini saklayın ve onlar adına işlem yapmaya başlayın.
Çoğu Binance Futures SDK'sı özel bir base URL kabul eder. İşte tipik bir Python botunun ihtiyaç duyduğu tüm değişiklik:
# before — trading on real Binance from binance.um_futures import UMFutures client = UMFutures(key=API_KEY, secret=API_SECRET) # after — trading on a BuyCrypt user's demo from binance.um_futures import UMFutures client = UMFutures( key=API_KEY, secret=API_SECRET, base_url="https://api.buycrypt.com/fapi", # <- the only line that changes ) # everything below is identical to your existing code client.new_order(symbol="BTCUSDT", side="BUY", type="MARKET", quantity=0.01) client.account() client.cancel_open_orders(symbol="BTCUSDT")
CCXT, python-binance, Go'nun go-binance'ı, JS node-binance-api — hepsi aynı şekilde çalışır. Basit requests.get(...).headers["X-MBX-APIKEY"] = key botları da çalışır; HMAC imzalama kuralı bayt bayt aynıdır.
Bir BuyCrypt kullanıcısı botunuza abone olduğunda, sunucu tarafında kullanıcı başına bir API anahtarı + secret oluşturur ve bunları kayıtlı webhook URL'nize POST ederiz. Secret hiçbir zaman kullanıcıya geri döndürülmez — yalnızca size, HTTPS üzerinden, imzalı olarak gider.
TL;DR: sign up → tap «Generate API key» on your demo → generate a webhook secret → run one Python script → admin approves. ~5 minutes.
Open buycrypt.com/terminal (or the mobile app). Sign in via Google or phone. A $1,000 USDT demo account is created automatically — that's the sandbox your bot will trade on.
In the app: Profile → API Keys → tap your demo account → «Bot API keys» → Generate. A dialog shows the apiKey + apiSecret once — copy both, you can't recover the secret afterwards.
# what you'll save API_KEY = "3fc370a4ac94b9aa756e2a97842dc04c" API_SECRET = "3WJ86kV_VQzLWaED3hSRlY9R6wQHh_f3UEZ_q-CrwRU"
Same shape as Binance — your existing USD-M Futures bot library reads it as a regular Binance key with base URL https://api.buycrypt.com/fapi.
A second secret, separate from API_SECRET. We use it to sign the events we POST to your webhook URL — so you can verify the request really came from us. You generate it on your side; we encrypt-store it but never reveal back:
# any of these works — pick one. Save the output. $ openssl rand -hex 32 # macOS / Linux $ python3 -c "import secrets; print(secrets.token_hex(32))" # cross-platform # sample output 8a31c2f4d5e6789abc01234567890def8a31c2f4d5e6789abc01234567890def
Drop your three secrets into one signed POST. Save this as register_bot.py and run it once. Works on any OS with Python 3.10+ and pip install requests:
import hmac, hashlib, time, urllib.parse, requests # ─── fill these in from steps 2 and 3 ───────────────────── API_KEY = "3fc370a4ac94b9aa756e2a97842dc04c" API_SECRET = "3WJ86kV_VQzLWaED3hSRlY9R6wQHh_f3UEZ_q-CrwRU" WEBHOOK_SECRET = "8a31c2f4d5e6789abc01234567890def8a31c2f4d5e6789abc01234567890def" SLUG = "alpha-trader" # lowercase, [a-z0-9-], unique DISPLAY_NAME = "Alpha Trader" # shown to users in the bot list WEBHOOK_URL = "https://your-bot.example.com/buycrypt/hook" # MUST be HTTPS, public # ────────────────────────────────────────────────────────── params = { "slug": SLUG, "displayName": DISPLAY_NAME, "webhookUrl": WEBHOOK_URL, "webhookSecret": WEBHOOK_SECRET, "defaultLeverage": 10, "timestamp": int(time.time() * 1000), } qs = urllib.parse.urlencode(params) sig = hmac.new(API_SECRET.encode(), qs.encode(), hashlib.sha256).hexdigest() r = requests.post( "https://api.buycrypt.com/fapi/v1/bot/profiles", headers={ "X-MBX-APIKEY": API_KEY, "Content-Type": "application/x-www-form-urlencoded", }, data=qs + f"&signature={sig}", ) print(r.status_code, r.json())
Notice no demoKeyPairId — your API_KEY already points to the demo it was generated for. Need to register against a different demo? Generate a separate API key for it (step 2 again).
Expected output:
201 {
"botId": 42,
"slug": "alpha-trader",
"status": "PENDING_REVIEW",
"webhookUrl": "https://your-bot.example.com/buycrypt/hook",
"webhookStatus": "ACTIVE",
"webhookSecretAutoGenerated": false
}
Common errors:
{"code":-2010, "msg":"Slug already in use."} # pick another slug
{"code":-1102, "msg":"webhookSecret must be at least 32..."} # too short — use 32+ chars
{"code":-1022, "msg":"Signature for this request is not valid."} # API_SECRET wrong, or params order changed after signing
{"code":-1003, "msg":"Bot registration rate limit: 1 per hour..."} # wait it out
Bot lands in PENDING_REVIEW. Our admin sees your request immediately and approves it. To check status anytime:
import hmac, hashlib, time, urllib.parse, requests API_KEY = "3fc370a4..." API_SECRET = "3WJ86kV..." qs = urllib.parse.urlencode({"timestamp": int(time.time() * 1000)}) sig = hmac.new(API_SECRET.encode(), qs.encode(), hashlib.sha256).hexdigest() r = requests.get( f"https://api.buycrypt.com/fapi/v1/bot/profiles?{qs}&signature={sig}", headers={"X-MBX-APIKEY": API_KEY}, ) print(r.json()) # [{"botId":42, "status":"ACTIVE", ...}] when approved
Once "status":"ACTIVE": every time a user subscribes we POST to your webhookUrl with the per-subscriber API key your bot will trade with. The events shape and a copy-paste signature-verification snippet are right below this section.
Lost your webhook secret? Pick a new one and rotate (same signing pattern as registration):
params = {
"webhookSecret": NEW_SECRET, # or omit to get backend-generated
"timestamp": int(time.time() * 1000),
}
qs = urllib.parse.urlencode(params)
sig = hmac.new(API_SECRET.encode(), qs.encode(), hashlib.sha256).hexdigest()
requests.post(
"https://api.buycrypt.com/fapi/v1/bot/profiles/42/webhook/rotate-secret",
headers={"X-MBX-APIKEY": API_KEY,
"Content-Type": "application/x-www-form-urlencoded"},
data=qs + f"&signature={sig}",
)
Old secret invalid the second the new one saves. Rate limit: 10 rotations/hour per bot.
subscription.created — kullanıcı yeni abone olduPOST https://your-bot.example.com/buycrypt/hook Content-Type: application/json User-Agent: BuyCrypt-Webhook/1.0 X-BuyCrypt-Event: subscription.created X-BuyCrypt-Delivery-Id: 7f3b2e8c-a4d1-4f12-93b8-0c1e9f8d2a4b # dedup key — store + reject duplicates X-BuyCrypt-Timestamp: 1745605200123 # ms epoch when payload was built X-BuyCrypt-Signature: 5e8c2d… # hex(HMAC-SHA256(webhookSecret, ts + "." + body)) { "event": "subscription.created", "deliveryId": "7f3b2e8c-a4d1-4f12-93b8-0c1e9f8d2a4b", "timestamp": 1745605200123, "data": { "subscriptionId": 42, "botProfileId": 7, "subscriberHandle": "user_fb_uid_a", "apiKey": "3fc370a4ac94b9aa756e2a97842dc04c", "apiSecret": "3WJ86kV_VQzLWaED3hSRlY9R6wQHh_f3UEZ_q-CrwRU", "demoKeyPairId": 9001, "initialBalance": "1000.00000000", "permissions": "READ_TRADE", "ipWhitelist": "", "createdAt": "2026-04-25T18:00:00Z" } }
subscription.deleted — kullanıcı bağlantıyı kesti, anahtar devre dışıX-BuyCrypt-Event: subscription.disconnected { "event": "subscription.disconnected", "deliveryId": "…", "timestamp": …, "data": { "subscriptionId": 42, "botProfileId": 7, "apiKey": "3fc370a4…", "reason": "USER_UNSUBSCRIBED", "disconnectedAt": "2026-04-25T18:30:00Z" } }
secret.regenerated — yönetici webhook secret'ınızı değiştirdiX-BuyCrypt-Event: secret.regenerated { "event": "secret.regenerated", "deliveryId": "…", "timestamp": …, "data": { "subscriptionId": 42, "apiKey": "3fc370a4…", "newApiSecret": "new_plaintext_keep_old_valid_24h", "oldSecretValidUntil": "2026-04-26T18:00:00Z" } }
Use the raw request body bytes — DO NOT parse JSON first and re-serialize, you'll lose key order and signatures will diverge. Always compare in constant time.
# Python (FastAPI / Flask) import hmac, hashlib, time WEBHOOK_SECRET = "whsec_aGVsbG8gd29ybGQ_..." # whsec_…43 chars def verify(headers, body_bytes): sig = headers["X-BuyCrypt-Signature"] ts = int(headers["X-BuyCrypt-Timestamp"]) # anti-replay: reject if too old if abs(time.time() * 1000 - ts) > 5 * 60 * 1000: return False payload = f"{ts}.".encode() + body_bytes expected = hmac.new(WEBHOOK_SECRET.encode(), payload, hashlib.sha256).hexdigest() return hmac.compare_digest(expected, sig)
// Node.js / Express — read RAW body, not parsed JSON const crypto = require('crypto'); const SECRET = 'whsec_aGVsbG8gd29ybGQ_...'; app.post('/buycrypt/hook', express.raw({ type: 'application/json' }), // raw, not json()! (req, res) => { const sig = req.headers['x-buycrypt-signature']; const ts = parseInt(req.headers['x-buycrypt-timestamp'], 10); if (Math.abs(Date.now() - ts) > 5 * 60 * 1000) return res.status(401).end(); const expected = crypto.createHmac('sha256', SECRET) .update(`${ts}.`).update(req.body).digest('hex'); if (!crypto.timingSafeEqual(Buffer.from(expected), Buffer.from(sig))) { return res.status(401).end(); } // req.body is a Buffer here — JSON.parse(req.body.toString('utf8')) res.sendStatus(200); });
Üstel geri çekilmeyle 6 deneme: 1dk, 5dk, 30dk, 2sa, 6sa, 12sa. 6'sı da başarısız olursa, olay dead-letter tablomuza düşer ve bir yönetici tekrar oynatabilir.
Uç noktanız arka arkaya 10 kez başarısız olursa, devre dışı olarak işaretleriz ve olay göndermeyi durdururuz. Yeniden etkinleştirmek için bize ulaşın. Bu, ölü bir botun yeni aboneleri süresiz olarak engellemesini önler.
Her gövde, kayıt sırasında paylaştığımız secret ile HMAC-SHA256 imzalıdır. Yükü güvenmeden önce sabit zamanlı doğrulayın. Örnekler partner rehberimizde.
Base URL: https://api.buycrypt.com/fapi. Kimlik doğrulama: imzalı uç noktalarda X-MBX-APIKEY başlığı + HMAC-SHA256 imzası. Recv window: varsayılan 5.000 ms, maksimum 60.000 ms.
{} döndürür.MARKET, LIMIT, STOP_MARKET, TAKE_PROFIT_MARKET, STOP, TAKE_PROFIT (limit türü), TRAILING_STOP_MARKET destekler. Bayraklar: reduceOnly, closePosition, timeInForce (GTC/IOC/FOK), idempotency için newClientOrderId, workingType, callbackRate.orderId veya origClientOrderId ile tek bir emiri sorgulayın.{dualSidePosition: false} döndürür.ORDER_TRADE_UPDATE, ACCOUNT_UPDATE, MARGIN_CALL. Binance ile aynı yük şekli.subscribe/unsubscribe/list_subscriptions kontrol mesajlarını destekler — üst akış Binance'e doğrudan geçiş.X-MBX-USED-WEIGHT-1M, X-MBX-ORDER-COUNT-10S, 429'da Retry-After.Retry-After üzerinden yavaşlayınBaşvuru formu yok, inceleme kuyruğu yok, entegrasyon ücreti yok. Herhangi bir kullanıcı gibi kaydolun, mobil uygulamada API anahtarları oluşturun, botunuzu https://api.buycrypt.com/fapi adresine yönlendirin — tüm entegrasyon bu kadar.