Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

UTXO rpc #1115

Open
winteraz opened this issue Jan 29, 2018 · 3 comments
Open

UTXO rpc #1115

winteraz opened this issue Jan 29, 2018 · 3 comments

Comments

@winteraz
Copy link

winteraz commented Jan 29, 2018

I'm need to get the UTXO of arbitrary addresses akin blockchain.info api call[0]. Is this possible with btcsuite?

[0] https://blockchain.info/api/blockchain_api
Unspent outputs


    https://blockchain.info/unspent?active=$address
    Multiple Addresses Allowed separated by "|"
    Address can be base58 or xpub





{
    "unspent_outputs":[
        {
            "tx_age":"1322659106",
            "tx_hash":"e6452a2cb71aa864aaa959e647e7a4726a22e640560f199f79b56b5502114c37",
            "tx_index":"12790219",
            "tx_output_n":"0",
            "script":"76a914641ad5051edd97029a003fe9efb29359fcee409d88ac", (Hex encoded)
            "value":"5000661330"
        }
    ]
}

@Roasbeef
Copy link
Member

See the gettxout RPC command. Or even the address index depending on your use case.

@stevenroose
Copy link
Contributor

In my gRPC PR, I implemented a method GetAddressUnspentOutputs to get all unspent outputs for a given address.

In this PR a method is implemented (also for gRPC) that allows retrieving the entire UTXO set.

@ghost
Copy link

ghost commented Nov 27, 2019

This would be pretty handy. I think it'd allow btcd to work in place of Insight for the most part.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants