Skip to content

Commit

Permalink
updated rpc methods
Browse files Browse the repository at this point in the history
  • Loading branch information
lmittmann committed Aug 13, 2024
1 parent b9d2e34 commit cd96494
Show file tree
Hide file tree
Showing 4 changed files with 25 additions and 25 deletions.
10 changes: 5 additions & 5 deletions docs/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,14 @@
},
"dependencies": {
"next": "^14.2.5",
"nextra": "3.0.0-alpha.28",
"nextra-theme-docs": "3.0.0-alpha.28",
"nextra": "3.0.0-alpha.31",
"nextra-theme-docs": "3.0.0-alpha.31",
"react": "^18.3.1",
"react-dom": "^18.3.1"
},
"devDependencies": {
"autoprefixer": "^10.4.19",
"postcss": "^8.4.39",
"tailwindcss": "^3.4.4"
"autoprefixer": "^10.4.20",
"postcss": "^8.4.41",
"tailwindcss": "^3.4.9"
}
}
8 changes: 4 additions & 4 deletions docs/pages/rpc-methods/debug.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,15 @@ List of supported RPC methods for `w3.Client` in the `debug`-namespace.
## `debug_traceCall`
`TraceCall` requests the trace of the given message.
```go {3}
var trace debug.Trace
var trace *debug.Trace
client.Call(
debug.TraceCall(msg, blockNumber, config).Returns(&trace),
)
```

