|
@@ -73,7 +73,7 @@ class ExBroker |
|
@@ -73,7 +73,7 @@ class ExBroker |
|
73
|
$subData['op'] = 'subscribe';
|
73
|
$subData['op'] = 'subscribe';
|
|
74
|
$subData['args'] = [
|
74
|
$subData['args'] = [
|
|
75
|
[
|
75
|
[
|
|
76
|
- 'channel' => $this->getKlineChannels()[$period],
|
76
|
+ 'channel' => $period,
|
|
77
|
'instId' => $symbol,
|
77
|
'instId' => $symbol,
|
|
78
|
],
|
78
|
],
|
|
79
|
];
|
79
|
];
|
|
@@ -178,22 +178,6 @@ class ExBroker |
|
@@ -178,22 +178,6 @@ class ExBroker |
|
178
|
{
|
178
|
{
|
|
179
|
return $this->api->placeOrder($param);
|
179
|
return $this->api->placeOrder($param);
|
|
180
|
}
|
180
|
}
|
|
181
|
- public function getKlineChannels()
|
|
|
|
182
|
- {
|
|
|
|
183
|
- return [
|
|
|
|
184
|
- '1s' => 'candle1s',
|
|
|
|
185
|
- '1m' => 'candle1m',
|
|
|
|
186
|
- '5m' => 'candle5m',
|
|
|
|
187
|
- '15m' => 'candle15m',
|
|
|
|
188
|
- '30m' => 'candle30m',
|
|
|
|
189
|
- '1h' => 'candle1H',
|
|
|
|
190
|
- '2h' => 'candle2H',
|
|
|
|
191
|
- '4h' => 'candle4H',
|
|
|
|
192
|
- '6h' => 'candle6H',
|
|
|
|
193
|
- '12h' => 'candle12H',
|
|
|
|
194
|
- '1d' => 'candle1D',
|
|
|
|
195
|
- ];
|
|
|
|
196
|
- }
|
|
|
|
197
|
public function getSymbolInfos()
|
181
|
public function getSymbolInfos()
|
|
198
|
{
|
182
|
{
|
|
199
|
$res = $this->api->instruments(["instType" => "SWAP"]);
|
183
|
$res = $this->api->instruments(["instType" => "SWAP"]);
|