作者 karlet

feat:增加杠杆设置

... ... @@ -67,6 +67,13 @@ class Api
$method = "POST";
return $this->request($method, $url, $params, $this->apiInfo);
}
//设置杠杆
public function setLever($params)
{
$url = "/fapi/v1/leverage";
$method = "POST";
return $this->request($method, $url, $params, $this->apiInfo);
}
//------------------------------------
... ...
... ... @@ -129,4 +129,8 @@ class ExBroker
{
return $this->api->placeOrder($params);
}
public function setLever($symbol, $lever)
{
return $this->api->setLever(['symbol' => $symbol, 'leverage' => $lever]);
}
}
... ...