fetch account's market settings. Settings are cached for walletAddress. To refresh the cache, call loadAccountSettings with refresh=true https://docs.pacifica.fi/api-documentation/api/rest-api/account/get-account-settings :param dict [params]: extra parameters specific to
(self, params={})
| 701 | } |
| 702 | |
| 703 | def fetch_account_settings(self, params={}) -> dict: |
| 704 | """ |
| 705 | fetch account's market settings. Settings are cached for walletAddress. To refresh the cache, call loadAccountSettings with refresh=true |
| 706 | |
| 707 | https://docs.pacifica.fi/api-documentation/api/rest-api/account/get-account-settings |
| 708 | |
| 709 | :param dict [params]: extra parameters specific to the exchange API endpoint |
| 710 | :param str [params.account]: will default to walletAddress if not provided |
| 711 | :returns dict: Dict repacked from list by symbol key |
| 712 | """ |
| 713 | userAccount = None |
| 714 | userAccount, params = self.handle_origin_and_single_address('fetchAccountSettings', params) |
| 715 | request = { |
| 716 | 'account': userAccount, |
| 717 | } |
| 718 | response = self.publicGetAccountSettings(self.extend(request, params)) |
| 719 | # { |
| 720 | # "success": True, |
| 721 | # "data": [ |
| 722 | # { |
| 723 | # "symbol": "WLFI", |
| 724 | # "isolated": False, |
| 725 | # "leverage": 5, |
| 726 | # "created_at": 1758085929703, |
| 727 | # "updated_at": 1758086074002 |
| 728 | # } |
| 729 | # ], |
| 730 | # "error": null, |
| 731 | # "code": null |
| 732 | # } |
| 733 | return self.parse_account_settings(self.safe_list(response, 'data', [])) |
| 734 | |
| 735 | def load_account_settings(self, refresh: bool = False, params={}): |
| 736 | settings = self.handle_option('loadAccountSettings', 'settings', None) |
no test coverage detected