getAccount (SDK Trading)
getAccount is a Fintechee API to get the specific account from the accounts that you have signed in. You can specify the account that you want to get by the selector(the index of the account).
object
getAccount(context, selector) ⇒ EA SDK This function gets account. Phase (this API's scope): init | onTick | deinit
Kind: global function
Returns: object
- account.
Param | Type | Description |
---|---|---|
context | object | the name should be the same with the name of parameter of initFunction or deinitFunction or onTickFunction |
selector | number | index of account |
getAccount (SDK Trading)
registerEA(
"test_api",
"An EA to test APIs",
[],
function (context) { // Init()
var account = getAccount(context, 0)
},
function (context) { // Deinit()
},
function (context) { // OnTick()
})