getPositionConfig
Retrieves and parses the position configuration for a given index token and position type (long or short).
Function Signature
Parameters
indexToken
(string): The token for which to retrieve the position configuration.long
(boolean): Indicates whether to retrieve the configuration for a long (true) or short (false) position.
Return Value
Returns a Promise
that resolves to an IPositionConfig
object. The object contains parsed position configuration, including:
Description
This method fetches the position configuration data from the blockchain for a specified index token and position type. It performs the following steps:
Usage Example
Last updated