Skip to content

Commit b346929

Browse files
committed
doc: update README.md
1 parent 308f796 commit b346929

File tree

2 files changed

+16
-2
lines changed

2 files changed

+16
-2
lines changed

README.md

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ PHP client for [Etherscan API](https://docs.etherscan.io) (and its families like
1010
- [Available bindings](#available-bindings)
1111
- [Accounts](#accounts)
1212
- [Contracts](#contracts)
13+
- [Proxy](#proxy)
1314

1415
## Installation
1516

@@ -100,3 +101,16 @@ $abi = $this->contracts->getAbi('0xBB9bc244D798123fDe783fCc1C72d3Bb8C189413');
100101
$sourceCode = $this->contracts->getSourceCode('0xBB9bc244D798123fDe783fCc1C72d3Bb8C189413');
101102
```
102103

104+
### Proxy
105+
106+
[eth_getTransactionByHash](https://docs.etherscan.io/api-reference/endpoint/ethgettransactionbyhash):
107+
108+
```php
109+
$transactionInfo = $etherscan->proxy->getTransactionByHash('0x136f818dfe87b367eee9890c162ef343dbd65e409aef102219a6091ba7e696d7');
110+
```
111+
112+
[eth_blockNumber](https://docs.etherscan.io/api-reference/endpoint/ethblocknumber):
113+
114+
```php
115+
$currentBlock = $etherscan->proxy->getBlockNumber();
116+
```

src/Module/Proxy/Proxy.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ final class Proxy
1818
public function __construct(private readonly EtherscanClient $client) {}
1919

2020
/**
21-
* @see https://docs.etherscan.io/api-endpoints/geth-parity-proxy#eth_gettransactionbyhash
21+
* @see https://docs.etherscan.io/api-reference/endpoint/ethgettransactionbyhash
2222
*/
2323
public function getTransactionByHash(string $hash): TransactionByHashInfo
2424
{
@@ -64,7 +64,7 @@ public function getTransactionByHash(string $hash): TransactionByHashInfo
6464
}
6565

6666
/**
67-
* @see https://docs.etherscan.io/api-endpoints/geth-parity-proxy#eth_blocknumber
67+
* @see https://docs.etherscan.io/api-reference/endpoint/ethblocknumber
6868
*/
6969
public function getBlockNumber(): BigInteger
7070
{

0 commit comments

Comments
 (0)