2017-01-07 1 views
0

polodyex api로 immediatelly를 구매하거나 판매하는 법을 안내합니다. 나는 nickelbot 하고 항상 순서Poloniex api 즉시 구매/판매

function api_buy() 
{ 
    global $Adapters; 

    $exchange = isset($_GET['exchange']) ? $_GET['exchange'] : "error"; 
    if($exchange == "error") return array("error" => "exchange required"); 
    $price = isset($_GET['price']) ? $_GET['price'] : "error"; 
    if($price == "error") return array("error" => "price required"); 
    $amount = isset($_GET['amount']) ? $_GET['amount'] : "error"; 
    if($amount == "error") return array("error" => "amount required"); 
    $market = isset($_GET['market']) ? $_GET['market'] : "error"; 
    if($market == "error") return array("error" => "market required"); 

    //let's not open up the trade api to the public: 


    return array(get_class($Adapters[$exchange]) => $Adapters[$exchange]->buy($market, $amount, $price)); 
} 

답변

0

당신이 immediatelly 무엇을 의미합니까 위해 넣어?를 사용하고

Websocket은 구매 또는 판매 주문을 보내지 않으므로 API 요청을 사용해야합니다.

당신은

무역 API 방법 사용할 수 있습니다 : 구매를하고

Poloniex API support를 살펴 보자 (필수 POST 매개 변수 "currencyPair", "속도"와 "양"이다) 판매