# Queries to Umbrel from Python

**URL:** <https://community.umbrel.com/t/queries-to-umbrel-from-python/6629>\
**Category:** Support and Troubleshooting\
**Created:** [March 5, 2022, 5:53pm UTC](https://community.umbrel.com/t/queries-to-umbrel-from-python/6629 "2022-03-05T17:53:06Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![zeycus](https://yyz2.discourse-cdn.com/flex030/user_avatar/community.umbrel.com/zeycus/32/1795_2.png) [@zeycus](https://community.umbrel.com/u/zeycus)\
**Post date:** [March 5, 2022, 5:53pm UTC](https://community.umbrel.com/t/queries-to-umbrel-from-python/6629/1 "2022-03-05T17:53:06Z")

</div>

I used to run BitcoinCore on my PC, and with the BitcoinLib library I could connect to it and query for blocks, transactions, etc. In Umbrel I installed a nice app: BTC RPC Explorer, it is easy to use if you enter the information interactively. Is it also possible to use it to query Umbrel from Python? If not, is there another way to do this?

Edit: I am trying

```
user = 'umbrel'
pwd = 'fdG........_Kw='
host = 'xx2....5frwad.onion'
port = '8332'

bdc = BitcoindClient(
    base_url=f"https://{user}:{pwd}@{host}:{port}"
)

```

and getting the error

```
for res in _socket.getaddrinfo(host, port, family, type, proto, flags): socket.gaierror: [Errno 11001] getaddrinfo failed.

```

Also tried building the connection string as

```
    base_url=f"btcrpc://{user}:{pwd}@{host}:{port}"

```

with the same result.

---

<div class="post-metadata">

**Author:** ![jpcrespo](https://avatars.discourse-cdn.com/v4/letter/j/9f8e36/32.png) [@jpcrespo](https://community.umbrel.com/u/jpcrespo)\
**Post date:** [July 11, 2022, 5:12pm UTC](https://community.umbrel.com/t/queries-to-umbrel-from-python/6629/2 "2022-07-11T17:12:19Z")

</div>

im in the same situation

---

<div class="post-metadata">

**Author:** ![Invoany](https://yyz2.discourse-cdn.com/flex030/user_avatar/community.umbrel.com/invoany/32/3119_2.png) [@Invoany](https://community.umbrel.com/u/Invoany)\
**Post date:** [December 23, 2022, 4:51pm UTC](https://community.umbrel.com/t/queries-to-umbrel-from-python/6629/3 "2022-12-23T16:51:19Z")

</div>

I am also in same situation, have you guys tried the lib bitcoin-explorer ?
