feat(): add samples & missing endpoints for spot leverage token and spot margin
This commit is contained in:
3
examples/apidoc/V5/Spot-Margin-Trade-(UTA)/README.md
Normal file
3
examples/apidoc/V5/Spot-Margin-Trade-(UTA)/README.md
Normal file
@@ -0,0 +1,3 @@
|
||||
# V5 - REST - Spot Margin Trade (UTA)
|
||||
|
||||
https://bybit-exchange.github.io/docs/v5/spot-margin-uta/switch-mode
|
||||
16
examples/apidoc/V5/Spot-Margin-Trade-(UTA)/set-leverage.js
Normal file
16
examples/apidoc/V5/Spot-Margin-Trade-(UTA)/set-leverage.js
Normal file
@@ -0,0 +1,16 @@
|
||||
const { RestClientV5 } = require('bybit-api');
|
||||
|
||||
const client = new RestClientV5({
|
||||
testnet: true,
|
||||
key: 'apikey',
|
||||
secret: 'apisecret',
|
||||
});
|
||||
|
||||
client
|
||||
.setSpotMarginLeverage('4')
|
||||
.then((response) => {
|
||||
console.log(response);
|
||||
})
|
||||
.catch((error) => {
|
||||
console.error(error);
|
||||
});
|
||||
@@ -0,0 +1,16 @@
|
||||
const { RestClientV5 } = require('bybit-api');
|
||||
|
||||
const client = new RestClientV5({
|
||||
testnet: true,
|
||||
key: 'apikey',
|
||||
secret: 'apisecret',
|
||||
});
|
||||
|
||||
client
|
||||
.toggleSpotMarginTrade('0')
|
||||
.then((response) => {
|
||||
console.log(response);
|
||||
})
|
||||
.catch((error) => {
|
||||
console.error(error);
|
||||
});
|
||||
Reference in New Issue
Block a user