fetch all the accounts associated with a profile https://apidoc.ndax.io/#getuseraccounts :param dict [params]: extra parameters specific to the exchange API endpoint :returns dict: a dictionary of `account structures ` i
(self, params={})
| 1092 | return self.parse_trades(response, market, since, limit) |
| 1093 | |
| 1094 | def fetch_accounts(self, params={}) -> List[Account]: |
| 1095 | """ |
| 1096 | fetch all the accounts associated with a profile |
| 1097 | |
| 1098 | https://apidoc.ndax.io/#getuseraccounts |
| 1099 | |
| 1100 | :param dict [params]: extra parameters specific to the exchange API endpoint |
| 1101 | :returns dict: a dictionary of `account structures <https://docs.ccxt.com/?id=account-structure>` indexed by the account type |
| 1102 | """ |
| 1103 | if not self.login: |
| 1104 | raise AuthenticationError(self.id + ' fetchAccounts() requires exchange.login email credential') |
| 1105 | omsId = self.safe_integer(self.options, 'omsId', 1) |
| 1106 | self.check_required_credentials() |
| 1107 | request = { |
| 1108 | 'omsId': omsId, |
| 1109 | 'UserId': self.uid, |
| 1110 | 'UserName': self.login, |
| 1111 | } |
| 1112 | response = self.privateGetGetUserAccounts(self.extend(request, params)) |
| 1113 | # |
| 1114 | # [449] # comma-separated list of account ids |
| 1115 | # |
| 1116 | result = [] |
| 1117 | for i in range(0, len(response)): |
| 1118 | accountId = self.safe_string(response, i) |
| 1119 | result.append({ |
| 1120 | 'id': accountId, |
| 1121 | 'type': None, |
| 1122 | 'currency': None, |
| 1123 | 'info': accountId, |
| 1124 | }) |
| 1125 | return result |
| 1126 | |
| 1127 | def parse_balance(self, response) -> Balances: |
| 1128 | result = { |
nothing calls this directly
no test coverage detected