Okex akun (kontrak, koin, dompet) untuk mengubah mata uang, apakah ada contoh kode?
Peraturan sub akun berbeda di setiap bursa, minta contoh kode okex.
MartinashesApakah transfer dari rekening koin ke rekening kontrak dapat dilakukan melalui API?
Jumlah investasi 01Terima kasih banyak!
Penemu Kuantitas - Mimpi KecilAsalkan pertukaran menyediakan antarmuka API seperti Coinbase, Coinbase, dan lain-lain, antarmuka ini dapat dipanggil langsung dengan exchange.IO. Untuk kode yang terkait, Anda dapat melihat template di Perpustakaan Perdagangan Mata Uang Digital: `` $.withdraw = function ((e, currency, address, amount, fee, password) { var withdraw_id = null; var ret = null; currency = currency.toLowerCase (dalam bahasa Inggris) switch (e.GetName)) { Kasus "OKCoin_EN": ret = e.IO (("api", "POST", "/api/v1/withdraw.do", "symbol="+currency.toLowerCase() +"_usd&chargefee=" + fee + "&trade_pwd=" + password + "&withdraw_address=" + address + "&withdraw_amount=" + amount); if (ret && typeof(ret.withdraw_id)!== 'undefined') { withdraw_id = ret.withdraw_id; } lainnya { Var err = GetLastError (); if (err && err.indexOf('10031')!== -1) { Log (("OKCoin_EN membutuhkan 6 konfirmasi jaringan untuk dapat ditarik kembali"); Aku tidak tahu. Aku tidak tahu. "Mengenai apa?" Kasus "Huobi": if (currency == "bch") { currency = "bcc" Aku tidak tahu. ret = e.IO (("api", "POST", "/v1/dw/withdraw-virtual/create", "currency="+currency+"&fee=" + fee + "&address=" + address + "&amount=" + amount); if (ret && typeof(ret.withdraw_id)!== 'undefined') { withdraw_id = ret.data; Aku tidak tahu. "Mengenai apa?" Kasus "Bithumb": ret = e.IO (("api", "POST", "/trade/btc_withdrawal", "currency="+currency.toUpperCase() +"&address=" + address + "&units=" + amount); if (ret && parseInt ((ret.status) == 0) { withdraw_id = 9999; Aku tidak tahu. "Mengenai apa?" Kasus "GateIO": ret = e.IO (("api", "POST", "/api2/1/private/withdraw", "currency="+currency+" & address=" + address + "&amount=" + amount); if (ret && parseInt ((ret.code) == 0) { withdraw_id = 9999; Aku tidak tahu. "Mengenai apa?" Kasus "ZB": ret = e.IO (("api", "POST", "/api/withdraw", "method=withdraw&itransfer=0¤cy="+currency+"&receiveAddr=" + address + "&amount=" + amount+"&fees="+fee+"&safePwd="+password); if (ret && parseInt ((ret.code) == 0) { dengandraw_id = ret.id; Aku tidak tahu. "Mengenai apa?" Kasus "Bitfinex": Var cMap = { "btc": "bitcoin", "bitcoin", "bitcoin", "bitcoin", "bitcoin", "bitcoin", "bitcoin", "bitcoin", "bitcoin", "bitcoin", "bitcoin", "bitcoin", "bitcoin", "bitcoin", "bitcoin", "bitcoin", "bitcoin", "bitcoin" "ltc": "litecoin", "eth": "ethereum", "etc": "ethereum c", "zec": "zcash", "xmr": "Monero", "Monero", "Monero", "Monero", "Monero", "Monero", "Monero", "Monero", "Monero", "Monero", "Monero", "Monero", "Monero", "Monero", "Monero", "Monero", "Monero", "Monero", "Monero", "Monero", "Monero", "Monero", "Monero", "Monero", "Monero", "Monero", "Monero", "Monero", "Monero", "Monero", "Monero", "Monero", "Monero", "Monero", "Monero", "Monero", "Monero", "Monero", "Monero", "Monero", "Monero", "Monero" Omni: "mastercoin" "usd": "wire", "dash": "dash", "xrp": "ripple", "eos": "eos"}; if (typeof ((cMap[currency]) == 'undefined') { throw "bitfinex not support " + currency; Aku tidak tahu. var withdraw_type = cMap[currency]; ret = e.IO (("api", "POST", "/v1/withdraw", "withdraw_type=" + withdraw_type + "&walletselected=exchange&address=" + address + "&amount='" + amount + "'"); if (ret && ret.length == 1 && typeof(ret[0].withdrawal_id)!== 'undefined') { withdraw_id = ret[0].withdrawal_id; Aku tidak tahu. "Mengenai apa?" Kasus "Poloniex": var ext = ""; Jika (currency == 'xrp') { /ext = '&paymentId=' + PXRPLabel; Aku tidak tahu. if (currency.toLowerCase() == 'bts' && address.indexOf('_') == -1) { alamat = "poloniexwallet_" + alamat; Aku tidak tahu. ret = e.IO (("api", "POST", "withdraw", "amount=" + amount + "¤cy="+currency.toUpperCase() +"&address=" + address+ext); if (ret && ret.response.indexOf('With')!== -1) { withdraw_id = 9999; Aku tidak tahu. break Kasus "Bittrex": ret = e.IO (("api", "GET", "/api/v1.1/account/withdraw", "quantity=" + amount + "¤cy="+currency.toUpperCase() +"&address=" + address); if (ret && ret.success) { dengandraw_id = ret.result.uuid; Aku tidak tahu. break Kasus "Binance": ret = e.IO (("api", "POST", "/wapi/v1/withdraw.html", "amount=" + amount + "&asset=" + currency + "&address=" + address); if (ret && ret.success) { withdraw_id = 9999; Aku tidak tahu. break Kasus "OKEX": ret = e.IO (("api", "POST", "/api/v1/withdraw.do", "target=address&withdraw_amount=" + amount + "&symbol="+currency+"_usd&withdraw_address=" + address+"&chargefee="+fee+"&trade_pwd="+password); jika (ret && ret.result) { withdraw_id = ret.withdraw_id; Aku tidak tahu. break default: Membuang "Operasi tidak didukung"; Aku tidak tahu. return {info: ret, withdraw_id: withdraw_id} Aku tidak tahu. ``