problem: doesn't work for private ethereum networks
solution: allow configuring methods with static responses rel: #96
This commit is contained in:
@@ -218,6 +218,27 @@ NOTE: It's especially useful when used together with upstream labels.If an archi
|
||||
possible to specify that the client wants to execute method `trace_transaction` only on an archive node(s), which has
|
||||
complete historical data for tracing.
|
||||
|
||||
=== Static Methods
|
||||
|
||||
You can overwrite existing methods or add new ones using a static response:
|
||||
|
||||
[source, yaml]
|
||||
----
|
||||
upstreams:
|
||||
- id: my-node
|
||||
chain: ethereum
|
||||
methods:
|
||||
enabled:
|
||||
- name: net_version
|
||||
static: "\"100000\""
|
||||
- name: eth_chainId
|
||||
static: "0x186a0"
|
||||
- name: eth_custom_array
|
||||
static: '["custom_array_response"]'
|
||||
- name: eth_custom_bool
|
||||
static: "false"
|
||||
----
|
||||
|
||||
=== Authentication
|
||||
|
||||
==== TLS
|
||||
@@ -234,4 +255,4 @@ NOTE: Please note that `key` must be encoded with _PKCS 8_
|
||||
For JSON RPC and Websockets a Basic Authentication can be used:
|
||||
|
||||
- `username` - username
|
||||
- `password` - password
|
||||
- `password` - password
|
||||
|
||||
Reference in New Issue
Block a user