`CallTraceCall` requests the call trace of the given message.
```go {3}
var trace debug.CallTrace
var trace *debug.CallTrace
client.Call(
debug.CallTraceCall(msg, blockNumber, overrides).Returns(&trace),
)
Expand All @@ -23,15 +23,15 @@ client.Call(
`TraceTx` requests the trace of the transaction with the given hash.
TraceTx requests the trace of the transaction with the given hash.
```go {3}
var trace debug.Trace
var trace *debug.Trace
client.Call(
debug.TraceTx(txHash, config).Returns(&trace),
)
```

`CallTraceTx` requests the call trace of the transaction with the given hash.
```go {3}
var trace debug.CallTrace
var trace *debug.CallTrace
client.Call(
debug.CallTraceTx(txHash, overrides).Returns(&trace),
)
Expand Down
26 changes: 13 additions & 13 deletions docs/pages/rpc-methods/eth.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ List of supported RPC methods for `w3.Client` in the `eth`-namespace.
## `eth_blockNumber`
`BlockNumber` requests the number of the most recent block.
```go {3}
var blockNumber big.Int
var blockNumber *big.Int
client.Call(
eth.BlockNumber().Returns(&blockNumber),
)
Expand All @@ -32,7 +32,7 @@ client.Call(
## `eth_createAccessList`
`AccessList` requests the access list of the given message at the given blockNumber. If blockNumber is nil, the access list of the message at the latest block is requested.
```go {3}
var accessListResp AccessListResponse
var accessListResp *AccessListResponse
client.Call(
eth.AccessList(msg, blockNumber).Returns(&accessListResp),
)
Expand All @@ -50,7 +50,7 @@ client.Call(
## `eth_gasPrice`
`GasPrice` requests the current gas price in wei.
```go {3}
var gasPrice big.Int
var gasPrice *big.Int
client.Call(
eth.GasPrice().Returns(&gasPrice),
)
Expand All @@ -59,7 +59,7 @@ client.Call(
## `eth_maxPriorityFeePerGas`
`GasTipCap` requests the currently suggested gas tip cap after EIP-1559 to allow a timely execution of a transaction.
```go {3}
var gasTipCap big.Int
var gasTipCap *big.Int
client.Call(
eth.GasTipCap().Returns(&gasTipCap),
)
Expand All @@ -68,7 +68,7 @@ client.Call(
## `eth_getBalance`
`Balance` requests the balance of the given common.Address addr at the given blockNumber. If blockNumber is nil, the balance at the latest known block is requested.
```go {3}
var balance big.Int
var balance *big.Int
client.Call(
eth.Balance(addr, blockNumber).Returns(&balance),
)
Expand All @@ -77,7 +77,7 @@ client.Call(
## `eth_getBlockByHash`
`BlockByHash` requests the block with the given hash with full transactions.
```go {3}
var block types.Block
var block *types.Block
client.Call(
eth.BlockByHash(hash).Returns(&block),
)
Expand All @@ -86,7 +86,7 @@ client.Call(
## `eth_getBlockByNumber`
`BlockByNumber` requests the block with the given number with full transactions. If number is nil, the latest block is requested.
```go {3}
var block types.Block
var block *types.Block
client.Call(
eth.BlockByNumber(number).Returns(&block),
)
Expand Down Expand Up @@ -149,7 +149,7 @@ client.Call(
## `eth_getTransactionByHash`
`Tx` requests the transaction with the given hash.
```go {3}
var tx types.Transaction
var tx *types.Transaction
client.Call(
eth.Tx(hash).Returns(&tx),
)
Expand All @@ -158,7 +158,7 @@ client.Call(
## `eth_getTransactionByBlockHashAndIndex`
`TxByBlockHashAndIndex` requests the transaction in the given block with the given index.
```go {3}
var tx types.Transaction
var tx *types.Transaction
client.Call(
eth.TxByBlockHashAndIndex(blockHash, index).Returns(&tx),
)
Expand All @@ -167,7 +167,7 @@ client.Call(
## `eth_getTransactionByBlockNumberAndIndex`
`TxByBlockNumberAndIndex` requests the transaction in the given block with the given index.
```go {3}
var tx types.Transaction
var tx *types.Transaction
client.Call(
eth.TxByBlockNumberAndIndex(blockNumber, index).Returns(&tx),
)
Expand All @@ -184,7 +184,7 @@ client.Call(
## `eth_getTransactionReceipt`
`TxReceipt` requests the receipt of the transaction with the given hash.
```go {3}
var receipt types.Receipt
var receipt *types.Receipt
client.Call(
eth.TxReceipt(txHash).Returns(&receipt),
)
Expand All @@ -210,7 +210,7 @@ client.Call(
## `eth_getUncleByBlockHashAndIndex`
`UncleByBlockHashAndIndex` requests the uncle of the block with the given hash at the given index.
```go {3}
var uncle types.Header
var uncle *types.Header
client.Call(
eth.UncleByBlockHashAndIndex(hash, index).Returns(&uncle),
)
Expand All @@ -219,7 +219,7 @@ client.Call(
## `eth_getUncleByBlockNumberAndIndex`
`UncleByBlockNumberAndIndex` requests the uncle of the block with the given number at the given index.
```go {3}
var uncle types.Header
var uncle *types.Header
client.Call(
eth.UncleByBlockNumberAndIndex(number, index).Returns(&uncle),
)
Expand Down
6 changes: 3 additions & 3 deletions docs/pages/rpc-methods/txpool.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ List of supported RPC methods for `w3.Client` in the `txpool`-namespace.
## `txpool_content`
`Content` requests the pending and queued transactions in the transaction pool.
```go {3}
var content txpool.ContentResponse
var content *txpool.ContentResponse
client.Call(
txpool.Content().Returns(&content),
)
Expand All @@ -14,7 +14,7 @@ client.Call(
## `txpool_contentFrom`
`ContentFrom` requests the pending and queued transactions in the transaction pool from the given address.
```go {3}
var contentFrom txpool.ContentFromResponse
var contentFrom *txpool.ContentFromResponse
client.Call(
txpool.ContentFrom(addr).Returns(&contentFrom),
)
Expand All @@ -24,7 +24,7 @@ client.Call(
## `txpool_status`
`Status` requests the number of pending and queued transactions in the transaction pool.
```go {3}
var status txpool.StatusResponse
var status *txpool.StatusResponse
client.Call(
txpool.Status().Returns(&status),
)
Expand Down

0 comments on commit cd96494

Please sign in to comment.