Skip to content

Commit 3ff13d2

Browse files
OPDATA-5523 remove view-function-multi-chain from readmeBlacklist to document new endpoints (#4469)
* OPDATA-5523 remove view-function-multi-chain from readmeBlacklist to document new endpoints * add changeset
1 parent 9819cd0 commit 3ff13d2

File tree

4 files changed

+96
-20
lines changed

4 files changed

+96
-20
lines changed

.changeset/curly-rabbits-beg.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
---
2+
'@chainlink/view-function-multi-chain-adapter': patch
3+
'@chainlink/ea-scripts': patch
4+
---
5+
6+
Remove view-function-multi-chain from readme generator blacklist

packages/scripts/src/generate-readme/readmeBlacklist.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,6 @@
4141
"synthetix-debt-pool",
4242
"the-graph",
4343
"token-allocation",
44-
"view-function-multi-chain",
4544
"xsushi-price",
4645
"coinbase-prime",
4746
"harris-and-trotter",

packages/sources/view-function-multi-chain/README.md

Lines changed: 82 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,28 +1,41 @@
11
# VIEW_FUNCTION_MULTI_CHAIN
22

3-
![v3](https://img.shields.io/badge/framework%20version-v3-blueviolet)
3+
![1.6.0](https://img.shields.io/github/package-json/v/smartcontractkit/external-adapters-js?filename=packages/sources/view-function-multi-chain/package.json) ![v3](https://img.shields.io/badge/framework%20version-v3-blueviolet)
4+
5+
This document was generated automatically. Please see [README Generator](../../scripts#readme-generator) for more info.
6+
7+
## Generic Environment Variables
8+
9+
In order to connect to different blockchains, you may need to set additional environment variables for the respective RPC URLs.
10+
11+
| Required? | Name | Description | Type | Options | Default |
12+
| :-------: | :-----------------: | :---------------------: | :----: | :-----: | :-----: |
13+
| | {NETWORK}\_RPC_URL | RPC url for a NETWORK. | string | | |
14+
| | {NETWORK}\_CHAIN_ID | Chain id for a NETWORK. | number | | |
415

516
## Environment Variables
617

718
| Required? | Name | Description | Type | Options | Default |
819
| :-------: | :-------------------: | :---------------------------------------------------------------------------------------: | :----: | :-----: | :-----: |
9-
| | {NETWORK}\_RPC_URL | RPC url for a NETWORK. NETWORK is the value of `network` input param | string | | |
10-
| | {NETWORK}\_CHAIN_ID | Chain id for a NETWORK. NETWORK is the value of `network` input param | number | | |
20+
| | APTOS_URL | Aptos rest api url | string | | `` |
21+
| | APTOS_TESTNET_URL | Aptos testnet rest api url | string | | `` |
1122
| | BACKGROUND_EXECUTE_MS | The amount of time the background execute should sleep before performing the next request | number | | `10000` |
1223

1324
---
1425

1526
## Data Provider Rate Limits
1627

17-
There are no rate limits for this adapter.
28+
| Name | Requests/credits per second | Requests/credits per minute | Requests/credits per hour | Note |
29+
| :-----: | :-------------------------: | :-------------------------: | :-----------------------: | :---------------: |
30+
| default | 1 | | | Reasonable limits |
1831

1932
---
2033

2134
## Input Parameters
2235

23-
| Required? | Name | Description | Type | Options | Default |
24-
| :-------: | :------: | :-----------------: | :----: | :----------------------------: | :--------: |
25-
| | endpoint | The endpoint to use | string | [function](#function-endpoint) | `function` |
36+
| Required? | Name | Description | Type | Options | Default |
37+
| :-------: | :------: | :-----------------: | :----: | :------------------------------------------------------------------------------------------------------------------------------------------------------------------------: | :--------: |
38+
| | endpoint | The endpoint to use | string | [aptos-df-reader](#aptos-df-reader-endpoint), [aptos](#aptos-endpoint), [function-response-selector](#function-response-selector-endpoint), [function](#function-endpoint) | `function` |
2639

2740
## Function Endpoint
2841

@@ -39,18 +52,68 @@ There are no rate limits for this adapter.
3952

4053
### Example
4154

42-
Request:
43-
44-
```json
45-
{
46-
"data": {
47-
"endpoint": "function",
48-
"signature": "function latestAnswer() view returns (int256)",
49-
"address": "0x779877A7B0D9E8603169DdbD7836e478b4624789",
50-
"network": "ETHEREUM_GOERLI"
51-
}
52-
}
53-
```
55+
There are no examples for this endpoint.
56+
57+
---
58+
59+
## Function-response-selector Endpoint
60+
61+
`function-response-selector` is the only supported name for this endpoint.
62+
63+
### Input Params
64+
65+
| Required? | Name | Aliases | Description | Type | Options | Default | Depends On | Not Valid With |
66+
| :-------: | :---------: | :--------: | :---------------------------------------------------------------------------------------------------------------------------------------------------------: | :------: | :-----: | :-----: | :--------: | :------------: |
67+
|| signature | `function` | Function signature. Should be formatted as [human readable ABI](https://docs.ethers.io/v5/single-page/#/v5/getting-started/-%23-getting-started--contracts) | string | | | | |
68+
|| address | `contract` | Address of the contract | string | | | | |
69+
| | inputParams | | Array of function parameters in order | string[] | | | | |
70+
|| network | | RPC network name | string | | | | |
71+
|| resultField | | If present, returns the named parameter specified from the signature's response. Has precedence over resultIndex. | string | | | | |
72+
73+
### Example
74+
75+
There are no examples for this endpoint.
76+
77+
---
78+
79+
## Aptos Endpoint
80+
81+
`aptos` is the only supported name for this endpoint.
82+
83+
### Input Params
84+
85+
| Required? | Name | Aliases | Description | Type | Options | Default | Depends On | Not Valid With |
86+
| :-------: | :---------: | :--------: | :-------------------------------------------------------------------: | :------: | :------------------: | :-------: | :--------: | :------------: |
87+
|| signature | `function` | Function signature. Format: {address}::{module name}::{function name} | string | | | | |
88+
| | arguments | | Arguments of the function | string[] | | | | |
89+
| | type | | Type arguments of the function | string[] | | | | |
90+
| | index | | Which item in the function output array to return | number | | | | |
91+
| | networkType | | testnet or mainnet | string | `mainnet`, `testnet` | `mainnet` | | |
92+
93+
### Example
94+
95+
There are no examples for this endpoint.
96+
97+
---
98+
99+
## Aptos-df-reader Endpoint
100+
101+
`aptos-df-reader` is the only supported name for this endpoint.
102+
103+
### Input Params
104+
105+
| Required? | Name | Aliases | Description | Type | Options | Default | Depends On | Not Valid With |
106+
| :-------: | :---------: | :--------: | :-------------------------------------------------------------------: | :------: | :------------------: | :-------: | :--------: | :------------: |
107+
|| signature | `function` | Function signature. Format: {address}::{module name}::{function name} | string | | | | |
108+
| | arguments | | Arguments of the function | string[] | | | | |
109+
| | type | | Type arguments of the function | string[] | | | | |
110+
| | index | | Which item in the function output array to return | number | | | | |
111+
| | networkType | | testnet or mainnet | string | `mainnet`, `testnet` | `mainnet` | | |
112+
|| feedId | | feedId to parse | string | | | | |
113+
114+
### Example
115+
116+
There are no examples for this endpoint.
54117

55118
---
56119

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
## Generic Environment Variables
2+
3+
In order to connect to different blockchains, you may need to set additional environment variables for the respective RPC URLs.
4+
5+
| Required? | Name | Description | Type | Options | Default |
6+
| :-------: | :-----------------: | :---------------------: | :----: | :-----: | :-----: |
7+
| | {NETWORK}\_RPC_URL | RPC url for a NETWORK. | string | | |
8+
| | {NETWORK}\_CHAIN_ID | Chain id for a NETWORK. | number | | |

0 commit comments

Comments
 (0)