Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
zzGHzz authored and zzGHzz committed Feb 1, 2023
2 parents 24d9c95 + 24658bb commit cf4c3aa
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ const contract = await factory.deploy(...args)
```
Methods `modifyProvider` and `modifyFactory` are used to bypass the Ethereum contract address computation that is incompatible with the Thor protocol.

### Request at a Particular Block Hight
### Request at a particular block hight
APIs `eth_getBalance`, `eth_getCode`, `et_getStorageAt` and `eth_call` allow users to specify a particular block height [1]. To do that, we need to provide a `Net` object when creating a provider:
```ts
import { SimpleNet } from '@vechain/connex-driver'
Expand Down Expand Up @@ -158,7 +158,7 @@ Equivalent to `eth_chainId`
Returning string `thor`

## Implementation Notes
1. Here `blockHash` and `transactionHash` equivalent to `blockId` and `transactionId` in the Thor protocol
1. Fields `blockHash` and `transactionHash` return the values of [`blockId`](https://docs.vechain.org/thor/learn/block.html#block) and [`transactionId`](https://docs.vechain.org/thor/learn/transaction-model.html#transaction-id) defined in the Thor protocol, respectively
2. APIs `eth_estimateGas`, `eth_call` and `eth_getTransactionReceipt` only return information associated with the first [clause](https://docs.vechain.org/thor/learn/transaction-model.html#clauses) in a transaction
3. Unsupported returning fields (all set to zero):
* `cumulativeGasUsed`
Expand All @@ -174,4 +174,4 @@ This software is licensed under the
[GNU Lesser General Public License v3.0](https://www.gnu.org/licenses/lgpl-3.0.html), also included
in *LICENSE##### file in repository.
## References
[1] [https://eth.wiki/json-rpc/API](https://eth.wiki/json-rpc/API).
[1] [https://eth.wiki/json-rpc/API](https://eth.wiki/json-rpc/API).

0 comments on commit cf4c3aa

Please sign in to comment.