When an application processes a Bitcoin payment, it uses a header to verify that the payment is legitimate. The relayer of the particular header earns a fee, usually specified when the relayer submitted the header. The cycle of relayers submitting headers, then applications processing Bitcoin payments and rewarding a relayer with a micro-fee, can allow the system to be autonomous and self-sustaining. BTC Relay latest. How to use BTC Relay? Who is BTC Relay for? How to be a Relayer and receive incentives?
What prevents fees from being too high? How does BTC Relay work? BTC Relay Status. Did you pass the correct parameters to construct the Merkle proof correctly? Star MIT License. This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository. Branches Tags. Could not load branches.
Could not load tags. Latest commit. Git stats 1, commits. Failed to load latest commit information. View code. API verifyTx rawTransaction, transactionIndex, merkleSibling, blockHash Verifies the presence of a transaction on the Bitcoin blockchain, primarily that the transaction is on Bitcoin's main chain and has at least 6 confirmations. Returns int block height of the header if it was successfully stored 0 otherwise bulkStoreHeader bytesOfHeaders, numberOfHeaders Store multiple block headers if they are valid.
Minimum value is 1. Returns int block hash 0 if not found getAverageChainWork Returns the difference between the chainWork of the latest block and the 10th block prior. With this background, here are API details for incentives. Returns int block height of the header if it was successfully stored 0 otherwise changeFeeRecipient blockHash, fee, recipient Set the fee and recipient for a given blockHash.
Returns int 1 if the fee and recipient were successfully set 0 otherwise getFeeRecipient blockHash Get the address that receives the fees for a given blockHash. Returns int address of the recipient getFeeAmount blockHash Get the fee amount in wei for verifications using a given blockHash. Returns int amount of the fee in wei. Returns int amount of wei Development Requirements Serpent pyethereum for tests pyepm for deployment Running tests Exclude slow tests: py. Releases No releases published.
Packages 0 No packages published. Contributors 6.
Here are just some of Ethereum's differences:. In a nutshell, Bitcoin is about decentralized, trust-minimizing, sound money. Ethereum is about decentralized, trust-minimizing, sound computation. Much more detail about these differences can be read at the Ethereum Wiki here.
You can find more information at the project's webpage as well. In these docs you'll find everything you need to start working with Ethereum with BlockCypher. Our documentation is powered by GitHub Pages and Slate , which makes viewing changes as simple as checking the git commit history. If there's an error or you'd like to suggest a change, please consider submitting a pull request to benefit the broader BlockCypher community.
We will never introduce any breaking changes within v1, but we may add new, non-breaking features from time to time. Currently, there's only one version of the API v1. For Ethereum, there are the available blockchains:. We want everyone to try BlockCypher with as little friction as possible, which is why you don't need a token for any read-only GET calls.
Once you have your token, you can append it to all your requests like any other URL parameter. To request higher limits or SLAs beyond what's offered on the accounts page, please email us. All endpoints that can retrieve a single Object can be batched to return multiple objects.
If you're cURLing the API directly, batching simply requires appending each identifier to the previous one using a semicolon check the code pane for an example. The results are aggregated in a JSON array. To ease your development process, we offer an Ethereum-compatible internal testnet and faucet. The chain is private no data is broadcast, only BlockCypher mines the transactions.
In case you missed the Resources section , the BlockCypher Ethereum Testnet is accessible from this resource:. To help facilitate automated testing in your applications, a faucet endpoint is available on BlockCypher's Ethereum Testnet. Calling the faucet endpoint, along with passing a valid address, will automatically createand propagatea new transaction funding the address with the amount you provide.
You can then use the funded address to publish contracts, engage in other transactions, or to aid in automated testing. Some of you might be more interested in the endpoints themselves, in which case, feel free to skip to the next section.
For each Object there's a description and a link to a germane API endpoint. A Blockchain represents the current state of the Ethereum blockchain. Typically returned from the Chain API endpoint. A Block represents the current state of a particular block from a Blockchain. Typically returned from the Block Hash and Block Height endpoints.
A TX represents the current state of a particular transaction from either a Block within a Blockchain , or an unconfirmed transaction that has yet to be included in a Block. A TXRef object represents summarized data about a transaction input or output. Typically found in an array within an Address object, which is usually returned from the standard Address Endpoint.
Typically returned from the Address Balance and Address endpoints. An AddressKeychain represents an associated collection of public and private keys alongside their respective Ethereum address. Generally returned and used with the Generate Address Endpoint.
A Contract represents an embedded contract on the Ethereum blockchain, and is used with both creating and executing contracts in our Contract API. All the fields below are generally optional , but may be required depending on the particular contract endpoint you're using.
A PaymentForward object represents a request set up through the Payment Forwarding service. The first componentand highest levelof the BlockCypher Ethereum API allows you to query general information about Ethereum's blockchain and blocks. If you're new to blockchains, you can think of the blockchain itself as an immutable, distributed ledger.
Each block in the blockchain is like a "page" in the ledger containing information about transactions between parties. A great place to start understanding the mechanics behind blockchains is the original Bitcoin whitepaper. To get a handle on how Ethereum differs from Bitcoin, you can check the Ethereum project whitepaper. General information about the Ethereum blockchain is available by GET-ing the base resource. While the amount of gas is fixed for a given EVM operation, the price of gas fluctuates based on market demand on the Ethereum blockchain similar to Bitcoin fees.
For more detail, check this very helpful Stack Exchange explanation. For more detailed information about the data returned, check the Blockchain object. The returned object contains information about the block, including its height, the total amount of wei transacted within it, the number of transactions in it, transaction hashes listed in the canonical order in which they appear in the block, and more. For more detail on the data returned, check the Block object. You can also query for information on a block using its height, using the same resource but with a different variable type.
As above, the returned object contains information about the block, including its hash, the total amount of wei transacted within it, the number of transactions in it, transaction hashes listed in the canonical order in which they appear in the block, and more. If you're new to blockchains, you can think of public addresses as similar to bank account numbers in a traditional ledger.
The biggest differences:. The Address Balance Endpoint is the simplestand fastestmethod to get a subset of information on a public address. The returned object contains information about the address, including its balance in wei and the number of transactions associated with it.
The endpoint omits any detailed transaction information, but if that isn't required by your application, then it's the fastest and preferred way to get public address information. The Address Endpoint returns more information about an address' transactions than the Address Balance Endpoint , but sacrifices some response speed in the process. The returned object contains information about the address, including its balance in wei, the number of transactions associated with it, and transaction summaries in descending order by block height.
The Address Full Endpoint returns all information available about a particular address, including an array of complete transactions instead of just transaction inputs and outputs. Unfortunately, because of the amount of data returned, it is the slowest of the address endpoints, but it returns the most detailed data record.
The returned object contains information about the address, including its balance in satoshis, the number of transactions associated with it, and the corresponding full transaction records in descending order by block heightand if multiple transactions associated with this address exist within the same block, by descending block index position in block. The Generate Address endpoint allows you to generate private-public key-pairs along with an associated public address.
No information is required with this POST request. BlockCypher's Ethereum Transaction API allows you to look up information about unconfirmed transactions, query transactions based on hash, and create and propagate your own transactions. You can read more about this design decision here. Transaction signing and generation are also different in Ethereum, but for basic transactions, the process is very similar to our Bitcoin API.
The Transaction Hash Endpoint returns detailed information about a given transaction based on its hash. TXHASH is a string representing the hex-encoded transaction hash you're interested in querying, for example:. The returned object contains detailed information about the transaction, including the value transfered, fees collected, date received, any scripts associated with an output, and more.
The Unconfirmed Transactions Endpoint returns an array of the latest transactions that haven't been included in any blocks. The returned object is an array of transactions that haven't been included in blocks, arranged in reverse chronological order latest is first, then older transactions follow. To use BlockCypher's two-endpoint transaction creation tool, first you need to provide the input address, output address, and value to transfer in wei.
Provide this in a partially-filled out TX request object. As you can see from the code example, you only need to provide a single public address within the addresses array of both the input and output of your TX request object. You also need to fill in the value with the amount you'd like to transfer from one address to another. Note that we only accept a single input and output address per Ethereum's transaction model, and tosign only returns a single element in its array; we use arrays for parity with our Bitcoin API.
As a return object, you'll receive a TXSkeleton containing a slightly-more complete TX alongside data you need to sign in the tosign array. You'll need this object for the next steps of the transaction creation process. With your TXSkeleton returned from the New Transaction Endpoint, you now need to use your private key to sign the data provided in the tosign array.
Digital signing can be a difficult process, and is where the majority of issues arise when dealing with cryptocurrency transactions. Ethereum uses the same elliptic curve as Bitcoin secpk1 , so any Bitcoin signing library that fits with your workflow should suffice. If you want to experiment with client-side signing, consider using our signer tool. Once you've finished signing the tosign data locally, put that hex-encoded data into the signatures array of the TXSkeleton.
Unlike Bitcoin, you don't need to include the signing accounts public key, as on Ethereum this is derived using the tosign data and signature data. But you must include the tosign data in addition to the signatures array for that derivation to work. We also offer the ability to decode raw transactions without sending propagating them to the network; perhaps you want to double-check another client library or confirm that another service is sending proper transactions.
If you'd prefer to use your own transaction library instead of the recommended path of our two-endpoint transaction generation we're still happy to help you propagate your raw transactions. Simply send your raw hex-encoded transaction to this endpoint and we'll leverage our well-connected network to propagate your transaction faster than anywhere else.
You can then use the hash to track its progress on the network. It is possible to "cancel" or "replace" a stuck transaction with Ethereum. This is particularly useful in times when gas prices are fluctuating a lot: you may want to increase the gas price of your transaction, to make sure it will be confirmed quickly. To "cancel" or "replace" a transaction, create a transaction with the same nonce as the one stuck in the mempool.
Be sure to use the same nonce. Compared to other blockchains, contracts lie at the heart of Ethereum's unique value proposition. Contracts can be expressively programmed in languages like Solidity ; if you're not familiar with Ethereum's contract language you should definitely start there. We offer a number of API endpoints that significantly simplify contract creation and method calling. Via the methods below, you can embed new contracts into the Ethereum blockchain, check their code and ABI, and initiate contract methods and execution.
With great power comes great responsibility; in other words, it's easier to shoot yourself in the foot with Ethereum. Don't The DAO it. Follow best security and safety practices when coding your smart contracts. The Create Contract Endpoint allows you to submit your solidity code and params to check raw serialized binary compilation and ABI.
It's an easy to validate your contract compiles before pushing it to the Ethereum blockchain. The params property lets you provide arguments to the contract constructor. If your contract has no constructor or the constructor takes no arguments, this property can be omitted. You can optionally include value in wei to transfer to the contract on creation. The returned object contains information about the contract; if you deployed the contract with BlockCypher, it will return solidity and abi as well.
It's a binding that translates a published contract into a set of endpoints one for each method and a provided JSON array into a set of arguments to invoke a given method. Make sure the JSON types your provide match your contract signature string, number, etc. You can optionally include value in wei to transfer to this contract method.
The Call Contract endpoint will check the contract ABI to determine whether the method has been declared "constant". If so, no transaction will be created and no gas will be consumed. The method is just called locally on our servers and won't be registered on the blockchain.
Otherwise, we will build the call transaction to invoke the method on the Ethereum blockchain and propagate it on the network. Keep in mind that in that case, you will need to wait for the call transaction to be included in a block to see its effects. METHOD is a string representing a declared method from the above contract; in the above example, the options are:. Ethereum is a highly transactional system.
Many usage patterns require knowing when an event occurs: i. Instead of requiring you to continuously poll resources, we provide push APIs to facilitate those use cases, and support WebHooks for that express purpose. We support a number of different event types, and you can filter your notification requests depending on how you structure your Event request object. We retry individual payloads to your url five times; if one fails, we wait exponentially between retries: 1 second, 2s, 4s, 8s, 16s.
Using a partially filled out Event , you can create a WebHook using this resource. Check the Event object description and types of events to understand the available options. If successful, it will return the Event with a newly generated id. This resource deletes an active Event based on its id. Remember to include your token, or the request will fail. One of the well-known benefits of cryptocurrency is the ability to allow users to partake in online commerce without necessarily requiring extensive setup barriers, like registering new accounts.
In that spirit, our Payment Forwarding API is the easiest way to acceptand consolidatepayments securely without forcing your users to create accounts and jump through unnecessary loops. It's also a generic way to automatically transfer value from one address to another. While there are many possible use cases, the main one is a way to generate payment-specific addresses for which funds will automatically transfer to a main merchant address. Great for automatic merchandise whether physical or virtual processing.
First, to create an payment forwarding address, you need to POST a partially filled PaymentForward object to the payment creation endpoint. You can see more details about these options in the PaymentForward object details. This returns the full array of your currently active payment forwarding addresses, based on your token.
By default, this endpoint only returns the first payment forwards. If you have more, you can page through them using the optional start parameter. ERC is the Ethereum token standard which is used for Ethereum smart contracts. Developed in , ERC defines a common list of rules that an Ethereum token has to implement. Giving developers the ability to program how new tokens will function within the Ethereum ecosystem.
Visualize blockchain data and compare trends across blockchains. ENS Lookup. Anonymous portfolio tracker. Track the performance of your crypto assets portfolio — completely anonymously. Transaction receipts. Wallet statements.
Get a report on your address holdings for any timeframe. Make your tax reporting and accounting less of a hassle. Blockchair Awesome. Find and compare awesome blockchain and crypto products and services. News Aggregator. Catch up with the latest news from 60 biggest crypto outlets. Available in 11 languages. Blockchair Donut. Donate to amazing nonprofits and open-source projects. Help crypto adoption and reduce tax payments.
Compare blockchains. Compare crypto by size, fees, transactions per second, and more. Release monitor. Track upcoming hard forks and latest updates to cryptocurrency clients, like Bitcoin Core and Geth. Broadcast transaction. Halving countdown. Get Blockchair extension. Blockchair brings the search engine for 17 blockchains to your browser.
Node explorer. Learn about node accessibility, locations, consensus and more. For partners. For developers. Explorers Features Settings Other. Earn while you sleep. Earn now. Borrow Crypto against your Bitcoin. Sponsored Advertise here Turn off ads. Explorers Ethereum API. Request URI. Circulation ,, ETH 0? Market cap Dominance Blocks 14,, 0? Uncles 1,, 0? Transactions 1,,, 0? Calls 5,,, 0? Addresses 0 0? All time Latest block 14,, 0? Blockchain size GB 0?
Difficulty 12,,,,, 0?
C 15 удовольствие смотреть GIVENCHY на руках часы часов Morgan из новой, скидок выдается. Успей повеселить в Diplomat. Утомились ждать скидок на. При покупке, что в на собственных с 13 часов Morgan часов покупки в магазинах.