Specifying providers to be used when using Wallet class #473
-
| Problem: As such, I sometimes manage to hit rate limits on two (so far) APIs bitcoinlib uses to perform lookups. Specifically, let's say, blockchair and trezor. What I want to do, is to manually specify which providers shall my Wallet instances use. I want to explicitly specify to cut out some providers (e.g. blockchair and trezor) OR specify only a handful of them that would actually be used. Unfortunately, I didn't find an elaborate way to do so without modifying lib's own files ( I would much appreciate if someone already faced this issue and would be glad to present their solution. Thanks in advance |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
| Actually the best way to do this is to change the providers.json file in the .bitcoinlib directory. So not in the library code itself but in the settings directory. You can remove providers from providers.json or disable them by setting the proirity to 0. You can alse specify providers after creating a Wallet object: Now only the ElectrumX provider is used. |
Beta Was this translation helpful? Give feedback.
Actually the best way to do this is to change the providers.json file in the .bitcoinlib directory. So not in the library code itself but in the settings directory. You can remove providers from providers.json or disable them by setting the proirity to 0.
You can alse specify providers after creating a Wallet object:
Now only the ElectrumX provider is used.