feat(): start adding per-endpoint examples
This commit is contained in:
25
examples/apidoc/V5/Trade/amend-order.js
Normal file
25
examples/apidoc/V5/Trade/amend-order.js
Normal file
@@ -0,0 +1,25 @@
|
||||
const { RestClientV5 } = require('bybit-api');
|
||||
|
||||
const client = new RestClientV5({
|
||||
testnet: true,
|
||||
key: 'apikey',
|
||||
secret: 'apisecret',
|
||||
});
|
||||
|
||||
client
|
||||
.submitOrder({
|
||||
category: 'linear',
|
||||
symbol: 'ETHPERP',
|
||||
orderLinkId: 'linear-004',
|
||||
triggerPrice: '1145',
|
||||
qty: '0.15',
|
||||
price: '1050',
|
||||
takeProfit: '0',
|
||||
stopLoss: '0',
|
||||
})
|
||||
.then((response) => {
|
||||
console.log(response);
|
||||
})
|
||||
.catch((error) => {
|
||||
console.error(error);
|
||||
});
|
||||
Reference in New Issue
Block a user